Memory API — reference
Every operation of the agent protocol with its access level, parameters and response shape, rendered from the tool table and the OpenAPI document.
Generated by scripts/gen_skill_reference.py from docs/openapi/agent-protocol.json and the tool table. Do not edit by hand.
Base URL https://api.app.membase.com. Every request: Authorization: Bearer <developer key or consent token>. MCP endpoint https://api.app.membase.com/mcp-http (Streamable HTTP): the same tools by the same names, with the same arguments and answers. No request names a Memory.
Access levels
Section titled “Access levels”| Level | Tools |
|---|---|
Read (read) |
search_memories, list_memories, get_memory, list_profile_facts, list_documents, get_document, list_media, get_media, search_media, ask_memory |
Read & write (suggest) |
search_memories, list_memories, get_memory, add_memory, list_profile_facts, add_profile_fact, list_documents, get_document, add_document, list_media, get_media, search_media, ask_memory |
Full access (manage) |
search_memories, list_memories, get_memory, add_memory, forget_memory, list_profile_facts, add_profile_fact, forget_profile_fact, list_documents, get_document, add_document, delete_document, list_media, get_media, search_media, delete_media, ask_memory |
A level is the ceiling of what a credential of that kind may hold. The profile tools and ask_memory are held only when a credential’s tool list names them: a developer key gets the profile when the owner ticks it — reading at Read, keeping a statement at Read & write, forgetting one at Full access; ask_memory is what a marketplace buyer holds, and only that. A consent-minted client holds search_memories (the fact list and reads stand on it), the media reads (list_media, get_media, search_media) and, when ticked, list_profile_facts — nothing else. A verb outside a credential’s tools is not offered in tools/list and is refused with 403 when called.
Tools and endpoints
Section titled “Tools and endpoints”get_capabilities — What this connection can do
Section titled “get_capabilities — What this connection can do”any credential; read-only.
GET /v1/capabilities
The actions this credential holds (actions: search, memories.list, profile_facts.list, …), the Memories it reaches (memories, by name and kind, never by id), the standing rules for using them (rules: citation_required, retention_notice, version) and the features on here. It is not permission: every call is still checked when made.
search_memories — Search memories
Section titled “search_memories — Search memories”level Read; read-only.
POST /v1/search
Passages the Memories in reach hold on a question, most relevant first. A Memory that could not answer, or whose passages all lost to limit, is named in partial.
| Field | Type | Required | Description |
|---|---|---|---|
limit |
integer or null | no | How many passages in all. |
mode |
string | no | full: the engine’s whole retrieval. fast: one round, no model call. |
q |
string | yes | The question, in natural language. |
list_memories — List memories
Section titled “list_memories — List memories”level Read; read-only.
GET /v1/memories
The newest facts the Memories in reach hold — newest by when it happened, the engine’s own order. has_more says more were left out; a Memory that could not answer is named in partial and the others are still listed.
| Field | Type | Required | Description |
|---|---|---|---|
limit (query) |
integer or null | no | How many, newest first: 1–1000, default 100. |
get_memory — Get one memory
Section titled “get_memory — Get one memory”level Read; read-only.
GET /v1/memories/{memory_id}
One fact, of any age — a search can name one older than any list shows.
| Field | Type | Required | Description |
|---|---|---|---|
memory_id (path) |
string | yes |
add_memory — Add a memory
Section titled “add_memory — Add a memory”level Read & write.
POST /v1/memories/add
Save one fact into this credential’s write target. The answer is the note it was written as — a document of kind note; poll GET /v1/documents/{id} for its learning.
| Field | Type | Required | Description |
|---|---|---|---|
content |
string | yes | The fact, as said. |
title |
string | no |
forget_memory — Forget a memory
Section titled “forget_memory — Forget a memory”level Full access; destructive — confirm=true from a developer key, or a request.
POST /v1/memories/{memory_id}/forget
Forget one learned fact; the material it was learned from stays.
| Field | Type | Required | Description |
|---|---|---|---|
memory_id (path) |
string | yes | |
confirm (query) |
boolean | no | True to carry it out (a Full access developer key). |
list_profile_facts — List the user’s profile
Section titled “list_profile_facts — List the user’s profile”level Read; read-only; held only when named.
GET /v1/profile-facts
Who the user is: their standing statements, newest first, each with where it came from (source_kind: user_stated, imported or model_generated).
| Field | Type | Required | Description |
|---|---|---|---|
limit (query) |
integer or null | no | How many, newest first: 1–1000, default 100. |
add_profile_fact — Add a profile fact
Section titled “add_profile_fact — Add a profile fact”level Read & write; held only when named.
POST /v1/profile-facts/add
Keep one standing statement about the user. The same statement again keeps the one already there (created: false).
| Field | Type | Required | Description |
|---|---|---|---|
content |
string | yes | One standing statement about the user. |
forget_profile_fact — Forget a profile fact
Section titled “forget_profile_fact — Forget a profile fact”level Full access; destructive — confirm=true from a developer key, or a request; held only when named.
POST /v1/profile-facts/{fact_id}/forget
Forget one profile fact. There is no editing one: to correct it, add the new statement and forget the old.
| Field | Type | Required | Description |
|---|---|---|---|
fact_id (path) |
string | yes | |
confirm (query) |
boolean | no | True to carry it out (a Full access developer key). |
list_documents — List documents
Section titled “list_documents — List documents”level Read; read-only.
GET /v1/documents
The material the Memories in reach were given, newest first; every kind unless kind narrows it (a kind added later is listed too).
| Field | Type | Required | Description |
|---|---|---|---|
kind (query) |
string or null | no | file (a file or page) or note (a fact as said); omit for both. |
limit (query) |
integer or null | no | How many, newest first: 1–1000, default 100. |
get_document — Get one document
Section titled “get_document — Get one document”level Read; read-only.
GET /v1/documents/{document_id}
One document, with how far each Memory got in learning it.
| Field | Type | Required | Description |
|---|---|---|---|
document_id (path) |
string | yes |
add_document — Add a document
Section titled “add_document — Add a document”level Read & write.
POST /v1/documents/add
Hand in a document (text or a url) to this credential’s write target.
| Field | Type | Required | Description |
|---|---|---|---|
content |
string or null | no | The document’s full text. |
custom_id |
string | no | Your own id; adding the same custom_id again is a no-op. |
title |
string | no | |
url |
string or null | no | A public web address to fetch instead. |
delete_document — Delete a document
Section titled “delete_document — Delete a document”level Full access; destructive — confirm=true from a developer key, or a request.
POST /v1/documents/{document_id}/delete
Withdraw a document and what every Memory learned from it.
| Field | Type | Required | Description |
|---|---|---|---|
document_id (path) |
string | yes | |
confirm (query) |
boolean | no | True to carry it out (a Full access developer key). |
list_media — List photos and videos
Section titled “list_media — List photos and videos”level Read; read-only.
GET /v1/media
The photos and videos the media Memories in reach hold, newest first.
| Field | Type | Required | Description |
|---|---|---|---|
limit (query) |
integer or null | no | How many, newest first: 1–1000, default 100. |
get_media — Get one photo or video
Section titled “get_media — Get one photo or video”level Read; read-only.
GET /v1/media/{media_id}
One photo or video with its moments: shots and spoken lines with their times, speakers and thumbnails.
| Field | Type | Required | Description |
|---|---|---|---|
media_id (path) |
string | yes |
search_media — Search photos and videos
Section titled “search_media — Search photos and videos”level Read; read-only.
POST /v1/media/search
Photos and videos matching what was seen or said, best first, each with the moments that matched (a shot or a spoken line, its time and speaker).
| Field | Type | Required | Description |
|---|---|---|---|
kind |
string or null | no | Omit for both. |
limit |
integer or null | no | How many items in all. |
q |
string | yes | What was seen or said, in any language. |
delete_media — Delete a photo or video
Section titled “delete_media — Delete a photo or video”level Full access; destructive — confirm=true from a developer key, or a request.
POST /v1/media/{media_id}/delete
Forget a photo or video and remove its file.
| Field | Type | Required | Description |
|---|---|---|---|
media_id (path) |
string | yes | |
confirm (query) |
boolean | no | True to carry it out (a Full access developer key). |
ask_memory — Ask the memory
Section titled “ask_memory — Ask the memory”level Read; read-only; held only when named.
POST /v1/ask
One answer from the memory itself — the engine reads the Memories in reach and answers once, with no agent and no tools. The citations name the Memory the answer came from, never the passages.
| Field | Type | Required | Description |
|---|---|---|---|
message |
string | yes | The question to answer. |
Retired names
Section titled “Retired names”Grant names credentials minted earlier still hold; each covers its current name.
| Retired | Current |
|---|---|
memory_recall |
search_memories |
memory_remember |
add_memory |
memory_ingest |
add_document |
memory_list_sources |
list_documents |
memory_forget |
delete_document |
get_profile |
list_profile_facts |
ask_agent |
ask_memory |
agent_invoke |
ask_memory |
Errors
Section titled “Errors”| Status | Code | When |
|---|---|---|
| 400 | validation |
an empty q; both or neither of content and url; a limit out of range |
| 403 | unauthorized |
a verb above the credential’s access level, or one it does not hold at all (a consent client’s delete, a buyer’s search) |
| 404 | not_found |
an id that is not this credential’s to read: outside its reach, deleted, or not one of ours |
| 422 | validation |
a malformed body: a field missing, of the wrong type, or unknown (container included) |
| 422 | write_target_required |
a write from a credential that reaches several Memories |
| 422 | capability_unavailable |
the account’s memory cannot run a turn here (no model) |
| 428 | confirmation_required |
a destructive verb without confirm=true; nothing changed, and details.id names the target |
| 429 | rate_limited |
the account’s concurrent-turn budget, or too many requests on one credential |
Read code, not only the status: 422 is several.