BINANCE SAPI · C2C

Cancel Order API

Cancel an active peer-to-peer (C2C) trade order by providing the order number, a standard cancellation reason code, and optional contextual notes.

ENDPOINT
POST /sapi/v1/c2c/orderMatch/cancelOrder
Authentication USER_DATA / SIGNED
API Group C2C / Order Match
Method POST
Response JSON

Overview

This endpoint enables a buyer or trading bot to cancel an active C2C (P2P) order that has not yet been marked as paid. When cancelled, the locked cryptocurrency assets held in Binance escrow are released back to the seller's available balance or ad inventory.

Automated trading systems utilize this endpoint to handle expired payment sessions, counterparty timeout errors, or user-initiated cancellation requests cleanly.

01

Request Parameters

Parameters accepted in Body and HTTP Headers.

Parameter In Type Required Description
clientType Header STRING Required Client Device Type initiating the request (e.g., WEB, APP).
orderNumber Body STRING Required Unique identifier of the C2C order to cancel.
orderCancelReasonCode Body INT Optional Standardized reason code explaining the cancellation.
orderCancelAdditionalInfo Body STRING Optional Additional remarks or text description for the cancellation.
x-gray-env Header STRING Optional Environment flag identifier used for internal gray/stage testing.
x-trace-id Header STRING Optional Custom client trace ID for request tracking and debugging.
!
Cancellation Limits

Cancelling too many orders within a 24-hour window can temporarily restrict a user's ability to place new P2P orders. Ensure cancellation logic only triggers when strictly necessary.

02

Request Example

Example POST request using cURL to cancel an order.

cURL BASH
curl -X POST \
'https://api.binance.com/sapi/v1/c2c/orderMatch/cancelOrder' \
-H 'clientType: WEB' \
-H 'Content-Type: application/json' \
-d '{
  "orderNumber": "202608161234567890",
  "orderCancelReasonCode": 1,
  "orderCancelAdditionalInfo": "Payment method unavailable"
}'
03

Response

Example response returned on successful cancellation.

RESPONSE 200 OK
{
    "code": "000000",
    "message": "success",
    "data": null,
    "success": true
}

Response Fields

Field Type Description
code STRING Standard Binance status code ("000000" indicates success).
message STRING Response execution status or feedback message.
data NULL / VOID Void return payload on successful cancellation.
success BOOLEAN Indicates overall request execution result.
04

How It Works

Workflow for cancelling a C2C trade order.

01 Check Order State Verify order is unpaid and within cancellation window.
02 Pass Reason Code Attach orderNumber and cancellation reason in JSON body.
03 Send POST Request Issue request to /sapi/v1/c2c/orderMatch/cancelOrder.
04 Release Escrow Order status updates to CANCELLED and escrow unlocks.

Common Use Cases

Payment Timeout Handling

Automatically cancel buy orders when downstream payment gateways or bank rails fail to execute within limit windows.

Trader-Initiated Abort

Provide frontend cancellation buttons for users who choose not to proceed with a manual transfer.

Automated Error Recovery

Cancel stale or mismatched orders programmatically before unlocking allocated trading bot balances.



💬
Telegram WhatsApp