Skip to content

Disputes Rail

Dispute resolution, case management, and escalation workflows.

The Disputes Rail provides endpoints for managing customer disputes, resolution workflows, and escalation processes.

/api/v1/disputes
POST /api/v1/disputes

Create a new dispute.

Request Body:

{
"type": "TRANSACTION",
"category": "UNAUTHORIZED_TRANSACTION",
"customerId": "cust_123",
"transactionId": "txn_abc",
"amount": "5000.00",
"currency": "SAR",
"description": "Customer claims transaction was not authorized",
"evidence": ["doc_123", "doc_456"],
"priority": "HIGH"
}

Response:

{
"data": {
"disputeId": "dsp_abc123",
"caseNumber": "DSP-2025-0001",
"status": "OPEN",
"assignedTo": "agent_xyz",
"slaDeadline": "2025-01-25T10:00:00Z",
"createdAt": "2025-01-15T10:00:00Z"
}
}
GET /api/v1/disputes/:disputeId

Retrieve dispute details.

GET /api/v1/disputes

Query Parameters:

ParameterTypeDescription
statusstringFilter by status
categorystringFilter by category
prioritystringFilter by priority
assignedTostringFilter by assignee
customerIdstringFilter by customer
PATCH /api/v1/disputes/:disputeId

Update dispute details.

Request Body:

{
"status": "INVESTIGATING",
"notes": "Contacted merchant for transaction details"
}
POST /api/v1/disputes/:disputeId/comments

Add a comment to the dispute.

Request Body:

{
"content": "Merchant confirmed transaction was legitimate",
"internal": true,
"attachments": ["doc_789"]
}
POST /api/v1/disputes/:disputeId/escalate

Escalate to higher authority.

Request Body:

{
"reason": "Customer unsatisfied with initial resolution",
"escalateTo": "SUPERVISOR",
"notes": "Requires senior review"
}
POST /api/v1/disputes/:disputeId/resolve

Resolve the dispute.

Request Body:

{
"resolution": "CUSTOMER_FAVOR",
"action": "REFUND",
"amount": "5000.00",
"notes": "Merchant unable to provide authorization proof",
"compensation": {
"type": "GOODWILL",
"amount": "100.00"
}
}
GET /api/v1/disputes/:disputeId/timeline

Get dispute activity timeline.

Response:

{
"data": [
{
"timestamp": "2025-01-15T10:00:00Z",
"event": "CREATED",
"actor": "cust_123",
"details": "Dispute opened via mobile app"
},
{
"timestamp": "2025-01-15T10:05:00Z",
"event": "ASSIGNED",
"actor": "system",
"details": "Auto-assigned to agent_xyz"
}
]
}
TypeDescription
TRANSACTIONTransaction dispute
BILLINGBilling dispute
SERVICEService quality dispute
CONTRACTContract dispute
FEEFee dispute
CategoryDescription
UNAUTHORIZED_TRANSACTIONUnauthorized transaction
DUPLICATE_CHARGEDuplicate charge
INCORRECT_AMOUNTIncorrect amount
NOT_RECEIVEDProduct/service not received
QUALITY_ISSUEQuality issue
CANCELLATIONCancellation dispute
ResolutionDescription
CUSTOMER_FAVORResolved in customer favor
MERCHANT_FAVORResolved in merchant favor
PARTIALPartial resolution
WITHDRAWNCustomer withdrew dispute
EXPIREDDispute expired
PrioritySLA
CRITICAL4 hours
HIGH24 hours
MEDIUM3 days
LOW7 days
EventDescription
dispute.createdDispute created
dispute.assignedDispute assigned
dispute.escalatedDispute escalated
dispute.resolvedDispute resolved
dispute.sla.breachSLA breached