Skip to main content
Use these routes to inspect runtime state and operate a configured instance. Health, ingest readiness, work completion, and claim correctness are separate observations. Read the relevant result fields rather than using HTTP success alone as a readiness or completion check.

Managed Runtime Status

GET /v1/runtime/status

Returns bootstrap/configuration state plus semantic-ingest readiness for the managed runtime.
Use this endpoint to distinguish:
  • Meerkat Recall unreachable
  • reachable but not configured
  • configured but not ingest-ready
  • fully semantic-ingest ready
config_path and private worker diagnostics are not exposed here. This route requires authentication and read:status (retained alternatives read:system or read:space_config), plus current space-grant attenuation when applicable. Only /v1/health is unauthenticated liveness. /v1/readiness reports 200/503 for the runtime role; /v1/spaces/{space}/status separately reports named-space provider and guidance capabilities.
boolean
required
Whether Meerkat Recall has a persisted config or equivalent env-driven runtime configuration.
boolean
required
True when Meerkat Recall is exposing only bootstrap-safe runtime surfaces.
string
required
One of local_memory, shared_memory, read_only, or maintenance.
boolean
required
Whether the currently configured storage backend is live.
boolean
required
Whether managed background worker loops are running.
boolean
required
Whether the semantic extractor is reachable and healthy.
boolean
required
Whether the configured worker/extractor path can currently process semantic ingestion. Durable API admission can remain available while this is false; this does not certify any source revision complete.
array
required
Machine-readable readiness problems such as semantic_extractor_unavailable.

Health

GET /v1/health

Reports process liveness without authentication, storage, worker or provider checks. It remains live while the runtime drains or recovers.
Use authenticated /v1/readiness for runtime readiness and named-space status for configured capabilities. A live process is not a successful database, provider, recovery or source-publication check.

Capabilities

GET /v1/capabilities

Returns the server’s capabilities including supported policies, installed extensions, and feature flags.
features are derived from the caller-visible MCP capability surface. For example, embedded_snapshots only appears when the current principal can use snapshot tools.

Managed Snapshots

CLI and HTTP export/restore support elephant-db and retained surreal-db. MCP snapshot tools remain advertised only for globally authorized embedded hosts. Export request (configure ELEPHANT_SNAPSHOT_DIR=/backups on the server):
Restore requires {"path":"/backups/nightly-UNIQUE"}. Success includes success, backend, path, message and manifest. The immutable directory contains manifest.json and data.snapshot, format recall-snapshot-v1: version, backend, original journal identity, snapshot identity/name, creation/expiry, byte length and SHA-256. Existing export directories are refused. The payload is the selected backend’s real snapshot/export, not a generic legacy migration; restore requires the same backend and original independent journal. Paths are on the server within ELEPHANT_SNAPSHOT_DIR (default server working directory .elephant-snapshots). Export needs a global read:system principal; restore needs global write:system. A named-space service token cannot operate a whole-store backup. The compatibility CLI name elephant and positional path spellings remain, but consumers of an old single JSON file must adapt to the manifest/payload directory. Export pauses admission/scheduling and drains running work before exclusive capture. Quiescence defaults to 30 seconds (maximum 60); retention defaults to 7 days (maximum 30). A request timeout is an uncertain outcome: inspect the operator result before retrying. Restore replaces the selected database/store under an exclusive barrier, including nonempty SurrealDB databases. A failed or interrupted restore stays unready until durable erasure replay, attempt fencing and final persistence finish. Native private-guard migration 039 initialization belongs to explicit migration; privileged restore reinstalls required current and historical guards under its barrier, never ordinary serve-time schema DDL. See deployment snapshots for CLI commands and bounded retention/cleanup. A successful export is not by itself a passing restore or source-erasure qualification receipt.

Spaces

Space configuration stores embedding policy and optional extraction guidance. These routes use space names in their paths, not space_config: record IDs. Space reads require read:space_config; create and update require both write:space_config and read authority for the returned configuration. The principal must match the target space and pass the record’s clearance and subject checks. Lists contain only authorized configurations. Configuration updates compare the authorized state at the storage write; a stale update returns 409. Creation accepts name, embedding_provider, embedding_model, and embedding_dims, plus optional purpose and skill. Updates accept the same configuration fields except name. Omitted fields retain their previous values; null purpose or skill does not clear an existing value.
This configuration selects the provider but does not supply its credentials. Check spaces before changing an existing embedding policy.

Daily budget

