CancelGroupPendingTrade¶
Info
DELETE https://{some_domain}/trade/cancel/group
Cancels multiple pending orders for a specific user in one request.
If symbol is provided, only pending orders for that symbol are considered.
Authorization¶
All requests must include a JWT token:
Authorization: <JWT_TOKEN>
The token is issued by the authentication method (/sign/in) and contains session info (login, type, expiration).
With runtime protocol v2, this close/cancellation endpoint remains available when the license lease is inactive, subject to its normal authorization and account/order checks. Risk-increasing opens and modifications are gated separately.
Copy-follower manual trading policy¶
For authenticated user/customer requests, an enabled copy follower's
manual_trading_mode is enforced after account/order ownership checks:
0rejects all manual trade writes with HTTP403,COPY_MANUAL_TRADING_DISABLED(Manual trading is disabled for this copy follower).1permits writes to non-copied orders and rejects changes to copied orders with HTTP403,COPY_COPIED_ORDER_MANUAL_FORBIDDEN(Manual changes to copied orders are disabled for this copy follower).2permits manual writes to copied and non-copied orders.
| HTTP | Error | Message |
|---|---|---|
403 |
COPY_MANUAL_TRADING_DISABLED |
Manual trading is disabled for this copy follower |
403 |
COPY_COPIED_ORDER_MANUAL_FORBIDDEN |
Manual changes to copied orders are disabled for this copy follower |
This applies to opens, modifications, closes, pending-order changes, and group operations. A group operation that matches a protected copied order is rejected before any order is changed. Staff and internal requests bypass this follower policy.
Request¶
Content-Type: application/json
Body Parameters¶
| Field | Type | Required | Description |
|---|---|---|---|
login |
int | Yes | User account login ID whose pending orders will be cancelled |
symbol |
string | No | Symbol filter (e.g. EURUSD) |
Response¶
Success (200)¶
{
"rows": [
{
"accepted": true,
"order": 123456,
"state": 9,
"login": 1001,
"symbol": "EURUSD",
"cmd": 2,
"volume": 100
}
],
"matched": 1,
"cancelled": 1,
"failed": 0
}
Partial Success (207)¶
Returned when some pending orders were accepted for cancellation and some failed.
Error Responses¶
| Code | Error | Description |
|---|---|---|
| 400 | INVALID_DATA |
Validation failed, missing or incorrect request fields |
| 404 | RET_NOT_FOUND |
No matching pending trades found for the request |
| 409 | mixed batch failure | Matching orders were found, but none were accepted for cancellation |
Note: Failed pending orders are returned in
failures. Successful requests are returned inrowsas acknowledgment objects.
Example¶
Request¶
DELETE https://{some_domain}/trade/cancel/group
Authorization: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...
Content-Type: application/json
{
"login": 1001,
"symbol": "EURUSD"
}
Response¶
{
"rows": [
{
"accepted": true,
"order": 123456,
"state": 9,
"login": 1001,
"symbol": "EURUSD",
"cmd": 2,
"volume": 100
},
{
"accepted": true,
"order": 123457,
"state": 9,
"login": 1001,
"symbol": "EURUSD",
"cmd": 3,
"volume": 100
}
],
"matched": 2,
"cancelled": 2,
"failed": 0
}