Error Codes

All Rekall API errors follow a consistent format with HTTP status codes and Rekall-specific error codes. Use this reference to diagnose and resolve issues.

Error Format

Every error response includes a machine-readable error code, a human-readable message, the HTTP status, and a unique request ID for debugging.

Error Response Format
{
"error": {
"code": "INVALID_MEMORY_TYPE",
"message": "The memory type 'spatial' is not supported.",
"status": 400,
"details": {
"provided": "spatial",
"allowed": ["episodic", "semantic", "procedural", "long-term", "short-term", "execution", "preferences"]
},
"request_id": "req_abc123def456"
}
}

HTTP Status Codes

StatusTitleDescription
400Bad RequestThe request body is malformed, missing required fields, or contains invalid values.
401UnauthorizedThe request lacks valid authentication credentials. The API key is missing, expired, or invalid.
403ForbiddenThe authenticated user does not have permission to perform the requested action. Insufficient scopes.
404Not FoundThe requested resource does not exist. The ID may be incorrect or the resource may have been deleted.
409ConflictThe request conflicts with the current state of the resource. Common with duplicate entities or relationships.
422Unprocessable EntityThe request is well-formed but contains semantic errors. Often related to invalid memory content or metadata.
429Too Many RequestsRate limit exceeded. The request was throttled based on your plan tier limits.
500Internal Server ErrorAn unexpected error occurred on the server. This is not caused by your request.

Rekall Error Codes

These application-specific error codes provide more detail about what went wrong. They are returned in the error.code field of the response.

CodeHTTPDescription
INVALID_MEMORY_TYPE400The specified memory type is not one of the 7 supported types.
SCOPE_INSUFFICIENT403Your API key does not have the required scope for this endpoint.
RATE_LIMIT_EXCEEDED429You have exceeded the rate limit for your plan tier.
ENTITY_NOT_FOUND404The referenced entity does not exist in the knowledge graph.
RELATIONSHIP_CONFLICT409A relationship of this type already exists between the specified entities.
MEMORY_CONTENT_TOO_LARGE422The memory content exceeds the maximum allowed size (100KB for text, 10MB for embeddings).
EMBEDDING_GENERATION_FAILED422The system failed to generate a vector embedding for the provided content.
HIVE_MEMBER_LIMIT422The hive has reached the maximum number of members allowed by your plan.
WORKFLOW_STEP_FAILED422A workflow step failed during execution. The run has been paused.
AGENT_ALREADY_TERMINATED409The agent has already been terminated and cannot accept further operations.
SANDBOX_PRODUCTION_MISMATCH403A sandbox key (rk_test_) was used to access production resources, or vice versa.
CONTEXT_NOT_ACCESSIBLE403The memory context (agent, user, or hive) is not accessible with the current credentials.

Handling Errors

refresh

Retryable errors

Errors with status 429 and 500 are generally retryable. Use exponential backoff starting at 1 second with a maximum of 5 retries.

timer

Rate limit headers

Every response includes rate limit headers: X-RateLimit-Limit, X-RateLimit-Remaining, and X-RateLimit-Reset. Use these proactively to avoid hitting limits.

bug_report

Request ID for support

Include the request_id when contacting support. It is also returned in the X-Request-Id response header.

SDK error handling

The official SDKs automatically handle retryable errors with configurable backoff. Set maxRetries in the client constructor to control retry behavior.

Rekall
rekall