{"openapi":"3.1.0","info":{"title":"Achtung.app API","version":"1.0.0","description":"AI Visibility Intelligence API. Track how brands are cited, mentioned, and recommended by major AI assistants (ChatGPT, Gemini, Claude, Perplexity, Grok, Mistral). Visibility scores are computed from blind multi-query LLM prompts run several times per day per keyword and averaged, so they reflect stable trends rather than single-response noise. See /llms.txt for a full product overview.","contact":{"email":"hello@achtung.app","url":"https://achtung.app"},"termsOfService":"https://achtung.app/agb","license":{"name":"Proprietary"}},"servers":[{"url":"https://achtung.app/api/v1","description":"Production"}],"externalDocs":{"description":"LLM-readable product index","url":"https://achtung.app/llms.txt"},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","description":"Laravel Sanctum bearer token. Preview tokens are issued via POST /tokens (email verification). Full API tokens are issued from the admin panel on Pro/Enterprise plans."}},"schemas":{"TokenRequest":{"type":"object","required":["email","agree_to_terms"],"properties":{"email":{"type":"string","format":"email","description":"Business email at the domain you want to scan. Free mail providers are rejected."},"agree_to_terms":{"type":"boolean","const":true}}},"TokenIssued":{"type":"object","properties":{"message":{"type":"string"},"abilities":{"type":"array","items":{"type":"string"}},"daily_limit":{"type":"integer"},"docs":{"type":"string","format":"uri"}}},"PreviewScanResult":{"type":"object","properties":{"domain":{"type":"string"},"brand":{"type":"string"},"niche":{"type":"string"},"cached":{"type":"boolean"},"checked_at":{"type":"string","format":"date-time"},"providers_checked":{"type":"array","items":{"type":"string"}},"queries_checked":{"type":"integer"},"visibility":{"type":"object","properties":{"mentioned":{"type":"boolean"},"mention_count":{"type":"integer"},"top_competitors":{"type":"array","items":{"type":"string"}}}},"cta":{"type":"object","properties":{"message":{"type":"string"},"url":{"type":"string","format":"uri"}}}}},"BrandList":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"domain":{"type":"string"},"niche":{"type":"string","nullable":true},"is_active":{"type":"boolean"},"created_at":{"type":"string","format":"date-time"}}}}}},"ScoreList":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"geo_score":{"type":"number"},"citation_frequency":{"type":"number"},"sentiment_score":{"type":"number"},"period_start":{"type":"string","format":"date"},"period_end":{"type":"string","format":"date"}}}}}}}},"security":[{"bearerAuth":[]}],"paths":{"/tokens":{"post":{"summary":"Request a preview API token","description":"Emails a Sanctum token with the `preview` ability to the given address. Rate limited to 3 requests per IP per hour. The token is not returned in the response \u2014 delivered by email only.","security":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenRequest"}}}},"responses":{"201":{"description":"Token issued and emailed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenIssued"}}}},"422":{"description":"Validation error"},"429":{"description":"Rate limit exceeded"}}}},"/scan/preview":{"get":{"summary":"Run a free preview visibility scan","description":"Returns a lightweight AI visibility check for the given domain. Domain must match the email domain used to issue the token. Results cached 24h, 10 scans per token per day.","parameters":[{"name":"domain","in":"query","required":true,"schema":{"type":"string"},"description":"Domain to scan; must match token owner's email domain"},{"name":"brand","in":"query","required":false,"schema":{"type":"string"},"description":"Brand name; defaults to the domain"},{"name":"location","in":"query","required":false,"schema":{"type":"string"},"description":"City/region for local-business queries (e.g. \"Berlin, Germany\")"}],"responses":{"200":{"description":"Scan result","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreviewScanResult"}}}},"403":{"description":"Token domain mismatch or missing preview ability"},"422":{"description":"Invalid or missing domain"},"429":{"description":"Daily token limit exceeded"},"503":{"description":"Preview budget temporarily exhausted"}}}},"/brands":{"get":{"summary":"List brands in the authenticated team","description":"Requires a token on a Pro or Enterprise plan.","responses":{"200":{"description":"List of brands","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandList"}}}},"401":{"description":"Unauthenticated"},"403":{"description":"Plan does not include API access"}}}},"/brands/{brand}/scores":{"get":{"summary":"Score history for a brand","description":"Returns up to 90 daily AI Prominence scores in reverse chronological order.","parameters":[{"name":"brand","in":"path","required":true,"schema":{"type":"integer"},"description":"Brand ID"}],"responses":{"200":{"description":"Score list","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScoreList"}}}},"401":{"description":"Unauthenticated"},"403":{"description":"Brand is outside the authenticated team"},"404":{"description":"Brand not found"}}}},"/brands/{brand}/keywords":{"get":{"summary":"Tracked keywords for a brand","parameters":[{"name":"brand","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Keyword list"},"401":{"description":"Unauthenticated"},"403":{"description":"Brand is outside the authenticated team"}}}},"/brands/{brand}/reports":{"get":{"summary":"Generated monthly reports for a brand","parameters":[{"name":"brand","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Report list"},"401":{"description":"Unauthenticated"},"403":{"description":"Brand is outside the authenticated team"}}}},"/user":{"get":{"summary":"The authenticated user","responses":{"200":{"description":"User record"},"401":{"description":"Unauthenticated"}}}}}}