snaptrade-typescript-sdk 5.0.0 → 6.0.0

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.
Files changed (52) hide show
  1. package/.konfig/generate-id.txt +1 -1
  2. package/README.md +2 -2
  3. package/api/account-information-api.ts +136 -120
  4. package/api/api-disclaimer-api.ts +14 -19
  5. package/api/authentication-api.ts +37 -43
  6. package/api/connections-api.ts +46 -40
  7. package/api/error-logs-api.ts +12 -10
  8. package/api/options-api.ts +104 -108
  9. package/api/portfolio-management-api.ts +259 -253
  10. package/api/reference-data-api.ts +49 -53
  11. package/api/trading-api.ts +172 -185
  12. package/api/transactions-and-reporting-api.ts +64 -60
  13. package/client.ts +2 -0
  14. package/configuration.ts +1 -1
  15. package/dist/api/account-information-api.d.ts +112 -112
  16. package/dist/api/api-disclaimer-api.d.ts +10 -16
  17. package/dist/api/api-disclaimer-api.js +1 -1
  18. package/dist/api/authentication-api.d.ts +27 -40
  19. package/dist/api/authentication-api.js +2 -2
  20. package/dist/api/connections-api.d.ts +38 -38
  21. package/dist/api/error-logs-api.d.ts +10 -10
  22. package/dist/api/options-api.d.ts +82 -94
  23. package/dist/api/options-api.js +2 -2
  24. package/dist/api/portfolio-management-api.d.ts +214 -256
  25. package/dist/api/portfolio-management-api.js +7 -7
  26. package/dist/api/reference-data-api.d.ts +37 -50
  27. package/dist/api/reference-data-api.js +2 -2
  28. package/dist/api/trading-api.d.ts +131 -160
  29. package/dist/api/trading-api.js +10 -10
  30. package/dist/api/transactions-and-reporting-api.d.ts +52 -52
  31. package/dist/configuration.js +1 -1
  32. package/dist/models/index.d.ts +1 -0
  33. package/dist/models/index.js +1 -0
  34. package/dist/models/target-asset.d.ts +4 -2
  35. package/dist/models/trading-cancel-user-account-order-request.d.ts +24 -0
  36. package/dist/models/trading-cancel-user-account-order-request.js +15 -0
  37. package/docs/AccountInformationApi.md +72 -88
  38. package/docs/ApiDisclaimerApi.md +8 -12
  39. package/docs/ApiStatusApi.md +6 -7
  40. package/docs/AuthenticationApi.md +34 -48
  41. package/docs/ConnectionsApi.md +26 -32
  42. package/docs/ErrorLogsApi.md +8 -10
  43. package/docs/OptionsApi.md +55 -62
  44. package/docs/PortfolioManagementApi.md +229 -309
  45. package/docs/ReferenceDataApi.md +66 -93
  46. package/docs/TradingApi.md +88 -117
  47. package/docs/TransactionsAndReportingApi.md +26 -28
  48. package/index.test.ts +2 -4
  49. package/models/index.ts +1 -0
  50. package/models/target-asset.ts +2 -2
  51. package/models/trading-cancel-user-account-order-request.ts +29 -0
  52. package/package.json +1 -1
@@ -8,8 +8,10 @@ Method | HTTP request | Description
8
8
 
9
9
 
10
10
  # **check**
11
- > Status check()
12
11
 
12
+ #### **GET** /
13
+
14
+ ### Description
13
15
  Check whether the API is operational and verify timestamps.
14
16
 
15
17
  ### Example
@@ -25,8 +27,9 @@ const snaptrade = new Snaptrade({
25
27
  clientId: "YOUR_CLIENT_ID",
26
28
  })
27
29
 
28
- const response = await snaptrade.apiStatus.check()
29
- console.log(response)
30
+ const checkResponse = await snaptrade.apiStatus.check()
31
+
32
+ console.log(checkResponse)
30
33
 
