Disputes
List disputes
get/v1/disputes
Parameters
statusneeds_response | under_review | won | lostin queryqstringin querySearch: the dispute's or payment's id, or part of the payment's reference, description or customer email.
up to 100 characters
Responses
- 200OKobject
Show the fields
object"list"dataarray of DisputeFields of data
idstring (uuid)object"dispute"livemodebooleanmerchant_idstring (uuid)payment_intentstring (uuid)amountintegerMinor units (kobo, cents).
at least 0
held_amountintegerMinor units (kobo, cents).
at least 0
currencyNGN | USDreasonfraudulent | product_not_received | duplicate | credit_not_processed | generalstatusneeds_response | under_review | won | lostrespond_bystring (date-time)evidencestring | nullevidence_submitted_atstring (date-time) | nullcreated_atstring (date-time)resolved_atstring (date-time) | nullfeeintegerChargeback fee, charged when the dispute is lost (0 otherwise).
at least 0
fee_vatintegerVAT on the chargeback fee.
at least 0
accepted_atstring (date-time) | nullWhen you accepted the dispute instead of sending evidence.
merchant_notestring | nullYour note when accepting.
has_moreboolean
curl https://sandbox.api.biftpay.com/v1/disputes \
-H "Authorization: Bearer bp_test_..."{
"object": "list",
"data": [
{
"id": "…",
"object": "dispute",
"livemode": true,
"merchant_id": "…",
"payment_intent": "…",
"amount": 0,
"held_amount": 0,
"currency": "NGN",
"reason": "fraudulent",
"status": "needs_response",
"respond_by": "…",
"created_at": "…",
"fee": 0,
"fee_vat": 0
}
]
}Retrieve a dispute
get/v1/disputes/{id}
Parameters
idstring (uuid)in pathrequiredResponses
- 200OKDispute
Show the fields
idstring (uuid)object"dispute"livemodebooleanmerchant_idstring (uuid)payment_intentstring (uuid)amountintegerMinor units (kobo, cents).
at least 0
held_amountintegerMinor units (kobo, cents).
at least 0
currencyNGN | USDreasonfraudulent | product_not_received | duplicate | credit_not_processed | generalstatusneeds_response | under_review | won | lostrespond_bystring (date-time)evidencestring | nullevidence_submitted_atstring (date-time) | nullcreated_atstring (date-time)resolved_atstring (date-time) | nullfeeintegerChargeback fee, charged when the dispute is lost (0 otherwise).
at least 0
fee_vatintegerVAT on the chargeback fee.
at least 0
accepted_atstring (date-time) | nullWhen you accepted the dispute instead of sending evidence.
merchant_notestring | nullYour note when accepting.
- 404Not found, or not visible to this key
curl https://sandbox.api.biftpay.com/v1/disputes/{id} \
-H "Authorization: Bearer bp_test_..."{
"id": "…",
"object": "dispute",
"livemode": true,
"merchant_id": "…",
"payment_intent": "…",
"amount": 0,
"held_amount": 0,
"currency": "NGN",
"reason": "fraudulent",
"status": "needs_response",
"respond_by": "…",
"created_at": "…",
"fee": 0,
"fee_vat": 0
}The dispute's evidence files
get/v1/disputes/{id}/files
Parameters
idstring (uuid)in pathrequiredResponses
- 200OKFileList
Show the fields
object"list"dataarray of FileFields of data
idstring (uuid)object"file"file_namestringcontent_typestringsizeintegeruploaded_bymerchant | biftpaymessagestring (uuid) | nullThe case message it's attached to.
created_atstring (date-time)has_moreboolean - 404Not found, or not visible to this key
curl https://sandbox.api.biftpay.com/v1/disputes/{id}/files \
-H "Authorization: Bearer bp_test_..."{
"object": "list",
"data": [
{
"id": "…",
"object": "file",
"file_name": "…",
"content_type": "…",
"size": 1000,
"uploaded_by": "merchant",
"message": "…",
"created_at": "…"
}
],
"has_more": true
}Attach evidence (receipt, delivery proof, messages) before responding
post/v1/disputes/{id}/files
Up to 10 files, while the dispute needs a response and before the deadline (409 dispute_not_open, response_deadline_passed).
Parameters
idstring (uuid)in pathrequiredIdempotency-Keystringin headerrequiredA unique key per logical request, for example a UUID. Up to 255 characters.
up to 255 characters
Body
file_namestringrequiredup to 200 characters
content_typeapplication/pdf | image/jpeg | image/pngrequireddatastringrequiredBase64; up to 5 MB decoded
Responses
- 201The fileFile
Show the fields
idstring (uuid)object"file"file_namestringcontent_typestringsizeintegeruploaded_bymerchant | biftpaymessagestring (uuid) | nullThe case message it's attached to.
created_atstring (date-time) - 400Invalid request
- 404Not found, or not visible to this key
- 409The object is in a state that doesn't allow this
curl -X POST https://sandbox.api.biftpay.com/v1/disputes/{id}/files \
-H "Authorization: Bearer bp_test_..." \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{
"file_name": "…",
"content_type": "application/pdf",
"data": "…"
}'{
"id": "…",
"object": "file",
"file_name": "…",
"content_type": "…",
"size": 1000,
"uploaded_by": "merchant",
"message": "…",
"created_at": "…"
}One evidence file's content
get/v1/disputes/{id}/files/{fileId}
Parameters
idstring (uuid)in pathrequiredfileIdstring (uuid)in pathrequiredResponses
- 200The file, base64FileContent
Show the fields
object"file_content"file_namestringcontent_typestringdatastringBase64
- 404Not found, or not visible to this key
curl https://sandbox.api.biftpay.com/v1/disputes/{id}/files/{fileId} \
-H "Authorization: Bearer bp_test_..."{
"object": "file_content",
"file_name": "…",
"content_type": "…",
"data": "…"
}Remove an evidence file (before responding)
post/v1/disputes/{id}/files/{fileId}/remove
Parameters
idstring (uuid)in pathrequiredfileIdstring (uuid)in pathrequiredIdempotency-Keystringin headerrequiredA unique key per logical request, for example a UUID. Up to 255 characters.
up to 255 characters
Responses
- 200The remaining filesFileList
Show the fields
object"list"dataarray of FileFields of data
idstring (uuid)object"file"file_namestringcontent_typestringsizeintegeruploaded_bymerchant | biftpaymessagestring (uuid) | nullThe case message it's attached to.
created_atstring (date-time)has_moreboolean - 404Not found, or not visible to this key
- 409The object is in a state that doesn't allow this
curl -X POST https://sandbox.api.biftpay.com/v1/disputes/{id}/files/{fileId}/remove \
-H "Authorization: Bearer bp_test_..." \
-H "Idempotency-Key: $(uuidgen)"{
"object": "list",
"data": [
{
"id": "…",
"object": "file",
"file_name": "…",
"content_type": "…",
"size": 1000,
"uploaded_by": "merchant",
"message": "…",
"created_at": "…"
}
],
"has_more": true
}Submit evidence (once, before respond_by)
post/v1/disputes/{id}/respond
Parameters
idstring (uuid)in pathrequiredIdempotency-Keystringin headerrequiredA unique key per logical request, for example a UUID. Up to 255 characters.
up to 255 characters
Body
evidencestringrequiredup to 10000 characters
Responses
- 200OKDispute
Show the fields
idstring (uuid)object"dispute"livemodebooleanmerchant_idstring (uuid)payment_intentstring (uuid)amountintegerMinor units (kobo, cents).
at least 0
held_amountintegerMinor units (kobo, cents).
at least 0
currencyNGN | USDreasonfraudulent | product_not_received | duplicate | credit_not_processed | generalstatusneeds_response | under_review | won | lostrespond_bystring (date-time)evidencestring | nullevidence_submitted_atstring (date-time) | nullcreated_atstring (date-time)resolved_atstring (date-time) | nullfeeintegerChargeback fee, charged when the dispute is lost (0 otherwise).
at least 0
fee_vatintegerVAT on the chargeback fee.
at least 0
accepted_atstring (date-time) | nullWhen you accepted the dispute instead of sending evidence.
merchant_notestring | nullYour note when accepting.
- 404Not found, or not visible to this key
- 409The object is in a state that doesn't allow this
curl -X POST https://sandbox.api.biftpay.com/v1/disputes/{id}/respond \
-H "Authorization: Bearer bp_test_..." \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{
"evidence": "…"
}'{
"id": "…",
"object": "dispute",
"livemode": true,
"merchant_id": "…",
"payment_intent": "…",
"amount": 0,
"held_amount": 0,
"currency": "NGN",
"reason": "fraudulent",
"status": "needs_response",
"respond_by": "…",
"created_at": "…",
"fee": 0,
"fee_vat": 0
}Accept the dispute instead of sending evidence
post/v1/disputes/{id}/accept
The dispute is settled as lost straight away. The held amount goes back to the customer and the chargeback fee applies. You can't send evidence after this.
Parameters
idstring (uuid)in pathrequiredIdempotency-Keystringin headerrequiredA unique key per logical request, for example a UUID. Up to 255 characters.
up to 255 characters
Body
notestringAn optional note for Biftpay.
up to 1000 characters
Responses
- 200OKDispute
Show the fields
idstring (uuid)object"dispute"livemodebooleanmerchant_idstring (uuid)payment_intentstring (uuid)amountintegerMinor units (kobo, cents).
at least 0
held_amountintegerMinor units (kobo, cents).
at least 0
currencyNGN | USDreasonfraudulent | product_not_received | duplicate | credit_not_processed | generalstatusneeds_response | under_review | won | lostrespond_bystring (date-time)evidencestring | nullevidence_submitted_atstring (date-time) | nullcreated_atstring (date-time)resolved_atstring (date-time) | nullfeeintegerChargeback fee, charged when the dispute is lost (0 otherwise).
at least 0
fee_vatintegerVAT on the chargeback fee.
at least 0
accepted_atstring (date-time) | nullWhen you accepted the dispute instead of sending evidence.
merchant_notestring | nullYour note when accepting.
- 404Not found, or not visible to this key
- 409The object is in a state that doesn't allow this
curl -X POST https://sandbox.api.biftpay.com/v1/disputes/{id}/accept \
-H "Authorization: Bearer bp_test_..." \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{}'{
"id": "…",
"object": "dispute",
"livemode": true,
"merchant_id": "…",
"payment_intent": "…",
"amount": 0,
"held_amount": 0,
"currency": "NGN",
"reason": "fraudulent",
"status": "needs_response",
"respond_by": "…",
"created_at": "…",
"fee": 0,
"fee_vat": 0
}