The agentmemory HTTP REST API surface, the primary protocol for talking to the memory server. Use when calling agentmemory over HTTP, when MCP is unavailable and you need a fallback, or when integrating a host that does not speak MCP.
Getting started
Full instructionsExample command
Quick start
curl -fsS http://localhost:3111/agentmemory/livezInstructions: SKILL.mdv1.0.4
REST is agentmemory's primary surface. MCP is a bridge on top of it. Every memory operation has an HTTP endpoint under http://localhost:3111/agentmemory/*.
Quick start
# liveness
curl -fsS http://localhost:3111/agentmemory/livez
# For this fixed loopback URL only. Do not print the value or enable shell tracing.
agentmemory_secret="${AGENTMEMORY_SECRET:-$(cat "$HOME/.agentmemory/secret")}"
test -n "$agentmemory_secret" || exit 1
# save
curl -fsS -X POST http://localhost:3111/agentmemory/remember \
-H "Authorization: Bearer $agentmemory_secret" \
-H "Content-Type: application/json" \
-d '{"content":"chose JWT refresh rotation","concepts":["jwt-refresh-rotation"]}'
# recall
curl -fsS -X POST http://localhost:3111/agentmemory/smart-search \
-H "Authorization: Bearer $agentmemory_secret" \
-H "Content-Type: application/json" \
-d '{"query":"auth token strategy","limit":5}'
Auth
Every endpoint except liveness requires Authorization: Bearer <secret>, including on localhost. The server always has a secret: AGENTMEMORY_SECRET when you set one, otherwise one it generates at first start. Requests without the header get 401. Liveness is public. The example uses an explicit environment secret or the generated local secret file; if the daemon uses a secret from its .env, load that value locally without displaying it. For a remote daemon, require an explicit credential for that endpoint and HTTPS. Never forward a local-file secret or follow an authenticated redirect to another host. See TROUBLESHOOTING.md.
Conventions
- Save returns
201, reads return200, validation errors return400. - Use documented fields only. A successful response does not prove an unsupported field was applied.
GET /agentmemory/sessionsfilters bystartedAfter,startedBefore,endedAfterandendedBefore.GET /agentmemory/statusreportsindex.vectorBackfillReasonwhen the vector backfill is paused.- MCP clients that connect by URL use
POST /agentmemory/mcp(MCP Streamable HTTP) with the same bearer secret. - The REST port defaults to
3111and is configurable with--portor--instance. The viewer defaults to3113; the internal engine WebSocket defaults to49134.
See also
- agentmemory-mcp-tools for the MCP equivalents.
- agentmemory-config for local configuration and the secret.
Reference
The full endpoint list with methods lives in REFERENCE.md, generated from src/triggers/ and src/mcp/.
Explore more skills
Browse all- Commit HistoryList recent git commits linked to agent sessions, optionally filtered by branch or repo. Use when the user asks "show…
- lessonSave a correction or hard-won rule as a confidence-weighted lesson that resurfaces before similar work. Use when the…
- Session HistoryShow what happened in recent past sessions on this project as a clean timeline. Use when the user asks "what did we do…
- forgetDelete selected durable memories from agentmemory after showing them and getting explicit confirmation. Use when the…
- Agentmemory ArchitectureHow agentmemory is built, the iii engine primitives it runs on, its storage model, ports, and the viewer. Use when…
- recallSearch agentmemory for past observations, sessions, and learnings about a topic using hybrid BM25 plus vector plus…
Security
Reviews (0)
More from AgentMemory
View source →Frequently asked questions about agentmemory-rest-api
What does the agentmemory-rest-api skill do?
The agentmemory HTTP REST API surface, the primary protocol for talking to the memory server. Use when calling agentmemory over HTTP, when MCP is unavailable and you need a fallback, or when integrating a host that does not speak MCP. It's a reusable SKILL.md instruction set that loads into your AI coding assistant on demand, no prompt engineering, no copy-pasting every session.
How do I install the agentmemory-rest-api skill?
Run `npx @skills-hub-ai/cli install agentmemory-rest-api` from your terminal. The CLI writes the SKILL.md to the correct location for your AI tool (e.g. ~/.claude/skills/agentmemory-rest-api/ for Claude Code or ~/.cursor/skills/ for Cursor with --target cursor) and adds it to your project's .skills.json lockfile.
Which AI tools does agentmemory-rest-api work with?
agentmemory-rest-api runs in Claude Code. It follows the open Agent Skills standard (SKILL.md), so the same skill works in every supported tool without modification.
Is the agentmemory-rest-api skill free?
Yes. Every skill on skills-hub.ai is free and open-source. There are no premium tiers, paywalls, or usage limits. You only pay for whatever AI assistant you're already using.
How do I use agentmemory-rest-api after installing it?
In Claude Code, type `/agentmemory-rest-api` (or whatever slash command the skill registers) and the AI follows the skill's instructions immediately. You can also reference it by name in natural language, your AI loads the skill into context when relevant.
Can I share the agentmemory-rest-api skill with my team?
Yes. Commit your project's .skills.json lockfile and teammates run `npx @skills-hub-ai/cli install` (no args) to install every skill at the exact version you pinned. Organization-scoped installs work via skills-hub.ai organizations.
Badge for your README
Show that this skill is on Skills Hub. The badge links back to this page and shows the live install count.
[](https://skills-hub.ai/skills/agentmemory-rest-api)<a href="https://skills-hub.ai/skills/agentmemory-rest-api"><img src="https://skills-hub.ai/api/badges/skill/agentmemory-rest-api" alt="Install on Skills Hub"></a>More options in the badge docs.