GetOrderStatuses - Get Order Status Data
Retrieve order status events at a specific position from Hyperliquid L1 Gateway via gRPC. Get order lifecycle data for analysis and auditing.
Retrieve order status events at a specific position from the Hyperliquid L1 Gateway.
Full Code Examples
Clone our gRPC Code Examples Repository for complete, runnable implementations in Go, Python, and Node.js.
When to Use This Method
GetOrderStatuses is essential for:
- Order Reconciliation - Verify order lifecycle events at a specific block
- Rejection Analysis - Retrieve and classify rejections at a point in time
- Auditing - Confirm status transitions at specific blocks
- Debugging - Investigate specific order outcomes during development
Method signature
rpc GetOrderStatuses(GetRequest) returns (Record) {}V3 accepts an inclusive position.block_number or Unix-millisecond position.timestamp; explicit zero is invalid. A positioned call returns the selected envelope. An empty GetRequest waits for the next status record written after the call begins, so set a deadline.
filter: {
fields: {
field: "coins"
op: FILTER_OP_IN
values: "BTC"
}
}Order statuses accept users and coins filters. User matching is case-insensitive and coin matching is case-sensitive; values within a field use OR semantics and separate fields use AND semantics. A zero-match unary request returns the selected Record with data containing events: []. A pruned position returns NOT_FOUND; malformed filters return INVALID_ARGUMENT.
Common Use Cases
For V3, select each record with GetRequest.position.block_number, decode Record.data, and inspect the events array. This supports single-block inspection and bounded searches for rejection statuses.
Order Status Field Reference
GetOrderStatuses returns the same format as StreamOrderStatuses. See the StreamOrderStatuses documentation for the complete field reference, including status values and the order object.
Best Practices
- Position Selection: Use the exact sequential block cursor for precise queries; timestamp lookups may resolve to different blocks across requests
- Stable Keys: Index per-order state on
(coin, oid), never onoidalone - Defensive Parsing: Handle nullable
hashandbuilderand the non-exhaustivestatusset - Error Recovery: Implement retry logic with exponential backoff
- Resource Management: Close gRPC connections properly to avoid resource leaks
Current Limitations
- Replay History: Available replay history varies by feed and endpoint. A cursor outside retained history returns
NOT_FOUND - Rate Limits: Be mindful of request frequency to avoid overwhelming the service
Resources
- GitHub: gRPC Code Examples - Complete working examples
- StreamOrderStatuses Documentation - Full order status specification and streaming examples
- Historical Data - Historical
node_order_statuses_by_blockdownloads
Need help? Contact our support team or check the Hyperliquid gRPC documentation.
GetOrderBookSnapshot - Get Order Book Data
Retrieve a generated order book snapshot with individual order visibility from Hyperliquid L1 Gateway via gRPC.
GetRawBookDiffs - Get Book Diff Data
Retrieve order book diffs at a specific position from Hyperliquid L1 Gateway via gRPC. Get incremental book changes for analysis and reconstruction.