Mac & WebTechnical

API keys & SDK

Create a key for your own code, use the Python or TypeScript client, and find the machine-readable docs.

API keys

An API key lets a script or tool read and write one workspace without signing in. You send it as Authorization: Bearer <key>, to the REST API under /v1 or to the MCP endpoint.

  1. 1On the web, switch to the workspace in the sidebar and open Settings → Workspace. Only admins see API keys.
  2. 2Click New key, give it a name and click Create.
  3. 3Copy the key now. It is shown once.
  4. 4To remove a key, hover over it in the list and click Revoke.
  • Scope: a key belongs to the workspace you created it in and gets the same permission as you: admin, read write or read only. The list shows each key’s permission and when it was last used.
  • Keys are stored hashed, so Esment cannot show one again.
  • On the Mac: extra keys for the local store are in Settings → Connection → API keys, separate from the admin token above them.
Roles and seats, and who can manage keys, are explained on the workspaces page.

SDKs

There are two clients in the repository, one for Python and one for TypeScript. Both talk to the REST API and take a base URL and an API key.

  • Python (esment-sdk): sync and async clients (Esment, AsyncEsment), typed models and errors. Needs Python 3.10 or later. Install from source with pip install -e sdks/python.
  • TypeScript (memoria-sdk): zero-dependency client, MemoriaClient, for Node.js 18 or later. Install from source with npm install ./sdks/typescript.
python
from esment import Esment

client = Esment(base_url="http://localhost:8080", api_key="cos_xxx")

client.add_memory("The user prefers Python", tags=["preference"], space="user")
for r in client.search(query="language preferences", top_k=10):
    print(r.score, r.memory.content)
typescript
import { MemoriaClient } from "memoria-sdk";

const client = new MemoriaClient({ baseUrl: "http://127.0.0.1:8080", apiKey: "your-api-key" });
const id = await client.addMemory({ content: "Rust is a systems language", tags: ["rust"] });
const results = await client.search("systems programming", { top_k: 5 });

Both cover memories (add, list, update, forget), search, time travel, events, entities and the commit history.

Whether the packages are published on PyPI and npm under these names is not confirmed, so install from source for now. The TypeScript README’s default address is port 3434, while the Mac app listens on 8080: pass your own base URL.

llms.txt

For tools that read documentation, Esment publishes two plain-text files. /llms.txt is an index of the site and the guide. /llms-full.txt has expanded product content plus the full text of the essays and newsroom posts in one file, so a model can read it in one request.

Was this page helpful?
Updated Oct 31, 2026