Overview
USPS delivers invoice data as EPS transaction detail reports, with one row per charge (label purchase, refund, scan form, etc.). Each row becomes one line item in the Trackstar API. Unlike UPS or FedEx, a row is not tied to one shipment: a single EPS transaction can cover many packages, and a package can appear in several transactions.Files you’ll receive
Trackstar requests the EPS transaction detail report from the USPS reporting portal and serves it unchanged through the Files endpoint.- One CSV per date range. Each report covers up to 7 days. Its file name starts with
TRANSACTIONDETAILS-{CRID}-{start date}-{end date}, with dates asYYYY-MM-DD, and itsfile_typeiscsv. A daily sync usually produces one report. - Reports overlap by a day. USPS reports cover whole days, and each daily report starts on the date the previous one ended. Charges from that shared day appear in both files. The two copies are identical except for
ACH Withdrawal Amount(see below). Line items are not duplicated, because both copies produce the same line-itemid. If you process the raw files yourself, de-duplicate onPackage Identification Code (PIC)plusEPS Transaction ID.
Shape notes
- One row per charge. A label purchase is one row; a later refund or adjustment on the same package is a separate row with its own
EPS Transaction ID. - Rows don’t map 1:1 to shipments. One EPS transaction can cover many packages, so many rows can share an
EPS Transaction ID. The same PIC can appear on several rows, one per transaction that charged it. Account-level rows have no PIC at all. - Transaction types vary. Common values include
Label Purchase,Label Refund,SCAN Form Used,Carrier Pickup, andShipping Services File. TheTransaction Typecolumn becomes thecharge_descriptionin the Trackstar-normalized output. - Dates are space-separated.
Transaction Date/TimeusesYYYY-MM-DD HH:MM:SSformat. - Identifiers are wrapped in single quotes. USPS sends PIC, EFN, and customer reference numbers wrapped in single quotes, for example
'9234690377819201924530'. Trackstar keeps the quotes as sent, sotracking_numberand the line-itemidinclude them. Strip them if you need the bare number. ACH Withdrawal Amountis a report total. Every row carries the same value: the report’s total ACH withdrawal, not that row’s amount. UseTransaction AmountorPostagefor the row’s own charge.- Tracking numbers are IMpb barcodes. The
Package Identification Code (PIC)column holds the 20–22 digit USPS IMpb barcode (inside the quotes), which Trackstar maps totracking_number. - Pass-through fields. Trackstar reads 6 columns (
Package Identification Code (PIC),EPS Account #,EPS Transaction ID,Postage,Transaction Date/Time,Transaction Type). The remaining 15 columns pass through in therawfield.
Sample rows
The full CSV is shown here because USPS has only 21 columns. The downloadable CSV contains additional rows.Download
Download full sample CSV (1 header row + 25 data rows, 21 columns)All sample data is synthetic. Tracking numbers, account numbers, addresses, and reference fields are fabricated and do not correspond to any real shipments or customers.
Fields
Columns marked ✓ are parsed into the Trackstar
invoice_line_items schema; the rest are preserved in the raw field.