DEVELOPER REFERENCE · V1

API quick start

Upload an invoice, retain its jobId and retrieve the structured result using the Number7 AI v1 API.

1. Authenticate on your server

Keep your API key in a server-side secret. Send it as a Bearer token; never embed it in website JavaScript.

Authorization: Bearer <YOUR_API_KEY>

2. Upload an invoice

curl --fail-with-body --request POST \
  'https://api.number7ai.com/api/v1/upload?document.type=invoice&document.version=v1' \
  --header "Authorization: Bearer $N7_API_KEY" \
  --form 'file=@invoice.pdf' \
  --form 'fileName=invoice.pdf' \
  --form 'fileType=application/pdf'

Read data.jobId from the response and persist it before continuing. The upload response acknowledges a job; it does not mean processing has completed.

3. Retrieve the result

curl --fail-with-body \
  'https://api.number7ai.com/api/v1/results/YOUR_JOB_ID' \
  --header "Authorization: Bearer $N7_API_KEY"

Poll approximately every 20 seconds with a bounded timeout, or use completion webhooks. Check data.fileStatus: done means a result is available; failed requires error handling. Intermediate states include uploading, processing, scanning and ai_processing.

Before accounting-system handoff

Validate the returned business data against your required accounting fields and policy. A completed extraction job is not an authorization to post or pay. Keep the original document and job identifier attached to downstream work.

Aligned with Number7 AI’s published API documentation, reviewed 8 September 2026. These examples have not been executed against your account.

Request the diagnostic