### Authorize Application Request URL Example Source: https://apisb.etrade.com/docs/api/authorization/authorize Provides an example of the URL used to initiate the authorization process, including the consumer key and request token as parameters. ```APIDOC https://us.etrade.com/e/t/etws/authorize?key=282683cc9e4b8fc81dea6bc687d46758&token=%2FiQRgQCRGPo7Xdk6G8QDSEzX0Jsy6sKNcULcDavAGgU%3D ``` -------------------------------- ### E*TRADE API Get Option Chains Example Source: https://apisb.etrade.com/docs/api/market/api-market-v1 Illustrates how to request option chains for a given symbol with specific expiration dates and strike price parameters. The example shows the GET request URL. ```APIDOC Request URL: https://api.etrade.com/v1/market/optionchains?symbol=IBM&expiryYear=2018&expiryMonth=08&strikePriceNear=200&noOfStrikes=2 ``` -------------------------------- ### Preview Order Request URL Source: https://apisb.etrade.com/docs/api/order/api-order-v1 Example URL for previewing an order for a specific account. This is used before submitting an order to get a confirmation. ```APIDOC POST https://api.etrade.com/v1/accounts/{accountId}/orders/preview ``` -------------------------------- ### List Accounts Request and Response Example Source: https://apisb.etrade.com/docs/api/account/api-account-v1 This example demonstrates how to make a request to the E*TRADE API to list accounts and the expected XML response format. ```APIDOC Request: https://api.etrade.com/v1/accounts/list Response: 840104290 JIdOIAcSpwR1Jva7RQBraQ MARGIN INDIVIDUAL Individual Brokerage INDIVIDUAL BROKERAGE ACTIVE 0 ``` -------------------------------- ### E*TRADE API Access Token Request Example Source: https://apisb.etrade.com/docs/api/authorization/get_access_token An example of the HTTP header used to request an access token from the E*TRADE API. This demonstrates the correct formatting and inclusion of all required OAuth parameters. ```APIDOC Authorization: OAuth realm="",oauth_signature="FjoSQaFDKEDK1FJazlY3xArNflk%3D",oauth_nonce="LTg2ODUzOTQ5MTEzMTY3MzQwMzE%3D", oauth_signature_method="HMAC-SHA1",oauth_consumer_key= "282683cc9e4b8fc81dea6bc687d46758",oauth_timestamp="1273254425", oauth_verifier="Y27X25F",oauth_token=%2FiQRgQCRGPo7Xdk6G8QDSEzX0Jsy6sKNcULcDavAGgU%3D ``` -------------------------------- ### Place Options Order Response Source: https://apisb.etrade.com/docs/api/order/api-order-v1 Example JSON response for placing an options order. It details the order parameters, instrument, and any system messages or identifiers. ```JSON { "PlaceOrderResponse": { "orderType": "OPTN", "Order": { "orderTerm": "GOOD_FOR_DAY", "priceType": "MARKET", "limitPrice": "0", "stopPrice": "0", "marketSession": "REGULAR", "allOrNone": "false", "Instrument": { "Product": { "symbol": "FB", "securityType": "OPTN", "callPut": "CALL", "expiryYear": "2018", "expiryMonth": "12", "expiryDay": "21", "strikePrice": "140.00", "productId": { "symbol": "FB----210409P00297500", "typeCode": "OPTION" } }, "symbolDescription": "FB Dec 21 '18 $140 Call", "orderAction": "BUY_OPEN", "quantityType": "QUANTITY", "quantity": "1", "cancelQuantity": "0.0", "osiKey": "FB----181221C00140000", "reserveOrder": "true", "reserveQuantity": "0.0" }, "messages": { "Message": { "code": "1026", "description": "200|Your order was successfully entered during market hours.", "type": "WARNING" } }, "egQual": "EG_QUAL_NOT_AN_ELIGIBLE_SECURITY", "estimatedCommission": "5.45", "estimatedTotalAmount": "330.4644", "netPrice": "0", "netBid": "0", "netAsk": "0", "gcd": "0", "ratio": [] }, "dstFlag": "false", "optionLevelCd": "4", "marginLevelCd": "MARGIN_TRADING_ALLOWED", "OrderIds": { "orderId": "169" }, "placedTime": "1544038195663", "accountId": "314497960" } } ``` -------------------------------- ### E*TRADE API Symbol Lookup Example Source: https://apisb.etrade.com/docs/api/market/api-market-v1 Demonstrates how to perform a symbol lookup using the E*TRADE API. It includes the request URL and an example XML response containing symbol, description, and type for various equity symbols. ```APIDOC Request URL: https://api.etrade.com/v1/market/lookup/a Response: A AGILENT TECHNOLOGIES INC COM EQUITY AA ALCOA CORP COM EQUITY AABA ALTABA INC COM EQUITY AAPL APPLE INC COM EQUITY ABBV ABBVIE INC COM EQUITY ABEV AMBEV SA SPONSORED ADR EQUITY ABT ABBOTT LABS COM EQUITY ACN ACCENTURE PLC IRELAND SHS CLASS A EQUITY ADBE ADOBE SYS INC COM EQUITY ADP AUTOMATIC DATA PROCESSING INC COM EQUITY ``` -------------------------------- ### Place Equity Order Response Source: https://apisb.etrade.com/docs/api/order/api-order-v1 Example JSON response for placing an equity order. It includes details about the order, instrument, and any associated messages or identifiers. ```JSON { "PlaceOrderResponse":{ "orderType":"EQ", "dstFlag":false, "optionLevelCd":4, "marginLevelCd":"MARGIN_TRADING_ALLOWED", "placedTime":1549318099447, "accountId":"838796270", "Order":[ { "orderTerm":"GOOD_FOR_DAY", "priceType":"LIMIT", "limitPrice":169, "stopPrice":0, "marketSession":"REGULAR", "allOrNone":false, "messages":{ "Message":[ { "description":"200|The market was closed when we received your order. It has been entered into our system and will be reviewed prior to market open on the next regular trading day. After market open, please check to make sure your order was accepted.", "code":1027, "type":"WARNING" } ] }, "egQual":"EG_QUAL_NOT_A_MARKET_ORDER", "estimatedCommission":6.95, "estimatedTotalAmount":175.95, "netPrice":0, "netBid":0, "netAsk":0, "gcd":0, "ratio":"", "Instrument":[ { "symbolDescription":"FACEBOOK INC CL A", "orderAction":"BUY", "quantityType":"QUANTITY", "quantity":1, "cancelQuantity":0, "reserveOrder":true, "reserveQuantity":0, "Product":{ "symbol":"FB", "securityType":"EQ" } } ] } ], "OrderIds":[ { "orderId":485 } ] } } ``` -------------------------------- ### E*TRADE API Access Token Response Example Source: https://apisb.etrade.com/docs/api/authorization/get_access_token An example of the response received after a successful E*TRADE API access token request. It includes the access token and token secret, which are crucial for subsequent API interactions. ```APIDOC oauth_token=%3TiQRgQCRGPo7Xdk6G8QDSEzX0Jsy6sKNcULcDavAGgU%3D&oauth_token_secret=%7RrC9scEpzcwSEMy4vE7nodSzPLqfRINnTNY4voczyFM%3D ``` -------------------------------- ### Place Options Order Request Source: https://apisb.etrade.com/docs/api/order/api-order-v1 Example JSON request for placing an options order. This includes details like order type, client order ID, and instrument specifications for options. ```JSON { "PlaceOrderRequest":{ "orderType":"OPTN", "clientOrderId":"8e4153f1", "PreviewIds":[ { "previewId":"2785277279" } ], "Order":[ { "allOrNone":"false", "priceType":"MARKET", "limitPrice":"5", "stopPrice":"0", "orderTerm":"GOOD_FOR_DAY", "marketSession":"REGULAR", "Instrument":[ { "Product":{ "symbol":"FB", "securityType":"OPTN", "callPut":"CALL", "expiryYear":"2018", "expiryMonth":"12", "expiryDay":"21", "strikePrice":"140" }, "orderAction":"BUY_OPEN", "orderedQuantity":"1", "quantity":"1" } ] } ] } } ``` -------------------------------- ### E*TRADE API - Account Balance Response Example Source: https://apisb.etrade.com/docs/api/account/api-balance-v1 This snippet provides an example XML response from the E*TRADE API for an account balance request. It includes details such as account ID, type, computed values like net cash and buying power, and margin information. ```XML 835649790 PDT_ACCOUNT LEVEL_4 KRITHH TT 6 PDT_MIN_EQUITY_RES_1XK PDT ACCOUNT 0 0 0 93921.44 93921.44 0 0 0 0 0 93921.44 0 0 0 0 0 0 0 0 ``` -------------------------------- ### List Orders Response Source: https://apisb.etrade.com/docs/api/order/api-order-v1 Example XML response when listing orders. It includes order IDs, details URLs, and order types. ```XML 96
https://api.etrade.com/v1/accounts/ZrnXF-hPu853sBzwHfWGBQ/orders/96
EQ
95
https://api.etrade.com/v1/accounts/ZrnXF-hPu853sBzwHfWGBQ/orders/95
EQ
94
https://api.etrade.com/v1/accounts/ZrnXF-hPu853sBzwHfWGBQ/orders/94
EQ
93
https://api.etrade.com/v1/accounts/ZrnXF-hPu853sBzwHfWGBQ/orders/93
EQ
``` -------------------------------- ### Preview Order Request Source: https://apisb.etrade.com/docs/api/order/api-order-v1 Example XML request body for previewing an equity order. It includes details like order type, client order ID, instrument, quantity, and price. ```XML EQ sdfer333 false LIMIT GOOD_FOR_DAY REGULAR 188.51 EQ FB BUY QUANTITY 10 ``` -------------------------------- ### E*TRADE API Portfolio Request Example Source: https://apisb.etrade.com/docs/api/account/api-portfolio-v1 Demonstrates how to request portfolio information from the E*TRADE API. It includes the request URL and a sample XML response detailing account holdings, position information, and market data. ```APIDOC API Endpoint: Get Portfolio Request URL Method: GET URL: https://api.etrade.com/v1/accounts/{accountId}/portfolio Parameters: - accountId: The unique identifier for the account. Notes on Pagination: - Use the 'count' property to specify the number of items per page (default is 25). - Use the 'marker' property to specify the starting point for paging (default is the newest). - Each response includes a 'marker' for the next group of items. - To retrieve all items, repeat requests using the marker from the previous response until an empty marker is received. - The API does not support bi-directional paging directly. Applications can manage this by saving and re-using markers or storing returned items. ``` ```XML 835547880 10087531 0 0 0 EQ 0 A A -68400000 0 0 0 -120 TYPE2 SHORT 190.80 2.4472 -7605.60 0 -7605.60 0 -0.0008 0 0 0 0 0 64.970000 -1.59 -2.4472 63.38 1529429280 DELAYED 2431617 https://api.etrade.com/v1/accounts/JDIozUumZpHdgbIjMnAAHQ/portfolio/10087531 https://api.etrade.com/v1/market/quote/A 140357348131 0 0 0 EQ 0 TWTR TWTR -68400000 0 0 0 3 TYPE2 LONG -3.915 -2.8369 134.085 0 134.085 0 0.0235 0 0 0 0 0 46.000000 -1.305 -2.8369 44.695 1529429280 DELAYED 26582141 https://api.etrade.com/v1/accounts/yIFaUoJ81qyAhgxLWRQ42g/portfolio/140357348131 https://api.etrade.com/v1/market/quote/TWTR 1 ``` -------------------------------- ### E*TRADE API - Transaction Details Response Example Source: https://apisb.etrade.com/docs/api/account/api-transaction-v1 An example of an XML response for a transaction details request, illustrating the structure and data types of the returned transaction information. ```APIDOC 18144100000861 835649790 1527134400000 -2.0 ACH WITHDRAWL REFID:77521276; 0 0 Transfer 0.0 0.0 USD USD 0.0 0 ``` -------------------------------- ### Callback URL Examples with Verification Code Source: https://apisb.etrade.com/docs/api/authorization/authorize Illustrates how the verification code (oauth_verifier) is appended to the callback URL when the user authorizes the application, facilitating direct data transfer. ```APIDOC https://myapplicationsite.com/mytradingapp?oauth_verifier=WXYZ89 https://myapplicationsite.com?myapp=trading&oauth_verifier=WXYZ89 ``` -------------------------------- ### E*TRADE API - List Alerts Source: https://apisb.etrade.com/docs/api/user/api-alert-v1 Demonstrates how to request a list of user alerts from the E*TRADE API. Includes the request URL and an example XML response. ```APIDOC Request URL: https://api.etrade.com/v1/user/alerts Response (XML): 148 6774 1529426402 Transfer failed-Insufficient Funds UNREAD 6773 1529416825 AAPL down by at least 2.00% UNREAD ``` -------------------------------- ### List Orders Request URL Source: https://apisb.etrade.com/docs/api/order/api-order-v1 Example URL for listing orders for a specific account. This endpoint is used to retrieve a list of existing orders. ```APIDOC GET https://api.etrade.com/v1/accounts/{accountId}/orders ``` -------------------------------- ### Get Quote Request URL Source: https://apisb.etrade.com/docs/api/market/api-quote-v1 Example URL for retrieving quote information for a specific stock symbol. ```APIDOC https://api.etrade.com/v1/market/quote/GOOG ``` -------------------------------- ### Get Option Expire Dates Response Source: https://apisb.etrade.com/docs/api/market/api-market-v1 This is an example of the XML response received from the E*TRADE API when requesting option expiration dates. The response contains a list of expiration dates, each with a year, month, day, and expiry type. ```XML 2018 6 22 WEEKLY 2018 6 29 WEEKLY 2018 7 6 WEEKLY 2018 7 13 WEEKLY 2018 7 20 MONTHLY 2018 7 27 WEEKLY 2018 8 17 MONTHLY 2018 9 21 MONTHLY 2018 12 21 MONTHLY 2019 1 18 MONTHLY 2019 6 21 MONTHLY 2020 1 17 MONTHLY ``` -------------------------------- ### E*TRADE API - Delete Alerts Source: https://apisb.etrade.com/docs/api/user/api-alert-v1 Provides an example of how to delete one or more user alerts by specifying their IDs in the request URL. Includes the request URL and an example XML response. ```APIDOC Request URL: https://api.etrade.com/v1/user/alerts/{alertId1},{alertId2} Response (XML): Success ``` -------------------------------- ### E*TRADE Preview Order Request (Options) Source: https://apisb.etrade.com/docs/api/order/api-order-v1 Defines the structure for submitting a Preview Order request for options trades. Includes order parameters, client order ID, and instrument-specific details for options. ```APIDOC PreviewOrderRequest: orderType: OPTN clientOrderId: string Order: - allOrNone: string (e.g., "false") - priceType: string (e.g., MARKET) - limitPrice: string - stopPrice: string - orderTerm: string (e.g., GOOD_FOR_DAY) - marketSession: string (e.g., REGULAR) - Instrument: - Product: - symbol: string - securityType: string (e.g., OPTN) - callPut: string (e.g., CALL) - expiryYear: string - expiryMonth: string - expiryDay: string - strikePrice: string - orderAction: string (e.g., BUY_OPEN) - orderedQuantity: string - quantity: string ``` -------------------------------- ### Accounts API - Get Account Balances Source: https://apisb.etrade.com/docs/api/authorization/get_access_token Fetches the current balance information for a specified account. This includes cash and margin balances. ```APIDOC Accounts API: Get Account Balances [link](https://apisb.etrade.com/docs/api/account/api-balance-v1.html) ``` -------------------------------- ### E*TRADE API Place Order Request (Options) Source: https://apisb.etrade.com/docs/api/order/api-order-v1 This snippet shows the XML structure for a Place Order request for a single option. It includes details about the instrument, order action, quantity, and order terms. Dependencies include valid security details and order parameters. ```XML CALL 21 12 2018 OPTN 140 FB BUY_OPEN 1 1 false 5 REGULAR GOOD_FOR_DAY MARKET 0 2785277279 8e4153f1 OPTN ``` -------------------------------- ### Market API - Look Up Product Source: https://apisb.etrade.com/docs/api/authorization/get_access_token Searches for financial products (stocks, options, etc.) based on keywords or symbols. Returns detailed product information. ```APIDOC Market API: Look Up Product [link](https://apisb.etrade.com/docs/api/market/api-market-v1.html#/definition/Lookup) ``` -------------------------------- ### Cancel Order Request (XML) Source: https://apisb.etrade.com/docs/api/order/api-order-v1 Example XML request for canceling an order. It requires the specific order ID to be provided within the request body. ```XML 11 ``` -------------------------------- ### E*TRADE API Preview Order Request (Options) Source: https://apisb.etrade.com/docs/api/order/api-order-v1 This XML structure represents a request to the E*TRADE API for previewing an options order. It specifies the order details, including the instrument, product, quantity, price type, and client order ID. ```XML CALL 21 12 2018 OPTN 140 FB BUY_OPEN 1 1 false 5 REGULAR GOOD_FOR_DAY MARKET 0 8e4153f1 OPTN ``` -------------------------------- ### Market API - Get Option Chains Source: https://apisb.etrade.com/docs/api/authorization/get_access_token Retrieves option chain data for a given underlying security. Includes available expiration dates and strike prices. ```APIDOC Market API: Get Option Chains [link](https://apisb.etrade.com/docs/api/market/api-market-v1.html#/definition/getOptionChains) ``` -------------------------------- ### E*TRADE API - Order Placement and Cancellation Source: https://apisb.etrade.com/docs/api/order/api-order-v1 This section details the E*TRADE API endpoints for placing and canceling orders. It includes request parameters, HTTP methods, URL structures, and response information for both live and sandbox environments. ```APIDOC Place Order: Description: The Place Order API is used to submit an order after it has been successfully previewed. HTTP Method: POST Live URL: https://api.etrade.com/v1/accounts/{accountIdKey}/orders/place Sandbox URL: https://apisb.etrade.com/v1/accounts/{accountIdKey}/orders/place Request: accountIdKey (path, yes): The unique account key. Retrievable by calling the List Accounts API. PlaceOrderRequest (body, yes): The body of the place order request. Response: 200 (Successful operation): OrdersResponse 400 (Account key does not belong to user.): Error Code 100 400 (Please enter valid account key.): Error Code 102 Cancel Order: Description: The cancel order API is used to cancel an existing order. HTTP Method: PUT Live URL: https://api.etrade.com/v1/accounts/{accountIdKey}/orders/cancel Sandbox URL: https://apisb.etrade.com/v1/accounts/{accountIdKey}/orders/cancel Request: accountIdKey (path, yes): The unique account key. Retrievable by calling the List Accounts API. CancelOrderRequest (body, yes): The body of the request. Response: 200 (Successful operation): CancelOrderResponse 400 (Account key does not belong to user.): Error Code 100 400 (Please enter valid account key.): Error Code 102 ``` -------------------------------- ### Accounts API - List Transactions Source: https://apisb.etrade.com/docs/api/account/api-transaction-v1 Retrieves all transactions for a specified brokerage account. This API endpoint requires an account ID key and supports GET requests. ```APIDOC Accounts API - List Transactions Description: Get all transactions for the specified account. HTTP Method: GET Live URL: https://api.etrade.com/v1/accounts/{accountIdKey}/transactions Sandbox URL: https://apisb.etrade.com/v1/accounts/{accountIdKey}/transactions Parameters: - accountIdKey: The unique identifier for the brokerage account. ``` -------------------------------- ### E*TRADE API - Order Management Source: https://apisb.etrade.com/docs/api/order/api-order-v1 APIs for managing trading orders, including listing existing orders, previewing, placing, changing, and canceling orders. ```APIDOC APIDOC: List Orders: https://apisb.etrade.com/docs/api/order/api-order-v1.html#/definition/getOrders Preview Order: https://apisb.etrade.com/docs/api/order/api-order-v1.html#/definition/orderPreview Place Order: https://apisb.etrade.com/docs/api/order/api-order-v1.html#/definition/orderPlace Cancel Order: https://apisb.etrade.com/docs/api/order/api-order-v1.html#/definition/cancelOrder Change Previewed Order: https://apisb.etrade.com/docs/api/order/api-order-v1.html#/definition/changeOrderPreview Place Changed Order: https://apisb.etrade.com/docs/api/order/api-order-v1.html#/definition/changeOrderPlace ``` -------------------------------- ### Market API - Get Quotes Source: https://apisb.etrade.com/docs/api/authorization/get_access_token Retrieves real-time or delayed quotes for financial instruments. Supports various symbols and data points like price, volume, and change. ```APIDOC Market API: Get Quotes [link](https://apisb.etrade.com/docs/api/market/api-quote-v1.html) ``` -------------------------------- ### E*TRADE Preview Order Response (Options) Source: https://apisb.etrade.com/docs/api/order/api-order-v1 This snippet details the structure of a Preview Order Response for options trades. It includes order details, instrument information, and margin impact. ```APIDOC PreviewOrderResponse: orderType: Type of order (e.g., "SPREADS") totalOrderValue: Total value of the order previewTime: Timestamp of the preview dstFlag: Daylight Saving Time flag accountId: The account ID optionLevelCd: Option trading level code marginLevelCd: Margin trading level code Order: orderTerm: Order term (e.g., "GOOD_FOR_DAY") priceType: Type of price (e.g., "NET_DEBIT") limitPrice: Limit price stopPrice: Stop price marketSession: Market session (e.g., "REGULAR") allOrNone: All or none flag messages: Message: description: Description of the message code: Message code type: Message type (e.g., "WARNING") egQual: Eligibility qualifier estimatedCommission: Estimated commission estimatedTotalAmount: Estimated total amount netPrice: Net price netBid: Net bid netAsk: Net ask gcd: GCD value ratio: Ratio Instrument: symbolDescription: Description of the instrument symbol orderAction: Action for the order (e.g., "BUY_OPEN") quantityType: Type of quantity (e.g., "QUANTITY") quantity: Order quantity cancelQuantity: Quantity to cancel osiKey: OSI key reserveOrder: Reserve order flag reserveQuantity: Reserved quantity Product: symbol: Security symbol (e.g., "IBM") securityType: Type of security (e.g., "OPTN") callPut: Call or Put indicator expiryYear: Expiry year expiryMonth: Expiry month expiryDay: Expiry day strikePrice: Strike price PreviewIds: previewId: Unique identifier for the preview Disclosure: conditionalDisclosureFlag: Conditional disclosure flag aoDisclosureFlag: AO disclosure flag marginable: currentBp: Current buying power currentNetBp: Current net buying power currentOor: Current out of range currentOrderImpact: Current order impact netBp: Net buying power nonMarginable: currentBp: Current buying power currentNetBp: Current net buying power currentOor: Current out of range currentOrderImpact: Current order impact netBp: Net buying power ``` -------------------------------- ### Market API - Get Option Expire Dates Source: https://apisb.etrade.com/docs/api/authorization/get_access_token Fetches a list of available expiration dates for options on a specific security. Useful for planning options trading strategies. ```APIDOC Market API: Get Option Expire Dates [link](https://apisb.etrade.com/docs/api/market/api-market-v1.html#/definition/getOptionExpireDates) ``` -------------------------------- ### Order API - Preview Order Source: https://apisb.etrade.com/docs/api/authorization/get_access_token Allows users to preview an order before placing it. This helps in verifying order details and potential impact. ```APIDOC Order API: Preview Order [link](https://apisb.etrade.com/docs/api/order/api-order-v1.html#/definition/orderPreview) ``` -------------------------------- ### E*TRADE API - Authorization Source: https://apisb.etrade.com/docs/api/order/api-order-v1 APIs for managing user authorization, including obtaining request tokens, authorizing applications, and managing access tokens (getting, renewing, revoking). ```APIDOC APIDOC: Get Request Token: https://apisb.etrade.com/docs/api/authorization/request_token.html Authorize Application: https://apisb.etrade.com/docs/api/authorization/authorize.html Get Access Token: https://apisb.etrade.com/docs/api/authorization/get_access_token.html Renew Access Token: https://apisb.etrade.com/docs/api/authorization/renew_access_token.html Revoke Access Token: https://apisb.etrade.com/docs/api/authorization/revoke_access_token.html ``` -------------------------------- ### E*TRADE API - Preview Order Request (Spread Order) Source: https://apisb.etrade.com/docs/api/order/api-order-v1 This JSON snippet demonstrates the structure of a request to the E*TRADE API for previewing a spread order. It includes details for multiple legs of the spread, specifying options contracts, order actions, and pricing. ```JSON { "PreviewOrderRequest":{ "orderType":"SPREADS", "clientOrderId":"3453f1", "Order":[ { "allOrNone":"false", "priceType":"NET_DEBIT", "limitPrice":"5", "stopPrice":"0", "orderTerm":"GOOD_FOR_DAY", "marketSession":"REGULAR", "Instrument":[ { "Product":{ "symbol":"IBM", "securityType":"OPTN", "callPut":"CALL", "expiryYear":"2019", "expiryMonth":"02", "expiryDay":"15", "strikePrice":"130" }, "orderAction":"BUY_OPEN", "orderedQuantity":"1", "quantity":"1" }, { "Product":{ "symbol":"IBM", "securityType":"OPTN", "callPut":"CALL", "expiryYear":"2019", "expiryMonth":"02", "expiryDay":"15", "strikePrice":"131" }, "orderAction":"SELL_OPEN", "orderedQuantity":"1", "quantity":"1" } ] } ] } } ``` -------------------------------- ### Authorization API - Get Access Token Source: https://apisb.etrade.com/docs/api/authorization/get_access_token Retrieves an access token for authenticating API requests. This is a crucial step in the OAuth 2.0 flow for accessing E*TRADE services. ```APIDOC Authorization API: Get Access Token [link](https://apisb.etrade.com/docs/api/authorization/get_access_token.html#/definition/AccessToken) Overview: Returns an access token. ``` -------------------------------- ### E*TRADE Preview Order Request (Equity) Source: https://apisb.etrade.com/docs/api/order/api-order-v1 This snippet illustrates the structure of a Preview Order Request for equity trades. It specifies order type, client order ID, and instrument details. ```APIDOC PreviewOrderRequest: orderType: Type of order (e.g., "EQ") clientOrderId: Unique client-generated order ID Order: allOrNone: All or none flag priceType: Type of price (e.g., "LIMIT") orderTerm: Order term (e.g., "GOOD_FOR_DAY") marketSession: Market session (e.g., "REGULAR") stopPrice: Stop price limitPrice: Limit price Instrument: Product: securityType: Type of security (e.g., "EQ") symbol: Security symbol (e.g., "FB") orderAction: Action for the order (e.g., "BUY") quantityType: Type of quantity (e.g., "QUANTITY") quantity: Order quantity ```