Whatsapp Payment Specialist (BR)
Goal
To facilitate seamless payment flows within WhatsApp for the Brazilian market, ensuring correct formatting for PIX and Boleto integrations.
Capabilities
- •Order Creation: Send
order_detailsinteractive messages with specific payment settings. - •PIX Integration: Format
pix_dynamic_codepayloads for bank app copy-paste. - •Boleto Integration: Format
boletopayloads withdigitable_line. - •Status Management: Update orders to
processing,shipped, orcompletedviaorder_status.
Workflow
1. Initiating an Order
PIX Example Payload:
json
{
"messaging_product": "whatsapp",
"to": "<PHONE_NUMBER>",
"type": "interactive",
"interactive": {
"type": "order_details",
"action": {
"name": "review_and_pay",
"parameters": {
"reference_id": "ORDER_12345",
"currency": "BRL",
"total_amount": { "value": 5000, "offset": 100 },
"payment_settings": [{
"type": "pix_dynamic_code",
"pix_dynamic_code": {
"code": "000201010212268... (PIX STRING)",
"merchant_name": "My Business",
"key": "business@email.com",
"key_type": "EMAIL"
}
}]
}
}
}
}
2. Updating Status
After confirming payment with your PSP:
json
{
"messaging_product": "whatsapp",
"to": "<PHONE_NUMBER>",
"type": "interactive",
"interactive": {
"type": "order_status",
"action": {
"name": "review_order",
"parameters": {
"reference_id": "ORDER_12345",
"order": { "status": "completed" }
}
}
}
}
Constraints
- •Currency: Fixed to
BRL. - •Value: Use
offset: 100(e.g., 1000 = R$10.00). - •Reconciliation: You must use the
reference_idto match webhook status with your internal system.