List account disputes
curl --request GET \
--url https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes \
--header 'Authorization: Basic <encoded-value>'import requests
url = "https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes")
.header("Authorization", "Basic <encoded-value>")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'
response = http.request(request)
puts response.read_body{
"data": [
{
"notes": "fraudulent purchase",
"token": "dispute_token_1234",
"amount": 500,
"status": "ACTIVE",
"category": "FRAUD",
"resolved_at": "2021-07-01T00:27:09Z",
"created_time": "2021-07-01T00:27:09Z",
"updated_time": "2021-07-01T00:27:09Z",
"account_token": "account_token_12",
"ledger_entry_token": "journal_entry_token1222"
}
],
"count": 1,
"is_more": true,
"end_index": 0,
"start_index": 0
}{
"code": 123,
"message": "<string>"
}Credit Account Disputes
List account disputes
Retrieve an array of disputes on a credit account.
GET
/
credit
/
accounts
/
{account_token}
/
disputes
List account disputes
curl --request GET \
--url https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes \
--header 'Authorization: Basic <encoded-value>'import requests
url = "https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes")
.header("Authorization", "Basic <encoded-value>")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox-api.marqeta.com/v3/credit/accounts/{account_token}/disputes")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'
response = http.request(request)
puts response.read_body{
"data": [
{
"notes": "fraudulent purchase",
"token": "dispute_token_1234",
"amount": 500,
"status": "ACTIVE",
"category": "FRAUD",
"resolved_at": "2021-07-01T00:27:09Z",
"created_time": "2021-07-01T00:27:09Z",
"updated_time": "2021-07-01T00:27:09Z",
"account_token": "account_token_12",
"ledger_entry_token": "journal_entry_token1222"
}
],
"count": 1,
"is_more": true,
"end_index": 0,
"start_index": 0
}{
"code": 123,
"message": "<string>"
}GET////
Retrieve an array of disputes on a credit account.
This endpoint supports sorting and pagination.
URL path parameters
| Fields | Description |
|---|---|
| account_token string Required | Unique identifier of the credit account for which to retrieve the disputes. Send a GET request to /credit/accounts to retrieve existing credit account tokens.Allowable Values: Existing account token |
URL query parameters
| Fields | Description |
|---|---|
| count integer Optional | Number of disputes resources to retrieve. Allowable Values: 1–100 |
| start_index integer Optional | Sort order index of the first resource in the returned array. Allowable Values: 0 min |
| sort_by string Optional | Field on which to sort. Prefix the field name with a hyphen (-) to sort in descending order. Omit the hyphen to sort in ascending order.NOTE: You must sort using system field names such as lastModifiedTime, and not by the field names appearing in response bodies such as last_modified_time.Allowable Values: lastModifiedTime, -lastModifiedTime |
| ledger_entry_tokens array of strings Optional | Unique identifier of the journal entry in dispute. This type of identifier can only be used for authorization.clearing-type journal entries.Allowable Values: Existing authorization.clearing-type journal entry token |
| statuses array of strings Optional | Status of the dispute. Allowable Values: ACTIVE, REVERSED, AH_WON, AH_LOST, REFUNDEDValid dispute status |
Response body
| Fields | Description |
|---|---|
| count integer Returned | Number of resources returned. Allowable Values: 1-10 |
| start_index integer Returned | Sort order index of the first resource in the returned array. Allowable Values: Any integer |
| end_index integer Returned | Sort order index of the last resource in the returned array. Allowable Values: Any integer |
| is_more boolean Returned | A value of true indicates that more unreturned resources exist.Allowable Values: true, false |
| data array of objects Returned | Contains one or more disputes on a credit account. Allowable Values: One or more dispute objects |
| data[].token string Returned | Unique identifier of the dispute. Allowable Values: 36 char max |
| data[].ledger_entry_token string Returned | Unique identifier of the journal entry (authorization.clearing type only) in dispute.Allowable Values: Existing journal entry token |
| data[].account_token string Returned | Unique identifier of the credit account on which the dispute was created. Allowable Values: 36 char max Existing account token |
| data[].amount decimal Returned | Amount of the dispute. Allowable Values: Format: 0.00 |
| data[].status string Returned | Status of the dispute. - ACTIVE - The dispute is active and awaiting resolution.- REVERSED - The dispute has been reversed and is no longer active.- AH_WON - The account holder won the dispute.- AH_LOST - The account holder lost the dispute.Allowable Values: ACTIVE, REVERSED, AH_WON, AH_LOST, REFUNDED |
| data[].category string Returned | Category to which the dispute belongs. Allowable Values: FRAUD, AUTH, PROCESSING_ERROR, CONSUMER_DISPUTE |
| data[].notes string Conditionally returned | Additional information on the dispute (for example, a reason for the dispute). Allowable Values: 750 char max |
| data[].resolved_at datetime Conditionally returned | Date and time when the dispute was resolved and no longer in ACTIVE status.Allowable Values: Format: yyyy-MM-ddThh:mm:ssZ |
| data[].updated_time datetime Returned | Date and time when the dispute was last updated on Marqeta’s credit platform, in UTC. Allowable Values: Format: yyyy-MM-ddThh:mm:ssZ |
| data[].created_time datetime Returned | Date and time when the dispute was created on Marqeta’s credit platform, in UTC. Allowable Values: Format: yyyy-MM-ddThh:mm:ssZ |
Sample response body
JSON
{
"count": 1,
"start_index": 0,
"end_index": 0,
"is_more": true,
"data": [
{
"token": "dispute_token_1234",
"ledger_entry_token": "journal_entry_token1222",
"account_token": "account_token_12",
"amount": 500,
"status": "ACTIVE",
"category": "FRAUD",
"notes": "fraudulent purchase",
"resolved_at": "2021-07-01T00:27:09Z",
"updated_time": "2021-07-01T00:27:09Z",
"created_time": "2021-07-01T00:27:09Z"
}
]
}
Authorizations
Path Parameters
Query Parameters
Field on which to sort.
Prefix the field name with a hyphen (-) to sort in descending order.
Omit the hyphen to sort in ascending order.
NOTE:
You must sort using system field names such as lastModifiedTime, and not by the field names appearing in response bodies such as last_modified_time.
Available options:
lastModifiedTime, -lastModifiedTime Status of the dispute.
Status of the dispute.
ACTIVE- The dispute is active and awaiting resolution.REVERSED- The dispute has been reversed and is no longer active.AH_WON- The account holder won the dispute.AH_LOST- The account holder lost the dispute.WRITE_OFF- The dispute was written off.
Available options:
ACTIVE, REVERSED, AH_WON, AH_LOST, REFUNDED, WRITE_OFF Response
Expected response to a valid request
Return paginated disputes.
Was this page helpful?