snaptrade 1.16.3 → 1.17.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +5 -5
- data/docs/AccountHoldings.md +2 -2
- data/docs/AccountHoldingsAccount.md +2 -2
- data/docs/AccountInformationApi.md +64 -64
- data/docs/AccountOrderRecord.md +2 -2
- data/docs/AuthenticationApi.md +32 -32
- data/docs/Balance.md +1 -1
- data/docs/Brokerage.md +1 -1
- data/docs/BrokerageAuthorization.md +1 -1
- data/docs/BrokerageAuthorizationTypeReadOnly.md +1 -1
- data/docs/BrokerageSymbol.md +1 -1
- data/docs/BrokerageSymbolOptionSymbol.md +1 -1
- data/docs/BrokerageSymbolSymbol.md +7 -7
- data/docs/ConnectionsApi.md +30 -30
- data/docs/EncryptedResponse.md +1 -1
- data/docs/ErrorLogsApi.md +6 -6
- data/docs/ExchangeRatePairs.md +2 -2
- data/docs/ExcludedAsset.md +1 -1
- data/docs/ManualTrade.md +1 -1
- data/docs/ManualTradeAndImpact.md +2 -2
- data/docs/ManualTradeBalance.md +2 -2
- data/docs/ManualTradeSymbol.md +1 -1
- data/docs/ModelAssetClassDetails.md +1 -1
- data/docs/ModelAssetClassTarget.md +1 -1
- data/docs/ModelPortfolioAssetClass.md +1 -1
- data/docs/ModelPortfolioDetails.md +1 -1
- data/docs/ModelPortfolioSecurity.md +1 -1
- data/docs/NetDividend.md +1 -1
- data/docs/OptionStrategy.md +1 -1
- data/docs/OptionsApi.md +58 -58
- data/docs/OptionsHoldings.md +2 -2
- data/docs/OptionsPosition.md +1 -1
- data/docs/OptionsSymbol.md +1 -1
- data/docs/PerformanceCustom.md +1 -1
- data/docs/PortfolioGroupInfo.md +1 -1
- data/docs/PortfolioGroupPosition.md +1 -1
- data/docs/PortfolioGroupSettings.md +1 -1
- data/docs/Position.md +1 -1
- data/docs/PositionSymbol.md +1 -1
- data/docs/ReferenceDataApi.md +28 -28
- data/docs/SnapTradeHoldingsAccount.md +1 -1
- data/docs/StrategyOrderRecord.md +1 -1
- data/docs/StrategyQuotes.md +2 -2
- data/docs/Symbol.md +3 -3
- data/docs/SymbolsQuotesInner.md +1 -1
- data/docs/TargetAsset.md +1 -1
- data/docs/Trade.md +3 -3
- data/docs/TradeExecutionStatus.md +3 -3
- data/docs/TradeImpact.md +2 -2
- data/docs/TradingApi.md +84 -84
- data/docs/TransactionsAndReportingApi.md +32 -32
- data/docs/UnderlyingSymbol.md +3 -3
- data/docs/UniversalActivity.md +5 -5
- data/docs/UniversalSymbol.md +7 -7
- data/docs/UniversalSymbolTicker.md +3 -3
- data/docs/UserSettings.md +1 -1
- data/header.png +0 -0
- data/lib/snaptrade/api/account_information_api.rb +0 -16
- data/lib/snaptrade/api/api_status_api.rb +0 -2
- data/lib/snaptrade/api/authentication_api.rb +0 -10
- data/lib/snaptrade/api/connections_api.rb +0 -8
- data/lib/snaptrade/api/error_logs_api.rb +0 -2
- data/lib/snaptrade/api/options_api.rb +0 -10
- data/lib/snaptrade/api/reference_data_api.rb +0 -22
- data/lib/snaptrade/api/trading_api.rb +0 -12
- data/lib/snaptrade/api/transactions_and_reporting_api.rb +0 -4
- data/lib/snaptrade/api_client_custom.rb +1 -1
- data/lib/snaptrade/models/brokerage_symbol_symbol.rb +30 -0
- data/lib/snaptrade/models/universal_activity.rb +1 -1
- data/lib/snaptrade/models/universal_symbol.rb +30 -0
- data/lib/snaptrade/version.rb +1 -1
- metadata +3 -2
@@ -22,7 +22,6 @@ module SnapTrade
|
|
22
22
|
# @param user_id [String]
|
23
23
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
24
24
|
def delete_snap_trade_user(user_id:, extra: {})
|
25
|
-
|
26
25
|
data, _status_code, _headers = delete_snap_trade_user_with_http_info_impl(user_id, extra)
|
27
26
|
data
|
28
27
|
end
|
@@ -31,7 +30,6 @@ module SnapTrade
|
|
31
30
|
# @param user_id [String]
|
32
31
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
33
32
|
def delete_snap_trade_user_with_http_info(user_id:, extra: {})
|
34
|
-
|
35
33
|
delete_snap_trade_user_with_http_info_impl(user_id, extra)
|
36
34
|
end
|
37
35
|
|
@@ -103,7 +101,6 @@ module SnapTrade
|
|
103
101
|
# @param user_secret [String]
|
104
102
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
105
103
|
def get_user_jwt(user_id:, user_secret:, extra: {})
|
106
|
-
|
107
104
|
data, _status_code, _headers = get_user_jwt_with_http_info_impl(user_id, user_secret, extra)
|
108
105
|
data
|
109
106
|
end
|
@@ -113,7 +110,6 @@ module SnapTrade
|
|
113
110
|
# @param user_secret [String]
|
114
111
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
115
112
|
def get_user_jwt_with_http_info(user_id:, user_secret:, extra: {})
|
116
|
-
|
117
113
|
get_user_jwt_with_http_info_impl(user_id, user_secret, extra)
|
118
114
|
end
|
119
115
|
|
@@ -190,7 +186,6 @@ module SnapTrade
|
|
190
186
|
# List SnapTrade users
|
191
187
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
192
188
|
def list_snap_trade_users(extra: {})
|
193
|
-
|
194
189
|
data, _status_code, _headers = list_snap_trade_users_with_http_info_impl(extra)
|
195
190
|
data
|
196
191
|
end
|
@@ -198,7 +193,6 @@ module SnapTrade
|
|
198
193
|
# List SnapTrade users
|
199
194
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
200
195
|
def list_snap_trade_users_with_http_info(extra: {})
|
201
|
-
|
202
196
|
list_snap_trade_users_with_http_info_impl(extra)
|
203
197
|
end
|
204
198
|
|
@@ -276,7 +270,6 @@ module SnapTrade
|
|
276
270
|
_body[:reconnect] = reconnect if reconnect != SENTINEL
|
277
271
|
_body[:connectionType] = connection_type if connection_type != SENTINEL
|
278
272
|
extra[:snap_trade_login_user_request_body] = _body if !_body.empty?
|
279
|
-
|
280
273
|
data, _status_code, _headers = login_snap_trade_user_with_http_info_impl(user_id, user_secret, extra)
|
281
274
|
data
|
282
275
|
end
|
@@ -299,7 +292,6 @@ module SnapTrade
|
|
299
292
|
_body[:reconnect] = reconnect if reconnect != SENTINEL
|
300
293
|
_body[:connectionType] = connection_type if connection_type != SENTINEL
|
301
294
|
extra[:snap_trade_login_user_request_body] = _body if !_body.empty?
|
302
|
-
|
303
295
|
login_snap_trade_user_with_http_info_impl(user_id, user_secret, extra)
|
304
296
|
end
|
305
297
|
|
@@ -390,7 +382,6 @@ module SnapTrade
|
|
390
382
|
_body[:userId] = user_id if user_id != SENTINEL
|
391
383
|
_body[:rsaPublicKey] = rsa_public_key if rsa_public_key != SENTINEL
|
392
384
|
snap_trade_register_user_request_body = _body
|
393
|
-
|
394
385
|
data, _status_code, _headers = register_snap_trade_user_with_http_info_impl(snap_trade_register_user_request_body, extra)
|
395
386
|
data
|
396
387
|
end
|
@@ -405,7 +396,6 @@ module SnapTrade
|
|
405
396
|
_body[:userId] = user_id if user_id != SENTINEL
|
406
397
|
_body[:rsaPublicKey] = rsa_public_key if rsa_public_key != SENTINEL
|
407
398
|
snap_trade_register_user_request_body = _body
|
408
|
-
|
409
399
|
register_snap_trade_user_with_http_info_impl(snap_trade_register_user_request_body, extra)
|
410
400
|
end
|
411
401
|
|
@@ -24,7 +24,6 @@ module SnapTrade
|
|
24
24
|
# @param user_secret [String]
|
25
25
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
26
26
|
def detail_brokerage_authorization(authorization_id:, user_id:, user_secret:, extra: {})
|
27
|
-
|
28
27
|
data, _status_code, _headers = detail_brokerage_authorization_with_http_info_impl(authorization_id, user_id, user_secret, extra)
|
29
28
|
data
|
30
29
|
end
|
@@ -35,7 +34,6 @@ module SnapTrade
|
|
35
34
|
# @param user_secret [String]
|
36
35
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
37
36
|
def detail_brokerage_authorization_with_http_info(authorization_id:, user_id:, user_secret:, extra: {})
|
38
|
-
|
39
37
|
detail_brokerage_authorization_with_http_info_impl(authorization_id, user_id, user_secret, extra)
|
40
38
|
end
|
41
39
|
|
@@ -120,7 +118,6 @@ module SnapTrade
|
|
120
118
|
# @param user_secret [String]
|
121
119
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
122
120
|
def list_brokerage_authorizations(user_id:, user_secret:, extra: {})
|
123
|
-
|
124
121
|
data, _status_code, _headers = list_brokerage_authorizations_with_http_info_impl(user_id, user_secret, extra)
|
125
122
|
data
|
126
123
|
end
|
@@ -130,7 +127,6 @@ module SnapTrade
|
|
130
127
|
# @param user_secret [String]
|
131
128
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
132
129
|
def list_brokerage_authorizations_with_http_info(user_id:, user_secret:, extra: {})
|
133
|
-
|
134
130
|
list_brokerage_authorizations_with_http_info_impl(user_id, user_secret, extra)
|
135
131
|
end
|
136
132
|
|
@@ -210,7 +206,6 @@ module SnapTrade
|
|
210
206
|
# @param user_secret [String]
|
211
207
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
212
208
|
def remove_brokerage_authorization(authorization_id:, user_id:, user_secret:, extra: {})
|
213
|
-
|
214
209
|
remove_brokerage_authorization_with_http_info_impl(authorization_id, user_id, user_secret, extra)
|
215
210
|
nil
|
216
211
|
end
|
@@ -221,7 +216,6 @@ module SnapTrade
|
|
221
216
|
# @param user_secret [String]
|
222
217
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
223
218
|
def remove_brokerage_authorization_with_http_info(authorization_id:, user_id:, user_secret:, extra: {})
|
224
|
-
|
225
219
|
remove_brokerage_authorization_with_http_info_impl(authorization_id, user_id, user_secret, extra)
|
226
220
|
end
|
227
221
|
|
@@ -307,7 +301,6 @@ module SnapTrade
|
|
307
301
|
def session_events(partner_client_id:, user_id: SENTINEL, session_id: SENTINEL, extra: {})
|
308
302
|
extra[:user_id] = user_id if user_id != SENTINEL
|
309
303
|
extra[:session_id] = session_id if session_id != SENTINEL
|
310
|
-
|
311
304
|
data, _status_code, _headers = session_events_with_http_info_impl(partner_client_id, extra)
|
312
305
|
data
|
313
306
|
end
|
@@ -320,7 +313,6 @@ module SnapTrade
|
|
320
313
|
def session_events_with_http_info(partner_client_id:, user_id: SENTINEL, session_id: SENTINEL, extra: {})
|
321
314
|
extra[:user_id] = user_id if user_id != SENTINEL
|
322
315
|
extra[:session_id] = session_id if session_id != SENTINEL
|
323
|
-
|
324
316
|
session_events_with_http_info_impl(partner_client_id, extra)
|
325
317
|
end
|
326
318
|
|
@@ -23,7 +23,6 @@ module SnapTrade
|
|
23
23
|
# @param user_secret [String]
|
24
24
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
25
25
|
def list_user_errors(user_id:, user_secret:, extra: {})
|
26
|
-
|
27
26
|
data, _status_code, _headers = list_user_errors_with_http_info_impl(user_id, user_secret, extra)
|
28
27
|
data
|
29
28
|
end
|
@@ -33,7 +32,6 @@ module SnapTrade
|
|
33
32
|
# @param user_secret [String]
|
34
33
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
35
34
|
def list_user_errors_with_http_info(user_id:, user_secret:, extra: {})
|
36
|
-
|
37
35
|
list_user_errors_with_http_info_impl(user_id, user_secret, extra)
|
38
36
|
end
|
39
37
|
|
@@ -33,7 +33,6 @@ module SnapTrade
|
|
33
33
|
_body[:legs] = legs if legs != SENTINEL
|
34
34
|
_body[:strategy_type] = strategy_type if strategy_type != SENTINEL
|
35
35
|
options_get_option_strategy_request = _body
|
36
|
-
|
37
36
|
data, _status_code, _headers = get_option_strategy_with_http_info_impl(user_id, user_secret, account_id, options_get_option_strategy_request, extra)
|
38
37
|
data
|
39
38
|
end
|
@@ -53,7 +52,6 @@ module SnapTrade
|
|
53
52
|
_body[:legs] = legs if legs != SENTINEL
|
54
53
|
_body[:strategy_type] = strategy_type if strategy_type != SENTINEL
|
55
54
|
options_get_option_strategy_request = _body
|
56
|
-
|
57
55
|
get_option_strategy_with_http_info_impl(user_id, user_secret, account_id, options_get_option_strategy_request, extra)
|
58
56
|
end
|
59
57
|
|
@@ -151,7 +149,6 @@ module SnapTrade
|
|
151
149
|
# @param symbol [String] Universal symbol ID if symbol
|
152
150
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
153
151
|
def get_options_chain(user_id:, user_secret:, account_id:, symbol:, extra: {})
|
154
|
-
|
155
152
|
data, _status_code, _headers = get_options_chain_with_http_info_impl(user_id, user_secret, account_id, symbol, extra)
|
156
153
|
data
|
157
154
|
end
|
@@ -163,7 +160,6 @@ module SnapTrade
|
|
163
160
|
# @param symbol [String] Universal symbol ID if symbol
|
164
161
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
165
162
|
def get_options_chain_with_http_info(user_id:, user_secret:, account_id:, symbol:, extra: {})
|
166
|
-
|
167
163
|
get_options_chain_with_http_info_impl(user_id, user_secret, account_id, symbol, extra)
|
168
164
|
end
|
169
165
|
|
@@ -257,7 +253,6 @@ module SnapTrade
|
|
257
253
|
# @param option_strategy_id [String] Option strategy id obtained from response when creating option strategy object
|
258
254
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
259
255
|
def get_options_strategy_quote(user_id:, user_secret:, account_id:, option_strategy_id:, extra: {})
|
260
|
-
|
261
256
|
data, _status_code, _headers = get_options_strategy_quote_with_http_info_impl(user_id, user_secret, account_id, option_strategy_id, extra)
|
262
257
|
data
|
263
258
|
end
|
@@ -269,7 +264,6 @@ module SnapTrade
|
|
269
264
|
# @param option_strategy_id [String] Option strategy id obtained from response when creating option strategy object
|
270
265
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
271
266
|
def get_options_strategy_quote_with_http_info(user_id:, user_secret:, account_id:, option_strategy_id:, extra: {})
|
272
|
-
|
273
267
|
get_options_strategy_quote_with_http_info_impl(user_id, user_secret, account_id, option_strategy_id, extra)
|
274
268
|
end
|
275
269
|
|
@@ -361,7 +355,6 @@ module SnapTrade
|
|
361
355
|
# @param account_id [String] The ID of the account get positions.
|
362
356
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
363
357
|
def list_option_holdings(user_id:, user_secret:, account_id:, extra: {})
|
364
|
-
|
365
358
|
data, _status_code, _headers = list_option_holdings_with_http_info_impl(user_id, user_secret, account_id, extra)
|
366
359
|
data
|
367
360
|
end
|
@@ -372,7 +365,6 @@ module SnapTrade
|
|
372
365
|
# @param account_id [String] The ID of the account get positions.
|
373
366
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
374
367
|
def list_option_holdings_with_http_info(user_id:, user_secret:, account_id:, extra: {})
|
375
|
-
|
376
368
|
list_option_holdings_with_http_info_impl(user_id, user_secret, account_id, extra)
|
377
369
|
end
|
378
370
|
|
@@ -468,7 +460,6 @@ module SnapTrade
|
|
468
460
|
_body[:time_in_force] = time_in_force if time_in_force != SENTINEL
|
469
461
|
_body[:price] = price if price != SENTINEL
|
470
462
|
options_place_option_strategy_request = _body
|
471
|
-
|
472
463
|
data, _status_code, _headers = place_option_strategy_with_http_info_impl(user_id, user_secret, account_id, option_strategy_id, options_place_option_strategy_request, extra)
|
473
464
|
data
|
474
465
|
end
|
@@ -489,7 +480,6 @@ module SnapTrade
|
|
489
480
|
_body[:time_in_force] = time_in_force if time_in_force != SENTINEL
|
490
481
|
_body[:price] = price if price != SENTINEL
|
491
482
|
options_place_option_strategy_request = _body
|
492
|
-
|
493
483
|
place_option_strategy_with_http_info_impl(user_id, user_secret, account_id, option_strategy_id, options_place_option_strategy_request, extra)
|
494
484
|
end
|
495
485
|
|
@@ -22,7 +22,6 @@ module SnapTrade
|
|
22
22
|
# @param currency_pair [String] A currency pair based on currency code for example, {CAD-USD}
|
23
23
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
24
24
|
def get_currency_exchange_rate_pair(currency_pair:, extra: {})
|
25
|
-
|
26
25
|
data, _status_code, _headers = get_currency_exchange_rate_pair_with_http_info_impl(currency_pair, extra)
|
27
26
|
data
|
28
27
|
end
|
@@ -31,7 +30,6 @@ module SnapTrade
|
|
31
30
|
# @param currency_pair [String] A currency pair based on currency code for example, {CAD-USD}
|
32
31
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
33
32
|
def get_currency_exchange_rate_pair_with_http_info(currency_pair:, extra: {})
|
34
|
-
|
35
33
|
get_currency_exchange_rate_pair_with_http_info_impl(currency_pair, extra)
|
36
34
|
end
|
37
35
|
|
@@ -100,7 +98,6 @@ module SnapTrade
|
|
100
98
|
# Get metadata related to Snaptrade partner
|
101
99
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
102
100
|
def get_partner_info(extra: {})
|
103
|
-
|
104
101
|
data, _status_code, _headers = get_partner_info_with_http_info_impl(extra)
|
105
102
|
data
|
106
103
|
end
|
@@ -108,7 +105,6 @@ module SnapTrade
|
|
108
105
|
# Get metadata related to Snaptrade partner
|
109
106
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
110
107
|
def get_partner_info_with_http_info(extra: {})
|
111
|
-
|
112
108
|
get_partner_info_with_http_info_impl(extra)
|
113
109
|
end
|
114
110
|
|
@@ -171,7 +167,6 @@ module SnapTrade
|
|
171
167
|
# List of all security types.
|
172
168
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
173
169
|
def get_security_types(extra: {})
|
174
|
-
|
175
170
|
data, _status_code, _headers = get_security_types_with_http_info_impl(extra)
|
176
171
|
data
|
177
172
|
end
|
@@ -179,7 +174,6 @@ module SnapTrade
|
|
179
174
|
# List of all security types.
|
180
175
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
181
176
|
def get_security_types_with_http_info(extra: {})
|
182
|
-
|
183
177
|
get_security_types_with_http_info_impl(extra)
|
184
178
|
end
|
185
179
|
|
@@ -242,7 +236,6 @@ module SnapTrade
|
|
242
236
|
# List exchanges
|
243
237
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
244
238
|
def get_stock_exchanges(extra: {})
|
245
|
-
|
246
239
|
data, _status_code, _headers = get_stock_exchanges_with_http_info_impl(extra)
|
247
240
|
data
|
248
241
|
end
|
@@ -250,7 +243,6 @@ module SnapTrade
|
|
250
243
|
# List exchanges
|
251
244
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
252
245
|
def get_stock_exchanges_with_http_info(extra: {})
|
253
|
-
|
254
246
|
get_stock_exchanges_with_http_info_impl(extra)
|
255
247
|
end
|
256
248
|
|
@@ -318,7 +310,6 @@ module SnapTrade
|
|
318
310
|
_body = {}
|
319
311
|
_body[:substring] = substring if substring != SENTINEL
|
320
312
|
extra[:symbol_query] = _body if !_body.empty?
|
321
|
-
|
322
313
|
data, _status_code, _headers = get_symbols_with_http_info_impl(extra)
|
323
314
|
data
|
324
315
|
end
|
@@ -331,7 +322,6 @@ module SnapTrade
|
|
331
322
|
_body = {}
|
332
323
|
_body[:substring] = substring if substring != SENTINEL
|
333
324
|
extra[:symbol_query] = _body if !_body.empty?
|
334
|
-
|
335
325
|
get_symbols_with_http_info_impl(extra)
|
336
326
|
end
|
337
327
|
|
@@ -404,7 +394,6 @@ module SnapTrade
|
|
404
394
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
405
395
|
def get_symbols_by_ticker(ticker:, symbol_id: SENTINEL, extra: {})
|
406
396
|
extra[:symbol_id] = symbol_id if symbol_id != SENTINEL
|
407
|
-
|
408
397
|
data, _status_code, _headers = get_symbols_by_ticker_with_http_info_impl(ticker, extra)
|
409
398
|
data
|
410
399
|
end
|
@@ -415,7 +404,6 @@ module SnapTrade
|
|
415
404
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
416
405
|
def get_symbols_by_ticker_with_http_info(ticker:, symbol_id: SENTINEL, extra: {})
|
417
406
|
extra[:symbol_id] = symbol_id if symbol_id != SENTINEL
|
418
|
-
|
419
407
|
get_symbols_by_ticker_with_http_info_impl(ticker, extra)
|
420
408
|
end
|
421
409
|
|
@@ -489,7 +477,6 @@ module SnapTrade
|
|
489
477
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
490
478
|
def list_all_brokerage_authorization_type(brokerage: SENTINEL, extra: {})
|
491
479
|
extra[:brokerage] = brokerage if brokerage != SENTINEL
|
492
|
-
|
493
480
|
data, _status_code, _headers = list_all_brokerage_authorization_type_with_http_info_impl(extra)
|
494
481
|
data
|
495
482
|
end
|
@@ -499,7 +486,6 @@ module SnapTrade
|
|
499
486
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
500
487
|
def list_all_brokerage_authorization_type_with_http_info(brokerage: SENTINEL, extra: {})
|
501
488
|
extra[:brokerage] = brokerage if brokerage != SENTINEL
|
502
|
-
|
503
489
|
list_all_brokerage_authorization_type_with_http_info_impl(extra)
|
504
490
|
end
|
505
491
|
|
@@ -565,7 +551,6 @@ module SnapTrade
|
|
565
551
|
# List brokerages
|
566
552
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
567
553
|
def list_all_brokerages(extra: {})
|
568
|
-
|
569
554
|
data, _status_code, _headers = list_all_brokerages_with_http_info_impl(extra)
|
570
555
|
data
|
571
556
|
end
|
@@ -573,7 +558,6 @@ module SnapTrade
|
|
573
558
|
# List brokerages
|
574
559
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
575
560
|
def list_all_brokerages_with_http_info(extra: {})
|
576
|
-
|
577
561
|
list_all_brokerages_with_http_info_impl(extra)
|
578
562
|
end
|
579
563
|
|
@@ -636,7 +620,6 @@ module SnapTrade
|
|
636
620
|
# List currencies
|
637
621
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
638
622
|
def list_all_currencies(extra: {})
|
639
|
-
|
640
623
|
data, _status_code, _headers = list_all_currencies_with_http_info_impl(extra)
|
641
624
|
data
|
642
625
|
end
|
@@ -644,7 +627,6 @@ module SnapTrade
|
|
644
627
|
# List currencies
|
645
628
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
646
629
|
def list_all_currencies_with_http_info(extra: {})
|
647
|
-
|
648
630
|
list_all_currencies_with_http_info_impl(extra)
|
649
631
|
end
|
650
632
|
|
@@ -707,7 +689,6 @@ module SnapTrade
|
|
707
689
|
# List currency exchange rates
|
708
690
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
709
691
|
def list_all_currencies_rates(extra: {})
|
710
|
-
|
711
692
|
data, _status_code, _headers = list_all_currencies_rates_with_http_info_impl(extra)
|
712
693
|
data
|
713
694
|
end
|
@@ -715,7 +696,6 @@ module SnapTrade
|
|
715
696
|
# List currency exchange rates
|
716
697
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
717
698
|
def list_all_currencies_rates_with_http_info(extra: {})
|
718
|
-
|
719
699
|
list_all_currencies_rates_with_http_info_impl(extra)
|
720
700
|
end
|
721
701
|
|
@@ -786,7 +766,6 @@ module SnapTrade
|
|
786
766
|
_body = {}
|
787
767
|
_body[:substring] = substring if substring != SENTINEL
|
788
768
|
extra[:symbol_query] = _body if !_body.empty?
|
789
|
-
|
790
769
|
data, _status_code, _headers = symbol_search_user_account_with_http_info_impl(user_id, user_secret, account_id, extra)
|
791
770
|
data
|
792
771
|
end
|
@@ -802,7 +781,6 @@ module SnapTrade
|
|
802
781
|
_body = {}
|
803
782
|
_body[:substring] = substring if substring != SENTINEL
|
804
783
|
extra[:symbol_query] = _body if !_body.empty?
|
805
|
-
|
806
784
|
symbol_search_user_account_with_http_info_impl(user_id, user_secret, account_id, extra)
|
807
785
|
end
|
808
786
|
|
@@ -29,7 +29,6 @@ module SnapTrade
|
|
29
29
|
_body = {}
|
30
30
|
_body[:brokerage_order_id] = brokerage_order_id if brokerage_order_id != SENTINEL
|
31
31
|
trading_cancel_user_account_order_request = _body
|
32
|
-
|
33
32
|
data, _status_code, _headers = cancel_user_account_order_with_http_info_impl(user_id, user_secret, account_id, trading_cancel_user_account_order_request, extra)
|
34
33
|
data
|
35
34
|
end
|
@@ -45,7 +44,6 @@ module SnapTrade
|
|
45
44
|
_body = {}
|
46
45
|
_body[:brokerage_order_id] = brokerage_order_id if brokerage_order_id != SENTINEL
|
47
46
|
trading_cancel_user_account_order_request = _body
|
48
|
-
|
49
47
|
cancel_user_account_order_with_http_info_impl(user_id, user_secret, account_id, trading_cancel_user_account_order_request, extra)
|
50
48
|
end
|
51
49
|
|
@@ -160,7 +158,6 @@ module SnapTrade
|
|
160
158
|
_body[:units] = units if units != SENTINEL
|
161
159
|
_body[:universal_symbol_id] = universal_symbol_id if universal_symbol_id != SENTINEL
|
162
160
|
manual_trade_form = _body
|
163
|
-
|
164
161
|
data, _status_code, _headers = get_order_impact_with_http_info_impl(user_id, user_secret, manual_trade_form, extra)
|
165
162
|
data
|
166
163
|
end
|
@@ -189,7 +186,6 @@ module SnapTrade
|
|
189
186
|
_body[:units] = units if units != SENTINEL
|
190
187
|
_body[:universal_symbol_id] = universal_symbol_id if universal_symbol_id != SENTINEL
|
191
188
|
manual_trade_form = _body
|
192
|
-
|
193
189
|
get_order_impact_with_http_info_impl(user_id, user_secret, manual_trade_form, extra)
|
194
190
|
end
|
195
191
|
|
@@ -283,7 +279,6 @@ module SnapTrade
|
|
283
279
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
284
280
|
def get_user_account_quotes(user_id:, user_secret:, symbols:, account_id:, use_ticker: SENTINEL, extra: {})
|
285
281
|
extra[:use_ticker] = use_ticker if use_ticker != SENTINEL
|
286
|
-
|
287
282
|
data, _status_code, _headers = get_user_account_quotes_with_http_info_impl(user_id, user_secret, symbols, account_id, extra)
|
288
283
|
data
|
289
284
|
end
|
@@ -297,7 +292,6 @@ module SnapTrade
|
|
297
292
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
298
293
|
def get_user_account_quotes_with_http_info(user_id:, user_secret:, symbols:, account_id:, use_ticker: SENTINEL, extra: {})
|
299
294
|
extra[:use_ticker] = use_ticker if use_ticker != SENTINEL
|
300
|
-
|
301
295
|
get_user_account_quotes_with_http_info_impl(user_id, user_secret, symbols, account_id, extra)
|
302
296
|
end
|
303
297
|
|
@@ -411,7 +405,6 @@ module SnapTrade
|
|
411
405
|
_body[:units] = units if units != SENTINEL
|
412
406
|
_body[:universal_symbol_id] = universal_symbol_id if universal_symbol_id != SENTINEL
|
413
407
|
manual_trade_form = _body
|
414
|
-
|
415
408
|
data, _status_code, _headers = place_force_order_with_http_info_impl(user_id, user_secret, manual_trade_form, extra)
|
416
409
|
data
|
417
410
|
end
|
@@ -440,7 +433,6 @@ module SnapTrade
|
|
440
433
|
_body[:units] = units if units != SENTINEL
|
441
434
|
_body[:universal_symbol_id] = universal_symbol_id if universal_symbol_id != SENTINEL
|
442
435
|
manual_trade_form = _body
|
443
|
-
|
444
436
|
place_force_order_with_http_info_impl(user_id, user_secret, manual_trade_form, extra)
|
445
437
|
end
|
446
438
|
|
@@ -537,7 +529,6 @@ module SnapTrade
|
|
537
529
|
_body[:first_trade_id] = first_trade_id if first_trade_id != SENTINEL
|
538
530
|
_body[:second_trade_id] = second_trade_id if second_trade_id != SENTINEL
|
539
531
|
trading_place_oco_order_request = _body
|
540
|
-
|
541
532
|
data, _status_code, _headers = place_oco_order_with_http_info_impl(user_id, user_secret, trading_place_oco_order_request, extra)
|
542
533
|
data
|
543
534
|
end
|
@@ -554,7 +545,6 @@ module SnapTrade
|
|
554
545
|
_body[:first_trade_id] = first_trade_id if first_trade_id != SENTINEL
|
555
546
|
_body[:second_trade_id] = second_trade_id if second_trade_id != SENTINEL
|
556
547
|
trading_place_oco_order_request = _body
|
557
|
-
|
558
548
|
place_oco_order_with_http_info_impl(user_id, user_secret, trading_place_oco_order_request, extra)
|
559
549
|
end
|
560
550
|
|
@@ -645,7 +635,6 @@ module SnapTrade
|
|
645
635
|
# @param user_secret [String]
|
646
636
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
647
637
|
def place_order(trade_id:, user_id:, user_secret:, extra: {})
|
648
|
-
|
649
638
|
data, _status_code, _headers = place_order_with_http_info_impl(trade_id, user_id, user_secret, extra)
|
650
639
|
data
|
651
640
|
end
|
@@ -656,7 +645,6 @@ module SnapTrade
|
|
656
645
|
# @param user_secret [String]
|
657
646
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
658
647
|
def place_order_with_http_info(trade_id:, user_id:, user_secret:, extra: {})
|
659
|
-
|
660
648
|
place_order_with_http_info_impl(trade_id, user_id, user_secret, extra)
|
661
649
|
end
|
662
650
|
|
@@ -34,7 +34,6 @@ module SnapTrade
|
|
34
34
|
extra[:accounts] = accounts if accounts != SENTINEL
|
35
35
|
extra[:brokerage_authorizations] = brokerage_authorizations if brokerage_authorizations != SENTINEL
|
36
36
|
extra[:type] = type if type != SENTINEL
|
37
|
-
|
38
37
|
data, _status_code, _headers = get_activities_with_http_info_impl(user_id, user_secret, extra)
|
39
38
|
data
|
40
39
|
end
|
@@ -55,7 +54,6 @@ module SnapTrade
|
|
55
54
|
extra[:accounts] = accounts if accounts != SENTINEL
|
56
55
|
extra[:brokerage_authorizations] = brokerage_authorizations if brokerage_authorizations != SENTINEL
|
57
56
|
extra[:type] = type if type != SENTINEL
|
58
|
-
|
59
57
|
get_activities_with_http_info_impl(user_id, user_secret, extra)
|
60
58
|
end
|
61
59
|
|
@@ -160,7 +158,6 @@ module SnapTrade
|
|
160
158
|
extra[:accounts] = accounts if accounts != SENTINEL
|
161
159
|
extra[:detailed] = detailed if detailed != SENTINEL
|
162
160
|
extra[:frequency] = frequency if frequency != SENTINEL
|
163
|
-
|
164
161
|
data, _status_code, _headers = get_reporting_custom_range_with_http_info_impl(start_date, end_date, user_id, user_secret, extra)
|
165
162
|
data
|
166
163
|
end
|
@@ -179,7 +176,6 @@ module SnapTrade
|
|
179
176
|
extra[:accounts] = accounts if accounts != SENTINEL
|
180
177
|
extra[:detailed] = detailed if detailed != SENTINEL
|
181
178
|
extra[:frequency] = frequency if frequency != SENTINEL
|
182
|
-
|
183
179
|
get_reporting_custom_range_with_http_info_impl(start_date, end_date, user_id, user_secret, extra)
|
184
180
|
end
|
185
181
|
|
@@ -19,7 +19,7 @@ module SnapTrade
|
|
19
19
|
path = request.path[request.path.index('/api/v1/')..-1]
|
20
20
|
query = Faraday::Utils.build_query(request.params)
|
21
21
|
sig_object = {
|
22
|
-
"content" => request.body.nil? || request.body.empty? ? nil : JSON.parse(request.body),
|
22
|
+
"content" => request.body.nil? || request.body.empty? ? nil : Hash[JSON.parse(request.body).sort],
|
23
23
|
"path" => path,
|
24
24
|
"query" => query
|
25
25
|
}
|
@@ -130,12 +130,42 @@ module SnapTrade
|
|
130
130
|
# @return Array for valid properties with the reasons
|
131
131
|
def list_invalid_properties
|
132
132
|
invalid_properties = Array.new
|
133
|
+
if @id.nil?
|
134
|
+
invalid_properties.push('invalid value for "id", id cannot be nil.')
|
135
|
+
end
|
136
|
+
|
137
|
+
if @symbol.nil?
|
138
|
+
invalid_properties.push('invalid value for "symbol", symbol cannot be nil.')
|
139
|
+
end
|
140
|
+
|
141
|
+
if @raw_symbol.nil?
|
142
|
+
invalid_properties.push('invalid value for "raw_symbol", raw_symbol cannot be nil.')
|
143
|
+
end
|
144
|
+
|
145
|
+
if @currency.nil?
|
146
|
+
invalid_properties.push('invalid value for "currency", currency cannot be nil.')
|
147
|
+
end
|
148
|
+
|
149
|
+
if @type.nil?
|
150
|
+
invalid_properties.push('invalid value for "type", type cannot be nil.')
|
151
|
+
end
|
152
|
+
|
153
|
+
if @currencies.nil?
|
154
|
+
invalid_properties.push('invalid value for "currencies", currencies cannot be nil.')
|
155
|
+
end
|
156
|
+
|
133
157
|
invalid_properties
|
134
158
|
end
|
135
159
|
|
136
160
|
# Check to see if the all the properties in the model are valid
|
137
161
|
# @return true if the model is valid
|
138
162
|
def valid?
|
163
|
+
return false if @id.nil?
|
164
|
+
return false if @symbol.nil?
|
165
|
+
return false if @raw_symbol.nil?
|
166
|
+
return false if @currency.nil?
|
167
|
+
return false if @type.nil?
|
168
|
+
return false if @currencies.nil?
|
139
169
|
true
|
140
170
|
end
|
141
171
|
|
@@ -26,7 +26,7 @@ module SnapTrade
|
|
26
26
|
|
27
27
|
attr_accessor :fee
|
28
28
|
|
29
|
-
# The forex conversion rate involved in the transaction if provided by the brokerage
|
29
|
+
# The forex conversion rate involved in the transaction if provided by the brokerage. Used in cases where securities of one currency are purchased in a different currency, and the forex conversion is automatic. In those cases, price, amount and fee will be in the top level currency (activity -> currency)
|
30
30
|
attr_accessor :fx_rate
|
31
31
|
|
32
32
|
attr_accessor :institution
|
@@ -124,12 +124,42 @@ module SnapTrade
|
|
124
124
|
# @return Array for valid properties with the reasons
|
125
125
|
def list_invalid_properties
|
126
126
|
invalid_properties = Array.new
|
127
|
+
if @id.nil?
|
128
|
+
invalid_properties.push('invalid value for "id", id cannot be nil.')
|
129
|
+
end
|
130
|
+
|
131
|
+
if @symbol.nil?
|
132
|
+
invalid_properties.push('invalid value for "symbol", symbol cannot be nil.')
|
133
|
+
end
|
134
|
+
|
135
|
+
if @raw_symbol.nil?
|
136
|
+
invalid_properties.push('invalid value for "raw_symbol", raw_symbol cannot be nil.')
|
137
|
+
end
|
138
|
+
|
139
|
+
if @currency.nil?
|
140
|
+
invalid_properties.push('invalid value for "currency", currency cannot be nil.')
|
141
|
+
end
|
142
|
+
|
143
|
+
if @type.nil?
|
144
|
+
invalid_properties.push('invalid value for "type", type cannot be nil.')
|
145
|
+
end
|
146
|
+
|
147
|
+
if @currencies.nil?
|
148
|
+
invalid_properties.push('invalid value for "currencies", currencies cannot be nil.')
|
149
|
+
end
|
150
|
+
|
127
151
|
invalid_properties
|
128
152
|
end
|
129
153
|
|
130
154
|
# Check to see if the all the properties in the model are valid
|
131
155
|
# @return true if the model is valid
|
132
156
|
def valid?
|
157
|
+
return false if @id.nil?
|
158
|
+
return false if @symbol.nil?
|
159
|
+
return false if @raw_symbol.nil?
|
160
|
+
return false if @currency.nil?
|
161
|
+
return false if @type.nil?
|
162
|
+
return false if @currencies.nil?
|
133
163
|
true
|
134
164
|
end
|
135
165
|
|
data/lib/snaptrade/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: snaptrade
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.17.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- SnapTrade
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-10-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -219,6 +219,7 @@ files:
|
|
219
219
|
- docs/UserErrorLog.md
|
220
220
|
- docs/UserIDandSecret.md
|
221
221
|
- docs/UserSettings.md
|
222
|
+
- header.png
|
222
223
|
- lib/snaptrade.rb
|
223
224
|
- lib/snaptrade/api/account_information_api.rb
|
224
225
|
- lib/snaptrade/api/api_status_api.rb
|