Skip to main content

PATCH /classic/cancel/:sGroupId

Cancel every bot in a classic group.

  • If the group is still INITIATED (unpaid), bots move straight to CANCELLED.
  • If the group is already RUNNING, bots are scheduled to cancel — they finish the in-flight swap, then stop.
  • Groups that are already initializing deposits cannot be cancelled.

Use case

User aborts a campaign (pre-payment or mid-run). No follow-up calls needed — wallets are drained and state settles automatically.

Path params

ParamRequiredDescription
sGroupIdyes13-char group id returned by /classic/initialize.

Response 200

{ "message": "Order canceled" }

Or, if the group was running:

{ "message": "Order scheduled to cancel" }

Errors

StatusMeaning
400Bots already paying-in, or in a state where cancel is not allowed.
403Group not owned by caller.
404Group not found.

Example

curl -X PATCH "$BASE_URL/classic/cancel/<sGroupId>" \
-H "Authorization: Bearer $ACCESS" \
-H "x-user-id: $USER_ID"