snaptrade-typescript-sdk 9.0.180 → 9.0.186
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 +56 -3
- package/dist/api/account-information-api-generated.d.ts +16 -9
- package/dist/api/account-information-api-generated.js +14 -10
- package/dist/api/connections-api-generated.d.ts +16 -9
- package/dist/api/connections-api-generated.js +14 -10
- package/dist/api/experimental-endpoints-api-generated.d.ts +61 -0
- package/dist/api/experimental-endpoints-api-generated.js +89 -0
- package/dist/api/transactions-and-reporting-api-generated.d.ts +4 -4
- package/dist/api/transactions-and-reporting-api-generated.js +4 -4
- package/dist/browser.js +1 -1
- package/dist/configuration.js +1 -1
- package/dist/models/account-order-record-trailing-stop.d.ts +21 -0
- package/dist/models/account-order-record-trailing-stop.js +2 -0
- package/dist/models/account-order-record-v2.d.ts +7 -0
- package/dist/models/account-order-record.d.ts +7 -0
- package/dist/models/brokerage-authorization-transactions-sync-confirmation.d.ts +14 -0
- package/dist/models/brokerage-authorization-transactions-sync-confirmation.js +2 -0
- package/dist/models/index.d.ts +3 -0
- package/dist/models/index.js +3 -0
- package/dist/models/order-updated-response-order.d.ts +7 -0
- package/dist/models/rate-of-return-object.d.ts +1 -1
- package/dist/models/trailing-stop.d.ts +22 -0
- package/dist/models/trailing-stop.js +2 -0
- package/dist/models/transactions-status.d.ts +1 -1
- package/dist/operationParameterMap.js +19 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
Connect brokerage accounts to your app for live positions and trading
|
|
8
8
|
|
|
9
|
-
[](https://www.npmjs.com/package/snaptrade-typescript-sdk/v/9.0.186)
|
|
10
10
|
[](https://snaptrade.com/)
|
|
11
11
|
|
|
12
12
|
</div>
|
|
@@ -48,6 +48,7 @@ Connect brokerage accounts to your app for live positions and trading
|
|
|
48
48
|
* [`snaptrade.experimentalEndpoints.getUserAccountOrderDetailV2`](#snaptradeexperimentalendpointsgetuseraccountorderdetailv2)
|
|
49
49
|
* [`snaptrade.experimentalEndpoints.getUserAccountOrdersV2`](#snaptradeexperimentalendpointsgetuseraccountordersv2)
|
|
50
50
|
* [`snaptrade.experimentalEndpoints.getUserAccountRecentOrdersV2`](#snaptradeexperimentalendpointsgetuseraccountrecentordersv2)
|
|
51
|
+
* [`snaptrade.experimentalEndpoints.syncBrokerageAuthorizationTransactions`](#snaptradeexperimentalendpointssyncbrokerageauthorizationtransactions)
|
|
51
52
|
* [`snaptrade.options.listOptionHoldings`](#snaptradeoptionslistoptionholdings)
|
|
52
53
|
* [`snaptrade.referenceData.getCurrencyExchangeRatePair`](#snaptradereferencedatagetcurrencyexchangeratepair)
|
|
53
54
|
* [`snaptrade.referenceData.getPartnerInfo`](#snaptradereferencedatagetpartnerinfo)
|
|
@@ -270,6 +271,8 @@ Optional comma separated list of transaction types to filter by. SnapTrade does
|
|
|
270
271
|
List all accounts for the user, plus balances, positions, and orders for each
|
|
271
272
|
account.
|
|
272
273
|
|
|
274
|
+
**Note:** This endpoint will return HTTP 410 Gone for all customers that sign up after April 25, 2026.
|
|
275
|
+
|
|
273
276
|
|
|
274
277
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
|
275
278
|
|
|
@@ -581,7 +584,7 @@ Defaults to true. Indicates if request should fetch only executed orders. Set to
|
|
|
581
584
|
|
|
582
585
|
### `snaptrade.accountInformation.getUserAccountReturnRates`<a id="snaptradeaccountinformationgetuseraccountreturnrates"></a>
|
|
583
586
|
|
|
584
|
-
Returns a list of rate of return percents for a given account.
|
|
587
|
+
Returns a list of rate of return percents for a given account.
|
|
585
588
|
|
|
586
589
|
|
|
587
590
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
|
@@ -592,6 +595,7 @@ const getUserAccountReturnRatesResponse =
|
|
|
592
595
|
userId: "snaptrade-user-123",
|
|
593
596
|
userSecret: "adf2aa34-8219-40f7-a6b3-60156985cc61",
|
|
594
597
|
accountId: "917c8734-8470-4a3e-a18f-57c3f2ee6631",
|
|
598
|
+
timeframes: "ALL,1Y",
|
|
595
599
|
});
|
|
596
600
|
```
|
|
597
601
|
|
|
@@ -603,6 +607,10 @@ const getUserAccountReturnRatesResponse =
|
|
|
603
607
|
|
|
604
608
|
##### accountId: `string`<a id="accountid-string"></a>
|
|
605
609
|
|
|
610
|
+
##### timeframes: `string`<a id="timeframes-string"></a>
|
|
611
|
+
|
|
612
|
+
Optional comma separated list of rate-of-return timeframes to return. Supported values are `ALL`, `1Y`, `YTD`, `1M`, `1W`, and `1D`. If omitted, SnapTrade returns all six supported timeframes.
|
|
613
|
+
|
|
606
614
|
#### 🔄 Return<a id="🔄-return"></a>
|
|
607
615
|
|
|
608
616
|
[RateOfReturnResponse](./models/rate-of-return-response.ts)
|
|
@@ -1113,6 +1121,7 @@ Trigger a holdings update for all accounts under this connection. Updates will b
|
|
|
1113
1121
|
This endpoint will also trigger a transaction sync for the past day if one has not yet occurred.
|
|
1114
1122
|
|
|
1115
1123
|
**Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)**
|
|
1124
|
+
**Please note this endpoint is disabled for real-time plans (ex: PayGo). Real-time plans do not benefit from this feature since data is refreshed when calls are made**
|
|
1116
1125
|
|
|
1117
1126
|
|
|
1118
1127
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
|
@@ -1181,7 +1190,7 @@ const removeBrokerageAuthorizationResponse =
|
|
|
1181
1190
|
|
|
1182
1191
|
### `snaptrade.connections.returnRates`<a id="snaptradeconnectionsreturnrates"></a>
|
|
1183
1192
|
|
|
1184
|
-
Returns a list of rate of return percents for a given connection.
|
|
1193
|
+
Returns a list of rate of return percents for a given connection.
|
|
1185
1194
|
|
|
1186
1195
|
|
|
1187
1196
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
|
@@ -1191,6 +1200,7 @@ const returnRatesResponse = await snaptrade.connections.returnRates({
|
|
|
1191
1200
|
userId: "snaptrade-user-123",
|
|
1192
1201
|
userSecret: "adf2aa34-8219-40f7-a6b3-60156985cc61",
|
|
1193
1202
|
authorizationId: "87b24961-b51e-4db8-9226-f198f6518a89",
|
|
1203
|
+
timeframes: "ALL,1Y",
|
|
1194
1204
|
});
|
|
1195
1205
|
```
|
|
1196
1206
|
|
|
@@ -1202,6 +1212,10 @@ const returnRatesResponse = await snaptrade.connections.returnRates({
|
|
|
1202
1212
|
|
|
1203
1213
|
##### authorizationId: `string`<a id="authorizationid-string"></a>
|
|
1204
1214
|
|
|
1215
|
+
##### timeframes: `string`<a id="timeframes-string"></a>
|
|
1216
|
+
|
|
1217
|
+
Optional comma separated list of rate-of-return timeframes to return. Supported values are `ALL`, `1Y`, `YTD`, `1M`, `1W`, and `1D`. If omitted, SnapTrade returns all six supported timeframes.
|
|
1218
|
+
|
|
1205
1219
|
#### 🔄 Return<a id="🔄-return"></a>
|
|
1206
1220
|
|
|
1207
1221
|
[RateOfReturnResponse](./models/rate-of-return-response.ts)
|
|
@@ -1436,6 +1450,43 @@ Defaults to true. Indicates if request should fetch only executed orders. Set to
|
|
|
1436
1450
|
---
|
|
1437
1451
|
|
|
1438
1452
|
|
|
1453
|
+
### `snaptrade.experimentalEndpoints.syncBrokerageAuthorizationTransactions`<a id="snaptradeexperimentalendpointssyncbrokerageauthorizationtransactions"></a>
|
|
1454
|
+
|
|
1455
|
+
Trigger a transactions sync for all accounts under this connection. Updates will be queued asynchronously. Transactions are not updated intra-day, but calling this endpoint can ensure that the previous day's transactions have been synced. For more information on sync behaviour, see: https://docs.snaptrade.com/docs/syncing
|
|
1456
|
+
|
|
1457
|
+
|
|
1458
|
+
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
|
1459
|
+
|
|
1460
|
+
```typescript
|
|
1461
|
+
const syncBrokerageAuthorizationTransactionsResponse =
|
|
1462
|
+
await snaptrade.experimentalEndpoints.syncBrokerageAuthorizationTransactions({
|
|
1463
|
+
authorizationId: "87b24961-b51e-4db8-9226-f198f6518a89",
|
|
1464
|
+
userId: "snaptrade-user-123",
|
|
1465
|
+
userSecret: "adf2aa34-8219-40f7-a6b3-60156985cc61",
|
|
1466
|
+
});
|
|
1467
|
+
```
|
|
1468
|
+
|
|
1469
|
+
#### ⚙️ Parameters<a id="⚙️-parameters"></a>
|
|
1470
|
+
|
|
1471
|
+
##### authorizationId: `string`<a id="authorizationid-string"></a>
|
|
1472
|
+
|
|
1473
|
+
##### userId: `string`<a id="userid-string"></a>
|
|
1474
|
+
|
|
1475
|
+
##### userSecret: `string`<a id="usersecret-string"></a>
|
|
1476
|
+
|
|
1477
|
+
#### 🔄 Return<a id="🔄-return"></a>
|
|
1478
|
+
|
|
1479
|
+
[BrokerageAuthorizationTransactionsSyncConfirmation](./models/brokerage-authorization-transactions-sync-confirmation.ts)
|
|
1480
|
+
|
|
1481
|
+
#### 🌐 Endpoint<a id="🌐-endpoint"></a>
|
|
1482
|
+
|
|
1483
|
+
`/authorizations/{authorizationId}/transactions/sync` `POST`
|
|
1484
|
+
|
|
1485
|
+
[🔙 **Back to Table of Contents**](#table-of-contents)
|
|
1486
|
+
|
|
1487
|
+
---
|
|
1488
|
+
|
|
1489
|
+
|
|
1439
1490
|
### `snaptrade.options.listOptionHoldings`<a id="snaptradeoptionslistoptionholdings"></a>
|
|
1440
1491
|
|
|
1441
1492
|
Returns a list of option positions in the specified account. For stock/ETF/crypto/mutual fund positions, please use the [positions endpoint](/reference/Account%20Information/AccountInformation_getUserAccountPositions).
|
|
@@ -2778,6 +2829,8 @@ There is no guarantee to the ordering of the transactions returned. Please sort
|
|
|
2778
2829
|
|
|
2779
2830
|
The data returned here is always cached and refreshed once a day.
|
|
2780
2831
|
|
|
2832
|
+
**Note:** This endpoint will return HTTP 410 Gone for all customers that sign up after April 25, 2026.
|
|
2833
|
+
|
|
2781
2834
|
|
|
2782
2835
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
|
2783
2836
|
|
|
@@ -32,7 +32,7 @@ export declare const AccountInformationApiAxiosParamCreator: (configuration?: Co
|
|
|
32
32
|
*/
|
|
33
33
|
getAccountActivities: (accountId: string, userId: string, userSecret: string, startDate?: string | Date, endDate?: string | Date, offset?: number, limit?: number, type?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
34
34
|
/**
|
|
35
|
-
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account.
|
|
35
|
+
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account. **Note:** This endpoint will return HTTP 410 Gone for all customers that sign up after April 25, 2026.
|
|
36
36
|
* @summary List all accounts for the user, plus balances, positions, and orders for each account.
|
|
37
37
|
* @param {string} userId
|
|
38
38
|
* @param {string} userSecret
|
|
@@ -107,15 +107,16 @@ export declare const AccountInformationApiAxiosParamCreator: (configuration?: Co
|
|
|
107
107
|
*/
|
|
108
108
|
getUserAccountRecentOrders: (userId: string, userSecret: string, accountId: string, onlyExecuted?: boolean, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
109
109
|
/**
|
|
110
|
-
* Returns a list of rate of return percents for a given account.
|
|
110
|
+
* Returns a list of rate of return percents for a given account.
|
|
111
111
|
* @summary List account rate of returns
|
|
112
112
|
* @param {string} userId
|
|
113
113
|
* @param {string} userSecret
|
|
114
114
|
* @param {string} accountId
|
|
115
|
+
* @param {string} [timeframes] Optional comma separated list of rate-of-return timeframes to return. Supported values are `ALL`, `1Y`, `YTD`, `1M`, `1W`, and `1D`. If omitted, SnapTrade returns all six supported timeframes.
|
|
115
116
|
* @param {*} [options] Override http request option.
|
|
116
117
|
* @throws {RequiredError}
|
|
117
118
|
*/
|
|
118
|
-
getUserAccountReturnRates: (userId: string, userSecret: string, accountId: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
119
|
+
getUserAccountReturnRates: (userId: string, userSecret: string, accountId: string, timeframes?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
119
120
|
/**
|
|
120
121
|
* Returns a list of balances, positions, and recent orders for the specified account. The data returned is similar to the data returned over the more fine-grained [balances](/reference/Account%20Information/AccountInformation_getUserAccountBalance), [positions](/reference/Account%20Information/AccountInformation_getUserAccountPositions) and [orders](/reference/Account%20Information/AccountInformation_getUserAccountOrders) endpoints. __The finer-grained APIs are preferred. They are easier to work with, faster, and have better error handling than this coarse-grained API.__ Check your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing) to see if you have real-time data access: - If you do, this endpoint returns real-time data. - If you don\'t, the data is cached and refreshed once a day. How long the data is cached for varies by brokerage. Check the [brokerage integrations doc](https://support.snaptrade.com/brokerages-table?v=d16c4c97b8d5438bbb2d8581ac53b11e) and look for \"Cache Expiry Time\" to see the exact value for a specific brokerage. If you need real-time, use the [manual refresh](/reference/Connections/Connections_refreshBrokerageAuthorization) endpoint. If the connection has become disabled, it can no longer access the latest data from the brokerage, but will continue to return the last available cached state. Please see [this guide](/docs/fix-broken-connections) on how to fix a disabled connection.
|
|
121
122
|
* @summary List account holdings
|
|
@@ -160,7 +161,7 @@ export declare const AccountInformationApiFp: (configuration?: Configuration) =>
|
|
|
160
161
|
*/
|
|
161
162
|
getAccountActivities(requestParameters: AccountInformationApiGetAccountActivitiesRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<PaginatedUniversalActivity>>;
|
|
162
163
|
/**
|
|
163
|
-
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account.
|
|
164
|
+
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account. **Note:** This endpoint will return HTTP 410 Gone for all customers that sign up after April 25, 2026.
|
|
164
165
|
* @summary List all accounts for the user, plus balances, positions, and orders for each account.
|
|
165
166
|
* @param {AccountInformationApiGetAllUserHoldingsRequest} requestParameters Request parameters.
|
|
166
167
|
* @param {*} [options] Override http request option.
|
|
@@ -217,7 +218,7 @@ export declare const AccountInformationApiFp: (configuration?: Configuration) =>
|
|
|
217
218
|
*/
|
|
218
219
|
getUserAccountRecentOrders(requestParameters: AccountInformationApiGetUserAccountRecentOrdersRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<RecentOrdersResponse>>;
|
|
219
220
|
/**
|
|
220
|
-
* Returns a list of rate of return percents for a given account.
|
|
221
|
+
* Returns a list of rate of return percents for a given account.
|
|
221
222
|
* @summary List account rate of returns
|
|
222
223
|
* @param {AccountInformationApiGetUserAccountReturnRatesRequest} requestParameters Request parameters.
|
|
223
224
|
* @param {*} [options] Override http request option.
|
|
@@ -263,7 +264,7 @@ export declare const AccountInformationApiFactory: (configuration?: Configuratio
|
|
|
263
264
|
*/
|
|
264
265
|
getAccountActivities(requestParameters: AccountInformationApiGetAccountActivitiesRequest, options?: AxiosRequestConfig): AxiosPromise<PaginatedUniversalActivity>;
|
|
265
266
|
/**
|
|
266
|
-
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account.
|
|
267
|
+
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account. **Note:** This endpoint will return HTTP 410 Gone for all customers that sign up after April 25, 2026.
|
|
267
268
|
* @summary List all accounts for the user, plus balances, positions, and orders for each account.
|
|
268
269
|
* @param {AccountInformationApiGetAllUserHoldingsRequest} requestParameters Request parameters.
|
|
269
270
|
* @param {*} [options] Override http request option.
|
|
@@ -320,7 +321,7 @@ export declare const AccountInformationApiFactory: (configuration?: Configuratio
|
|
|
320
321
|
*/
|
|
321
322
|
getUserAccountRecentOrders(requestParameters: AccountInformationApiGetUserAccountRecentOrdersRequest, options?: AxiosRequestConfig): AxiosPromise<RecentOrdersResponse>;
|
|
322
323
|
/**
|
|
323
|
-
* Returns a list of rate of return percents for a given account.
|
|
324
|
+
* Returns a list of rate of return percents for a given account.
|
|
324
325
|
* @summary List account rate of returns
|
|
325
326
|
* @param {AccountInformationApiGetUserAccountReturnRatesRequest} requestParameters Request parameters.
|
|
326
327
|
* @param {*} [options] Override http request option.
|
|
@@ -624,6 +625,12 @@ export type AccountInformationApiGetUserAccountReturnRatesRequest = {
|
|
|
624
625
|
* @memberof AccountInformationApiGetUserAccountReturnRates
|
|
625
626
|
*/
|
|
626
627
|
readonly accountId: string;
|
|
628
|
+
/**
|
|
629
|
+
* Optional comma separated list of rate-of-return timeframes to return. Supported values are `ALL`, `1Y`, `YTD`, `1M`, `1W`, and `1D`. If omitted, SnapTrade returns all six supported timeframes.
|
|
630
|
+
* @type {string}
|
|
631
|
+
* @memberof AccountInformationApiGetUserAccountReturnRates
|
|
632
|
+
*/
|
|
633
|
+
readonly timeframes?: string;
|
|
627
634
|
};
|
|
628
635
|
/**
|
|
629
636
|
* Request parameters for getUserHoldings operation in AccountInformationApi.
|
|
@@ -711,7 +718,7 @@ export declare class AccountInformationApiGenerated extends BaseAPI {
|
|
|
711
718
|
*/
|
|
712
719
|
getAccountActivities(requestParameters: AccountInformationApiGetAccountActivitiesRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<PaginatedUniversalActivity, any, {}>>;
|
|
713
720
|
/**
|
|
714
|
-
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account.
|
|
721
|
+
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account. **Note:** This endpoint will return HTTP 410 Gone for all customers that sign up after April 25, 2026.
|
|
715
722
|
* @summary List all accounts for the user, plus balances, positions, and orders for each account.
|
|
716
723
|
* @param {AccountInformationApiGetAllUserHoldingsRequest} requestParameters Request parameters.
|
|
717
724
|
* @param {*} [options] Override http request option.
|
|
@@ -775,7 +782,7 @@ export declare class AccountInformationApiGenerated extends BaseAPI {
|
|
|
775
782
|
*/
|
|
776
783
|
getUserAccountRecentOrders(requestParameters: AccountInformationApiGetUserAccountRecentOrdersRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<RecentOrdersResponse, any, {}>>;
|
|
777
784
|
/**
|
|
778
|
-
* Returns a list of rate of return percents for a given account.
|
|
785
|
+
* Returns a list of rate of return percents for a given account.
|
|
779
786
|
* @summary List account rate of returns
|
|
780
787
|
* @param {AccountInformationApiGetUserAccountReturnRatesRequest} requestParameters Request parameters.
|
|
781
788
|
* @param {*} [options] Override http request option.
|
|
@@ -115,7 +115,7 @@ const AccountInformationApiAxiosParamCreator = function (configuration) {
|
|
|
115
115
|
};
|
|
116
116
|
}),
|
|
117
117
|
/**
|
|
118
|
-
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account.
|
|
118
|
+
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account. **Note:** This endpoint will return HTTP 410 Gone for all customers that sign up after April 25, 2026.
|
|
119
119
|
* @summary List all accounts for the user, plus balances, positions, and orders for each account.
|
|
120
120
|
* @param {string} userId
|
|
121
121
|
* @param {string} userSecret
|
|
@@ -519,15 +519,16 @@ const AccountInformationApiAxiosParamCreator = function (configuration) {
|
|
|
519
519
|
};
|
|
520
520
|
}),
|
|
521
521
|
/**
|
|
522
|
-
* Returns a list of rate of return percents for a given account.
|
|
522
|
+
* Returns a list of rate of return percents for a given account.
|
|
523
523
|
* @summary List account rate of returns
|
|
524
524
|
* @param {string} userId
|
|
525
525
|
* @param {string} userSecret
|
|
526
526
|
* @param {string} accountId
|
|
527
|
+
* @param {string} [timeframes] Optional comma separated list of rate-of-return timeframes to return. Supported values are `ALL`, `1Y`, `YTD`, `1M`, `1W`, and `1D`. If omitted, SnapTrade returns all six supported timeframes.
|
|
527
528
|
* @param {*} [options] Override http request option.
|
|
528
529
|
* @throws {RequiredError}
|
|
529
530
|
*/
|
|
530
|
-
getUserAccountReturnRates: (userId, userSecret, accountId, options = {}) => __awaiter(this, void 0, void 0, function* () {
|
|
531
|
+
getUserAccountReturnRates: (userId, userSecret, accountId, timeframes, options = {}) => __awaiter(this, void 0, void 0, function* () {
|
|
531
532
|
// verify required parameter 'userId' is not null or undefined
|
|
532
533
|
(0, common_1.assertParamExists)('getUserAccountReturnRates', 'userId', userId);
|
|
533
534
|
// verify required parameter 'userSecret' is not null or undefined
|
|
@@ -557,6 +558,9 @@ const AccountInformationApiAxiosParamCreator = function (configuration) {
|
|
|
557
558
|
if (userSecret !== undefined) {
|
|
558
559
|
localVarQueryParameter['userSecret'] = userSecret;
|
|
559
560
|
}
|
|
561
|
+
if (timeframes !== undefined) {
|
|
562
|
+
localVarQueryParameter['timeframes'] = timeframes;
|
|
563
|
+
}
|
|
560
564
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
561
565
|
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
562
566
|
(0, requestBeforeHook_1.requestBeforeHook)({
|
|
@@ -758,7 +762,7 @@ const AccountInformationApiFp = function (configuration) {
|
|
|
758
762
|
});
|
|
759
763
|
},
|
|
760
764
|
/**
|
|
761
|
-
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account.
|
|
765
|
+
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account. **Note:** This endpoint will return HTTP 410 Gone for all customers that sign up after April 25, 2026.
|
|
762
766
|
* @summary List all accounts for the user, plus balances, positions, and orders for each account.
|
|
763
767
|
* @param {AccountInformationApiGetAllUserHoldingsRequest} requestParameters Request parameters.
|
|
764
768
|
* @param {*} [options] Override http request option.
|
|
@@ -853,7 +857,7 @@ const AccountInformationApiFp = function (configuration) {
|
|
|
853
857
|
});
|
|
854
858
|
},
|
|
855
859
|
/**
|
|
856
|
-
* Returns a list of rate of return percents for a given account.
|
|
860
|
+
* Returns a list of rate of return percents for a given account.
|
|
857
861
|
* @summary List account rate of returns
|
|
858
862
|
* @param {AccountInformationApiGetUserAccountReturnRatesRequest} requestParameters Request parameters.
|
|
859
863
|
* @param {*} [options] Override http request option.
|
|
@@ -861,7 +865,7 @@ const AccountInformationApiFp = function (configuration) {
|
|
|
861
865
|
*/
|
|
862
866
|
getUserAccountReturnRates(requestParameters, options) {
|
|
863
867
|
return __awaiter(this, void 0, void 0, function* () {
|
|
864
|
-
const localVarAxiosArgs = yield localVarAxiosParamCreator.getUserAccountReturnRates(requestParameters.userId, requestParameters.userSecret, requestParameters.accountId, options);
|
|
868
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.getUserAccountReturnRates(requestParameters.userId, requestParameters.userSecret, requestParameters.accountId, requestParameters.timeframes, options);
|
|
865
869
|
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
|
|
866
870
|
});
|
|
867
871
|
},
|
|
@@ -925,7 +929,7 @@ const AccountInformationApiFactory = function (configuration, basePath, axios) {
|
|
|
925
929
|
return localVarFp.getAccountActivities(requestParameters, options).then((request) => request(axios, basePath));
|
|
926
930
|
},
|
|
927
931
|
/**
|
|
928
|
-
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account.
|
|
932
|
+
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account. **Note:** This endpoint will return HTTP 410 Gone for all customers that sign up after April 25, 2026.
|
|
929
933
|
* @summary List all accounts for the user, plus balances, positions, and orders for each account.
|
|
930
934
|
* @param {AccountInformationApiGetAllUserHoldingsRequest} requestParameters Request parameters.
|
|
931
935
|
* @param {*} [options] Override http request option.
|
|
@@ -996,7 +1000,7 @@ const AccountInformationApiFactory = function (configuration, basePath, axios) {
|
|
|
996
1000
|
return localVarFp.getUserAccountRecentOrders(requestParameters, options).then((request) => request(axios, basePath));
|
|
997
1001
|
},
|
|
998
1002
|
/**
|
|
999
|
-
* Returns a list of rate of return percents for a given account.
|
|
1003
|
+
* Returns a list of rate of return percents for a given account.
|
|
1000
1004
|
* @summary List account rate of returns
|
|
1001
1005
|
* @param {AccountInformationApiGetUserAccountReturnRatesRequest} requestParameters Request parameters.
|
|
1002
1006
|
* @param {*} [options] Override http request option.
|
|
@@ -1057,7 +1061,7 @@ class AccountInformationApiGenerated extends base_1.BaseAPI {
|
|
|
1057
1061
|
return (0, exports.AccountInformationApiFp)(this.configuration).getAccountActivities(requestParameters, options).then((request) => request(this.axios, this.basePath));
|
|
1058
1062
|
}
|
|
1059
1063
|
/**
|
|
1060
|
-
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account.
|
|
1064
|
+
* **Deprecated, please use the account-specific holdings endpoint instead.** List all accounts for the user, plus balances, positions, and orders for each account. **Note:** This endpoint will return HTTP 410 Gone for all customers that sign up after April 25, 2026.
|
|
1061
1065
|
* @summary List all accounts for the user, plus balances, positions, and orders for each account.
|
|
1062
1066
|
* @param {AccountInformationApiGetAllUserHoldingsRequest} requestParameters Request parameters.
|
|
1063
1067
|
* @param {*} [options] Override http request option.
|
|
@@ -1135,7 +1139,7 @@ class AccountInformationApiGenerated extends base_1.BaseAPI {
|
|
|
1135
1139
|
return (0, exports.AccountInformationApiFp)(this.configuration).getUserAccountRecentOrders(requestParameters, options).then((request) => request(this.axios, this.basePath));
|
|
1136
1140
|
}
|
|
1137
1141
|
/**
|
|
1138
|
-
* Returns a list of rate of return percents for a given account.
|
|
1142
|
+
* Returns a list of rate of return percents for a given account.
|
|
1139
1143
|
* @summary List account rate of returns
|
|
1140
1144
|
* @param {AccountInformationApiGetUserAccountReturnRatesRequest} requestParameters Request parameters.
|
|
1141
1145
|
* @param {*} [options] Override http request option.
|
|
@@ -52,7 +52,7 @@ export declare const ConnectionsApiAxiosParamCreator: (configuration?: Configura
|
|
|
52
52
|
*/
|
|
53
53
|
listBrokerageAuthorizations: (userId: string, userSecret: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
54
54
|
/**
|
|
55
|
-
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)**
|
|
55
|
+
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)** **Please note this endpoint is disabled for real-time plans (ex: PayGo). Real-time plans do not benefit from this feature since data is refreshed when calls are made**
|
|
56
56
|
* @summary Refresh holdings for a connection
|
|
57
57
|
* @param {string} authorizationId
|
|
58
58
|
* @param {string} userId
|
|
@@ -72,15 +72,16 @@ export declare const ConnectionsApiAxiosParamCreator: (configuration?: Configura
|
|
|
72
72
|
*/
|
|
73
73
|
removeBrokerageAuthorization: (authorizationId: string, userId: string, userSecret: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
74
74
|
/**
|
|
75
|
-
* Returns a list of rate of return percents for a given connection.
|
|
75
|
+
* Returns a list of rate of return percents for a given connection.
|
|
76
76
|
* @summary List connection rate of returns
|
|
77
77
|
* @param {string} userId
|
|
78
78
|
* @param {string} userSecret
|
|
79
79
|
* @param {string} authorizationId
|
|
80
|
+
* @param {string} [timeframes] Optional comma separated list of rate-of-return timeframes to return. Supported values are `ALL`, `1Y`, `YTD`, `1M`, `1W`, and `1D`. If omitted, SnapTrade returns all six supported timeframes.
|
|
80
81
|
* @param {*} [options] Override http request option.
|
|
81
82
|
* @throws {RequiredError}
|
|
82
83
|
*/
|
|
83
|
-
returnRates: (userId: string, userSecret: string, authorizationId: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
84
|
+
returnRates: (userId: string, userSecret: string, authorizationId: string, timeframes?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
84
85
|
/**
|
|
85
86
|
* Returns a list of session events associated with a user.
|
|
86
87
|
* @summary Get all session events for a user
|
|
@@ -130,7 +131,7 @@ export declare const ConnectionsApiFp: (configuration?: Configuration) => {
|
|
|
130
131
|
*/
|
|
131
132
|
listBrokerageAuthorizations(requestParameters: ConnectionsApiListBrokerageAuthorizationsRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<BrokerageAuthorization>>>;
|
|
132
133
|
/**
|
|
133
|
-
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)**
|
|
134
|
+
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)** **Please note this endpoint is disabled for real-time plans (ex: PayGo). Real-time plans do not benefit from this feature since data is refreshed when calls are made**
|
|
134
135
|
* @summary Refresh holdings for a connection
|
|
135
136
|
* @param {ConnectionsApiRefreshBrokerageAuthorizationRequest} requestParameters Request parameters.
|
|
136
137
|
* @param {*} [options] Override http request option.
|
|
@@ -146,7 +147,7 @@ export declare const ConnectionsApiFp: (configuration?: Configuration) => {
|
|
|
146
147
|
*/
|
|
147
148
|
removeBrokerageAuthorization(requestParameters: ConnectionsApiRemoveBrokerageAuthorizationRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
|
|
148
149
|
/**
|
|
149
|
-
* Returns a list of rate of return percents for a given connection.
|
|
150
|
+
* Returns a list of rate of return percents for a given connection.
|
|
150
151
|
* @summary List connection rate of returns
|
|
151
152
|
* @param {ConnectionsApiReturnRatesRequest} requestParameters Request parameters.
|
|
152
153
|
* @param {*} [options] Override http request option.
|
|
@@ -200,7 +201,7 @@ export declare const ConnectionsApiFactory: (configuration?: Configuration, base
|
|
|
200
201
|
*/
|
|
201
202
|
listBrokerageAuthorizations(requestParameters: ConnectionsApiListBrokerageAuthorizationsRequest, options?: AxiosRequestConfig): AxiosPromise<Array<BrokerageAuthorization>>;
|
|
202
203
|
/**
|
|
203
|
-
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)**
|
|
204
|
+
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)** **Please note this endpoint is disabled for real-time plans (ex: PayGo). Real-time plans do not benefit from this feature since data is refreshed when calls are made**
|
|
204
205
|
* @summary Refresh holdings for a connection
|
|
205
206
|
* @param {ConnectionsApiRefreshBrokerageAuthorizationRequest} requestParameters Request parameters.
|
|
206
207
|
* @param {*} [options] Override http request option.
|
|
@@ -216,7 +217,7 @@ export declare const ConnectionsApiFactory: (configuration?: Configuration, base
|
|
|
216
217
|
*/
|
|
217
218
|
removeBrokerageAuthorization(requestParameters: ConnectionsApiRemoveBrokerageAuthorizationRequest, options?: AxiosRequestConfig): AxiosPromise<void>;
|
|
218
219
|
/**
|
|
219
|
-
* Returns a list of rate of return percents for a given connection.
|
|
220
|
+
* Returns a list of rate of return percents for a given connection.
|
|
220
221
|
* @summary List connection rate of returns
|
|
221
222
|
* @param {ConnectionsApiReturnRatesRequest} requestParameters Request parameters.
|
|
222
223
|
* @param {*} [options] Override http request option.
|
|
@@ -400,6 +401,12 @@ export type ConnectionsApiReturnRatesRequest = {
|
|
|
400
401
|
* @memberof ConnectionsApiReturnRates
|
|
401
402
|
*/
|
|
402
403
|
readonly authorizationId: string;
|
|
404
|
+
/**
|
|
405
|
+
* Optional comma separated list of rate-of-return timeframes to return. Supported values are `ALL`, `1Y`, `YTD`, `1M`, `1W`, and `1D`. If omitted, SnapTrade returns all six supported timeframes.
|
|
406
|
+
* @type {string}
|
|
407
|
+
* @memberof ConnectionsApiReturnRates
|
|
408
|
+
*/
|
|
409
|
+
readonly timeframes?: string;
|
|
403
410
|
};
|
|
404
411
|
/**
|
|
405
412
|
* Request parameters for sessionEvents operation in ConnectionsApi.
|
|
@@ -470,7 +477,7 @@ export declare class ConnectionsApiGenerated extends BaseAPI {
|
|
|
470
477
|
*/
|
|
471
478
|
listBrokerageAuthorizations(requestParameters: ConnectionsApiListBrokerageAuthorizationsRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<BrokerageAuthorization[], any, {}>>;
|
|
472
479
|
/**
|
|
473
|
-
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)**
|
|
480
|
+
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)** **Please note this endpoint is disabled for real-time plans (ex: PayGo). Real-time plans do not benefit from this feature since data is refreshed when calls are made**
|
|
474
481
|
* @summary Refresh holdings for a connection
|
|
475
482
|
* @param {ConnectionsApiRefreshBrokerageAuthorizationRequest} requestParameters Request parameters.
|
|
476
483
|
* @param {*} [options] Override http request option.
|
|
@@ -488,7 +495,7 @@ export declare class ConnectionsApiGenerated extends BaseAPI {
|
|
|
488
495
|
*/
|
|
489
496
|
removeBrokerageAuthorization(requestParameters: ConnectionsApiRemoveBrokerageAuthorizationRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
490
497
|
/**
|
|
491
|
-
* Returns a list of rate of return percents for a given connection.
|
|
498
|
+
* Returns a list of rate of return percents for a given connection.
|
|
492
499
|
* @summary List connection rate of returns
|
|
493
500
|
* @param {ConnectionsApiReturnRatesRequest} requestParameters Request parameters.
|
|
494
501
|
* @param {*} [options] Override http request option.
|
|
@@ -252,7 +252,7 @@ const ConnectionsApiAxiosParamCreator = function (configuration) {
|
|
|
252
252
|
};
|
|
253
253
|
}),
|
|
254
254
|
/**
|
|
255
|
-
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)**
|
|
255
|
+
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)** **Please note this endpoint is disabled for real-time plans (ex: PayGo). Real-time plans do not benefit from this feature since data is refreshed when calls are made**
|
|
256
256
|
* @summary Refresh holdings for a connection
|
|
257
257
|
* @param {string} authorizationId
|
|
258
258
|
* @param {string} userId
|
|
@@ -362,15 +362,16 @@ const ConnectionsApiAxiosParamCreator = function (configuration) {
|
|
|
362
362
|
};
|
|
363
363
|
}),
|
|
364
364
|
/**
|
|
365
|
-
* Returns a list of rate of return percents for a given connection.
|
|
365
|
+
* Returns a list of rate of return percents for a given connection.
|
|
366
366
|
* @summary List connection rate of returns
|
|
367
367
|
* @param {string} userId
|
|
368
368
|
* @param {string} userSecret
|
|
369
369
|
* @param {string} authorizationId
|
|
370
|
+
* @param {string} [timeframes] Optional comma separated list of rate-of-return timeframes to return. Supported values are `ALL`, `1Y`, `YTD`, `1M`, `1W`, and `1D`. If omitted, SnapTrade returns all six supported timeframes.
|
|
370
371
|
* @param {*} [options] Override http request option.
|
|
371
372
|
* @throws {RequiredError}
|
|
372
373
|
*/
|
|
373
|
-
returnRates: (userId, userSecret, authorizationId, options = {}) => __awaiter(this, void 0, void 0, function* () {
|
|
374
|
+
returnRates: (userId, userSecret, authorizationId, timeframes, options = {}) => __awaiter(this, void 0, void 0, function* () {
|
|
374
375
|
// verify required parameter 'userId' is not null or undefined
|
|
375
376
|
(0, common_1.assertParamExists)('returnRates', 'userId', userId);
|
|
376
377
|
// verify required parameter 'userSecret' is not null or undefined
|
|
@@ -400,6 +401,9 @@ const ConnectionsApiAxiosParamCreator = function (configuration) {
|
|
|
400
401
|
if (userSecret !== undefined) {
|
|
401
402
|
localVarQueryParameter['userSecret'] = userSecret;
|
|
402
403
|
}
|
|
404
|
+
if (timeframes !== undefined) {
|
|
405
|
+
localVarQueryParameter['timeframes'] = timeframes;
|
|
406
|
+
}
|
|
403
407
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
404
408
|
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
405
409
|
(0, requestBeforeHook_1.requestBeforeHook)({
|
|
@@ -532,7 +536,7 @@ const ConnectionsApiFp = function (configuration) {
|
|
|
532
536
|
});
|
|
533
537
|
},
|
|
534
538
|
/**
|
|
535
|
-
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)**
|
|
539
|
+
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)** **Please note this endpoint is disabled for real-time plans (ex: PayGo). Real-time plans do not benefit from this feature since data is refreshed when calls are made**
|
|
536
540
|
* @summary Refresh holdings for a connection
|
|
537
541
|
* @param {ConnectionsApiRefreshBrokerageAuthorizationRequest} requestParameters Request parameters.
|
|
538
542
|
* @param {*} [options] Override http request option.
|
|
@@ -558,7 +562,7 @@ const ConnectionsApiFp = function (configuration) {
|
|
|
558
562
|
});
|
|
559
563
|
},
|
|
560
564
|
/**
|
|
561
|
-
* Returns a list of rate of return percents for a given connection.
|
|
565
|
+
* Returns a list of rate of return percents for a given connection.
|
|
562
566
|
* @summary List connection rate of returns
|
|
563
567
|
* @param {ConnectionsApiReturnRatesRequest} requestParameters Request parameters.
|
|
564
568
|
* @param {*} [options] Override http request option.
|
|
@@ -566,7 +570,7 @@ const ConnectionsApiFp = function (configuration) {
|
|
|
566
570
|
*/
|
|
567
571
|
returnRates(requestParameters, options) {
|
|
568
572
|
return __awaiter(this, void 0, void 0, function* () {
|
|
569
|
-
const localVarAxiosArgs = yield localVarAxiosParamCreator.returnRates(requestParameters.userId, requestParameters.userSecret, requestParameters.authorizationId, options);
|
|
573
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.returnRates(requestParameters.userId, requestParameters.userSecret, requestParameters.authorizationId, requestParameters.timeframes, options);
|
|
570
574
|
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
|
|
571
575
|
});
|
|
572
576
|
},
|
|
@@ -634,7 +638,7 @@ const ConnectionsApiFactory = function (configuration, basePath, axios) {
|
|
|
634
638
|
return localVarFp.listBrokerageAuthorizations(requestParameters, options).then((request) => request(axios, basePath));
|
|
635
639
|
},
|
|
636
640
|
/**
|
|
637
|
-
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)**
|
|
641
|
+
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)** **Please note this endpoint is disabled for real-time plans (ex: PayGo). Real-time plans do not benefit from this feature since data is refreshed when calls are made**
|
|
638
642
|
* @summary Refresh holdings for a connection
|
|
639
643
|
* @param {ConnectionsApiRefreshBrokerageAuthorizationRequest} requestParameters Request parameters.
|
|
640
644
|
* @param {*} [options] Override http request option.
|
|
@@ -654,7 +658,7 @@ const ConnectionsApiFactory = function (configuration, basePath, axios) {
|
|
|
654
658
|
return localVarFp.removeBrokerageAuthorization(requestParameters, options).then((request) => request(axios, basePath));
|
|
655
659
|
},
|
|
656
660
|
/**
|
|
657
|
-
* Returns a list of rate of return percents for a given connection.
|
|
661
|
+
* Returns a list of rate of return percents for a given connection.
|
|
658
662
|
* @summary List connection rate of returns
|
|
659
663
|
* @param {ConnectionsApiReturnRatesRequest} requestParameters Request parameters.
|
|
660
664
|
* @param {*} [options] Override http request option.
|
|
@@ -728,7 +732,7 @@ class ConnectionsApiGenerated extends base_1.BaseAPI {
|
|
|
728
732
|
return (0, exports.ConnectionsApiFp)(this.configuration).listBrokerageAuthorizations(requestParameters, options).then((request) => request(this.axios, this.basePath));
|
|
729
733
|
}
|
|
730
734
|
/**
|
|
731
|
-
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)**
|
|
735
|
+
* Trigger a holdings update for all accounts under this connection. Updates will be queued asynchronously. [`ACCOUNT_HOLDINGS_UPDATED` webhook](/docs/webhooks#webhooks-account_holdings_updated) will be sent once the sync completes for each account under the connection. This endpoint will also trigger a transaction sync for the past day if one has not yet occurred. **Because of the cost of refreshing a connection, each call to this endpoint incurs an additional charge. You can find the exact cost for your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing)** **Please note this endpoint is disabled for real-time plans (ex: PayGo). Real-time plans do not benefit from this feature since data is refreshed when calls are made**
|
|
732
736
|
* @summary Refresh holdings for a connection
|
|
733
737
|
* @param {ConnectionsApiRefreshBrokerageAuthorizationRequest} requestParameters Request parameters.
|
|
734
738
|
* @param {*} [options] Override http request option.
|
|
@@ -750,7 +754,7 @@ class ConnectionsApiGenerated extends base_1.BaseAPI {
|
|
|
750
754
|
return (0, exports.ConnectionsApiFp)(this.configuration).removeBrokerageAuthorization(requestParameters, options).then((request) => request(this.axios, this.basePath));
|
|
751
755
|
}
|
|
752
756
|
/**
|
|
753
|
-
* Returns a list of rate of return percents for a given connection.
|
|
757
|
+
* Returns a list of rate of return percents for a given connection.
|
|
754
758
|
* @summary List connection rate of returns
|
|
755
759
|
* @param {ConnectionsApiReturnRatesRequest} requestParameters Request parameters.
|
|
756
760
|
* @param {*} [options] Override http request option.
|