MemMesh — persistent, self-improving memory for AI agents. Get started →
API ReferenceOverview

API Reference Overview

Most integrations talk to MemMesh through MCP or the TypeScript SDK. For direct HTTP access, this section documents the engine’s REST surface.

Base URL

  • Self-hosted engine: http://localhost:3000
  • Hosted cloud: https://app.memmesh.ai

Every REST route is project-scoped and lives under /api/v1/projects/{projectId}/…. The /api prefix is added at the gateway; the engine registers the routes under /v1/projects/{projectId}/… internally.

The MCP endpoint is mounted at <base>/api/v1/projects/{projectId}/mcp-server.

Authentication

Requests authenticate with a Bearer token in the Authorization header.

curl https://app.memmesh.ai/api/v1/projects/$PROJECT_ID/... \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json"

Read routes require the READ_MEMORY permission; write and admin routes require WRITE_MEMORY. A few surfaces are additionally entitlement-gated — see the individual pages (compliance requires the memory.compliance entitlement; the health estimators require the healthcare pack).

Endpoint reference

Every path below is relative to /api/v1/projects/{projectId}.

Memory

SurfaceEndpointReference
Observe / search / recall / save / listMCP tools on /mcp-serverMemory API
Admin list / create / confirm / promote / search/admin/memory, /admin/memory/searchMemory API
Media ingest (image / audio / doc)POST /memory/mediaMemory API
Typed attributes + accumulators/memory-typed/*Typed Attributes

Prediction & behavior

SurfaceEndpointReference
Declared-target predictionPOST /memory-intelligence/predict (send a target)Predictions API
Pattern projectionPOST /lattice/predict (no target)Predictions API
Upcoming / overdue predictionsGET /lattice/predictions/upcomingPredictions API
Behavior discoveryPOST /lattice/discoverBehavior discovery API
Behavioral profilePOST /lattice/profile, POST /memory-intelligence/profileContext & Profiles
Calibration reportGET /lattice/calibrationOutcomes & Calibration

Context, cohorts & estimators

SurfaceEndpointReference
Context bundlePOST /lattice/contextContext & Profiles
Batch context (≤500 subjects)POST /lattice/context/batchContext & Profiles
Cohort similarityPOST /lattice/cohortCohorts & Estimators
Cohort-aware predictionPOST /lattice/cohort/predictCohorts & Estimators
Estimators (bio-age)POST /lattice/estimate, POST /lattice/health/*Cohorts & Estimators

Closed-loop learning

SurfaceEndpointReference
Record a decisionPOST /lattice/decisionsOutcomes & Calibration
Record an outcomePOST /lattice/outcomesOutcomes & Calibration
List outcomesGET /lattice/outcomesOutcomes & Calibration
What workedGET /lattice/effectivenessOutcomes & Calibration

Events & alerts

SurfaceEndpointReference
Emit / poll eventsPOST /lattice/events/emit, GET /memory-eventsEvents & Alerts
Alert-rule CRUD + fires/memory-alerts/*Events & Alerts

Knowledge graph & maintenance

SurfaceEndpointReference
Point-in-time graph queryPOST /lattice/graph/queryKnowledge Graph API
Associative prefetchPOST /admin/memory/prefetch-relatedKnowledge Graph API
Reflection / insightsPOST /admin/memory/reflectKnowledge Graph API
Consolidate / dedupPOST /admin/memory/consolidate, POST /admin/memory/dedupKnowledge Graph API

Compliance

SurfaceEndpointReference
Subject export (GDPR Art. 15)POST /memory-compliance/exportCompliance API
Hard delete (GDPR Art. 17)POST /memory-compliance/hard-deleteCompliance API
Audit log / packsGET /memory-compliance/audit, GET /memory-compliance/packsCompliance API

The full, generated endpoint reference is published from the repository’s openapi.json. Most teams use the TypeScript SDK, which wraps all of the above.