Chargebacks
Learn how to handle chargebacks, address disputes, and test integrations effectively.
A chargeback occurs when a cardholder disputes a charge with their issuing bank. When this happens, dLocal notifies your application asynchronously through a webhook.
Below, you'll find detailed information on how to manage chargebacks using dLocal’s API, including notification handling, dispute documentation uploads, and testing with our sandbox environment.
Overview
Chargeback handling
Manage incoming chargebacks effectively.
How chargebacks work Chargeback notifications Retrieve a chargebackDispute
resolution
Provide documentation to contest chargebacks.
Dispute management flow Upload documentation Dispute file requirementsChargeback handling
How chargebacks work
Understand the general chargeback process and key stakeholders involved.
Chargeback notifications
When a cardholder initiates a chargeback, dLocal will send an asynchronous notification (POST request) to the registered merchant chargeback notification URL with the following parameters:
| Property | Type | Description |
|---|---|---|
id | String | The chargeback ID. |
payment_id | String | The payment ID. |
created_date | String | The date of when the chargeback was executed. |
currency | String | The currency of the chargeback. |
amount | Positive Float | The amount of the chargeback. |
status | String | Current status of the chargeback. |
status_code | Integer | The status code of the chargeback. |
status_detail | String | The description of the chargeback's status. |
notification_url | String | URL where dLocal will send chargeback notifications and subsequent updates. |
order_id | String | ID given by the merchant in their system. |
chargeback_date | String | ISO 8601 timestamp indicating when the chargeback event was recorded by the acquirer/processor. |
chargeback_stage | String | Current stage of the chargeback process as reported by the acquirer/scheme. |
processor_id | String | Identifier of the processor/acquirer that originated or reported the chargeback (when available). |
reason_code | String | Numeric or alphanumeric code specifying the reason for the chargeback. |
reason_description | String | Description of the reason associated with the reason_code. |
arn | String | Acquirer Reference Number. A 23-digit identifier assigned by the acquirer to track the transaction across the card network. |
️ Secure notifications
Notifications from dLocal are digitally signed. Learn how to verify signatures.
Example notification (POST)
POST: {merchant.chargeback_url}
{
"id": "CHAR42342",
"payment_id": "PAY245235",
"created_date": "2025-10-21T17:38:57.000+0000",
"currency": "UYU",
"amount": 1000,
"status": "PENDING",
"status_code": 100,
"status_detail": "The chargeback is pending.",
"notification_url": "http://merchant.com/notifications",
"order_id": "1122334455667788",
"chargeback_date": "2025-10-21T17:38:57.000+0000",
"chargeback_stage": "OTHER",
"processor_id": "156",
"reason_code": "10.4",
"reason_description": "Other Fraud: Card-absent Environment/Condition.",
"arn": "74049384186711978854903"
}
Retrieve a chargeback
Fetch detailed information about a chargeback using the dLocal API endpoint.
Example request
$ curl \
-H 'X-Date: 2018-02-20T15:44:42.310Z' \
-H 'X-Login: {x-login}' \
-H 'X-Trans-Key: {x-trans-key}' \
-H 'Content-Type: application/json' \
-H 'Authorization: V2-HMAC-SHA256, Signature: 1bd227f9d892a7f4581b998c21e353b1...' \
https://api.dlocal.com/chargebacks/CHAR42342
Learn more about retrieving chargebacks.
Dispute resolution
Dispute management flow
The following diagram shows the different statuses a chargeback may go through, along with their transitions:
PENDING: Initial status after receiving a chargeback.- If you do not dispute the chargeback before the deadline:
- It becomes
COMPLETED. - Funds are permanently debited from your balance.
- It becomes
- If you dispute the chargeback before the deadline:
- It moves to
DISPUTE_RECEIVEDand after that will change toIN_DISPUTEonce the deadline passes. - Funds are temporarily debited from your balance during the dispute.
- It moves to
- After the dispute:
- If the issuer rules in favor of the merchant: Status changes to
REVERSAL, and the funds are credited back to your balance as a credit note. - If the issuer rules in favor of the cardholder: Status becomes
DISPUTE_LOST, and funds remain permanently debited from your balance.
- If the issuer rules in favor of the merchant: Status changes to
Chargeback status transitions
Upload dispute documentation
When disputing chargebacks, merchants must provide supporting documentation. dLocal will forward this evidence to the issuer bank for evaluation.
The Dispute API is available for merchants in all markets supported by dLocal.
Dispute file requirements
The uploaded files should have the following characteristics:
- Single PDF file per chargeback dispute.
- File must be base64-encoded within the POST request body.
- File size limit: 1Mb.
- Document language: English or local language of transaction country.
Example request
curl -X POST \
-H 'X-Date: 2018-02-20T15:44:42.310Z' \
-H 'X-Login: {x-login}' \
-H 'X-Trans-Key: {x-trans-key}' \
-H 'Content-Type: application/json' \
-H 'X-Version: 2.1' \
-H 'User-Agent: MerchantTest / 1.0 ' \
-H 'Authorization: V2-HMAC-SHA256, Signature: 1bd227f9d892a7f4581b998c21e353b1...' \
-d '{body}'
https://api.dlocal.com/chargebacks/dispute/CBK-12345-1512742-823b91f0-3b47-47f0-915c-f15d98d1a20b
//body:
{
"filename": "chargeback_dispute.pdf",
"content": "JVBERi0xLjMKJcTl8uXrp/Og0MTGCjMgMCBvYmoKPDwgL0ZpbHRlc ..."
}
Response codes
| Status | Status code | Description |
|---|---|---|
SUCCESS | 200 | Dispute documentation received successfully. |
REJECTED | 300 | The chargeback is no longer disputable as it is not in PENDING or INQUIRY status or due date is expired. |
REJECTED | 301 | Dispute file is larger than 1MB. |
REJECTED | 302 | Incorrect file - Not in PDF format, or malformed/corrupted contents. |
NOT FOUND | 404 | Chargeback not found. |
Testing & simulation
Simulate a chargeback (Sandbox only)
In production, chargebacks are initiated by the cardholder directly through their bank.
In the dLocal Sandbox environment, chargebacks can be simulated for testing purposes. To simulate a chargeback, submit a request specifying the desired status.
Example request
$ curl -X POST \
-H 'X-Date: 2018-02-20T15:44:42.310Z' \
-H 'X-Login: {x-login}' \
-H 'X-Trans-Key: {x-trans-key}' \
-H 'Content-Type: application/json' \
-H 'Authorization: V2-HMAC-SHA256, Signature: 1bd227f9d892a7f4581b998c21e353b1...' \
https://sandbox.dlocal.com/sandbox-tools/chargebacks
{
"payment_id" : "PAY4334346343",
"status" : "PENDING"
}
Updated 19 days ago
