Payezydevelopers
Sandbox

API reference / Act as a platform

Quote a customer's payment

POST/v1/platforms/{platformOrgId}/customers/{customerOrgId}/payments/quote

Acts on a linked customer with the platform's own key or team (platform:customer_operate). Same as POST /v1/orgs/{orgId}/payments/quote. Prices each way to send a payment (rail, fee, arrival) without moving money.

Before you call it

  • Organizationplatform
  • Permissionplatform:customer_operate

Parameters

ParameterWhat it does
platformOrgIdpath, uuidrequiredYour platform's organization id. platformOrgId is the platform response's org_id.
customerOrgIdpath, uuidrequiredcustomerOrgId is the customer response's org_id.

Request body

FieldWhat it does
account_idstring (uuid)requiredPayezy account to send from. Use an id from list accounts.
external_account_idstring (uuid)requiredThe recipient's bank account or wallet
amountstringrequiredHow much to send, as a decimal string in major units. The fee from the quote is reserved on top of this.
assetenumStablecoin to deliver to a wallet (default USDC)

One of USDC SBC

railenumRail to use. Take it from the quote. Omit it and set policy to let Payezy choose. One of: ach_credit, same_day_ach_credit, wire, fednow_credit, onchain.

One of ach_credit same_day_ach_credit wire fednow_credit onchain

policyenumcheapest picks the lowest fee. fastest picks the earliest arrival. Ignored when rail is set. One of: cheapest, fastest.

One of cheapest fastest

Default "cheapest"

memostringNote that travels with the payment, up to 140 characters.
invoice_numberstringThe invoice or bill this payment settles

Response 200

Options ordered by the requested policy

FieldWhat it does
amountstringrequiredAmount as a decimal string in major units, such as dollars.
assetstringrequiredAsset code, such as USD, USDC, or SBC.
availablestringrequiredAvailable balance
optionsPaymentOption[]requiredRails that can send this payment, each with a fee and an arrival time.
options[].railstringrequiredHow the money moves. Send one of the values this field allows.
options[].feestringrequiredFee as a decimal string in the same units as the amount. Creating a payment reserves the amount plus this fee.
options[].eta_secondsintegerrequiredEstimated seconds until the money arrives.
options[].arrives_bystring (date-time)requiredWhen the money is expected to arrive, as an ISO-8601 timestamp.
options[].brandablebooleanrequiredThe recipient sees your business name
options[].payezy_feestringPayezy's fee (part of fee); 0 for customers billed through a platform
options[].network_feestringRail or network cost (part of fee)
options[].fee_linesFeeLine[]fee broken down; the lines sum to fee
options[].fee_lines[].kindenumrequiredpayezy: Payezy's fee; network: rail or network cost

One of payezy network

options[].fee_lines[].codestringrequiredBilling product code (payezy) or rail (network)
options[].fee_lines[].labelstringrequiredShort name chosen for this record.
options[].fee_lines[].amountstringrequiredAmount as a decimal string in major units, such as dollars.

Errors to handle

CodeWhat it means and what to do
insufficient_funds422The available balance cannot cover the amount plus fee.

Fund the account, or send less. Quote first to see the fee.

no_route422No enabled rail and partner can carry this payment.

Try another rail or asset, or drop the rail and use policy.

invalid_amount422Enter a positive amount.
single_payout_limit422The amount is above the organization's single-transfer limit.

Send less, or ask Payezy about your limits (getPaymentLimits shows them).

daily_payout_limit422Today's payouts would go over the daily limit.

Send the rest tomorrow, or ask Payezy about your limits.

Every error is a Problem document. Branch on code; quote request_id to support.