Skip to content

Errors and rate limits

Every error uses one structured envelope with a stable code. That includes your library, device sign-in, and the API front door at api.prophouse.dev, which rejects some requests before they reach your library (authentication, rate limits, workspace state).

Every non-2xx JSON response looks like this:

{
"error": {
"code": "LOCKED",
"message": "Lineage 'guid:6F9619FF8B86D011B42D00C04FC964FF' is locked by another user.",
"details": {
"holder": { "id": 7, "name": "<user>", "display_name": "Sam Rigger" },
"lock": { "id": 31, "lineage_id": "guid:6F9619FF8B86D011B42D00C04FC964FF", "active": true }
}
}
}

Switch on code. Messages are written for people and can change. details is always an object, often empty. It carries machine-readable context where the tables below list keys.

The front door uses the same envelope. Its messages are finished sentences you can show to people, and details.reason says which case you hit:

{
"error": {
"code": "RATE_LIMITED",
"message": "Rate limit exceeded for this key. Back off and retry.",
"details": { "retry_after_seconds": 30 }
}
}
Status Code Cause
400 VALIDATION An MCP request body is not valid JSON.
401 UNAUTHORIZED The key or token is missing, unknown, revoked or expired, or the member who created the key left the workspace. A self-hosted token sent to the hosted API also gets 401. details.reason is missing_credential, invalid_key, foreign_key, key_owner_removed, invalid_token or membership_inactive.
402 PAYMENT_REQUIRED The workspace is suspended for billing, and every request is refused, reads included. Fix billing at app.prophouse.dev/billing.
403 READ_ONLY_KEY A read-scoped key sent a write. Sign in from the editor, which requests a write-scoped key, or create a write-scoped key at app.prophouse.dev/keys.
403 FORBIDDEN The key belongs to a different workspace (wrong_workspace), or you are not a member of the workspace named in the host (not_a_member). Signing out with a key created on the dashboard also gets it (not_an_app_key).
404 NOT_FOUND No workspace has that <slug>.prophouse.dev name (no_such_workspace, with the name in details.slug), or the workspace has no library yet (library_not_provisioned).
410 WORKSPACE_DELETED The workspace is scheduled for deletion, so its library is closed. Fixing billing does not reopen it. To cancel the deletion, email support@prophouse.dev.
411 LENGTH_REQUIRED An MCP POST has no Content-Length header. The header is required, with a value of 1 MB or less.
413 PAYLOAD_TOO_LARGE An MCP request body is larger than 1 MB. details.max_bytes gives the limit.
429 RATE_LIMITED The key hit its rate limit. See below.
429 AGENT_CALL_LIMIT The workspace used up its agent calls for the month. details.used and details.limit show the count.
503 LIBRARY_STARTING Your library is starting, being prepared or moving. Show a short wait and retry after Retry-After.
503 UNAVAILABLE The API is paused (api_paused), your workspace’s API access is paused (workspace_paused), or your library is temporarily unavailable. This is an outage, not a start-up wait. Both pauses send Retry-After: 120. If workspace_paused persists, contact support@prophouse.dev.

Every front-door response that asks you to wait sends a Retry-After header and the same number of seconds in details.retry_after_seconds.

These are all the stable codes your library can return. The front door’s own codes are in the table above. details keys are listed where the API sets them.