GET /api/v1/budget (Recall 0.9.1) selects a space with X-Space-Id and requires read:space_config, record clearance and current-grant authority. It is available without provider calls and does not reserve budget or start work. Historical euros configuration names use abstract accounting units, with measured tokens reconciled at one unit per million; they are not monetary provider charges. Remaining values saturate at zero while usage retains an overrun. This is an advisory read; concurrent reservations can change headroom immediately. Policy applies independently per space and UTC day, and separately configured external worker settings are not attested. Missing runtime configuration or invalid/unavailable accounting returns 503. Unknown authorized space returns 404; insufficient authority returns 403. The legacy GET /api/v1/budget/today retains its original ledger-total contract. Use the budget operator guide for supported limit changes, defaults and import planning.

Work Items

Work items represent dispatched tasks such as rendering, extraction, artifact validation/commit, and truth resolution. Use these endpoints to monitor and retry pipeline work.

List Work Items

GET /v1/work-items
string
Filter by work item kind (for example render_doc, plan_extraction, extract_assertions, tm_detect_conflicts, freshness_sweep).
string
Filter by status: pending, runnable, running, done, failed, cancelled.
integer
Filter by minimum age in seconds (useful for finding stuck items).
integer
default:"50"
Maximum results to return.
string
Pagination cursor.
The current list handler returns total for the authorized records in this response and always returns cursor: null; do not use it as a complete queue export. A status-filtered request does not consume cursor. kind is applied when supplied together with status. Consult work queue for scheduler behavior and operational diagnosis.

Get Work Item

GET /v1/work-items/{id}
string
required
Work item record ID (e.g., work_item:550e8400-...).

Retry Work Item

Work-item reads require read:work_item; retry additionally requires write:work_item. Both operation scopes and record authorization apply before retrying or returning a record. A concurrent status, security, or payload change returns 409, without reactivating stale work. Archived retries use the same atomic guard. POST /v1/work-items/{id}/retry Reset a failed work item to runnable status so the pipeline picks it up again. Only items with failed status can be retried.
string
required
Work item record ID.

Truth Slots

Truth slots represent the current “truth” for a subject-predicate pair. They track which assertion currently holds the winning value and whether conflicts exist.

List Truth Slots

The result contains full TruthSlot records; the example below is abbreviated. current_values can hold multiple accepted claims or be empty. GET /v1/truth-slots
string
Filter by subject entity ID.
string
Filter by predicate ID.
boolean
default:"false"
Only return stale slots (truth needs re-evaluation).
integer
default:"50"
Maximum results to return.
string
Pagination cursor.

Get Truth Slot History

GET /v1/truth-slots/{id}/history Returns a full truth slot and, when present, its conflict group. The abbreviated examples omit common record fields. conflict_group is omitted when absent. Unlike the MCP history tool, this endpoint does not include an assertions array.
string
required
Truth slot record ID (e.g., truth_slot:550e8400-...).

Identity Resolution

Identity resolution endpoints manage duplicate detection and entity merging.

Create Identity Candidate

POST /v1/identity/candidates This REST route accepts a complete IdentityCandidate record, including the common record fields. It returns 201 with the stored candidate. It does not accept the MCP convenience proposal shape. Supply valid IDs, actual timestamps, and the correct provenance/security fields alongside these values. For a smaller input that generates base fields, use MCP propose_identity_candidate on Maintenance or Full. A candidate records a proposed match; it does not itself merge entities or establish their identity.

List Identity Candidates

GET /v1/identity/candidates
boolean
default:"false"
Only return pending (unresolved) candidates.
number
Minimum confidence threshold.
integer
default:"50"
Maximum results to return.

Merge Entities

POST /v1/identity/merge
Merge is a destructive operation. The merged entity is soft-deleted and all its relationships and events are repointed to the surviving entity. This cannot be undone through the API.
Merge two entities into one. Relationships and events from the merged entity are repointed to the survivor. Both entities must be in the same space.
string
required
First entity ID.
string
required
Second entity ID.
string
required
Merge strategy: keep_a (keep entity A), keep_b (keep entity B), or combine (create a new merged entity).

Events

System events provide an append-only audit stream of changes across the knowledge graph.

Stream Events (JSON)

GET /v1/events/stream
string
Base64-encoded cursor to resume from. Encodes the space ID and sequence number.
integer
default:"100"
Maximum events to return (max 1000).

Stream Events (SSE)

GET /v1/events/sse Opens a persistent Server-Sent Events stream. The server polls storage at the configured cadence and pushes batches to the connected client. Preserve the returned cursor to resume after disconnection. Example events below omit common base fields for readability.
string
Base64-encoded cursor to resume from.
integer
default:"1000"
Polling interval in milliseconds for checking new events.

Get Latest Sequence

GET /v1/events/latest Returns the latest event sequence number for a space.
string
required
Space ID to query.

Audit Revert

POST /v1/audit/revert/

Revert changes recorded in an audit log entry. Supports reverting create, update, delete, and restore actions on entities, relationships, documents, sources, and identity candidates.
string
required
Audit log record ID (e.g., audit_log:550e8400-...).
Promote, merge, and purge actions cannot be reverted through this endpoint.