31
34
  ```
32
35
 
@@ -39,10 +42,6 @@ This endpoint does not need any parameter.
39
42
 
40
43
  **Status**
41
44
 
42
- ### Authorization
43
-
44
- No authorization required
45
-
46
45
  ### HTTP request headers
47
46
 
48
47
  - **Content-Type**: Not defined
@@ -12,7 +12,8 @@ Method | HTTP request | Description
12
12
 
13
13
 
14
14
  # **deleteSnapTradeUser**
15
- > DeleteUserResponse deleteSnapTradeUser()
15
+
16
+ #### **DELETE** /snapTrade/deleteUser
16
17
 
17
18
 
18
19
  ### Example
@@ -28,10 +29,11 @@ const snaptrade = new Snaptrade({
28
29
  clientId: "YOUR_CLIENT_ID",
29
30
  })
30
31
 
31
- const response = await snaptrade.authentication.deleteSnapTradeUser({
32
- 'userId': "John.doe@snaptrade.com",
33
- })
34
- console.log(response)
32
+ const deleteSnapTradeUserResponse = await snaptrade.authentication.deleteSnapTradeUser({
33
+ "userId": "John.doe@snaptrade.com",
34
+ })
35
+
36
+ console.log(deleteSnapTradeUserResponse)
35
37
 
36
38
  ```
37
39
 
@@ -47,10 +49,6 @@ Name | Type | Description | Notes
47
49
 
48
50
  **DeleteUserResponse**
49
51
 
50
- ### Authorization
51
-
52
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
53
-
54
52
  ### HTTP request headers
55
53
 
56
54
  - **Content-Type**: Not defined
@@ -69,7 +67,8 @@ Name | Type | Description | Notes
69
67
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
70
68
 
71
69
  # **getUserJWT**
72
- > EncryptedResponse getUserJWT()
70
+
71
+ #### **GET** /snapTrade/encryptedJWT
73
72
 
74
73
 
75
74
  ### Example
@@ -85,11 +84,12 @@ const snaptrade = new Snaptrade({
85
84
  clientId: "YOUR_CLIENT_ID",
86
85
  })
87
86
 
88
- const response = await snaptrade.authentication.getUserJWT({
89
- 'userId': "John.doe@snaptrade.com",
90
- 'userSecret': "USERSECRET123",
91
- })
92
- console.log(response)
87
+ const getUserJWTResponse = await snaptrade.authentication.getUserJWT({
88
+ "userId": "John.doe@snaptrade.com",
89
+ "userSecret": "USERSECRET123",
90
+ })
91
+
92
+ console.log(getUserJWTResponse)
93
93
 
94
94
  ```
95
95
 
@@ -106,10 +106,6 @@ Name | Type | Description | Notes
106
106
 
107
107
  **EncryptedResponse**
108
108
 
109
- ### Authorization
110
-
111
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
112
-
113
109
  ### HTTP request headers
114
110
 
115
111
  - **Content-Type**: Not defined
@@ -128,7 +124,8 @@ Name | Type | Description | Notes
128
124
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
129
125
 
130
126
  # **listSnapTradeUsers**
131
- > Array<string> listSnapTradeUsers()
127
+
128
+ #### **GET** /snapTrade/listUsers
132
129
 
133
130
 
134
131
  ### Example
@@ -144,8 +141,9 @@ const snaptrade = new Snaptrade({
144
141
  clientId: "YOUR_CLIENT_ID",
145
142
  })
146
143
 
147
- const response = await snaptrade.authentication.listSnapTradeUsers()
148
- console.log(response)
144
+ const listSnapTradeUsersResponse = await snaptrade.authentication.listSnapTradeUsers()
145
+
146
+ console.log(listSnapTradeUsersResponse)
149
147
 
150
148
  ```
151
149
 
@@ -158,10 +156,6 @@ This endpoint does not need any parameter.
158
156
 
159
157
  **Array<string>**
160
158
 
161
- ### Authorization
162
-
163
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
164
-
165
159
  ### HTTP request headers
166
160
 
167
161
  - **Content-Type**: Not defined
@@ -179,7 +173,8 @@ This endpoint does not need any parameter.
179
173
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
180
174
 
181
175
  # **loginSnapTradeUser**
182
- > AuthenticationLoginSnapTradeUser200Response loginSnapTradeUser()
176
+
177
+ #### **POST** /snapTrade/login
183
178
 
184
179
 
185
180
  ### Example
@@ -195,18 +190,17 @@ const snaptrade = new Snaptrade({
195
190
  clientId: "YOUR_CLIENT_ID",
196
191
  })
197
192
 
