Decaf
Conteúdo

Referência da API/Destinatários

Destinatários

Um destinatário é um destino salvo com exatamente um tipo: conta bancária, PagoMóvil, carteira, telefone, e-mail ou usuário Decaf. Pergunte à API quais campos cada corredor exige em vez de fixá-los no código: uma CLABE de 18 dígitos no México, uma chave PIX e CPF ou CNPJ no Brasil, um código SWIFT e documento de identidade em Hong Kong. Campos bancários e de identidade voltam mascarados.

Required recipient fields for a channel

GET/channels/{channel}/requirements

Parâmetros

  • channelpathstringobrigatório

Resposta 200

{
  "channel": "spei_mxn",
  "recipient_type": "bank_account",
  "fields": [
    {
      "name": "holder_name",
      "type": "string",
      "required": true
    },
    {
      "name": "clabe",
      "type": "string",
      "required": true,
      "pattern": "^[0-9]{18}$"
    },
    {
      "name": "recipient_kind",
      "type": "enum",
      "values": [
        "individual",
        "business"
      ],
      "required": true
    }
  ],
  "limits": {
    "min": "30.12",
    "max": "300000.00",
    "currency": "USDC"
  }
}

Exemplos: Required recipient fields for a channel

curl -X GET https://sandbox.api.decaf.so/v1/channels/spei_mxn/requirements \
  -H "Authorization: Bearer $DECAF_API_KEY"

Create a recipient

POST/recipients

Parâmetros

  • Idempotency-Keyheaderstringopcional
CampoTipoobrigatórioObservações
typeRecipientTypeobrigatório
countrystringopcional
currencystringopcional
namestringopcional
kindenum: individual, businessopcional
external_idstringopcional
bank_accountobjectopcionalFields from the channel requirements.
pagomovilobjectopcional
walletobjectopcional
phoneobjectopcional
emailobjectopcional
decaf_userobjectopcional

Requisição

{
  "type": "bank_account",
  "country": "HK",
  "currency": "HKD",
  "external_id": "vendor-4471",
  "name": "Brightway Electronics Ltd",
  "kind": "business",
  "bank_account": {
    "bank_name": "HSBC",
    "account_number": "123456789012",
    "swift": "HSBCHKHHHKH",
    "id_document_number": "12345678-000-01-23-4"
  }
}

Resposta 201

{
  "id": "rcp_9d1a",
  "type": "bank_account",
  "country": "HK",
  "currency": "HKD",
  "name": "Brightway Electronics Ltd",
  "kind": "business",
  "external_id": "vendor-4471",
  "status": "ready",
  "channels": [
    "chats_hkd"
  ],
  "bank_account": {
    "bank_name": "HSBC",
    "account_number": "•••• 9012",
    "swift": "HSBCHKHHHKH"
  },
  "created_at": "2026-09-16T14:59:00Z"
}

Erros: 422 recipient_not_ready

Exemplos: Create a recipient

curl -X POST https://sandbox.api.decaf.so/v1/recipients \
  -H "Authorization: Bearer $DECAF_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"type":"bank_account","country":"HK","currency":"HKD","external_id":"vendor-4471","name":"Brightway Electronics Ltd","kind":"business","bank_account":{"bank_name":"HSBC","account_number":"123456789012","swift":"HSBCHKHHHKH","id_document_number":"12345678-000-01-23-4"}}'

List recipients

GET/recipients

Parâmetros

  • typequeryenum: bank_account, pagomovil, wallet, phone, email, decaf_useropcional
  • countryquerystringopcional
  • limitqueryintegeropcional
  • cursorquerystringopcional

Get a recipient

GET/recipients/{id}

Parâmetros

  • idpathstringobrigatório

Update a recipient

PATCH/recipients/{id}

Parâmetros

  • idpathstringobrigatório
CampoTipoobrigatórioObservações
typeRecipientTypeobrigatório
countrystringopcional
currencystringopcional
namestringopcional
kindenum: individual, businessopcional
external_idstringopcional
bank_accountobjectopcionalFields from the channel requirements.
pagomovilobjectopcional
walletobjectopcional
phoneobjectopcional
emailobjectopcional
decaf_userobjectopcional

Delete a recipient

DELETE/recipients/{id}

Parâmetros

  • idpathstringobrigatório

Check whether a phone or email can receive

GET/recipients/check

Says before sending whether a person in that country can receive, and by which methods.

Parâmetros

  • typequeryenum: phone, emailobrigatório
  • numberquerystringopcional
  • addressquerystringopcional

Resposta 200

{
  "receivable": true,
  "country": "MX",
  "methods": [
    "spei_bank",
    "decaf_wallet"
  ],
  "kyc_required_for": [
    "spei_bank"
  ]
}

Obtenha acesso

Construa contra o sandbox esta semana.

Conte-nos os corredores de que precisa e quem você paga. As chaves de sandbox são emitidas por uma pessoa.