API reference / Act as a platform
Get a customer's payment
GET/v1/platforms/{platformOrgId}/customers/{customerOrgId}/payments/{paymentId}
Acts on a linked customer with the platform's own key or team (platform:customer_accounts_view). Same as GET /v1/orgs/{orgId}/payments/{paymentId}.
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. |
paymentIdpath, uuidrequired | The payment id from create payment or list payments. Withdrawals use the same id. |
Response 200
A payment with its status timeline
| Field | What it does |
|---|---|
paymentPaymentrequired | A payment, deposit, or withdrawal on an account. |
payment.idstring (uuid)required | Payment id. Send it as paymentId to get, cancel, approve, or reject the payment. |
payment.account_idstring (uuid)required | Payezy account the money moved from or into. |
payment.directionenumrequired | Whether money came in or went out. One of: inbound, outbound. One of |
payment.kindstringrequired | How the money moved, for example a fiat deposit or a payout. |
payment.purposeenum | payment sends to a third party, withdrawal moves funds to the organization's own account, deposit is incoming One of |
payment.invoice_numberstring | Your invoice or bill number, up to 64 characters. It is stored on the payment. |
payment.statusstringrequired | Where the payment is in its lifecycle, such as pending_approval, processing, completed, failed, or canceled. |
payment.amountstringrequired | Payment amount as a decimal string in major units of asset. |
payment.assetstringrequired | Asset code, such as USD, USDC, or SBC. |
payment.feestringrequired | Fee reserved with the amount, as a decimal string. |
payment.railstringrequired | Rail that sent or received the money, such as ach_credit, wire, or onchain. |
payment.memostringrequired | Note stored with the payment, up to 140 characters. |
payment.failurePaymentFailure | Why a payment failed and the code to branch on. |
payment.failure.codestringrequired | Stable reason the payment failed. |
payment.failure.reasonstringrequired | Why this happened, or why the change is being made. |
payment.created_atstring (date-time)required | When this record was created, as an ISO-8601 timestamp. |
payment.completed_atstring (date-time) | When this finished, as an ISO-8601 timestamp. |
payment.counterparty_idstring (uuid) | Recipient id. A recipient is a counterparty. |
payment.recipientstring | Recipient name (outbound) |
payment.recipient_accountstring | Masked destination, e.g. Chase ••6789 |
payment.dest_assetstring | Stablecoin delivered (crypto payouts) |
payment.dest_networkstring | Network a crypto payout is delivered on. |
payment.tx_hashstring | On-chain hash or bank trace number |
payment.tx_urlstring | Block explorer page for tx_hash. Set only for a crypto payout whose network Payezy supports. |
payment.from_addressstring | On-chain address a crypto payout was sent from (the customer's holding wallet). |
payment.to_addressstring | On-chain address a crypto payout was sent to (the destination wallet). |
payment.approvals_requiredinteger | How many approvals the payment still needs. |
payment.created_bystring (uuid) | User id of the person who created this. |
eventsPaymentEvent[]required | Status changes, oldest first, or the webhook event names this endpoint receives. |
events[].statusstringrequired | Where this record is in its lifecycle. |
events[].messagestringrequired | What happened, in plain language. |
events[].atstring (date-time)required | When this happened, as an ISO-8601 timestamp. |
approvalsPaymentApproval[]required | Approve and reject decisions already recorded on this payment. |
approvals[].user_idstring (uuid)required | User id of the person. |
approvals[].emailstring | Email address. |
approvals[].decisionenumrequired | The approve or reject choice. One of: approve, reject. One of |
approvals[].commentstringrequired | Note left with a decision. |
approvals[].atstring (date-time)required | When this happened, as an ISO-8601 timestamp. |
approvals[].api_key_idstring (uuid) | The API key that decided, when a key did |
approvals[].via_platform_idstring (uuid) | The platform that decided on the customer's behalf |
legsPaymentLeg[]required | Partner steps that moved the money. |
legs[].seqintegerrequired | Order of this leg. The first step is 1. |
legs[].partnerstringrequired | Banking or payout partner that handled this. |
legs[].operationstringrequired | What the partner did for this leg of the payment. |
legs[].statusstringrequired | Where this record is in its lifecycle. |
legs[].amountstringrequired | Amount as a decimal string in major units, such as dollars. |
legs[].referencestring | Partner reference for this step, such as a bank trace or a transaction hash. |
can_approvebooleanrequired | The caller may approve or reject this payment now |
can_cancelbooleanrequired | Whether the caller may cancel this payment now. |