SDKs & API
cURL
Every MemLab capability is available over plain HTTP. These snippets hit the same gateway endpoints the SDKs use — copy them into any shell or HTTP client.
- 1
Set your credentials
Export the API key you minted in the dashboard and the gateway base URL.
bashexport MEMLAB_API_KEY="your-api-key" export MEMLAB_API_URL="https://duevlcjdbpgye.cloudfront.net"
- 2
Ingest an Episodic Memory
POST raw content to /v1/episodic-memories for extraction into Semantic Memory.
bashcurl -X POST "$MEMLAB_API_URL/v1/episodic-memories" \ -H "Authorization: Bearer $MEMLAB_API_KEY" \ -H "Content-Type: application/json" \ -d '{"content":"My name is Alice and I love hiking.","episodic_memory_type":"MESSAGE"}' - 3
Search Semantic Memory
POST a query to /v1/semantic-memories/search to retrieve facts ranked by relevance.
bashcurl -X POST "$MEMLAB_API_URL/v1/semantic-memories/search" \ -H "Authorization: Bearer $MEMLAB_API_KEY" \ -H "Content-Type: application/json" \ -d '{"query":"What do I like?"}'
More integrations