snaptrade-typescript-sdk 10.0.7 → 10.0.9
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 +18 -7
- package/dist/browser.umd.js +1 -1
- package/dist/index.cjs +15 -10
- package/dist/index.d.cts +71 -8
- package/dist/index.d.mts +71 -8
- package/dist/index.d.ts +71 -8
- package/dist/index.mjs +15 -10
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -3194,6 +3194,22 @@ type ActionStrict = 'BUY' | 'SELL';
|
|
|
3194
3194
|
*/
|
|
3195
3195
|
type ActionStrictWithOptions = 'BUY' | 'SELL' | 'BUY_TO_OPEN' | 'BUY_TO_CLOSE' | 'SELL_TO_OPEN' | 'SELL_TO_CLOSE';
|
|
3196
3196
|
//#endregion
|
|
3197
|
+
//#region models/all-account-positions-response-data-freshness.d.ts
|
|
3198
|
+
/**
|
|
3199
|
+
* Metadata describing freshness of the returned positions data.
|
|
3200
|
+
* @export
|
|
3201
|
+
* @interface AllAccountPositionsResponseDataFreshness
|
|
3202
|
+
*/
|
|
3203
|
+
interface AllAccountPositionsResponseDataFreshness {
|
|
3204
|
+
[key: string]: any;
|
|
3205
|
+
/**
|
|
3206
|
+
* The time the returned positions data was fetched from the brokerage.
|
|
3207
|
+
* @type {string}
|
|
3208
|
+
* @memberof AllAccountPositionsResponseDataFreshness
|
|
3209
|
+
*/
|
|
3210
|
+
'as_of': string;
|
|
3211
|
+
}
|
|
3212
|
+
//#endregion
|
|
3197
3213
|
//#region models/all-account-positions-response.d.ts
|
|
3198
3214
|
/**
|
|
3199
3215
|
* Information about all account positions.
|
|
@@ -3208,6 +3224,12 @@ interface AllAccountPositionsResponse {
|
|
|
3208
3224
|
* @memberof AllAccountPositionsResponse
|
|
3209
3225
|
*/
|
|
3210
3226
|
'results': Array<AccountPosition>;
|
|
3227
|
+
/**
|
|
3228
|
+
*
|
|
3229
|
+
* @type {AllAccountPositionsResponseDataFreshness}
|
|
3230
|
+
* @memberof AllAccountPositionsResponse
|
|
3231
|
+
*/
|
|
3232
|
+
'data_freshness': AllAccountPositionsResponseDataFreshness;
|
|
3211
3233
|
}
|
|
3212
3234
|
//#endregion
|
|
3213
3235
|
//#region models/encrypted-response-encrypted-message-data.d.ts
|
|
@@ -4465,7 +4487,7 @@ interface ManualTradeFormComplex {
|
|
|
4465
4487
|
*/
|
|
4466
4488
|
'orders': Array<ComplexOrderLeg>;
|
|
4467
4489
|
/**
|
|
4468
|
-
*
|
|
4490
|
+
*
|
|
4469
4491
|
* @type {string}
|
|
4470
4492
|
* @memberof ManualTradeFormComplex
|
|
4471
4493
|
*/
|
|
@@ -4473,6 +4495,14 @@ interface ManualTradeFormComplex {
|
|
|
4473
4495
|
}
|
|
4474
4496
|
type ManualTradeFormComplexTypeEnum = 'OCO' | 'OTO' | 'OTOCO';
|
|
4475
4497
|
//#endregion
|
|
4498
|
+
//#region models/manual-trade-place-time-in-force-strict.d.ts
|
|
4499
|
+
/**
|
|
4500
|
+
* The Time in Force type for the order. This field indicates how long the order will remain active before it is executed or expires. Here are the supported values: - `Day` - Day. The order is valid only for the trading day on which it is placed. - `GTC` - Good Til Canceled. The order is valid until it is executed or canceled. - `FOK` - Fill Or Kill. The order must be executed in its entirety immediately or be canceled completely. - `IOC` - Immediate Or Cancel. The order must be executed immediately. Any portion of the order that cannot be filled immediately will be canceled. - `GTD` - Good Til Date. The order is valid until `expiry_date`, which is required. Not available for market orders. GTD orders are only available on certain brokerages. Visit https://support.snaptrade.com/brokerages for brokerage support.
|
|
4501
|
+
* @export
|
|
4502
|
+
* @enum {string}
|
|
4503
|
+
*/
|
|
4504
|
+
type ManualTradePlaceTimeInForceStrict = 'FOK' | 'Day' | 'GTC' | 'IOC' | 'GTD';
|
|
4505
|
+
//#endregion
|
|
4476
4506
|
//#region models/trading-session.d.ts
|
|
4477
4507
|
/**
|
|
4478
4508
|
* The trading session for the order. This field indicates which market session the order will be placed in. This is only available for certain brokerages. Defaults to REGULAR. Here are the supported values: - `REGULAR` - Regular trading hours. - `EXTENDED` - Extended trading hours.
|
|
@@ -4519,17 +4549,23 @@ interface ManualTradeFormWithOptions {
|
|
|
4519
4549
|
*/
|
|
4520
4550
|
'order_type': OrderTypeStrict;
|
|
4521
4551
|
/**
|
|
4522
|
-
* The Time in Force type for the order. This field indicates how long the order will remain active before it is executed or expires. Here are the supported values: - `Day` - Day. The order is valid only for the trading day on which it is placed. - `GTC` - Good Til Canceled. The order is valid until it is executed or canceled. - `FOK` - Fill Or Kill. The order must be executed in its entirety immediately or be canceled completely. - `IOC` - Immediate Or Cancel. The order must be executed immediately. Any portion of the order that cannot be filled immediately will be canceled.
|
|
4523
|
-
* @type {
|
|
4552
|
+
* The Time in Force type for the order. This field indicates how long the order will remain active before it is executed or expires. Here are the supported values: - `Day` - Day. The order is valid only for the trading day on which it is placed. - `GTC` - Good Til Canceled. The order is valid until it is executed or canceled. - `FOK` - Fill Or Kill. The order must be executed in its entirety immediately or be canceled completely. - `IOC` - Immediate Or Cancel. The order must be executed immediately. Any portion of the order that cannot be filled immediately will be canceled. - `GTD` - Good Til Date. The order is valid until `expiry_date`, which is required. Not available for market orders. GTD orders are only available on certain brokerages. Visit https://support.snaptrade.com/brokerages for brokerage support.
|
|
4553
|
+
* @type {ManualTradePlaceTimeInForceStrict}
|
|
4524
4554
|
* @memberof ManualTradeFormWithOptions
|
|
4525
4555
|
*/
|
|
4526
|
-
'time_in_force':
|
|
4556
|
+
'time_in_force': ManualTradePlaceTimeInForceStrict;
|
|
4527
4557
|
/**
|
|
4528
4558
|
* The trading session for the order. This field indicates which market session the order will be placed in. This is only available for certain brokerages. Defaults to REGULAR. Here are the supported values: - `REGULAR` - Regular trading hours. - `EXTENDED` - Extended trading hours.
|
|
4529
4559
|
* @type {TradingSession}
|
|
4530
4560
|
* @memberof ManualTradeFormWithOptions
|
|
4531
4561
|
*/
|
|
4532
4562
|
'trading_session'?: TradingSession;
|
|
4563
|
+
/**
|
|
4564
|
+
* Timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format indicating when the order expires. Required when `time_in_force` is `GTD`. Include a timezone offset or `Z` for UTC; if no timezone is provided, UTC is assumed. GTD orders are only available on certain brokerages. Visit https://support.snaptrade.com/brokerages for brokerage support.
|
|
4565
|
+
* @type {string}
|
|
4566
|
+
* @memberof ManualTradeFormWithOptions
|
|
4567
|
+
*/
|
|
4568
|
+
'expiry_date'?: string | null;
|
|
4533
4569
|
/**
|
|
4534
4570
|
* The limit price for `Limit` and `StopLimit` orders.
|
|
4535
4571
|
* @type {number}
|
|
@@ -4554,6 +4590,12 @@ interface ManualTradeFormWithOptions {
|
|
|
4554
4590
|
* @memberof ManualTradeFormWithOptions
|
|
4555
4591
|
*/
|
|
4556
4592
|
'notional_value'?: ManualTradeFormNotionalValue | null;
|
|
4593
|
+
/**
|
|
4594
|
+
*
|
|
4595
|
+
* @type {string}
|
|
4596
|
+
* @memberof ManualTradeFormWithOptions
|
|
4597
|
+
*/
|
|
4598
|
+
'client_order_id'?: string | null;
|
|
4557
4599
|
}
|
|
4558
4600
|
//#endregion
|
|
4559
4601
|
//#region models/manual-trade-replace-form.d.ts
|
|
@@ -6370,6 +6412,27 @@ interface TradeDetectionAddSubscriptionRequest {
|
|
|
6370
6412
|
* @memberof TradeDetectionAddSubscriptionRequest
|
|
6371
6413
|
*/
|
|
6372
6414
|
'account_id': string;
|
|
6415
|
+
/**
|
|
6416
|
+
* How often the subscribed account should be checked for new trades. Must match an active Trade Detection plan.
|
|
6417
|
+
* @type {number}
|
|
6418
|
+
* @memberof TradeDetectionAddSubscriptionRequest
|
|
6419
|
+
*/
|
|
6420
|
+
'check_interval_seconds': number;
|
|
6421
|
+
}
|
|
6422
|
+
//#endregion
|
|
6423
|
+
//#region models/trade-detection-cancel-subscription-request.d.ts
|
|
6424
|
+
/**
|
|
6425
|
+
*
|
|
6426
|
+
* @export
|
|
6427
|
+
* @interface TradeDetectionCancelSubscriptionRequest
|
|
6428
|
+
*/
|
|
6429
|
+
interface TradeDetectionCancelSubscriptionRequest {
|
|
6430
|
+
/**
|
|
6431
|
+
* Unique identifier for the connected brokerage account. This is the UUID used to reference the account in SnapTrade.
|
|
6432
|
+
* @type {string}
|
|
6433
|
+
* @memberof TradeDetectionCancelSubscriptionRequest
|
|
6434
|
+
*/
|
|
6435
|
+
'account_id': string;
|
|
6373
6436
|
}
|
|
6374
6437
|
//#endregion
|
|
6375
6438
|
//#region models/trade-detection-cancel-subscription-response.d.ts
|
|
@@ -8553,11 +8616,11 @@ declare const ExperimentalEndpointsApiAxiosParamCreator: (configuration?: Config
|
|
|
8553
8616
|
/**
|
|
8554
8617
|
* Cancels a Trade Detection subscription for a connected brokerage account. This endpoint requires partner signature authentication only and does not require `userId` or `userSecret`.
|
|
8555
8618
|
* @summary Cancel a Trade Detection subscription
|
|
8556
|
-
* @param {
|
|
8619
|
+
* @param {TradeDetectionCancelSubscriptionRequest} tradeDetectionCancelSubscriptionRequest
|
|
8557
8620
|
* @param {*} [options] Override http request option.
|
|
8558
8621
|
* @throws {RequiredError}
|
|
8559
8622
|
*/
|
|
8560
|
-
cancelSubscription: (
|
|
8623
|
+
cancelSubscription: (tradeDetectionCancelSubscriptionRequest: TradeDetectionCancelSubscriptionRequest, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
8561
8624
|
/**
|
|
8562
8625
|
* Returns the detail of a single order using the brokerage order ID provided as a path parameter. The V2 order response format includes all legs of the order in the `legs` list field. If the order is single legged, `legs` will be a list of one leg. This endpoint is always realtime and does not rely on cached data. This endpoint only returns orders placed through SnapTrade. In other words, orders placed outside of the SnapTrade network are not returned by this endpoint.
|
|
8563
8626
|
* @summary Get account order detail (V2)
|
|
@@ -8730,7 +8793,7 @@ type ExperimentalEndpointsApiAddSubscriptionRequest = {
|
|
|
8730
8793
|
* @export
|
|
8731
8794
|
* @interface ExperimentalEndpointsApiCancelSubscriptionRequest
|
|
8732
8795
|
*/
|
|
8733
|
-
type ExperimentalEndpointsApiCancelSubscriptionRequest = {} &
|
|
8796
|
+
type ExperimentalEndpointsApiCancelSubscriptionRequest = {} & TradeDetectionCancelSubscriptionRequest;
|
|
8734
8797
|
/**
|
|
8735
8798
|
* Request parameters for getUserAccountOrderDetailV2 operation in ExperimentalEndpointsApi.
|
|
8736
8799
|
* @export
|
|
@@ -10799,4 +10862,4 @@ declare class SnaptradeError extends Error {
|
|
|
10799
10862
|
declare function readableStreamToString(stream: ReadableStream): Promise<string>;
|
|
10800
10863
|
declare function parseIfJson(input: unknown): object | unknown;
|
|
10801
10864
|
//#endregion
|
|
10802
|
-
export { Account, AccountBalance, AccountBalanceTotal, AccountHoldings, AccountHoldingsAccount, AccountInformationApi, AccountInformationApiAxiosParamCreator, AccountInformationApiFactory, AccountInformationApiFp, AccountInformationApiGenerated, AccountInformationApiGetAccountActivitiesRequest, AccountInformationApiGetAccountBalanceHistoryRequest, AccountInformationApiGetAllAccountPositionsRequest, AccountInformationApiGetAllUserHoldingsRequest, AccountInformationApiGetUserAccountBalanceRequest, AccountInformationApiGetUserAccountDetailsRequest, AccountInformationApiGetUserAccountOrderDetailRequest, AccountInformationApiGetUserAccountOrdersRequest, AccountInformationApiGetUserAccountPositionsRequest, AccountInformationApiGetUserAccountRecentOrdersRequest, AccountInformationApiGetUserAccountReturnRatesRequest, AccountInformationApiGetUserHoldingsRequest, AccountInformationApiListUserAccountsRequest, AccountInformationApiUpdateUserAccountRequest, AccountInformationGetUserAccountOrderDetailRequest, AccountOrderRecord, AccountOrderRecordChildBrokerageOrderIds, AccountOrderRecordLeg, AccountOrderRecordLegInstrument, AccountOrderRecordOptionSymbol, AccountOrderRecordQuoteCurrency, AccountOrderRecordQuoteUniversalSymbol, AccountOrderRecordStatus, AccountOrderRecordStatusV2, AccountOrderRecordTrailingStop, AccountOrderRecordUniversalSymbol, AccountOrderRecordV2, AccountOrdersV2Response, AccountPosition, AccountSimple, AccountSyncStatus, AccountUniversalActivity, AccountUniversalActivityCurrency, AccountUniversalActivityOptionSymbol, AccountUniversalActivitySymbol, AccountValueHistoryItem, AccountValueHistoryResponse, ActionStrict, ActionStrictWithOptions, AdrInstrument, AllAccountPositionsResponse, ApiStatusApi, ApiStatusApiAxiosParamCreator, ApiStatusApiFactory, ApiStatusApiFp, ApiStatusApiGenerated, AuthenticationApi, AuthenticationApiAxiosParamCreator, AuthenticationApiDeleteSnapTradeUserRequest, AuthenticationApiFactory, AuthenticationApiFp, AuthenticationApiGenerated, AuthenticationApiLoginSnapTradeUserRequest, AuthenticationApiRegisterSnapTradeUserRequest, AuthenticationApiResetSnapTradeUserSecretRequest, AuthenticationLoginSnapTradeUser200Response, Balance, BalanceCurrency, Brokerage, BrokerageAuthorization, BrokerageAuthorizationDisabledConfirmation, BrokerageAuthorizationRefreshConfirmation, BrokerageAuthorizationTransactionsSyncConfirmation, BrokerageAuthorizationTypeReadOnly, BrokerageAuthorizationTypeReadOnlyBrokerage, BrokerageInstrument, BrokerageInstrumentsResponse, BrokerageType, CancelOrderResponse, CefInstrument, ChildBrokerageOrderIDs, ComplexOrderLeg, ComplexOrderResponse, Configuration, ConfigurationParameters, ConnectionsApi, ConnectionsApiAxiosParamCreator, ConnectionsApiDeleteConnectionRequest, ConnectionsApiDetailBrokerageAuthorizationRequest, ConnectionsApiDisableBrokerageAuthorizationRequest, ConnectionsApiFactory, ConnectionsApiFp, ConnectionsApiGenerated, ConnectionsApiListBrokerageAuthorizationAccountsRequest, ConnectionsApiListBrokerageAuthorizationsRequest, ConnectionsApiRefreshBrokerageAuthorizationRequest, ConnectionsApiRemoveBrokerageAuthorizationRequest, ConnectionsApiReturnRatesRequest, ConnectionsApiSessionEventsRequest, ConnectionsApiSyncBrokerageAuthorizationTransactionsRequest, ConnectionsSessionEvents200ResponseInner, CryptoInstrument, CryptoOrderForm, CryptoOrderPreview, CryptoOrderPreviewEstimatedFee, CryptoTradingInstrument, CryptocurrencyPair, CryptocurrencyPairQuote, Currency, DeleteConnectionConfirmation, DeleteUserResponse, DividendAtDate, EncryptedResponse, EncryptedResponseEncryptedMessageData, EtfInstrument, Exchange, ExchangeRatePairs, ExperimentalEndpointsApi, ExperimentalEndpointsApiAddSubscriptionRequest, ExperimentalEndpointsApiAxiosParamCreator, ExperimentalEndpointsApiCancelSubscriptionRequest, ExperimentalEndpointsApiFactory, ExperimentalEndpointsApiFp, ExperimentalEndpointsApiGenerated, ExperimentalEndpointsApiGetUserAccountOrderDetailV2Request, ExperimentalEndpointsApiGetUserAccountOrdersV2Request, ExperimentalEndpointsApiGetUserAccountRecentOrdersV2Request, FigiInstrument, FutureInstrument, HoldingsStatus, Instrument, LoginRedirectURI, ManualTrade, ManualTradeAndImpact, ManualTradeBalance, ManualTradeForm, ManualTradeFormBracket, ManualTradeFormComplex, ManualTradeFormNotionalValue, ManualTradeFormWithOptions, ManualTradeImpact, ManualTradeReplaceForm, ManualTradeSymbol, MlegActionStrict, MlegInstrumentType, MlegLeg, MlegOrderResponse, MlegOrderTypeStrict, MlegPriceEffectStrict, MlegTradeForm, MlegTradingInstrument, Model400FailedRequestResponse, Model401FailedRequestResponse, Model402BrokerageAuthAlreadyDisabledException, Model402BrokerageAuthDisabledResponse, Model403FailedRequestResponse, Model403FeatureNotEnabledResponse, Model404FailedRequestResponse, Model425FailedRequestResponse, Model500UnexpectedExceptionResponse, MonthlyDividends, MutualFundInstrument, NetContributions, NetDividend, NotionalValue, OptionBrokerageSymbol, OptionChainInner, OptionChainInnerChainPerRootInner, OptionChainInnerChainPerRootInnerChainPerStrikePriceInner, OptionImpact, OptionInstrument, OptionLeg, OptionQuote, OptionQuoteGreeks, OptionStrategy, OptionStrategyLegsInner, OptionsApi, OptionsApiAxiosParamCreator, OptionsApiFactory, OptionsApiFp, OptionsApiGenerated, OptionsApiListOptionHoldingsRequest, OptionsPosition, OptionsPositionCurrency, OptionsSymbol, OrderTypeStrict, OrderUpdatedResponse, OrderUpdatedResponseOrder, OtherInstrument, PaginatedUniversalActivity, PaginationDetails, PartnerData, PastValue, PerformanceCustom, Position, PositionCurrency, PositionSymbol, RateOfReturnObject, RateOfReturnResponse, RecentOrdersResponse, ReferenceDataApi, ReferenceDataApiAxiosParamCreator, ReferenceDataApiFactory, ReferenceDataApiFp, ReferenceDataApiGenerated, ReferenceDataApiGetCurrencyExchangeRatePairRequest, ReferenceDataApiGetSymbolsByTickerRequest, ReferenceDataApiGetSymbolsRequest, ReferenceDataApiListAllBrokerageAuthorizationTypeRequest, ReferenceDataApiListAllBrokerageInstrumentsRequest, ReferenceDataApiSymbolSearchUserAccountRequest, SecurityType, SessionEvent, SimpleOrderForm, SnapTradeHoldingsAccount, SnapTradeHoldingsTotalValue, SnapTradeLoginUserRequestBody, SnapTradeRegisterUserRequestBody, Snaptrade, SnaptradeError, Status, StockInstrument, StockInstrumentFigiInstrument, StopLoss, StrategyOrderRecord, StrategyQuotes, StrategyQuotesGreek, SubPeriodReturnRate, Symbol$1 as Symbol, SymbolCurrency, SymbolExchange, SymbolQuery, SymbolsQuotesInner, TakeProfit, TaxLot, TimeInForceStrict, TradeDetectionAddSubscriptionRequest, TradeDetectionCancelSubscriptionResponse, TradeDetectionSubscription, TradingApi, TradingApiAxiosParamCreator, TradingApiCancelOrderRequest, TradingApiCancelUserAccountOrderRequest, TradingApiFactory, TradingApiFp, TradingApiGenerated, TradingApiGetCryptocurrencyPairQuoteRequest, TradingApiGetOptionImpactRequest, TradingApiGetOrderImpactRequest, TradingApiGetUserAccountOptionQuotesRequest, TradingApiGetUserAccountQuotesRequest, TradingApiPlaceBracketOrderRequest, TradingApiPlaceComplexOrderRequest, TradingApiPlaceCryptoOrderRequest, TradingApiPlaceForceOrderRequest, TradingApiPlaceMlegOrderRequest, TradingApiPlaceOrderRequest, TradingApiPreviewCryptoOrderRequest, TradingApiReplaceOrderRequest, TradingApiSearchCryptocurrencyPairInstrumentsRequest, TradingInstrument, TradingSearchCryptocurrencyPairInstruments200Response, TradingSession, TrailingStop, TransactionsAndReportingApi, TransactionsAndReportingApiAxiosParamCreator, TransactionsAndReportingApiFactory, TransactionsAndReportingApiFp, TransactionsAndReportingApiGenerated, TransactionsAndReportingApiGetActivitiesRequest, TransactionsAndReportingApiGetReportingCustomRangeRequest, TransactionsStatus, USExchange, UnderlyingOptionInstrument, UnderlyingSymbol, UnderlyingSymbolExchange, UnderlyingSymbolType, UniversalActivity, UniversalSymbol, UserIDandSecret, ValidatedTradeBody, parseIfJson, readableStreamToString };
|
|
10865
|
+
export { Account, AccountBalance, AccountBalanceTotal, AccountHoldings, AccountHoldingsAccount, AccountInformationApi, AccountInformationApiAxiosParamCreator, AccountInformationApiFactory, AccountInformationApiFp, AccountInformationApiGenerated, AccountInformationApiGetAccountActivitiesRequest, AccountInformationApiGetAccountBalanceHistoryRequest, AccountInformationApiGetAllAccountPositionsRequest, AccountInformationApiGetAllUserHoldingsRequest, AccountInformationApiGetUserAccountBalanceRequest, AccountInformationApiGetUserAccountDetailsRequest, AccountInformationApiGetUserAccountOrderDetailRequest, AccountInformationApiGetUserAccountOrdersRequest, AccountInformationApiGetUserAccountPositionsRequest, AccountInformationApiGetUserAccountRecentOrdersRequest, AccountInformationApiGetUserAccountReturnRatesRequest, AccountInformationApiGetUserHoldingsRequest, AccountInformationApiListUserAccountsRequest, AccountInformationApiUpdateUserAccountRequest, AccountInformationGetUserAccountOrderDetailRequest, AccountOrderRecord, AccountOrderRecordChildBrokerageOrderIds, AccountOrderRecordLeg, AccountOrderRecordLegInstrument, AccountOrderRecordOptionSymbol, AccountOrderRecordQuoteCurrency, AccountOrderRecordQuoteUniversalSymbol, AccountOrderRecordStatus, AccountOrderRecordStatusV2, AccountOrderRecordTrailingStop, AccountOrderRecordUniversalSymbol, AccountOrderRecordV2, AccountOrdersV2Response, AccountPosition, AccountSimple, AccountSyncStatus, AccountUniversalActivity, AccountUniversalActivityCurrency, AccountUniversalActivityOptionSymbol, AccountUniversalActivitySymbol, AccountValueHistoryItem, AccountValueHistoryResponse, ActionStrict, ActionStrictWithOptions, AdrInstrument, AllAccountPositionsResponse, AllAccountPositionsResponseDataFreshness, ApiStatusApi, ApiStatusApiAxiosParamCreator, ApiStatusApiFactory, ApiStatusApiFp, ApiStatusApiGenerated, AuthenticationApi, AuthenticationApiAxiosParamCreator, AuthenticationApiDeleteSnapTradeUserRequest, AuthenticationApiFactory, AuthenticationApiFp, AuthenticationApiGenerated, AuthenticationApiLoginSnapTradeUserRequest, AuthenticationApiRegisterSnapTradeUserRequest, AuthenticationApiResetSnapTradeUserSecretRequest, AuthenticationLoginSnapTradeUser200Response, Balance, BalanceCurrency, Brokerage, BrokerageAuthorization, BrokerageAuthorizationDisabledConfirmation, BrokerageAuthorizationRefreshConfirmation, BrokerageAuthorizationTransactionsSyncConfirmation, BrokerageAuthorizationTypeReadOnly, BrokerageAuthorizationTypeReadOnlyBrokerage, BrokerageInstrument, BrokerageInstrumentsResponse, BrokerageType, CancelOrderResponse, CefInstrument, ChildBrokerageOrderIDs, ComplexOrderLeg, ComplexOrderResponse, Configuration, ConfigurationParameters, ConnectionsApi, ConnectionsApiAxiosParamCreator, ConnectionsApiDeleteConnectionRequest, ConnectionsApiDetailBrokerageAuthorizationRequest, ConnectionsApiDisableBrokerageAuthorizationRequest, ConnectionsApiFactory, ConnectionsApiFp, ConnectionsApiGenerated, ConnectionsApiListBrokerageAuthorizationAccountsRequest, ConnectionsApiListBrokerageAuthorizationsRequest, ConnectionsApiRefreshBrokerageAuthorizationRequest, ConnectionsApiRemoveBrokerageAuthorizationRequest, ConnectionsApiReturnRatesRequest, ConnectionsApiSessionEventsRequest, ConnectionsApiSyncBrokerageAuthorizationTransactionsRequest, ConnectionsSessionEvents200ResponseInner, CryptoInstrument, CryptoOrderForm, CryptoOrderPreview, CryptoOrderPreviewEstimatedFee, CryptoTradingInstrument, CryptocurrencyPair, CryptocurrencyPairQuote, Currency, DeleteConnectionConfirmation, DeleteUserResponse, DividendAtDate, EncryptedResponse, EncryptedResponseEncryptedMessageData, EtfInstrument, Exchange, ExchangeRatePairs, ExperimentalEndpointsApi, ExperimentalEndpointsApiAddSubscriptionRequest, ExperimentalEndpointsApiAxiosParamCreator, ExperimentalEndpointsApiCancelSubscriptionRequest, ExperimentalEndpointsApiFactory, ExperimentalEndpointsApiFp, ExperimentalEndpointsApiGenerated, ExperimentalEndpointsApiGetUserAccountOrderDetailV2Request, ExperimentalEndpointsApiGetUserAccountOrdersV2Request, ExperimentalEndpointsApiGetUserAccountRecentOrdersV2Request, FigiInstrument, FutureInstrument, HoldingsStatus, Instrument, LoginRedirectURI, ManualTrade, ManualTradeAndImpact, ManualTradeBalance, ManualTradeForm, ManualTradeFormBracket, ManualTradeFormComplex, ManualTradeFormNotionalValue, ManualTradeFormWithOptions, ManualTradeImpact, ManualTradePlaceTimeInForceStrict, ManualTradeReplaceForm, ManualTradeSymbol, MlegActionStrict, MlegInstrumentType, MlegLeg, MlegOrderResponse, MlegOrderTypeStrict, MlegPriceEffectStrict, MlegTradeForm, MlegTradingInstrument, Model400FailedRequestResponse, Model401FailedRequestResponse, Model402BrokerageAuthAlreadyDisabledException, Model402BrokerageAuthDisabledResponse, Model403FailedRequestResponse, Model403FeatureNotEnabledResponse, Model404FailedRequestResponse, Model425FailedRequestResponse, Model500UnexpectedExceptionResponse, MonthlyDividends, MutualFundInstrument, NetContributions, NetDividend, NotionalValue, OptionBrokerageSymbol, OptionChainInner, OptionChainInnerChainPerRootInner, OptionChainInnerChainPerRootInnerChainPerStrikePriceInner, OptionImpact, OptionInstrument, OptionLeg, OptionQuote, OptionQuoteGreeks, OptionStrategy, OptionStrategyLegsInner, OptionsApi, OptionsApiAxiosParamCreator, OptionsApiFactory, OptionsApiFp, OptionsApiGenerated, OptionsApiListOptionHoldingsRequest, OptionsPosition, OptionsPositionCurrency, OptionsSymbol, OrderTypeStrict, OrderUpdatedResponse, OrderUpdatedResponseOrder, OtherInstrument, PaginatedUniversalActivity, PaginationDetails, PartnerData, PastValue, PerformanceCustom, Position, PositionCurrency, PositionSymbol, RateOfReturnObject, RateOfReturnResponse, RecentOrdersResponse, ReferenceDataApi, ReferenceDataApiAxiosParamCreator, ReferenceDataApiFactory, ReferenceDataApiFp, ReferenceDataApiGenerated, ReferenceDataApiGetCurrencyExchangeRatePairRequest, ReferenceDataApiGetSymbolsByTickerRequest, ReferenceDataApiGetSymbolsRequest, ReferenceDataApiListAllBrokerageAuthorizationTypeRequest, ReferenceDataApiListAllBrokerageInstrumentsRequest, ReferenceDataApiSymbolSearchUserAccountRequest, SecurityType, SessionEvent, SimpleOrderForm, SnapTradeHoldingsAccount, SnapTradeHoldingsTotalValue, SnapTradeLoginUserRequestBody, SnapTradeRegisterUserRequestBody, Snaptrade, SnaptradeError, Status, StockInstrument, StockInstrumentFigiInstrument, StopLoss, StrategyOrderRecord, StrategyQuotes, StrategyQuotesGreek, SubPeriodReturnRate, Symbol$1 as Symbol, SymbolCurrency, SymbolExchange, SymbolQuery, SymbolsQuotesInner, TakeProfit, TaxLot, TimeInForceStrict, TradeDetectionAddSubscriptionRequest, TradeDetectionCancelSubscriptionRequest, TradeDetectionCancelSubscriptionResponse, TradeDetectionSubscription, TradingApi, TradingApiAxiosParamCreator, TradingApiCancelOrderRequest, TradingApiCancelUserAccountOrderRequest, TradingApiFactory, TradingApiFp, TradingApiGenerated, TradingApiGetCryptocurrencyPairQuoteRequest, TradingApiGetOptionImpactRequest, TradingApiGetOrderImpactRequest, TradingApiGetUserAccountOptionQuotesRequest, TradingApiGetUserAccountQuotesRequest, TradingApiPlaceBracketOrderRequest, TradingApiPlaceComplexOrderRequest, TradingApiPlaceCryptoOrderRequest, TradingApiPlaceForceOrderRequest, TradingApiPlaceMlegOrderRequest, TradingApiPlaceOrderRequest, TradingApiPreviewCryptoOrderRequest, TradingApiReplaceOrderRequest, TradingApiSearchCryptocurrencyPairInstrumentsRequest, TradingInstrument, TradingSearchCryptocurrencyPairInstruments200Response, TradingSession, TrailingStop, TransactionsAndReportingApi, TransactionsAndReportingApiAxiosParamCreator, TransactionsAndReportingApiFactory, TransactionsAndReportingApiFp, TransactionsAndReportingApiGenerated, TransactionsAndReportingApiGetActivitiesRequest, TransactionsAndReportingApiGetReportingCustomRangeRequest, TransactionsStatus, USExchange, UnderlyingOptionInstrument, UnderlyingSymbol, UnderlyingSymbolExchange, UnderlyingSymbolType, UniversalActivity, UniversalSymbol, UserIDandSecret, ValidatedTradeBody, parseIfJson, readableStreamToString };
|
package/dist/index.mjs
CHANGED
|
@@ -3340,12 +3340,12 @@ const ExperimentalEndpointsApiAxiosParamCreator = function(configuration) {
|
|
|
3340
3340
|
/**
|
|
3341
3341
|
* Cancels a Trade Detection subscription for a connected brokerage account. This endpoint requires partner signature authentication only and does not require `userId` or `userSecret`.
|
|
3342
3342
|
* @summary Cancel a Trade Detection subscription
|
|
3343
|
-
* @param {
|
|
3343
|
+
* @param {TradeDetectionCancelSubscriptionRequest} tradeDetectionCancelSubscriptionRequest
|
|
3344
3344
|
* @param {*} [options] Override http request option.
|
|
3345
3345
|
* @throws {RequiredError}
|
|
3346
3346
|
*/
|
|
3347
|
-
cancelSubscription: async (
|
|
3348
|
-
assertParamExists("cancelSubscription", "
|
|
3347
|
+
cancelSubscription: async (tradeDetectionCancelSubscriptionRequest, options = {}) => {
|
|
3348
|
+
assertParamExists("cancelSubscription", "tradeDetectionCancelSubscriptionRequest", tradeDetectionCancelSubscriptionRequest);
|
|
3349
3349
|
const localVarPath = `/snapTrade/tradeDetection/subscriptions/cancel`;
|
|
3350
3350
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
3351
3351
|
let baseOptions;
|
|
@@ -3383,7 +3383,7 @@ const ExperimentalEndpointsApiAxiosParamCreator = function(configuration) {
|
|
|
3383
3383
|
...options.headers
|
|
3384
3384
|
};
|
|
3385
3385
|
requestBeforeHook({
|
|
3386
|
-
requestBody:
|
|
3386
|
+
requestBody: tradeDetectionCancelSubscriptionRequest,
|
|
3387
3387
|
queryParameters: localVarQueryParameter,
|
|
3388
3388
|
requestConfig: localVarRequestOptions,
|
|
3389
3389
|
path: localVarPath,
|
|
@@ -3391,7 +3391,7 @@ const ExperimentalEndpointsApiAxiosParamCreator = function(configuration) {
|
|
|
3391
3391
|
pathTemplate: "/snapTrade/tradeDetection/subscriptions/cancel",
|
|
3392
3392
|
httpMethod: "POST"
|
|
3393
3393
|
});
|
|
3394
|
-
localVarRequestOptions.data = serializeDataIfNeeded(
|
|
3394
|
+
localVarRequestOptions.data = serializeDataIfNeeded(tradeDetectionCancelSubscriptionRequest, localVarRequestOptions, configuration);
|
|
3395
3395
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
3396
3396
|
return {
|
|
3397
3397
|
url: toPathString(localVarUrlObj),
|
|
@@ -3671,7 +3671,10 @@ const ExperimentalEndpointsApiFp = function(configuration) {
|
|
|
3671
3671
|
* @throws {RequiredError}
|
|
3672
3672
|
*/
|
|
3673
3673
|
async addSubscription(requestParameters, options) {
|
|
3674
|
-
const tradeDetectionAddSubscriptionRequest = {
|
|
3674
|
+
const tradeDetectionAddSubscriptionRequest = {
|
|
3675
|
+
account_id: requestParameters.account_id,
|
|
3676
|
+
check_interval_seconds: requestParameters.check_interval_seconds
|
|
3677
|
+
};
|
|
3675
3678
|
return createRequestFunction(await localVarAxiosParamCreator.addSubscription(requestParameters.userId, requestParameters.userSecret, tradeDetectionAddSubscriptionRequest, options), globalAxios, BASE_PATH, configuration);
|
|
3676
3679
|
},
|
|
3677
3680
|
/**
|
|
@@ -3682,8 +3685,8 @@ const ExperimentalEndpointsApiFp = function(configuration) {
|
|
|
3682
3685
|
* @throws {RequiredError}
|
|
3683
3686
|
*/
|
|
3684
3687
|
async cancelSubscription(requestParameters, options) {
|
|
3685
|
-
const
|
|
3686
|
-
return createRequestFunction(await localVarAxiosParamCreator.cancelSubscription(
|
|
3688
|
+
const tradeDetectionCancelSubscriptionRequest = { account_id: requestParameters.account_id };
|
|
3689
|
+
return createRequestFunction(await localVarAxiosParamCreator.cancelSubscription(tradeDetectionCancelSubscriptionRequest, options), globalAxios, BASE_PATH, configuration);
|
|
3687
3690
|
},
|
|
3688
3691
|
/**
|
|
3689
3692
|
* Returns the detail of a single order using the brokerage order ID provided as a path parameter. The V2 order response format includes all legs of the order in the `legs` list field. If the order is single legged, `legs` will be a list of one leg. This endpoint is always realtime and does not rely on cached data. This endpoint only returns orders placed through SnapTrade. In other words, orders placed outside of the SnapTrade network are not returned by this endpoint.
|
|
@@ -6374,10 +6377,12 @@ const TradingApiFp = function(configuration) {
|
|
|
6374
6377
|
order_type: requestParameters.order_type,
|
|
6375
6378
|
time_in_force: requestParameters.time_in_force,
|
|
6376
6379
|
trading_session: requestParameters.trading_session,
|
|
6380
|
+
expiry_date: requestParameters.expiry_date,
|
|
6377
6381
|
price: requestParameters.price,
|
|
6378
6382
|
stop: requestParameters.stop,
|
|
6379
6383
|
units: requestParameters.units,
|
|
6380
|
-
notional_value: requestParameters.notional_value
|
|
6384
|
+
notional_value: requestParameters.notional_value,
|
|
6385
|
+
client_order_id: requestParameters.client_order_id
|
|
6381
6386
|
};
|
|
6382
6387
|
return createRequestFunction(await localVarAxiosParamCreator.placeForceOrder(requestParameters.userId, requestParameters.userSecret, manualTradeFormWithOptions, options), globalAxios, BASE_PATH, configuration);
|
|
6383
6388
|
},
|
|
@@ -7095,7 +7100,7 @@ var Configuration = class {
|
|
|
7095
7100
|
this.accessToken = param.accessToken;
|
|
7096
7101
|
this.basePath = param.basePath;
|
|
7097
7102
|
this.baseOptions = param.baseOptions ?? {};
|
|
7098
|
-
this.userAgent = param.userAgent === void 0 ? "Konfig/10.0.
|
|
7103
|
+
this.userAgent = param.userAgent === void 0 ? "Konfig/10.0.9/typescript" : param.userAgent;
|
|
7099
7104
|
this.formDataCtor = param.formDataCtor;
|
|
7100
7105
|
}
|
|
7101
7106
|
/**
|