Skip to main content
POST
/
v1
/
withdrawals
Create a withdrawal
curl --request POST \
  --url https://api.yuvexpay.com/v1/withdrawals \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'X-Idempotency-Key: <x-idempotency-key>' \
  --data '
{
  "amount": 500,
  "method": "PIX",
  "currency": "BRL",
  "destination": {
    "type": "pix",
    "pixKey": "12345678900",
    "recipientDocument": "12345678900"
  },
  "description": "Weekly payout"
}
'
{
  "withdrawal": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "txId": "<string>",
    "grossAmount": 123,
    "feeAmount": 123,
    "netAmount": 123,
    "pixKey": "<string>",
    "pixKeyType": "<string>",
    "status": "PENDING",
    "isSandbox": true,
    "createdAt": "2023-11-07T05:31:56Z",
    "paymentMethod": "PIX",
    "currency": "BRL",
    "processedAt": "2023-11-07T05:31:56Z",
    "errorMessage": "<string>"
  }
}

Authorizations

Authorization
string
header
required

API access token obtained from POST /oauth/token. Include as Authorization: Bearer {token}.

Headers

X-Idempotency-Key
string
required

A unique string to ensure the request is processed only once. Must be unique per request. Valid for 24 hours.

Maximum string length: 100

Body

application/json
amount
number
required

Withdrawal amount (minimum R$10.00).

Required range: 10 <= x <= 1000000Must be a multiple of 0.01
destination
PIX destination · object
required

Where to send the funds.

method
enum<string>
default:PIX

Public withdrawals currently support PIX only.

Available options:
PIX
currency
enum<string>
default:BRL
Available options:
BRL
description
string

Internal description for this withdrawal.

Maximum string length: 500

Response

Withdrawal created.

withdrawal
object