availability

Managing disputes via the API is only available to merchants who can access disputes in the Braintree Control Panel.

You can only finalize disputes that have a status of Open. This will submit the evidence to the banks and update the status to Disputed.

important

You must call this function in order for the evidence to be submitted on the dispute.

Ruby
Copy
Copied
result = gateway.dispute.finalize("a_dispute_id")
This code snippet now uses gateway instance methods instead of class-level methods. Learn more.

If the dispute is successfully finalized, the result will be successful. Otherwise, check for validation errors.

Ruby
Copy
Copied
if result.success?
  # dispute successfully finalized
else
  p result.errors
end

If the dispute can't be found, it will raise a Braintree::NotFoundError.

Arguments
dispute_id required, String

The unique dispute identifier. You can only finalize disputes that have a status of Open.

Still have questions?

If you can’t find an answer, contact our Support team