198
- const response = await snaptrade.authentication.loginSnapTradeUser({
199
- 'userId': "John.doe@snaptrade.com",
200
- 'userSecret': "USERSECRET123",
201
- 'requestBody': {
193
+ const loginSnapTradeUserResponse = await snaptrade.authentication.loginSnapTradeUser({
194
+ "userId": "John.doe@snaptrade.com",
195
+ "userSecret": "USERSECRET123",
202
196
  "broker": "ALPACA",
203
197
  "immediate_redirect": true,
204
198
  "custom_redirect": "https://passiv.com",
205
199
  "reconnect": "8b5f262d-4bb9-365d-888a-202bd3b15fa1",
206
200
  "connection_type": "read",
207
- },
208
- })
209
- console.log(response)
201
+ })
202
+
203
+ console.log(loginSnapTradeUserResponse)
210
204
 
211
205
  ```
212
206
 
@@ -224,10 +218,6 @@ Name | Type | Description | Notes
224
218
 
225
219
  **AuthenticationLoginSnapTradeUser200Response**
226
220
 
227
- ### Authorization
228
-
229
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
230
-
231
221
  ### HTTP request headers
232
222
 
233
223
  - **Content-Type**: application/json
@@ -246,7 +236,8 @@ Name | Type | Description | Notes
246
236
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
247
237
 
248
238
  # **registerSnapTradeUser**
249
- > UserIDandSecret registerSnapTradeUser(snapTradeRegisterUserRequestBody)
239
+
240
+ #### **POST** /snapTrade/registerUser
250
241
 
251
242
 
252
243
  ### Example
@@ -262,13 +253,12 @@ const snaptrade = new Snaptrade({
262
253
  clientId: "YOUR_CLIENT_ID",
263
254
  })
264
255
 
265
- const response = await snaptrade.authentication.registerSnapTradeUser({
266
- 'requestBody': {
256
+ const registerSnapTradeUserResponse = await snaptrade.authentication.registerSnapTradeUser({
267
257
  "user_id": "snaptrade-user-123",
268
258
  "rsa_public_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAAAgQC7vbqajDw4o6gJy8UtmIbkcpnkO3Kwc4qsEnSZp/TR+fQi62F79RHWmwKOtFmwteURgLbj7D/WGuNLGOfa/2vse3G2eHnHl5CB8ruRX9fBl/KgwCVr2JaEuUm66bBQeP5XeBotdR4cvX38uPYivCDdPjJ1QWPdspTBKcxeFbccDw==",
269
- },
270
- })
271
- console.log(response)
259
+ })
260
+
261
+ console.log(registerSnapTradeUserResponse)
272
262
 
273
263
  ```
274
264
 
@@ -284,10 +274,6 @@ Name | Type | Description | Notes
284
274
 
285
275
  **UserIDandSecret**
286
276
 
287
- ### Authorization
288
-
289
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
290
-
291
277
  ### HTTP request headers
292
278
 
293
279
  - **Content-Type**: application/json
@@ -10,7 +10,8 @@ Method | HTTP request | Description
10
10
 
11
11
 
12
12
  # **detailBrokerageAuthorization**
13
- > BrokerageAuthorization detailBrokerageAuthorization()
13
+
14
+ #### **GET** /authorizations/{authorizationId}
14
15
 
15
16
 
16
17
  ### Example
@@ -26,12 +27,13 @@ const snaptrade = new Snaptrade({
26
27
  clientId: "YOUR_CLIENT_ID",
27
28
  })
28
29
 
29
- const response = await snaptrade.connections.detailBrokerageAuthorization({
30
- 'authorizationId': "2bcd7cc3-e922-4976-bce1-9858296801c3",
31
- 'userId': "John.doe@snaptrade.com",
32
- 'userSecret': "USERSECRET123",
33
- })
34
- console.log(response)
30
+ const detailBrokerageAuthorizationResponse = await snaptrade.connections.detailBrokerageAuthorization({
31
+ "authorizationId": "2bcd7cc3-e922-4976-bce1-9858296801c3",
32
+ "userId": "John.doe@snaptrade.com",
33
+ "userSecret": "USERSECRET123",
34
+ })
35
+
36
+ console.log(detailBrokerageAuthorizationResponse)
35
37
 
