PayAlpha
  1. Pix Out
PayAlpha
  • Intro
  • Pix In
    • Create Pix In Transaction
      POST
    • Get Pix In Transaction
      GET
  • Pix Out
    • Create Pix Out Transaction
      POST
    • Get Pix Out Transaction
      GET
  • Webhooks (Reference)
    • Pix In - Payment Confirmed (transaction.paid)
      POST
    • Pix In - Refunded (transaction.refunded)
      POST
    • Pix Out - Transfer Confirmed (transfer.paid)
      POST
    • Pix Out - Transfer Failed (transfer.failed)
      POST
  • Wallets
    • Get Wallet Balances
      GET
  1. Pix Out

Create Pix Out Transaction

POST
{{baseUrl}}/api/v1/transactions/pix-out
Debits the company wallet and creates a Pix transfer to the destination key.
Amount: All values are in cents (e.g., 10000 = R$ 100.00).
Idempotency: The Idempotency-Key header (UUID format) is required to prevent duplicate transfers. If a request with the same key is sent again, the API returns the original response without processing a new transfer.
Webhooks: If postbackUrl is provided, webhook notifications will be sent to this URL. If webhookSecret is also provided, webhooks will include an HMAC-SHA256 signature in the X-Webhook-Signature header.

Request Headers#

HeaderRequiredDescription
Idempotency-KeyYesUnique UUID to prevent duplicate transfers
Content-TypeYesapplication/json
AuthorizationYesBasic Auth (inherited from collection)

Request Body Fields#

FieldTypeRequiredDescription
amountintegerYesAmount in cents (min: 100)
pixKeystringYesDestination Pix key
pixKeyTypestringYesCPF, CNPJ, EMAIL, PHONE, or RANDOM
destinationNamestringYesRecipient name
destinationDocumentstringYesRecipient CPF/CNPJ (digits only)
externalRefstringNoClient reference/external ID
postbackUrlstringNoURL for webhook notifications
webhookSecretstringNoSecret key for HMAC signature
metadataobjectNoCustom metadata for tracking

Requisição

Authorization
Envie suas requisições HTTP com um cabeçalho
Authorization
que contenha a palavra Basic seguida por um espaço e uma string codificada em base64 username:password
Exemplo:
Authorization: Basic *****************
Parâmetros Header

Parâmetros Bodyapplication/json

Examples

Respostas

🟢201
application/json
Body

🟠400
🟠401
🟠402
🟠422
Request Request Example
Shell
JavaScript
Java
Swift
curl --location -g --request POST '{{baseUrl}}/api/v1/transactions/pix-out' \
--header 'Idempotency-Key: {{$guid}}' \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data-raw '{
  "amount": 10000,
  "pixKey": "user@example.com",
  "pixKeyType": "EMAIL",
  "destinationName": "Maria Santos",
  "destinationDocument": "98765432100",
  "externalRef": "withdraw_123",
  "postbackUrl": "https://webhook.example.com/postback",
  "webhookSecret": "your-secret-key-for-hmac",
  "metadata": {
    "channel": "api"
  }
}'
Response Response Example
201 - 201 - Pix Out Created
{
  "success": true,
  "data": {
    "id": "dd5c6b14-8fb2-4eaf-b092-7e65a6f3182b",
    "secureId": "e9fa7447-40b9-46e6-b4e5-29bce3043edc",
    "status": "PROCESSING",
    "amount": 10000,
    "fee": 60,
    "netAmount": 10000,
    "pixKey": "maria.santos@example.com",
    "pixKeyType": "EMAIL",
    "destinationName": "Maria Santos",
    "destinationDocument": "98765432100",
    "requiresManualApproval": false,
    "acquirerTxId": null,
    "createdAt": "2025-12-12T02:11:40.090Z"
  }
}
Modificado em 2025-12-29 21:29:45
Página anterior
Pix Out
Próxima página
Get Pix Out Transaction
Built with