Search code examples
square-connectsquare

Square Connect API: How to Identify the Payment is having any disputes


The Square Connect Dispute API is not having an option to retrieve the disputes which are created/resolved based on the Date Range, as well it's not having an option to retrieve the dispute based on the Payment ID. can you help me to know the dispute is exist for the the Payment Id? Note: We have evaluated the webhook API to monitor when the dispute is created/resolved. But we are looking to check is their any dispute is created against the Payment Id.


Solution

  • There's currently no direct way to see if a payment was part of a dispute. If you retrieve a dispute, it will have the payment_id as part of the response, but there's no way to search by payment_id directly. You could list the disputes, and find the payment_id from above, but that would require looping through all of the disputes in a given query, of course.