{"openapi":"3.1.0","info":{"title":"FALA by Elav8 public API","version":"1.0.0","description":"Public, unauthenticated FALA (Elevate Follow-Up by Elav8) surface: widget runtime, health, branding, and agent discovery. Dashboard, admin, billing mutation, and Shopify-internal routes are not part of this specification.","contact":{"name":"FALA by Elav8","url":"https://fala.elav8.ai/developers"}},"servers":[{"url":"https://fala.elav8.ai","description":"Production"}],"tags":[{"name":"Discovery","description":"Agent and developer discovery files"},{"name":"Widget runtime","description":"Public embed API keyed by public_key"}],"paths":{"/api/health":{"get":{"tags":["Discovery"],"operationId":"getHealth","summary":"Liveness and database ping","responses":{"200":{"description":"Service is up","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"db":{"type":"boolean"}}}}}}}}},"/api/elav8/branding":{"get":{"tags":["Discovery"],"operationId":"getElav8Branding","summary":"Public FALA branding from Paga","description":"Unauthenticated theme payload (or empty object when billing is unconfigured).","responses":{"200":{"description":"Branding object or {}"}}}},"/openapi.json":{"get":{"tags":["Discovery"],"operationId":"getOpenApi","summary":"This OpenAPI document","responses":{"200":{"description":"OpenAPI 3.1 document","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/llms.txt":{"get":{"tags":["Discovery"],"operationId":"getLlmsTxt","summary":"llms.txt agent index","responses":{"200":{"description":"Markdown index","content":{"text/markdown":{"schema":{"type":"string"}}}}}}},"/.well-known/api-catalog":{"get":{"tags":["Discovery"],"operationId":"getApiCatalog","summary":"RFC 9727 API catalog","responses":{"200":{"description":"Linkset catalog","content":{"application/linkset+json":{"schema":{"type":"object"}}}}}}},"/widget.js":{"get":{"tags":["Widget runtime"],"operationId":"getWidgetLoader","summary":"Embeddable FALA widget loader","responses":{"200":{"description":"JavaScript loader","content":{"application/javascript":{"schema":{"type":"string"}}}}}}},"/api/w/{public_key}/config":{"get":{"tags":["Widget runtime"],"operationId":"getWidgetConfig","summary":"Public widget appearance and capabilities","parameters":[{"name":"public_key","in":"path","required":true,"schema":{"type":"string"},"description":"Widget public key from the embed snippet"}],"responses":{"200":{"description":"Widget config snapshot"},"404":{"description":"Unknown widget"}}}},"/api/w/chat":{"post":{"tags":["Widget runtime"],"operationId":"postWidgetChat","summary":"Stream a text reply from the published agent","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatRequest"}}}},"responses":{"200":{"description":"Server-sent events stream of tokens and cards"},"404":{"description":"Unknown widget"}}}},"/api/w/lead":{"post":{"tags":["Widget runtime"],"operationId":"postWidgetLead","summary":"Capture a visitor lead","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadCapture"}}}},"responses":{"200":{"description":"Lead accepted"},"404":{"description":"Unknown widget"}}}},"/api/w/{public_key}/voice-token":{"post":{"tags":["Widget runtime"],"operationId":"postWidgetVoiceToken","summary":"Mint an ephemeral live-voice token","parameters":[{"name":"public_key","in":"path","required":true,"schema":{"type":"string"},"description":"Widget public key from the embed snippet"}],"responses":{"200":{"description":"Short-lived voice credentials"},"404":{"description":"Unknown widget"}}}}},"components":{"schemas":{"ChatRequest":{"type":"object","required":["public_key","message"],"properties":{"public_key":{"type":"string"},"message":{"type":"string","maxLength":8000},"conversation_id":{"type":"string"},"visitor_id":{"type":"string"}}},"LeadCapture":{"type":"object","required":["public_key"],"properties":{"public_key":{"type":"string"},"conversation_id":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"},"notes":{"type":"string"}}}}}}