Errors

The Quin Local API error envelope, HTTP status codes, error codes by area, and how the Python and JavaScript SDKs map them to exceptions.

Local APIÁp dụng cho Quin Camoufox 0.7Cập nhật 2 tháng 11, 2026

Trang này chưa có bản tiếng Việt. Nội dung tiếng Anh được hiển thị bên dưới.

Every refused or failed request returns a JSON error envelope with an HTTP status. Codes are stable strings meant for scripts; messages are for people and may change.

JSON
{"error": {"code": "insufficient_scope", "message": "This token lacks browser:control.",
           "details": {"required": ["browser:control"]}}}

details is null or an object/list with extra information. Browser actions are the exception: a failed action answers 200 with "outcome": "error" (see Browser actions).

HTTP statuses

StatusWhen
200 / 201Success (201 for created resources)
202Accepted as a job ("wait": false on open/close)
400Invalid input recognised by Quin (invalid_request, invalid_profile_id, …)
401Missing or invalid token
403Token valid but not allowed (scope, account, entitlement, web origin)
404Unknown resource
409Conflict with the current state (busy, not running, not published…)
411A Transfer-Encoding header was sent
413Body larger than 1 MB
421Foreign Host header
422The body or query does not match the schema
429Rate limited; honour Retry-After
500Unexpected error (internal_error)
504Waiting for a browser to open or close timed out

Request and transport

StatusCodeMeaning / what to do
421bad_hostCall http://127.0.0.1:<port>/ or localhost:<port>
403origin_forbiddenThe request carried an Origin header or cross-site fetch metadata, or was an OPTIONS preflight. Browsers and web pages cannot use the API
411length_requiredSend Content-Length, not chunked or other transfer encodings
413body_too_largeKeep bodies under 1 MB
400invalid_idempotency_keyIdempotency-Key longer than 100 characters
422invalid_requestSchema validation failed; details lists up to 10 {loc, msg} entries
429rate_limitedOver 30 requests/s for this token (burst 60); Retry-After: 1
429too_many_failures10 failed authentications within a minute; Retry-After: 60
500internal_errorThe message names the exception type only

Authentication and account

StatusCodeMeaning
401auth_requiredNo Authorization: Bearer header
401invalid_tokenUnknown, malformed or wrong token
401token_expiredPast its expiry
401token_revokedRevoked in Settings
403insufficient_scopedetails.required lists the missing scopes
403sign_in_requiredNobody is signed in to Quin
403account_mismatchAnother Quin account is signed in
403account_not_activeAccount suspended, banned, deleted or expired, or device revoked
403local_api_disabledLocal API turned off for the account by its administrator
403rpa_disabledRPA Plus turned off for the account
403local_mode_disabledLocal profiles turned off for the account (create/clone)

Profiles, proxies and Quin Cloud

StatusCodeMeaning
400invalid_profile_idNot an 8-character local id or a Cloud UUID
404profile_not_on_this_computerA Cloud profile without a copy here (open it first)
409not_cloud_profileRevisions, sync status and sync are for Quin Cloud profiles only
404proxy_not_foundUnknown proxy id
409writer_busyThe Cloud profile is open on another computer
409cloud_unavailableQuin Cloud is not available

Other Quin errors (proxy, runtime, Trash, Quin Cloud) pass through with Quin's own code and status, for example proxy_unavailable, runtime_incompatible or lease_lost.

Browsers

StatusCodeMeaning
404session_not_foundUnknown or long-ended session id
409session_busyAnother holder controls the browser; details.controlled_by is api or rpa. Wait, or take over
409taken_overYour action was cancelled by a takeover or a close
409launch_failedThe browser did not start; details.state, details.cause
504launch_timeoutNot ready within timeout_s
504close_timeoutDid not finish closing in time
400invalid_windowwindow needs width 200–7680 and height 200–4320
404file_not_foundGET /files/{path}: no such file in the workspace

Jobs and RPA

StatusCodeMeaning
404job_not_found, task_not_foundUnknown id
400no_targetsThe workflow uses the browser; give profiles, a group or a filter
409not_publishedPublish the workflow first
409workflow_disabledThe workflow is disabled
422workflow_invalidThe workflow graph has problems (details.issues)
409not_waitingThe run is not waiting for that signal

Runs and jobs record their own error codes, for example interrupted (Quin stopped during the run; state RECOVERY_REQUIRED), profile_not_saved (steps finished but a Quin Cloud profile was not saved) and lease_lost.

SDK exceptions

Both SDKs raise a QuinError subclass carrying code, message, status and details.

ClassRaised for
AuthError401, or no token configured
PermissionDenied403
NotFound404
Conflict / SessionBusy409 / 409 session_busy
InvalidRequest400, 413, 422
RateLimited429 after retries; retry_after (Python) / retryAfter (JS) in seconds
ServerError5xx
ActionErrorAn action with outcome: "error"; adds action, action_id / actionId, duration_ms / durationMs
QuinTimeoutrequest_timeout (HTTP) or wait_timeout (a job, task or session wait)
ApiUnavailableapi_unavailable: Quin not running, API off, or discovery file missing
Python
from quin_camoufox import ActionError, PermissionDenied, SessionBusy

try:
    session.click("#submit")
except SessionBusy as e:
    print("busy, controlled by", e.details["controlled_by"])
except ActionError as e:
    print(e.action, e.code, e.message)
except PermissionDenied as e:
    print("missing scopes:", (e.details or {}).get("required"))