API reference

Payouts

The payout endpoints, documented as defined. No payout method is available today.

EndpointPurpose
POST/api/v1/payouts/createSend money from your balance to a payee
POST/api/v1/payouts/queryLook up a payout
POST/api/v1/payouts/cancelCancel a payout that is still processing
POST/api/v1/payouts/precheckCheck your balance and the fee before creating a payout
{
  "payment_method": "CASH_APP",
  "merchant_payout_no": "PAYOUT-1001-069I",
  "trans_amount": {
    "currency": "USD",
    "value": "20.00"
  },
  "payee": {
    "account_id": "$testpayee",
    "account_type": "CASHTAG",
    "full_name": "Test Payee"
  },
  "notify_url": "https://merchant.example.com/hansapay/webhook"
}
200 · response
{
  "code": 5007,
  "msg": "payment_method CASH_APP is not available for payouts|unsupportedPayoutMethod"
}

Create a payout

POST/api/v1/payouts/create
FieldTypeRequiredDescription
payment_methodstringYesCASH_APP, PAYPAL or PIX
merchant_payout_nostringYesYour payout number, at most 64 characters, unique among your payouts
trans_amountobjectYesThe amount the payee receives, not including the fee
payeeobjectYesaccount_id, account_type, full_name, email, mobile, country, document, payee_id
memostringNoAt most 128 characters
notify_urlstringYesWhere to send payout.updated webhooks
metadatastringNoReturned in queries and webhooks
client_ipstringNo

account_type is one of EMAIL, MOBILE, CASHTAG, USERID, BANK_ACCOUNT or USDT_ADDRESS; for PIX also CPF, CNPJ or PHONE.

Response fields: payment_method, payout_no, merchant_payout_no, status, trans_amount, fee, total_debit (amount plus fee, in USD), next_action (WAIT_NOTIFY, SUCCESS or FAILED) and created_at.

The fee is the payout amount times your payout fee rate, plus your per-payout fee. Your available balance must cover total_debit; otherwise the request fails with 5004 insufficient merchant payout balance|insufficientFunds.

Query a payout

POST/api/v1/payouts/query

POST/api/v1/payouts/query with exactly one of payout_no or merchant_payout_no. Response fields: payment_method, payout_no, merchant_payout_no, status, status_reason, trans_amount, fee, total_debit, payee (with the account masked), metadata, paid_at, created_at and updated_at. An unknown payout returns 5002 payout not found|notFound.

Cancel a payout

POST/api/v1/payouts/cancel

POST/api/v1/payouts/cancel with exactly one of payout_no or merchant_payout_no, and an optional reason (at most 128 characters). Only a payout in PROCESSING can be cancelled, and only if the channel supports it. Cancelling a payout that is already cancelled succeeds again. Response fields: payout_no, merchant_payout_no and status.

Precheck

POST/api/v1/payouts/precheck

POST/api/v1/payouts/precheck with payment_method and, optionally, trans_amount. Response fields: payment_method, currency, available_balance, unsettled_balance, frozen_balance, spendable_balance, estimated_fee and estimated_debit (when an amount was sent), and can_payout. Without an amount, can_payout only says whether your available balance is above zero; it does not mean a payout method is available.

{
  "payment_method": "CASH_APP"
}
200 · response
{
  "code": 0,
  "msg": "success",
  "data": {
    "payment_method": "CASH_APP",
    "currency": "USD",
    "available_balance": {
      "currency": "USD",
      "value": "97.20"
    },
    "unsettled_balance": {
      "currency": "USD",
      "value": "137.00"
    },
    "frozen_balance": {
      "currency": "USD",
      "value": "80.00"
    },
    "spendable_balance": {
      "currency": "USD",
      "value": "97.20"
    },
    "can_payout": true
  }
}

Payout statuses

PENDING (accepted), PROCESSING (sent to the provider), SUCCESS, FAILED and CANCELED. The last three are final and are sent as payout.updated webhooks, with status_reason set to Payout failed, Payout request failed or Payout canceled where it applies.