v51

latestOpenAPI 3.0.0raw.githubusercontent.com2026-08-0175184292.5 KB
Experimental endpoints

Get account order detail (V2)

Returns the detail of a single order using the brokerage order ID provided as a path parameter.

The V2 order response format includes all legs of the order in the legs list field. If the order is single legged, legs will be a list of one leg.

This endpoint is always realtime and does not rely on cached data.

This endpoint only returns orders placed through SnapTrade. In other words, orders placed outside of the SnapTrade network are not returned by this endpoint.

get/accounts/{accountId}/orders/details/v2/{brokerageOrderId}

Path parameters

accountIdstring uuid required

Unique identifier for the connected brokerage account. This is the UUID used to reference the account in SnapTrade.

Example:917c8734-8470-4a3e-a18f-57c3f2ee6631
brokerageOrderIdstring required

Order ID returned by brokerage. This is the unique identifier for the order in the brokerage system.

Example:66a033fa-da74-4fcf-b527-feefdec9257e

Query parameters

userIdstring required

SnapTrade User ID. This is chosen by the API partner and can be any string that is a) unique to the user, and b) immutable for the user. It is recommended to NOT use email addresses for this property because they are usually not immutable.

Example:snaptrade-user-123
userSecretstring required

SnapTrade User Secret. This is a randomly generated string and should be stored securely. If compromised, please rotate it via the rotate user secret endpoint.

Example:adf2aa34-8219-40f7-a6b3-60156985cc61

Response

OK

brokerage_order_idstring

Order ID returned by brokerage. This is the unique identifier for the order in the brokerage system.

brokerage_group_order_idstring nullable

The brokerage-assigned identifier that links all orders within a complex order (OCO, OTO, OTOCO) together. Null for non-complex orders or when the brokerage does not return a group identifier.

order_role'TRIGGER' | 'CONDITIONAL' | 'PEER' nullable

The role of this order within a complex order group (OCO, OTO, OTOCO). Null for non-complex orders.

status'NONE' | 'PENDING' | 'ACCEPTED' | 'FAILED' | 'REJECTED' | 'CANCELED' | 'PARTIAL_CANCELED' | 'CANCEL_PENDING' | 'EXECUTED' | 'PARTIAL' | 'REPLACE_PENDING' | 'REPLACED' | 'STOPPED' | 'SUSPENDED' | 'EXPIRED' | 'QUEUED' | 'TRIGGERED' | 'ACTIVATED' | 'PENDING_RISK_REVIEW' | 'CONTINGENT_ORDER'

Indicates the status of an order. SnapTrade does a best effort to map brokerage statuses to statuses in this enum. Possible values include:

  • NONE
  • PENDING
  • ACCEPTED
  • FAILED
  • REJECTED
  • CANCELED
  • PARTIAL_CANCELED
  • CANCEL_PENDING
  • EXECUTED
  • PARTIAL
  • REPLACE_PENDING
  • REPLACED
  • EXPIRED
  • QUEUED
  • TRIGGERED
  • ACTIVATED
order_typestring nullable

The type of order placed.

  • MARKET
  • LIMIT
  • STOP
  • STOP_LIMIT
time_in_forcestring

The Time in Force type for the order. This field indicates how long the order will remain active before it is executed or expires. We try our best to map brokerage time in force values to the following. When mapping fails, we will return the brokerage's time in force value.

  • DAY - Day. The order is valid only for the trading day on which it is placed.
  • GTC - Good Til Canceled. The order is valid until it is executed or canceled.
  • FOK - Fill Or Kill. The order must be executed in its entirety immediately or be canceled completely.
  • IOC - Immediate Or Cancel. The order must be executed immediately. Any portion of the order that cannot be filled immediately will be canceled.
  • GTD - Good Til Date. The order is valid until the specified date.
  • MOO - Market On Open. The order is to be executed at the day's opening price.
  • EHP - Extended Hours P.M. The order is to be placed during extended hour trading, after markets close.
time_placedstring date-time

The time the order was placed. This is the time the order was submitted to the brokerage.

time_executedstring date-time nullable

The time the order was executed in the brokerage system. This value is not always available from the brokerage.

quote_currencystring

Quote currency code for the order.

execution_pricestring decimal nullable

The price at which the order was executed.

limit_pricestring decimal nullable

The limit price is maximum price one is willing to pay for a buy order or the minimum price one is willing to accept for a sell order. Should only apply to Limit and StopLimit orders.

stop_pricestring decimal nullable

The stop price is the price at which a stop order is triggered. Should only apply to Stop and StopLimit orders.

Example response

{
  "brokerage_order_id": "66a033fa-da74-4fcf-b527-feefdec9257e",
  "brokerage_group_order_id": "1234567890",
  "order_role": "TRIGGER",
  "order_type": "MARKET",
  "time_in_force": "DAY",
  "time_placed": "2024-07-30T22:51:49.746270Z",
  "time_executed": "2024-08-05T00:05:57.409000Z",
  "quote_currency": "USD",
  "execution_price": "12.34",
  "limit_price": "12.34",
  "stop_price": "12.50",
  "trailing_stop": {
    "amount": "0.60"
  },
  "legs": [
    {
      "instrument": {
        "symbol": "AAPL",
        "description": "Apple Inc.",
        "asset_type": "EQUITY",
        "exchange_mic_code": "XNAS",
        "figi_code": "BBG000B9XRY4"
      },
      "execution_price": "12.34",
      "total_quantity": "10",
      "canceled_quantity": "1",
      "filled_quantity": "9"
    }
  ]
}