Invoice and Receipt Extraction
Read an invoice or receipt from an image or PDF. Returns line items, totals, dates, supplier details and VAT amounts.
invoice-extract Example
{
"iban": null,
"currency": null,
"due_date": null,
"subtotal": null,
"vat_rate": null,
"buyer_vat": null,
"buyer_name": null,
"confidence": {
"line_items": "low",
"vat_amount": "low",
"vendor_name": "low",
"total_amount": "low"
},
"line_items": [],
"vat_amount": null,
"vendor_vat": null,
"vendor_name": null,
"invoice_date": null,
"total_amount": null,
"invoice_number": null,
"payment_reference": null
} Inputs
| Field | Type | Required | What it is |
|---|---|---|---|
url | string | No | URL to invoice image or PDF |
base64 | string | No | Base64-encoded invoice file |
Output fields
How reliably each field appears in a successful answer.
| Field | Type | Appears |
|---|---|---|
iban | string | Usually (present for most inputs) |
currency | string | Usually (present for most inputs) |
due_date | string | Usually (present for most inputs) |
subtotal | number | Usually (present for most inputs) |
vat_rate | number | Usually (present for most inputs) |
buyer_vat | string | Usually (present for most inputs) |
buyer_name | string | Usually (present for most inputs) |
confidence | object | Sometimes (present only for some inputs) |
line_items | array | Sometimes (present only for some inputs) |
vat_amount | number | Usually (present for most inputs) |
vendor_vat | string | Usually (present for most inputs) |
vendor_name | string | Usually (present for most inputs) |
invoice_date | string | Usually (present for most inputs) |
total_amount | number | Usually (present for most inputs) |
invoice_number | string | Usually (present for most inputs) |
payment_reference | string | Usually (present for most inputs) |
How to call it
The same tool through each route. MCP clients reach it through Strale’s server at https://api.strale.io/mcp; the call below is what the agent sends.
# Needs an API key. max_price_cents caps what this call may cost.
curl -X POST https://api.strale.io/v1/do \
-H "Authorization: Bearer $STRALE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{
"capability_slug": "invoice-extract",
"inputs": {
"url": "https://httpbin.org/image/jpeg"
},
"max_price_cents": 50
}' {
"tool": "strale_execute",
"arguments": {
"slug": "invoice-extract",
"inputs": {
"url": "https://httpbin.org/image/jpeg"
},
"max_price_cents": 50
}
} import { Strale } from "straleio";
const strale = new Strale({ apiKey: process.env.STRALE_API_KEY! });
const result = await strale.do({
capability_slug: "invoice-extract",
inputs: {
"url": "https://httpbin.org/image/jpeg"
},
max_price_cents: 50,
}); import os
from straleio import Strale, DoRequest
strale = Strale(api_key=os.environ["STRALE_API_KEY"])
result = strale.do(DoRequest(
capability_slug="invoice-extract",
inputs={
"url": "https://httpbin.org/image/jpeg",
},
max_price_cents=50,
)) # No account. The first request answers 402 with the price in USDC;
# an x402 client pays it from your wallet and repeats the request.
curl -i -X POST https://api.strale.io/x402/v2/invoice-extract \
-H 'Content-Type: application/json' \
-d '{
"url": "https://httpbin.org/image/jpeg"
}' Limitations
Handwritten or unusual layouts reduce accuracy
Best results with standard invoice layouts — handwritten invoices or heavily stylised designs may have lower accuracy
What to do instead: For non-standard formats, use pdf-extract for raw text and apply custom parsing rules
Extracted totals and tax figures need checking
AI extraction from invoice documents — line item totals and tax calculations should be verified against source
What to do instead: Validate that extracted line items sum to the total amount and cross-check VAT calculations before booking
Input documents are limited to 8 MiB decoded
Documents supplied by URL or base64 are refused above 8 MiB of decoded data, with a caller_input error naming the input field and no charge. Reduce the document size or split it before submitting.
Bundled checks that include it
Related tools
- PDF Data Extraction €0.30
- Privacy Policy Analysis €0.30
- Return Policy Extraction €0.20
- SWIFT Message Parser €0.02
- Terms of Service Extraction €0.30