Skip to main content
Only some failures carry a code. Codes are emitted by guards and middleware that construct the response directly. Controller errors generally return { status, message, error } without a code.

Storage API codes

MCP codes

Codes that are not stable

Do not depend on:
  • message text,
  • validation field names,
  • HTTP reason phrases,
  • a code that is not in the tables above,
  • the error field’s contents.
If a response includes an unknown code, log it and treat the HTTP status as authoritative.

The trial upload exception

A trial upload over 100 MB is rejected with 413. The backend defines a trial-specific upload code internally, but the current controller path may return only the standard error envelope. Do not require a code to detect this case: use 413 plus your own pre-flight size check.

Where codes are absent

These failures usually have no stable code:
  • schema validation (400),
  • missing scope on a normal controller route (403),
  • file not found (404),
  • retention or legal-hold block (403 or 400),
  • restore window elapsed (410),
  • decryption state failure (400 or 5xx),
  • insufficient storage (402).
Handle them by status and by checking state before the request where possible.

Example