feat: remote browser login persistence + balance display + UI consistency
- Retain login state in remote browser profiles (don't delete on disconnect)
- Add GET /api/browser-sessions/{id}/clipboard for clipboard sync
- Add POST /api/browser-sessions/{id}/autofill-login for manual credential fill
- Add DELETE /api/browser-sessions/profiles/{custom_page_id} for login clear
- Add balance tracking with configurable divisor (balance_divisor)
- Health check on session reuse, idle TTL eviction, background cleanup
- Add first-frame watchdog (10s timeout) to prevent infinite loading
- Reconnect browser on active=true when session was closed
- UI: uniform text-only inline buttons (websites + upstreams pages)
- Fix page switch race with closingRemoteSessionPromise
This commit is contained in:
@@ -29,6 +29,9 @@ class UpstreamCreate(BaseModel):
|
||||
enabled: bool = True
|
||||
check_interval_seconds: int = 600
|
||||
timeout_seconds: int = 30
|
||||
balance_endpoint: str = ""
|
||||
balance_response_path: str = ""
|
||||
balance_divisor: float = 1.0
|
||||
|
||||
|
||||
class UpstreamUpdate(BaseModel):
|
||||
@@ -42,6 +45,9 @@ class UpstreamUpdate(BaseModel):
|
||||
enabled: Optional[bool] = None
|
||||
check_interval_seconds: Optional[int] = None
|
||||
timeout_seconds: Optional[int] = None
|
||||
balance_endpoint: Optional[str] = None
|
||||
balance_response_path: Optional[str] = None
|
||||
balance_divisor: Optional[float] = None
|
||||
|
||||
|
||||
class UpstreamResponse(BaseModel):
|
||||
@@ -59,6 +65,11 @@ class UpstreamResponse(BaseModel):
|
||||
last_status: str
|
||||
last_checked_at: Optional[datetime]
|
||||
last_error: Optional[str]
|
||||
balance: Optional[float] = None
|
||||
balance_updated_at: Optional[datetime] = None
|
||||
balance_endpoint: str = ""
|
||||
balance_response_path: str = ""
|
||||
balance_divisor: float = 1.0
|
||||
created_at: datetime
|
||||
updated_at: datetime
|
||||
|
||||
|
||||
Reference in New Issue
Block a user