Extract Invoice
by NetIntel in Markets & finance
Extract structured data from invoice or receipt text — or directly from an invoice URL (PDF, HTML, or plain text, fetched and parsed server-side) — using Claude Haiku: returns vendor, invoice number, dates, line items, subtotal, tax, total, and currency as clean JSON for accounts-payable, expense processing, and bookkeeping automation.
https://netintel.dev/extract/invoice- Price
- $0.02
- per call in USDC
- Uptime
- 100%
- last 30 days
- Response time
- 193 ms
- 389 ms slowest 5%
- Last check
- Passed
- 1 h ago, next any minute now
Reliability
How to call it
POST https://netintel.dev/extract/invoice
Each call costs $0.02 in USDC on Base, paid with the request over x402.
Run a free test callOne unpaid request, the way an agent sends it. You see the payment challenge it gets back. Nothing is charged.
Example request
From the listing.
POST https://netintel.dev/extract/invoice
content-type: application/json
{
"text": "Acme Supplies Inc\nInvoice INV-2024-0142\nDate: 2024-03-01 Due: 2024-03-31\nWidget A 10 x $5.00 = $50.00\nShipping 1 x $12.00 = $12.00\nSubtotal: $62.00\nTax: $5.58\nTotal: $67.58 USD"
}Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
text | string | No | The invoice or receipt content ITSELF (email body, OCR dump, pasted PDF text) — not an instruction or question about an invoice. Have only a link? Pass url instead. Text with no extractable invoice data returns an uncharged 400 (NO_INVOICE_CONTENT). Max 10000 words or 50KB. |
url | string | No | Publicly reachable invoice URL — PDF, HTML, or plain text; fetched and parsed server-side (e.g. https://vendor.example/invoice-42.pdf). Provide exactly one of text or url. |
Example response
The provider's example. We can't check it without paying.
Example response, 37 lines
{
"cached": false,
"findings": [],
"grade": "A",
"invoice": {
"currency": "USD",
"due_date": "2024-03-31",
"invoice_date": "2024-03-01",
"invoice_number": "INV-2024-0142",
"line_items": [
{
"amount": 50,
"description": "Widget A",
"quantity": 10,
"unit_price": 5
},
{
"amount": 12,
"description": "Shipping",
"quantity": 1,
"unit_price": 12
}
],
"subtotal": 62,
"tax": 5.58,
"total": 67.58,
"vendor": "Acme Supplies Inc"
},
"line_item_count": 2,
"score": 100,
"source": {
"content_type": null,
"type": "text",
"url": null
},
"totals_reconcile": true
}Call it from code
The curl command shows the payment challenge. The JavaScript and Python versions pay and call, and never pay more than $0.02.
curl: see the payment challenge
# bash or zsh: see the payment challenge. Nothing is charged.
curl -sS -g -i -X POST 'https://netintel.dev/extract/invoice' \
-H 'content-type: application/json' \
--data-raw '{"text":"Acme Supplies Inc\nInvoice INV-2024-0142\nDate: 2024-03-01 Due: 2024-03-31\nWidget A 10 x $5.00 = $50.00\nShipping 1 x $12.00 = $12.00\nSubtotal: $62.00\nTax: $5.58\nTotal: $67.58 USD"}'
# x402 v2 sends the challenge base64-encoded in the PAYMENT-REQUIRED header (v1 sends it in the body).
# To read the header:
curl -sS -g -o /dev/null -D - -X POST 'https://netintel.dev/extract/invoice' \
-H 'content-type: application/json' \
--data-raw '{"text":"Acme Supplies Inc\nInvoice INV-2024-0142\nDate: 2024-03-01 Due: 2024-03-31\nWidget A 10 x $5.00 = $50.00\nShipping 1 x $12.00 = $12.00\nSubtotal: $62.00\nTax: $5.58\nTotal: $67.58 USD"}' \
| grep -i '^payment-required:' | cut -d' ' -f2 | tr -d '\r' | base64 --decodeJavaScript: pay and call
// npm i @x402/fetch @x402/evm viem
import { wrapFetchWithPayment, x402Client } from "@x402/fetch";
import { registerExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
// Pays at most $0.02 per call.
const client = new x402Client().setSpendControls({ maxAmountPerPayment: "$0.02" });
registerExactEvmScheme(client, { signer: privateKeyToAccount(process.env.EVM_PRIVATE_KEY) });
const pay = wrapFetchWithPayment(fetch, client);
// Not sure it's safe to pay? ToolVet checks it first for $0.005. Pay for that from a separate
// client: this one is capped at $0.02 per payment. GET https://toolvet.app/api/v1/check?url=https%3A%2F%2Fnetintel.dev%2Fextract%2Finvoice&method=POST
const res = await pay("https://netintel.dev/extract/invoice", {
method: "POST",
headers: { "content-type": "application/json" },
body: JSON.stringify({
"text": "Acme Supplies Inc\nInvoice INV-2024-0142\nDate: 2024-03-01 Due: 2024-03-31\nWidget A 10 x $5.00 = $50.00\nShipping 1 x $12.00 = $12.00\nSubtotal: $62.00\nTax: $5.58\nTotal: $67.58 USD"
}),
});
console.log(res.status, await res.text());Python: pay and call
# pip install "x402[requests,evm]"
import os
from eth_account import Account
from x402 import x402ClientSync
from x402.http.clients import x402_requests
from x402.mechanisms.evm import EthAccountSigner
from x402.mechanisms.evm.exact.register import register_exact_evm_client
# Pays at most $0.02 per call.
client = x402ClientSync().set_spend_controls({"max_amount_per_payment": "$0.02"})
register_exact_evm_client(client, EthAccountSigner(Account.from_key(os.environ["EVM_PRIVATE_KEY"])))
with x402_requests(client) as session:
res = session.post(
"https://netintel.dev/extract/invoice",
json={
"text": "Acme Supplies Inc\nInvoice INV-2024-0142\nDate: 2024-03-01 Due: 2024-03-31\nWidget A 10 x $5.00 = $50.00\nShipping 1 x $12.00 = $12.00\nSubtotal: $62.00\nTax: $5.58\nTotal: $67.58 USD",
},
)
print(res.status_code, res.text)Security scan
No findings
We scan names, descriptions and tool definitions for hidden instructions and other prompt-injection patterns.
Recent checks
| When | Result | HTTP | Time | Price |
|---|---|---|---|---|
| 1 h ago | Passed | 402 | 179 ms | $0.02 |
| 6 h ago | Passed | 402 | 193 ms | $0.02 |
| 10 h ago | Passed | 402 | 294 ms | $0.02 |
| 14 h ago | Passed | 402 | 196 ms | $0.02 |
| 18 h ago | Passed | 402 | 410 ms | $0.02 |
Show 10 older checks
| 22 h ago | Passed | 402 | 192 ms | $0.02 |
| 26 h ago | Passed | 402 | 182 ms | $0.02 |
| 30 h ago | Passed | 402 | 389 ms | $0.02 |
| 34 h ago | Passed | 402 | 440 ms | $0.02 |
| 37 h ago | Passed | 402 | 326 ms | $0.02 |
| 41 h ago | Passed | 402 | 260 ms | $0.02 |
| 44 h ago | Passed | 402 | 183 ms | $0.02 |
| 2 days ago | Passed | 402 | 183 ms | $0.02 |
| 2 days ago | Passed | 402 | 264 ms | $0.02 |
| 2 days ago | Passed | 402 | 184 ms | $0.02 |