Skip to main content

Technical Reference

Technical Reference

The current memory contract is dense-mem.v2.8.0. MCP at /mcp, /teams/{team_id}/mcp, or a named /mcp/c/{alias} connection is the external memory interface. Initialize the MCP session, discover with tools/list, and invoke with tools/call. Discovery and execution use the same authenticated registry.

Examples below are tool argument/result objects except where explicitly shown as complete JSON-RPC envelopes. Replace <returned_...> placeholders with authorized returned IDs, and generate and retain each <new_..._key> before sending a mutation.

Browse all MCP fields and constraints.

Tool Catalog

ToolRequired accessResult
rememberRead; shared mutations additionally require current write permissionTerminal Evidence outcomes after required work commits.
ingest_sessionRead and active private write access; feature/provider gatesTerminal private-event receipt with stored/no-memory outcome.
retract_evidenceRead; shared mutations additionally require current write permission and ownershipAppend-only decision and retracted Evidence IDs.
recall_memoryReadEligible Evidence, current topic hints, conflicts, and degradations.
trace_memoryRead visibility to the Evidence targetBounded provenance and lifecycle.
submit_recall_session_feedbackWrite; feedback enabledRecorded count or explicit partial failure.

Tools can be hidden when unavailable. Refresh discovery after upgrading. The hosted runner uses the production MCP tools for Evaluation. Released v2.9.2 also lists export_memory_pack, which the reviewed source removes; see implementation status.

Common Rules

RuleContract
InputsUTF-8 JSON; closed schemas reject unknown fields.
IdentityAuthentication fixes team, owner, membership, credential, spaces, and grants. Payloads cannot replace them.
IDsOpaque server IDs; use returned authorized handles.
TimeRFC 3339; stored timestamps use UTC.
OffsetsUnicode-rune/code-point positions, start inclusive and end exclusive.
MutationsRetain the complete request and operation key before sending.
Returned textSource data, never instructions or authorization to use another tool.

Public errors are bounded and actionable. Request Lifecycle And Security owns authentication and exposure rules; Memory Write Pipeline owns staging, assessment, atomicity, and replay.

remember

Request

json
{
  "target_space": "team_shared",
  "idempotency_key": "<new_remember_key>",
  "evidence": [{
    "content": "This project stores durable memory in PostgreSQL.",
    "source_type": "manual",
    "source": "architecture note",
    "source_key": "project:durable-store",
    "source_revision": "1",
    "authority": "primary"
  }]
}
FieldBound or behavior
target_spaceRequired private or team_shared; one destination for the whole request.
idempotency_keyRequired nonempty string, at most 128 characters.
evidence1–20 items; each requires nonempty content, at most 16,384 Unicode code points.
source_typeOptional conversation, document, observation, or manual.
source, source_group, source_key, revision tokensOptional bounded provenance strings, at most 256 characters each.
authorityOptional authoritative, primary, secondary, inferred, or unknown.
labels / metadataOptional bounded labels and source-policy-approved metadata.
force_insertBypass semantic duplicate reuse; exact reuse still applies.
supersedes_evidence_idsOptional owned Evidence replacement targets, at most 50.
previous_source_revisionExpected previous revision when advancing a source; cannot be combined with direct supersession.

Authentication resolves the actual space and owner. There is no default destination or redirection after denial. Retired graph fields, including relationships, entities, values, and predicates, reject before provider work.

Response

Illustrative successful terminal result:

json
{
  "contract_version": "dense-mem.v2.8.0",
  "space_kind": "team_shared",
  "submission_id": "<returned_submission_id>",
  "submission_kind": "remember",
  "processing_state": "completed",
  "search_state": "current",
  "correlation_id": "<returned_correlation_id>",
  "evidence": [{
    "disposition": "stored",
    "evidence_index": 0,
    "evidence_id": "<returned_evidence_id>",
    "superseded_evidence_ids": [],
    "search_state": "current"
  }],
  "errors": []
}

