{"openapi":"3.1.0","info":{"title":"Fileverity API","version":"1.0.0","description":"Check images, documents and plain text for AI generation, tampering and AI-written passages. Image and document checks return a full report with a report ID, SHA-256 fingerprints, an RFC 3161 timestamp and a public verification page. Text checks return a result with the AI-written passages marked.\n\n## Getting started\n\n- Base URL: `https://api.fileverity.com/v1` (HTTPS only, JSON).\n- Authentication: a bearer API key in the `Authorization` header. Live keys start with `fv_live_`; test keys start with `fv_test_`, return fixed sample results and are never charged.\n- Image check: model `fvimg-2` (FVIMG V2), US$1.99 per image. Upload with `POST /files`, then `POST /analyses`.\n- Document check: model `fvdoc-3` (FVDOC V3), US$5.99 per document. Upload with `POST /files`, then `POST /analyses`.\n- Text check: model `fvdoc-3-text` (FVDOC V3 Text), US$0.14 per 1,000 characters, at least 100 words. One synchronous call to `POST /text/detections`.\n\n## How a check runs\n\nImages and documents take two calls: upload the file with `POST /files`, then create an analysis with `POST /analyses`. An analysis is one image or document check. Send `Prefer: wait=60` to hold the request until the result is ready, poll `GET /analyses/{id}`, or subscribe to the `analysis.completed` and `analysis.failed` webhooks, which are signed as Standard Webhooks. Text takes one synchronous call to `POST /text/detections`.\n\nSend an `Idempotency-Key` on `POST` requests so a retry never runs a check twice. Every response carries an `x-request-id` header, and every error repeats it as `error.request_id`. Quote it when you contact support.\n\n## Billing and data\n\nThe API is prepaid, with no subscription: add funds to your workspace balance from US$19. Your first workspace starts with 5 free image or document checks and 5,000 free text characters. Failed checks are not charged. The balance stays valid for 12 months after your latest top-up, and top-ups are non-refundable except where required by law or stated in your agreement. Uploaded files are deleted when the analysis starts, and at the latest after 24 hours. Text you send is not stored. Results are kept for 7 days.","termsOfService":"https://fileverity.com/en/legal/terms","contact":{"name":"Fileverity support","email":"hello@fileverity.com","url":"https://fileverity.com/en/contact"}},"externalDocs":{"description":"Fileverity API documentation: quickstart, guides and the API reference.","url":"https://fileverity.com/en/docs"},"servers":[{"url":"https://api.fileverity.com/v1"}],"security":[{"apiKey":[]}],"tags":[{"name":"Text","description":"Detect AI-written passages in plain text. One synchronous call."},{"name":"Files","description":"Upload images and documents before you create an analysis."},{"name":"Analyses","description":"Check an uploaded image or document. An analysis is one image or document check."},{"name":"Models","description":"The models you can call, with their limits and prices."}],"paths":{"/files":{"post":{"operationId":"createFile","summary":"Upload a file","description":"Uploads a file for analysis. Send files up to 4 MB as multipart/form-data in the field file; the response has status uploaded. Files larger than 4 MB must be uploaded with a pre-signed URL. Send JSON with filename, content_type and bytes (documents up to 50 MB); the response has status pending and an upload object with a pre-signed URL: send the file bytes to it with PUT and the given headers before it expires. A file is deleted when an analysis starts and at the latest after 24 hours. A workspace can hold up to 50 unexpired files and 200 MB per mode at once.","tags":["Files"],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Unique key of up to 255 characters. Repeating the request with the same key and body within 24 hours returns the first response with the header idempotent-replayed: true; the same key with a different body returns 409.","schema":{"type":"string","maxLength":255}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}},"application/json":{"schema":{"$ref":"#/components/schemas/FileUploadRequest"}}}},"responses":{"201":{"description":"The file.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/File"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"idempotent-replayed":{"$ref":"#/components/headers/IdempotentReplayed"}}},"400":{"description":"Invalid request. Error codes: invalid_json, missing_parameter, invalid_parameter.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"401":{"description":"Missing or invalid API key. Error codes: missing_api_key, invalid_api_key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"}}},"409":{"description":"Conflict with the current state. Error codes: idempotency_mismatch, idempotency_in_progress.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"413":{"description":"A size limit was exceeded. Error codes: file_too_large.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"415":{"description":"Unsupported media type or file format. Error codes: unsupported_media_type, unsupported_file.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"422":{"description":"The file cannot be processed. Error codes: invalid_file.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"429":{"description":"Too many requests. Error codes: pending_files_limit, rate_limited.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}},"500":{"description":"Internal error; not charged. Error codes: internal_error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}}}}},"/files/{id}":{"get":{"operationId":"retrieveFile","summary":"Retrieve a file","description":"Returns the file and whether its bytes have arrived.","tags":["Files"],"parameters":[{"name":"id","in":"path","required":true,"description":"File ID.","schema":{"type":"string"},"example":"file_8Hk2pQ4vN9sL1xR7cW3mY6zB"}],"responses":{"200":{"description":"The file.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/File"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"401":{"description":"Missing or invalid API key. Error codes: missing_api_key, invalid_api_key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"}}},"404":{"description":"Resource not found. Error codes: not_found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"429":{"description":"Too many requests. Error codes: rate_limited.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}},"500":{"description":"Internal error; not charged. Error codes: internal_error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}}}},"delete":{"operationId":"deleteFile","summary":"Delete a file","description":"Deletes an uploaded file and its stored bytes.","tags":["Files"],"parameters":[{"name":"id","in":"path","required":true,"description":"File ID.","schema":{"type":"string"},"example":"file_8Hk2pQ4vN9sL1xR7cW3mY6zB"}],"responses":{"200":{"description":"The file was deleted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FileDeleted"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"401":{"description":"Missing or invalid API key. Error codes: missing_api_key, invalid_api_key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"}}},"404":{"description":"Resource not found. Error codes: not_found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"429":{"description":"Too many requests. Error codes: rate_limited.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}},"500":{"description":"Internal error; not charged. Error codes: internal_error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}}}}},"/analyses":{"post":{"operationId":"createAnalysis","summary":"Create an analysis","description":"Analyzes an uploaded file with fvimg-2 (images) or fvdoc-3 (documents). An analysis is one image or document check. The response is 202 with status processing; the result arrives by webhook or by polling GET /analyses/{id}. Send Prefer: wait=N (up to 60 seconds) to hold the request until the result is ready; a finished analysis returns 200. The price is reserved when the analysis is created and released if it fails or is canceled. Results are kept for 7 days. When capacity is busy the API returns 503 service_unavailable with a retry-after header and charges nothing: retry with the same Idempotency-Key, and run image analyses one after another for the best throughput. Test keys return a sample result and are never charged; the sample report contains only a few fields.","tags":["Analyses"],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Unique key of up to 255 characters. Repeating the request with the same key and body within 24 hours returns the first response with the header idempotent-replayed: true; the same key with a different body returns 409.","schema":{"type":"string","maxLength":255}},{"name":"Prefer","in":"header","required":false,"description":"wait=N holds the request for up to N seconds (maximum 60) until the analysis finishes.","schema":{"type":"string","example":"wait=30"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalysisRequest"}}}},"responses":{"200":{"description":"The finished analysis.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Analysis"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"idempotent-replayed":{"$ref":"#/components/headers/IdempotentReplayed"},"preference-applied":{"$ref":"#/components/headers/PreferenceApplied"}}},"202":{"description":"The analysis is processing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Analysis"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"idempotent-replayed":{"$ref":"#/components/headers/IdempotentReplayed"},"preference-applied":{"$ref":"#/components/headers/PreferenceApplied"}}},"400":{"description":"Invalid request. Error codes: invalid_json, missing_parameter, file_not_found, invalid_parameter.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"401":{"description":"Missing or invalid API key. Error codes: missing_api_key, invalid_api_key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"}}},"402":{"description":"The balance or the key's monthly spend limit cannot cover the request. Error codes: insufficient_balance, spend_limit_reached.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"404":{"description":"Resource not found. Error codes: model_not_found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"409":{"description":"Conflict with the current state. Error codes: idempotency_mismatch, idempotency_in_progress.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"413":{"description":"A size limit was exceeded. Error codes: file_too_large, too_many_pixels, too_many_pages, document_too_long.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"415":{"description":"Unsupported media type or file format. Error codes: unsupported_media_type, unsupported_file.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"422":{"description":"The file cannot be processed. Error codes: invalid_file, password_required, wrong_password, not_examinable.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"429":{"description":"Too many requests. Error codes: rate_limited.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}},"500":{"description":"Internal error; not charged. Error codes: internal_error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"502":{"description":"Analysis could not be completed; not charged. Error codes: analysis_failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"503":{"description":"Temporarily unavailable or busy; not charged. Retry after the number of seconds in the retry-after header. Error codes: service_unavailable.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}}}},"get":{"operationId":"listAnalyses","summary":"List analyses","description":"Lists the image and document analyses of your workspace, newest first. Test keys always get an empty list.","tags":["Analyses"],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":20}},{"name":"starting_after","in":"query","required":false,"description":"Cursor: the next_cursor of the previous page.","schema":{"type":"string"}},{"name":"type","in":"query","required":false,"schema":{"enum":["image","document"]}}],"responses":{"200":{"description":"A page of analyses.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalysisList"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"400":{"description":"Invalid request. Error codes: invalid_parameter.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"401":{"description":"Missing or invalid API key. Error codes: missing_api_key, invalid_api_key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"}}},"429":{"description":"Too many requests. Error codes: rate_limited.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}},"500":{"description":"Internal error; not charged. Error codes: internal_error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}}}}},"/analyses/{id}":{"get":{"operationId":"retrieveAnalysis","summary":"Retrieve an analysis","description":"Returns the analysis, with its result once it has succeeded and until it expires.","tags":["Analyses"],"parameters":[{"name":"id","in":"path","required":true,"description":"Analysis ID.","schema":{"type":"string"},"example":"an_8Hk2pQ4vN9sL1xR7cW3mY6zB"}],"responses":{"200":{"description":"The analysis.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Analysis"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"401":{"description":"Missing or invalid API key. Error codes: missing_api_key, invalid_api_key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"}}},"404":{"description":"Resource not found. Error codes: not_found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"429":{"description":"Too many requests. Error codes: rate_limited.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}},"500":{"description":"Internal error; not charged. Error codes: internal_error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}}}}},"/analyses/{id}/cancel":{"post":{"operationId":"cancelAnalysis","summary":"Cancel an analysis","description":"Cancels a document analysis that is still processing and releases its charge. Image analyses cannot be canceled once created.","tags":["Analyses"],"parameters":[{"name":"id","in":"path","required":true,"description":"Analysis ID.","schema":{"type":"string"},"example":"an_8Hk2pQ4vN9sL1xR7cW3mY6zB"},{"name":"Idempotency-Key","in":"header","required":false,"description":"Unique key of up to 255 characters. Repeating the request with the same key and body within 24 hours returns the first response with the header idempotent-replayed: true; the same key with a different body returns 409.","schema":{"type":"string","maxLength":255}}],"responses":{"200":{"description":"The canceled analysis.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Analysis"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"idempotent-replayed":{"$ref":"#/components/headers/IdempotentReplayed"}}},"400":{"description":"Invalid request. Error codes: invalid_parameter.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"401":{"description":"Missing or invalid API key. Error codes: missing_api_key, invalid_api_key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"}}},"404":{"description":"Resource not found. Error codes: not_found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"409":{"description":"Conflict with the current state. Error codes: not_cancelable, idempotency_mismatch, idempotency_in_progress.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"429":{"description":"Too many requests. Error codes: rate_limited.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}},"500":{"description":"Internal error; not charged. Error codes: internal_error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}}}}},"/analyses/{id}/report.pdf":{"get":{"operationId":"retrieveAnalysisReport","summary":"Download the PDF report","description":"Returns the sealed PDF report of a succeeded analysis while its result is kept. Test keys get 404. Document evidence such as page images is available for 3 hours after the analysis; after that the PDF omits it, signaled by x-evidence-included: false.","tags":["Analyses"],"parameters":[{"name":"id","in":"path","required":true,"description":"Analysis ID.","schema":{"type":"string"},"example":"an_8Hk2pQ4vN9sL1xR7cW3mY6zB"},{"name":"locale","in":"query","required":false,"schema":{"enum":["en","fr","de","es","zh","vi","ar"],"default":"en"}}],"responses":{"200":{"description":"The PDF report.","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"x-evidence-included":{"$ref":"#/components/headers/EvidenceIncluded"}}},"400":{"description":"Invalid request. Error codes: invalid_parameter.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"401":{"description":"Missing or invalid API key. Error codes: missing_api_key, invalid_api_key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"}}},"404":{"description":"Resource not found. Error codes: not_found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"429":{"description":"Too many requests. Error codes: rate_limited.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}},"500":{"description":"Internal error; not charged. Error codes: internal_error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}}}}},"/models":{"get":{"operationId":"listModels","summary":"List models","description":"Lists the models available to your API key.","tags":["Models"],"responses":{"200":{"description":"The available models.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModelList"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"401":{"description":"Missing or invalid API key. Error codes: missing_api_key, invalid_api_key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"}}},"429":{"description":"Too many requests. Error codes: rate_limited.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}},"500":{"description":"Internal error; not charged. Error codes: internal_error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}}}}},"/models/{model}":{"get":{"operationId":"retrieveModel","summary":"Retrieve a model","description":"Retrieves a model by its ID or snapshot ID.","tags":["Models"],"parameters":[{"name":"model","in":"path","required":true,"description":"Model ID or snapshot ID.","schema":{"type":"string"},"example":"fvimg-2"}],"responses":{"200":{"description":"The model.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Model"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"401":{"description":"Missing or invalid API key. Error codes: missing_api_key, invalid_api_key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"}}},"404":{"description":"Resource not found. Error codes: model_not_found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"429":{"description":"Too many requests. Error codes: rate_limited.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}},"500":{"description":"Internal error; not charged. Error codes: internal_error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}}}}},"/text/detections":{"post":{"operationId":"createTextDetection","summary":"Detect AI-written text","description":"Classifies plain text as AI-written, partly AI-written or human-written and returns the AI-written passages. The text is evaluated and discarded; it is not stored. Billing counts Unicode code points in units of 1,000 characters, rounded up per request. Requests rejected before evaluation are not charged. Test keys return a fixed human result without charge.","tags":["Text"],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Unique key of up to 255 characters. Repeating the request with the same key and body within 24 hours returns the first response with the header idempotent-replayed: true; the same key with a different body returns 409.","schema":{"type":"string","maxLength":255}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TextDetectionRequest"}}}},"responses":{"200":{"description":"The detection result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TextDetection"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"idempotent-replayed":{"$ref":"#/components/headers/IdempotentReplayed"}}},"400":{"description":"Invalid request. Error codes: invalid_json, missing_parameter, text_too_short, unsupported_language, invalid_parameter.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"401":{"description":"Missing or invalid API key. Error codes: missing_api_key, invalid_api_key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"}}},"402":{"description":"The balance or the key's monthly spend limit cannot cover the request. Error codes: insufficient_balance, spend_limit_reached.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"404":{"description":"Resource not found. Error codes: model_not_found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"409":{"description":"Conflict with the current state. Error codes: idempotency_mismatch, idempotency_in_progress.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"413":{"description":"A size limit was exceeded. Error codes: text_too_long.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"415":{"description":"Unsupported media type or file format. Error codes: unsupported_media_type.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"429":{"description":"Too many requests. Error codes: rate_limited.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}},"500":{"description":"Internal error; not charged. Error codes: internal_error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"502":{"description":"Analysis could not be completed; not charged. Error codes: analysis_failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"}}},"503":{"description":"Temporarily unavailable or busy; not charged. Retry after the number of seconds in the retry-after header. Error codes: service_unavailable.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"x-request-id":{"$ref":"#/components/headers/RequestId"},"x-ratelimit-limit-requests":{"$ref":"#/components/headers/RateLimitLimit"},"x-ratelimit-remaining-requests":{"$ref":"#/components/headers/RateLimitRemaining"},"x-ratelimit-reset-requests":{"$ref":"#/components/headers/RateLimitReset"},"retry-after":{"$ref":"#/components/headers/RetryAfter"}}}}}}},"webhooks":{"analysis.completed":{"post":{"operationId":"webhook_analysis_completed","summary":"Event analysis.completed","description":"Delivered to your webhook endpoints following the Standard Webhooks specification: the headers webhook-id, webhook-timestamp and webhook-signature (v1,<base64 HMAC-SHA256 of id.timestamp.body>, keyed with the base64 part of your whsec_ secret). Respond with any 2xx within 10 seconds; failures are retried with exponential backoff for 3 days.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Event"}}}},"responses":{"200":{"description":"Event received."}}}},"analysis.failed":{"post":{"operationId":"webhook_analysis_failed","summary":"Event analysis.failed","description":"Delivered to your webhook endpoints following the Standard Webhooks specification: the headers webhook-id, webhook-timestamp and webhook-signature (v1,<base64 HMAC-SHA256 of id.timestamp.body>, keyed with the base64 part of your whsec_ secret). Respond with any 2xx within 10 seconds; failures are retried with exponential backoff for 3 days.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Event"}}}},"responses":{"200":{"description":"Event received."}}}},"balance.low":{"post":{"operationId":"webhook_balance_low","summary":"Event balance.low","description":"Delivered to your webhook endpoints following the Standard Webhooks specification: the headers webhook-id, webhook-timestamp and webhook-signature (v1,<base64 HMAC-SHA256 of id.timestamp.body>, keyed with the base64 part of your whsec_ secret). Respond with any 2xx within 10 seconds; failures are retried with exponential backoff for 3 days.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Event"}}}},"responses":{"200":{"description":"Event received."}}}}},"components":{"headers":{"RequestId":{"description":"ID of this request, repeated as error.request_id on errors. Quote it when you contact support.","schema":{"type":"string","example":"req_4mQ9cX2vB7nP1sK8tL3wR6yZ"}},"RateLimitLimit":{"description":"Requests allowed per one-minute window for this key.","schema":{"type":"integer","example":120}},"RateLimitRemaining":{"description":"Requests left in the current window.","schema":{"type":"integer"}},"RateLimitReset":{"description":"Seconds until the window resets.","schema":{"type":"integer"}},"RetryAfter":{"description":"Seconds to wait before retrying. Sent with rate_limited and service_unavailable.","schema":{"type":"integer"}},"IdempotentReplayed":{"description":"true when the response is a saved replay of an earlier request with the same Idempotency-Key.","schema":{"type":"string","const":"true"}},"PreferenceApplied":{"description":"wait=N when the Prefer header was honored.","schema":{"type":"string","example":"wait=60"}},"EvidenceIncluded":{"description":"false when document evidence has expired and the PDF omits it.","schema":{"type":"string","enum":["true","false"]}}},"securitySchemes":{"apiKey":{"type":"http","scheme":"bearer","description":"Your secret API key, fv_live_… for live requests or fv_test_… for test mode."}},"schemas":{"File":{"type":"object","required":["id","object","filename","bytes","content_type","status","livemode","created","expires_at"],"properties":{"id":{"type":"string","example":"file_8Hk2pQ4vN9sL1xR7cW3mY6zB"},"object":{"const":"file"},"filename":{"type":["string","null"]},"bytes":{"type":["integer","null"]},"content_type":{"type":"string"},"status":{"enum":["pending","uploaded"],"description":"pending until the bytes sent to the pre-signed URL have arrived."},"livemode":{"type":"boolean","description":"Files are only visible to keys of the same mode."},"created":{"type":"integer","description":"Unix timestamp."},"expires_at":{"type":"integer","description":"Unix timestamp after which the file is deleted."},"upload":{"type":"object","description":"Present on the response to a JSON upload request.","required":["url","method","headers","expires_at"],"properties":{"url":{"type":"string","description":"Test keys get a placeholder URL (test: true); nothing is uploaded or stored."},"method":{"const":"PUT"},"headers":{"type":"object","additionalProperties":{"type":"string"}},"expires_at":{"type":"integer","description":"Unix timestamp."},"test":{"const":true}}}}},"FileUploadRequest":{"type":"object","required":["content_type","bytes"],"additionalProperties":false,"properties":{"filename":{"type":"string"},"content_type":{"type":"string","description":"MIME type of the file, for example image/jpeg or application/pdf."},"bytes":{"type":"integer","minimum":1,"maximum":52428800,"description":"Exact size in bytes."}}},"FileDeleted":{"type":"object","required":["id","object","deleted"],"properties":{"id":{"type":"string"},"object":{"const":"file"},"deleted":{"const":true}}},"AnalysisRequest":{"type":"object","required":["model","file"],"additionalProperties":false,"properties":{"model":{"enum":["fvimg-2","fvimg-2-2026-10-30","fvdoc-3","fvdoc-3-2026-11-03"],"description":"Model ID or snapshot ID. fvimg-2 analyzes images, fvdoc-3 documents."},"file":{"type":"string","description":"ID of an uploaded file.","example":"file_8Hk2pQ4vN9sL1xR7cW3mY6zB"},"metadata":{"type":"object","description":"Up to 16 string pairs (keys up to 40 characters, values up to 500) returned on the analysis and in webhooks.","additionalProperties":{"type":"string","maxLength":500}},"options":{"type":"object","additionalProperties":false,"properties":{"password":{"type":"string","maxLength":256,"description":"Password of an encrypted document."},"locale":{"enum":["en","fr","de","es","zh","vi","ar"],"default":"en","description":"Language of document findings."}}}}},"ImageSummary":{"type":"object","description":"Summary of an image analysis.","required":["level","assessment","action","ai","edit"],"properties":{"level":{"enum":["L0","L1","L2","L3","L4","L5"],"description":"Risk level, L0 to L5."},"assessment":{"enum":["authentic_untouched","authentic_locally_edited","ai_generated","undetermined"]},"action":{"enum":["accept","review","reject","resubmit"]},"ai":{"enum":["labelled","very_likely","suspected","undecided","low","very_low","not_evaluated"],"description":"The finding on AI generation."},"edit":{"enum":["detected","suspected","suspected_record","review","generative","minor","none","not_applicable","not_evaluated"],"description":"The finding on local editing."}}},"DocumentSummary":{"type":"object","description":"Summary of a document analysis.","required":["kind","level","action","reason","findings","pages","images","text"],"properties":{"kind":{"const":"docpro"},"level":{"enum":["L0","L1","L2","L3","L4","L5"],"description":"Risk level, L0 to L5."},"action":{"enum":["accept","note","review","reject","resubmit"],"description":"note: check the AI content marked in the report against your policy."},"reason":{"type":["string","null"],"description":"The finding or condition behind the level, for example clean or incomplete, or a finding ID."},"findings":{"type":"array","items":{"type":"string"},"description":"IDs of the findings that matter."},"pages":{"type":"integer","description":"Pages in the document."},"images":{"type":"integer","description":"Embedded photos examined."},"text":{"enum":["ai_generated","mixed","human","inconclusive",null],"description":"The verdict on the document's text, or null when text was not evaluated."},"strong":{"const":true,"description":"Present when a listed finding is strong."}}},"ImageReport":{"type":"object","description":"The full report of an image analysis, the one the website and the PDF show. The fields below are stable within fileverity.report/1. New fields can be added, and fields not listed here are not part of the stable API.","required":["schema","id"],"properties":{"schema":{"const":"fileverity.report/1"},"id":{"type":"string","description":"Report ID, FV-XXXX-XXXX-XXXX."},"sample":{"const":true,"description":"Present on the fixed sample reports that test keys return."},"issuedAt":{"type":"string","format":"date-time","description":"When the report was issued, ISO 8601 in UTC."},"issuer":{"type":"object","description":"Who issued the report.","properties":{"name":{"type":"string"},"operator":{"type":"string"},"verify":{"type":"string","description":"Public verification page of the report."}}},"file":{"type":"object","description":"The checked image.","properties":{"name":{"type":["string","null"]},"sha256":{"type":"string","description":"SHA-256 of the checked file, in hex."},"bytes":{"type":"integer"},"width":{"type":"integer","description":"Width in pixels as displayed."},"height":{"type":"integer","description":"Height in pixels as displayed."},"format":{"type":"string"}}},"pro":{"type":"object","description":"The verdict. The same values as summary, with reason.","properties":{"level":{"enum":["L0","L1","L2","L3","L4","L5"],"description":"Risk level, L0 to L5."},"action":{"enum":["accept","review","reject","resubmit"]},"assessment":{"enum":["authentic_untouched","authentic_locally_edited","ai_generated","undetermined"]},"reason":{"type":["string","null"]}}},"score":{"type":["integer","null"],"minimum":0,"maximum":100,"description":"Authenticity score from 0 to 100 in steps of 5: how strongly the evidence supports the image as an authentic, unedited capture. null when not evaluated."},"confidence":{"enum":["high","medium","low"],"description":"How much this file allows the analysis to establish. Low confidence usually reflects the file itself, such as low resolution or heavy compression."},"questions":{"type":"object","description":"The three questions the report answers.","properties":{"ai":{"type":"object","properties":{"key":{"enum":["labelled","very_likely","suspected","undecided","low","very_low","not_evaluated"]},"basis":{"enum":["verified","detected","declared",null],"description":"What the answer rests on."},"strength":{"enum":["strong","moderate","limited",null],"description":"How strongly the evidence supports the answer."},"likelihood":{"type":["integer","null"],"description":"Likelihood of AI generation from 0 to 100 in steps of 5, or null."}}},"edit":{"type":"object","properties":{"key":{"enum":["detected","suspected","suspected_record","review","generative","minor","none","not_applicable","not_evaluated"]},"basis":{"enum":["verified","detected","declared",null],"description":"What the answer rests on."},"strength":{"enum":["strong","moderate","limited",null],"description":"How strongly the evidence supports the answer."},"regions":{"type":"integer","description":"Number of flagged regions."}}},"source":{"type":"object","properties":{"key":{"type":"string"},"basis":{"enum":["verified","detected","declared",null],"description":"What the answer rests on."},"strength":{"enum":["strong","moderate","limited",null],"description":"How strongly the evidence supports the answer."},"signer":{"type":["string","null"]},"aiClaim":{"type":"boolean","description":"Whether the file's own records claim AI generation."}}}}},"generator":{"type":["object","null"],"description":"The AI generator named for the image, or null.","properties":{"name":{"type":"string"},"basis":{"type":"string","description":"How the generator was identified."}}},"regions":{"type":"array","description":"Flagged regions, in pixels of the displayed image.","items":{"type":"object","properties":{"id":{"type":"string"},"x":{"type":"integer"},"y":{"type":"integer"},"w":{"type":"integer"},"h":{"type":"integer"},"strength":{"enum":["high","medium"]}}}},"provenance":{"type":"object","description":"What the file's own records say about its origin.","properties":{"credentials":{"enum":["valid","unverified","issues","invalid","removed","none"],"description":"State of the Content Credentials."},"signer":{"type":["string","null"]},"software":{"type":"array","items":{"type":"string"},"description":"Software named in the file's records."},"camera":{"type":["string","null"]},"captured":{"type":["string","null"],"description":"Capture time recorded in the file, if any."}}},"digest":{"type":"string","description":"Fingerprint of the report content, used by the verification page."}}},"DocumentReport":{"type":"object","description":"The full report of a document analysis, the one the website and the PDF show. The fields below are stable within fileverity.docpro/1. New fields can be added, and fields not listed here are not part of the stable API.","required":["schema","id"],"properties":{"schema":{"const":"fileverity.docpro/1"},"id":{"type":"string","description":"Report ID, FV-XXXX-XXXX-XXXX."},"sample":{"const":true,"description":"Present on the fixed sample reports that test keys return."},"issuedAt":{"type":"string","format":"date-time","description":"When the report was issued, ISO 8601 in UTC."},"receivedAt":{"type":"string","format":"date-time","description":"When the file was received, ISO 8601 in UTC."},"issuer":{"type":"object","description":"Who issued the report.","properties":{"name":{"type":"string"},"operator":{"type":"string"},"verify":{"type":"string","description":"Public verification page of the report."}}},"file":{"type":"object","description":"The checked document.","properties":{"name":{"type":["string","null"]},"sha256":{"type":"string","description":"SHA-256 of the checked file, in hex."},"bytes":{"type":"integer"},"format":{"type":"string"},"pages":{"type":"integer"},"textLayer":{"enum":["present","partial","absent"],"description":"Whether the document carries a text layer."}}},"level":{"enum":["L0","L1","L2","L3","L4","L5"],"description":"Risk level, L0 to L5."},"action":{"enum":["accept","note","review","reject","resubmit"]},"reason":{"type":["string","null"],"description":"The finding or condition behind the level."},"findings":{"type":"array","description":"The findings behind the level, each with the pages and embedded photos it refers to.","items":{"type":"object","properties":{"id":{"type":"string"},"basis":{"enum":["verified","detected","declared"]},"strength":{"enum":["strong","moderate","limited"]},"material":{"type":"boolean","description":"Whether the finding counts toward the level."},"pages":{"type":"array","items":{"type":"integer"}},"images":{"type":"array","items":{"type":"integer"}}}}},"text":{"type":"object","description":"The result for the document's text.","properties":{"status":{"enum":["evaluated","insufficient_text","unsupported_language","no_text"]},"verdict":{"enum":["ai_generated","mixed","human","inconclusive"],"description":"Present when status is evaluated."},"words":{"type":"integer"},"languages":{"type":"array","items":{"type":"string"}},"passages":{"type":"integer","description":"Number of marked passages."}}},"images":{"type":"array","description":"The embedded photos and graphics, numbered in document order.","items":{"type":"object","properties":{"n":{"type":"integer"},"pages":{"type":"array","items":{"type":"integer"}},"kind":{"enum":["photo","graphic"]},"width":{"type":"integer"},"height":{"type":"integer"},"level":{"enum":["L0","L1","L2","L3","L4","L5",null]},"assessment":{"enum":["authentic_untouched","authentic_locally_edited","ai_generated","undetermined",null]},"ai":{"enum":["labelled","very_likely","suspected","undecided","low","very_low","not_evaluated",null]},"edit":{"enum":["detected","suspected","suspected_record","review","generative","minor","none","not_applicable","not_evaluated",null]}}}},"structure":{"type":["object","null"],"description":"The edit history of the file, or null when it was not examined.","properties":{"revisions":{"type":["integer","null"]},"changedPages":{"type":"array","items":{"type":"integer"}},"addedPages":{"type":"integer"},"signatures":{"type":"integer"}}},"provenance":{"type":"object","description":"What the file's own records say about its origin.","properties":{"credentials":{"type":"string","description":"State of the Content Credentials."},"signer":{"type":["string","null"]},"aiClaim":{"type":"boolean","description":"Whether the file's own records claim AI generation."},"software":{"type":"array","items":{"type":"string"}},"created":{"type":["string","null"]},"modified":{"type":["string","null"]},"revisions":{"type":["integer","null"]},"signed":{"type":["boolean","null"]}}},"digest":{"type":"string","description":"Fingerprint of the report content, used by the verification page."}}},"Analysis":{"type":"object","required":["id","object","created","model","livemode","status","file","report_id","report_url","summary","result","error","progress","usage","metadata","completed_at","expires_at"],"properties":{"id":{"type":"string","example":"an_8Hk2pQ4vN9sL1xR7cW3mY6zB"},"object":{"const":"analysis"},"created":{"type":"integer","description":"Unix timestamp."},"model":{"type":"string","description":"Snapshot that produced the result.","example":"fvimg-2-2026-10-30"},"livemode":{"type":"boolean"},"status":{"enum":["processing","succeeded","failed","canceled"]},"file":{"type":"object","properties":{"name":{"type":["string","null"]},"bytes":{"type":["integer","null"]},"format":{"type":["string","null"]}}},"report_id":{"type":["string","null"],"description":"Verifiable report ID, FV-XXXX-XXXX-XXXX."},"report_url":{"type":["string","null"],"description":"Public verification page of the report."},"summary":{"oneOf":[{"$ref":"#/components/schemas/ImageSummary"},{"$ref":"#/components/schemas/DocumentSummary"},{"type":"null"}],"description":"The short, stable verdict: an ImageSummary for images, a DocumentSummary for documents, null until the analysis succeeds."},"result":{"type":["object","null"],"description":"Present once status is succeeded and until the result expires.","properties":{"report":{"oneOf":[{"$ref":"#/components/schemas/ImageReport"},{"$ref":"#/components/schemas/DocumentReport"}],"description":"The full report. report.schema is fileverity.report/1 for images and fileverity.docpro/1 for documents."},"stamped_at":{"type":["integer","null"],"description":"Unix timestamp of the RFC 3161 timestamp issued for the report, or null."}}},"error":{"type":["object","null"],"properties":{"code":{"enum":["invalid_json","missing_parameter","invalid_parameter","text_too_short","text_too_long","unsupported_media_type","unsupported_language","file_not_found","unsupported_file","file_too_large","too_many_pixels","too_many_pages","document_too_long","invalid_file","password_required","wrong_password","not_examinable","missing_api_key","invalid_api_key","insufficient_balance","spend_limit_reached","not_found","model_not_found","not_cancelable","canceled","idempotency_mismatch","idempotency_in_progress","pending_files_limit","rate_limited","internal_error","analysis_failed","service_unavailable"]},"message":{"type":"string"}}},"progress":{"type":["object","null"],"properties":{"stage":{"enum":["queued","reading","analyzing","reporting"]},"done":{"type":"integer","description":"Units finished in the current stage, when known; otherwise 0."},"total":{"type":"integer","description":"Units in the current stage, when known; otherwise 0."},"position":{"type":"integer","description":"Queue position while the stage is queued."}}},"usage":{"type":"object","properties":{"amount":{"type":"integer","description":"Charge in cents; 0 for free-start checks and failures."},"currency":{"const":"usd"},"funding":{"enum":["trial","balance",null]}}},"metadata":{"type":["object","null"],"additionalProperties":{"type":"string"}},"completed_at":{"type":["integer","null"]},"expires_at":{"type":["integer","null"],"description":"Unix timestamp after which the result is deleted."}}},"AnalysisList":{"type":"object","required":["object","data","has_more","next_cursor"],"properties":{"object":{"const":"list"},"data":{"type":"array","items":{"$ref":"#/components/schemas/Analysis"}},"has_more":{"type":"boolean"},"next_cursor":{"type":["string","null"],"description":"Pass as starting_after to get the next page."}}},"BalanceLow":{"type":"object","required":["balance","threshold"],"properties":{"balance":{"type":"integer","description":"Balance in cents."},"threshold":{"type":"integer","description":"Alert threshold in cents."}}},"Event":{"type":"object","required":["id","object","type","created","data"],"properties":{"id":{"type":"string","example":"evt_8Hk2pQ4vN9sL1xR7cW3mY6zB","description":"Also sent as the webhook-id header; use it to deduplicate retries."},"object":{"const":"event"},"type":{"enum":["analysis.completed","analysis.failed","balance.low"]},"created":{"type":"integer","description":"Unix timestamp."},"data":{"oneOf":[{"$ref":"#/components/schemas/Analysis"},{"$ref":"#/components/schemas/BalanceLow"}],"description":"analysis.* events carry the same object as GET /analyses/{id}, with result always null; fetch the result with that endpoint. balance.low events carry the balance and threshold in cents."}}},"Model":{"type":"object","required":["id","object","created","owned_by","name","type","description","snapshot","status","input","output","pricing"],"properties":{"id":{"type":"string","example":"fvimg-2"},"object":{"const":"model"},"created":{"type":"integer","description":"Unix timestamp of the current snapshot."},"owned_by":{"type":"string","example":"fileverity"},"name":{"type":"string"},"type":{"enum":["image","document","text"]},"description":{"type":"string"},"snapshot":{"type":"string","description":"Dated snapshot the ID currently points to.","example":"fvimg-2-2026-10-30"},"status":{"enum":["available","preview","deprecated"]},"input":{"type":"object","description":"Accepted input. Files list formats and size limits; text lists languages and length limits.","properties":{"formats":{"type":"array","items":{"type":"string"}},"max_bytes":{"type":"integer"},"max_megapixels":{"type":"integer"},"max_pages":{"type":"integer"},"languages":{"type":"array","items":{"type":"string"}},"min_words":{"type":"integer"},"max_characters":{"type":"integer"}}},"output":{"type":"object","required":["schema"],"properties":{"schema":{"type":"string","description":"Schema of the report in analysis results."}}},"pricing":{"type":"object","required":["currency","unit","unit_amount"],"properties":{"currency":{"const":"usd"},"unit":{"type":"string"},"unit_amount":{"type":"integer","description":"Price per unit in cents."}}}}},"TextDetectionRequest":{"type":"object","required":["text"],"additionalProperties":false,"properties":{"model":{"type":"string","default":"fvdoc-3-text","description":"Model ID or snapshot ID."},"text":{"type":"string","maxLength":100000,"description":"Plain text, at least 100 words and at most 100,000 characters."},"language":{"enum":["en","fr","de","es","zh",null],"default":null,"description":"ISO 639-1 code. Detected automatically when omitted."}}},"TextDetection":{"type":"object","required":["id","object","created","model","livemode","language","verdict","score","ai_fraction","segments","usage"],"properties":{"id":{"type":"string","example":"tdet_8Hk2pQ4vN9sL1xR7cW3mY6zB"},"object":{"const":"text.detection"},"created":{"type":"integer","description":"Unix timestamp."},"model":{"type":"string","description":"Snapshot that produced the result.","example":"fvdoc-3-text-2026-11-03"},"livemode":{"type":"boolean","description":"False for test keys."},"language":{"enum":["en","fr","de","es","zh"]},"verdict":{"enum":["ai","mixed","human"],"description":"ai: the text reads as AI-written throughout; mixed: AI-written passages within human text; human: no AI-written passage found."},"score":{"type":"number","minimum":0,"maximum":1,"description":"Model score for the most AI-like passage."},"ai_fraction":{"type":"number","minimum":0,"maximum":1,"description":"Share of the evaluated text inside AI-written segments."},"segments":{"type":"array","description":"AI-written passages, as offsets into the submitted text in Unicode code points. Boundaries are approximate and can include adjacent sentences.","items":{"type":"object","required":["start","end","score"],"properties":{"start":{"type":"integer"},"end":{"type":"integer","description":"Exclusive."},"score":{"type":"number","minimum":0,"maximum":1}}}},"usage":{"type":"object","required":["characters","free_characters","billed_units"],"properties":{"characters":{"type":"integer","description":"Unicode code points evaluated."},"free_characters":{"type":"integer","description":"Characters covered by your free-start allowance, not billed."},"billed_units":{"type":"integer","description":"Units of 1,000 characters actually charged, after free characters; billed_units × unit price is the cost."}}}}},"ModelList":{"type":"object","required":["object","data"],"properties":{"object":{"const":"list"},"data":{"type":"array","items":{"$ref":"#/components/schemas/Model"}}}},"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["type","code","message","param","request_id"],"properties":{"type":{"enum":["invalid_request_error","authentication_error","billing_error","not_found_error","conflict_error","rate_limit_error","api_error"]},"code":{"enum":["invalid_json","missing_parameter","invalid_parameter","text_too_short","text_too_long","unsupported_media_type","unsupported_language","file_not_found","unsupported_file","file_too_large","too_many_pixels","too_many_pages","document_too_long","invalid_file","password_required","wrong_password","not_examinable","missing_api_key","invalid_api_key","insufficient_balance","spend_limit_reached","not_found","model_not_found","not_cancelable","canceled","idempotency_mismatch","idempotency_in_progress","pending_files_limit","rate_limited","internal_error","analysis_failed","service_unavailable"]},"message":{"type":"string"},"param":{"type":["string","null"]},"request_id":{"type":"string","example":"req_4mQ9cX2vB7nP1sK8tL3wR6yZ"}}}}}}}}