agentmemory-rest-api
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.
How do I install this agent skill?
npx skills add https://github.com/rohitg00/agentmemory --skill agentmemory-rest-apiIs this agent skill safe to install?
- Gen Agent Trust Hubpass
The skill facilitates access to a local memory server via a REST API. It correctly advises on best practices for secret management, such as using environment variables and local files, while cautioning against printing credentials. It uses localhost for communication and has built-in instructions to avoid exfiltrating local secrets to remote hosts. The 'low' verdict is assigned due to the inherent indirect prompt injection surface present in any skill that processes and stores external data into an agent's memory.
- Socketpass
No alerts
- Snykpass
Risk: LOW · No issues
What does this agent skill do?
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
Protected endpoints require bearer authentication by default, including localhost. 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.
- The port is configurable with
--portor--instance; streams, viewer, and engine derive from it.
See also
- agentmemory-mcp-tools for the MCP equivalents.
- agentmemory-config for the port quartet and the secret.
Reference
The full endpoint list with methods lives in REFERENCE.md, generated from src/triggers/api.ts.
How can the creator link this skill?
Add the canonical catalog link to the repository README so users can inspect current installs and available audits. The publishing guide covers the complete discovery path.
<a href="https://skillzs.dev/skills/rohitg00/agentmemory/agentmemory-rest-api">View agentmemory-rest-api on skillZs</a>