UntangledAPI
Extract

Receipt

Extract merchant, date, line items, and totals from a receipt.

POST /v1/extract/receipt is tuned for retail and food-service receipts — the kind of document with a header, columnar line items, and a totals block. Use Invoice for B2B invoices.

Request

curl https://api.untangledapi.com/v1/extract/receipt \
  -H "x-api-key: $UNTANGLED_KEY" \
  -H "content-type: application/json" \
  -d '{
    "document": {
      "text": "BLUE BOTTLE COFFEE\n2026-04-12 09:14\nLatte 5.50\nCroissant 4.25\nSubtotal 9.75\nTax 0.85\nTotal 10.60\nVisa ****1234"
    }
  }'

Response

{
  "data": {
    "merchant": "BLUE BOTTLE COFFEE",
    "transaction_date": "2026-04-12T09:14:00",
    "currency": "USD",
    "items": [
      { "name": "Latte", "price": 5.50 },
      { "name": "Croissant", "price": 4.25 }
    ],
    "subtotal": 9.75,
    "tax": 0.85,
    "total": 10.60,
    "payment_method": "Visa ****1234"
  },
  "model": "claude-haiku-4-5",
  "usage": {
    "inputTokens": 360,
    "outputTokens": 120
  }
}

Fields

FieldTypeNotes
merchantstringThe store / restaurant name.
transaction_datestring (ISO 8601) | nullIf a time is present it's included; otherwise just the date.
currencyISO 4217 | null
items[]array{ name, price, quantity? }.
subtotal / tax / totalnumber | null
payment_methodstring | nullLast four digits if present, otherwise "Cash" / "Card" / etc.

Tip extraction

Tips are surfaced as a separate field if the document has a clear Tip: line. If the receipt only shows a total-after-tip, we don't infer a tip — use the line-item structure or a Custom schema if you need it.

On this page