Order API

It is easy for users to create, retrieve, and cancel orders, and it supports orders for both spot and futures markets. Additionally, the API features customized endpoints for internal orders, the retrieval of order history according to specific characteristics, and the determination of the order liquidation status.

The ability to cancel orders forcibly with adequate authority and the capacity to monitor the status of orders, with a maximum display of 20 orders at any given moment, are two of the most important aspects.

The Orion protocol's Order API part includes a collection of endpoints that allow users to make, retrieve, and manage orders:

  1. GET /api/v1/order - This endpoint retrieves the status of a spot order based on the ID and address provided. This allows consumers to easily track the status of their spot orders.

  2. POST /api/v1/order - This endpoint is used to place an order on the spot. The request body contains the order specifics, such as the assets involved, the amount, and other important factors.

  3. DELETE /api/v1/order - With this API, users can cancel a spot order. The order to be canceled is identifiable by its ID and the address of the owner.

  4. POST /api/v1/order/internal - You may use this endpoint to place an internal spot order. The request body, like the typical spot order placement endpoint, provides the order information.

  5. GET /api/v1/order/futures - This endpoint retrieves the status of a futures order based on the ID and address provided. This allows users to immediately track their futures orders.

  6. POST /api/v1/order/futures - Users can use this endpoint to make a futures order. The request body contains the order specifics, such as the assets involved, the amount, and other factors.

  7. GET /api/v1/order/status - Retrieves spot orders based on their status. A maximum of 20 orders can be displayed at the same time.

  8. GET /api/v1/order/liquidation - This endpoint retrieves the status of a liquidation order using the order ID.

  9. POST /api/v1/order/history - This endpoint retrieves spot orders that meet specific criteria.

  10. POST /api/v1/order/futures/status - This endpoint retrieves futures orders based on their current state. A maximum of 20 orders can be displayed at once, same like the spot order equivalent.

  11. POST /api/v1/order/futures/history - This API retrieves futures orders that meet specific criteria.

  12. DELETE /api/v1/order/force/orderId - This endpoint allows users to cancel an order forcibly. The canceled order is identifiable by its ID.

This API area, in essence, offers the functionality required for the complete lifecycle management of spot and futures orders, from creation through retrieval and cancellation.

Last updated