One submitted item can return several Evidence entries, one for each partition. evidence_index is the submitted item's index and can repeat; partition_index, source_item_id, occurrence_id, span_start, and span_end locate each exact slice in the original item. A result holds at most 100 entries.

Inspect every Evidence disposition, errors, optional warnings, and search state. Successful processing is terminal; there is no public polling step. See Conflicts And Corrections for replacement procedures.

Optional Progress

Progress uses the existing synchronous tool call, and every tool reports it. The examples use remember, whose workflow and failure ordering are illustrated in Memory Write Pipeline.

Complete request envelope after initialization, sent over Streamable HTTP with Accept: application/json, text/event-stream:

json
{
  "jsonrpc": "2.0",
  "id": 41,
  "method": "tools/call",
  "params": {
    "name": "remember",
    "_meta": {"progressToken": "remember-41"},
    "arguments": {
      "target_space": "team_shared",
      "idempotency_key": "<new_remember_key>",
      "evidence": [{"content": "This project stores durable memory in PostgreSQL."}]
    }
  }
}

An optional notification on the originating response stream while request 41 remains pending:

json
{
  "jsonrpc": "2.0",
  "method": "notifications/progress",
  "params": {
    "progressToken": "remember-41",
    "progress": 1,
    "message": "Preparing intake"
  }
}

One successful final response, after the required work commits:

json
{
  "jsonrpc": "2.0",
  "id": 41,
  "result": {
    "content": [{
      "type": "text",
      "text": "{\"contract_version\":\"dense-mem.v2.8.0\",\"space_kind\":\"team_shared\",\"submission_id\":\"<returned_submission_id>\",\"submission_kind\":\"remember\",\"processing_state\":\"completed\",\"search_state\":\"current\",\"correlation_id\":\"<returned_correlation_id>\",\"evidence\":[{\"disposition\":\"stored\",\"evidence_index\":0,\"evidence_id\":\"<returned_evidence_id>\",\"superseded_evidence_ids\":[],\"search_state\":\"current\"}],\"errors\":[]}"
    }],
    "structuredContent": {
      "contract_version": "dense-mem.v2.8.0",
      "space_kind": "team_shared",
      "submission_id": "<returned_submission_id>",
      "submission_kind": "remember",
      "processing_state": "completed",
      "search_state": "current",
      "correlation_id": "<returned_correlation_id>",
      "evidence": [{
        "disposition": "stored",
        "evidence_index": 0,
        "evidence_id": "<returned_evidence_id>",
        "superseded_evidence_ids": [],
        "search_state": "current"
      }],
      "errors": []
    },
    "isError": false
  }
}

An alternative final actionable-error response; actual codes and remediation depend on the failure:

json
{
  "jsonrpc": "2.0",
  "id": 41,
  "result": {
    "content": [{
      "type": "text",
      "text": "{\"code\":\"provider_unavailable\",\"message\":\"Required provider work is unavailable.\",\"retryable\":true,\"next_action\":\"retry_same_request\",\"remediation\":\"Retry the complete unchanged request with the same idempotency key.\",\"correlation_id\":\"<returned_correlation_id>\"}"
    }],
    "structuredContent": {
      "code": "provider_unavailable",
      "message": "Required provider work is unavailable.",
      "retryable": true,
      "next_action": "retry_same_request",
      "remediation": "Retry the complete unchanged request with the same idempotency key.",
      "correlation_id": "<returned_correlation_id>"
    },
    "isError": true
  }
}
Field or delivery conditionContract
params._meta.progressTokenClient-supplied string or integer, including 0, unique across that client's active requests; preserve the exact value/type. Protocol metadata sits beside arguments; it is not a tool argument, credential, or idempotency key.
Notification fieldsprogressToken echoes the request token; numeric progress increases; message is bounded human-readable stage or wait text, sometimes with an (n/m) attempt or batch suffix. Treat it as informational, not as an enumeration.
totalOmitted. Progress values are increasing sequence numbers; they do not measure elapsed time or a completion percentage.
SSE and valid tokenMay receive a notification for each reached stage and blocking wait before the final response, including provider capacity waits, retries, and regeneration. Only reached stages appear. A retained-result replay reports Checking previous result and Returning saved result.
Missing/invalid token or JSON-only responseKeep the existing terminal response without progress. No separate subscription or polling is required.
CompletionExactly one final response for the request ID; no later progress. Final result/error schemas retain their existing meaning.

