Papr Memory API (1.0.0)

API for managing enterprise context and memory items with authentication and user-specific data.

Authentication

This API supports three authentication methods:

  • API Key: Include your API key in the X-API-Key header
    X-API-Key: <your-api-key>
  • Session Token: Include your session token in the X-Session-Token header
    X-Session-Token: <your-session-token>
  • Bearer Token: Include your OAuth2 token from Auth0 in the Authorization header
    Authorization: Bearer <token>

All endpoints require one of these authentication methods.

Download OpenAPI description
Languages
Servers
Production server
https://memory.papr.ai/

v1

Operations

Delete Namespace

Request

Delete a namespace and optionally cascade-delete all memories, Neo4j nodes, and ACL references associated with it.

Path
namespace_idstring(Namespace Id)required
Query
delete_memoriesboolean(Delete Memories)

Delete all memories in this namespace

Default true
delete_neo4j_nodesboolean(Delete Neo4J Nodes)

Delete all Neo4j nodes in this namespace

Default true
remove_acl_referencesboolean(Remove Acl References)

Remove namespace from ACL arrays on remaining nodes

Default true
Headers
X-API-Keystring(X-Api-Key)required
curl -i -X DELETE \
  'https://memory.papr.ai/v1/namespace/{namespace_id}?delete_memories=true&delete_neo4j_nodes=true&remove_acl_references=true' \
  -H 'X-API-Key: string'

Responses

Namespace deleted

Bodyapplication/json
codeinteger(Code)

HTTP status code

Default 200
statusstring(Status)

'success' or 'error'

Default "success"
namespace_idNamespace Id (string) or Namespace Id (null)(Namespace Id)

ID of deleted namespace

Any of:

ID of deleted namespace

string(Namespace Id)

ID of deleted namespace

messageMessage (string) or Message (null)(Message)

Human-readable message

Any of:

Human-readable message

string(Message)

Human-readable message

cascadeCascadeDeletionResult (object) or null

Cascade deletion details

Any of:

Cascade deletion details

errorError (string) or Error (null)(Error)

Error message if failed

Any of:

Error message if failed

string(Error)

Error message if failed

detailsDetails (any) or Details (null)(Details)

Additional error details or context

Any of:

Additional error details or context

any(Details)

Additional error details or context

Response
application/json
{ "code": 200, "status": "success", "namespace_id": "string", "message": "string", "cascade": { "memories_deleted": 0, "memories_failed": 0, "neo4j_nodes_deleted": 0, "acl_read_cleaned": 0, "acl_write_cleaned": 0 }, "error": "string", "details": {} }

Create Namespace Api Key

Request

Mint a new API key bound to the given namespace. Caller must authenticate with any API key belonging to the same organization (typically the org-wide / default-namespace key).

Security: The full key is returned exactly once in this response. Store it immediately — it cannot be retrieved later. Subsequent reads expose only the masked key_prefix.

Path
namespace_idstring(Namespace Id)required
Headers
X-API-Keystring(X-Api-Key)required
Bodyapplication/jsonrequired
namestring(Name)[ 1 .. 128 ] charactersrequired

Human-readable name for the API key (shown in admin UIs).

Example: "Acme Production API Key"
environmentstring(Environment)

Environment label: development, staging, or production.

Default "production"
Enum"development""staging""production"
Example: "production"
permissionsArray of strings(Permissions)[ 1 .. 3 ] items

Permissions granted by this key. Must be a subset of ['read', 'write', 'delete'].

Items Enum"read""write""delete"
Example: ["read","write","delete"]
curl -i -X POST \
  'https://memory.papr.ai/v1/namespace/{namespace_id}/api-keys' \
  -H 'Content-Type: application/json' \
  -H 'X-API-Key: string' \
  -d '{
    "environment": "production",
    "name": "Acme Production API Key",
    "permissions": [
      "read",
      "write",
      "delete"
    ]
  }'

Responses

API key created

Bodyapplication/json
codeinteger(Code)

HTTP status code

Default 200
statusstring(Status)

'success' or 'error'

Default "success"
dataNamespaceApiKeyItem (object) or null

The newly created API key, including the full key string (only on creation).

Any of:

The newly created API key, including the full key string (only on creation).

errorError (string) or Error (null)(Error)

Error message if failed

Any of:

Error message if failed

string(Error)

Error message if failed

detailsDetails (any) or Details (null)(Details)

Additional error details. NEVER contains the API key.

Any of:

Additional error details. NEVER contains the API key.

any(Details)

Additional error details. NEVER contains the API key.

Response
application/json
{ "code": 200, "status": "success", "data": { "objectId": "string", "key": "string", "key_prefix": "string", "name": "string", "namespace_id": "string", "organization_id": "string", "environment": "string", "permissions": [], "is_active": true, "createdAt": "string" }, "error": "string", "details": {} }

Transform text to graph embeddings

Request

Vector-store agnostic producer.

