openapi: 3.2.0 info: description: 'Connect brokerage accounts to your app for live positions and trading. ## Rate limiting Two limits apply to requests signed with your `clientId`. The stricter one wins, and exceeding either returns `429 Too Many Requests`. - **Customer-level** — 250 requests/minute by default, scoped to your `clientId` and applied across all endpoints. Reported in `X-RateLimit-Limit`, `X-RateLimit-Remaining` and `X-RateLimit-Reset`. - **Account-level** — 10 requests/minute per account, scoped to (`clientId`, `accountId`). All covered operations for one account draw on the same bucket — reading balances and reading positions share it — and enforcement does not depend on the HTTP method, so updating an account consumes the same bucket as reading it. Only enforced for Personal users, and only for integrations it has been rolled out to — it is not yet in force for every Personal integration. It also does not apply on every operation that documents a 429 below. Where it applies it is reported in `X-RateLimit-Account-Limit`, `X-RateLimit-Account-Remaining` and `X-RateLimit-Account-Reset`. Do not read the absence of those headers as proof the limit is off — some configurations omit the rate limit headers while still enforcing the limit, so header absence tells you nothing about your allowance. On a 429, `X-RateLimit-Remaining: 0` means you hit the customer-level limit and `X-RateLimit-Account-Remaining: 0` means the account-level one. Wait for the corresponding `*-Reset` value (seconds) before retrying, or fall back to exponential backoff with jitter. Not every 429 is explained by those headers. A separate per-authenticated-user limit, reported in no `X-RateLimit-*` header, covers OAuth-authenticated requests and signed requests in configurations where the customer-level limit is not in effect — on the operations that use the default throttles. A few operations override those and are governed by the customer-level limit alone. The two do not stack: a signed request governed by the customer-level limit above is not additionally subject to the per-user one. If a 429 arrives with no header at zero — or with no `X-RateLimit-*` headers at all — honour `Retry-After` and back off. Treat the remaining counts as a hint, not a guarantee that the next request will succeed. Because the customer-level limit applies everywhere, any signed request can return 429. **OAuth-authenticated requests are an exception.** They are not subject to the customer-level limit and do not receive `X-RateLimit-Limit`, `X-RateLimit-Remaining` or `X-RateLimit-Reset` — do not wait on those headers or design around a customer-level allowance on this path. The account-level limit still applies to them on the account-data endpoints above, reported in the `X-RateLimit-Account-*` headers. On operations using the default throttles the per-user limit above applies to them as well, so an OAuth request can be rejected while the account headers still show capacity; on the few operations that override those throttles, OAuth callers have no per-user ceiling at all. Drive retries from `Retry-After` and exponential backoff with jitter rather than from the headers. See https://docs.snaptrade.com/docs/ratelimiting.' version: 1.0.0 title: SnapTrade Trading API termsOfService: N/A contact: email: api@snaptrade.com x-konfig-ignore: potential-incorrect-type: true x-readme: explorer-enabled: false servers: - description: SnapTrade Production API url: https://api.snaptrade.com security: - PartnerSignature: [] PartnerClientId: [] PartnerTimestamp: [] tags: - name: Trading description: Manage orders on user accounts. paths: /accounts/{accountId}/quotes: get: tags: - Trading summary: Get equity symbol quotes description: 'Returns a maximum of 10 quotes from the brokerage for the specified symbols and account. The quotes returned can be delayed depending on the brokerage the account belongs to. It is highly recommended that you use your own market data provider for real-time quotes instead of relying on this endpoint. **This endpoint is not a substitute for a market data provider. Frequent polling of this endpoint may result in the disabling of your keys** This endpoint does not work for options quotes.' operationId: Trading_getUserAccountQuotes parameters: - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' - in: query name: symbols required: true description: List of Universal Symbol IDs or tickers to get quotes for. When providing multiple values, use a comma as separator. Maximum of 10 values allowed schema: type: string - in: query name: use_ticker description: Should be set to `True` if `symbols` are comprised of tickers. Defaults to `False` if not provided. schema: type: boolean - in: path name: accountId required: true schema: $ref: '#/components/schemas/AccountID' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/SymbolsQuotes' '429': $ref: '#/components/responses/TooManyRequests' '500': description: Unexpected error content: application/json: schema: $ref: '#/components/schemas/500UnexpectedExceptionResponse' /trade/place: post: tags: - Trading summary: Place equity order description: 'Places a brokerage order in the specified account. The order could be rejected by the brokerage if it is invalid or if the account does not have sufficient funds. This endpoint does not compute the impact to the account balance from the order and any potential commissions before submitting the order to the brokerage. If that is desired, you can use the check order impact endpoint. It''s recommended to trigger a manual refresh of the account after placing an order to ensure the account is up to date. You can use the manual refresh endpoint for this.' operationId: Trading_placeForceOrder parameters: - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' requestBody: $ref: '#/components/requestBodies/ManualTradeFormRequestBodyWithOptions' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/AccountOrderRecord' '400': description: Trade could not be placed content: application/json: schema: $ref: '#/components/schemas/400FailedRequestResponse' '403': description: User does not have permissions to place trades content: application/json: schema: $ref: '#/components/schemas/403FailedRequestResponse' '500': description: Unexpected Error /accounts/{accountId}/trading/complex: post: tags: - Trading summary: Place complex order description: 'Places a complex conditional order (OCO, OTO, or OTOCO). Only supported on certain brokerages. Please refer to the brokerage trading support page for details on which brokerages support complex orders and which types they support. - **OCO** (One Cancels the Other): Two peer orders; when one fills the other is cancelled. - **OTO** (One Triggers the Other): A trigger order that, when filled, activates a conditional order. - **OTOCO** (One Triggers a One Cancels the Other): A trigger order that, when filled, activates an OCO pair of two peer orders. Option OCO peers must trade the same OCC option symbol with the same closing action and positive whole-contract quantity. On tastytrade, option OCO supports closing an existing long or short option position with one `Limit` order and one `Stop` or `StopLimit` order. Both `PEER` orders must use `SELL_TO_CLOSE` or both must use `BUY_TO_CLOSE`, with `Day` or `GTC` time in force. Opening option OCOs are not supported. On enabled Webull US v3 accounts, option OCO supports closing an existing long option position with one `Limit` take-profit order and one `Stop` stop-loss order. Both `PEER` orders must use `SELL_TO_CLOSE`, `Day`, the same OCC option symbol, and the same positive whole-contract quantity. Webull receives these as `STOP_PROFIT` and `STOP_LOSS` orders sharing a combo ID, without a MASTER order. Opening option OCOs, `BUY_TO_CLOSE`, `StopLimit`, and other option order pairs are not supported on Webull. Equity complex-order behavior is unchanged.' operationId: Trading_placeComplexOrder parameters: - in: path name: accountId required: true description: The ID of the account to execute the trade on. schema: $ref: '#/components/schemas/AccountID' - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' requestBody: $ref: '#/components/requestBodies/ManualTradeFormComplexRequestBody' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/ComplexOrderResponse' '400': description: Trade could not be placed content: application/json: schema: $ref: '#/components/schemas/400FailedRequestResponse' '403': description: User does not have permissions to place trades content: application/json: schema: $ref: '#/components/schemas/403FailedRequestResponse' '500': description: Unexpected Error /accounts/{accountId}/trading/replace: post: tags: - Trading summary: Replace order description: 'Replaces an existing pending order with a new one. The way this works is brokerage dependent, but usually involves cancelling the existing order and placing a new one. The order''s brokerage_order_id may or may not change, be sure to use the one returned in the response going forward. Only supported on some brokerages' operationId: Trading_replaceOrder parameters: - in: path name: accountId required: true description: The ID of the account to execute the trade on. schema: $ref: '#/components/schemas/Id' - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' requestBody: $ref: '#/components/requestBodies/ManualTradeReplaceFormRequestBody' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/AccountOrderRecord' '400': description: Trade could not be placed content: application/json: schema: $ref: '#/components/schemas/400FailedRequestResponse' '403': description: User does not have permissions to place trades content: application/json: schema: $ref: '#/components/schemas/403FailedRequestResponse' '500': description: Unexpected Error /trade/impact: post: tags: - Trading summary: Check equity order impact description: Simulates an order and its impact on the account. This endpoint does not place the order with the brokerage. If successful, it returns a `Trade` object and the ID of the object can be used to place the order with the brokerage using the place checked order endpoint. Please note that the `Trade` object returned expires after 5 minutes. Any order placed using an expired `Trade` will be rejected. operationId: Trading_getOrderImpact parameters: - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' requestBody: $ref: '#/components/requestBodies/ManualTradeFormRequestBody' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/ManualTradeAndImpact' '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/400FailedRequestResponse' '403': description: Forbidden content: application/json: schema: $ref: '#/components/schemas/403FailedRequestResponse' '500': description: Unexpected Error /trade/{tradeId}: post: tags: - Trading summary: Place checked equity order description: 'Places the previously checked order with the brokerage. The `tradeId` is obtained from the check order impact endpoint. If you prefer to place the order without checking for impact first, you can use the place order endpoint. It''s recommended to trigger a manual refresh of the account after placing an order to ensure the account is up to date. You can use the manual refresh endpoint for this.' operationId: Trading_placeOrder parameters: - in: path name: tradeId required: true description: Obtained from calling the [check order impact endpoint](/reference/Trading/Trading_getOrderImpact) schema: $ref: '#/components/schemas/TradeID' - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' requestBody: $ref: '#/components/requestBodies/ValidatedTradeRequestBody' responses: '200': description: Status of order placed content: application/json: schema: $ref: '#/components/schemas/AccountOrderRecord' '400': description: Failed to submit order to broker content: application/json: schema: $ref: '#/components/schemas/400FailedRequestResponse' '500': description: Unexpected Error /accounts/{accountId}/trading/crypto: post: tags: - Trading summary: Place crypto order description: 'Places an order in the specified account. This endpoint does not compute the impact to the account balance from the order before submitting the order.' operationId: Trading_placeCryptoOrder parameters: - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' - in: path required: true name: accountId schema: $ref: '#/components/schemas/AccountID' requestBody: $ref: '#/components/requestBodies/CryptoOrderRequestBody' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/OrderUpdatedResponse' '400': description: Invalid request content: application/json: schema: $ref: '#/components/schemas/400FailedRequestResponse' '500': description: Unexpected Error /accounts/{accountId}/trading/cancel: post: tags: - Trading summary: Cancel order description: Cancels an order in the specified account. Accepts order IDs for all asset types. operationId: Trading_cancelOrder parameters: - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' - in: path required: true name: accountId schema: $ref: '#/components/schemas/AccountID' requestBody: $ref: '#/components/requestBodies/CancelOrderRequestBody' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/CancelOrderResponse' '400': description: Invalid request content: application/json: schema: $ref: '#/components/schemas/400FailedRequestResponse' '500': description: Unexpected Error /accounts/{accountId}/trading/crypto/preview: post: tags: - Trading summary: Preview crypto order description: Previews an order using the specified account. operationId: Trading_previewCryptoOrder parameters: - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' - in: path required: true name: accountId schema: $ref: '#/components/schemas/AccountID' requestBody: $ref: '#/components/requestBodies/CryptoOrderRequestBody' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/CryptoOrderPreview' '400': description: Invalid request content: application/json: schema: $ref: '#/components/schemas/400FailedRequestResponse' '500': description: Unexpected Error /accounts/{accountId}/trading/instruments/cryptocurrencyPairs: get: tags: - Trading summary: Get crypto pairs description: Searches cryptocurrency pairs instruments accessible to the specified account. Both `base` and `quote` are optional. Omit both for a full list of cryptocurrency pairs. operationId: Trading_searchCryptocurrencyPairInstruments parameters: - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' - in: path required: true name: accountId schema: $ref: '#/components/schemas/AccountID' - in: query required: false name: base schema: $ref: '#/components/schemas/CryptocurrencyBaseSymbol' - in: query required: false name: quote schema: $ref: '#/components/schemas/CryptocurrencyQuoteSymbol' responses: '200': description: OK content: application/json: schema: type: object required: - items description: The instruments properties: items: type: array items: $ref: '#/components/schemas/CryptocurrencyPair' '400': description: Invalid request content: application/json: schema: $ref: '#/components/schemas/400FailedRequestResponse' '500': description: Unexpected Error /accounts/{accountId}/trading/instruments/cryptocurrencyPairs/{instrumentSymbol}/quote: get: tags: - Trading summary: Get crypto pair quote description: Gets a quote for the specified account. operationId: Trading_getCryptocurrencyPairQuote parameters: - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' - in: path required: true name: accountId schema: $ref: '#/components/schemas/AccountID' - in: path required: true name: instrumentSymbol schema: $ref: '#/components/schemas/CryptocurrencyPairSymbol' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/CryptocurrencyPairQuote' '400': description: Invalid request content: application/json: schema: $ref: '#/components/schemas/400FailedRequestResponse' '500': description: Unexpected Error /accounts/{accountId}/trading/options/impact: post: tags: - Trading summary: Get option order impact description: 'Beta operation. Simulates an option order with up to 4 legs and returns the estimated cost and transaction fees without placing it. Only supported for certain enabled brokerages. Please refer to the brokerage trading support page for more information on which brokerages support this endpoint.' operationId: Trading_getOptionImpact parameters: - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' - in: path required: true name: accountId schema: $ref: '#/components/schemas/AccountID' requestBody: $ref: '#/components/requestBodies/MlegOrderRequestBody' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/OptionImpact' '400': description: Invalid request, or option impact is not supported for this brokerage content: application/json: schema: $ref: '#/components/schemas/400FailedRequestResponse' '403': description: Forbidden content: application/json: schema: $ref: '#/components/schemas/403FailedRequestResponse' '501': description: Deprecated. Previously returned when option impact was not supported for this brokerage; such requests now return 400. x-beta: true /accounts/{accountId}/trading/options: post: tags: - Trading summary: Place option order description: Places a multi-leg option order. Only supported on certain option trading brokerages. https://support.snaptrade.com/brokerages has information on brokerage trading support operationId: Trading_placeMlegOrder parameters: - in: query required: true name: userId schema: $ref: '#/components/schemas/UserID' - in: query required: true name: userSecret schema: $ref: '#/components/schemas/UserSecret' - in: path required: true name: accountId schema: $ref: '#/components/schemas/AccountID' requestBody: $ref: '#/components/requestBodies/MlegOrderRequestBody' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/MlegOrderResponse' '400': description: Invalid request content: application/json: schema: $ref: '#/components/schemas/400FailedRequestResponse' '500': description: Unexpected Error components: schemas: MlegInstrumentType: description: The instrument's type type: string enum: - OPTION - EQUITY Units: description: Number of shares for the order. This can be a decimal for fractional orders. Must be `null` if `notional_value` is provided. type: number example: 10.5 MlegLeg: type: object required: - instrument - action - units properties: instrument: $ref: '#/components/schemas/MlegTradingInstrument' action: $ref: '#/components/schemas/MlegActionStrict' units: description: The quantity to trade. For options this represents the number of contracts. For equity this represents the number of shares. type: integer example: 1 403FailedRequestResponse: description: Example for failed request response type: object properties: default_detail: example: User does not have permission to access this resource default_code: example: 1066 ManualTrade: description: Contains the details of a submitted order. type: object properties: id: $ref: '#/components/schemas/TradeID' account: $ref: '#/components/schemas/AccountID' order_type: $ref: '#/components/schemas/OrderTypeStrict' time_in_force: $ref: '#/components/schemas/TimeInForceStrict' symbol: $ref: '#/components/schemas/ManualTradeSymbol' action: $ref: '#/components/schemas/ActionStrict' units: allOf: - $ref: '#/components/schemas/Units' price: $ref: '#/components/schemas/Price' UniversalSymbolID: description: Unique identifier for the symbol within SnapTrade. This is the ID used to reference the symbol in SnapTrade API calls. type: string format: uuid example: 2bcd7cc3-e922-4976-bce1-9858296801c3 400FailedRequestResponse: description: Example for failed request response type: object properties: default_detail: example: Unable to verify data sent default_code: example: 1076 AccountOrderRecordStatus: description: "Indicates the status of an order. SnapTrade does a best effort to map brokerage statuses to statuses in this enum.\nPossible values include:\n - NONE\n - PENDING\n - ACCEPTED\n - FAILED\n - REJECTED\n - CANCELED\n - PARTIAL_CANCELED\n - CANCEL_PENDING\n - EXECUTED\n - PARTIAL\n - REPLACE_PENDING\n - REPLACED\n - EXPIRED\n - QUEUED\n - TRIGGERED\n - ACTIVATED\n" type: string enum: - 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 CancelOrderResponse: type: object required: - brokerage_order_id properties: brokerage_order_id: $ref: '#/components/schemas/BrokerageOrderID' raw_response: type: - object - 'null' description: The raw response from the brokerage. example: order_id: '1234567890' status: CANCELLED AccountSimple: description: A single account at a brokerage. type: object properties: id: $ref: '#/components/schemas/AccountID' name: type: string description: A display name for the account. Either assigned by the user or by the brokerage itself. For certain brokerages, SnapTrade appends the brokerage name to the account name for clarity. example: Robinhood Individual number: type: string example: Q6542138443 description: The account number assigned by the brokerage. For some brokerages, this field may be masked for security reasons. institution_account_id: type: - string - 'null' example: '54953432' description: A stable and unique account identifier provided by the institution. Will be set to null if not provided. When present, can be used to check if a user has connected the same brokerage account across multiple connections. sync_status: $ref: '#/components/schemas/AccountSyncStatus' SyncStatusDate: description: Date in YYYY-MM-DD format or null type: - string - 'null' example: '2022-01-24' format: date ClientOrderID: description: 'Optional caller-supplied identifier passed through to the brokerage for idempotent order placement. Must be a canonical 36-character UUID. Idempotency enforcement is brokerage-specific - SnapTrade forwards this value to the broker but does not enforce uniqueness server-side. Refer to per-brokerage documentation for behavior on duplicate submission. ' type: - string - 'null' format: uuid example: 550e8400-e29b-41d4-a716-446655440000 ManualTradeForm: description: Inputs for placing an order with the brokerage. type: object required: - account_id - action - order_type - time_in_force - universal_symbol_id properties: account_id: $ref: '#/components/schemas/AccountID' action: $ref: '#/components/schemas/ActionStrict' universal_symbol_id: $ref: '#/components/schemas/UniversalSymbolID' order_type: $ref: '#/components/schemas/OrderTypeStrict' time_in_force: $ref: '#/components/schemas/TimeInForceStrict' price: description: The limit price for `Limit` and `StopLimit` orders. type: - number - 'null' example: 31.33 stop: description: The price at which a stop order is triggered for `Stop` and `StopLimit` orders. type: - number - 'null' example: 31.33 units: allOf: - $ref: '#/components/schemas/Units' notional_value: allOf: - $ref: '#/components/schemas/NotionalValue' BrokerageSymbolID: deprecated: true description: A unique ID for the security within SnapTrade, scoped to the brokerage account that the security belongs to. This is a legacy field and should not be used. Do not rely on this being a stable ID as it can change. type: string format: uuid example: 2bcd7cc3-e922-4976-bce1-9858296801c3 Id: type: string format: uuid example: 2bcd7cc3-e922-4976-bce1-9858296801c3 MlegTradingInstrument: type: object required: - symbol - instrument_type properties: symbol: description: The security's trading ticker symbol. This currently supports stock symbols and Options symbols in the 21 character OCC format. For example `AAPL 251114C00240000` represents a call option on AAPL expiring on 2025-11-14 with a strike price of $240. For more information on the OCC format, see [here](https://en.wikipedia.org/wiki/Option_symbol#OCC_format) type: string example: PBI 250718C00006000 instrument_type: $ref: '#/components/schemas/MlegInstrumentType' ValidatedTradeBody: type: object properties: wait_to_confirm: example: true type: - boolean - 'null' description: Optional, defaults to true. Determines if a wait is performed to check on order status. If false, latency will be reduced but orders returned will be more likely to be of status `PENDING` as we will not wait to check on the status before responding to the request. MlegPriceEffectStrict: type: string description: The desired price_effect for `LIMIT` and `STOP_LOSS_LIMIT` orders. Values are `CREDIT`, `DEBIT`, `EVEN` enum: - CREDIT - DEBIT - EVEN example: DEBIT FigiInstrument: description: Financial Instrument Global Identifier (FIGI) information for the security. See [OpenFIGI](https://www.openfigi.com/) for more information. type: object properties: figi_code: description: This identifier is unique per security per trading venue. See section 1.4.1 of the [FIGI Standard](https://www.openfigi.com/assets/local/figi-allocation-rules.pdf) for more information. type: - string - 'null' example: BBG000B9Y5X2 figi_share_class: description: This enables users to link multiple FIGIs for the same security in order to obtain an aggregated view across all countries and all exchanges. For example, `AAPL` has a different FIGI for each exchange/trading venue it is traded on. The `figi_share_class` is the same for all of these FIGIs. See section 1.4.3 of the [FIGI Standard](https://www.openfigi.com/assets/local/figi-allocation-rules.pdf) for more information. type: - string - 'null' example: BBG001S5N8V8 ManualTradeSymbol: description: Information about the security for the order. type: object properties: universal_symbol_id: $ref: '#/components/schemas/UniversalSymbolID' currency: $ref: '#/components/schemas/Currency' local_id: deprecated: true description: This field is deprecated and should not be used. type: string example: '1048101' description: deprecated: true description: This field is deprecated and should not be used. type: - string - 'null' example: Metaverse Global ETF symbol: deprecated: true description: This field is deprecated and should not be used. type: string example: MVGP.U.TO brokerage_symbol_id: $ref: '#/components/schemas/BrokerageSymbolID' Price: description: Trade Price if limit or stop limit order type: - number - 'null' example: 31.33 OptionsSymbol: description: Uniquely describes an option security + exchange combination across all brokerages. type: object required: - id - ticker - option_type - strike_price - expiration_date - underlying_symbol properties: id: $ref: '#/components/schemas/OptionSymbolID' ticker: description: The [OCC symbol](https://en.wikipedia.org/wiki/Option_symbol) for the option. type: string example: AAPL 261218C00240000 option_type: description: The type of option. Either "CALL" or "PUT". type: string enum: - CALL - PUT example: CALL strike_price: description: The option strike price. type: number example: 240 expiration_date: description: The option expiration date. type: string format: date example: '2026-12-18' is_mini_option: description: Whether the option is a mini option. Mini options have 10 underlying shares per contract instead of the standard 100. type: boolean example: false underlying_symbol: $ref: '#/components/schemas/UnderlyingSymbol' AccountSyncStatus: description: Contains status update for the account sync process between SnapTrade and the brokerage. properties: transactions: $ref: '#/components/schemas/TransactionsStatus' holdings: $ref: '#/components/schemas/HoldingsStatus' NotionalValue: description: Total notional amount for the order. Must be `null` if `units` is provided. Can only work with `Market` for `order_type` and `Day` for `time_in_force`. This is only available for certain brokerages. Please check the [integrations doc](https://support.snaptrade.com/brokerages-table?v=e7bbcbf9f272441593f93decde660687) for more information. oneOf: - type: string - type: number example: 100 CryptocurrencyPairQuote: type: object required: - bid - ask properties: bid: description: The highest price a buyer is willing to pay. type: string format: decimal example: '123.45' ask: description: The lowest price a seller is willing to accept. type: string format: decimal example: '123.45' mid: description: The market mid price. type: string format: decimal example: '123.45' timestamp: description: The timestamp of the quote. type: string format: date-time example: '2024-01-24T15:00:00.000Z' CryptocurrencyPairSymbol: description: Cryptocurrency pair instrument symbol type: string example: BTC-USD 500UnexpectedExceptionResponse: description: Example for a response that failed for unexpected reasons type: object properties: detail: example: Encountered an unexpected exception. status_code: example: 500 code: example: 1000 CryptocurrencyBaseSymbol: description: 'The base currency of a pair (e.g., "BTC" in BTC/USD). Either fiat or cryptocurrency symbol, for fiat use ISO-4217 codes. ' type: string example: BTC CryptocurrencyQuoteSymbol: description: 'The quote currency of a pair (e.g., "USD" in BTC/USD). Either fiat or cryptocurrency symbol, for fiat use ISO-4217 codes. ' type: string example: USD CryptoOrderForm: type: object required: - instrument - side - type - time_in_force - amount properties: instrument: $ref: '#/components/schemas/CryptoTradingInstrument' side: $ref: '#/components/schemas/ActionStrict' type: type: string enum: - MARKET - LIMIT - STOP_LOSS_MARKET - STOP_LOSS_LIMIT - TAKE_PROFIT_MARKET - TAKE_PROFIT_LIMIT description: The type of order to place. time_in_force: description: "The Time in Force type for the order. This field indicates how long the order will remain active before it is executed or expires.\n - `GTC` - Good Til Canceled. The order is valid until it is executed or canceled.\n - `FOK` - Fill Or Kill. The order must be executed in its entirety immediately or be canceled completely.\n - `IOC` - Immediate Or Cancel. The order must be executed immediately. Any portion of the order that cannot be filled immediately will be canceled.\n - `GTD` - Good Til Date. The order is valid until the specified date.\n" type: string enum: - GTC - FOK - IOC - GTD amount: description: The amount of the base currency to buy or sell. type: string format: decimal example: '123.45' limit_price: description: The limit price. Required if the order type is `LIMIT`, `STOP_LOSS_LIMIT` or `TAKE_PROFIT_LIMIT`. type: string format: decimal example: '123.45' stop_price: description: The stop price. Required if the order type is `STOP_LOSS_MARKET`, `STOP_LOSS_LIMIT`, `TAKE_PROFIT_MARKET` or `TAKE_PROFIT_LIMIT`. type: string format: decimal example: '123.45' post_only: type: boolean example: false description: 'Valid and required only for order type `LIMIT`. If true orders that would be filled immediately are rejected to avoid incurring TAKER fees. ' expiration_date: type: string format: date-time example: '2024-01-01T00:00:00Z' description: The expiration date of the order. Required if the time_in_force is `GTD`. AccountID: description: Unique identifier for the connected brokerage account. This is the UUID used to reference the account in SnapTrade. type: string format: uuid example: 917c8734-8470-4a3e-a18f-57c3f2ee6631 UniversalSymbol: description: Uniquely describes a single security + exchange combination across all brokerages. type: object properties: id: $ref: '#/components/schemas/UniversalSymbolID' symbol: description: The security's trading ticker symbol. For example "AAPL" for Apple Inc. We largely follow the [Yahoo Finance ticker format](https://help.yahoo.com/kb/SLN2310.html)(click on "Yahoo Finance Market Coverage and Data Delays"). For example, for securities traded on the Toronto Stock Exchange, the symbol has a '.TO' suffix. For securities traded on NASDAQ or NYSE, the symbol does not have a suffix. Share classes and preferred series use SnapTrade's canonical dotted form, for example `HBND.U.TO`, `FTN.PR.A.TO`, and `ECF.PRA`. type: string example: VAB.TO raw_symbol: description: The raw symbol is `symbol` with the exchange suffix removed. For example, if `symbol` is "VAB.TO", then `raw_symbol` is "VAB". type: string example: VAB description: description: A human-readable description of the security. This is usually the company name or ETF name. type: - string - 'null' example: VANGUARD CDN AGGREGATE BOND INDEX ETF currency: description: The currency in which the security is traded. allOf: - $ref: '#/components/schemas/Currency' exchange: description: The exchange on which the security is listed and traded. allOf: - $ref: '#/components/schemas/Exchange' type: $ref: '#/components/schemas/SecurityType' figi_code: description: This identifier is unique per security per trading venue. See section 1.4.1 of the [FIGI Standard](https://www.openfigi.com/assets/local/figi-allocation-rules.pdf) for more information. This value should be the same as the `figi_code` in the `figi_instrument` child property. type: - string - 'null' example: BBG000B9XRY4 figi_instrument: allOf: - $ref: '#/components/schemas/FigiInstrument' currencies: deprecated: true description: This field is deprecated and should not be used. Please reach out to SnapTrade support if you have a valid use case for this. type: array items: $ref: '#/components/schemas/Currency' required: - id - symbol - raw_symbol - currency - type - currencies 429TooManyRequestsResponse: description: Example for a rate-limited request response type: object properties: detail: example: Connection refreshed too recently. Please try again later. status_code: example: 429 code: example: throttled UnderlyingSymbol: description: Symbol object for the underlying security of an option. type: object properties: id: $ref: '#/components/schemas/UniversalSymbolID' symbol: description: The security's trading ticker symbol. For example "AAPL" for Apple Inc. We largely follow the [Yahoo Finance ticker format](https://help.yahoo.com/kb/SLN2310.html)(click on "Yahoo Finance Market Coverage and Data Delays"). For example, for securities traded on the Toronto Stock Exchange, the symbol has a '.TO' suffix. For securities traded on NASDAQ or NYSE, the symbol does not have a suffix. type: string example: SPY raw_symbol: description: The raw symbol is `symbol` with the exchange suffix removed. For example, if `symbol` is "VAB.TO", then `raw_symbol` is "VAB". type: string example: VAB description: description: A human-readable description of the security. This is usually the company name or ETF name. type: - string - 'null' example: SPDR S&P 500 ETF Trust currency: description: The currency in which the security is traded. allOf: - $ref: '#/components/schemas/Currency' exchange: description: The exchange on which the security is listed and traded. allOf: - $ref: '#/components/schemas/USExchange' type: description: The type of security. For example, "Common Stock" or "ETF". allOf: - $ref: '#/components/schemas/SecurityType' figi_code: description: This identifier is unique per security per trading venue. See section 1.4.1 of the [FIGI Standard](https://www.openfigi.com/assets/local/figi-allocation-rules.pdf) for more information. This value should be the same as the `figi_code` in the `figi_instrument` child property. type: - string - 'null' example: BBG000B9XRY4 figi_instrument: allOf: - $ref: '#/components/schemas/FigiInstrument' currencies: deprecated: true description: This field is deprecated and should not be used. Please reach out to SnapTrade support if you have a valid use case for this. type: array items: $ref: '#/components/schemas/Currency' TimeInForceStrict: description: "The Time in Force type for the order. This field indicates how long the order will remain active before it is executed or expires. Here are the supported values:\n - `Day` - Day. The order is valid only for the trading day on which it is placed.\n - `GTC` - Good Til Canceled. The order is valid until it is executed or canceled.\n - `FOK` - Fill Or Kill. The order must be executed in its entirety immediately or be canceled completely.\n - `IOC` - Immediate Or Cancel. The order must be executed immediately. Any portion of the order that cannot be filled immediately will be canceled.\n" type: string enum: - FOK - Day - GTC - IOC example: Day Currency: description: Describes a currency object. type: object properties: id: $ref: '#/components/schemas/CurrencyID' code: type: string description: The ISO-4217 currency code for the currency. example: USD name: type: string description: A human-friendly name of the currency. example: US Dollar TradingInstrument: type: object required: - symbol - type properties: symbol: description: The instrument's trading ticker symbol. This currently supports stock symbols and Options symbols in the 21 character OCC format. For example `AAPL 251114C00240000` represents a call option on AAPL expiring on 2025-11-14 with a strike price of $240. For more information on the OCC format, see [here](https://en.wikipedia.org/wiki/Option_symbol#OCC_format) type: string example: AAPL type: description: The instrument's type type: string enum: - EQUITY - OPTION - CRYPTOCURRENCY - CRYPTOCURRENCY_PAIR UserSecret: description: 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](/reference/Authentication/Authentication_resetSnapTradeUserSecret). type: string example: adf2aa34-8219-40f7-a6b3-60156985cc61 CryptocurrencySymbol: description: Symbol to identify a cryptocurrency or fiat currency on a crypto exchange. Fiat currencies symbols are ISO-4217 codes. type: string example: BTC OrderUpdatedResponse: type: object required: - brokerage_order_id properties: brokerage_order_id: $ref: '#/components/schemas/BrokerageOrderID' order: allOf: - $ref: '#/components/schemas/AccountOrderRecord' MlegOrderTypeStrict: example: MARKET type: string enum: - MARKET - LIMIT - STOP_LOSS_MARKET - STOP_LOSS_LIMIT description: The type of order to place. TransactionsStatus: description: 'Status of account transaction sync. SnapTrade syncs transactions from the brokerage under the following conditions: 1. Initial connection - SnapTrade syncs all transactions from the brokerage account as far back as the brokerage allows. Check [our integrations doc](https://support.snaptrade.com/brokerages-table?v=6fab8012ade6441fa0c6d9af9c55ce3a) for details on how far back we sync for each brokerage. 2. Daily sync - Once a day SnapTrade syncs new transactions from the brokerage. 3. Manual sync - You can trigger an incremental sync of transactions with the [transactions sync](/reference/Experimental%20endpoints/Connections_syncBrokerageAuthorizationTransactions) endpoint. ' properties: initial_sync_completed: description: Indicates if the initial sync of transactions has been completed. For accounts with a large number of transactions, the initial sync may take a while to complete. type: boolean example: true last_successful_sync: description: All transactions up to this date have been successfully synced. Please note that this is not the date of the last transaction, nor the last time SnapTrade attempted to sync transactions. allOf: - $ref: '#/components/schemas/SyncStatusDate' first_transaction_date: description: The date of the first transaction in the account known to SnapTrade. It's possible that the account has transactions before this date, but they are not known to SnapTrade. allOf: - $ref: '#/components/schemas/SyncStatusDate' HoldingsSyncStatusDate: description: Date in ISO 8601 format or null (YYYY-MM-DD HH:MM:SS.mmmmmmTZ) type: - string - 'null' example: '2024-06-28 18:42:46.561408+00:00' format: date-time UserID: description: 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. type: string example: snaptrade-user-123 Exchange: description: Describes a single stock or crypto exchange. type: object properties: id: $ref: '#/components/schemas/ExchangeID' code: description: A short name for the exchange. For standardized exchange code, please use the `mic_code` field. type: string example: TSX mic_code: description: The [Market Identifier Code](https://en.wikipedia.org/wiki/Market_Identifier_Code) (MIC) for the exchange. type: - string - 'null' example: XTSE name: description: The full name of the exchange. type: string example: Toronto Stock Exchange timezone: description: The timezone for the trading hours (`start_time` and `close_time`) of the exchange. type: string example: America/New_York start_time: description: The time when the exchange opens for trading. type: string example: 09:30:00 close_time: description: The time when the exchange closes for trading. type: string example: '16:00:00' suffix: description: The suffix to be appended to the symbol when trading on this exchange. For example, the suffix for the Toronto Stock Exchange is `.TO`. See `UniversalSymbol->symbol` and `UniversalSymbol->raw_symbol` for more detail. type: - string - 'null' example: .TO OptionSymbolID: description: Unique identifier for the option symbol within SnapTrade. This is the ID used to reference the symbol in SnapTrade API calls. type: string format: uuid example: 2bcd7cc3-e922-4976-bce1-9858296801c3 ManualTradeFormWithOptions: description: Inputs for placing an order with the brokerage. type: object required: - account_id - action - order_type - time_in_force properties: account_id: $ref: '#/components/schemas/AccountID' action: $ref: '#/components/schemas/ActionStrictWithOptions' universal_symbol_id: description: The universal symbol ID of the security to trade. Must be 'null' if `symbol` is provided, otherwise must be provided. allOf: - $ref: '#/components/schemas/UniversalSymbolID' symbol: description: The security's trading ticker symbol. If 'symbol' is provided, then 'universal_symbol_id' must be 'null'. type: - string - 'null' example: AAPL order_type: $ref: '#/components/schemas/OrderTypeStrict' time_in_force: $ref: '#/components/schemas/ManualTradePlaceTimeInForceStrict' trading_session: $ref: '#/components/schemas/TradingSession' expiry_date: description: Timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format indicating when the order expires. Required when `time_in_force` is `GTD`. Include a timezone offset or `Z` for UTC; if no timezone is provided, UTC is assumed. GTD orders are only available on certain brokerages. Visit https://support.snaptrade.com/brokerages for brokerage support. type: - string - 'null' format: date-time example: '2026-08-21T23:27:55.027Z' price: description: The limit price for `Limit` and `StopLimit` orders. type: - number - 'null' example: 31.33 stop: description: The price at which a stop order is triggered for `Stop` and `StopLimit` orders. type: - number - 'null' example: 31.33 units: description: For Equity orders, this represents the number of shares for the order. This can be a decimal for fractional orders. Must be `null` if `notional_value` is provided. If placing an Option order, this field represents the number of contracts to buy or sell. (e.g., 1 contract = 100 shares). allOf: - $ref: '#/components/schemas/Units' notional_value: allOf: - $ref: '#/components/schemas/NotionalValue' client_order_id: allOf: - $ref: '#/components/schemas/ClientOrderID' TradingSession: description: "The trading session for the order. This field indicates which market session the order will be placed in. This is only available for certain brokerages. Defaults to REGULAR. Here are the supported values:\n - `REGULAR` - Regular trading hours.\n - `EXTENDED` - Extended trading hours.\n" type: string enum: - REGULAR - EXTENDED example: REGULAR default: REGULAR HoldingsStatus: description: 'Status of account holdings sync. SnapTrade syncs holdings from the brokerage under the following conditions: 1. Initial connection - SnapTrade syncs all holdings (positions, balances, recent orders, and transactions) immediately after the connection is established. 2. Daily sync - Once a day SnapTrade refreshes all holdings from the brokerage. 3. Manual sync - You can trigger a refresh of holdings with the [manual refresh](/reference/Connections/Connections_refreshBrokerageAuthorization) endpoint. ' properties: initial_sync_completed: description: Indicates if the initial sync of holdings has been completed. For accounts with a large number of positions/orders/transactions, the initial sync may take a while to complete. type: boolean example: true last_successful_sync: description: The last time holdings were successfully synced by SnapTrade. allOf: - $ref: '#/components/schemas/HoldingsSyncStatusDate' holdings_unavailable: description: 'Indicates that the brokerage does not expose this account''s holdings to SnapTrade, so the empty positions and balances reported for it do not mean the account is empty. This is set for accounts served by a separate brokerage system that we cannot read, such as Vanguard employer-sponsored retirement plans. When this is `true`, prefer the account''s total value over the sum of its positions and cash, and note that `initial_sync_completed` and `last_successful_sync` may still reflect an earlier sync. ' type: boolean example: true ActionStrictWithOptions: description: The action describes the intent or side of a trade. This is either `BUY` or `SELL` for Equity symbols or `BUY_TO_OPEN`, `BUY_TO_CLOSE`, `SELL_TO_OPEN` or `SELL_TO_CLOSE` for Options. type: string enum: - BUY - SELL - BUY_TO_OPEN - BUY_TO_CLOSE - SELL_TO_OPEN - SELL_TO_CLOSE Action: type: string description: "The action describes the intent or side of a trade. This is usually `BUY` or `SELL` but can include other potential values like the following depending on the specific brokerage.\n - BUY\n - SELL\n - BUY_COVER\n - SELL_SHORT\n - BUY_OPEN\n - BUY_CLOSE\n - SELL_OPEN\n - SELL_CLOSE\n" ManualTradeFormComplex: description: Request body for placing a complex conditional order (OCO, OTO, or OTOCO). type: object required: - type - orders properties: type: description: 'The complex order type. - `OCO`: One Cancels the Other — two peer orders. - `OTO`: One Triggers the Other — a trigger order and a conditional order. - `OTOCO`: One Triggers a One Cancels the Other — a trigger order and two peer orders. ' type: string enum: - OCO - OTO - OTOCO example: OTO orders: description: 'The orders that make up the complex order. Required counts and roles per type: - `OCO`: exactly 2 orders, both `PEER` - `OTO`: exactly 2 orders, one `TRIGGER` and one `CONDITIONAL` - `OTOCO`: exactly 3 orders, one `TRIGGER` and two `PEER` ' type: array items: $ref: '#/components/schemas/ComplexOrderLeg' client_order_id: allOf: - $ref: '#/components/schemas/ClientOrderID' CryptoTradingInstrument: type: object required: - symbol - type properties: symbol: description: The instrument's trading ticker symbol type: string example: BTC type: description: The instrument's type type: string enum: - CRYPTOCURRENCY - CRYPTOCURRENCY_PAIR TradeID: description: Unique identifier for the submitted order through SnapTrade. type: string format: uuid example: 139e307a-82f7-4402-b39e-4da7baa87758 SecurityType: type: object description: The type of security. For example, "Common Stock" or "ETF". properties: id: $ref: '#/components/schemas/SecurityTypeID' code: description: "A short code representing the security type. For example, \"cs\" for Common Stock. Here are some common values:\n - `ad` - ADR\n - `bnd` - Bond\n - `cs` - Common Stock\n - `cef` - Closed End Fund\n - `crypto` - Cryptocurrency\n - `et` - ETF\n - `oef` - Open Ended Fund\n - `pm` - Precious Metals\n - `ps` - Preferred Stock\n - `rt` - Right\n - `struct` - Structured Product\n - `ut` - Unit\n - `wi` - When Issued\n - `wt` - Warrant\n" type: string example: cs description: description: A human-readable description of the security type. For example, "Common Stock" or "ETF". type: string example: Common Stock is_supported: deprecated: true description: This field is deprecated and should not be used. Please reach out to SnapTrade support if you have a valid use case for this. type: boolean example: true OptionImpact: description: Estimated cash change and fees for an option order before it is placed. type: object properties: estimated_cash_change: description: Estimated cash change for the order, before fees. type: string example: '1.97' cash_change_direction: description: Direction of the cash change. CREDIT means cash is received, DEBIT means cash is paid out, EVEN means no cash changes hands. UNKNOWN if the direction cannot be determined from the request. type: - string - 'null' enum: - CREDIT - DEBIT - EVEN - UNKNOWN estimated_fee_total: description: Estimated total transaction fees and commissions for the order. type: string example: '0.50' CurrencyID: type: string format: uuid description: Unique identifier for the currency. This is the UUID used to reference the currency in SnapTrade. example: 87b24961-b51e-4db8-9226-f198f6518a89 CryptoOrderPreview: description: Preview of an order. type: object properties: estimated_fee: type: object required: - currency - amount description: The estimated order fee. properties: currency: $ref: '#/components/schemas/CryptocurrencySymbol' amount: type: string format: decimal example: '123.45' MlegActionStrict: description: The action describes the intent and side of a trade. For equities, this is either `BUY` or `SELL`. For options, this is one of `BUY_TO_OPEN`, `BUY_TO_CLOSE`, `SELL_TO_OPEN`, `SELL_TO_CLOSE`. type: string enum: - BUY - SELL - BUY_TO_OPEN - BUY_TO_CLOSE - SELL_TO_OPEN - SELL_TO_CLOSE example: BUY_TO_OPEN SecurityTypeID: description: Unique identifier for the security type within SnapTrade. This is the ID used to reference the security type in SnapTrade API calls. type: string format: uuid example: 2bcd7cc3-e922-4976-bce1-9858296801c3 ComplexOrderResponse: description: 'Response returned after successfully placing a complex order. AccountOrderRecord rows for the legs are not created synchronously — they''re hydrated by the next brokerage sync, and can be queried later using the returned `brokerage_group_order_id`. ' type: object properties: type: description: The complex order type that was placed. type: string enum: - OCO - OTO - OTOCO example: OTO brokerage_group_order_id: description: 'The brokerage-assigned identifier that links all legs of this complex order together. Each leg will eventually appear as a separate AccountOrderRecord sharing this value. May be null if the brokerage does not return a group identifier. ' type: - string - 'null' example: '1234567890' AccountOrderRecord: description: Describes a single recent order in an account. Each record here represents a single order leg. For multi-leg orders, there will be multiple records. type: object properties: brokerage_order_id: $ref: '#/components/schemas/BrokerageOrderID' brokerage_group_order_id: description: '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. ' type: - string - 'null' example: '1234567890' order_role: description: 'The role of this order within a complex order group (OCO, OTO, OTOCO). Null for non-complex orders. ' type: - string - 'null' enum: - TRIGGER - CONDITIONAL - PEER example: TRIGGER status: $ref: '#/components/schemas/AccountOrderRecordStatus' universal_symbol: description: Contains information about the security that the order is for. This field is only present for stock/ETF/crypto/mutual fund orders. For option orders, this field will be null and the `option_symbol` field will be populated. allOf: - $ref: '#/components/schemas/UniversalSymbol' option_symbol: description: Contains information about the option contract that the order is for. This field is only present for option orders. For stock/ETF/crypto/mutual fund orders, this field will be null and the `universal_symbol` field will be populated. allOf: - $ref: '#/components/schemas/OptionsSymbol' quote_universal_symbol: description: Quote cryptocurrency. This field is only present for cryptocurrency pair orders with a cryptocurrency as quote. allOf: - $ref: '#/components/schemas/UniversalSymbol' quote_currency: description: Quote currency. This field is only present for cryptocurrency pair orders with a fiat currency as quote. allOf: - $ref: '#/components/schemas/Currency' action: $ref: '#/components/schemas/Action' total_quantity: description: The total number of shares or contracts of the order. This should be the sum of the filled, canceled, and open quantities. Can be a decimal number for fractional shares. type: - string - 'null' example: '100' open_quantity: description: The number of shares or contracts that are still open (waiting for execution). Can be a decimal number for fractional shares. type: - string - 'null' example: '10' canceled_quantity: description: The number of shares or contracts that have been canceled. Can be a decimal number for fractional shares. type: - string - 'null' example: '10' filled_quantity: description: The number of shares or contracts that have been filled. Can be a decimal number for fractional shares. type: - string - 'null' example: '80' execution_price: description: The price at which the order was executed. For option orders, this represents the price per share. type: - string - 'null' format: decimal example: '12.34' limit_price: description: 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. For option orders, this represents the price per share. type: - string - 'null' format: decimal example: '12.34' stop_price: description: The stop price is the price at which a stop order is triggered. Should only apply to `Stop` and `StopLimit` orders. For option orders, this represents the price per share. type: - string - 'null' format: decimal example: '12.50' trailing_stop: description: For trailing stop orders, contains the trail configuration. Null for all other order types. allOf: - $ref: '#/components/schemas/TrailingStop' order_type: description: The type of order placed. The most common values are `Market`, `Limit`, `Stop`, and `StopLimit`. We try our best to map brokerage order types to these values. When mapping fails, we will return the brokerage's order type value. type: - string - 'null' example: Market time_in_force: description: "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.\n - `Day` - Day. The order is valid only for the trading day on which it is placed.\n - `GTC` - Good Til Canceled. The order is valid until it is executed or canceled.\n - `FOK` - Fill Or Kill. The order must be executed in its entirety immediately or be canceled completely.\n - `IOC` - Immediate Or Cancel. The order must be executed immediately. Any portion of the order that cannot be filled immediately will be canceled.\n - `GTD` - Good Til Date. The order is valid until the specified date.\n - `MOO` - Market On Open. The order is to be executed at the day's opening price.\n - `EHP` - Extended Hours P.M. The order is to be placed during extended hour trading, after markets close.\n" type: string time_placed: description: The time the order was placed. This is the time the order was submitted to the brokerage. type: string format: date-time example: '2024-07-30T22:51:49.746Z' time_updated: description: The time the order was last updated in the brokerage system. This value is not always available from the brokerage. type: - string - 'null' format: date-time example: '2024-08-05T00:05:57.409Z' time_executed: description: The time the order was executed in the brokerage system. This value is not always available from the brokerage. type: - string - 'null' format: date-time example: '2024-08-05T00:05:57.409Z' expiry_date: description: The time the order expires. This value is not always available from the brokerage. type: - string - 'null' format: date-time example: '2024-08-05T00:05:57.409Z' symbol: $ref: '#/components/schemas/BrokerageSymbolID' child_brokerage_order_ids: allOf: - $ref: '#/components/schemas/ChildBrokerageOrderIDs' ManualTradeReplaceForm: description: Inputs for replacing an order with the brokerage. type: object required: - brokerage_order_id - action - order_type - time_in_force properties: brokerage_order_id: $ref: '#/components/schemas/BrokerageOrderID' action: $ref: '#/components/schemas/ActionStrictWithOptions' order_type: $ref: '#/components/schemas/OrderTypeStrict' time_in_force: $ref: '#/components/schemas/TimeInForceStrict' price: description: The limit price for `Limit` and `StopLimit` orders. type: - number - 'null' example: 31.33 symbol: description: The security's trading ticker symbol. Use the OCC symbol to replace an option order. type: string example: AAPL stop: description: The price at which a stop order is triggered for `Stop` and `StopLimit` orders. type: - number - 'null' example: 31.33 units: allOf: - $ref: '#/components/schemas/Units' ManualTradeAndImpact: type: object properties: trade: $ref: '#/components/schemas/ManualTrade' trade_impacts: description: List of impacts of the trade on the account. The list always contains one value at the moment. type: array items: $ref: '#/components/schemas/ManualTradeImpact' combined_remaining_balance: $ref: '#/components/schemas/ManualTradeBalance' MlegTradeForm: description: Inputs for placing a multi-leg order with the brokerage. type: object required: - order_type - time_in_force - legs properties: order_type: $ref: '#/components/schemas/MlegOrderTypeStrict' time_in_force: $ref: '#/components/schemas/TimeInForceStrict' limit_price: description: The limit price. Required if the order type is `LIMIT`, `STOP_LOSS_LIMIT`, unless `price_effect` is `EVEN` - a net-even order is implicitly priced at 0, so the field may be omitted and must be `0` if sent. type: - string - 'null' format: decimal example: '' stop_price: description: The stop price. Required if the order type is `STOP_LOSS_MARKET`, `STOP_LOSS_LIMIT`. type: - string - 'null' format: decimal example: '' price_effect: example: DEBIT allOf: - $ref: '#/components/schemas/MlegPriceEffectStrict' legs: type: array items: $ref: '#/components/schemas/MlegLeg' USExchange: description: US Stock Exchange type: object properties: id: $ref: '#/components/schemas/Id' code: type: string example: ARCX mic_code: type: - string - 'null' example: ARCA name: type: string example: NYSE ARCA timezone: type: string example: America/New_York start_time: type: string example: 09:30:00 close_time: type: string example: '16:00:00' suffix: type: - string - 'null' example: None allows_cryptocurrency_symbols: type: boolean example: false BrokerageOrderID: description: Order ID returned by brokerage. This is the unique identifier for the order in the brokerage system. type: string example: 66a033fa-da74-4fcf-b527-feefdec9257e MlegOrderResponse: type: object required: - brokerage_order_id - orders properties: brokerage_order_id: $ref: '#/components/schemas/BrokerageOrderID' orders: type: array items: $ref: '#/components/schemas/AccountOrderRecord' ManualTradeImpact: type: object properties: account: $ref: '#/components/schemas/AccountID' currency: $ref: '#/components/schemas/CurrencyID' remaining_cash: description: Estimated amount of cash remaining in the account after the trade. type: - number - 'null' example: 1.11 estimated_commission: description: Estimated commission for the trade. type: - number - 'null' example: 3.26 forex_fees: description: Estimated foreign transaction fees for the trade. type: - number - 'null' example: 5.26 ChildBrokerageOrderIDs: type: object properties: take_profit_order_id: type: string description: The brokerage order ID for the take profit leg of the bracket order example: '12345678' stop_loss_order_id: type: string description: The brokerage order ID for the stop loss leg of the bracket order example: '12345678' TrailingStop: description: Trail configuration for trailing stop orders. type: object required: - amount - type properties: amount: description: The trail amount. Interpreted as dollars if `type` is `DOLLAR`, or a percentage if `type` is `PERCENT`. type: string example: '0.60' type: description: Whether the trail `amount` is a dollar amount (`DOLLAR`) or a percentage (`PERCENT`). For example, if `amount` is "0.60" and `type` is `DOLLAR`, the stop price will trail the market price by $0.60. If `amount` is "5" and `type` is `PERCENT`, the stop price will trail the market price by 5%. type: string enum: - DOLLAR - PERCENT SymbolsQuotes: description: List of symbols with the latest quotes from the brokerage. type: array items: properties: symbol: $ref: '#/components/schemas/UniversalSymbol' last_trade_price: description: The most recent trade price from the brokerage. type: number example: 8.74 bid_price: description: The most recent bid price from the brokerage. type: number example: 8.43 ask_price: description: The most recent price from the brokerage. type: number example: 8.43 bid_size: description: The most recent bid size from the brokerage. type: number example: 260 ask_size: description: The most recent ask size from the brokerage. type: number example: 344 ComplexOrderLeg: description: A single order within a complex group. For option OCOs, each peer trades one option contract type. type: object required: - order_role - action - instrument - order_type - units - time_in_force properties: order_role: description: The role of this leg within the complex order. type: string enum: - TRIGGER - CONDITIONAL - PEER example: TRIGGER action: $ref: '#/components/schemas/ActionStrictWithOptions' instrument: $ref: '#/components/schemas/TradingInstrument' order_type: $ref: '#/components/schemas/OrderTypeStrict' units: description: A positive whole number of shares or option contracts. Option OCO peers must use the same quantity. type: integer minimum: 1 example: 1 time_in_force: $ref: '#/components/schemas/TimeInForceStrict' price: description: The limit price. Required when `order_type` is `Limit` or `StopLimit`. type: - number - 'null' example: 31.33 stop: description: The stop trigger price. Required when `order_type` is `Stop` or `StopLimit`. type: - number - 'null' example: 29.5 OrderTypeStrict: description: 'The type of order to place. - For `Limit` and `StopLimit` orders, the `price` field is required. - For `Stop` and `StopLimit` orders, the `stop` field is required. ' example: Market type: string enum: - Limit - Market - StopLimit - Stop CryptocurrencyIncrement: description: 'The precision or smallest price incremental step available for this cryptocurrency pair ' type: string example: '0.001' CryptocurrencyPair: description: A cryptocurrency pair instrument. type: object required: - base - quote properties: symbol: $ref: '#/components/schemas/CryptocurrencyPairSymbol' base: $ref: '#/components/schemas/CryptocurrencyBaseSymbol' quote: $ref: '#/components/schemas/CryptocurrencyQuoteSymbol' increment: allOf: - $ref: '#/components/schemas/CryptocurrencyIncrement' ActionStrict: description: The action describes the intent or side of a trade. This is either `BUY` or `SELL`. type: string enum: - BUY - SELL ManualTradePlaceTimeInForceStrict: description: "The Time in Force type for the order. This field indicates how long the order will remain active before it is executed or expires. Here are the supported values:\n - `Day` - Day. The order is valid only for the trading day on which it is placed.\n - `GTC` - Good Til Canceled. The order is valid until it is executed or canceled.\n - `FOK` - Fill Or Kill. The order must be executed in its entirety immediately or be canceled completely.\n - `IOC` - Immediate Or Cancel. The order must be executed immediately. Any portion of the order that cannot be filled immediately will be canceled.\n - `GTD` - Good Til Date. The order is valid until `expiry_date`, which is required. Not available for market orders. GTD orders are only available on certain brokerages. Visit https://support.snaptrade.com/brokerages for brokerage support.\n" type: string enum: - FOK - Day - GTC - IOC - GTD example: Day ManualTradeBalance: description: Estimated remaining balance of the account after the trade is executed. type: object properties: account: $ref: '#/components/schemas/AccountSimple' currency: $ref: '#/components/schemas/Currency' cash: description: Estimated amount of cash remaining in the account after the trade. At the moment this is the same as `remaining_cash` under `trade_impacts`. type: - number - 'null' example: 1.11 ExchangeID: description: Unique ID for the exchange in SnapTrade. type: string format: uuid example: 2bcd7cc3-e922-4976-bce1-9858296801c3 headers: X-RateLimit-Account-Limit: description: Per-account request allowance for the current window. Only sent on account-data endpoints where the account-level limit applies. schema: type: integer example: 10 X-RateLimit-Limit: description: Customer-level request allowance for the current window. schema: type: integer example: 250 X-RateLimit-Remaining: description: Customer-level requests left in the current window. 0 on a 429 means this is the limit you hit. schema: type: integer example: 249 X-RateLimit-Account-Reset: description: Seconds until the per-account window resets. schema: type: integer example: 60 X-RateLimit-Account-Remaining: description: Per-account requests left in the current window. 0 on a 429 means this is the limit you hit. schema: type: integer example: 9 X-RateLimit-Reset: description: Seconds until the customer-level window resets. schema: type: integer example: 60 responses: TooManyRequests: description: 'Rate limit exceeded. Check `X-RateLimit-Remaining` (customer-level) and `X-RateLimit-Account-Remaining` (account-level) to see which limit you hit, then wait for the matching `*-Reset` value before retrying. Not every header listed below appears on every operation. The `X-RateLimit-Account-*` headers are sent only where the per-account limit is enforced, and OAuth-authenticated requests never receive the customer-level `X-RateLimit-Limit`, `X-RateLimit-Remaining` or `X-RateLimit-Reset`. A separate per-authenticated-user limit, reported in no `X-RateLimit-*` header, covers OAuth-authenticated requests and signed requests not governed by the customer-level limit; it does not stack on top of that limit. So a 429 can arrive with every reported counter above zero — or with no `X-RateLimit-*` headers at all. Honour `Retry-After` in that case. ' headers: Retry-After: description: Seconds to wait before retrying. schema: type: integer example: 7 X-RateLimit-Limit: $ref: '#/components/headers/X-RateLimit-Limit' X-RateLimit-Remaining: $ref: '#/components/headers/X-RateLimit-Remaining' X-RateLimit-Reset: $ref: '#/components/headers/X-RateLimit-Reset' X-RateLimit-Account-Limit: $ref: '#/components/headers/X-RateLimit-Account-Limit' X-RateLimit-Account-Remaining: $ref: '#/components/headers/X-RateLimit-Account-Remaining' X-RateLimit-Account-Reset: $ref: '#/components/headers/X-RateLimit-Account-Reset' content: application/json: schema: $ref: '#/components/schemas/429TooManyRequestsResponse' requestBodies: ValidatedTradeRequestBody: required: false content: application/json: schema: $ref: '#/components/schemas/ValidatedTradeBody' MlegOrderRequestBody: required: true content: application/json: schema: $ref: '#/components/schemas/MlegTradeForm' ManualTradeFormRequestBody: required: true content: application/json: schema: $ref: '#/components/schemas/ManualTradeForm' CryptoOrderRequestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CryptoOrderForm' CancelOrderRequestBody: required: true content: application/json: schema: type: object required: - brokerage_order_id properties: brokerage_order_id: $ref: '#/components/schemas/BrokerageOrderID' ManualTradeFormRequestBodyWithOptions: required: true content: application/json: schema: $ref: '#/components/schemas/ManualTradeFormWithOptions' ManualTradeReplaceFormRequestBody: required: true content: application/json: schema: $ref: '#/components/schemas/ManualTradeReplaceForm' ManualTradeFormComplexRequestBody: required: true content: application/json: schema: $ref: '#/components/schemas/ManualTradeFormComplex' securitySchemes: PartnerSignature: type: apiKey in: header name: Signature PartnerClientId: type: apiKey in: query name: clientId PartnerTimestamp: type: apiKey in: query name: timestamp