Create a store
POST/api/v1/memory/collection
In the SDKs: create_store
Stores are explicit: a store must exist before you write to or read it. Idempotent. Every account starts with a built-in "default" store.
Authentication
Every call carries your API key in an X-API-Key header. Keys are created in the console.
Request body
JSON, required. Out-of-range values are refused with a 400 rather than quietly clamped.
user_idstring requiredThe store to operate on. Stores are explicit: create one first or use the built-in "default".
Returns
The 200 body. Fields nested one level are shown as parent.child.
user_idstringstatus"exists"
Example
curl -X POST https://api.wontopos.com/api/v1/memory/collection \
-H "X-API-Key: $WOS_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'Status codes
| Status | Meaning |
|---|---|
| 200 | Already existed (idempotent). |
| 201 | Created. |
| 400 | user_id longer than 128 characters. |
| 401 | Missing or invalid API key. |
| 429 | Rate limited (per-account, per-tier RPM). Retry after the indicated delay. |
Rate limits per tier and the full status list are in Errors & limits.
In the SDKs
The Python, TypeScript, and Rust SDKs wrap this endpoint so you do not build the request by
hand — pip install wontopos, npm i wontopos, or cargo add wontopos, then the method list is on the SDK reference. A coding agent can take the whole API in one file
at llms.txt, or over MCP with npx -y wontopos-mcp.