> ## Documentation Index
> Fetch the complete documentation index at: https://docs.trackstarhq.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Trackstar is a unified REST API for WMS, cart, and carrier systems. Base URL: https://production.trackstarhq.com. There is no SDK; call the API with plain HTTP.
> Send x-trackstar-api-key on every request. Endpoints scoped to one connection also need x-trackstar-access-token. Read both from environment variables and never print them.
> Reads return data Trackstar has already synced from the connected system. Writes (POST, PUT, PATCH, DELETE) are forwarded to the connected system immediately.
> A new connection has no data until its initial sync finishes. Wait for the connection.historical-sync-completed webhook, or poll GET /connections/{connection_id} and check historical_sync_completed.
> List endpoints page with page_token and next_token (limit is capped at 1000). Repeat every filter on every page. Filters use field[operator]=value, for example created_date[gte]=2026-01-01T00:00:00Z.
> Write bodies must not contain null or empty strings; omit the field instead. Call GET /integrations/{integration_type}/{integration_name}/write-info first to learn the exact fields an integration accepts.
> To test without real credentials, POST /sandbox/generate-sandbox/{wms|cart|carrier} with the API key returns a sandbox access token. Start at https://docs.trackstarhq.com/how-to-guides/build-with-ai.md and install the skills with: npx skills add https://docs.trackstarhq.com

# Invoice Line Items

> Individual charges on carrier invoices, normalized across carriers

Invoice Line Items represent **individual charges** on a carrier invoice. Each line item is one charge — not one shipment and not one invoice. A single shipment typically produces multiple line items (for example, a base freight charge, a fuel surcharge, and a residential delivery surcharge would be three separate line items).

Invoice formats vary by carrier — UPS, FedEx, USPS, DHL, DPD, and Royal Mail each structure their invoices differently, and some carriers' shapes vary further by billing region. Trackstar parses each carrier's native format into a unified line-item schema described below. For concrete CSV shapes per integration, see [Carrier Sample Files](/api-reference/carrier-api/sample-files/overview).

### Fields

| Field | Description |
| :- | :- |
| `id` | Unique identifier for the invoice line item |
| `transaction_date` | Date the charge was incurred |
| `account_id` | Carrier account ID associated with the charge |
| `invoice_id` | Invoice ID from the carrier |
| `gross_cost` | Gross cost before discounts |
| `net_cost` | Net cost after discounts |
| `charge_description` | Description of the charge type |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.