API

Introduction

One endpoint in, structured JSON out. Upload an invoice, poll the document, read the extraction.

Base URL

Text
https://api.invoi.st

All requests are authenticated with an API key sent as a bearer token. See Authentication.

Conventions

ConventionDetail
ResponsesAlways JSON. Errors use one envelope, documented under Errors and limits.
MoneyInteger cents, never floats. total_cents: 284900 is $2,849.00.
DatesInvoice dates are YYYY-MM-DD. Timestamps are RFC 3339 UTC.
UploadsMultipart form data, field name file. PDF, PNG, or JPEG, at most 20 MB.
ConfidenceEach major field gets a 0 to 1 score. Decide your own threshold for review.
Versioning/v1 in the path. What's breaking and what isn't is documented under Versioning.

The extraction lifecycle

  1. Upload. POST /v1/extract stores the file and answers immediately with a document in processing and an extraction in pending.
  2. Poll. GET /v1/documents/{id} until the extraction status is done or failed. Most invoices finish in a few seconds.
  3. Read. The extraction carries header fields, line items, and confidence scores in the same shape every time.
1. Upload
curl -X POST https://api.invoi.st/v1/extract \
  -H "Authorization: Bearer $INVOIST_API_KEY" \
  -F "[email protected]"
2. Poll
curl https://api.invoi.st/v1/documents/01a01663-6802-7707-a847-13323ffab41e \
  -H "Authorization: Bearer $INVOIST_API_KEY"

Same schema, every invoice

Fields that are not on the invoice come back null rather than disappearing, so your parser never has to guess at shape.

Full request and response details are in the reference: Extraction, Documents, and Usage.