Architect Documentation
  • User Guide
  • SDK Documentation
  • Algos Book
  • Introduction
  • Creating an API key
  • Getting started with Python
  • Getting started with Rust
  • Concepts
    • Symbology
    • Orderflow
    • Accounts and portfolio management
    • Systems and connectivity diagram
    • Authentication
  • SDK Reference
    • Symbology and instrument info
    • Marketdata
    • Order entry
    • Order management
    • Portfolio management
Powered by GitBook
On this page
  • Get open orders
  • Get historical orders
  • Get fills
  • Fill IDs
  • Orderflow channel
  • Stream orderflow
  1. SDK Reference

Order management

PreviousOrder entryNextPortfolio management

Last updated 4 days ago

Get open orders

Get all open orders matching the selectors.

orders = await client.get_open_orders()

for order in orders:
    print(order.id)

Get historical orders

Get all historical orders (orders whose statuses are not PENDING nor OPEN) matching the selectors. If order_ids is not specified, then from_inclusive and to_exclusive are required.

orders = await client.get_historical_orders()

for order in orders:
    print(order.id)

Get fills

Get all fills matching the selectors.

res = await client.get_fills()

for fill in res.fills:
    print(fill.id)

Fill IDs

Architect attempts to uniquely identify fills, executions, or trades across all venues. They are typically UUIDv5s which are derived from exchange fill IDs and other characteristics of the fill necessary to make the identifications unambiguous.

Orderflow channel

The most efficient way to trade using the Architect OEMS is to use the bidirectional orderflow channel. This is similar to a websocket or FIX session where one connection is opened and maintained for an entire trading session. The client will send place order and cancel order requests and receive order status updates and fills in realtime.

The specific mechanics of using the orderflow channel depend on the specific language SDK's implementation.

Example coming soon

Stream orderflow

Subscribe to orderflow events, order status updates, fills from the Architect OEMS. The events streamed are the same as those received by the orderflow bidirectional channel.

async for event in client.stream_orderflow():
    print(event)
Order management
Get open orders
Get historical orders
Get fills
Fill IDs
Orderflow channel
Stream orderflow