Skip to main content

Modify Order via WebSocket

To modify orders on Rails platform, use the WebSocket API and subscribe to the Order Creation Stream. The specifications and behavior remain the same.

Order Modification Workflow

Order modification is done by submitting a Modify Order request via the Order Creation Stream. You will receive four responses in sequence:
  • Acknowledgment: Confirms the request was received and validates basic parameters
  • Original Order Modified Notice: Confirms the original order has been successfully cancelled and is no longer present in the system
  • New Order Pending Notice: Confirms a new order was created with the updated parameters, pending acceptance
  • Creation Confirmation: Confirms the new order was accepted and created in the order book
Key differences: Note that a unique clientRequestId can be used to correlate acknowledgment, confirmation, and any error responses for a single request.

Comparison with Cancel and Create Workflow

The order modification workflow provides a more streamlined process with fewer steps and lower overall latency compared to cancelling an order and creating a new one separately. Despite modifying an existing order, the modified order is treated as a new order in the order book with a new order ID, and the original order is cancelled. Since it’s essentially a cancellation followed by a new order creation, it’s subject to the same Order Limits and Restrictions as a regular order creation.