Everything the portal and MCP tools do goes through the REST API. Use it for scripts, integrations, and anything a client cannot do over MCP.
#Base URL and schema
https://api.animawake.comThe full, generated reference is public:
- Swagger UI: api.animawake.com/api/docs/
- OpenAPI schema: api.animawake.com/api/schema/
This page covers the conventions the schema does not explain.
#Authentication
Send a key as a bearer token:
curl https://api.animawake.com/api/startup/ \
-H "Authorization: Bearer ent_your_key_here"Only the Authorization: Bearer header is accepted. Headers such as X-API-Key are ignored, and keys in query strings are never accepted.
#Key types
| Prefix | Acts as | Use it for |
|---|---|---|
ent_ |
One entity | Entity endpoints such as /api/moments/, /api/memory/search/, and /api/startup/. The key decides the entity, so these paths have no entity in them. |
usr_ |
You | Workspace and account endpoints under /api/families/<workspace>/..., with the same access you have in the portal. |
fam_ |
One workspace | Device endpoints. Issued to devices; you rarely need one. |
See Access tokens and keys for how to create, rotate, and revoke keys.
#Portal sessions
The portal authenticates with a session cookie. If you call the API from a browser session, send X-Animawake-Preflight: 1 on writes; it is required for requests with form, multipart, plain-text, or empty bodies. Three session endpoints also require an X-Animawake-Client header with any non-empty value: VRM upload (POST /api/vrm-library/), VRM delete (DELETE /api/vrm-library/<id>/), and voice profile upload (POST /api/families/<workspace>/<entity>/voice-profile/).
#URL shapes
- Entity endpoints:
/api/<resource>/, with anent_key. Examples:/api/moments/,/api/insights/,/api/decisions/,/api/sessions/,/api/memory/search/. - Workspace endpoints:
/api/families/<workspace-slug>/.... Examples:/api/families/<workspace>/entities/,/api/families/<workspace>/entities/<entity>/api-keys/. - Entity endpoints addressed through a workspace:
/api/families/<workspace-slug>/<entity-slug>/..., for exampleset-engine/andcontinuity/export/.
In paths and in the API, a workspace is called a family.
#Examples
Load startup context:
curl https://api.animawake.com/api/startup/ \
-H "Authorization: Bearer ent_your_key_here"Record a moment:
curl -X POST https://api.animawake.com/api/moments/ \
-H "Authorization: Bearer ent_your_key_here" \
-H "Content-Type: application/json" \
-d '{"event": "Shipped the importer", "tags": ["MILESTONE"], "date": "2026-09-27"}'Search memory:
curl -X POST https://api.animawake.com/api/memory/search/ \
-H "Authorization: Bearer ent_your_key_here" \
-H "Content-Type: application/json" \
-d '{"query": "importer launch", "limit": 5}'limit is 1 to 100 (default 10). threshold is 0 to 3 (default 1.5); lower values return only closer matches.
#Pagination
List endpoints are paginated by page number, 50 items per page:
curl "https://api.animawake.com/api/moments/?page=2" -H "Authorization: Bearer ent_your_key_here"{
"count": 134,
"next": "https://api.animawake.com/api/moments/?page=3",
"previous": "https://api.animawake.com/api/moments/?page=1",
"results": [ ... ]
}Follow next until it is null. Some endpoints return their own shape instead, such as {"tokens": [...]}; the schema shows each response.
#Errors
Errors use standard HTTP status codes and a JSON body with an error key:
{ "error": "Entity name does not match. Retirement cancelled." }Validation errors put field messages under error:
{ "error": { "name": ["This field is required."] } }A few endpoints return field messages at the top level, as {"query": ["This field is required."]}, or add extra keys next to error. Check error first, then fall back to the whole body.
| Status | Meaning |
|---|---|
400 |
The request is invalid. |
401 |
Returned by only a few endpoints, such as the budget checks, when the key is missing or invalid. |
403 |
The key is missing, invalid, expired, or deactivated, or it is valid but not allowed to do this, for example a non-owner deciding a proposal. |
404 |
Not found, or not visible to this key. |
409 |
Conflicts with current state, for example a dream already running. |
429 |
Rate limited. See below. |
503 |
A dependency is unavailable, for example embeddings for search. |
#Rate limits
Limits apply per endpoint group, counted per entity, per user, or per IP address. A limited request returns 429:
{ "error": "Request was throttled. Expected available in 42 seconds." }| Endpoints | Limit | Counted per |
|---|---|---|
| Moments, insights, search, recall, trace creation and extraction, screenshots, relevant wisdom, and the memory graph (all share one budget) | 100 per hour | Entity (or user) |
| Feedback signals | 120 per minute | Entity (or user) |
| Entity backup download | 5 per hour | User |
| Dream requests | 4 per hour | Entity |
| Device heartbeats | 20 per minute | Device |
| Connection code generation | 60 per hour | User |
Device registration with a connection code (POST /api/players/register/) |
30 per minute, plus the 60 per hour connection code limit | IP address |
| Device link codes | 6 per minute | IP address |
| Device sign-in | 30 per hour | IP address |
Device key registration (POST /api/me/entities/<id>/register-key/) |
60 per minute | User |
| Service secret delivery to devices (pending and acknowledged secrets) | 20 per minute | Caller |
| Custom service secrets | 50 per hour | User |
| Service OAuth start | 10 per hour | User |
| Service OAuth callback | 10 per hour | IP address |
| First wake conversation | 60 per hour | User |
| Budget checks | 120 per minute | Entity |
| GitHub token requests | 60 per minute | Caller (entity or workspace key) |
| Discord bridge inbound messages | 120 per minute | The bridge (one shared budget) |
| Waitlist sign-up | 10 per hour | IP address |
Resonance checks (/api/memory/check-resonance/) and reading traces have no rate limit. The MCP server has separate limits; see Connection troubleshooting.
#Useful endpoints
| Task | Endpoint |
|---|---|
| Who does this key belong to? | GET /api/identity/whoami/ |
| Startup context | GET /api/startup/, or POST /api/startup/ecphoric/ with {"mode": "alive"} |
| Save a session | POST /api/session-end/ or POST /api/sessions/ |
| Steering rules as Markdown | GET /api/context-rules/ |
| Entity keys | GET, POST /api/families/<workspace>/entities/<entity>/api-keys/; DELETE .../api-keys/<id>/ |
| OAuth connections | GET /api/families/<workspace>/mcp-access/; DELETE .../mcp-access/<id>/ |
| Revoke all access | DELETE /api/families/<workspace>/entities/<entity>/revoke-all/ |
| Backup | GET /api/families/<workspace>/entities/<entity>/backup/ |
| Continuity export | GET /api/families/<workspace>/<entity>/continuity/export/ |
| OpenAI key | GET, POST, DELETE /api/families/<workspace>/integrations/openai/ |
| Proposals | /api/self-changes/proposals/, with approve/ and reject/ actions |
The MCP tools reference is also a guide to the entity endpoints: each tool is a thin wrapper around one or two of them.