36
38
  ```
37
39
 
@@ -49,10 +51,6 @@ Name | Type | Description | Notes
49
51
 
50
52
  **BrokerageAuthorization**
51
53
 
52
- ### Authorization
53
-
54
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
55
-
56
54
  ### HTTP request headers
57
55
 
58
56
  - **Content-Type**: Not defined
@@ -68,7 +66,8 @@ Name | Type | Description | Notes
68
66
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
69
67
 
70
68
  # **listBrokerageAuthorizations**
71
- > Array<BrokerageAuthorization> listBrokerageAuthorizations()
69
+
70
+ #### **GET** /authorizations
72
71
 
73
72
 
74
73
  ### Example
@@ -84,11 +83,12 @@ const snaptrade = new Snaptrade({
84
83
  clientId: "YOUR_CLIENT_ID",
85
84
  })
86
85
 
87
- const response = await snaptrade.connections.listBrokerageAuthorizations({
88
- 'userId': "John.doe@snaptrade.com",
89
- 'userSecret': "USERSECRET123",
90
- })
91
- console.log(response)
86
+ const listBrokerageAuthorizationsResponse = await snaptrade.connections.listBrokerageAuthorizations({
87
+ "userId": "John.doe@snaptrade.com",
88
+ "userSecret": "USERSECRET123",
89
+ })
90
+
91
+ console.log(listBrokerageAuthorizationsResponse)
92
92
 
93
93
  ```
94
94
 
@@ -105,10 +105,6 @@ Name | Type | Description | Notes
105
105
 
106
106
  **Array<BrokerageAuthorization>**
107
107
 
108
- ### Authorization
109
-
110
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
111
-
112
108
  ### HTTP request headers
113
109
 
114
110
  - **Content-Type**: Not defined
@@ -124,7 +120,8 @@ Name | Type | Description | Notes
124
120
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
125
121
 
126
122
  # **removeBrokerageAuthorization**
127
- > removeBrokerageAuthorization()
123
+
124
+ #### **DELETE** /authorizations/{authorizationId}
128
125
 
129
126
 
130
127
  ### Example
@@ -140,12 +137,13 @@ const snaptrade = new Snaptrade({
140
137
  clientId: "YOUR_CLIENT_ID",
141
138
  })
142
139
 
143
- const response = await snaptrade.connections.removeBrokerageAuthorization({
144
- 'authorizationId': "2bcd7cc3-e922-4976-bce1-9858296801c3",
145
- 'userId': "John.doe@snaptrade.com",
146
- 'userSecret': "USERSECRET123",
147
- })
148
- console.log(response)
140
+ const removeBrokerageAuthorizationResponse = await snaptrade.connections.removeBrokerageAuthorization({
141
+ "authorizationId": "2bcd7cc3-e922-4976-bce1-9858296801c3",
142
+ "userId": "John.doe@snaptrade.com",
143
+ "userSecret": "USERSECRET123",
144
+ })
145
+
146
+ console.log(removeBrokerageAuthorizationResponse)
149
147
 
150
148
  ```
151
149
 
@@ -163,10 +161,6 @@ Name | Type | Description | Notes
163
161
 
164
162
  void (empty response body)
165
163
 
166
- ### Authorization
167
-
168
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
169
-
170
164
  ### HTTP request headers
171
165
 
172
166
  - **Content-Type**: Not defined
@@ -8,7 +8,8 @@ Method | HTTP request | Description
8
8
 
9
9
 
10
10
  # **listUserErrors**
11
- > Array<UserErrorLog> listUserErrors()
11
+
12
+ #### **GET** /snapTrade/listUserErrors
12
13
 
13
14
 
14
15
  ### Example
@@ -24,11 +25,12 @@ const snaptrade = new Snaptrade({
24
25
  clientId: "YOUR_CLIENT_ID",
25
26
  })
26
27
 
27
- const response = await snaptrade.errorLogs.listUserErrors({
28
- 'userId': "John.doe@snaptrade.com",
29
- 'userSecret': "USERSECRET123",
30
- })
31
- console.log(response)
28
+ const listUserErrorsResponse = await snaptrade.errorLogs.listUserErrors({
29
+ "userId": "John.doe@snaptrade.com",
30
+ "userSecret": "USERSECRET123",
31
+ })
32
+
33
+ console.log(listUserErrorsResponse)
32
34
 
33
35
  ```
34
36
 
@@ -45,10 +47,6 @@ Name | Type | Description | Notes
45
47
 
46
48
  **Array<UserErrorLog>**
47
49
 
48
- ### Authorization
49
-
50
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
51
-
52
50
  ### HTTP request headers
53
51
 
54
52
  - **Content-Type**: Not defined
