Get customer statement

GET/api/v1/customer-statements/{customer_id}

Build an A/R statement for a customer over a date range.

Operation ID: get_customer_statement_api_v1_customer_statements__customer_id__get·View as markdown·OpenAPI slice

Authentication

Bearer token authentication. Pass your DayZero API token in the Authorization header and the target business UUID in x-business-id.

Parameters

Path

customer_idstringrequired

Query

start_datestring · date

Start of the statement period (defaults to 1 year ago).

end_datestring · date

End of the statement period (defaults to today).

as_of_datestring · date

Aging as-of date (defaults to end_date).

Responses

200Successful Response

customer_idstringrequired
customer_namestring
customer_emailstring
customer_addressstring
business_namestring
start_datestring · daterequired
end_datestring · daterequired
as_of_datestring · daterequired
opening_balanceintegerrequired
linesarray · StatementLinerequiredStatementLine
7 fields
datestring · daterequired
typestringrequired

invoice, payment, or credit.

referencestring

Invoice or credit memo number.

descriptionstring
chargesinteger

Amount added to the balance, in cents.

paymentsinteger

Amount reducing the balance, in cents.

balanceintegerrequired

Running balance after this line, in cents.

total_chargesintegerrequired
total_paymentsintegerrequired
closing_balanceintegerrequired
agingStatementAgingrequiredStatementAging
6 fields
currentinteger
days_1_30integer
days_31_60integer
days_61_90integer
days_91_plusinteger
totalinteger

401Unauthorized - Authentication required

403Forbidden - Insufficient permissions

404Not Found - Resource does not exist

422Validation Error

detailarray · ValidationErrorValidationError
5 fields
locarray · string | integerrequired
msgstringrequired
typestringrequired
inputobject
ctxobject