{"openapi":"3.1.0","info":{"title":"LookTwice API","version":"0.1.0","description":"Verify business inputs and watch important facts. Results are signals with evidence, not certifications of safety, legality, deliverability, or account existence."},"servers":[{"url":"https://api.looktwice.dev","description":"Production"},{"url":"http://localhost:4000","description":"Local development"}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"API key"}},"parameters":{"idempotencyKey":{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","minLength":8,"maxLength":200},"description":"Required on charged POST operations. Reuse only for an identical request body."}}},"security":[{"bearerAuth":[]}],"paths":{"/v1/email/check":{"post":{"tags":["Validation"],"summary":"Check email signals (2 credits)","parameters":[{"$ref":"#/components/parameters/idempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["email"],"properties":{"email":{"type":"string"}}}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"mailbox_status":{"const":"not_checked"}}}}},"headers":{"Idempotency-Replayed":{"description":"True when this response replays a completed request.","schema":{"type":"boolean"}},"X-LookTwice-Credits-Charged":{"description":"Credits charged by this HTTP attempt; zero on a replay.","schema":{"type":"integer","minimum":0}},"X-LookTwice-Original-Credits-Charged":{"description":"The original charge, present on a replay.","schema":{"type":"integer","minimum":0}},"X-LookTwice-Credits-Remaining":{"description":"Current workspace balance after the operation.","schema":{"type":"integer","minimum":0}},"X-LookTwice-Price-Version":{"description":"Price version locked to the original request.","schema":{"type":"string"}}}},"400":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"402":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"403":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"422":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"429":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"503":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}}}}},"/v1/vat/check":{"post":{"tags":["Validation"],"summary":"Check a VAT number against VIES (1 credit)","parameters":[{"$ref":"#/components/parameters/idempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["country_code","vat_number"],"properties":{"country_code":{"type":"string","minLength":2,"maxLength":2},"vat_number":{"type":"string"},"requester_country_code":{"type":"string"},"requester_vat_number":{"type":"string"}}}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"valid":{"type":"boolean"},"checked_at":{"type":"string","format":"date-time"}}}}},"headers":{"Idempotency-Replayed":{"description":"True when this response replays a completed request.","schema":{"type":"boolean"}},"X-LookTwice-Credits-Charged":{"description":"Credits charged by this HTTP attempt; zero on a replay.","schema":{"type":"integer","minimum":0}},"X-LookTwice-Original-Credits-Charged":{"description":"The original charge, present on a replay.","schema":{"type":"integer","minimum":0}},"X-LookTwice-Credits-Remaining":{"description":"Current workspace balance after the operation.","schema":{"type":"integer","minimum":0}},"X-LookTwice-Price-Version":{"description":"Price version locked to the original request.","schema":{"type":"string"}}}},"400":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"402":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"403":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"422":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"429":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"503":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}}}}},"/v1/iban/check":{"post":{"tags":["Validation"],"summary":"Check IBAN format and checksum (1 credit)","parameters":[{"$ref":"#/components/parameters/idempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["iban"],"properties":{"iban":{"type":"string"}}}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"valid":{"type":"boolean"},"account_status":{"const":"not_checked"}}}}},"headers":{"Idempotency-Replayed":{"description":"True when this response replays a completed request.","schema":{"type":"boolean"}},"X-LookTwice-Credits-Charged":{"description":"Credits charged by this HTTP attempt; zero on a replay.","schema":{"type":"integer","minimum":0}},"X-LookTwice-Original-Credits-Charged":{"description":"The original charge, present on a replay.","schema":{"type":"integer","minimum":0}},"X-LookTwice-Credits-Remaining":{"description":"Current workspace balance after the operation.","schema":{"type":"integer","minimum":0}},"X-LookTwice-Price-Version":{"description":"Price version locked to the original request.","schema":{"type":"string"}}}},"400":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"402":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"403":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"422":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"429":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}}}}},"/v1/domain/check":{"post":{"tags":["Validation"],"summary":"Check DNS, MX, TLS, and RDAP (free; 100/day/workspace)","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["domain"],"properties":{"domain":{"type":"string"}}}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"domain":{"type":"string"},"mail_configured":{"type":"boolean"},"mx_status":{"enum":["configured","null_mx","absent","unavailable"]},"checked_at":{"type":"string","format":"date-time"}}}}},"headers":{"X-LookTwice-Domain-Requests-Remaining":{"description":"Successful free Domain checks remaining today for the workspace.","schema":{"type":"integer","minimum":0,"maximum":100}}}},"403":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"422":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"429":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"503":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}}}}},"/v1/cpsc/recall-match":{"post":{"tags":["CPSC"],"summary":"Find recall and warning candidates (3 credits)","description":"Requires at least one of brand, model, or UPC. A none result is not a safety or legal clearance.","parameters":[{"$ref":"#/components/parameters/idempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["product_name"],"properties":{"external_id":{"type":"string","maxLength":128},"product_name":{"type":"string","maxLength":500},"brand":{"type":"string","maxLength":200},"model":{"type":"string","maxLength":200},"upc":{"type":"string","maxLength":32},"description":{"type":"string","maxLength":2000}}}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"match_level":{"enum":["exact","likely","possible","none"]},"candidates":{"type":"array","items":{"type":"object"}},"disclaimer":{"type":"string"}}}}},"headers":{"Idempotency-Replayed":{"description":"True when this response replays a completed request.","schema":{"type":"boolean"}},"X-LookTwice-Credits-Charged":{"description":"Credits charged by this HTTP attempt; zero on a replay.","schema":{"type":"integer","minimum":0}},"X-LookTwice-Original-Credits-Charged":{"description":"The original charge, present on a replay.","schema":{"type":"integer","minimum":0}},"X-LookTwice-Credits-Remaining":{"description":"Current workspace balance after the operation.","schema":{"type":"integer","minimum":0}},"X-LookTwice-Price-Version":{"description":"Price version locked to the original request.","schema":{"type":"string"}}}},"400":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"402":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"403":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"422":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"429":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}},"503":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}}}}},"/v1/cpsc/catalogs":{"get":{"tags":["CPSC"],"summary":"List catalogs","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}}}}}}}}},"post":{"tags":["CPSC"],"summary":"Create a daily catalog watch","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string"},"webhook_endpoint_id":{"type":"string","format":"uuid"}}}}}},"responses":{"201":{"description":"Catalog created","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/cpsc/catalogs/{id}/items":{"post":{"tags":["CPSC"],"summary":"Upsert up to 1,000 catalog items","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["items"],"properties":{"items":{"type":"array","minItems":1,"maxItems":1000,"items":{"type":"object","required":["product_name"],"properties":{"external_id":{"type":"string","maxLength":128},"product_name":{"type":"string","maxLength":500},"brand":{"type":"string","maxLength":200},"model":{"type":"string","maxLength":200},"upc":{"type":"string","maxLength":32},"description":{"type":"string","maxLength":2000}}}}}}}}},"responses":{"202":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"accepted":{"type":"integer"},"catalog_id":{"type":"string","format":"uuid"}}}}}}}}},"/v1/cpsc/catalogs/{id}/import":{"post":{"tags":["CPSC"],"summary":"Import up to 1,000 catalog rows from CSV","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}}}},"responses":{"202":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"accepted":{"type":"integer"}}}}}}}}},"/v1/cpsc/catalogs/{id}/matches":{"get":{"tags":["CPSC"],"summary":"List catalog matches","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"status","in":"query","schema":{"enum":["active","resolved","all"],"default":"active"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"status":{"enum":["active","resolved"]},"resolved_at":{"type":["string","null"],"format":"date-time"},"last_evaluated_at":{"type":"string","format":"date-time"}}}},"disclaimer":{"type":"string"}}}}}}}}},"/v1/cpsc/catalogs/{id}":{"delete":{"tags":["CPSC"],"summary":"Delete a catalog","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"204":{"description":"Catalog deleted"}}}},"/v1/knowledge/watches":{"get":{"tags":["Knowledge"],"summary":"List knowledge watches","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}}}}}}}}},"post":{"tags":["Knowledge"],"summary":"Create a daily public-page fact watch","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["url","facts"],"properties":{"url":{"type":"string","format":"uri","pattern":"^https://"},"facts":{"type":"array","minItems":1,"maxItems":10,"items":{"type":"object","required":["key","description"],"properties":{"key":{"type":"string"},"description":{"type":"string"}}}},"webhook_endpoint_id":{"type":"string","format":"uuid"}}}}}},"responses":{"201":{"description":"Watch created","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/knowledge/watches/{id}":{"get":{"tags":["Knowledge"],"summary":"Get a watch and recent changes","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}}},"delete":{"tags":["Knowledge"],"summary":"Delete a watch","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"204":{"description":"Watch deleted"}}}},"/v1/credits/balance":{"get":{"tags":["Account"],"summary":"Get credit balance","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"available":{"type":"integer"},"reserved":{"type":"integer"},"expiring":{"type":"array","items":{"type":"object"}}}}}}}}}},"/v1/usage":{"get":{"tags":["Account"],"summary":"List metered usage","parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100}},{"name":"cursor","in":"query","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}},"next_cursor":{"type":["string","null"]}}}}}}}}},"/v1/prices":{"get":{"tags":["Account"],"summary":"Get prices (2026-08-11.v1)","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/api-keys":{"get":{"tags":["Account"],"summary":"List API keys","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}}}}}}}}},"post":{"tags":["Account"],"summary":"Create an API key","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string"},"environment":{"enum":["live","test"]},"scopes":{"type":"array","items":{"enum":["validators:email","validators:vat","validators:iban","validators:domain","cpsc:read","cpsc:write","knowledge:read","knowledge:write","webhooks:read","webhooks:write","usage:read","keys:manage","billing:manage","*"]}},"spend_limit_credits":{"type":"integer","minimum":1,"description":"Maximum synchronous API credits for this key per UTC calendar month. Scheduled Catalog and Knowledge charges are workspace-level and excluded."}}}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/api-keys/{id}":{"delete":{"tags":["Account"],"summary":"Revoke an API key","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"204":{"description":"Key revoked"}}}},"/v1/webhook-endpoints":{"get":{"tags":["Webhooks"],"summary":"List webhook endpoints","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}}}}}}}}},"post":{"tags":["Webhooks"],"summary":"Create a webhook endpoint","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["url"],"properties":{"url":{"type":"string","format":"uri","pattern":"^https://"},"description":{"type":"string"}}}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/events":{"get":{"tags":["Webhooks"],"summary":"List generated events","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}}}}}}}}}},"/v1/webhook-deliveries/{id}/replay":{"post":{"tags":["Webhooks"],"summary":"Replay a webhook delivery","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"202":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"status":{"const":"pending"}}}}}}}}},"/v1/billing/checkout":{"post":{"tags":["Billing"],"summary":"Create a Paddle checkout","description":"Subscription checkout is available only when Paddle billing is enabled. Top-up checkout additionally requires the PAYG approval feature flag.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["kind","id"],"properties":{"kind":{"enum":["topup","subscription"]},"id":{"type":"string"}}}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/billing/portal":{"post":{"tags":["Billing"],"summary":"Create a Paddle customer portal session","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/billing/auto-reload":{"get":{"tags":["Billing"],"summary":"Get auto-reload settings","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}}},"put":{"tags":["Billing"],"summary":"Configure explicit-consent auto-reload","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["enabled","threshold_credits","topup_pack_id","monthly_limit_usd_cents","consent"],"properties":{"enabled":{"type":"boolean"},"threshold_credits":{"type":"integer","minimum":0},"topup_pack_id":{"enum":["payg_10","payg_50","payg_200","payg_900"]},"monthly_limit_usd_cents":{"type":"integer","minimum":1000},"consent":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"422":{"description":"Request failed","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","request_id"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","additionalProperties":true}}}}}}}}}}},"/v1/status":{"get":{"security":[],"tags":["Status"],"summary":"Get public component status","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["status","checked_at","components","features","data_sources","outbox_lag_seconds"],"properties":{"status":{"enum":["operational","degraded"]},"checked_at":{"type":"string","format":"date-time"},"components":{"type":"object","additionalProperties":{"type":"boolean"}},"features":{"type":"object","additionalProperties":{"type":"boolean"}},"data_sources":{"type":"array","items":{"type":"object","required":["source","label","source_url","last_success_at","record_count","parsed_count","fresh"],"properties":{"source":{"type":"string"},"label":{"type":"string"},"source_url":{"type":"string","format":"uri"},"last_success_at":{"type":["string","null"],"format":"date-time"},"record_count":{"type":["integer","null"],"minimum":0},"parsed_count":{"type":["integer","null"],"minimum":0},"fresh":{"type":"boolean"}}}},"outbox_lag_seconds":{"type":["number","null"]}}}}}}}}}}}