Skip to main content

Get Ecommerce P&L

GET 

/api/ledger/reports/ecommerce-pnl

Ecommerce P&L workbook: income by month, income and COGS by sales channel by month down to gross profit and contribution margin, inventory, inventory in transit and vendor deposits at each month end, and the cost and count trust behind each month.

Required scope: accounting:read

Grant this scope to your token under Settings → Developer → Personal Access Tokens.

Every month carries its basis in basis_by_month: ledger (SKU's journal), operational (order lines and the inventory subledger), history (before the inventory start date, from the history register) or estimate (estimated history, never posted). On ledger months pnl lists income and direct-cost accounts; on other months it lists net sales and product COGS.

Revenue by channel always comes from order lines. Unassigned channel is the month total minus the named channels, so the channel blocks always add up to pnl; tie_out.flagged_months lists months where it exceeds 0.5% of revenue.

Amounts are in the account currency; percent rows are already multiplied by 100; null means the figure does not apply to that month's basis.

Authentication: Requires Bearer token with the accounting scope and the accounting.index permission.

Request​

Responses​

OK

Response Headers
    Content-Type