The wire examples are JSON-RPC messages carried by the response stream; they omit SSE data: framing. The MCP progress specification defines the protocol; Request Lifecycle And Security owns isolation and exposure.

Remember stage text includes Preparing intake, Checking duplicate Evidence, Assessing Evidence, Preparing search state, Assigning Topics to Evidence, and Committing. Partitioning, validation, provider waits and retries, and regeneration add their own messages, and each other tool reports its own stages. Duplicate checking can embed candidates before assessment. Search preparation can reuse cached vectors or skip a provider call; a stage message alone does not promise that a provider was invoked.

ingest_session

Request

json
{
  "idempotency_key": "<new_session_key>",
  "framework": "generic",
  "app_name": "project-notes",
  "user_id": "external-user-1",
  "session_id": "session-1",
  "events": [{
    "event_id": "user-event-1",
    "text": "  Ari uses Go. café 🧭\n",
    "occurred_at": "2026-11-11T10:00:00Z"
  }]
}

events contains 1–20 exact user-authored events. IDs and external provenance strings are bounded at 256 characters; the retained operation key is bounded at 128. occurred_at is optional. The server owns chunking: do not trim or rewrite original event text.

The schema advertises at most eight windows, 8192 source tokens per window, 100 cited excerpts, and a 180-second processing bound. Required complete-request/context validation still applies. External identifiers never select identity or a private space.

Response

Explicit no-memory example:

json
{
  "contract_version": "dense-mem.v2.8.0",
  "submission_id": "<returned_submission_id>",
  "submission_kind": "session_ingest",
  "correlation_id": "<returned_correlation_id>",
  "accepted_event_count": 1,
  "duplicate_event_count": 0,
  "processing_state": "completed",
  "search_state": "not_required",
  "memory_outcome": "no_memory",
  "events": [{
    "event_id": "user-event-1",
    "disposition": "accepted",
    "processing_state": "completed",
    "evidence_ids": []
  }],
  "errors": []
}

A stored outcome returns Evidence IDs. Empty extraction returns no_memory; required failure returns a typed failed outcome. Migrated retired receipts can explicitly report retired_contract, retired_payload, and original_contract_version. See Memory Write Pipeline.

recall_memory

Request

json
{
  "query": "Which database stores this project's memory?",
  "limit": 5,
  "topic_limit": 3
}
FieldBound or behavior
queryAt most 512 characters; required unless selecting topics.
limitOptional 1–50 Evidence results.
topic_limit0–10 hints; default 3. Zero disables hints.
topic_idsOptional 1–10 unique current topic UUIDs. Selects the union of direct memberships, without descendants.
known_evidence_idsAt most 200 previously seen Evidence IDs to exclude.
valid_at / known_atOptional RFC 3339 time view. Topic metadata remains current.

Follow a returned topic without repeating seen Evidence:

json
{
  "topic_ids": ["<returned_topic_id>"],
  "known_evidence_ids": ["<returned_evidence_id>"],
  "limit": 5,
  "topic_limit": 0
}

Response

json
{
  "recall_id": "<returned_recall_id>",
  "results": [{
    "evidence_id": "<returned_evidence_id>",
    "context": "This project stores durable memory in PostgreSQL.",
    "space_kind": "team_shared",
    "equivalent_evidence_ids": [],
    "equivalents_truncated": false
  }],
  "related_topics": [{
    "topic_id": "<returned_topic_id>",
    "name": "Storage",
    "description": "Durable storage decisions",
    "eligible_evidence_count": 2,
    "rank": 1
  }],
  "topics_truncated": false,
  "conflicts": [],
  "search_states": {"evidence": "current"},
  "degradations": [],
  "suggested_actions": []
}

