Extract Line Items from Invoice to JSON

Parse every row from any invoice table automatically — description, quantity, unit price, and total extracted via a single API call.

All line item fields Multi-page invoices JSON array output

Invoice line items are the core data in any invoice — the individual rows that describe each product or service billed, with quantities, unit prices, and totals. Extracting them manually from PDF invoices is slow, error-prone, and does not scale.

With the Parselyze API, you define which line item columns to extract once using the Template Builder, then submit any invoice and receive a structured JSON array containing every row — ready to push directly into your ERP, accounting tool, or database.

Fields commonly extracted per line item

Define any combination of these fields in your invoice template.

Description

e.g. "Cloud storage subscription — 1 TB"

Quantity

e.g. 3

Unit

e.g. "months"

Unit Price

e.g. 29.99

Discount

e.g. "10%"

Line Total

e.g. 80.97

Tax Rate

e.g. "20%"

SKU / Product Code

e.g. "CLO-STOR-1TB"

Real Example

Invoice line items extracted to JSON

A 3-line-item software invoice. This is the exact JSON returned by the API.

line_items_result.json
"line_items": [
  {
    "description":  "Cloud storage subscription — 1 TB",
    "sku":          "CLO-STOR-1TB",
    "quantity":     3,
    "unit":         "months",
    "unit_price":   29.99,
    "discount":     "10%",
    "line_total":   80.97
  },
  {
    "description":  "Priority support plan",
    "sku":          "SUPP-PRIO-M",
    "quantity":     1,
    "unit":         "month",
    "unit_price":   49.00,
    "discount":     null,
    "line_total":   49.00
  },
  {
    "description":  "One-time setup fee",
    "sku":          "SETUP-FEE",
    "quantity":     1,
    "unit":         null,
    "unit_price":   250.00,
    "discount":     null,
    "line_total":   250.00
  }
]

Typical workflows

What teams build once invoice line items are structured.

AP Reconciliation

Compare extracted line items against purchase orders to auto-approve or flag discrepancies in your accounts payable process.

Inventory Updates

Parse supplier invoice line items to automatically update stock levels and cost prices in your inventory system.

Spend Categorisation

Feed line item descriptions into your spend analytics tool to categorise costs by department, project, or product.

ERP Import

Use the extracted line item JSON to build import payloads for SAP, Oracle NetSuite, QuickBooks, or any other accounting system.

Frequently asked questions

What are invoice line items?

Invoice line items are the individual rows in an invoice table that describe each product or service billed. Each line typically includes a description, quantity, unit price, and line total. Extracting them as structured data eliminates manual entry into accounting systems.

Can Parselyze extract line items from multi-page invoices?

Yes. Parselyze processes multi-page PDF invoices and correctly concatenates line item tables that span multiple pages. The result is a single unified line_items array in the JSON response.

How are line items returned in the API response?

Line items are returned as a JSON array of objects. Each object contains the fields you defined in your template: description, quantity, unit_price, total, tax_rate, discount, and any custom fields you specify.

What if the invoice uses a non-standard table layout?

Use the Template Builder to define exactly which columns to extract and how they map to your field names. The AI handles varying column orders, merged cells, and non-standard headers without custom code.

Is there a limit on the number of line items that can be extracted?

No hard limit. Parselyze extracts all line items present in the invoice document, regardless of how many rows the table contains.

Extract invoice line items in seconds

50 pages/month free · No credit card required