List charge disputes
List all disputes for a specific charge. Returns disputes sorted by creation date with pagination capabilities.
Request Parametersโ
Required - 1 fieldRequired Parameters
`id`STRING(required)
The charge ID to retrieve disputes for. Must be a valid charge ID from your account.
Recommended - 3 fieldsRecommended Parameters
`limit`INTEGER(optional)
Number of disputes to return per page.
`offset`INTEGER(optional)
Number of disputes to skip for pagination. Use with limit to navigate through pages.
`order`STRING(optional)
Sort order by creation date.
Additional - 2 fieldsAdditional Parameters
Responsesโ
200
Successful list retrievalReturns a list object containing dispute data array and pagination metadata.
Response includes:
data- Array of dispute objectstotal- Total number of disputes for this chargelimit- Number of items per pageoffset- Current pagination offsetorder- Sort order appliedfrom/to- Date range applied
400
Bad requestInvalid parameters provided.
Common causes:
- Invalid date format (must be ISO 8601)
- Limit out of range (must be 1-100)
- Invalid offset value
401
UnauthorizedAuthentication failed. Invalid or missing API key.
Common causes:
- Missing Authorization header
- Invalid secret key
- Using public key instead of secret key
404
Not foundCharge ID does not exist.
Common causes:
- Incorrect charge ID
- Charge from different account
- Using test key for live charge (or vice versa)
5xx
Server errorServer-side error occurred. These are rare but should be handled gracefully.
How to handle:
- Retry the request with exponential backoff
- Check status.omise.co for service incidents
- See Error Handling for detailed guidance
Code samplesโ
- cURL
- Ruby
- Python
- Node.js
- PHP
- Java
- C#
- Go
curl "https://api.omise.co/charges/chrg_test_5xuy4w91xqz7d1w9u0t/disputes?limit=20&offset=0" \
-u skey_test_5xuy4w91xqz7d1w9u0t:
require 'omise'
Omise.api_key = 'skey_test_5xuy4w91xqz7d1w9u0t'
charge = Omise::Charge.retrieve('chrg_test_5xuy4w91xqz7d1w9u0t')
disputes = charge.disputes(limit: 20, offset: 0)
import omise
omise.api_secret = 'skey_test_5xuy4w91xqz7d1w9u0t'
charge = omise.Charge.retrieve('chrg_test_5xuy4w91xqz7d1w9u0t')
disputes = charge.disputes(limit=20, offset=0)
const omise = require('omise')({
secretKey: 'skey_test_5xuy4w91xqz7d1w9u0t'
});
const disputes = await omise.charges.listDisputes('chrg_test_5xuy4w91xqz7d1w9u0t', {
limit: 20,
offset: 0
});
<?php
define('OMISE_SECRET_KEY', 'skey_test_5xuy4w91xqz7d1w9u0t');
$charge = OmiseCharge::retrieve('chrg_test_5xuy4w91xqz7d1w9u0t');
$disputes = $charge->disputes(array(
'limit' => 20,
'offset' => 0
));
Client client = new Client.Builder()
.secretKey("skey_test_5xuy4w91xqz7d1w9u0t")
.build();
ScopedList<Dispute> disputes = client.charges()
.get("chrg_test_5xuy4w91xqz7d1w9u0t")
.disputes()
.limit(20)
.offset(0)
.send();
var client = new Client("skey_test_5xuy4w91xqz7d1w9u0t");
var disputes = await client.Charges.ListDisputes("chrg_test_5xuy4w91xqz7d1w9u0t", new ListOptions {
Limit = 20,
Offset = 0
});
client, _ := omise.NewClient(
"pkey_test_5xuy4w91xqz7d1w9u0t",
"skey_test_5xuy4w91xqz7d1w9u0t",
)
disputes, _ := client.ListChargeDisputes("chrg_test_5xuy4w91xqz7d1w9u0t", &operations.ListChargeDisputes{
List: operations.List{
Limit: 20,
Offset: 0,
},
})
Error and result codesโ
Dispute Status Valuesโ
| Status | Description | Next Steps |
|---|---|---|
open | Dispute is open and pending resolution | Submit evidence via dashboard |
pending | Evidence submitted, awaiting decision | Wait for card network decision |
won | Dispute resolved in merchant's favor | Funds returned to merchant |
lost | Dispute resolved in customer's favor | Funds debited from account |
Pagination Calculationโ
| Field | Calculation | Use |
|---|---|---|
| Next page | offset + limit | Get next set of results |
| Previous page | offset - limit (min 0) | Go back to previous page |
| Has more | offset + limit < total | Check if more pages exist |
| Page number | (offset / limit) + 1 | Current page number |
API Credentials
Try it outโ
Required - 1 fields
Recommended - 3 fields
Additional - 2 fields
Your IP:
...Loading...