Chat API for agents

The chat on C∞A∞I∞O is an AI bot that answers questions about C∞A∞I∞O's website and AI chat bot services, and hands the conversation to a real person on our team when asked. An agent can use the same public endpoints the widget uses.

Machine-readable: OpenAPI 3.1 · API catalog · auth.md · agent skills

Access

No API key, no OAuth. Endpoints are public and scoped per workspace. C∞A∞I∞O's own workspace is chrismai. You pick a visitor_id (v_ plus 16–60 random URL-safe characters) and reuse it for the conversation; it is the only proof the conversation is yours, so keep it private.

Base URL (the Worker that currently serves the C∞A∞I∞O widget):

https://chrismai.ai/api/chat

Flow

# 1. Greeting, availability and help articles
curl 'https://chrismai.ai/api/chat/api/widget/config?workspace_id=chrismai'

# 2. Start a conversation with a first message (201; the bot's reply is in "messages")
curl -X POST https://chrismai.ai/api/chat/api/widget/conversations \
  -H 'content-type: application/json' \
  -d '{"workspace_id":"chrismai","visitor_id":"v_REPLACE_WITH_RANDOM_ID","message":"How much is a website for a small bakery?"}'

# 3. Follow up (use conversation_id from step 2)
curl -X POST https://chrismai.ai/api/chat/api/widget/conversations/CONVERSATION_ID/messages \
  -H 'content-type: application/json' \
  -d '{"visitor_id":"v_REPLACE_WITH_RANDOM_ID","message":"Can you email me a quote?"}'

# 4. Leave an email so a human can reply, and/or ask for a human
curl -X POST .../conversations/CONVERSATION_ID/email   -H 'content-type: application/json' -d '{"visitor_id":"v_…","email":"you@example.com","name":"Your Name"}'
curl -X POST .../conversations/CONVERSATION_ID/handoff -H 'content-type: application/json' -d '{"visitor_id":"v_…"}'

# 5. Later: read the transcript (human replies have role "human")
curl 'https://chrismai.ai/api/chat/api/widget/conversations/CONVERSATION_ID?visitor_id=v_…'

Endpoints

Method and pathWhat it does
GET /api/widget/configGreeting, contact email, whether a human is online, help articles
GET /api/widget/articles?q=Search help articles (pricing, services, process)
POST /api/widget/conversationsStart a conversation, optionally with a first message
GET /api/widget/conversationsYour recent conversations for a visitor_id
GET /api/widget/conversations/{id}State and full transcript
POST /api/widget/conversations/{id}/messagesSend a message; the bot's reply comes back in the response
POST /api/widget/conversations/{id}/handoffAsk for a human (a real person)
POST /api/widget/conversations/{id}/emailLeave a reply address
POST /api/widget/conversations/{id}/ratingThumbs up or down
GET /api/healthLiveness

Errors are JSON: {"error": "…", "code": "…"}, with 400, 403, 404, 409 (closed), 413 (too long) or 429 (rate limited).

Limits and etiquette

What is not offered

There is no payment API, account API, OAuth server, MCP server or A2A endpoint. Every project is quoted per project. There is no public checkout. Our team works remotely. Questions: support@chrismai.ai