Code Status Meaning
UNAUTHORIZED 401 Missing, invalid or expired credential. Device sign-in also returns it for an unknown or already-used device code.
FORBIDDEN 403 You are signed in but not allowed to do this. Examples are an admin-only endpoint, a change to something you do not own, or a workspace that blocks writes. details.reason is read_only when billing suspended the workspace (on hosted workspaces the front door returns 402 for every request first), or ingest_blocked when the workspace reached its storage limit.
RATE_LIMITED 429 Too many requests to the library’s /auth/ endpoints. details.retry_after_seconds says when to retry.
SETUP_ALREADY_DONE 409 Not used by hosted workspaces.
DEVICE_PENDING 400 Device sign-in is not approved yet. Keep polling every details.interval seconds.
DEVICE_SLOW_DOWN 429 Device sign-in polled too fast. Wait details.interval seconds.
DEVICE_EXPIRED 400 The device code expired. Start a new sign-in.
DEVICE_DENIED 400 The person denied the device sign-in.
NOT_FOUND 404 Generic not found. Covers an unknown route or method and a missing thumbnail, preview artifact, attachment, lock or project.
ENTRY_NOT_FOUND 404 No entry with that id. Bulk calls list the missing ids in details.missing.
OBJECT_NOT_FOUND 404 No object (immutable version) with that id.
LINEAGE_NOT_FOUND 404 No lineage with that id in the catalog.
PACK_NOT_FOUND 404 No pack with that id.
TAG_NOT_FOUND 404 No tag with that id.
COMMENT_NOT_FOUND 404 No comment with that id.
ANNOTATION_NOT_FOUND 404 No annotation with that id.
COLLECTION_NOT_FOUND 404 No collection with that id.
JOB_NOT_FOUND 404 No pull job with that id.
INGEST_NOT_FOUND 404 Reserved for server-side pack ingestion.
USER_NOT_FOUND 404 No member with that id (reviewers, assignees, member profiles).
TOKEN_NOT_FOUND 404 Not used by hosted workspaces.
WEBHOOK_NOT_FOUND 404 No webhook with that id.
REVIEW_REQUEST_NOT_FOUND 404 No review request with that id.
VALIDATION 422 The request is malformed or breaks a rule, such as a bad field, a bad cursor, too many items or invalid media. For body and query validation, details.errors lists each failing field.
CONFLICT 409 A uniqueness or state conflict. Examples: a duplicate tag name (details.existing_id), a preview for an object that is no longer current (details.current_object_id), deleting an entry that was pulled, or opening a review round while one is open (details.open_request_id).
LOCKED 409 Another person holds the check-out lock (details.holder, details.lock).
DENYLISTED 403 The blob’s hash is on the workspace denylist.
HASH_MISMATCH 409 The uploaded bytes do not match the declared hash.
BLOB_MISSING 409 or 404 A commit references bytes that were never uploaded (409, details.missing), or a download asks for an unknown hash (404).
LINEAGE_CONFLICT 409 The object belongs to a different lineage than the entry (restore, face change, pinned pull, version-pinned comment or annotation), or a pull’s closure maps two objects to one lineage (details.lineage_collisions).
PROBABLE_LOST_STAMP none Never returned as an error. It appears as probable_lost_stamp: true on push items.
STALE_FACE 409 A push would replace a current version you did not see. details has lineage_id, expected_face_object_id, actual_face_object_id and content_hash. Re-sync before you push again.
ENGINE_TOO_OLD 409 A pull job’s closure has assets saved by a newer engine than the claiming editor (details.objects, details.claimant_engine_version).
JOB_STATE 409 An illegal job transition, a lost claim or a stale claim token. For pull jobs, details.status has the job’s current status.
DRY_RUN_REQUIRED 409 An admin maintenance sweep ran without a dry run from the last hour (details.dry_run_id).
UPGRADE_REQUIRED 426 The request declared a different API major version in the X-PH-API header or the /api/v<major> path, or a write declared neither. details has server_major, declared and source.
UNAVAILABLE 503 The library cannot take the request right now. Right after the library starts, writes return details.reason: "policy_unavailable" with Retry-After: 5 until it confirms the workspace plan. Reads keep working. Retry.
INTERNAL 500 Unexpected error. The details stay in server logs. Retry once, then contact support with the time of the request.
EMBEDDINGS_UNAVAILABLE 503 or 409 Visual search is unavailable for now (503), or the entry you asked for similar props to has no image embedding yet (409, details.entry_id).

Device sign-in also returns INVALID_REQUEST (400) when the poll body has no device_code.

The front door limits each API key over a sliding one-minute window:

Traffic Limit per key
Most requests 240 per minute
Uploads, blob transfers and media processing: /push/*, /blobs/*, POST /entries/media/presign and /finalize, and /entries/{id}/preview, /thumbnail and /metadata 2,400 per minute

The two budgets are separate. A large upload does not use up the budget for other calls made with the same key. The desktop app’s background sync also uses the 2,400 budget.

Over the limit you get:

HTTP/1.1 429 Too Many Requests
Retry-After: 30
Content-Type: application/json; charset=utf-8
{"error": {"code": "RATE_LIMITED", "message": "Rate limit exceeded for this key. Back off and retry.", "details": {"retry_after_seconds": 30}}}

On /mcp, a single JSON-RPC request with an id gets a 200 with a RATE_LIMITED error and details.retry_after_seconds instead of the 429. A tools/call gets it as a tool error, and other methods get it as a JSON-RPC error. See MCP errors and limits.

Device sign-in has its own limits. See device sign-in.

REST API calls never count toward a plan allowance. Search, browsing, downloads, thumbnails, uploads and every other REST request are uncounted. The rate limits above still apply.

Only MCP tool calls (tools/call on /mcp) count. Each /mcp request that carries a tool call counts once against the workspace’s monthly agent-call allowance, which resets at the start of each UTC calendar month. When the allowance runs out, MCP tool calls return an AGENT_CALL_LIMIT tool error. A JSON-RPC batch, or a request without an id, gets a plain 429 with used and limit in the body instead. Search in the apps and the REST API keeps working. See MCP errors and limits and Plans and limits.

Response Retry?
429 rate limit Yes, after Retry-After seconds (or details.retry_after_seconds). Add jitter if you run several workers.
429 agent-call limit No. The allowance resets at the start of the next UTC month.
503 Yes, after Retry-After when present. Otherwise back off exponentially, starting at about 2 seconds.
500 INTERNAL Once, then stop and report it.
409 codes No. The state changed. Read it again and decide. JOB_STATE on a pull job means you lost your claim.
Other 4xx No. Fix the request.

Uploads and pushes are safe to retry. Blob uploads are idempotent by hash, and a commit registers the whole batch or nothing. See Push (uploads).