@@ -12,7 +12,8 @@ Method | HTTP request | Description
12
12
 
13
13
 
14
14
  # **getOptionStrategy**
15
- > StrategyQuotes getOptionStrategy(optionsGetOptionStrategyRequest)
15
+
16
+ #### **POST** /accounts/{accountId}/optionStrategy
16
17
 
17
18
 
18
19
  ### Example
@@ -28,16 +29,22 @@ const snaptrade = new Snaptrade({
28
29
  clientId: "YOUR_CLIENT_ID",
29
30
  })
30
31
 
31
- const response = await snaptrade.options.getOptionStrategy({
32
- 'userId': "John.doe@snaptrade.com",
33
- 'userSecret': "USERSECRET123",
34
- 'accountId': "accountId_example",
35
- 'requestBody': {
32
+ const getOptionStrategyResponse = await snaptrade.options.getOptionStrategy({
33
+ "userId": "John.doe@snaptrade.com",
34
+ "userSecret": "USERSECRET123",
35
+ "accountId": "accountId_example",
36
36
  "underlying_symbol_id": "2bcd7cc3-e922-4976-bce1-9858296801c3",
37
+ "legs": [
38
+ {
39
+ "action": "BUY_TO_OPEN",
40
+ "option_symbol_id": "SPY220819P00200000",
41
+ "quantity": 1,
42
+ }
43
+ ],
37
44
  "strategy_type": "CUSTOM",
38
- },
39
- })
40
- console.log(response)
45
+ })
46
+
47
+ console.log(getOptionStrategyResponse)
41
48
 
42
49
  ```
43
50
 
@@ -56,10 +63,6 @@ Name | Type | Description | Notes
56
63
 
57
64
  **StrategyQuotes**
58
65
 
59
- ### Authorization
60
-
61
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
62
-
63
66
  ### HTTP request headers
64
67
 
65
68
  - **Content-Type**: application/json
@@ -75,7 +78,8 @@ Name | Type | Description | Notes
75
78
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
76
79
 
77
80
  # **getOptionsChain**
78
- > Array<OptionChainInner> getOptionsChain()
81
+
82
+ #### **GET** /accounts/{accountId}/optionsChain
79
83
 
80
84
 
81
85
  ### Example
@@ -91,13 +95,14 @@ const snaptrade = new Snaptrade({
91
95
  clientId: "YOUR_CLIENT_ID",
92
96
  })
93
97
 
94
- const response = await snaptrade.options.getOptionsChain({
95
- 'userId': "John.doe@snaptrade.com",
96
- 'userSecret': "USERSECRET123",
97
- 'accountId': "accountId_example",
98
- 'symbol': "symbol_example",
99
- })
100
- console.log(response)
98
+ const getOptionsChainResponse = await snaptrade.options.getOptionsChain({
99
+ "userId": "John.doe@snaptrade.com",
100
+ "userSecret": "USERSECRET123",
101
+ "accountId": "accountId_example",
102
+ "symbol": "symbol_example",
103
+ })
104
+
105
+ console.log(getOptionsChainResponse)
101
106
 
102
107
  ```
103
108
 
@@ -116,10 +121,6 @@ Name | Type | Description | Notes
116
121
 
117
122
  **Array<OptionChainInner>**
118
123
 
119
- ### Authorization
120
-
121
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
122
-
123
124
  ### HTTP request headers
124
125
 
125
126
  - **Content-Type**: Not defined
@@ -135,7 +136,8 @@ Name | Type | Description | Notes
135
136
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
136
137
 
137
138
  # **getOptionsStrategyQuote**
138
- > StrategyQuotes getOptionsStrategyQuote()
139
+
140
+ #### **GET** /accounts/{accountId}/optionStrategy/{optionStrategyId}
139
141
 
140
142
 
141
143
  ### Example
@@ -151,13 +153,14 @@ const snaptrade = new Snaptrade({
151
153
  clientId: "YOUR_CLIENT_ID",
152
154
  })
153
155
 
