---
title: "Create a store"
method: POST
path: "/api/v1/memory/collection"
tags: ["stores"]
---

# Create a store

`POST /api/v1/memory/collection`

## Request

- Base URL: `https://api.wontopos.com`
- URL: `https://api.wontopos.com/api/v1/memory/collection`
- Auth: API key in header `X-API-Key`

Stores are explicit: a store must exist before you write to or read it. Idempotent. Every account starts with a built-in "default" store.

## Request body

- object
  - `user_id` string, required: The store to operate on. Stores are explicit: create one first or use the built-in "default". Use the id the store was created with: 1-64 ASCII letters, digits, ., _ or -, starting with a letter or digit. Ids that differ only by case name one store.

## Response `200`

Already existed (idempotent).

- object
  - `user_id` string
  - `status` 'exists'
  - `canonical_id` string: Present when the id is stored in a normalized form.
  - `note` string

## Other responses

- `201`: Created.
- `400`: The id is not 1-64 ASCII letters, digits, ., _ or -, starting with a letter or digit (an email address, for example).
- `401`: Missing or invalid API key.
- `409`: An existing store's id differs from this one only by punctuation.
- `429`: Rate limited (per-account, per-tier RPM). Retry after the indicated delay.

---

[API](https://skmtc.dev/wontopos/apis/wontopos-memory-api.md) · [All operations](https://skmtc.dev/wontopos/apis/wontopos-memory-api/llms.txt) · [OpenAPI document](https://skmtc.dev/wontopos/apis/wontopos-memory-api/revisions/48dda7326a33?raw)