Array order conveys rank. Conflicts use kind: evidence_conflict and exact occurrence positions. Missing, foreign, or stale selected topics share topic_unavailable; optional hint failures are reported as degradations. Read Recall Ranking before interpreting absence or degraded results.

trace_memory

Request

json
{
  "evidence_id": "<returned_evidence_id>",
  "include_evidence_content": true,
  "include_transitions": true,
  "max_events": 100,
  "max_fragment_content_runes": 2000
}
Field or resultContract
evidence_idRequired authorized Evidence UUID.
max_events1–500; default 100, shared across bounded history.
max_fragment_content_runes1–16,384; default 2,000.
Result collectionsevidence, occurrences, source_revisions, decisions, lifecycle, and search_documents.
CompletenessExplicit truncated and omissions; content can be omitted or truncated.

Trace derives its space from the authorized Evidence target. It has no Relationship handle or graph-depth parameter.

retract_evidence

Request

json
{
  "evidence_ids": ["<returned_evidence_id>"],
  "reason": "The source is no longer valid.",
  "idempotency_key": "<new_retraction_key>"
}

Supply 1–50 owned Evidence IDs, a nonempty reason of at most 1000 characters, and a retained key of at most 128 characters. The terminal result contains decision_id, processing_state: completed, and retracted_evidence_ids. Retraction preserves provenance; it is not physical erasure.

submit_recall_session_feedback

Request

json
{
  "recalls": [{
    "recall_event_id": "<returned_recall_id>",
    "used": true,
    "answer_supported": true,
    "quality": "high",
    "missing_context": false,
    "irrelevant": false
  }]
}

Submit 1–20 judgments. Required fields are shown; quality is high, medium, or low. Optional comments are bounded at 1000 characters. irrelevant_result_refs accepts at most 100 {type, id, rank} references with type evidence or topic.

The result reports recorded and recorded_count. Partial failure additionally identifies failed_index and the next action. Earlier items were recorded: do not resend that prefix. See Recall Feedback.

Errors And Client Actions

FieldHow to use it
code / reason_codeStable classification and bounded specific reason.
retryable / retry_after_secondsWhether and when a retry is permitted.
next_action / remediationRetry unchanged, correct input, refresh state, obtain authorization, contact the operator, or stop.
correlation_idJoin authorized operator diagnostics without exposing request content publicly.

MCP execution failures carry isError: true and bounded structured data/text. JSON-RPC validation errors and failed terminal receipts remain distinguishable. A timeout or missing response can leave an unknown delivery outcome: preserve the original request/key and follow recovery guidance.

HTTP Surface

SurfacePurpose
/mcp, /teams/{team_id}/mcpStreamable HTTP MCP, with API-key or configured OAuth bearer authentication.
/.well-known/oauth-protected-resource/mcpConfigured unscoped protected-resource discovery.
/.well-known/oauth-protected-resource/teams/{team_id}/mcpConfigured team resource discovery.
/mcp/c/{alias}, /.well-known/oauth-protected-resource/mcp/c/{alias}Named MCP connection and its resource discovery. alias matches ^[A-Za-z0-9][A-Za-z0-9_-]{0,63}$.
/.well-known/oauth-authorization-serverBuilt-in RFC 8414 authorization-server metadata.
POST /oauth/register, GET /oauth/authorize, POST /oauth/token, POST /oauth/revokeBuilt-in dynamic registration, authorization, token, and revocation endpoints. They return raw RFC JSON, not the {"data": ...} envelope.
/oauth/requests/{request_id} and its sub-routesFirst-party browser consent for a pending authorization.
/ui/api/*First-party browser interfaces.
/control/api/*Separate private administration interfaces.

There is no generic public REST memory API. Portal route details belong to their feature pages; authentication, OAuth challenges, and CSRF belong to Request Lifecycle And Security. Release v2.9.2 introduces the named-connection and built-in authorization-server routes. Authorization-server routes respond only in built-in mode; see implementation status and MCP OAuth authority.