UNPKG

@gitchrisqueen/tdameritrade-api-js-client

Version:
1,557 lines 148 kB
swagger: '2.0' info: description: This is replication of the TD Ameritrade API. title: TD Ameritrade API - OAuth2 version: 0.1.4 host: api.tdameritrade.com basePath: /v1 schemes: - https paths: /accounts: get: produces: - application/json parameters: - description: >- Balances displayed by default, additional fields can be added here by adding positions or orders. Example: fields=positions,orders in: query name: fields required: false type: string responses: '200': description: OK schema: $ref: '#/definitions/Account' '207': description: >- Indicates there was a problem getting account data for one or more linked accounts, but the accounts who's data returned successfully is in the response. Do not aggregate balances and positions for this case. schema: $ref: '#/definitions/Account' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid AuthToken in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this page. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Accounts description: 'Account balances, positions, and orders for all linked accounts.' operationId: accountsGET summary: Get Accounts x-swagger-router-controller: Accounts /accounts/watchlists: get: produces: - application/json parameters: [] responses: '200': description: OK schema: $ref: '#/definitions/WatchListResponse' '401': description: >- An error message indicating the caller must pass a valid Authorization in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Watchlist description: All watchlists for all of the user's linked accounts. operationId: accountsWatchlistsGET summary: Get Watchlists for Multiple Accounts x-swagger-router-controller: Watchlist '/accounts/{accountId}': get: produces: - application/json parameters: - in: path name: accountId required: true type: integer - description: >- Balances displayed by default, additional fields can be added here by adding positions or orders. Example: fields=positions,orders in: query name: fields required: false type: string responses: '200': description: OK schema: $ref: '#/definitions/Account' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid AuthToken in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this page. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Accounts description: 'Account balances, positions, and orders for a specific account.' operationId: accountsAccountIdGET summary: Get Account x-swagger-router-controller: Accounts '/accounts/{accountId}/orders': get: produces: - application/json parameters: - in: path name: accountId required: true type: integer - in: query name: maxResults required: false type: integer - format: date-time in: query name: fromEnteredTime required: false type: string - format: date-time in: query name: toEnteredTime required: false type: string - enum: - AWAITING_PARENT_ORDER - AWAITING_CONDITION - AWAITING_MANUAL_REVIEW - ACCEPTED - AWAITING_UR_OUT - PENDING_ACTIVATION - QUEUED - WORKING - REJECTED - PENDING_CANCEL - CANCELED - PENDING_REPLACE - REPLACED - FILLED - EXPIRED in: query name: status required: false type: string responses: '200': description: OK schema: $ref: '#/definitions/OrderGet' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid AuthToken in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this page. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Orders description: Orders for a specific account. operationId: accountsAccountIdOrdersGET summary: Get Orders by Path x-swagger-router-controller: Orders '/accounts/{accountId}/orders/{orderId}': delete: produces: - application/json parameters: - in: path name: accountId required: true type: integer - in: path name: orderId required: true type: integer responses: '200': description: OK schema: $ref: '#/definitions/ErrorObject' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid AuthToken in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this page. schema: $ref: '#/definitions/ErrorObject' '404': description: An error message if the order was not found. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Orders description: Cancel a specific order for a spcific account operationId: accountsAccountIdOrdersOrderIdDELETE summary: Cancel Order x-swagger-router-controller: Orders get: produces: - application/json parameters: - in: path name: accountId required: true type: integer - in: path name: orderId required: true type: integer responses: '200': description: OK schema: $ref: '#/definitions/OrderGet' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid AuthToken in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this page. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Orders description: Get a specific order for a specific account. operationId: accountsAccountIdOrdersOrderIdGET summary: Get Order x-swagger-router-controller: Orders put: consumes: - application/json produces: - application/json parameters: - in: path name: accountId required: true type: integer - in: path name: orderId required: true type: integer - in: body name: body schema: $ref: '#/definitions/OrderGet' responses: '200': description: OK '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid AuthToken in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this page. schema: $ref: '#/definitions/ErrorObject' '404': description: An error message if the order was not found. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Orders description: >- Replace an existing order for an account. The existing order will be replaced by the new order. Once replaced, the old order will be canceled and a new order will be created. See our Place Order Samples Guide - https://developer.tdameritrade.com/content/place-order-samples. operationId: accountsAccountIdOrdersOrderIdPUT summary: Replace Order x-swagger-router-controller: Orders '/accounts/{accountId}/preferences': get: produces: - application/json parameters: - in: path name: accountId required: true type: string responses: '200': description: OK schema: $ref: '#/definitions/Preferences' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid Authorization in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' '503': description: An error message indicating there is a temporary problem responding. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - User Info & Preferences description: Preferences for a specific account. operationId: accountsAccountIdPreferencesGET summary: Get Preferences x-swagger-router-controller: UserInfoPreferences put: consumes: - application/json produces: - application/json parameters: - in: path name: accountId required: true type: string - in: body name: body schema: $ref: '#/definitions/Preferences' responses: '200': description: OK '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid AuthToken in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this resource. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' '503': description: An error message indicating there is a temporary problem responding. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - User Info & Preferences description: >- Update preferences for a specific account. Please note that the directOptionsRouting and directEquityRouting values cannot be modified via this operation. operationId: accountsAccountIdPreferencesPUT summary: Update Preferences x-swagger-router-controller: UserInfoPreferences '/accounts/{accountId}/savedorders': get: produces: - application/json parameters: - in: path name: accountId required: true type: integer responses: '200': description: OK schema: $ref: '#/definitions/OrderGet' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid AuthToken in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this page. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Saved Orders description: Saved orders for a specific account. operationId: accountsAccountIdSavedordersGET summary: Get Saved Orders by Path x-swagger-router-controller: SavedOrders post: consumes: - application/Json produces: - application/json parameters: - in: path name: accountId required: true type: integer - in: body name: body schema: $ref: '#/definitions/OrderGet' responses: '200': description: OK schema: $ref: '#/definitions/OrderGet' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid AuthToken in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this page. schema: $ref: '#/definitions/EASObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Saved Orders description: >- Save an order for a specific account. See our Place Order Samples Guide - https://developer.tdameritrade.com/content/place-order-samples. operationId: accountsAccountIdSavedordersPOST summary: Create Saved Orders x-swagger-router-controller: SavedOrders '/accounts/{accountId}/savedorders/{savedOrderId}': delete: produces: - application/json parameters: - in: path name: accountId required: true type: integer - in: path name: savedOrderId required: true type: integer responses: '200': description: OK schema: $ref: '#/definitions/EASObject' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid AuthToken in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this page. schema: $ref: '#/definitions/ErrorObject' '404': description: An error message if the order was not found. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Saved Orders description: Delete a specific saved order for a specific account. operationId: accountsAccountIdSavedordersSavedOrderIdDELETE summary: Delete Saved Orders x-swagger-router-controller: SavedOrders get: produces: - application/json parameters: - in: path name: accountId required: true type: integer - in: path name: savedOrderId required: true type: integer responses: '200': description: OK schema: $ref: '#/definitions/OrderGet' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid AuthToken in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this page. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Saved Orders description: 'Specific saved order by its ID, for a specific account.' operationId: accountsAccountIdSavedordersSavedOrderIdGET summary: Get Saved Orders x-swagger-router-controller: SavedOrders put: consumes: - application/json produces: - application/json parameters: - in: path name: accountId required: true type: integer - in: path name: savedOrderId required: true type: integer - in: body name: body schema: $ref: '#/definitions/OrderGet' responses: '200': description: OK '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid AuthToken in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this page. schema: $ref: '#/definitions/ErrorObject' '404': description: An error message if the order was not found. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Saved Orders description: >- Replace an existing saved order for an account. The existing saved order will be replaced by the new order. see our Place Order Samples Guide - Click here. operationId: accountsAccountIdSavedordersSavedOrderIdPUT summary: Replace Saved Orders x-swagger-router-controller: SavedOrders '/accounts/{accountId}/transactions': get: produces: - application/json parameters: - in: path name: accountId required: true type: string - description: Only transactions with the specified type will be returned. enum: - ALL - TRADE - BUY_ONLY - SELL_ONLY - CASH_IN_OR_CASH_OUT - CHECKING - DIVEDEND - INTEREST - OTHER - ADVISOR_FEES in: query name: type required: false type: string - description: Only transactions with the specified symbol will be returned. in: query name: symbol required: false type: string - description: >- Only transactions after the Start Date will be returned. Note: The maximum date range is one year. Valid ISO-8601 formats are : yyyy-MM-dd. in: query name: startDate required: false type: string - description: >- Only transactions after the end Date will be returned. Note: The maximum date range is one year. Valid ISO-8601 formats are : yyyy-MM-dd. in: query name: endDate required: false type: string responses: '200': description: OK schema: $ref: '#/definitions/Transaction' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid Authorization in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller doesn't have access to the account in the request. schema: $ref: '#/definitions/ErrorObject' '404': description: >- An error message indicating the specified transaction could not be found. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' '503': description: An error message indicating there is a temporary problem responding. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Transactions description: Transaction for a specific account. operationId: accountsAccountIdTransactionsGET summary: Get Transactions x-swagger-router-controller: Transactions '/accounts/{accountId}/transactions/{transactionId}': get: produces: - application/json parameters: - in: path name: accountId required: true type: string - in: path name: transactionId required: true type: string responses: '200': description: OK schema: $ref: '#/definitions/Transaction' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid Authorization in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller doesn't have access to the account in the request. schema: $ref: '#/definitions/ErrorObject' '404': description: >- An error message indicating the specified transaction could not be found. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' '503': description: An error message indicating there is a temporary problem responding. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Transactions description: Transaction for a specific account. operationId: accountsAccountIdTransactionsTransactionIdGET summary: Get Transaction x-swagger-router-controller: Transactions '/accounts/{accountId}/watchlists': get: produces: - application/json parameters: - in: path name: accountId required: true type: string responses: '200': description: OK schema: $ref: '#/definitions/WatchListResponse' '401': description: >- An error message indicating the caller must pass a valid Authorization in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Watchlist description: all watchlist for an account. operationId: accountsAccountIdWatchlistsGET summary: Get Watchlists for Single Account x-swagger-router-controller: Watchlist post: consumes: - application/json produces: - application/json parameters: - in: path name: accountId required: true type: string - in: body name: body schema: $ref: '#/definitions/WatchListRequest' responses: '200': description: OK '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid Authorization in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Watchlist description: >- Create watchlist for specific account.This method does not verify that the symbol or asset type are valid. operationId: accountsAccountIdWatchlistsPOST summary: Create Watchlist x-swagger-router-controller: Watchlist '/accounts/{accountId}/watchlists/{watchlistId}': get: produces: - application/json parameters: - in: path name: accountId required: true type: string - in: path name: watchlistId required: true type: string responses: '200': description: OK schema: $ref: '#/definitions/WatchListResponse' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid Authorization in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '404': description: >- An error message indicating the account or the watchlist ID does not exist. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Watchlist description: Specific watchlist for a specific account. operationId: accountsAccountIdWatchlistsWatchlistIdGET summary: Get Watchlists x-swagger-router-controller: Watchlist patch: consumes: - application/json produces: - application/json parameters: - in: path name: accountId required: true type: string - in: path name: watchlistId required: true type: string - in: body name: body schema: $ref: '#/definitions/WatchListRequest' responses: '200': description: OK '204': description: Watchlist updated. schema: $ref: '#/definitions/ErrorObject' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid Authorization in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Watchlist description: >- Partially update watchlist for a specific account: change watchlist name, add to the beginning/end of a watchlist, update or delete items in a watchlist. This method does not verify that the symbol or asset type are valid. operationId: accountsAccountIdWatchlistsWatchlistIdPATCH summary: Update Watchlist x-swagger-router-controller: Watchlist put: consumes: - application/json produces: - application/json parameters: - in: path name: accountId required: true type: string - in: path name: watchlistId required: true type: string - in: body name: body schema: $ref: '#/definitions/WatchListRequest' responses: '200': description: OK '204': description: Watchlist updated. schema: $ref: '#/definitions/ErrorObject' '400': description: An error message indicating the validation problem with the request. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid Authorization in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating there was an unexpected server error. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Watchlist description: Replace watchlist for a specific account. operationId: accountsAccountIdWatchlistsWatchlistIdPUT summary: Replace Watchlist x-swagger-router-controller: Watchlist /instruments: get: produces: - application/json parameters: - description: >- Pass your OAuth User ID to make an unauthenticated request for delayed data. in: query name: apikey required: false type: string - description: >- Value to pass to the search. See projection description for more information. in: query name: symbol required: true type: string - description: >- The type of request: symbol-search: Retrieve instrument data of a specific symbol or cusip symbol-regex: Retrieve instrument data for all symbols matching regex. Example: symbol=XYZ.* will return all symbols beginning with XYZ desc-search: Retrieve instrument data for instruments whose description contains the word supplied. Example: symbol=FakeCompany will return all instruments with FakeCompany in the description. desc-regex: Search description with full regex support. Example: symbol=XYZ.[A-C] returns all instruments whose descriptions contain a word beginning with XYZ followed by a character A through C. fundamental: Returns fundamental data for a single instrument specified by exact symbol. in: query name: projection required: true type: string responses: '200': description: OK schema: $ref: '#/definitions/SearchInstrumentResponse' '400': description: >- An error message indicating the caller must pass a non null value in the parameter. schema: $ref: '#/definitions/ErrorObject' '401': description: Unauthorized schema: $ref: '#/definitions/ErrorObject' '403': description: Forbidden schema: $ref: '#/definitions/ErrorObject' '404': description: >- An error message indicating the instrument for the symbol/cusip was not found. schema: $ref: '#/definitions/ErrorObject' '406': description: >- An error message indicating an issue in the symbol regex, or number of symbols searched is over the maximum. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Instruments description: 'Search or retrieve instrument data, including fundamental data' operationId: instrumentsGET summary: Search Instruments x-swagger-router-controller: Instruments '/instruments/{cusip}': get: produces: - application/json parameters: - in: path name: cusip required: true type: string - description: >- Pass your OAuth User ID to make an unauthenticated request for delayed data. in: query name: apikey required: false type: string responses: '200': description: OK schema: $ref: '#/definitions/SearchInstrumentResponse' '400': description: >- An error message indicating the caller must pass a non null value in the parameter. schema: $ref: '#/definitions/ErrorObject' '401': description: Unauthorized schema: $ref: '#/definitions/ErrorObject' '403': description: Forbidden schema: $ref: '#/definitions/ErrorObject' '404': description: >- An error message indicating the instrument for the symbol/cusip was not found. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Instruments description: Get an instrument by CUSIP operationId: instrumentsCusipGET summary: Get Instrument x-swagger-router-controller: Instruments /marketdata/chains: get: produces: - application/json parameters: - description: >- Pass your OAuth User ID to make an unauthenticated request for delayed data. in: query name: apikey required: false type: string - description: Enter one symbol in: query name: symbol required: false type: string - default: ALL description: >- Type of contracts to return in the chain. Can be CALL, PUT, or ALL. Default is ALL. enum: - CALL - PUT - ALL in: query name: contractType required: false type: string - description: >- The number of strikes to return above and below the at-the-money price. in: query name: strikeCount required: false type: integer - default: false description: >- Include quotes for options in the option chain. Can be TRUE or FALSE. Default is FALSE. in: query name: includeQuotes required: false type: boolean - description: >- Passing a value returns a Strategy Chain. Possible values are SINGLE, ANALYTICAL (allows use of the volatility, underlyingPrice, interestRate, and daysToExpiration params to calculate theoretical values), COVERED, VERTICAL, CALENDAR, STRANGLE, STRADDLE, BUTTERFLY, CONDOR, DIAGONAL, COLLAR, or ROLL. Default is SINGLE. enum: - SINGLE - ANALYTICAL - COVERED - VERTICAL - CALENDAR - STRANGLE - STRADDLE - BUTTERFLY - CONDOR - DIAGONAL - COLLAR - ROLL in: query name: strategy required: false type: string - description: Strike interval for spread strategy chains (see strategy param). in: query name: interval required: false type: integer - description: Provide a strike price to return options only at that strike price. in: query name: strike required: false type: number - description: >- Returns options for the given range. Possible values are: ITM: In-the-money NTM: Near-the-money OTM: Out-of-the-money SAK: Strikes Above Market SBK: Strikes Below Market SNK: Strikes Near Market ALL: All Strikes Default is ALL. enum: - ITM - NTM - OTM - SAK - SBK - SNK - ALL in: query name: range required: false type: string - description: >- Only return expirations after this date. For strategies, expiration refers to the nearest term expiration in the strategy. Valid ISO-8601 formats are: yyyy-MM-dd and yyyy-MM-ddTHH:mm:ssz. format: date-time in: query name: fromDate required: false type: string - description: >- Only return expirations before this date. For strategies, expiration refers to the nearest term expiration in the strategy. Valid ISO-8601 formats are: yyyy-MM-dd and yyyy-MM-ddTHH:mm:ssz. format: date-time in: query name: toDate required: false type: string - description: >- Volatility to use in calculations. Applies only to ANALYTICAL strategy chains (see strategy param). in: query name: volatility required: false type: number - description: >- Underlying price to use in calculations. Applies only to ANALYTICAL strategy chains (see strategy param). in: query name: underlyingPrice required: false type: number - description: >- Interest rate to use in calculations. Applies only to ANALYTICAL strategy chains (see strategy param). in: query name: interestRate required: false type: number - description: >- Days to expiration to use in calculations. Applies only to ANALYTICAL strategy chains (see strategy param) in: query name: daysToExpiration required: false type: integer - default: ALL description: >- Return only options expiring in the specified month. Month is given in the three character format. Example: JAN Default is ALL. in: query name: expMonth required: false type: string - default: ALL description: >- Type of contracts to return. Possible values are: S: Standard contract NS: Non-standard contract ALL: All contracts Default is ALL. in: query name: optionType required: false type: string responses: '200': description: OK schema: $ref: '#/definitions/GetOptionChainResponse' '400': description: >- An error message indicating the caller must pass a non null value in the parameter. schema: $ref: '#/definitions/ErrorObject' '401': description: Unauthorized schema: $ref: '#/definitions/ErrorObject' '403': description: Forbidden schema: $ref: '#/definitions/ErrorObject' '404': description: >- An error message indicating the optionchain for the symbol was not found. schema: $ref: '#/definitions/ErrorObject' '500': description: An error message indicating internal error in the service. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Option Chains description: Get option chain for an optionable Symbol operationId: marketdataChainsGET summary: Get Option Chain x-swagger-router-controller: OptionChains /marketdata/hours: get: produces: - application/json parameters: - in: query name: apiKey required: false type: string - enum: - EQUITY - OPTION - FUTURE - BOND - FOREX in: query name: markets required: false type: string - format: date-time in: query name: date required: false type: string responses: '200': description: OK schema: $ref: '#/definitions/Hours' '401': description: Unauthorized schema: $ref: '#/definitions/ErrorObject' '403': description: Forbidden schema: $ref: '#/definitions/ErrorObject' '404': description: Not Found schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Market Hours operationId: marketdataHoursGET summary: Get Hours for Multiple Markets x-swagger-router-controller: MarketHours /marketdata/quotes: get: produces: - application/json parameters: - in: query name: apikey required: false type: string - in: query name: symbol required: false type: string responses: '200': description: OK schema: $ref: '#/definitions/GetQuoteResponse' '400': description: >- An error message indicating the caller must pass a non null value in the parameter. schema: $ref: '#/definitions/ErrorObject' '401': description: >- An error message indicating the caller must pass a valid Authorization in the HTTP authorization request header. schema: $ref: '#/definitions/ErrorObject' '403': description: >- An error message indicating the caller is forbidden from accessing this page. schema: $ref: '#/definitions/ErrorObject' '404': description: >- An error message indicating the instrument for the symbol/cusip was not found. schema: $ref: '#/definitions/ErrorObject' '406': description: >- An error message indicating an issue in the symbol regex, or number of symbols searched is over the maximum. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Quotes description: Get quote for one or more symbols operationId: marketdataQuotesGET summary: Get Quotes x-swagger-router-controller: Quotes '/marketdata/{index}/movers': get: produces: - application/json parameters: - in: path name: index required: true type: string - in: query name: apikey required: false type: string - enum: - up - down in: query name: direction required: false type: string - enum: - value - percent in: query name: change required: false type: string responses: '200': description: OK schema: $ref: '#/definitions/Mover' '400': description: >- An error message indicating the caller must pass a correct value in the parameter. schema: $ref: '#/definitions/ErrorObject' '401': description: Unauthorized schema: $ref: '#/definitions/ErrorObject' '403': description: Forbidden schema: $ref: '#/definitions/ErrorObject' '404': description: An error message indicating movers for the instrument was not found. schema: $ref: '#/definitions/ErrorObject' security: - bearerAuth: [] tags: - Movers operationId: marketdataIndexMoversGET summary: Get price history for a symbol x-swagger-router-controller: Movers '/marketdata/{market}/hours': get: produces: - application/json parameters: - in: query name: apiKey required: false type: string - in: path name: market required: true type: string - format: date-time in: