Use the Disputes API to access disputes, accept a dispute, or challenge a dispute by uploading and submitting evidence.
Dispute objects are created by Square when a bank sends a notification that a cardholder is initiating a chargeback. Your application gets new
Dispute objects by listening for dispute webhook events, polling the Disputes API periodically by calling ListDisputes, or calling RetrieveDispute if the dispute ID is known.
Dispute object provides important details, including the
reason for the dispute, the current
state of the dispute, and the
due_at deadline by which the seller must respond (by accepting or challenging the dispute). This information should be provided to the seller using your application so that they can make the most appropriate decision regarding the dispute.
To accept a dispute, call the AcceptDispute endpoint. Square returns the disputed amount to the cardholder and updates the dispute state to
ACCEPTED. The dispute is now closed.
When a seller challenges a dispute, they must provide evidence that the payment was valid. Ultimately, the card-issuing bank determines the outcome of the dispute. However, the better evidence provided by the seller, the better chance they have of winning the dispute. Challenging a dispute using the Disputes API is a two-step process:
- Upload evidence - Your application provides one or more pieces of evidence related to the payment. These can be images, PDFs, or text. If available, Square automatically includes information such as business and cardholder details or receipts to supplement this evidence.
- Submit the evidence - Your application calls the SubmitEvidence endpoint to submit the provided evidence to the bank. Square changes the dispute state to
Before a seller can challenge a dispute, they need to see the reason. Your application must display the Dispute.reason, which lets the seller decide what evidence to provide to support the validity of the transaction. Your application can upload evidence of any DisputeEvidenceType for a dispute regardless of the reason, but choosing the most appropriate evidence type helps the seller make the best case to the bank, which increases their chances of winning a dispute. If no evidence type is provided, Square assigns the
The following table lists suggested evidence types to submit for each dispute reason. These suggestions are based on card network rules to help the seller make their best case when challenging a dispute.
- Use CreateDisputeEvidenceText for evidence such as tracking numbers, explanations, product descriptions, or any information that can be conveyed in a string with a maximum length of 500 characters.
- Use CreateDisputeEvidenceFile for evidence such as receipts, screenshots of email threads with customers, or any evidence in image or PDF format.
- Square supports these file types: image/tiff, application/pdf, image/jpeg, image/png, and image/heif. The file you upload can be up to 5 MB.
The following example shows a call to the CreateDisputeEvidenceFile endpoint, using a receipt scanned as a .tiff file as the evidence. In the request:
dispute_idis provided in the endpoint URL.
Authorizationheader specifies the access token of the seller responsible for the dispute.
- The request includes the path of the file to upload.
- The request body provides the
idempotency_key. For more information, see Idempotency.
Create dispute evidence file
The following is an example response:
To upload text evidence as a string, use the CreateDisputeEvidenceText endpoint as shown:
Create dispute evidence text
Prior to submission, your application can display a list of evidence provided for a dispute by calling the ListDisputeEvidence endpoint. If you know the
evidence_id, you can call RetrieveDisputeEvidence. Note that these endpoints don't return the evidence itself, only metadata about the uploaded evidence. Sellers should retain copies of any evidence submitted in case they want to reference it later.
If you need to remove a piece of evidence, call DeleteDisputeEvidence with the
evidence_id for the evidence you want to remove. Square doesn't send the bank any evidence that is removed. Note that you cannot remove evidence after submitting it to the bank using SubmitEvidence.
After uploading all relevant evidence for the dispute, call SubmitEvidence to submit the provided evidence to the card-issuing bank. Square changes the dispute state to
PROCESSING. At this point, the evidence for this dispute can no longer be removed or changed.
The following is an example response:
When available, Square automatically provides information to the card-issuing bank on a seller’s behalf to supplement the other evidence provided. This information might be business or cardholder details (name, address, phone number), Square receipts, related transactions, or tracking numbers.
When the seller challenges a dispute, there are three possible outcomes:
- Win - The bank accepts the evidence as sufficient proof of a legitimate payment. Square updates the dispute state to
WONand releases the held funds back to the seller’s bank account.
- Lose - The bank rejects the evidence as insufficient proof. Square updates the dispute state to
LOSTand the cardholder is refunded.
- Bank asks for more information - The bank is still deliberating and is requesting additional evidence. Square updates the dispute state to
EVIDENCE_REQUIRED. In this case, the seller can upload more evidence or accept the cardholder's dispute.
To receive the most timely information about disputes, subscribe to the
dispute.state.updated webhooks. When a bank notifies Square of a new payment dispute, Square creates a dispute and sends the
dispute.created webhook event notification, which includes the entire dispute object in its data.
The Disputes API supports the following webhooks: