API-first
The memory API that can't leak.
first-call.sh
curl -X POST https://api.memrail.com/v1/memory/write \
-H "Authorization: Bearer mk_live_a83f…" \
-d '{"client":"northwind_legal","content":"…"}'
# → 200
# { "chunk_hash": "sha256:3f9a…c21b" }import { Memrail } from 'memrail';
const m = new Memrail('mk_live_a83f…');
await m.memory.write({
client: 'northwind_legal',
content: 'Renewal clause §12…',
});
const r = await m.memory.read({
client: 'northwind_legal',
query: 'contract renewal terms',
});
// → { chunks: [{ hash, score: 0.91 }], client }MethodPathPurpose
POST/v1/memory/writeWrite a client-stamped chunk
GET/v1/memory/readRead with client assertion
POST/v1/memory/searchSemantic search within a client
DEL/v1/memory/[id]Delete a chunk (client-scoped)
POST/v1/delegationsInitiate a signed handoff
GET/v1/clientsList & provision client boundaries
mcp.json
{
"mcpServers": {
"memrail": {
"command": "npx",
"args": ["-y", "@memrail/mcp"],
"env": { "MEMRAIL_API_KEY": "mk_live_a83f…" }
}
}
}