snaptrade-typescript-sdk 10.0.3 → 10.0.5
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 +3 -5
- package/dist/index.browser.mjs +10332 -0
- package/dist/index.cjs +9 -13
- package/dist/index.d.cts +10802 -1
- package/dist/index.d.mts +8 -12
- package/dist/index.d.ts +10802 -1
- package/dist/index.mjs +9 -13
- package/package.json +6 -1
package/dist/index.mjs
CHANGED
|
@@ -1063,12 +1063,11 @@ const AccountInformationApiAxiosParamCreator = function(configuration) {
|
|
|
1063
1063
|
};
|
|
1064
1064
|
},
|
|
1065
1065
|
/**
|
|
1066
|
-
*
|
|
1066
|
+
* Returns all brokerage accounts across all connections known to SnapTrade for the authenticated user. This endpoint returns Daily data regardless of the customer\'s plan. Daily data is cached and refreshed once a day, which makes this endpoint fast and well-suited to listing accounts across all of a user\'s connections in a single call. Exact refresh timing may vary by brokerage. To get real-time data on Pay as you Go / Real-time, use the [list accounts for a connection endpoint](/reference/Connections/Connections_listBrokerageAuthorizationAccounts). Customers on Pay as you Go / Daily can force a refresh with the [manual refresh endpoint](/reference/Connections/Connections_refreshBrokerageAuthorization).
|
|
1067
1067
|
* @summary List accounts
|
|
1068
1068
|
* @param {string} userId
|
|
1069
1069
|
* @param {string} userSecret
|
|
1070
1070
|
* @param {*} [options] Override http request option.
|
|
1071
|
-
* @deprecated
|
|
1072
1071
|
* @throws {RequiredError}
|
|
1073
1072
|
*/
|
|
1074
1073
|
listUserAccounts: async (userId, userSecret, options = {}) => {
|
|
@@ -1323,11 +1322,10 @@ const AccountInformationApiFp = function(configuration) {
|
|
|
1323
1322
|
return createRequestFunction(await localVarAxiosParamCreator.getUserHoldings(requestParameters.accountId, requestParameters.userId, requestParameters.userSecret, options), globalAxios, BASE_PATH, configuration);
|
|
1324
1323
|
},
|
|
1325
1324
|
/**
|
|
1326
|
-
*
|
|
1325
|
+
* Returns all brokerage accounts across all connections known to SnapTrade for the authenticated user. This endpoint returns Daily data regardless of the customer\'s plan. Daily data is cached and refreshed once a day, which makes this endpoint fast and well-suited to listing accounts across all of a user\'s connections in a single call. Exact refresh timing may vary by brokerage. To get real-time data on Pay as you Go / Real-time, use the [list accounts for a connection endpoint](/reference/Connections/Connections_listBrokerageAuthorizationAccounts). Customers on Pay as you Go / Daily can force a refresh with the [manual refresh endpoint](/reference/Connections/Connections_refreshBrokerageAuthorization).
|
|
1327
1326
|
* @summary List accounts
|
|
1328
1327
|
* @param {AccountInformationApiListUserAccountsRequest} requestParameters Request parameters.
|
|
1329
1328
|
* @param {*} [options] Override http request option.
|
|
1330
|
-
* @deprecated
|
|
1331
1329
|
* @throws {RequiredError}
|
|
1332
1330
|
*/
|
|
1333
1331
|
async listUserAccounts(requestParameters, options) {
|
|
@@ -1476,11 +1474,10 @@ const AccountInformationApiFactory = function(configuration, basePath, axios) {
|
|
|
1476
1474
|
return localVarFp.getUserHoldings(requestParameters, options).then((request) => request(axios, basePath));
|
|
1477
1475
|
},
|
|
1478
1476
|
/**
|
|
1479
|
-
*
|
|
1477
|
+
* Returns all brokerage accounts across all connections known to SnapTrade for the authenticated user. This endpoint returns Daily data regardless of the customer\'s plan. Daily data is cached and refreshed once a day, which makes this endpoint fast and well-suited to listing accounts across all of a user\'s connections in a single call. Exact refresh timing may vary by brokerage. To get real-time data on Pay as you Go / Real-time, use the [list accounts for a connection endpoint](/reference/Connections/Connections_listBrokerageAuthorizationAccounts). Customers on Pay as you Go / Daily can force a refresh with the [manual refresh endpoint](/reference/Connections/Connections_refreshBrokerageAuthorization).
|
|
1480
1478
|
* @summary List accounts
|
|
1481
1479
|
* @param {AccountInformationApiListUserAccountsRequest} requestParameters Request parameters.
|
|
1482
1480
|
* @param {*} [options] Override http request option.
|
|
1483
|
-
* @deprecated
|
|
1484
1481
|
* @throws {RequiredError}
|
|
1485
1482
|
*/
|
|
1486
1483
|
listUserAccounts(requestParameters, options) {
|
|
@@ -1641,11 +1638,10 @@ var AccountInformationApiGenerated = class extends BaseAPI {
|
|
|
1641
1638
|
return AccountInformationApiFp(this.configuration).getUserHoldings(requestParameters, options).then((request) => request(this.axios, this.basePath));
|
|
1642
1639
|
}
|
|
1643
1640
|
/**
|
|
1644
|
-
*
|
|
1641
|
+
* Returns all brokerage accounts across all connections known to SnapTrade for the authenticated user. This endpoint returns Daily data regardless of the customer\'s plan. Daily data is cached and refreshed once a day, which makes this endpoint fast and well-suited to listing accounts across all of a user\'s connections in a single call. Exact refresh timing may vary by brokerage. To get real-time data on Pay as you Go / Real-time, use the [list accounts for a connection endpoint](/reference/Connections/Connections_listBrokerageAuthorizationAccounts). Customers on Pay as you Go / Daily can force a refresh with the [manual refresh endpoint](/reference/Connections/Connections_refreshBrokerageAuthorization).
|
|
1645
1642
|
* @summary List accounts
|
|
1646
1643
|
* @param {AccountInformationApiListUserAccountsRequest} requestParameters Request parameters.
|
|
1647
1644
|
* @param {*} [options] Override http request option.
|
|
1648
|
-
* @deprecated
|
|
1649
1645
|
* @throws {RequiredError}
|
|
1650
1646
|
* @memberof AccountInformationApiGenerated
|
|
1651
1647
|
*/
|
|
@@ -5656,7 +5652,7 @@ const TradingApiAxiosParamCreator = function(configuration) {
|
|
|
5656
5652
|
};
|
|
5657
5653
|
},
|
|
5658
5654
|
/**
|
|
5659
|
-
* Places a complex conditional order (OCO, OTO, or OTOCO). Disabled by default — contact support to enable. Only supported on certain brokerages. - **OCO** (One Cancels the Other): Two peer orders; when one fills the other is cancelled. - **OTO** (One Triggers the Other): A trigger order that, when filled, activates a conditional order. - **OTOCO** (One Triggers a One Cancels the Other): A trigger order that, when filled, activates an OCO pair of two peer orders.
|
|
5655
|
+
* Places a complex conditional order (OCO, OTO, or OTOCO). Disabled by default — contact support to enable. Only supported on certain brokerages. Please refer to the [brokerage trading support page](https://support.snaptrade.com/brokerages) for details on which brokerages support complex orders and which types they support. - **OCO** (One Cancels the Other): Two peer orders; when one fills the other is cancelled. - **OTO** (One Triggers the Other): A trigger order that, when filled, activates a conditional order. - **OTOCO** (One Triggers a One Cancels the Other): A trigger order that, when filled, activates an OCO pair of two peer orders.
|
|
5660
5656
|
* @summary Place complex order
|
|
5661
5657
|
* @param {string} accountId The ID of the account to execute the trade on.
|
|
5662
5658
|
* @param {string} userId
|
|
@@ -6327,7 +6323,7 @@ const TradingApiFp = function(configuration) {
|
|
|
6327
6323
|
return createRequestFunction(await localVarAxiosParamCreator.placeBracketOrder(requestParameters.accountId, requestParameters.userId, requestParameters.userSecret, manualTradeFormBracket, options), globalAxios, BASE_PATH, configuration);
|
|
6328
6324
|
},
|
|
6329
6325
|
/**
|
|
6330
|
-
* Places a complex conditional order (OCO, OTO, or OTOCO). Disabled by default — contact support to enable. Only supported on certain brokerages. - **OCO** (One Cancels the Other): Two peer orders; when one fills the other is cancelled. - **OTO** (One Triggers the Other): A trigger order that, when filled, activates a conditional order. - **OTOCO** (One Triggers a One Cancels the Other): A trigger order that, when filled, activates an OCO pair of two peer orders.
|
|
6326
|
+
* Places a complex conditional order (OCO, OTO, or OTOCO). Disabled by default — contact support to enable. Only supported on certain brokerages. Please refer to the [brokerage trading support page](https://support.snaptrade.com/brokerages) for details on which brokerages support complex orders and which types they support. - **OCO** (One Cancels the Other): Two peer orders; when one fills the other is cancelled. - **OTO** (One Triggers the Other): A trigger order that, when filled, activates a conditional order. - **OTOCO** (One Triggers a One Cancels the Other): A trigger order that, when filled, activates an OCO pair of two peer orders.
|
|
6331
6327
|
* @summary Place complex order
|
|
6332
6328
|
* @param {TradingApiPlaceComplexOrderRequest} requestParameters Request parameters.
|
|
6333
6329
|
* @param {*} [options] Override http request option.
|
|
@@ -6557,7 +6553,7 @@ const TradingApiFactory = function(configuration, basePath, axios) {
|
|
|
6557
6553
|
return localVarFp.placeBracketOrder(requestParameters, options).then((request) => request(axios, basePath));
|
|
6558
6554
|
},
|
|
6559
6555
|
/**
|
|
6560
|
-
* Places a complex conditional order (OCO, OTO, or OTOCO). Disabled by default — contact support to enable. Only supported on certain brokerages. - **OCO** (One Cancels the Other): Two peer orders; when one fills the other is cancelled. - **OTO** (One Triggers the Other): A trigger order that, when filled, activates a conditional order. - **OTOCO** (One Triggers a One Cancels the Other): A trigger order that, when filled, activates an OCO pair of two peer orders.
|
|
6556
|
+
* Places a complex conditional order (OCO, OTO, or OTOCO). Disabled by default — contact support to enable. Only supported on certain brokerages. Please refer to the [brokerage trading support page](https://support.snaptrade.com/brokerages) for details on which brokerages support complex orders and which types they support. - **OCO** (One Cancels the Other): Two peer orders; when one fills the other is cancelled. - **OTO** (One Triggers the Other): A trigger order that, when filled, activates a conditional order. - **OTOCO** (One Triggers a One Cancels the Other): A trigger order that, when filled, activates an OCO pair of two peer orders.
|
|
6561
6557
|
* @summary Place complex order
|
|
6562
6558
|
* @param {TradingApiPlaceComplexOrderRequest} requestParameters Request parameters.
|
|
6563
6559
|
* @param {*} [options] Override http request option.
|
|
@@ -6736,7 +6732,7 @@ var TradingApiGenerated = class extends BaseAPI {
|
|
|
6736
6732
|
return TradingApiFp(this.configuration).placeBracketOrder(requestParameters, options).then((request) => request(this.axios, this.basePath));
|
|
6737
6733
|
}
|
|
6738
6734
|
/**
|
|
6739
|
-
* Places a complex conditional order (OCO, OTO, or OTOCO). Disabled by default — contact support to enable. Only supported on certain brokerages. - **OCO** (One Cancels the Other): Two peer orders; when one fills the other is cancelled. - **OTO** (One Triggers the Other): A trigger order that, when filled, activates a conditional order. - **OTOCO** (One Triggers a One Cancels the Other): A trigger order that, when filled, activates an OCO pair of two peer orders.
|
|
6735
|
+
* Places a complex conditional order (OCO, OTO, or OTOCO). Disabled by default — contact support to enable. Only supported on certain brokerages. Please refer to the [brokerage trading support page](https://support.snaptrade.com/brokerages) for details on which brokerages support complex orders and which types they support. - **OCO** (One Cancels the Other): Two peer orders; when one fills the other is cancelled. - **OTO** (One Triggers the Other): A trigger order that, when filled, activates a conditional order. - **OTOCO** (One Triggers a One Cancels the Other): A trigger order that, when filled, activates an OCO pair of two peer orders.
|
|
6740
6736
|
* @summary Place complex order
|
|
6741
6737
|
* @param {TradingApiPlaceComplexOrderRequest} requestParameters Request parameters.
|
|
6742
6738
|
* @param {*} [options] Override http request option.
|
|
@@ -7099,7 +7095,7 @@ var Configuration = class {
|
|
|
7099
7095
|
this.accessToken = param.accessToken;
|
|
7100
7096
|
this.basePath = param.basePath;
|
|
7101
7097
|
this.baseOptions = param.baseOptions ?? {};
|
|
7102
|
-
this.userAgent = param.userAgent === void 0 ? "Konfig/10.0.
|
|
7098
|
+
this.userAgent = param.userAgent === void 0 ? "Konfig/10.0.5/typescript" : param.userAgent;
|
|
7103
7099
|
this.formDataCtor = param.formDataCtor;
|
|
7104
7100
|
}
|
|
7105
7101
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "snaptrade-typescript-sdk",
|
|
3
|
-
"version": "10.0.
|
|
3
|
+
"version": "10.0.5",
|
|
4
4
|
"description": "Client for SnapTrade",
|
|
5
5
|
"author": "Konfig",
|
|
6
6
|
"engines": {
|
|
@@ -22,9 +22,14 @@
|
|
|
22
22
|
"sideEffects": false,
|
|
23
23
|
"main": "./dist/index.cjs",
|
|
24
24
|
"module": "./dist/index.mjs",
|
|
25
|
+
"browser": "./dist/index.browser.mjs",
|
|
25
26
|
"types": "./dist/index.d.ts",
|
|
26
27
|
"exports": {
|
|
27
28
|
".": {
|
|
29
|
+
"browser": {
|
|
30
|
+
"types": "./dist/index.d.mts",
|
|
31
|
+
"default": "./dist/index.browser.mjs"
|
|
32
|
+
},
|
|
28
33
|
"require": {
|
|
29
34
|
"types": "./dist/index.d.cts",
|
|
30
35
|
"default": "./dist/index.cjs"
|