FastAPI server providing HTTP endpoints for chat, status, and events.
hexis api [--host HOST] [--port PORT]Default: 127.0.0.1:43817
Optional Bearer token via HEXIS_API_KEY environment variable. If unset, no auth is required.
curl -H "Authorization: Bearer <token>" http://localhost:43817/api/statusHealth check.
Response: {"status": "ok", "checks": {"db": true}}
Rich agent status.
Response: Full status payload including identity, memory counts, energy level, heartbeat info.
Streaming chat via SSE. The primary conversation endpoint.
Request body:
{
"message": "Hello, how are you?",
"history": [],
"prompt_addenda": ""
}SSE events:
| Event | Data | Description |
|---|---|---|
phase_start |
{"phase": "string"} |
Processing phase started |
phase_end |
{"phase": "string"} |
Processing phase completed |
token |
{"phase": "string", "text": "string"} |
Streaming text delta |
log |
{"id", "kind", "title", "detail"} |
Tool call/result/memory log |
done |
{"assistant": "full_text"} |
Completion signal |
error |
{"message": "string"} |
Error occurred |
Log kinds: tool_call, tool_result, memory_recall, memory_write
Accept external webhook events (e.g., from channels or external services).
Response: {"status": "accepted", "event_id": "..."}
SSE stream of gateway events. Listens on PostgreSQL pg_notify for real-time updates.
Trigger the consent flow for a model.
Request body:
{
"role": "conscious",
"llm": {
"provider": "openai-codex",
"model": "gpt-5.2"
}
}Response: Consent decision, contract, and recorded certificate.
Configurable via HEXIS_CORS_ORIGINS env var. Default: localhost:3477, localhost:3000.
- Web UI -- the web UI that uses this API
- Docker Compose -- API server port mapping