API reference / Act as a platform
Get a customer's statement
GET/v1/platforms/{platformOrgId}/customers/{customerOrgId}/accounts/{accountId}/statement
Acts on a linked customer with the platform's own key or team (platform:customer_accounts_view). Same as GET /v1/orgs/{orgId}/accounts/{accountId}/statement.
Before you call it
- Organization
platform - Permission
platform:customer_accounts_view
Parameters
| Parameter | What it does |
|---|---|
platformOrgIdpath, uuidrequired | Your platform's organization id. platformOrgId is the platform response's org_id. |
customerOrgIdpath, uuidrequired | customerOrgId is the customer response's org_id. |
accountIdpath, uuidrequired | The Payezy account id from list accounts. |
beforequery, date-time | Return items older than this ISO-8601 timestamp. Pass next_before from the previous page. |
limitquery, integer | How many items to return. 1 to 200, default 50 |
Response 200
Ledger lines for the account, newest first
| Field | What it does |
|---|---|
accountFinancialAccountrequired | A Payezy account and its ledger balances. This is the account you pay from. |
account.idstring (uuid)required | Payezy account id. Send it as accountId or account_id. |
account.namestringrequired | Name of the Payezy account. |
account.currencystringrequired | ISO currency code, such as USD. |
account.statusenumrequired | Whether the account is open, frozen, or closed. One of: active, frozen, closed. One of |
account.balanceBalancerequired | USD amounts as decimal strings. Available excludes holds and pending credits. |
account.balance.currencystringrequired | ISO currency code, such as USD. |
account.balance.postedstringrequired | Ledger balance, including amounts that are not available to spend yet, as a decimal string. |
account.balance.availablestringrequired | Balance that can be spent now, as a decimal string. |
account.balance.pending_instringrequired | Incoming funds not yet settled |
account.balance.pending_outstringrequired | Held for payouts in flight |
account.created_atstring (date-time)required | When this record was created, as an ISO-8601 timestamp. |
itemsStatementLine[]required | Records in this page. |
items[].idstring (uuid)required | Identifier of this record. |
items[].transaction_idstring (uuid)required | Payment id of this transaction. Withdrawals and deposits use the same id space. |
items[].directionenumrequired | credit adds to the balance One of |
items[].amountstringrequired | Amount as a decimal string in major units, such as dollars. |
items[].statusenumrequired | Where this record is in its lifecycle. One of: pending, posted. One of |
items[].descriptionstringrequired | Description of the statement line. |
items[].payment_idstring (uuid) | Payment id. A withdrawal is stored as a payment, so this is also the withdrawal id. |
items[].effective_atstring (date-time)required | When this price or setting takes effect, as an ISO-8601 timestamp. |
next_beforestring (date-time) | Pass this value as the before query parameter to load the next page of older items. |