Skip to main content

Errors

All error responses follow a consistent JSON format.

Error response format

{
"error": "Human-readable error message",
"details": [ /* optional — Zod issues for 422 responses */ ]
}
  • error is always a string.
  • details is optional. For validation errors (422), it is an array of Zod issues describing each invalid field. For other errors it may be an object with additional debugging context, or omitted entirely.

Validation error example

// 422
{
"error": "Validation failed",
"details": [
{
"code": "invalid_type",
"expected": "string",
"received": "undefined",
"path": ["customer_email"],
"message": "Required"
}
]
}

HTTP status codes

CodeMeaningWhen it happens
400Bad RequestInvalid JSON, missing required fields, validation errors
401UnauthorizedMissing or invalid API key
403ForbiddenValid auth but insufficient scope
404Not FoundResource doesn't exist or is outside your org scope
409ConflictDuplicate resource (e.g., vault already has authoritative copy)
422Unprocessable EntityValid JSON but semantically incorrect (e.g., voiding a completed envelope)
429Too Many RequestsRate limit exceeded
500Internal Server ErrorUnexpected server error

Common error examples

Missing authentication

// 401
{
"error": "API key is required"
}

Insufficient scope

// 403
{
"error": "Missing required scope: vault:read"
}

Envelope not found

// 404
{
"error": "Envelope not found"
}

Wrong vault-in endpoint for the envelope kind

// 409
{
"error": "Upload envelopes must use POST /partner/envelopes/:id/vault-in-upload"
}

An envelope that is already vaulted is not a conflict — the vault-in endpoints are idempotent and return 200 with the existing envelope. Vault storage paths are never included in a partner response, error bodies included; use GET /partner/envelopes/:id/vault/signed-url to reach the file.

Invalid envelope transition

// 422
{
"error": "Cannot void envelope with status: completed"
}

Rate limit exceeded

// 429
{
"error": "Rate limit exceeded",
"details": {
"retry_after": 42
}
}

Debugging

Every response includes an X-Request-Id header. Include this ID when contacting support:

X-Request-Id: req_a1b2c3d4-e5f6-7890-abcd-ef0123456789