API reference
The explicit HTTP lifecycle.
This reference is rendered from the same executable OpenAPI source as the raw artifact. Its public HTTP contract version is independent of API /v1, invoice schema, fixture, SDK, and pipeline versions.
On this page
Operations
/v1/documentsCreate document
Create an invoice document and upload authorization
createDocument/v1/documents/{document_id}/upload-completeConfirm upload
Confirm a direct upload and admit it for processing
completeDocumentUpload/v1/documents/{document_id}Retrieve document
Retrieve the current document resource
getDocument/v1/documents/{document_id}Delete document
Delete a document and its retained customer content
deleteDocument/v1/usageRetrieve usage
Retrieve current or historical processing usage
getUsageIntegration controls
- Send
Idempotency-Keyon create and keep its request body stable. - Treat
Retry-Afteras a minimum for polling and retry. - Follow only the returned upload method, URL, and headers; never add API credentials or follow redirects.
- Branch on terminal status and use
processing.result_expires_atas the result deadline. - Use
accounting_entity_idfor a caller-defined duplicate namespace. Choosepolicybefore submission; see all review policy settings for required fields, line-item acceptance and duplicate detection.
Known error codes
invalid_request · invalid_callback_url · invalid_api_key · billing_required · forbidden · document_not_found · idempotency_conflict · upload_not_complete · invalid_document_state · upload_expired · document_expired · document_too_large · unsupported_content_type · upload_size_mismatch · invalid_document · usage_limit_exceeded · usage_period_not_found · rate_limit_exceeded · internal_error · service_unavailableUnknown future codes
Preserve an unknown non-empty code and recover from HTTP status, retryable, request ID, and the operation state. Never parse message text for control flow.