snaptrade-typescript-sdk 9.0.199 → 10.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +42 -2
- package/dist/chunk-e9Ob2GDo.mjs +26 -0
- package/dist/index.cjs +6594 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +1 -0
- package/dist/index.d.mts +10422 -0
- package/dist/index.d.ts +1 -5
- package/dist/index.mjs +6527 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +27 -13
- package/dist/api/account-information-api-generated.d.ts +0 -950
- package/dist/api/account-information-api-generated.js +0 -1372
- package/dist/api/account-information-api.d.ts +0 -4
- package/dist/api/account-information-api.js +0 -22
- package/dist/api/api-status-api-generated.d.ts +0 -59
- package/dist/api/api-status-api-generated.js +0 -133
- package/dist/api/api-status-api.d.ts +0 -4
- package/dist/api/api-status-api.js +0 -22
- package/dist/api/authentication-api-generated.d.ts +0 -241
- package/dist/api/authentication-api-generated.js +0 -482
- package/dist/api/authentication-api.d.ts +0 -4
- package/dist/api/authentication-api.js +0 -22
- package/dist/api/connections-api-generated.d.ts +0 -576
- package/dist/api/connections-api-generated.js +0 -868
- package/dist/api/connections-api.d.ts +0 -4
- package/dist/api/connections-api.js +0 -22
- package/dist/api/options-api-generated.d.ts +0 -90
- package/dist/api/options-api-generated.js +0 -158
- package/dist/api/options-api.d.ts +0 -4
- package/dist/api/options-api.js +0 -22
- package/dist/api/reference-data-api-generated.d.ts +0 -497
- package/dist/api/reference-data-api-generated.js +0 -973
- package/dist/api/reference-data-api.d.ts +0 -4
- package/dist/api/reference-data-api.js +0 -22
- package/dist/api/trading-api-generated.d.ts +0 -1054
- package/dist/api/trading-api-generated.js +0 -1684
- package/dist/api/trading-api.d.ts +0 -4
- package/dist/api/trading-api.js +0 -22
- package/dist/api/transactions-and-reporting-api-generated.d.ts +0 -215
- package/dist/api/transactions-and-reporting-api-generated.js +0 -299
- package/dist/api/transactions-and-reporting-api.d.ts +0 -4
- package/dist/api/transactions-and-reporting-api.js +0 -22
- package/dist/api.d.ts +0 -8
- package/dist/api.js +0 -36
- package/dist/base.d.ts +0 -44
- package/dist/base.js +0 -60
- package/dist/browser.js +0 -2
- package/dist/browser.js.LICENSE.txt +0 -1
- package/dist/client-custom.d.ts +0 -4
- package/dist/client-custom.js +0 -7
- package/dist/client.d.ts +0 -14
- package/dist/client.js +0 -31
- package/dist/common.d.ts +0 -61
- package/dist/common.js +0 -220
- package/dist/configuration.d.ts +0 -98
- package/dist/configuration.js +0 -53
- package/dist/error.d.ts +0 -46
- package/dist/error.js +0 -105
- package/dist/index.js +0 -33
- package/dist/jest.config.d.ts +0 -3
- package/dist/jest.config.js +0 -13
- package/dist/mock.test.d.ts +0 -1
- package/dist/mock.test.js +0 -29
- package/dist/models/account-balance-total.d.ts +0 -19
- package/dist/models/account-balance-total.js +0 -2
- package/dist/models/account-balance.d.ts +0 -14
- package/dist/models/account-balance.js +0 -2
- package/dist/models/account-holdings-account.d.ts +0 -51
- package/dist/models/account-holdings-account.js +0 -2
- package/dist/models/account-holdings.d.ts +0 -37
- package/dist/models/account-holdings.js +0 -2
- package/dist/models/account-information-get-user-account-order-detail-request.d.ts +0 -13
- package/dist/models/account-information-get-user-account-order-detail-request.js +0 -2
- package/dist/models/account-order-record-child-brokerage-order-ids.d.ts +0 -19
- package/dist/models/account-order-record-child-brokerage-order-ids.js +0 -2
- package/dist/models/account-order-record-leg-instrument.d.ts +0 -38
- package/dist/models/account-order-record-leg-instrument.js +0 -2
- package/dist/models/account-order-record-leg.d.ts +0 -58
- package/dist/models/account-order-record-leg.js +0 -2
- package/dist/models/account-order-record-option-symbol.d.ts +0 -52
- package/dist/models/account-order-record-option-symbol.js +0 -2
- package/dist/models/account-order-record-quote-currency.d.ts +0 -25
- package/dist/models/account-order-record-quote-currency.js +0 -2
- package/dist/models/account-order-record-quote-universal-symbol.d.ts +0 -73
- package/dist/models/account-order-record-quote-universal-symbol.js +0 -2
- package/dist/models/account-order-record-status-v2.d.ts +0 -6
- package/dist/models/account-order-record-status-v2.js +0 -2
- package/dist/models/account-order-record-status.d.ts +0 -6
- package/dist/models/account-order-record-status.js +0 -2
- package/dist/models/account-order-record-trailing-stop.d.ts +0 -21
- package/dist/models/account-order-record-trailing-stop.js +0 -2
- package/dist/models/account-order-record-universal-symbol.d.ts +0 -73
- package/dist/models/account-order-record-universal-symbol.js +0 -2
- package/dist/models/account-order-record-v2.d.ts +0 -97
- package/dist/models/account-order-record-v2.js +0 -2
- package/dist/models/account-order-record.d.ts +0 -168
- package/dist/models/account-order-record.js +0 -2
- package/dist/models/account-orders-v2-response.d.ts +0 -15
- package/dist/models/account-orders-v2-response.js +0 -2
- package/dist/models/account-position.d.ts +0 -52
- package/dist/models/account-position.js +0 -2
- package/dist/models/account-simple.d.ts +0 -39
- package/dist/models/account-simple.js +0 -2
- package/dist/models/account-sync-status.d.ts +0 -21
- package/dist/models/account-sync-status.js +0 -2
- package/dist/models/account-universal-activity-currency.d.ts +0 -25
- package/dist/models/account-universal-activity-currency.js +0 -2
- package/dist/models/account-universal-activity-option-symbol.d.ts +0 -52
- package/dist/models/account-universal-activity-option-symbol.js +0 -2
- package/dist/models/account-universal-activity-symbol.d.ts +0 -65
- package/dist/models/account-universal-activity-symbol.js +0 -2
- package/dist/models/account-universal-activity.d.ts +0 -107
- package/dist/models/account-universal-activity.js +0 -2
- package/dist/models/account-value-history-item.d.ts +0 -20
- package/dist/models/account-value-history-item.js +0 -2
- package/dist/models/account-value-history-response.d.ts +0 -21
- package/dist/models/account-value-history-response.js +0 -2
- package/dist/models/account.d.ts +0 -126
- package/dist/models/account.js +0 -2
- package/dist/models/action-strict-with-options.d.ts +0 -6
- package/dist/models/action-strict-with-options.js +0 -2
- package/dist/models/action-strict.d.ts +0 -6
- package/dist/models/action-strict.js +0 -2
- package/dist/models/adr-instrument.d.ts +0 -59
- package/dist/models/adr-instrument.js +0 -2
- package/dist/models/all-account-positions-response.d.ts +0 -15
- package/dist/models/all-account-positions-response.js +0 -2
- package/dist/models/authentication-login-snap-trade-user200-response.d.ts +0 -7
- package/dist/models/authentication-login-snap-trade-user200-response.js +0 -2
- package/dist/models/balance-currency.d.ts +0 -25
- package/dist/models/balance-currency.js +0 -2
- package/dist/models/balance.d.ts +0 -27
- package/dist/models/balance.js +0 -2
- package/dist/models/brokerage-authorization-disabled-confirmation.d.ts +0 -14
- package/dist/models/brokerage-authorization-disabled-confirmation.js +0 -2
- package/dist/models/brokerage-authorization-refresh-confirmation.d.ts +0 -14
- package/dist/models/brokerage-authorization-refresh-confirmation.js +0 -2
- package/dist/models/brokerage-authorization-transactions-sync-confirmation.d.ts +0 -14
- package/dist/models/brokerage-authorization-transactions-sync-confirmation.js +0 -2
- package/dist/models/brokerage-authorization-type-read-only-brokerage.d.ts +0 -26
- package/dist/models/brokerage-authorization-type-read-only-brokerage.js +0 -2
- package/dist/models/brokerage-authorization-type-read-only.d.ts +0 -36
- package/dist/models/brokerage-authorization-type-read-only.js +0 -2
- package/dist/models/brokerage-authorization.d.ts +0 -73
- package/dist/models/brokerage-authorization.js +0 -2
- package/dist/models/brokerage-instrument.d.ts +0 -38
- package/dist/models/brokerage-instrument.js +0 -2
- package/dist/models/brokerage-instruments-response.d.ts +0 -15
- package/dist/models/brokerage-instruments-response.js +0 -2
- package/dist/models/brokerage-type.d.ts +0 -20
- package/dist/models/brokerage-type.js +0 -2
- package/dist/models/brokerage.d.ts +0 -122
- package/dist/models/brokerage.js +0 -2
- package/dist/models/cancel-order-response.d.ts +0 -22
- package/dist/models/cancel-order-response.js +0 -2
- package/dist/models/cef-instrument.d.ts +0 -59
- package/dist/models/cef-instrument.js +0 -2
- package/dist/models/child-brokerage-order-ids.d.ts +0 -20
- package/dist/models/child-brokerage-order-ids.js +0 -2
- package/dist/models/complex-order-leg.d.ts +0 -62
- package/dist/models/complex-order-leg.js +0 -2
- package/dist/models/complex-order-response.d.ts +0 -22
- package/dist/models/complex-order-response.js +0 -2
- package/dist/models/connections-session-events200-response-inner.d.ts +0 -6
- package/dist/models/connections-session-events200-response-inner.js +0 -2
- package/dist/models/crypto-instrument.d.ts +0 -59
- package/dist/models/crypto-instrument.js +0 -2
- package/dist/models/crypto-order-form.d.ts +0 -66
- package/dist/models/crypto-order-form.js +0 -2
- package/dist/models/crypto-order-preview-estimated-fee.d.ts +0 -20
- package/dist/models/crypto-order-preview-estimated-fee.js +0 -2
- package/dist/models/crypto-order-preview.d.ts +0 -15
- package/dist/models/crypto-order-preview.js +0 -2
- package/dist/models/crypto-trading-instrument.d.ts +0 -22
- package/dist/models/crypto-trading-instrument.js +0 -2
- package/dist/models/cryptocurrency-pair-quote.d.ts +0 -32
- package/dist/models/cryptocurrency-pair-quote.js +0 -2
- package/dist/models/cryptocurrency-pair.d.ts +0 -32
- package/dist/models/cryptocurrency-pair.js +0 -2
- package/dist/models/currency.d.ts +0 -26
- package/dist/models/currency.js +0 -2
- package/dist/models/delete-connection-confirmation.d.ts +0 -20
- package/dist/models/delete-connection-confirmation.js +0 -2
- package/dist/models/delete-user-response.d.ts +0 -26
- package/dist/models/delete-user-response.js +0 -2
- package/dist/models/dividend-at-date.d.ts +0 -26
- package/dist/models/dividend-at-date.js +0 -2
- package/dist/models/encrypted-response-encrypted-message-data.d.ts +0 -26
- package/dist/models/encrypted-response-encrypted-message-data.js +0 -2
- package/dist/models/encrypted-response.d.ts +0 -20
- package/dist/models/encrypted-response.js +0 -2
- package/dist/models/etf-instrument.d.ts +0 -59
- package/dist/models/etf-instrument.js +0 -2
- package/dist/models/exchange-rate-pairs.d.ts +0 -27
- package/dist/models/exchange-rate-pairs.js +0 -2
- package/dist/models/exchange.d.ts +0 -56
- package/dist/models/exchange.js +0 -2
- package/dist/models/figi-instrument.d.ts +0 -20
- package/dist/models/figi-instrument.js +0 -2
- package/dist/models/future-instrument.d.ts +0 -64
- package/dist/models/future-instrument.js +0 -2
- package/dist/models/holdings-status.d.ts +0 -19
- package/dist/models/holdings-status.js +0 -2
- package/dist/models/index.d.ts +0 -173
- package/dist/models/index.js +0 -189
- package/dist/models/instrument.d.ts +0 -33
- package/dist/models/instrument.js +0 -2
- package/dist/models/login-redirect-uri.d.ts +0 -19
- package/dist/models/login-redirect-uri.js +0 -2
- package/dist/models/manual-trade-and-impact.d.ts +0 -29
- package/dist/models/manual-trade-and-impact.js +0 -2
- package/dist/models/manual-trade-balance.d.ts +0 -28
- package/dist/models/manual-trade-balance.js +0 -2
- package/dist/models/manual-trade-form-bracket.d.ts +0 -67
- package/dist/models/manual-trade-form-bracket.js +0 -2
- package/dist/models/manual-trade-form-complex.d.ts +0 -28
- package/dist/models/manual-trade-form-complex.js +0 -2
- package/dist/models/manual-trade-form-notional-value.d.ts +0 -6
- package/dist/models/manual-trade-form-notional-value.js +0 -2
- package/dist/models/manual-trade-form-with-options.d.ts +0 -78
- package/dist/models/manual-trade-form-with-options.js +0 -2
- package/dist/models/manual-trade-form.d.ts +0 -65
- package/dist/models/manual-trade-form.js +0 -2
- package/dist/models/manual-trade-impact.d.ts +0 -38
- package/dist/models/manual-trade-impact.js +0 -2
- package/dist/models/manual-trade-replace-form.d.ts +0 -58
- package/dist/models/manual-trade-replace-form.js +0 -2
- package/dist/models/manual-trade-symbol.d.ts +0 -49
- package/dist/models/manual-trade-symbol.js +0 -2
- package/dist/models/manual-trade.d.ts +0 -60
- package/dist/models/manual-trade.js +0 -2
- package/dist/models/mleg-action-strict.d.ts +0 -6
- package/dist/models/mleg-action-strict.js +0 -2
- package/dist/models/mleg-instrument-type.d.ts +0 -6
- package/dist/models/mleg-instrument-type.js +0 -2
- package/dist/models/mleg-leg.d.ts +0 -28
- package/dist/models/mleg-leg.js +0 -2
- package/dist/models/mleg-order-response.d.ts +0 -21
- package/dist/models/mleg-order-response.js +0 -2
- package/dist/models/mleg-order-type-strict.d.ts +0 -6
- package/dist/models/mleg-order-type-strict.js +0 -2
- package/dist/models/mleg-price-effect-strict.d.ts +0 -6
- package/dist/models/mleg-price-effect-strict.js +0 -2
- package/dist/models/mleg-trade-form.d.ts +0 -47
- package/dist/models/mleg-trade-form.js +0 -2
- package/dist/models/mleg-trading-instrument.d.ts +0 -21
- package/dist/models/mleg-trading-instrument.js +0 -2
- package/dist/models/model400-failed-request-response.d.ts +0 -20
- package/dist/models/model400-failed-request-response.js +0 -2
- package/dist/models/model401-failed-request-response.d.ts +0 -20
- package/dist/models/model401-failed-request-response.js +0 -2
- package/dist/models/model402-brokerage-auth-already-disabled-exception.d.ts +0 -20
- package/dist/models/model402-brokerage-auth-already-disabled-exception.js +0 -2
- package/dist/models/model402-brokerage-auth-disabled-response.d.ts +0 -20
- package/dist/models/model402-brokerage-auth-disabled-response.js +0 -2
- package/dist/models/model403-failed-request-response.d.ts +0 -20
- package/dist/models/model403-failed-request-response.js +0 -2
- package/dist/models/model403-feature-not-enabled-response.d.ts +0 -20
- package/dist/models/model403-feature-not-enabled-response.js +0 -2
- package/dist/models/model404-failed-request-response.d.ts +0 -20
- package/dist/models/model404-failed-request-response.js +0 -2
- package/dist/models/model425-failed-request-response.d.ts +0 -20
- package/dist/models/model425-failed-request-response.js +0 -2
- package/dist/models/model500-unexpected-exception-response.d.ts +0 -26
- package/dist/models/model500-unexpected-exception-response.js +0 -2
- package/dist/models/monthly-dividends.d.ts +0 -21
- package/dist/models/monthly-dividends.js +0 -2
- package/dist/models/mutual-fund-instrument.d.ts +0 -59
- package/dist/models/mutual-fund-instrument.js +0 -2
- package/dist/models/net-contributions.d.ts +0 -26
- package/dist/models/net-contributions.js +0 -2
- package/dist/models/net-dividend.d.ts +0 -27
- package/dist/models/net-dividend.js +0 -2
- package/dist/models/notional-value.d.ts +0 -6
- package/dist/models/notional-value.js +0 -2
- package/dist/models/option-brokerage-symbol.d.ts +0 -29
- package/dist/models/option-brokerage-symbol.js +0 -2
- package/dist/models/option-chain-inner-chain-per-root-inner-chain-per-strike-price-inner.d.ts +0 -26
- package/dist/models/option-chain-inner-chain-per-root-inner-chain-per-strike-price-inner.js +0 -2
- package/dist/models/option-chain-inner-chain-per-root-inner.d.ts +0 -27
- package/dist/models/option-chain-inner-chain-per-root-inner.js +0 -2
- package/dist/models/option-chain-inner.d.ts +0 -39
- package/dist/models/option-chain-inner.js +0 -2
- package/dist/models/option-impact.d.ts +0 -28
- package/dist/models/option-impact.js +0 -2
- package/dist/models/option-instrument.d.ts +0 -60
- package/dist/models/option-instrument.js +0 -2
- package/dist/models/option-leg.d.ts +0 -28
- package/dist/models/option-leg.js +0 -2
- package/dist/models/option-quote-greeks.d.ts +0 -32
- package/dist/models/option-quote-greeks.js +0 -2
- package/dist/models/option-quote.d.ts +0 -39
- package/dist/models/option-quote.js +0 -2
- package/dist/models/option-strategy-legs-inner.d.ts +0 -31
- package/dist/models/option-strategy-legs-inner.js +0 -2
- package/dist/models/option-strategy.d.ts +0 -40
- package/dist/models/option-strategy.js +0 -2
- package/dist/models/options-position-currency.d.ts +0 -25
- package/dist/models/options-position-currency.js +0 -2
- package/dist/models/options-position.d.ts +0 -41
- package/dist/models/options-position.js +0 -2
- package/dist/models/options-symbol.d.ts +0 -53
- package/dist/models/options-symbol.js +0 -2
- package/dist/models/order-type-strict.d.ts +0 -6
- package/dist/models/order-type-strict.js +0 -2
- package/dist/models/order-updated-response-order.d.ts +0 -167
- package/dist/models/order-updated-response-order.js +0 -2
- package/dist/models/order-updated-response.d.ts +0 -21
- package/dist/models/order-updated-response.js +0 -2
- package/dist/models/other-instrument.d.ts +0 -59
- package/dist/models/other-instrument.js +0 -2
- package/dist/models/paginated-universal-activity.d.ts +0 -22
- package/dist/models/paginated-universal-activity.js +0 -2
- package/dist/models/pagination-details.d.ts +0 -26
- package/dist/models/pagination-details.js +0 -2
- package/dist/models/partner-data.d.ts +0 -82
- package/dist/models/partner-data.js +0 -2
- package/dist/models/past-value.d.ts +0 -26
- package/dist/models/past-value.js +0 -2
- package/dist/models/performance-custom.d.ts +0 -127
- package/dist/models/performance-custom.js +0 -2
- package/dist/models/position-currency.d.ts +0 -25
- package/dist/models/position-currency.js +0 -2
- package/dist/models/position-symbol.d.ts +0 -50
- package/dist/models/position-symbol.js +0 -2
- package/dist/models/position.d.ts +0 -66
- package/dist/models/position.js +0 -2
- package/dist/models/rate-of-return-object.d.ts +0 -28
- package/dist/models/rate-of-return-object.js +0 -2
- package/dist/models/rate-of-return-response.d.ts +0 -15
- package/dist/models/rate-of-return-response.js +0 -2
- package/dist/models/recent-orders-response.d.ts +0 -15
- package/dist/models/recent-orders-response.js +0 -2
- package/dist/models/security-type.d.ts +0 -33
- package/dist/models/security-type.js +0 -2
- package/dist/models/session-event.d.ts +0 -52
- package/dist/models/session-event.js +0 -2
- package/dist/models/simple-order-form.d.ts +0 -67
- package/dist/models/simple-order-form.js +0 -2
- package/dist/models/snap-trade-holdings-account.d.ts +0 -60
- package/dist/models/snap-trade-holdings-account.js +0 -2
- package/dist/models/snap-trade-holdings-total-value.d.ts +0 -20
- package/dist/models/snap-trade-holdings-total-value.js +0 -2
- package/dist/models/snap-trade-login-user-request-body.d.ts +0 -58
- package/dist/models/snap-trade-login-user-request-body.js +0 -2
- package/dist/models/snap-trade-register-user-request-body.d.ts +0 -13
- package/dist/models/snap-trade-register-user-request-body.js +0 -2
- package/dist/models/status.d.ts +0 -26
- package/dist/models/status.js +0 -2
- package/dist/models/stock-instrument-figi-instrument.d.ts +0 -19
- package/dist/models/stock-instrument-figi-instrument.js +0 -2
- package/dist/models/stock-instrument.d.ts +0 -59
- package/dist/models/stock-instrument.js +0 -2
- package/dist/models/stop-loss.d.ts +0 -20
- package/dist/models/stop-loss.js +0 -2
- package/dist/models/strategy-order-record.d.ts +0 -77
- package/dist/models/strategy-order-record.js +0 -2
- package/dist/models/strategy-quotes-greek.d.ts +0 -38
- package/dist/models/strategy-quotes-greek.js +0 -2
- package/dist/models/strategy-quotes.d.ts +0 -46
- package/dist/models/strategy-quotes.js +0 -2
- package/dist/models/sub-period-return-rate.d.ts +0 -26
- package/dist/models/sub-period-return-rate.js +0 -2
- package/dist/models/symbol-currency.d.ts +0 -25
- package/dist/models/symbol-currency.js +0 -2
- package/dist/models/symbol-exchange.d.ts +0 -55
- package/dist/models/symbol-exchange.js +0 -2
- package/dist/models/symbol-query.d.ts +0 -13
- package/dist/models/symbol-query.js +0 -2
- package/dist/models/symbol.d.ts +0 -66
- package/dist/models/symbol.js +0 -2
- package/dist/models/symbols-quotes-inner.d.ts +0 -44
- package/dist/models/symbols-quotes-inner.js +0 -2
- package/dist/models/take-profit.d.ts +0 -14
- package/dist/models/take-profit.js +0 -2
- package/dist/models/tax-lot.d.ts +0 -50
- package/dist/models/tax-lot.js +0 -2
- package/dist/models/time-in-force-strict.d.ts +0 -6
- package/dist/models/time-in-force-strict.js +0 -2
- package/dist/models/trade-detection-cancel-subscription-response.d.ts +0 -14
- package/dist/models/trade-detection-cancel-subscription-response.js +0 -2
- package/dist/models/trade-detection-subscription.d.ts +0 -26
- package/dist/models/trade-detection-subscription.js +0 -2
- package/dist/models/trading-instrument.d.ts +0 -22
- package/dist/models/trading-instrument.js +0 -2
- package/dist/models/trading-search-cryptocurrency-pair-instruments200-response.d.ts +0 -15
- package/dist/models/trading-search-cryptocurrency-pair-instruments200-response.js +0 -2
- package/dist/models/trading-session.d.ts +0 -6
- package/dist/models/trading-session.js +0 -2
- package/dist/models/trailing-stop.d.ts +0 -22
- package/dist/models/trailing-stop.js +0 -2
- package/dist/models/transactions-status.d.ts +0 -25
- package/dist/models/transactions-status.js +0 -2
- package/dist/models/underlying-option-instrument.d.ts +0 -27
- package/dist/models/underlying-option-instrument.js +0 -2
- package/dist/models/underlying-symbol-exchange.d.ts +0 -61
- package/dist/models/underlying-symbol-exchange.js +0 -2
- package/dist/models/underlying-symbol-type.d.ts +0 -32
- package/dist/models/underlying-symbol-type.js +0 -2
- package/dist/models/underlying-symbol.d.ts +0 -74
- package/dist/models/underlying-symbol.js +0 -2
- package/dist/models/universal-activity.d.ts +0 -114
- package/dist/models/universal-activity.js +0 -2
- package/dist/models/universal-symbol.d.ts +0 -74
- package/dist/models/universal-symbol.js +0 -2
- package/dist/models/user-idand-secret.d.ts +0 -19
- package/dist/models/user-idand-secret.js +0 -2
- package/dist/models/usexchange.d.ts +0 -62
- package/dist/models/usexchange.js +0 -2
- package/dist/models/validated-trade-body.d.ts +0 -13
- package/dist/models/validated-trade-body.js +0 -2
- package/dist/operationParameterMap.d.ts +0 -8
- package/dist/operationParameterMap.js +0 -966
- package/dist/pagination/page-types.d.ts +0 -16
- package/dist/pagination/page-types.js +0 -12
- package/dist/pagination/page.d.ts +0 -25
- package/dist/pagination/page.js +0 -32
- package/dist/pagination/pageable.d.ts +0 -47
- package/dist/pagination/pageable.js +0 -70
- package/dist/pagination/paginate.d.ts +0 -6
- package/dist/pagination/paginate.js +0 -39
- package/dist/requestAfterHook.d.ts +0 -8
- package/dist/requestAfterHook.js +0 -82
- package/dist/requestBeforeHook.d.ts +0 -10
- package/dist/requestBeforeHook.js +0 -8
- package/dist/requestBeforeUrlHook.d.ts +0 -7
- package/dist/requestBeforeUrlHook.js +0 -5
package/dist/mock.test.js
DELETED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
const axios_1 = require("axios");
|
|
13
|
-
const index_1 = require("./index");
|
|
14
|
-
describe("trailing slash is stripped", () => {
|
|
15
|
-
it("should make a GET request to the correct URL", () => __awaiter(void 0, void 0, void 0, function* () {
|
|
16
|
-
const mockGet = jest.fn().mockResolvedValueOnce({ data: {} });
|
|
17
|
-
axios_1.default.request = mockGet;
|
|
18
|
-
// Call your function
|
|
19
|
-
yield new index_1.Snaptrade({
|
|
20
|
-
consumerKey: process.env.SNAPTRADE_CONSUMER_KEY,
|
|
21
|
-
clientId: process.env.SNAPTRADE_CLIENT_ID,
|
|
22
|
-
basePath: "http://localhost:3000/api/proxy",
|
|
23
|
-
}).apiStatus.check();
|
|
24
|
-
// Assert that axios.get was called with the correct URL
|
|
25
|
-
expect(axios_1.default.request).toHaveBeenCalledWith(expect.objectContaining({
|
|
26
|
-
url: expect.stringContaining("http://localhost:3000/api/proxy?"),
|
|
27
|
-
}));
|
|
28
|
-
}));
|
|
29
|
-
});
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Total market value of this account (includes cash, equity, fixed income, etc). This value is directly obtained from the brokerage and should reflect the most accurate value of the account.
|
|
3
|
-
* @export
|
|
4
|
-
* @interface AccountBalanceTotal
|
|
5
|
-
*/
|
|
6
|
-
export interface AccountBalanceTotal {
|
|
7
|
-
/**
|
|
8
|
-
* Total value denominated in the currency of the `currency` field.
|
|
9
|
-
* @type {number}
|
|
10
|
-
* @memberof AccountBalanceTotal
|
|
11
|
-
*/
|
|
12
|
-
'amount'?: number;
|
|
13
|
-
/**
|
|
14
|
-
* The ISO-4217 currency code for the amount.
|
|
15
|
-
* @type {string}
|
|
16
|
-
* @memberof AccountBalanceTotal
|
|
17
|
-
*/
|
|
18
|
-
'currency'?: string;
|
|
19
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { AccountBalanceTotal } from './account-balance-total';
|
|
2
|
-
/**
|
|
3
|
-
* Contains balance related information for the account.
|
|
4
|
-
* @export
|
|
5
|
-
* @interface AccountBalance
|
|
6
|
-
*/
|
|
7
|
-
export interface AccountBalance {
|
|
8
|
-
/**
|
|
9
|
-
*
|
|
10
|
-
* @type {AccountBalanceTotal}
|
|
11
|
-
* @memberof AccountBalance
|
|
12
|
-
*/
|
|
13
|
-
'total'?: AccountBalanceTotal | null;
|
|
14
|
-
}
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
import { Account } from './account';
|
|
2
|
-
import { AccountOrderRecord } from './account-order-record';
|
|
3
|
-
import { Balance } from './balance';
|
|
4
|
-
import { OptionsPosition } from './options-position';
|
|
5
|
-
import { Position } from './position';
|
|
6
|
-
import { SnapTradeHoldingsTotalValue } from './snap-trade-holdings-total-value';
|
|
7
|
-
/**
|
|
8
|
-
* A wrapper object containing holdings information for a single account.
|
|
9
|
-
* @export
|
|
10
|
-
* @interface AccountHoldingsAccount
|
|
11
|
-
*/
|
|
12
|
-
export interface AccountHoldingsAccount {
|
|
13
|
-
[key: string]: any;
|
|
14
|
-
/**
|
|
15
|
-
*
|
|
16
|
-
* @type {Account}
|
|
17
|
-
* @memberof AccountHoldingsAccount
|
|
18
|
-
*/
|
|
19
|
-
'account'?: Account;
|
|
20
|
-
/**
|
|
21
|
-
* List of balances for the account. Each element of the list has a distinct currency. Some brokerages like Questrade [allows holding multiple currencies in the same account](https://www.questrade.com/learning/questrade-basics/balances-and-reports/understanding-your-account-balances).
|
|
22
|
-
* @type {Array<Balance>}
|
|
23
|
-
* @memberof AccountHoldingsAccount
|
|
24
|
-
*/
|
|
25
|
-
'balances'?: Array<Balance> | null;
|
|
26
|
-
/**
|
|
27
|
-
* List of stock/ETF/crypto/mutual fund positions in the account.
|
|
28
|
-
* @type {Array<Position>}
|
|
29
|
-
* @memberof AccountHoldingsAccount
|
|
30
|
-
*/
|
|
31
|
-
'positions'?: Array<Position> | null;
|
|
32
|
-
/**
|
|
33
|
-
* List of option positions in the account.
|
|
34
|
-
* @type {Array<OptionsPosition>}
|
|
35
|
-
* @memberof AccountHoldingsAccount
|
|
36
|
-
*/
|
|
37
|
-
'option_positions'?: Array<OptionsPosition> | null;
|
|
38
|
-
/**
|
|
39
|
-
* List of recent orders in the account, including both pending and executed orders. Note that option orders are included in this list. Option orders will have a null `universal_symbol` field and a non-null `option_symbol` field.
|
|
40
|
-
* @type {Array<AccountOrderRecord>}
|
|
41
|
-
* @memberof AccountHoldingsAccount
|
|
42
|
-
*/
|
|
43
|
-
'orders'?: Array<AccountOrderRecord> | null;
|
|
44
|
-
/**
|
|
45
|
-
*
|
|
46
|
-
* @type {SnapTradeHoldingsTotalValue}
|
|
47
|
-
* @memberof AccountHoldingsAccount
|
|
48
|
-
* @deprecated
|
|
49
|
-
*/
|
|
50
|
-
'total_value'?: SnapTradeHoldingsTotalValue;
|
|
51
|
-
}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { Balance } from './balance';
|
|
2
|
-
import { Position } from './position';
|
|
3
|
-
import { SnapTradeHoldingsAccount } from './snap-trade-holdings-account';
|
|
4
|
-
import { SnapTradeHoldingsTotalValue } from './snap-trade-holdings-total-value';
|
|
5
|
-
/**
|
|
6
|
-
* Account Holdings
|
|
7
|
-
* @export
|
|
8
|
-
* @interface AccountHoldings
|
|
9
|
-
*/
|
|
10
|
-
export interface AccountHoldings {
|
|
11
|
-
[key: string]: any;
|
|
12
|
-
/**
|
|
13
|
-
*
|
|
14
|
-
* @type {SnapTradeHoldingsAccount}
|
|
15
|
-
* @memberof AccountHoldings
|
|
16
|
-
*/
|
|
17
|
-
'account'?: SnapTradeHoldingsAccount;
|
|
18
|
-
/**
|
|
19
|
-
*
|
|
20
|
-
* @type {Array<Balance>}
|
|
21
|
-
* @memberof AccountHoldings
|
|
22
|
-
*/
|
|
23
|
-
'balances'?: Array<Balance> | null;
|
|
24
|
-
/**
|
|
25
|
-
*
|
|
26
|
-
* @type {Array<Position>}
|
|
27
|
-
* @memberof AccountHoldings
|
|
28
|
-
*/
|
|
29
|
-
'positions'?: Array<Position> | null;
|
|
30
|
-
/**
|
|
31
|
-
*
|
|
32
|
-
* @type {SnapTradeHoldingsTotalValue}
|
|
33
|
-
* @memberof AccountHoldings
|
|
34
|
-
* @deprecated
|
|
35
|
-
*/
|
|
36
|
-
'total_value'?: SnapTradeHoldingsTotalValue;
|
|
37
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
*
|
|
3
|
-
* @export
|
|
4
|
-
* @interface AccountInformationGetUserAccountOrderDetailRequest
|
|
5
|
-
*/
|
|
6
|
-
export interface AccountInformationGetUserAccountOrderDetailRequest {
|
|
7
|
-
/**
|
|
8
|
-
* Order ID returned by brokerage. This is the unique identifier for the order in the brokerage system.
|
|
9
|
-
* @type {string}
|
|
10
|
-
* @memberof AccountInformationGetUserAccountOrderDetailRequest
|
|
11
|
-
*/
|
|
12
|
-
'brokerage_order_id': string;
|
|
13
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
*
|
|
3
|
-
* @export
|
|
4
|
-
* @interface AccountOrderRecordChildBrokerageOrderIds
|
|
5
|
-
*/
|
|
6
|
-
export interface AccountOrderRecordChildBrokerageOrderIds {
|
|
7
|
-
/**
|
|
8
|
-
* The brokerage order ID for the take profit leg of the bracket order
|
|
9
|
-
* @type {string}
|
|
10
|
-
* @memberof AccountOrderRecordChildBrokerageOrderIds
|
|
11
|
-
*/
|
|
12
|
-
'take_profit_order_id'?: string;
|
|
13
|
-
/**
|
|
14
|
-
* The brokerage order ID for the stop loss leg of the bracket order
|
|
15
|
-
* @type {string}
|
|
16
|
-
* @memberof AccountOrderRecordChildBrokerageOrderIds
|
|
17
|
-
*/
|
|
18
|
-
'stop_loss_order_id'?: string;
|
|
19
|
-
}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Instrument metadata for an order leg.
|
|
3
|
-
* @export
|
|
4
|
-
* @interface AccountOrderRecordLegInstrument
|
|
5
|
-
*/
|
|
6
|
-
export interface AccountOrderRecordLegInstrument {
|
|
7
|
-
[key: string]: any;
|
|
8
|
-
/**
|
|
9
|
-
* The symbol or ticker for the security.
|
|
10
|
-
* @type {string}
|
|
11
|
-
* @memberof AccountOrderRecordLegInstrument
|
|
12
|
-
*/
|
|
13
|
-
'symbol'?: string;
|
|
14
|
-
/**
|
|
15
|
-
* Human-readable description of the security.
|
|
16
|
-
* @type {string}
|
|
17
|
-
* @memberof AccountOrderRecordLegInstrument
|
|
18
|
-
*/
|
|
19
|
-
'description'?: string;
|
|
20
|
-
/**
|
|
21
|
-
* Type of instrument for the leg. - EQUITY - OPTION - CRYPTO
|
|
22
|
-
* @type {string}
|
|
23
|
-
* @memberof AccountOrderRecordLegInstrument
|
|
24
|
-
*/
|
|
25
|
-
'asset_type'?: string;
|
|
26
|
-
/**
|
|
27
|
-
* Market Identifier Code (MIC) for the exchange on which the instrument trades.
|
|
28
|
-
* @type {string}
|
|
29
|
-
* @memberof AccountOrderRecordLegInstrument
|
|
30
|
-
*/
|
|
31
|
-
'exchange_mic_code'?: string;
|
|
32
|
-
/**
|
|
33
|
-
* Financial Instrument Global Identifier (FIGI) if available.
|
|
34
|
-
* @type {string}
|
|
35
|
-
* @memberof AccountOrderRecordLegInstrument
|
|
36
|
-
*/
|
|
37
|
-
'figi_code'?: string | null;
|
|
38
|
-
}
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
import { AccountOrderRecordLegInstrument } from './account-order-record-leg-instrument';
|
|
2
|
-
import { AccountOrderRecordStatusV2 } from './account-order-record-status-v2';
|
|
3
|
-
/**
|
|
4
|
-
* Describes an individual leg that makes up an order in the V2 format.
|
|
5
|
-
* @export
|
|
6
|
-
* @interface AccountOrderRecordLeg
|
|
7
|
-
*/
|
|
8
|
-
export interface AccountOrderRecordLeg {
|
|
9
|
-
[key: string]: any;
|
|
10
|
-
/**
|
|
11
|
-
* Brokerage order identifier for this leg, if available.
|
|
12
|
-
* @type {string}
|
|
13
|
-
* @memberof AccountOrderRecordLeg
|
|
14
|
-
*/
|
|
15
|
-
'leg_id'?: string | null;
|
|
16
|
-
/**
|
|
17
|
-
*
|
|
18
|
-
* @type {AccountOrderRecordLegInstrument}
|
|
19
|
-
* @memberof AccountOrderRecordLeg
|
|
20
|
-
*/
|
|
21
|
-
'instrument'?: AccountOrderRecordLegInstrument;
|
|
22
|
-
/**
|
|
23
|
-
* The action describes the intent or side of a trade. - BUY - SELL - BUY_COVER - SELL_SHORT - BUY_TO_OPEN - BUY_TO_CLOSE - SELL_TO_OPEN - SELL_TO_CLOSE
|
|
24
|
-
* @type {string}
|
|
25
|
-
* @memberof AccountOrderRecordLeg
|
|
26
|
-
*/
|
|
27
|
-
'action'?: string;
|
|
28
|
-
/**
|
|
29
|
-
* Execution price for this leg, if available.
|
|
30
|
-
* @type {number}
|
|
31
|
-
* @memberof AccountOrderRecordLeg
|
|
32
|
-
*/
|
|
33
|
-
'execution_price'?: number | null;
|
|
34
|
-
/**
|
|
35
|
-
* The total number of shares or contracts associated with this leg. Can be a decimal number for fractional shares.
|
|
36
|
-
* @type {string}
|
|
37
|
-
* @memberof AccountOrderRecordLeg
|
|
38
|
-
*/
|
|
39
|
-
'total_quantity'?: string | null;
|
|
40
|
-
/**
|
|
41
|
-
* The number of shares or contracts that have been canceled for this leg.
|
|
42
|
-
* @type {string}
|
|
43
|
-
* @memberof AccountOrderRecordLeg
|
|
44
|
-
*/
|
|
45
|
-
'canceled_quantity'?: string | null;
|
|
46
|
-
/**
|
|
47
|
-
* The number of shares or contracts that have been filled for this leg.
|
|
48
|
-
* @type {string}
|
|
49
|
-
* @memberof AccountOrderRecordLeg
|
|
50
|
-
*/
|
|
51
|
-
'filled_quantity'?: string | null;
|
|
52
|
-
/**
|
|
53
|
-
*
|
|
54
|
-
* @type {AccountOrderRecordStatusV2}
|
|
55
|
-
* @memberof AccountOrderRecordLeg
|
|
56
|
-
*/
|
|
57
|
-
'status'?: AccountOrderRecordStatusV2 | null;
|
|
58
|
-
}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { UnderlyingSymbol } from './underlying-symbol';
|
|
2
|
-
/**
|
|
3
|
-
* 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.
|
|
4
|
-
* @export
|
|
5
|
-
* @interface AccountOrderRecordOptionSymbol
|
|
6
|
-
*/
|
|
7
|
-
export interface AccountOrderRecordOptionSymbol {
|
|
8
|
-
/**
|
|
9
|
-
* Unique identifier for the option symbol within SnapTrade. This is the ID used to reference the symbol in SnapTrade API calls.
|
|
10
|
-
* @type {string}
|
|
11
|
-
* @memberof AccountOrderRecordOptionSymbol
|
|
12
|
-
*/
|
|
13
|
-
'id': string;
|
|
14
|
-
/**
|
|
15
|
-
* The [OCC symbol](https://en.wikipedia.org/wiki/Option_symbol) for the option.
|
|
16
|
-
* @type {string}
|
|
17
|
-
* @memberof AccountOrderRecordOptionSymbol
|
|
18
|
-
*/
|
|
19
|
-
'ticker': string;
|
|
20
|
-
/**
|
|
21
|
-
* The type of option. Either \"CALL\" or \"PUT\".
|
|
22
|
-
* @type {string}
|
|
23
|
-
* @memberof AccountOrderRecordOptionSymbol
|
|
24
|
-
*/
|
|
25
|
-
'option_type': AccountOrderRecordOptionSymbolOptionTypeEnum;
|
|
26
|
-
/**
|
|
27
|
-
* The option strike price.
|
|
28
|
-
* @type {number}
|
|
29
|
-
* @memberof AccountOrderRecordOptionSymbol
|
|
30
|
-
*/
|
|
31
|
-
'strike_price': number;
|
|
32
|
-
/**
|
|
33
|
-
* The option expiration date.
|
|
34
|
-
* @type {string}
|
|
35
|
-
* @memberof AccountOrderRecordOptionSymbol
|
|
36
|
-
*/
|
|
37
|
-
'expiration_date': string;
|
|
38
|
-
/**
|
|
39
|
-
* Whether the option is a mini option. Mini options have 10 underlying shares per contract instead of the standard 100.
|
|
40
|
-
* @type {boolean}
|
|
41
|
-
* @memberof AccountOrderRecordOptionSymbol
|
|
42
|
-
*/
|
|
43
|
-
'is_mini_option'?: boolean;
|
|
44
|
-
/**
|
|
45
|
-
*
|
|
46
|
-
* @type {UnderlyingSymbol}
|
|
47
|
-
* @memberof AccountOrderRecordOptionSymbol
|
|
48
|
-
*/
|
|
49
|
-
'underlying_symbol': UnderlyingSymbol;
|
|
50
|
-
}
|
|
51
|
-
type AccountOrderRecordOptionSymbolOptionTypeEnum = 'CALL' | 'PUT';
|
|
52
|
-
export {};
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Quote currency. This field is only present for cryptocurrency pair orders with a fiat currency as quote.
|
|
3
|
-
* @export
|
|
4
|
-
* @interface AccountOrderRecordQuoteCurrency
|
|
5
|
-
*/
|
|
6
|
-
export interface AccountOrderRecordQuoteCurrency {
|
|
7
|
-
/**
|
|
8
|
-
* Unique identifier for the currency. This is the UUID used to reference the currency in SnapTrade.
|
|
9
|
-
* @type {string}
|
|
10
|
-
* @memberof AccountOrderRecordQuoteCurrency
|
|
11
|
-
*/
|
|
12
|
-
'id'?: string;
|
|
13
|
-
/**
|
|
14
|
-
* The ISO-4217 currency code for the currency.
|
|
15
|
-
* @type {string}
|
|
16
|
-
* @memberof AccountOrderRecordQuoteCurrency
|
|
17
|
-
*/
|
|
18
|
-
'code'?: string;
|
|
19
|
-
/**
|
|
20
|
-
* A human-friendly name of the currency.
|
|
21
|
-
* @type {string}
|
|
22
|
-
* @memberof AccountOrderRecordQuoteCurrency
|
|
23
|
-
*/
|
|
24
|
-
'name'?: string;
|
|
25
|
-
}
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import { Currency } from './currency';
|
|
2
|
-
import { SecurityType } from './security-type';
|
|
3
|
-
import { StockInstrumentFigiInstrument } from './stock-instrument-figi-instrument';
|
|
4
|
-
import { SymbolCurrency } from './symbol-currency';
|
|
5
|
-
import { SymbolExchange } from './symbol-exchange';
|
|
6
|
-
/**
|
|
7
|
-
* Quote cryptocurrency. This field is only present for cryptocurrency pair orders with a cryptocurrency as quote.
|
|
8
|
-
* @export
|
|
9
|
-
* @interface AccountOrderRecordQuoteUniversalSymbol
|
|
10
|
-
*/
|
|
11
|
-
export interface AccountOrderRecordQuoteUniversalSymbol {
|
|
12
|
-
/**
|
|
13
|
-
* Unique identifier for the symbol within SnapTrade. This is the ID used to reference the symbol in SnapTrade API calls.
|
|
14
|
-
* @type {string}
|
|
15
|
-
* @memberof AccountOrderRecordQuoteUniversalSymbol
|
|
16
|
-
*/
|
|
17
|
-
'id': string;
|
|
18
|
-
/**
|
|
19
|
-
* 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.
|
|
20
|
-
* @type {string}
|
|
21
|
-
* @memberof AccountOrderRecordQuoteUniversalSymbol
|
|
22
|
-
*/
|
|
23
|
-
'symbol': string;
|
|
24
|
-
/**
|
|
25
|
-
* The raw symbol is `symbol` with the exchange suffix removed. For example, if `symbol` is \"VAB.TO\", then `raw_symbol` is \"VAB\".
|
|
26
|
-
* @type {string}
|
|
27
|
-
* @memberof AccountOrderRecordQuoteUniversalSymbol
|
|
28
|
-
*/
|
|
29
|
-
'raw_symbol': string;
|
|
30
|
-
/**
|
|
31
|
-
* A human-readable description of the security. This is usually the company name or ETF name.
|
|
32
|
-
* @type {string}
|
|
33
|
-
* @memberof AccountOrderRecordQuoteUniversalSymbol
|
|
34
|
-
*/
|
|
35
|
-
'description'?: string | null;
|
|
36
|
-
/**
|
|
37
|
-
*
|
|
38
|
-
* @type {SymbolCurrency}
|
|
39
|
-
* @memberof AccountOrderRecordQuoteUniversalSymbol
|
|
40
|
-
*/
|
|
41
|
-
'currency': SymbolCurrency;
|
|
42
|
-
/**
|
|
43
|
-
*
|
|
44
|
-
* @type {SymbolExchange}
|
|
45
|
-
* @memberof AccountOrderRecordQuoteUniversalSymbol
|
|
46
|
-
*/
|
|
47
|
-
'exchange'?: SymbolExchange;
|
|
48
|
-
/**
|
|
49
|
-
*
|
|
50
|
-
* @type {SecurityType}
|
|
51
|
-
* @memberof AccountOrderRecordQuoteUniversalSymbol
|
|
52
|
-
*/
|
|
53
|
-
'type': SecurityType;
|
|
54
|
-
/**
|
|
55
|
-
* 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.
|
|
56
|
-
* @type {string}
|
|
57
|
-
* @memberof AccountOrderRecordQuoteUniversalSymbol
|
|
58
|
-
*/
|
|
59
|
-
'figi_code'?: string | null;
|
|
60
|
-
/**
|
|
61
|
-
*
|
|
62
|
-
* @type {StockInstrumentFigiInstrument}
|
|
63
|
-
* @memberof AccountOrderRecordQuoteUniversalSymbol
|
|
64
|
-
*/
|
|
65
|
-
'figi_instrument'?: StockInstrumentFigiInstrument | null;
|
|
66
|
-
/**
|
|
67
|
-
* This field is deprecated and should not be used. Please reach out to SnapTrade support if you have a valid use case for this.
|
|
68
|
-
* @type {Array<Currency>}
|
|
69
|
-
* @memberof AccountOrderRecordQuoteUniversalSymbol
|
|
70
|
-
* @deprecated
|
|
71
|
-
*/
|
|
72
|
-
'currencies': Array<Currency>;
|
|
73
|
-
}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Indicates the status of an order. SnapTrade does a best effort to map brokerage statuses to statuses in this enum.
|
|
3
|
-
* @export
|
|
4
|
-
* @enum {string}
|
|
5
|
-
*/
|
|
6
|
-
export type AccountOrderRecordStatusV2 = 'PENDING' | 'REJECTED' | 'CANCELED' | 'CANCEL_PENDING' | 'PARTIAL_CANCELED' | 'EXECUTED' | 'PARTIALLY_EXECUTED' | 'REPLACED' | 'REPLACE_PENDING' | 'EXPIRED';
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Indicates the status of an order. SnapTrade does a best effort to map brokerage statuses to statuses in this enum. Possible values include: - NONE - PENDING - ACCEPTED - FAILED - REJECTED - CANCELED - PARTIAL_CANCELED - CANCEL_PENDING - EXECUTED - PARTIAL - REPLACE_PENDING - REPLACED - EXPIRED - QUEUED - TRIGGERED - ACTIVATED
|
|
3
|
-
* @export
|
|
4
|
-
* @enum {string}
|
|
5
|
-
*/
|
|
6
|
-
export type AccountOrderRecordStatus = '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';
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* For trailing stop orders, contains the trail configuration. Null for all other order types.
|
|
3
|
-
* @export
|
|
4
|
-
* @interface AccountOrderRecordTrailingStop
|
|
5
|
-
*/
|
|
6
|
-
export interface AccountOrderRecordTrailingStop {
|
|
7
|
-
/**
|
|
8
|
-
* The trail amount. Interpreted as dollars if `type` is `DOLLAR`, or a percentage if `type` is `PERCENT`.
|
|
9
|
-
* @type {string}
|
|
10
|
-
* @memberof AccountOrderRecordTrailingStop
|
|
11
|
-
*/
|
|
12
|
-
'amount': string;
|
|
13
|
-
/**
|
|
14
|
-
* 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%.
|
|
15
|
-
* @type {string}
|
|
16
|
-
* @memberof AccountOrderRecordTrailingStop
|
|
17
|
-
*/
|
|
18
|
-
'type': AccountOrderRecordTrailingStopTypeEnum;
|
|
19
|
-
}
|
|
20
|
-
type AccountOrderRecordTrailingStopTypeEnum = 'DOLLAR' | 'PERCENT';
|
|
21
|
-
export {};
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import { Currency } from './currency';
|
|
2
|
-
import { SecurityType } from './security-type';
|
|
3
|
-
import { StockInstrumentFigiInstrument } from './stock-instrument-figi-instrument';
|
|
4
|
-
import { SymbolCurrency } from './symbol-currency';
|
|
5
|
-
import { SymbolExchange } from './symbol-exchange';
|
|
6
|
-
/**
|
|
7
|
-
* 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.
|
|
8
|
-
* @export
|
|
9
|
-
* @interface AccountOrderRecordUniversalSymbol
|
|
10
|
-
*/
|
|
11
|
-
export interface AccountOrderRecordUniversalSymbol {
|
|
12
|
-
/**
|
|
13
|
-
* Unique identifier for the symbol within SnapTrade. This is the ID used to reference the symbol in SnapTrade API calls.
|
|
14
|
-
* @type {string}
|
|
15
|
-
* @memberof AccountOrderRecordUniversalSymbol
|
|
16
|
-
*/
|
|
17
|
-
'id': string;
|
|
18
|
-
/**
|
|
19
|
-
* 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.
|
|
20
|
-
* @type {string}
|
|
21
|
-
* @memberof AccountOrderRecordUniversalSymbol
|
|
22
|
-
*/
|
|
23
|
-
'symbol': string;
|
|
24
|
-
/**
|
|
25
|
-
* The raw symbol is `symbol` with the exchange suffix removed. For example, if `symbol` is \"VAB.TO\", then `raw_symbol` is \"VAB\".
|
|
26
|
-
* @type {string}
|
|
27
|
-
* @memberof AccountOrderRecordUniversalSymbol
|
|
28
|
-
*/
|
|
29
|
-
'raw_symbol': string;
|
|
30
|
-
/**
|
|
31
|
-
* A human-readable description of the security. This is usually the company name or ETF name.
|
|
32
|
-
* @type {string}
|
|
33
|
-
* @memberof AccountOrderRecordUniversalSymbol
|
|
34
|
-
*/
|
|
35
|
-
'description'?: string | null;
|
|
36
|
-
/**
|
|
37
|
-
*
|
|
38
|
-
* @type {SymbolCurrency}
|
|
39
|
-
* @memberof AccountOrderRecordUniversalSymbol
|
|
40
|
-
*/
|
|
41
|
-
'currency': SymbolCurrency;
|
|
42
|
-
/**
|
|
43
|
-
*
|
|
44
|
-
* @type {SymbolExchange}
|
|
45
|
-
* @memberof AccountOrderRecordUniversalSymbol
|
|
46
|
-
*/
|
|
47
|
-
'exchange'?: SymbolExchange;
|
|
48
|
-
/**
|
|
49
|
-
*
|
|
50
|
-
* @type {SecurityType}
|
|
51
|
-
* @memberof AccountOrderRecordUniversalSymbol
|
|
52
|
-
*/
|
|
53
|
-
'type': SecurityType;
|
|
54
|
-
/**
|
|
55
|
-
* 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.
|
|
56
|
-
* @type {string}
|
|
57
|
-
* @memberof AccountOrderRecordUniversalSymbol
|
|
58
|
-
*/
|
|
59
|
-
'figi_code'?: string | null;
|
|
60
|
-
/**
|
|
61
|
-
*
|
|
62
|
-
* @type {StockInstrumentFigiInstrument}
|
|
63
|
-
* @memberof AccountOrderRecordUniversalSymbol
|
|
64
|
-
*/
|
|
65
|
-
'figi_instrument'?: StockInstrumentFigiInstrument | null;
|
|
66
|
-
/**
|
|
67
|
-
* This field is deprecated and should not be used. Please reach out to SnapTrade support if you have a valid use case for this.
|
|
68
|
-
* @type {Array<Currency>}
|
|
69
|
-
* @memberof AccountOrderRecordUniversalSymbol
|
|
70
|
-
* @deprecated
|
|
71
|
-
*/
|
|
72
|
-
'currencies': Array<Currency>;
|
|
73
|
-
}
|