154
- const response = await snaptrade.options.getOptionsStrategyQuote({
155
- 'userId': "John.doe@snaptrade.com",
156
- 'userSecret': "USERSECRET123",
157
- 'accountId': "accountId_example",
158
- 'optionStrategyId': "2bcd7cc3-e922-4976-bce1-9858296801c3",
159
- })
160
- console.log(response)
156
+ const getOptionsStrategyQuoteResponse = await snaptrade.options.getOptionsStrategyQuote({
157
+ "userId": "John.doe@snaptrade.com",
158
+ "userSecret": "USERSECRET123",
159
+ "accountId": "accountId_example",
160
+ "optionStrategyId": "2bcd7cc3-e922-4976-bce1-9858296801c3",
161
+ })
162
+
163
+ console.log(getOptionsStrategyQuoteResponse)
161
164
 
162
165
  ```
163
166
 
@@ -176,10 +179,6 @@ Name | Type | Description | Notes
176
179
 
177
180
  **StrategyQuotes**
178
181
 
179
- ### Authorization
180
-
181
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
182
-
183
182
  ### HTTP request headers
184
183
 
185
184
  - **Content-Type**: Not defined
@@ -195,7 +194,8 @@ Name | Type | Description | Notes
195
194
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
196
195
 
197
196
  # **listOptionHoldings**
198
- > OptionsHoldings listOptionHoldings()
197
+
198
+ #### **GET** /accounts/{accountId}/options
199
199
 
200
200
 
201
201
  ### Example
@@ -211,12 +211,13 @@ const snaptrade = new Snaptrade({
211
211
  clientId: "YOUR_CLIENT_ID",
212
212
  })
213
213
 
214
- const response = await snaptrade.options.listOptionHoldings({
215
- 'userId': "John.doe@snaptrade.com",
216
- 'userSecret': "USERSECRET123",
217
- 'accountId': "accountId_example",
218
- })
219
- console.log(response)
214
+ const listOptionHoldingsResponse = await snaptrade.options.listOptionHoldings({
215
+ "userId": "John.doe@snaptrade.com",
216
+ "userSecret": "USERSECRET123",
217
+ "accountId": "accountId_example",
218
+ })
219
+
220
+ console.log(listOptionHoldingsResponse)
220
221
 
221
222
  ```
222
223
 
@@ -234,10 +235,6 @@ Name | Type | Description | Notes
234
235
 
235
236
  **OptionsHoldings**
236
237
 
237
- ### Authorization
238
-
239
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
240
-
241
238
  ### HTTP request headers
242
239
 
243
240
  - **Content-Type**: Not defined
@@ -253,7 +250,8 @@ Name | Type | Description | Notes
253
250
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
254
251
 
255
252
  # **placeOptionStrategy**
256
- > StrategyOrderRecord placeOptionStrategy(optionsPlaceOptionStrategyRequest)
253
+
254
+ #### **POST** /accounts/{accountId}/optionStrategy/{optionStrategyId}/execute
257
255
 
258
256
 
259
257
  ### Example
@@ -269,18 +267,17 @@ const snaptrade = new Snaptrade({
269
267
  clientId: "YOUR_CLIENT_ID",
270
268
  })
271
269
 
272
- const response = await snaptrade.options.placeOptionStrategy({
273
- 'userId': "John.doe@snaptrade.com",
274
- 'userSecret': "USERSECRET123",
275
- 'accountId': "2bcd7cc3-e922-4976-bce1-9858296801c3",
276
- 'optionStrategyId': "2bcd7cc3-e922-4976-bce1-9858296801c3",
277
- 'requestBody': {
270
+ const placeOptionStrategyResponse = await snaptrade.options.placeOptionStrategy({
271
+ "userId": "John.doe@snaptrade.com",
272
+ "userSecret": "USERSECRET123",
273
+ "accountId": "2bcd7cc3-e922-4976-bce1-9858296801c3",
274
+ "optionStrategyId": "2bcd7cc3-e922-4976-bce1-9858296801c3",
278
275
  "order_type": "Limit",
279
276
  "time_in_force": "DAY",
280
277
  "price": 31.33,
281
- },
282
- })
283
- console.log(response)
278
+ })
279
+
280
+ console.log(placeOptionStrategyResponse)
284
281
 
285
282
  ```
286
283
 
@@ -300,10 +297,6 @@ Name | Type | Description | Notes
300
297
 
301
298
  **StrategyOrderRecord**
302
299
 
303
- ### Authorization
304
-
305
- [PartnerClientId](README.md#PartnerClientId), [PartnerSignature](README.md#PartnerSignature), [PartnerTimestamp](README.md#PartnerTimestamp)
306
-
307
300
  ### HTTP request headers
308
301
 
309
302
  - **Content-Type**: application/json