{"openapi":"3.1.0","info":{"title":"NEMESIS API","description":"Start checks of AI model providers, follow them, and read the results.\n\n**Authentication.** Create a key on the *API keys* page of your account, then\nsend it as `Authorization: Bearer nmk_…`. Keys carry scopes\n(`checks:read`, `checks:write`, `providers:read`). Account and key management\nis only available from a signed-in browser, never with a key.\n\n**Errors** are `{\"error\": {\"code\", \"message\", \"request_id\"}}`.\n**Rate limits** are reported in `RateLimit-*` headers; starting a check also\nconsumes the account's run quota (`GET /api/v1/usage`).\n\n**Stability.** Within v1, fields and endpoints are only added, never renamed\nor removed.","version":"1.0.0"},"paths":{"/api/v1/auth/scopes":{"get":{"tags":["account"],"summary":"List the scopes an API key can hold","operationId":"list_scopes_api_v1_auth_scopes_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScopeList"}}}}}}},"/api/v1/auth/register":{"post":{"tags":["account"],"summary":"Create an account and sign in","description":"Creates an account and sets the session cookie.\n\nRate limited per network. The answer to an email that is already registered\nis a 409: without a mail service there is no way to hide that fact behind\n\"check your inbox\", so it is said plainly and the rate limit carries the\nweight of slowing enumeration.","operationId":"register_api_v1_auth_register_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Credentials"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountOut"}}}},"409":{"description":"An account with this email exists","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/v1/auth/login":{"post":{"tags":["account"],"summary":"Sign in","description":"Checks the password and sets the session cookie.\n\nOne answer for a wrong password and an unknown email, in the same time:\nan unknown email still costs one scrypt verification.","operationId":"login_api_v1_auth_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Credentials"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountOut"}}}},"401":{"description":"Wrong email or password","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/v1/auth/logout":{"post":{"tags":["account"],"summary":"Sign out this browser","operationId":"logout_api_v1_auth_logout_post","responses":{"204":{"description":"Successful Response"}}}},"/api/v1/auth/session":{"get":{"tags":["account"],"summary":"Whether this browser is signed in","description":"Always 200, so a page can ask without logging a failed request.","operationId":"session_status_api_v1_auth_session_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SessionStatus"}}}}}}},"/api/v1/account":{"get":{"tags":["account"],"summary":"The account making this request","description":"Works with a session or with any API key, so a script can verify its key.","operationId":"get_account_api_v1_account_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountOut"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"apiKey":[]},{"session":[]}],"x-required-scopes":[]},"delete":{"tags":["account"],"summary":"Delete the account","description":"Deletes the account, its sessions and its keys.\n\nChecks it started stay published under their existing links, detached from\nthe account: a measurement is a record, not a possession, and the product\ndoes not delete records silently.","operationId":"delete_account_api_v1_account_delete","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordConfirmation"}}},"required":true},"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true}},"/api/v1/account/password":{"post":{"tags":["account"],"summary":"Change the password","description":"Signs out every other browser. API keys are not affected.","operationId":"change_password_api_v1_account_password_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordChange"}}},"required":true},"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true}},"/api/v1/account/sessions":{"get":{"tags":["account"],"summary":"Browsers signed in to this account","operationId":"list_sessions_api_v1_account_sessions_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SessionList"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true}},"/api/v1/account/sessions/{session_id}":{"delete":{"tags":["account"],"summary":"Sign out one browser","operationId":"revoke_session_api_v1_account_sessions__session_id__delete","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","title":"Session Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true}},"/api/v1/account/sessions/revoke-others":{"post":{"tags":["account"],"summary":"Sign out every other browser","operationId":"revoke_other_sessions_api_v1_account_sessions_revoke_others_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":{"type":"integer"},"type":"object","title":"Response Revoke Other Sessions Api V1 Account Sessions Revoke Others Post"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true}},"/api/v1/keys":{"get":{"tags":["api keys"],"summary":"List this account's API keys","description":"Active keys first, then expired and revoked ones, newest first within each.","operationId":"list_keys_api_v1_keys_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeyList"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true},"post":{"tags":["api keys"],"summary":"Create an API key","description":"Returns the key once, in ``secret``. Store it now: it cannot be shown again.","operationId":"create_key_api_v1_keys_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeyCreate"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeyCreated"}}}},"409":{"description":"The account already holds the maximum number of keys","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true}},"/api/v1/keys/{key_id}":{"delete":{"tags":["api keys"],"summary":"Revoke an API key","description":"Takes effect on the key's next request. The key stays listed as revoked,\nso checks it started remain attributable.","operationId":"revoke_key_api_v1_keys__key_id__delete","parameters":[{"name":"key_id","in":"path","required":true,"schema":{"type":"string","title":"Key Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true}},"/api/v1/integrations":{"get":{"tags":["reference"],"summary":"Reference APIs a key can be saved for","description":"No authentication. OpenRouter is marked ``recommended``: it is the one\nprovider that shows a key its own credit limit, so it is the one where a\nlimit can be enforced rather than asked for.","operationId":"list_integrations_api_v1_integrations_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntegrationList"}}}}}}},"/api/v1/catalog/openrouter":{"get":{"tags":["reference"],"summary":"OpenRouter models a reference can be","description":"No authentication. Text models only, without routers and moving\naliases. Prices are USD per million tokens.","operationId":"get_openrouter_catalog_api_v1_catalog_openrouter_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Catalog"}}}}}}},"/api/v1/provider-keys":{"get":{"tags":["reference"],"summary":"Provider keys saved in this account","description":"Never returns a key: only its hint and the limit last reported.","operationId":"list_provider_keys_api_v1_provider_keys_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProviderKeyList"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true}},"/api/v1/provider-keys/{provider}":{"put":{"tags":["reference"],"summary":"Save or replace the key for one integration","description":"Checks the key with the provider first. An OpenRouter key without a\ncredit limit, or with less than ``min_remaining_usd`` left on it, is\nrefused, as are management and expired keys.","operationId":"save_provider_key_api_v1_provider_keys__provider__put","parameters":[{"name":"provider","in":"path","required":true,"schema":{"type":"string","title":"Provider"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProviderKeySave"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProviderKeyOut"}}}},"422":{"description":"The key was refused; `code` says why","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"The provider did not answer","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true},"delete":{"tags":["reference"],"summary":"Delete a saved provider key","description":"The row and its ciphertext are deleted outright. Runs it paid for keep\nthe integration's name and nothing else.","operationId":"delete_provider_key_api_v1_provider_keys__provider__delete","parameters":[{"name":"provider","in":"path","required":true,"schema":{"type":"string","title":"Provider"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true}},"/api/v1/provider-keys/{provider}/refresh":{"post":{"tags":["reference"],"summary":"Ask the provider for the key's current limit","description":"Updates what the account page shows. A key that has since lost its limit\nstays saved but is refused when a check tries to use it.","operationId":"refresh_provider_key_api_v1_provider_keys__provider__refresh_post","parameters":[{"name":"provider","in":"path","required":true,"schema":{"type":"string","title":"Provider"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProviderKeyOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true}},"/api/v1/provider-keys/{provider}/models":{"get":{"tags":["reference"],"summary":"Models the saved key can reach","description":"For OpenRouter use ``/catalog/openrouter`` instead: the list is the same\nfor every key. Empty with ``error`` when the provider cannot list models;\nthe form then takes a typed model id.","operationId":"provider_key_models_api_v1_provider_keys__provider__models_get","parameters":[{"name":"provider","in":"path","required":true,"schema":{"type":"string","title":"Provider"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Provider Key Models Api V1 Provider Keys  Provider  Models Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"session":[]}],"x-session-only":true}},"/api/v1/checks":{"post":{"tags":["checks"],"summary":"Start a check","description":"Admits the check and queues it.\n\nBefore anything is spent, both providers are tested with a catalogue read\nand an eight-token completion on your own keys; a key or model they refuse\nis a 400 here rather than a failed check later. Then the quota is applied.\nPoll ``GET /checks/{id}`` (every 10–30 s is plenty) or stream\n``/checks/{id}/events`` until ``status`` is ``complete``, ``failed`` or\n``cancelled``.","operationId":"create_check_api_v1_checks_post","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"description":"Any unique string. Retrying with the same key and body returns the original check instead of starting another; the key is remembered for 24 hours.","title":"Idempotency-Key"},"description":"Any unique string. Retrying with the same key and body returns the original check instead of starting another; the key is remembered for 24 hours."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckCreate"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckOut"}}}},"400":{"description":"provider_rejected — a provider refused the key, model or request. `error.side` says which provider and `error.reason` why.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"idempotency_in_progress — the same Idempotency-Key is still being processed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"validation_error, or idempotency_key_reused with a different body","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"quota_exceeded, budget_paused or rate_limited. `Retry-After` says how many seconds until a retry can work.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"provider_unreachable — a provider could not be reached. `error.side` and `error.reason` say which and why.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"apiKey":[]},{"session":[]},{}],"x-required-scopes":["checks:write"]},"get":{"tags":["checks"],"summary":"List this account's checks","description":"Newest first, from the web and the API alike. Only your own checks:\nthere is no endpoint that lists anyone else's.\n\nWith an API key that means the account's checks. In a browser it also\nincludes the checks that browser started before anyone signed in, and for\na visitor with no account it is those alone.","operationId":"list_checks_api_v1_checks_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Limit"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Cursor"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"enum":["queued","running","complete","failed","cancelled"],"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"model","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Model"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckList"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"apiKey":[]},{"session":[]},{}],"x-required-scopes":["checks:read"]}},"/api/v1/checks/{check_id}":{"get":{"tags":["checks"],"summary":"Get a check and its result","description":"Your own checks in full. Anyone else's only if its link is open to\neveryone (public or private, not moderated), with the public projection\nof the evidence — exactly what the web page shows a visitor.\n\nWith ``wait`` the call returns when the check reaches ``complete``,\n``failed`` or ``cancelled``, or when the time is up with whatever state it\nis in; look at ``status`` to tell which.","operationId":"get_check_api_v1_checks__check_id__get","parameters":[{"name":"check_id","in":"path","required":true,"schema":{"type":"string","title":"Check Id"}},{"name":"wait","in":"query","required":false,"schema":{"type":"integer","maximum":60,"minimum":0,"description":"Hold the request open for up to this many seconds while the check is still queued or running, and answer as soon as it ends. 0 (the default) answers at once. Meant for CI: one call per minute instead of a poll every few seconds.","default":0,"title":"Wait"},"description":"Hold the request open for up to this many seconds while the check is still queued or running, and answer as soon as it ends. 0 (the default) answers at once. Meant for CI: one call per minute instead of a poll every few seconds."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckOut"}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"apiKey":[]},{"session":[]},{}],"x-required-scopes":["checks:read"]}},"/api/v1/checks/{check_id}/events":{"get":{"tags":["checks"],"summary":"Stream a check's progress (Server-Sent Events)","description":"``text/event-stream``. Frames already sent are replayed first, then live\nones follow; the stream ends after the terminal frame (``type`` is\n``run.complete``, ``run.failed`` or ``run.cancelled``). Each frame is JSON\nwith ``seq``, ``type``, ``stage`` and ``message``, and carries the same\nnumber as its SSE ``id:``, so a client that reconnects with ``Last-Event-ID``\n(or ``?last_event_id=``) receives exactly the frames it missed. A comment\nline (``: ping``) arrives every 15 seconds while nothing else does.\nBrowser ``EventSource`` cannot send an Authorization header; use a\nfetch-based client, or the session cookie from our own pages.","operationId":"check_events_api_v1_checks__check_id__events_get","parameters":[{"name":"check_id","in":"path","required":true,"schema":{"type":"string","title":"Check Id"}}],"responses":{"200":{"description":"Successful Response","content":{"text/event-stream":{}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"apiKey":[]},{"session":[]},{}],"x-required-scopes":["checks:read"]}},"/api/v1/checks/{check_id}/cancel":{"post":{"tags":["checks"],"summary":"Cancel a queued check","description":"Only a check that has not started yet can be cancelled: once a worker\npicks it up it holds your key in memory and runs to the end. Cancelling\ndeletes the sealed keys at once and returns the quota unit to nobody — it\nwas spent on admission.","operationId":"cancel_check_api_v1_checks__check_id__cancel_post","parameters":[{"name":"check_id","in":"path","required":true,"schema":{"type":"string","title":"Check Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CancelOut"}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"check_running or check_finished","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"apiKey":[]},{"session":[]}],"x-required-scopes":["checks:write"]}},"/api/v1/preflight":{"post":{"tags":["checks"],"summary":"Test provider connections without starting a check","description":"The test ``POST /checks`` runs first, on its own: a catalogue read and\nan eight-token completion per side, on your keys. Always 200 — read\n``candidate.ok`` and ``candidate.code``.","operationId":"preflight_api_v1_preflight_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Preflight"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreflightResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"apiKey":[]},{"session":[]},{}],"x-required-scopes":["checks:write"]}},"/api/v1/usage":{"get":{"tags":["account"],"summary":"Run quota and request allowance left","operationId":"usage_api_v1_usage_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Usage"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"apiKey":[]},{"session":[]}],"x-required-scopes":[]}},"/api/v1/providers/lookup":{"post":{"tags":["providers"],"summary":"The public record for an exact provider URL","description":"Exact match only, the same answer as the web lookup. There is no search,\nprefix match or listing, by design.","operationId":"lookup_provider_api_v1_providers_lookup_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LookupBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProviderRecord"}}}},"404":{"description":"not_found — nothing public recorded for that URL","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"unauthenticated, invalid_api_key, api_key_revoked, api_key_expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"insufficient_scope, session_required, cross_site_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"rate_limited — `Retry-After` and `RateLimit-*` say when to retry","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"apiKey":[]},{"session":[]},{}],"x-required-scopes":["providers:read"]}},"/api/v1/tiers":{"get":{"tags":["reference"],"summary":"What each depth tier costs","description":"No authentication. Token figures are per side, with an error bar.","operationId":"tiers_api_v1_tiers_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/TierCost"},"type":"array","title":"Response Tiers Api V1 Tiers Get"}}}}}}},"/api/v1/errors":{"get":{"tags":["reference"],"summary":"Every error code and failure code","description":"No authentication. The same list the developer documentation prints.","operationId":"errors_catalogue_api_v1_errors_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorCatalogue"}}}}}}}},"components":{"schemas":{"AccountOut":{"properties":{"id":{"type":"string","title":"Id"},"email":{"type":"string","title":"Email"},"plan":{"type":"string","title":"Plan"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"quotas":{"$ref":"#/components/schemas/Quotas"},"authenticated_via":{"type":"string","enum":["session","api_key"],"title":"Authenticated Via"},"api_key":{"anyOf":[{"$ref":"#/components/schemas/ApiKeyOut"},{"type":"null"}]}},"type":"object","required":["id","email","plan","created_at","quotas","authenticated_via"],"title":"AccountOut"},"ApiKeyCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","examples":["CI pipeline"]},"scopes":{"items":{"type":"string"},"type":"array","title":"Scopes","description":"Any of: checks:read, checks:write, providers:read, provider-keys:use."},"expires_in_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":1.0},{"type":"null"}],"title":"Expires In Days","description":"Omit for a key that does not expire."}},"type":"object","required":["name"],"title":"ApiKeyCreate"},"ApiKeyCreated":{"properties":{"key":{"$ref":"#/components/schemas/ApiKeyOut"},"secret":{"type":"string","title":"Secret","description":"The API key. Shown in this response only — it is not stored and cannot be retrieved again."}},"type":"object","required":["key","secret"],"title":"ApiKeyCreated"},"ApiKeyList":{"properties":{"data":{"items":{"$ref":"#/components/schemas/ApiKeyOut"},"type":"array","title":"Data"},"limit":{"type":"integer","title":"Limit","description":"How many active keys an account may hold."}},"type":"object","required":["data","limit"],"title":"ApiKeyList"},"ApiKeyOut":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"prefix":{"type":"string","title":"Prefix","description":"The public part of the key. Safe to show and to log; it identifies the key but cannot be used to authenticate."},"scopes":{"items":{"type":"string"},"type":"array","title":"Scopes"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At"},"status":{"type":"string","enum":["active","expired","revoked"],"title":"Status"}},"type":"object","required":["id","name","prefix","scopes","created_at","last_used_at","expires_at","revoked_at","status"],"title":"ApiKeyOut"},"CancelOut":{"properties":{"id":{"type":"string","title":"Id"},"status":{"type":"string","const":"cancelled","title":"Status"}},"type":"object","required":["id","status"],"title":"CancelOut"},"Catalog":{"properties":{"data":{"items":{"$ref":"#/components/schemas/CatalogModel"},"type":"array","title":"Data"},"fetched_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fetched At"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"}},"type":"object","required":["data","fetched_at"],"title":"Catalog"},"CatalogModel":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"vendor":{"type":"string","title":"Vendor"},"author":{"type":"string","title":"Author"},"context_length":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Length"},"prompt_usd_per_mtok":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Prompt Usd Per Mtok"},"completion_usd_per_mtok":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Completion Usd Per Mtok"},"vision":{"type":"boolean","title":"Vision"},"reasoning":{"type":"boolean","title":"Reasoning"},"logprobs":{"type":"boolean","title":"Logprobs"},"free":{"type":"boolean","title":"Free"},"created":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Created"}},"type":"object","required":["id","name","vendor","author","context_length","prompt_usd_per_mtok","completion_usd_per_mtok","vision","reasoning","logprobs","free","created"],"title":"CatalogModel"},"CheckCreate":{"properties":{"endpoint":{"type":"string","title":"Endpoint","description":"Base URL of the provider being checked."},"api_key":{"type":"string","maxLength":512,"minLength":8,"title":"Api Key","description":"Your key for that provider."},"model":{"type":"string","maxLength":255,"minLength":1,"title":"Model","description":"The model it claims to serve."},"reference_source":{"type":"string","enum":["own","house"],"title":"Reference Source","description":"Always own: the reference is reached with your key. The house reference was retired.","default":"own"},"reference_endpoint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Endpoint","description":"Base URL of the reference, e.g. https://openrouter.ai/api/v1. Required unless reference_saved_key is given."},"reference_api_key":{"anyOf":[{"type":"string","maxLength":512,"minLength":8},{"type":"null"}],"title":"Reference Api Key"},"reference_saved_key":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Reference Saved Key","description":"Use the reference key this account saved for an integration (see GET /integrations). Needs the provider-keys:use scope."},"reference_model":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Reference Model","description":"The model to compare against. Resolved from `model` against the reference's own catalogue when omitted."},"tier":{"type":"string","enum":["base","deep"],"title":"Tier","default":"base"},"visibility":{"type":"string","enum":["public","private"],"title":"Visibility","description":"public results join the provider's public record; private ones open only by direct link and are never listed.","default":"public"}},"additionalProperties":false,"type":"object","required":["endpoint","api_key","model"],"title":"CheckCreate","description":"Start a check: the provider you doubt, and what to compare it against.\n\nThe fields and their rules are those of the web form. ``api_key`` (and\n``reference_api_key``) are sealed for the worker, held only while the check\nruns, then deleted; they are never stored or returned.","examples":[{"api_key":"sk-your-provider-key","endpoint":"https://api.provider.example/v1","model":"claude-opus-4-8","reference_model":"anthropic/claude-opus-4.8","reference_saved_key":"openrouter","tier":"base","visibility":"private"}]},"CheckFailure":{"properties":{"code":{"type":"string","enum":["provider_key_rejected","provider_out_of_credit","provider_rate_limited","provider_model_not_found","provider_unavailable","reference_model_not_found","reference_spend_guard","key_expired","reference_unavailable","internal_error","unclassified"],"title":"Code","description":"One of the values listed at `GET /api/v1/errors` under `failure_codes`. New codes may be added; treat an unknown one like `internal_error`."},"retryable":{"type":"boolean","title":"Retryable","description":"Whether starting the same check again, unchanged, may succeed."}},"type":"object","required":["code","retryable"],"title":"CheckFailure","description":"Why a check failed. Branch on ``code``, never on ``error``."},"CheckLinks":{"properties":{"self":{"type":"string","title":"Self"},"events":{"type":"string","title":"Events"},"web":{"type":"string","title":"Web","description":"The result page."},"report":{"type":"string","title":"Report","description":"The printable report."},"certificate":{"type":"string","title":"Certificate","description":"A shareable PNG card."}},"type":"object","required":["self","events","web","report","certificate"],"title":"CheckLinks"},"CheckList":{"properties":{"data":{"items":{"$ref":"#/components/schemas/CheckSummary"},"type":"array","title":"Data"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor","description":"Pass as `cursor` for the next page; null on the last page."}},"type":"object","required":["data","next_cursor"],"title":"CheckList"},"CheckOut":{"properties":{"id":{"type":"string","title":"Id"},"status":{"type":"string","enum":["queued","running","complete","failed","cancelled"],"title":"Status"},"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage"},"tier":{"type":"string","enum":["base","deep"],"title":"Tier"},"visibility":{"type":"string","enum":["public","private","under_review","hidden","removed"],"title":"Visibility"},"reference_source":{"type":"string","enum":["own","house"],"title":"Reference Source"},"reference_integration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Integration","description":"The known API the reference was reached at (openrouter, openai, ...), or null for another address."},"endpoint":{"type":"string","title":"Endpoint"},"reference_endpoint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Endpoint","description":"Only shown to the account that started the check."},"reference_provider_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Provider Hash","description":"Salted hash of the reference address: the same reference yields the same value, without naming it."},"ssrf_exempted":{"type":"boolean","title":"Ssrf Exempted","description":"True for a fixture run made against a local test provider. Such a check is never indexed or published in a provider's record.","default":false},"reference_cache":{"anyOf":[{"$ref":"#/components/schemas/ReferenceCache"},{"type":"null"}]},"model":{"type":"string","title":"Model"},"reference_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Model"},"provider_hash":{"type":"string","title":"Provider Hash"},"probe_suite_version":{"type":"string","title":"Probe Suite Version"},"formula_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Formula Version"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"RFC 3339 date-time, with a UTC offset."},"finished_at":{"anyOf":[{"type":"string","format":"date-time","description":"RFC 3339 date-time, with a UTC offset."},{"type":"null"}],"title":"Finished At"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Diagnostic text for a person. Not stable: do not parse it. Use `failure`."},"failure":{"anyOf":[{"$ref":"#/components/schemas/CheckFailure"},{"type":"null"}],"description":"Set exactly when `status` is `failed`."},"owned":{"type":"boolean","title":"Owned","description":"True when the caller started this check: the account, or for a browser with no account, that browser."},"result":{"anyOf":[{"$ref":"#/components/schemas/CheckResult"},{"type":"null"}],"description":"Present exactly when `status` is `complete` — even if the check produced no score, in which case `result.trust` is null. Null for every other status."},"links":{"$ref":"#/components/schemas/CheckLinks"},"estimate":{"anyOf":[{"$ref":"#/components/schemas/Estimate"},{"type":"null"}],"description":"Only in the response that created the check."},"queue":{"anyOf":[{"$ref":"#/components/schemas/CheckQueue"},{"type":"null"}],"description":"Present while the check is waiting to start."},"partial":{"anyOf":[{"$ref":"#/components/schemas/CheckPartial"},{"type":"null"}],"description":"For a check that failed after measuring part of it: how many probes finished. No result or score is computed from a partial run."}},"type":"object","required":["id","status","stage","tier","visibility","reference_source","endpoint","model","reference_model","provider_hash","probe_suite_version","formula_version","created_at","finished_at","error","owned","result","links"],"title":"CheckOut"},"CheckPartial":{"properties":{"probes_measured":{"type":"integer","title":"Probes Measured"},"probes_total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Probes Total"}},"type":"object","required":["probes_measured"],"title":"CheckPartial"},"CheckQueue":{"properties":{"position":{"type":"integer","title":"Position","description":"1 is next to start."},"estimated_wait_seconds":{"type":"integer","title":"Estimated Wait Seconds","description":"About how long until it starts, from recent runs."}},"type":"object","required":["position","estimated_wait_seconds"],"title":"CheckQueue"},"CheckResult":{"properties":{"trust":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Trust","description":"0–100, higher is better. Null when the check completed without producing a score."},"trust_ci":{"anyOf":[{"items":{"type":"number"},"type":"array"},{"type":"null"}],"title":"Trust Ci","description":"Confidence interval for trust."},"dimensions":{"anyOf":[{"additionalProperties":{"anyOf":[{"type":"number"},{"type":"null"}]},"type":"object"},{"type":"null"}],"title":"Dimensions"},"applied_ceilings":{"items":{"type":"string"},"type":"array","title":"Applied Ceilings"},"measurement_incomplete":{"type":"boolean","title":"Measurement Incomplete","description":"True when enough measurements failed that the score rests on a thin base. Read this before the score."},"measured_fraction":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Measured Fraction"},"signals":{"items":{"$ref":"#/components/schemas/Signal"},"type":"array","title":"Signals"},"judgement":{"anyOf":[{"$ref":"#/components/schemas/Judgement"},{"type":"null"}]}},"type":"object","required":["trust","trust_ci","dimensions","applied_ceilings","measurement_incomplete","measured_fraction","signals","judgement"],"title":"CheckResult"},"CheckSummary":{"properties":{"id":{"type":"string","title":"Id"},"status":{"type":"string","enum":["queued","running","complete","failed","cancelled"],"title":"Status"},"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage"},"tier":{"type":"string","enum":["base","deep"],"title":"Tier"},"visibility":{"type":"string","enum":["public","private","under_review","hidden","removed"],"title":"Visibility"},"reference_source":{"type":"string","enum":["own","house"],"title":"Reference Source"},"endpoint":{"type":"string","title":"Endpoint"},"model":{"type":"string","title":"Model"},"reference_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Model"},"trust":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Trust"},"trust_ci":{"anyOf":[{"items":{"type":"number"},"type":"array"},{"type":"null"}],"title":"Trust Ci"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"RFC 3339 date-time, with a UTC offset."},"finished_at":{"anyOf":[{"type":"string","format":"date-time","description":"RFC 3339 date-time, with a UTC offset."},{"type":"null"}],"title":"Finished At"},"created_via":{"type":"string","enum":["api","web"],"title":"Created Via"},"links":{"$ref":"#/components/schemas/CheckLinks"}},"type":"object","required":["id","status","stage","tier","visibility","reference_source","endpoint","model","reference_model","trust","trust_ci","created_at","finished_at","created_via","links"],"title":"CheckSummary"},"Credentials":{"properties":{"email":{"type":"string","maxLength":320,"minLength":3,"title":"Email","examples":["you@example.com"]},"password":{"type":"string","maxLength":512,"minLength":1,"title":"Password"}},"type":"object","required":["email","password"],"title":"Credentials"},"ErrorCatalogue":{"properties":{"errors":{"items":{"$ref":"#/components/schemas/ErrorCodeOut"},"type":"array","title":"Errors","description":"Every `error.code` the API answers with."},"failure_codes":{"items":{"$ref":"#/components/schemas/FailureCodeOut"},"type":"array","title":"Failure Codes","description":"Every value of `failure.code` on a failed check."}},"type":"object","required":["errors","failure_codes"],"title":"ErrorCatalogue"},"ErrorCodeOut":{"properties":{"code":{"type":"string","title":"Code"},"status":{"type":"integer","title":"Status"},"retryable":{"type":"boolean","title":"Retryable","description":"Whether the same request may succeed if sent again later."},"summary":{"type":"string","title":"Summary"}},"type":"object","required":["code","status","retryable","summary"],"title":"ErrorCodeOut"},"Estimate":{"properties":{"calls":{"type":"integer","title":"Calls"},"seconds":{"type":"integer","title":"Seconds"},"tokens_candidate":{"type":"integer","title":"Tokens Candidate"},"tokens_reference":{"type":"integer","title":"Tokens Reference"},"tokens_spread":{"type":"number","title":"Tokens Spread","description":"Either token figure may be off by this fraction."}},"type":"object","required":["calls","seconds","tokens_candidate","tokens_reference","tokens_spread"],"title":"Estimate"},"FailureCodeOut":{"properties":{"code":{"type":"string","enum":["provider_key_rejected","provider_out_of_credit","provider_rate_limited","provider_model_not_found","provider_unavailable","reference_model_not_found","reference_spend_guard","key_expired","reference_unavailable","internal_error","unclassified"],"title":"Code"},"retryable":{"type":"boolean","title":"Retryable"},"summary":{"type":"string","title":"Summary"}},"type":"object","required":["code","retryable","summary"],"title":"FailureCodeOut"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"IntegrationList":{"properties":{"data":{"items":{"$ref":"#/components/schemas/IntegrationOut"},"type":"array","title":"Data"},"min_remaining_usd":{"type":"number","title":"Min Remaining Usd","description":"A key whose provider reports its limit needs at least this much left to be saved."},"run_min_remaining_usd":{"type":"number","title":"Run Min Remaining Usd","description":"And at least this much left when a check starts."}},"type":"object","required":["data","min_remaining_usd","run_min_remaining_usd"],"title":"IntegrationList"},"IntegrationOut":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"base_url":{"type":"string","title":"Base Url"},"limit_check":{"type":"string","enum":["key_limit","balance","none"],"title":"Limit Check"},"recommended":{"type":"boolean","title":"Recommended"},"keys_url":{"type":"string","title":"Keys Url"},"limits_url":{"type":"string","title":"Limits Url"},"icon":{"type":"string","title":"Icon"},"key_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key Prefix"}},"type":"object","required":["id","name","base_url","limit_check","recommended","keys_url","limits_url","icon","key_prefix"],"title":"IntegrationOut"},"Judgement":{"properties":{"model":{"type":"string","title":"Model"},"winner":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Winner"},"swap_consistent":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Swap Consistent"},"narrative":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Narrative"},"narrative_ru":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Narrative Ru"}},"type":"object","required":["model","winner","swap_consistent"],"title":"Judgement"},"LookupBody":{"properties":{"url":{"type":"string","title":"Url","description":"The exact provider URL. There is no search."}},"additionalProperties":false,"type":"object","required":["url"],"title":"LookupBody"},"ModelRecord":{"properties":{"model":{"type":"string","title":"Model"},"runs":{"type":"integer","title":"Runs"},"eligible_runs":{"type":"integer","title":"Eligible Runs"},"time_separated":{"type":"boolean","title":"Time Separated"},"aggregate_status":{"type":"string","enum":["established","insufficient_measurements"],"title":"Aggregate Status","description":"`established` only when enough checks, from enough different requesters, spread over enough time, back the figure."},"flagged_runs":{"type":"integer","title":"Flagged Runs"},"trust":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Trust"},"trust_ci":{"anyOf":[{"items":{"type":"number"},"type":"array"},{"type":"null"}],"title":"Trust Ci"},"first_eligible_at":{"anyOf":[{"type":"string","format":"date-time","description":"RFC 3339 date-time, with a UTC offset."},{"type":"null"}],"title":"First Eligible At"},"last_run_at":{"type":"string","format":"date-time","title":"Last Run At","description":"RFC 3339 date-time, with a UTC offset."}},"type":"object","required":["model","runs","eligible_runs","time_separated","aggregate_status","flagged_runs","trust","trust_ci","first_eligible_at","last_run_at"],"title":"ModelRecord","description":"One model's public aggregate under a provider."},"PasswordChange":{"properties":{"current_password":{"type":"string","maxLength":512,"minLength":1,"title":"Current Password"},"new_password":{"type":"string","maxLength":512,"minLength":1,"title":"New Password"}},"type":"object","required":["current_password","new_password"],"title":"PasswordChange"},"PasswordConfirmation":{"properties":{"password":{"type":"string","maxLength":512,"minLength":1,"title":"Password"}},"type":"object","required":["password"],"title":"PasswordConfirmation"},"Preflight":{"properties":{"endpoint":{"type":"string","title":"Endpoint"},"api_key":{"type":"string","maxLength":512,"minLength":8,"title":"Api Key"},"model":{"type":"string","maxLength":255,"minLength":1,"title":"Model"},"reference_source":{"type":"string","const":"own","title":"Reference Source","default":"own"},"reference_endpoint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Endpoint"},"reference_api_key":{"anyOf":[{"type":"string","maxLength":512,"minLength":8},{"type":"null"}],"title":"Reference Api Key"},"reference_saved_key":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Reference Saved Key"},"reference_model":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Reference Model"}},"type":"object","required":["endpoint","api_key","model"],"title":"Preflight","description":"A key health-check request.\n\nDeliberately the same field names as CreateRun, so a form can send the\nbody it already has.  The validators are the same too — a URL that would\nbe refused by /api/runs must be refused here, or preflight becomes a\nlighter-guarded route to the same egress."},"PreflightChecks":{"properties":{"input_valid":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Input Valid"},"reachable":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Reachable"},"authenticated":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Authenticated"},"catalogue_parsed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Catalogue Parsed"},"model_listed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Model Listed"},"inference_ok":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Inference Ok"}},"type":"object","title":"PreflightChecks","description":"The individual facts a pre-flight established, one per line of enquiry.\n\nEvery field is tri-state: ``True`` proved, ``False`` disproved, ``None``\n*not determined* — either because an earlier check ended the sequence or\nbecause the provider did not answer the question.  Collapsing \"unknown\"\ninto \"false\" is what turns a diagnostic into a guess, and the whole reason\nthis structure exists is so a form can say \"your key is wrong\" rather than\n\"something is wrong\".\n\n  ``input_valid``      the submitted URL, key and slug are structurally\n                       usable.  Decided with no network at all.\n  ``reachable``        the host resolved, passed the SSRF guard and\n                       completed a request.\n  ``authenticated``    the key was *not rejected*.  ``True`` is deliberately\n                       the weaker claim: some gateways serve ``/models``\n                       without a key, so a 200 there only proves the key was\n                       not refused.  A successful completion upgrades it.\n  ``catalogue_parsed`` ``GET /models`` answered 2xx and at least one model id\n                       could be read out of it.  An empty or unrecognised\n                       body counts as *not* parsed, because a zero-length\n                       list must never be read as \"your model is missing\".\n  ``model_listed``     the requested slug appears in that catalogue.\n                       ``None`` when there is no catalogue to look in.\n                       Never fatal on its own — plenty of providers serve\n                       models they do not advertise — but a typo in the slug\n                       is the single most common cause of a wasted run, so\n                       it is surfaced.\n  ``inference_ok``     a real completion came back.  ``None`` when stage 1\n                       ended the sequence and no tokens were ever spent."},"PreflightResult":{"properties":{"candidate":{"$ref":"#/components/schemas/PreflightSide"},"reference":{"anyOf":[{"$ref":"#/components/schemas/PreflightSide"},{"type":"null"}]}},"type":"object","required":["candidate"],"title":"PreflightResult"},"PreflightSide":{"properties":{"ok":{"type":"boolean","title":"Ok"},"stage":{"type":"string","enum":["input","catalogue","inference"],"title":"Stage","default":"inference"},"code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code"},"status":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Status"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"latency_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Latency Ms"},"checks":{"$ref":"#/components/schemas/PreflightChecks"}},"type":"object","required":["ok"],"title":"PreflightSide","description":"What one provider said when we knocked on the door.\n\n``ok`` is the verdict; ``checks`` is why.  ``stage`` is the furthest point\nreached, and ``code`` is a stable machine-readable reason a UI can branch on\nwithout pattern-matching English error text.  ``latency_ms`` measures the\nstage that produced the verdict — the completion when one was made, the\ncatalogue request when stage 1 ended it."},"ProviderKeyList":{"properties":{"data":{"items":{"$ref":"#/components/schemas/ProviderKeyOut"},"type":"array","title":"Data"}},"type":"object","required":["data"],"title":"ProviderKeyList"},"ProviderKeyOut":{"properties":{"provider":{"type":"string","title":"Provider"},"hint":{"type":"string","title":"Hint"},"limit_verified":{"type":"boolean","title":"Limit Verified"},"limit_usd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Limit Usd"},"remaining_usd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Remaining Usd"},"usage_usd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Usage Usd"},"limit_reset":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Limit Reset"},"details":{"additionalProperties":true,"type":"object","title":"Details"},"checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Checked At"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["provider","hint","limit_verified","limit_usd","remaining_usd","usage_usd","limit_reset","details","checked_at","last_used_at","created_at"],"title":"ProviderKeyOut"},"ProviderKeySave":{"properties":{"key":{"type":"string","maxLength":512,"minLength":8,"title":"Key"},"limit_confirmed":{"type":"boolean","title":"Limit Confirmed","description":"For providers that cannot show a key its own limit: the person confirms they set a budget in the provider's console.","default":false}},"type":"object","required":["key"],"title":"ProviderKeySave"},"ProviderRecord":{"properties":{"provider_hash":{"type":"string","title":"Provider Hash"},"url":{"type":"string","title":"Url"},"origin":{"type":"string","title":"Origin"},"host":{"type":"string","title":"Host"},"first_seen":{"type":"string","format":"date-time","title":"First Seen","description":"RFC 3339 date-time, with a UTC offset."},"last_seen":{"type":"string","format":"date-time","title":"Last Seen","description":"RFC 3339 date-time, with a UTC offset."},"appeal_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Appeal Note"},"models":{"items":{"$ref":"#/components/schemas/ModelRecord"},"type":"array","title":"Models"},"runs":{"items":{"$ref":"#/components/schemas/RecordedCheck"},"type":"array","title":"Runs"}},"type":"object","required":["provider_hash","url","origin","host","first_seen","last_seen","appeal_note","models","runs"],"title":"ProviderRecord"},"QuotaOut":{"properties":{"tier":{"type":"string","enum":["base","deep"],"title":"Tier"},"limit":{"type":"integer","title":"Limit"},"used":{"type":"integer","title":"Used"},"remaining":{"type":"integer","title":"Remaining"},"window":{"type":"string","title":"Window"},"resets_in_seconds":{"type":"integer","title":"Resets In Seconds"}},"type":"object","required":["tier","limit","used","remaining","window","resets_in_seconds"],"title":"QuotaOut"},"Quotas":{"properties":{"base_per_hour":{"type":"integer","title":"Base Per Hour"},"deep_per_day":{"type":"integer","title":"Deep Per Day"}},"type":"object","required":["base_per_hour","deep_per_day"],"title":"Quotas"},"RecordedCheck":{"properties":{"run_id":{"type":"string","title":"Run Id"},"model":{"type":"string","title":"Model"},"reference_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Model"},"tier":{"type":"string","enum":["base","deep"],"title":"Tier"},"reference_source":{"type":"string","enum":["own","house"],"title":"Reference Source"},"reference_integration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Integration"},"trust":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Trust"},"trust_ci":{"anyOf":[{"items":{"type":"number"},"type":"array"},{"type":"null"}],"title":"Trust Ci"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"RFC 3339 date-time, with a UTC offset."},"finished_at":{"anyOf":[{"type":"string","format":"date-time","description":"RFC 3339 date-time, with a UTC offset."},{"type":"null"}],"title":"Finished At"},"findings":{"type":"integer","title":"Findings","description":"Signals with a penalty."},"visibility":{"type":"string","enum":["public","private","under_review","hidden","removed"],"title":"Visibility"}},"type":"object","required":["run_id","model","reference_model","tier","reference_source","reference_integration","trust","trust_ci","created_at","finished_at","findings","visibility"],"title":"RecordedCheck","description":"A public, completed check in a provider's record. ``run_id`` is the id\nthat every other endpoint calls ``id``; the name is kept for v1."},"ReferenceCache":{"properties":{"hits":{"type":"integer","title":"Hits"},"misses":{"type":"integer","title":"Misses"},"calls_saved":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Calls Saved","description":"A lower bound on the provider calls the reuse saved."}},"type":"object","required":["hits","misses","calls_saved"],"title":"ReferenceCache","description":"How much of the reference half was replayed from the shared cache\ninstead of measured live. Null on a check that predates the tracking."},"ScopeList":{"properties":{"data":{"items":{"$ref":"#/components/schemas/ScopeOut"},"type":"array","title":"Data"},"default":{"items":{"type":"string"},"type":"array","title":"Default"}},"type":"object","required":["data","default"],"title":"ScopeList"},"ScopeOut":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"}},"type":"object","required":["name","description"],"title":"ScopeOut"},"SessionList":{"properties":{"data":{"items":{"$ref":"#/components/schemas/SessionOut"},"type":"array","title":"Data"}},"type":"object","required":["data"],"title":"SessionList"},"SessionOut":{"properties":{"id":{"type":"string","title":"Id"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"last_seen_at":{"type":"string","format":"date-time","title":"Last Seen At"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"},"current":{"type":"boolean","title":"Current"}},"type":"object","required":["id","user_agent","created_at","last_seen_at","expires_at","current"],"title":"SessionOut"},"SessionStatus":{"properties":{"signed_in":{"type":"boolean","title":"Signed In"}},"type":"object","required":["signed_in"],"title":"SessionStatus"},"Signal":{"properties":{"key":{"type":"string","title":"Key"},"dimension":{"type":"string","enum":["authenticity","purity","capability","compliance","transparency"],"title":"Dimension"},"grade":{"type":"string","enum":["proven","strong","suspected","inconclusive"],"title":"Grade","description":"How strongly the evidence supports the finding. `inconclusive` means the check could not run, not that the provider is clean."},"summary":{"type":"string","title":"Summary"},"measured":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Measured"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"penalty":{"type":"number","title":"Penalty"},"probe_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Probe Id"},"evidence":{"additionalProperties":true,"type":"object","title":"Evidence","description":"The data behind the finding. Full for the account that started the check; a filtered public projection for anyone else."}},"type":"object","required":["key","dimension","grade","summary","measured","unit","penalty","probe_id"],"title":"Signal"},"TierCost":{"properties":{"id":{"type":"string","title":"Id"},"calls":{"type":"integer","title":"Calls"},"seconds":{"type":"integer","title":"Seconds"},"tokens_candidate":{"type":"integer","title":"Tokens Candidate"},"tokens_reference":{"type":"integer","title":"Tokens Reference"},"tokens_spread":{"type":"number","title":"Tokens Spread","default":0.4}},"type":"object","required":["id","calls","seconds","tokens_candidate","tokens_reference"],"title":"TierCost","description":"One depth tier, priced.  Served by GET /api/tiers."},"Usage":{"properties":{"quotas":{"items":{"$ref":"#/components/schemas/QuotaOut"},"type":"array","title":"Quotas","description":"Run quota per tier. Applies to every check — the reference comparison and the judge both run on our account."},"base_available":{"type":"boolean","title":"Base Available","description":"False while the service-wide daily budget pauses base checks."},"deep_available":{"type":"boolean","title":"Deep Available"},"rate_limit":{"additionalProperties":{"type":"integer"},"type":"object","title":"Rate Limit","description":"This key's request allowance for the current minute."}},"type":"object","required":["quotas","base_available","deep_available","rate_limit"],"title":"Usage"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","description":"Stable and machine-readable. Branch on this. New codes may be added; treat an unknown one by its HTTP status. Every code is listed, with its status and whether a retry can help, at `GET /api/v1/errors`."},"message":{"type":"string"},"request_id":{"type":"string","nullable":true},"details":{"type":"array","items":{"type":"object","properties":{"field":{"type":"string","nullable":true},"message":{"type":"string"}}}},"side":{"type":"string","enum":["candidate","reference"],"description":"On `provider_rejected` and `provider_unreachable`: which provider the pre-flight test failed on."},"reason":{"type":"string","description":"On `provider_rejected` and `provider_unreachable`: why, as `candidate.code` of `POST /preflight` reads (`unauthorized`, `out_of_credit`, `model_rejected`, …)."}}}}}},"securitySchemes":{"apiKey":{"type":"http","scheme":"bearer","bearerFormat":"nmk_<12>_<46>","description":"An API key from your account. Scopes: `checks:read` — Read the status, results, report links and live events of checks this account started.; `checks:write` — Start checks, run pre-flight connection tests and cancel queued checks. Consumes the account's run quota.; `providers:read` — Look up the public record for an exact provider URL.; `provider-keys:use` — Start checks whose reference uses a provider key saved in this account (reference_saved_key). Not granted by default: such a check spends the saved key, up to the limit set on it."},"session":{"type":"apiKey","in":"cookie","name":"nemesis_session","description":"Set by /auth/login. Writes must come from our own pages."}}},"tags":[{"name":"checks","description":"Start, follow and read checks."},{"name":"providers","description":"Exact-URL lookup of public records."},{"name":"reference","description":"Public reference data. No key needed."},{"name":"account","description":"Sign-up, sign-in, sessions and usage."},{"name":"api keys","description":"Create and revoke keys. Browser session only."}]}