API reference / Payments and approvals
Quote a payment
POST/v1/orgs/{orgId}/payments/quote
Prices each way to send a payment (rail, fee, arrival) without moving money.
When to use it
Before every payment, to show the fee and arrival time for each rail. Pick policy cheapest or fastest, or a specific rail.
Before you call it
- Permission
payments:create
Parameters
| Parameter | What it does |
|---|---|
orgIdpath, uuidrequired | The organization the call acts on. For platform calls, your platform's id; for customer calls, the customer's organization id. Get them from getMe or the customer list. |
Request body
| Field | What it does |
|---|---|
account_idstring (uuid)required | No description in the spec yet. |
external_account_idstring (uuid)required | The recipient's bank account or wallet |
amountstringrequired | No description in the spec yet. |
assetenum | Stablecoin to deliver to a wallet (default USDC) One of |
railenum | No description in the spec yet. One of |
policyenum | No description in the spec yet. One of Default |
memostring | No description in the spec yet. |
invoice_numberstring | The invoice or bill this payment settles |
Response 200
Options ordered by the requested policy
| Field | What it does |
|---|---|
amountstringrequired | No description in the spec yet. |
assetstringrequired | No description in the spec yet. |
availablestringrequired | Available balance |
optionsPaymentOption[]required | No description in the spec yet. |
options[].railstringrequired | No description in the spec yet. |
options[].feestringrequired | No description in the spec yet. |
options[].eta_secondsintegerrequired | No description in the spec yet. |
options[].arrives_bystring (date-time)required | No description in the spec yet. |
options[].brandablebooleanrequired | The recipient sees your business name |
options[].payezy_feestring | Payezy's fee (part of fee); 0 for customers billed through a platform |
options[].network_feestring | Rail or network cost (part of fee) |
options[].fee_linesFeeLine[] | fee broken down; the lines sum to fee |
options[].fee_lines[].kindenumrequired | payezy: Payezy's fee; network: rail or network cost One of |
options[].fee_lines[].codestringrequired | Billing product code (payezy) or rail (network) |
options[].fee_lines[].labelstringrequired | No description in the spec yet. |
options[].fee_lines[].amountstringrequired | No description in the spec yet. |
Errors to handle
| Code | What it means and what to do |
|---|---|
insufficient_funds422 | The available balance cannot cover the amount plus fee. Fund the account, or send less. Quote first to see the fee. |
no_route422 | No enabled rail and partner can carry this payment. Try another rail or asset, or drop the |
invalid_amount422 | Enter a positive amount. |
single_payout_limit422 | The amount is above the organization's single-transfer limit. Send less, or ask Payezy about your limits ( |
daily_payout_limit422 | Today'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.