Returns everything you'd want to index in any vector DB -- base embedding, 14-band extracted signals, per-band SBERT/Qwen embeddings, phases, and optional rot_v3 / concat reconstructions.

Uses the SAME extraction + embedding path as /v1/graph/rerank uses for queries, so artifacts produced here can be scored by /v1/graph/rerank without any drift.

Bodyapplication/jsonrequired
textstring(Text)required

Source text to transform.

embeddingArray of Embedding (numbers) or Embedding (null)(Embedding)

Optional caller-provided base embedding (Qwen 2560-d). If omitted, the server computes it.

Any of:

Optional caller-provided base embedding (Qwen 2560-d). If omitted, the server computes it.

domain_idDomain Id (string) or Domain Id (null)(Domain Id)

Domain shortname or full schema id controlling which frequency bands and extraction rules are used. Built-in shortnames: "general" (default), "code", "cosqa", "codetrans", "codetransocean", "codetransocean_hybrid", "text2sql", "scifact", "nfcorpus", "fiqa", "legal", "medical", "ecommerce", "coffee_shops". You can also pass a full schema id (e.g. "code_search:cosqa:2.0.0") or a custom domain_id registered via POST /v1/graph/domains.

Any of:

Domain shortname or full schema id controlling which frequency bands and extraction rules are used. Built-in shortnames: "general" (default), "code", "cosqa", "codetrans", "codetransocean", "codetransocean_hybrid", "text2sql", "scifact", "nfcorpus", "fiqa", "legal", "medical", "ecommerce", "coffee_shops". You can also pass a full schema id (e.g. "code_search:cosqa:2.0.0") or a custom domain_id registered via POST /v1/graph/domains.

string(Domain Id)

Domain shortname or full schema id controlling which frequency bands and extraction rules are used. Built-in shortnames: "general" (default), "code", "cosqa", "codetrans", "codetransocean", "codetransocean_hybrid", "text2sql", "scifact", "nfcorpus", "fiqa", "legal", "medical", "ecommerce", "coffee_shops". You can also pass a full schema id (e.g. "code_search:cosqa:2.0.0") or a custom domain_id registered via POST /v1/graph/domains.

metadataMetadata (object) or Metadata (null)(Metadata)

Free-form user metadata to attach (optional, not used for scoring).

Any of:

Free-form user metadata to attach (optional, not used for scoring).

signal_embedderstring(Signal Embedder)

Embedder for per-band signal vectors. 'sbert' (384d, default) is ~10x cheaper to store than 'qwen' (2560d, matched to base).

Default "sbert"
Enum"sbert""qwen"
return_rot_v3boolean(Return Rot V3)

If true, include the rot_v3 vector in the response.

Default false
return_concatboolean(Return Concat)

If true, include the base + bands concatenation embedding.

Default false
curl -i -X POST \
  https://memory.papr.ai/v1/graph/transform \
  -H 'Content-Type: application/json' \
  -H 'X-API-Key: YOUR_API_KEY_HERE' \
  -d '{
    "text": "string",
    "embedding": [
      0
    ],
    "domain_id": "string",
    "metadata": {},
    "signal_embedder": "sbert",
    "return_rot_v3": false,
    "return_concat": false
  }'

Responses

Successful Response

Bodyapplication/json
phasesArray of numbers(Phases)required

Per-frequency phase angles (14-dim).

embeddingArray of numbers(Embedding)required

Base embedding (normalized Qwen 2560-d).

signalsobject(Signals)

Signal band-name -> extracted text (e.g. {'docstring': '...', 'function_name': '...'}).

signal_embeddingsobject(Signal Embeddings)

Signal band-name -> embedding vector (384-d sbert or 2560-d qwen).

rot_v3Array of Rot V3 (numbers) or Rot V3 (null)(Rot V3)

Rotation v3 vector (only when return_rot_v3=true).

Any of:

Rotation v3 vector (only when return_rot_v3=true).

concat_embeddingArray of Concat Embedding (numbers) or Concat Embedding (null)(Concat Embedding)

Base + bands concatenation (only when return_concat=true).

Any of:

Base + bands concatenation (only when return_concat=true).

idstring(Id)required

Request id for log correlation.

domain_idstring(Domain Id)required

Domain used for extraction.

metaobject(Meta)

Timing and stats.

Response
application/json
{ "phases": [ 0 ], "embedding": [ 0 ], "signals": { "property1": "string", "property2": "string" }, "signal_embeddings": { "property1": [], "property2": [] }, "rot_v3": [ 0 ], "concat_embedding": [ 0 ], "id": "string", "domain_id": "string", "meta": {} }

Memory

Operations

Memory Status

Operations

User

Operations

Feedback

Operations

Schema Management

Operations

Messages

Operations

omo

Operations

Namespace

Operations

Graph

Operations

Graph Domains

Operations

Instance Configuration

Operations

AI Proxy

Operations

Sync

Operations

Telemetry

Operations

Document

Operations

GraphQL

Operations

Authentication

Operations