Skip to Content

API Reference

The Onoots OS exposes Mr. Onoots (the AI analyst) through a single public endpoint. Each vertical’s business APIs are documented on its own site — see Per-vertical APIs.

POST /api/chat

A public endpoint (no token) that powers Mr. Onoots, rate-limited per IP (15 req/min). The response is streamed.

Request

POST /api/chat Content-Type: application/json { "messages": [ { "role": "user", "parts": [{ "type": "text", "text": "How is the agent payout calculated?" }] } ], "appId": "proptech", "document": { "name": "closing.pdf", "content": "..." } }
FieldTypeRequiredDescription
messagesUIMessage[]Chat history (1–50 messages), AI SDK format
appIdenumActive vertical: proptech · supply · fintech · wealth · crowdfunding · luxury · insurance · ledger. If omitted, uses the generic landing persona
document{ name, content }Attached document for the analyst to cite

Response

A stream of messages (AI SDK UI message stream). The persona changes based on appId:

  • Known vertical → a domain-aware analyst: answers with tables, ledger-anchored figures, and fail-closed policy.
  • No vertical → “Mr. Onoots”, a public guide in plain language that replies in the user’s language.

Errors

StatusErrorCause
400bad_requestmessages empty, not an array, or over 50
429rate_limitedMore than 15 requests per minute per IP
503ai_unconfiguredANTHROPIC_API_KEY is missing in the deployment

Powered by Claude (Anthropic). The model can be overridden with the ONOOTS_AI_MODEL environment variable.

Per-vertical APIs

Each vertical documents its own business API (authenticated with Bearer + RLS):

Last updated on