Chat
The main entrypoint — query in, A2UI components out.
/chat is the primary endpoint. The shell sends a user query; the agent returns a list of
A2UI components to render.
Request
messagestringrequiredThe user's natural-language query.
{ "message": "show me the weather in Tokyo" }curl -X POST http://127.0.0.1:8000/chat \
-H "Content-Type: application/json" \
-d '{"message": "show me the weather in Tokyo"}'Response
The response carries a components array — each item is an A2UI
component tree the shell renders.
{
"components": [
{ "type": "live_weather", "city": "Tokyo" }
]
}For multi-step actions, the response instead contains a task_tracker component
summarizing each workflow step:
{
"components": [
{
"type": "task_tracker",
"data": {
"status": "completed",
"steps": [
{ "step": 1, "tool": "SEARCH_WEB", "status": "completed", "message": "..." },
{ "step": 2, "tool": "SEND_EMAIL", "status": "completed", "message": "..." }
]
}
}
]
}What happens internally
See Data Flow for the full walk-through.
Fast-path commands
These prefixes return prebuilt components without an LLM call:
| Input | Returns |
|---|---|
df | Disk usage |
free | RAM usage |
ps | Top-processes table |
telepath / demo | Telepath demo cards (--cards=a,b to filter) |
who is … / profile of … / bio of … | Generated profile UI |
Streaming
POST /chat/stream is the streaming counterpart, used when responses should arrive
incrementally. JIT widgets push their ongoing updates separately over the Unix socket rather
than through this endpoint.
Confirming unsafe actions
When a step requires approval (e.g. a custom_agents/ plugin with is_safe = False), the
agent returns a confirmation request. Approve it via:
curl -X POST http://127.0.0.1:8000/api/confirm \
-H "Content-Type: application/json" \
-d '{"confirmation_id": "...", "approved": true}'