Skip to main content

cancel_all_orders

Function cancel_all_orders 

Source
pub async fn cancel_all_orders(
    __arg0: State<AppState>,
) -> Result<SonicJson<ApiResponse<CancelAllOrdersResponse>>, ApiError>
Expand description

Cancel all market-maker orders across all wallets (testnet only)

Cleans up orphan orders left by previous MM instances that used ephemeral wallets. Only available when modes.enable_test_endpoints=true.

Identifies MM orders by client_id matching the cli_\d+ pattern (from wallet_client.rs: format!("cli_{}", nonce)). User orders placed via the frontend are left untouched.