curl --request PUT \
--url https://sandbox.cashfree.com/pg/disputes/{dispute_id}/accept \
--header 'x-api-version: <x-api-version>' \
--header 'x-client-id: <api-key>' \
--header 'x-client-secret: <api-key>'import requests
url = "https://sandbox.cashfree.com/pg/disputes/{dispute_id}/accept"
headers = {
"x-api-version": "<x-api-version>",
"x-client-id": "<api-key>",
"x-client-secret": "<api-key>"
}
response = requests.put(url, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {
'x-api-version': '<x-api-version>',
'x-client-id': '<api-key>',
'x-client-secret': '<api-key>'
}
};
fetch('https://sandbox.cashfree.com/pg/disputes/{dispute_id}/accept', 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.cashfree.com/pg/disputes/{dispute_id}/accept",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_HTTPHEADER => [
"x-api-version: <x-api-version>",
"x-client-id: <api-key>",
"x-client-secret: <api-key>"
],
]);
$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.cashfree.com/pg/disputes/{dispute_id}/accept"
req, _ := http.NewRequest("PUT", url, nil)
req.Header.Add("x-api-version", "<x-api-version>")
req.Header.Add("x-client-id", "<api-key>")
req.Header.Add("x-client-secret", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://sandbox.cashfree.com/pg/disputes/{dispute_id}/accept")
.header("x-api-version", "<x-api-version>")
.header("x-client-id", "<api-key>")
.header("x-client-secret", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.cashfree.com/pg/disputes/{dispute_id}/accept")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["x-api-version"] = '<x-api-version>'
request["x-client-id"] = '<api-key>'
request["x-client-secret"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"dispute_id": 433447817,
"dispute_type": "DISPUTE",
"reason_code": 1401,
"reason_description": "Fraud Transaction",
"dispute_amount": 10,
"created_at": "2023-01-18T11:26:58",
"respond_by": "2023-01-19T00:00:00",
"updated_at": "2023-01-18T11:26:58",
"resolved_at": "2023-01-18T11:26:58",
"dispute_status": "DISPUTE_MERCHANT_ACCEPTED",
"cf_dispute_remarks": "Load Testing",
"preferred_evidence": [],
"dispute_evidence": [],
"order_details": {
"order_id": "Load_test_0103_FGA4HF12AC",
"order_currency": "INR",
"order_amount": 10,
"cf_payment_id": 1489901523,
"payment_currency": "INR",
"payment_amount": 10
},
"customer_details": {
"customer_name": "John Ellur",
"customer_phone": 8281554863,
"customer_email": "john@cashfree.com"
}
}{
"message": "bad URL, please check API documentation",
"help": "Check latest errors and resolution from Merchant Dashboard API logs: https://bit.ly/4glEd0W Help Document: https://bit.ly/4eeZYO9",
"code": "request_failed",
"type": "invalid_request_error"
}{
"message": "authentication Failed",
"code": "request_failed",
"type": "authentication_error"
}{
"message": "something is not found",
"help": "Check latest errors and resolution from Merchant Dashboard API logs: https://bit.ly/4glEd0W Help Document: https://bit.ly/4eeZYO9",
"code": "something_not_found",
"type": "invalid_request_error"
}{
"message": "order with same id is already present",
"help": "Check latest errors and resolution from Merchant Dashboard API logs: https://bit.ly/4glEd0W Help Document: https://bit.ly/4eeZYO9",
"code": "order_already_exists",
"type": "invalid_request_error"
}{
"message": "something is not found",
"help": "Check latest errors and resolution from Merchant Dashboard API logs: https://bit.ly/4glEd0W Help Document: https://bit.ly/4eeZYO9",
"code": "request_invalid",
"type": "idempotency_error"
}{
"message": "Too many requests from IP. Check headers",
"code": "request_failed",
"type": "rate_limit_error"
}{
"message": "internal Server Error",
"help": "Check latest errors and resolution from Merchant Dashboard API logs: https://bit.ly/4glEd0W Help Document: https://bit.ly/4eeZYO9",
"code": "internal_error",
"type": "api_error"
}Accept Dispute by Dispute ID
Use this API to get accept the Dispute by specifying the Dispute ID.
curl --request PUT \
--url https://sandbox.cashfree.com/pg/disputes/{dispute_id}/accept \
--header 'x-api-version: <x-api-version>' \
--header 'x-client-id: <api-key>' \
--header 'x-client-secret: <api-key>'import requests
url = "https://sandbox.cashfree.com/pg/disputes/{dispute_id}/accept"
headers = {
"x-api-version": "<x-api-version>",
"x-client-id": "<api-key>",
"x-client-secret": "<api-key>"
}
response = requests.put(url, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {
'x-api-version': '<x-api-version>',
'x-client-id': '<api-key>',
'x-client-secret': '<api-key>'
}
};
fetch('https://sandbox.cashfree.com/pg/disputes/{dispute_id}/accept', 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.cashfree.com/pg/disputes/{dispute_id}/accept",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_HTTPHEADER => [
"x-api-version: <x-api-version>",
"x-client-id: <api-key>",
"x-client-secret: <api-key>"
],
]);
$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.cashfree.com/pg/disputes/{dispute_id}/accept"
req, _ := http.NewRequest("PUT", url, nil)
req.Header.Add("x-api-version", "<x-api-version>")
req.Header.Add("x-client-id", "<api-key>")
req.Header.Add("x-client-secret", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://sandbox.cashfree.com/pg/disputes/{dispute_id}/accept")
.header("x-api-version", "<x-api-version>")
.header("x-client-id", "<api-key>")
.header("x-client-secret", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.cashfree.com/pg/disputes/{dispute_id}/accept")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["x-api-version"] = '<x-api-version>'
request["x-client-id"] = '<api-key>'
request["x-client-secret"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"dispute_id": 433447817,
"dispute_type": "DISPUTE",
"reason_code": 1401,
"reason_description": "Fraud Transaction",
"dispute_amount": 10,
"created_at": "2023-01-18T11:26:58",
"respond_by": "2023-01-19T00:00:00",
"updated_at": "2023-01-18T11:26:58",
"resolved_at": "2023-01-18T11:26:58",
"dispute_status": "DISPUTE_MERCHANT_ACCEPTED",
"cf_dispute_remarks": "Load Testing",
"preferred_evidence": [],
"dispute_evidence": [],
"order_details": {
"order_id": "Load_test_0103_FGA4HF12AC",
"order_currency": "INR",
"order_amount": 10,
"cf_payment_id": 1489901523,
"payment_currency": "INR",
"payment_amount": 10
},
"customer_details": {
"customer_name": "John Ellur",
"customer_phone": 8281554863,
"customer_email": "john@cashfree.com"
}
}{
"message": "bad URL, please check API documentation",
"help": "Check latest errors and resolution from Merchant Dashboard API logs: https://bit.ly/4glEd0W Help Document: https://bit.ly/4eeZYO9",
"code": "request_failed",
"type": "invalid_request_error"
}{
"message": "authentication Failed",
"code": "request_failed",
"type": "authentication_error"
}{
"message": "something is not found",
"help": "Check latest errors and resolution from Merchant Dashboard API logs: https://bit.ly/4glEd0W Help Document: https://bit.ly/4eeZYO9",
"code": "something_not_found",
"type": "invalid_request_error"
}{
"message": "order with same id is already present",
"help": "Check latest errors and resolution from Merchant Dashboard API logs: https://bit.ly/4glEd0W Help Document: https://bit.ly/4eeZYO9",
"code": "order_already_exists",
"type": "invalid_request_error"
}{
"message": "something is not found",
"help": "Check latest errors and resolution from Merchant Dashboard API logs: https://bit.ly/4glEd0W Help Document: https://bit.ly/4eeZYO9",
"code": "request_invalid",
"type": "idempotency_error"
}{
"message": "Too many requests from IP. Check headers",
"code": "request_failed",
"type": "rate_limit_error"
}{
"message": "internal Server Error",
"help": "Check latest errors and resolution from Merchant Dashboard API logs: https://bit.ly/4glEd0W Help Document: https://bit.ly/4eeZYO9",
"code": "internal_error",
"type": "api_error"
}Authorizations
Client app ID. You can find your app id in the Merchant Dashboard.
Client secret key. You can find your secret key in the Merchant Dashboard.
Headers
API version to be used.
Request ID for the API call. Can be used to resolve tech issues. Communicate this in your tech related queries to Cashfree.
An idempotency key is a unique identifier you include with your API call. If the request fails or times out, you can safely retry it using the same key to avoid duplicate actions.
Path Parameters
Cashfree dispute ID to view the dispute details of an order.
Response
Success response for accepting a dispute by specifying the dispute ID.
DISPUTE, CHARGEBACK, RETRIEVAL, PRE_ARBITRATION, ARBITRATION Dispute amount may differ from transaction amount for partial cases.
This is the time when the dispute was created.
This is the time by which evidence should be submitted to contest the dispute.
This is the time when the dispute case was updated.
This is the time when the dispute case was closed.
DISPUTE_CREATED, DISPUTE_DOCS_RECEIVED, DISPUTE_UNDER_REVIEW, DISPUTE_MERCHANT_WON, DISPUTE_MERCHANT_LOST, DISPUTE_MERCHANT_ACCEPTED, DISPUTE_INSUFFICIENT_EVIDENCE, CHARGEBACK_CREATED, CHARGEBACK_DOCS_RECEIVED, CHARGEBACK_UNDER_REVIEW, CHARGEBACK_MERCHANT_WON, CHARGEBACK_MERCHANT_LOST, CHARGEBACK_MERCHANT_ACCEPTED, CHARGEBACK_INSUFFICIENT_EVIDENCE, RETRIEVAL_CREATED, RETRIEVAL_DOCS_RECEIVED, RETRIEVAL_UNDER_REVIEW, RETRIEVAL_MERCHANT_WON, RETRIEVAL_MERCHANT_LOST, RETRIEVAL_MERCHANT_ACCEPTED, RETRIEVAL_INSUFFICIENT_EVIDENCE, PRE_ARBITRATION_CREATED, PRE_ARBITRATION_DOCS_RECEIVED, PRE_ARBITRATION_UNDER_REVIEW, PRE_ARBITRATION_MERCHANT_WON, PRE_ARBITRATION_MERCHANT_LOST, PRE_ARBITRATION_MERCHANT_ACCEPTED, PRE_ARBITRATION_INSUFFICIENT_EVIDENCE, ARBITRATION_CREATED, ARBITRATION_DOCS_RECEIVED, ARBITRATION_UNDER_REVIEW, ARBITRATION_MERCHANT_WON, ARBITRATION_MERCHANT_LOST, ARBITRATION_MERCHANT_ACCEPTED, ARBITRATION_INSUFFICIENT_EVIDENCE Show child attributes
Show child attributes
{
"preferred_evidence": [
{
"document_type": "Delivery/Service Proof",
"document_description": "Proof that the cardholder/customer received the goods or services."
},
{
"document_type": "Statement of Service",
"document_description": "Account Statement of wallet where funds were loaded by customer."
}
]
}
Show child attributes
Show child attributes
[
{
"document_id": 18150,
"document_name": "disputeSampleFile.pdf",
"document_type": "DeliveryProof"
}
]
Show child attributes
Show child attributes
{
"order_id": "Load_test_0103_FGA4HF12AC",
"order_currency": "INR",
"order_amount": 10,
"cf_payment_id": 1489901523,
"payment_currency": "INR",
"payment_amount": 10
}
Show child attributes
Show child attributes
{
"customer_name": "Manideep Ellur",
"customer_phone": 8281554863,
"customer_email": "manideep.ellur@cashfree.com"
}
Was this page helpful?