snaptrade 2.0.17 → 2.0.18
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 +19 -14
- data/lib/snaptrade/api/connections_api.rb +4 -4
- data/lib/snaptrade/api/reference_data_api.rb +80 -28
- data/lib/snaptrade/api/trading_api.rb +24 -4
- data/lib/snaptrade/version.rb +1 -1
- data/spec/api/connections_api_spec.rb +1 -1
- data/spec/api/reference_data_api_spec.rb +15 -7
- data/spec/api/trading_api_spec.rb +4 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a363cc77c3f0d1064c2e6f173c15b0526b4a9e5a68bea6e38ef869c6377fd9ad
|
4
|
+
data.tar.gz: d2f7de1e5805be1d96d2f47d0263889abb5165576a0230d06704e9e223053afd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1711b6758368a02f9c7b247f9321aac58a7cfc0a1566da2cce4696b36887b352c63e341132395ef1f49e50432917a8ffa40eef197e4804441de448156c1fb6a0
|
7
|
+
data.tar.gz: d14162342db37f27e21f320f2ef837208895f274105642f13d13baf17ee2f9c87258515611a5e2d338452ae91a43e8c8a2cab18d00cb16e51f35063888abcdf2
|
data/Gemfile.lock
CHANGED
data/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
|
-
[![npm](https://img.shields.io/badge/gem-v2.0.
|
9
|
+
[![npm](https://img.shields.io/badge/gem-v2.0.18-blue)](https://rubygems.org/gems/snaptrade/versions/2.0.18)
|
10
10
|
[![More Info](https://img.shields.io/badge/More%20Info-Click%20Here-orange)](https://snaptrade.com/)
|
11
11
|
|
12
12
|
</div>
|
@@ -69,7 +69,7 @@ Connect brokerage accounts to your app for live positions and trading
|
|
69
69
|
Add to Gemfile:
|
70
70
|
|
71
71
|
```ruby
|
72
|
-
gem 'snaptrade', '~> 2.0.
|
72
|
+
gem 'snaptrade', '~> 2.0.18'
|
73
73
|
```
|
74
74
|
|
75
75
|
## Getting Started<a id="getting-started"></a>
|
@@ -676,7 +676,7 @@ The ID of a brokerage authorization object.
|
|
676
676
|
|
677
677
|
### `snaptrade.connections.list_brokerage_authorizations`<a id="snaptradeconnectionslist_brokerage_authorizations"></a>
|
678
678
|
|
679
|
-
Returns a list of Brokerage
|
679
|
+
Returns a list of Brokerage Authorization objects for the user
|
680
680
|
|
681
681
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
682
682
|
|
@@ -991,7 +991,7 @@ Trade Price if limit or stop limit order
|
|
991
991
|
|
992
992
|
### `snaptrade.reference_data.get_currency_exchange_rate_pair`<a id="snaptradereference_dataget_currency_exchange_rate_pair"></a>
|
993
993
|
|
994
|
-
|
994
|
+
Returns an Exchange Rate Pair object for the specified Currency Pair.
|
995
995
|
|
996
996
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
997
997
|
|
@@ -1070,7 +1070,7 @@ p result
|
|
1070
1070
|
|
1071
1071
|
### `snaptrade.reference_data.get_stock_exchanges`<a id="snaptradereference_dataget_stock_exchanges"></a>
|
1072
1072
|
|
1073
|
-
|
1073
|
+
Returns a list of all supported Exchanges.
|
1074
1074
|
|
1075
1075
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
1076
1076
|
|
@@ -1094,7 +1094,10 @@ p result
|
|
1094
1094
|
|
1095
1095
|
### `snaptrade.reference_data.get_symbols`<a id="snaptradereference_dataget_symbols"></a>
|
1096
1096
|
|
1097
|
-
|
1097
|
+
Returns a list of Universal Symbol objects that match a defined string.
|
1098
|
+
|
1099
|
+
Matches on ticker or name.
|
1100
|
+
|
1098
1101
|
|
1099
1102
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
1100
1103
|
|
@@ -1123,7 +1126,7 @@ p result
|
|
1123
1126
|
|
1124
1127
|
### `snaptrade.reference_data.get_symbols_by_ticker`<a id="snaptradereference_dataget_symbols_by_ticker"></a>
|
1125
1128
|
|
1126
|
-
|
1129
|
+
Returns the Universal Symbol object specified by the ticker or the universal_symbol_id.
|
1127
1130
|
|
1128
1131
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
1129
1132
|
|
@@ -1154,7 +1157,7 @@ The ticker or universal_symbol_id of the UniversalSymbol to get.
|
|
1154
1157
|
|
1155
1158
|
### `snaptrade.reference_data.list_all_brokerage_authorization_type`<a id="snaptradereference_datalist_all_brokerage_authorization_type"></a>
|
1156
1159
|
|
1157
|
-
|
1160
|
+
Returns a list of all defined Brokerage authorization Type objects.
|
1158
1161
|
|
1159
1162
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
1160
1163
|
|
@@ -1185,7 +1188,7 @@ Comma separated value of brokerage slugs
|
|
1185
1188
|
|
1186
1189
|
### `snaptrade.reference_data.list_all_brokerages`<a id="snaptradereference_datalist_all_brokerages"></a>
|
1187
1190
|
|
1188
|
-
|
1191
|
+
Returns a list of all defined Brokerage objects.
|
1189
1192
|
|
1190
1193
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
1191
1194
|
|
@@ -1209,7 +1212,7 @@ p result
|
|
1209
1212
|
|
1210
1213
|
### `snaptrade.reference_data.list_all_currencies`<a id="snaptradereference_datalist_all_currencies"></a>
|
1211
1214
|
|
1212
|
-
|
1215
|
+
Returns a list of all defined Currency objects.
|
1213
1216
|
|
1214
1217
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
1215
1218
|
|
@@ -1233,7 +1236,7 @@ p result
|
|
1233
1236
|
|
1234
1237
|
### `snaptrade.reference_data.list_all_currencies_rates`<a id="snaptradereference_datalist_all_currencies_rates"></a>
|
1235
1238
|
|
1236
|
-
|
1239
|
+
Returns a list of all Exchange Rate Pairs for all supported Currencies.
|
1237
1240
|
|
1238
1241
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
1239
1242
|
|
@@ -1336,7 +1339,7 @@ The ID of the account to cancel the order in.
|
|
1336
1339
|
|
1337
1340
|
### `snaptrade.trading.get_order_impact`<a id="snaptradetradingget_order_impact"></a>
|
1338
1341
|
|
1339
|
-
|
1342
|
+
Return the trade object and it's impact on the account for the specified order.
|
1340
1343
|
|
1341
1344
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
1342
1345
|
|
@@ -1439,7 +1442,7 @@ Should be set to True if providing tickers.
|
|
1439
1442
|
|
1440
1443
|
### `snaptrade.trading.place_force_order`<a id="snaptradetradingplace_force_order"></a>
|
1441
1444
|
|
1442
|
-
|
1445
|
+
Places a specified trade in the specified account.
|
1443
1446
|
|
1444
1447
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
1445
1448
|
|
@@ -1499,7 +1502,9 @@ Canceled
|
|
1499
1502
|
|
1500
1503
|
### `snaptrade.trading.place_order`<a id="snaptradetradingplace_order"></a>
|
1501
1504
|
|
1502
|
-
|
1505
|
+
Places the specified trade object. This places the order in the account and
|
1506
|
+
returns the status of the order from the brokerage.
|
1507
|
+
|
1503
1508
|
|
1504
1509
|
#### 🛠️ Usage<a id="🛠️-usage"></a>
|
1505
1510
|
|
@@ -122,7 +122,7 @@ module SnapTrade
|
|
122
122
|
|
123
123
|
# List all brokerage authorizations for the User
|
124
124
|
#
|
125
|
-
# Returns a list of Brokerage
|
125
|
+
# Returns a list of Brokerage Authorization objects for the user
|
126
126
|
#
|
127
127
|
# @param user_id [String]
|
128
128
|
# @param user_secret [String]
|
@@ -134,7 +134,7 @@ module SnapTrade
|
|
134
134
|
|
135
135
|
# List all brokerage authorizations for the User
|
136
136
|
#
|
137
|
-
# Returns a list of Brokerage
|
137
|
+
# Returns a list of Brokerage Authorization objects for the user
|
138
138
|
#
|
139
139
|
# @param user_id [String]
|
140
140
|
# @param user_secret [String]
|
@@ -144,7 +144,7 @@ module SnapTrade
|
|
144
144
|
end
|
145
145
|
|
146
146
|
# List all brokerage authorizations for the User
|
147
|
-
# Returns a list of Brokerage
|
147
|
+
# Returns a list of Brokerage Authorization objects for the user
|
148
148
|
# @param user_id [String]
|
149
149
|
# @param user_secret [String]
|
150
150
|
# @param [Hash] opts the optional parameters
|
@@ -155,7 +155,7 @@ module SnapTrade
|
|
155
155
|
end
|
156
156
|
|
157
157
|
# List all brokerage authorizations for the User
|
158
|
-
# Returns a list of Brokerage
|
158
|
+
# Returns a list of Brokerage Authorization objects for the user
|
159
159
|
# @param user_id [String]
|
160
160
|
# @param user_secret [String]
|
161
161
|
# @param [Hash] opts the optional parameters
|
@@ -17,7 +17,9 @@ module SnapTrade
|
|
17
17
|
@api_client = api_client
|
18
18
|
end
|
19
19
|
|
20
|
-
#
|
20
|
+
# Get exchange rate of a currency pair
|
21
|
+
#
|
22
|
+
# Returns an Exchange Rate Pair object for the specified Currency Pair.
|
21
23
|
#
|
22
24
|
# @param currency_pair [String] A currency pair based on currency code for example, {CAD-USD}
|
23
25
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
@@ -26,7 +28,9 @@ module SnapTrade
|
|
26
28
|
data
|
27
29
|
end
|
28
30
|
|
29
|
-
#
|
31
|
+
# Get exchange rate of a currency pair
|
32
|
+
#
|
33
|
+
# Returns an Exchange Rate Pair object for the specified Currency Pair.
|
30
34
|
#
|
31
35
|
# @param currency_pair [String] A currency pair based on currency code for example, {CAD-USD}
|
32
36
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
@@ -34,7 +38,8 @@ module SnapTrade
|
|
34
38
|
get_currency_exchange_rate_pair_with_http_info_impl(currency_pair, extra)
|
35
39
|
end
|
36
40
|
|
37
|
-
#
|
41
|
+
# Get exchange rate of a currency pair
|
42
|
+
# Returns an Exchange Rate Pair object for the specified Currency Pair.
|
38
43
|
# @param currency_pair [String] A currency pair based on currency code for example, {CAD-USD}
|
39
44
|
# @param [Hash] opts the optional parameters
|
40
45
|
# @return [ExchangeRatePairs]
|
@@ -43,7 +48,8 @@ module SnapTrade
|
|
43
48
|
data
|
44
49
|
end
|
45
50
|
|
46
|
-
#
|
51
|
+
# Get exchange rate of a currency pair
|
52
|
+
# Returns an Exchange Rate Pair object for the specified Currency Pair.
|
47
53
|
# @param currency_pair [String] A currency pair based on currency code for example, {CAD-USD}
|
48
54
|
# @param [Hash] opts the optional parameters
|
49
55
|
# @return [Array<(ExchangeRatePairs, Integer, Hash)>] ExchangeRatePairs data, response status code and response headers
|
@@ -250,7 +256,9 @@ module SnapTrade
|
|
250
256
|
end
|
251
257
|
|
252
258
|
|
253
|
-
#
|
259
|
+
# Get exchanges
|
260
|
+
#
|
261
|
+
# Returns a list of all supported Exchanges.
|
254
262
|
#
|
255
263
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
256
264
|
def get_stock_exchanges(extra: {})
|
@@ -258,14 +266,17 @@ module SnapTrade
|
|
258
266
|
data
|
259
267
|
end
|
260
268
|
|
261
|
-
#
|
269
|
+
# Get exchanges
|
270
|
+
#
|
271
|
+
# Returns a list of all supported Exchanges.
|
262
272
|
#
|
263
273
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
264
274
|
def get_stock_exchanges_with_http_info(extra: {})
|
265
275
|
get_stock_exchanges_with_http_info_impl(extra)
|
266
276
|
end
|
267
277
|
|
268
|
-
#
|
278
|
+
# Get exchanges
|
279
|
+
# Returns a list of all supported Exchanges.
|
269
280
|
# @param [Hash] opts the optional parameters
|
270
281
|
# @return [Array<Exchange>]
|
271
282
|
private def get_stock_exchanges_impl(opts = {})
|
@@ -273,7 +284,8 @@ module SnapTrade
|
|
273
284
|
data
|
274
285
|
end
|
275
286
|
|
276
|
-
#
|
287
|
+
# Get exchanges
|
288
|
+
# Returns a list of all supported Exchanges.
|
277
289
|
# @param [Hash] opts the optional parameters
|
278
290
|
# @return [Array<(Array<Exchange>, Integer, Hash)>] Array<Exchange> data, response status code and response headers
|
279
291
|
private def get_stock_exchanges_with_http_info_impl(opts = {})
|
@@ -323,6 +335,10 @@ module SnapTrade
|
|
323
335
|
|
324
336
|
# Search for symbols
|
325
337
|
#
|
338
|
+
# Returns a list of Universal Symbol objects that match a defined string.
|
339
|
+
#
|
340
|
+
# Matches on ticker or name.
|
341
|
+
#
|
326
342
|
# @param substring [String]
|
327
343
|
# @param body [SymbolQuery]
|
328
344
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
@@ -336,6 +352,10 @@ module SnapTrade
|
|
336
352
|
|
337
353
|
# Search for symbols
|
338
354
|
#
|
355
|
+
# Returns a list of Universal Symbol objects that match a defined string.
|
356
|
+
#
|
357
|
+
# Matches on ticker or name.
|
358
|
+
#
|
339
359
|
# @param substring [String]
|
340
360
|
# @param body [SymbolQuery]
|
341
361
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
@@ -347,6 +367,7 @@ module SnapTrade
|
|
347
367
|
end
|
348
368
|
|
349
369
|
# Search for symbols
|
370
|
+
# Returns a list of Universal Symbol objects that match a defined string. Matches on ticker or name.
|
350
371
|
# @param [Hash] opts the optional parameters
|
351
372
|
# @option opts [SymbolQuery] :symbol_query
|
352
373
|
# @return [Array<UniversalSymbol>]
|
@@ -356,6 +377,7 @@ module SnapTrade
|
|
356
377
|
end
|
357
378
|
|
358
379
|
# Search for symbols
|
380
|
+
# Returns a list of Universal Symbol objects that match a defined string. Matches on ticker or name.
|
359
381
|
# @param [Hash] opts the optional parameters
|
360
382
|
# @option opts [SymbolQuery] :symbol_query
|
361
383
|
# @return [Array<(Array<UniversalSymbol>, Integer, Hash)>] Array<UniversalSymbol> data, response status code and response headers
|
@@ -409,7 +431,9 @@ module SnapTrade
|
|
409
431
|
end
|
410
432
|
|
411
433
|
|
412
|
-
# Get details of a symbol
|
434
|
+
# Get details of a symbol
|
435
|
+
#
|
436
|
+
# Returns the Universal Symbol object specified by the ticker or the universal_symbol_id.
|
413
437
|
#
|
414
438
|
# @param query [String] The ticker or universal_symbol_id of the UniversalSymbol to get.
|
415
439
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
@@ -418,7 +442,9 @@ module SnapTrade
|
|
418
442
|
data
|
419
443
|
end
|
420
444
|
|
421
|
-
# Get details of a symbol
|
445
|
+
# Get details of a symbol
|
446
|
+
#
|
447
|
+
# Returns the Universal Symbol object specified by the ticker or the universal_symbol_id.
|
422
448
|
#
|
423
449
|
# @param query [String] The ticker or universal_symbol_id of the UniversalSymbol to get.
|
424
450
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
@@ -426,7 +452,8 @@ module SnapTrade
|
|
426
452
|
get_symbols_by_ticker_with_http_info_impl(query, extra)
|
427
453
|
end
|
428
454
|
|
429
|
-
# Get details of a symbol
|
455
|
+
# Get details of a symbol
|
456
|
+
# Returns the Universal Symbol object specified by the ticker or the universal_symbol_id.
|
430
457
|
# @param query [String] The ticker or universal_symbol_id of the UniversalSymbol to get.
|
431
458
|
# @param [Hash] opts the optional parameters
|
432
459
|
# @return [UniversalSymbol]
|
@@ -435,7 +462,8 @@ module SnapTrade
|
|
435
462
|
data
|
436
463
|
end
|
437
464
|
|
438
|
-
# Get details of a symbol
|
465
|
+
# Get details of a symbol
|
466
|
+
# Returns the Universal Symbol object specified by the ticker or the universal_symbol_id.
|
439
467
|
# @param query [String] The ticker or universal_symbol_id of the UniversalSymbol to get.
|
440
468
|
# @param [Hash] opts the optional parameters
|
441
469
|
# @return [Array<(UniversalSymbol, Integer, Hash)>] UniversalSymbol data, response status code and response headers
|
@@ -488,7 +516,9 @@ module SnapTrade
|
|
488
516
|
end
|
489
517
|
|
490
518
|
|
491
|
-
#
|
519
|
+
# Get all brokerage authorization types
|
520
|
+
#
|
521
|
+
# Returns a list of all defined Brokerage authorization Type objects.
|
492
522
|
#
|
493
523
|
# @param brokerage [String] Comma separated value of brokerage slugs
|
494
524
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
@@ -498,7 +528,9 @@ module SnapTrade
|
|
498
528
|
data
|
499
529
|
end
|
500
530
|
|
501
|
-
#
|
531
|
+
# Get all brokerage authorization types
|
532
|
+
#
|
533
|
+
# Returns a list of all defined Brokerage authorization Type objects.
|
502
534
|
#
|
503
535
|
# @param brokerage [String] Comma separated value of brokerage slugs
|
504
536
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
@@ -507,7 +539,8 @@ module SnapTrade
|
|
507
539
|
list_all_brokerage_authorization_type_with_http_info_impl(extra)
|
508
540
|
end
|
509
541
|
|
510
|
-
#
|
542
|
+
# Get all brokerage authorization types
|
543
|
+
# Returns a list of all defined Brokerage authorization Type objects.
|
511
544
|
# @param [Hash] opts the optional parameters
|
512
545
|
# @option opts [String] :brokerage Comma separated value of brokerage slugs
|
513
546
|
# @return [Array<BrokerageAuthorizationTypeReadOnly>]
|
@@ -516,7 +549,8 @@ module SnapTrade
|
|
516
549
|
data
|
517
550
|
end
|
518
551
|
|
519
|
-
#
|
552
|
+
# Get all brokerage authorization types
|
553
|
+
# Returns a list of all defined Brokerage authorization Type objects.
|
520
554
|
# @param [Hash] opts the optional parameters
|
521
555
|
# @option opts [String] :brokerage Comma separated value of brokerage slugs
|
522
556
|
# @return [Array<(Array<BrokerageAuthorizationTypeReadOnly>, Integer, Hash)>] Array<BrokerageAuthorizationTypeReadOnly> data, response status code and response headers
|
@@ -566,7 +600,9 @@ module SnapTrade
|
|
566
600
|
end
|
567
601
|
|
568
602
|
|
569
|
-
#
|
603
|
+
# Get brokerages
|
604
|
+
#
|
605
|
+
# Returns a list of all defined Brokerage objects.
|
570
606
|
#
|
571
607
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
572
608
|
def list_all_brokerages(extra: {})
|
@@ -574,14 +610,17 @@ module SnapTrade
|
|
574
610
|
data
|
575
611
|
end
|
576
612
|
|
577
|
-
#
|
613
|
+
# Get brokerages
|
614
|
+
#
|
615
|
+
# Returns a list of all defined Brokerage objects.
|
578
616
|
#
|
579
617
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
580
618
|
def list_all_brokerages_with_http_info(extra: {})
|
581
619
|
list_all_brokerages_with_http_info_impl(extra)
|
582
620
|
end
|
583
621
|
|
584
|
-
#
|
622
|
+
# Get brokerages
|
623
|
+
# Returns a list of all defined Brokerage objects.
|
585
624
|
# @param [Hash] opts the optional parameters
|
586
625
|
# @return [Array<Brokerage>]
|
587
626
|
private def list_all_brokerages_impl(opts = {})
|
@@ -589,7 +628,8 @@ module SnapTrade
|
|
589
628
|
data
|
590
629
|
end
|
591
630
|
|
592
|
-
#
|
631
|
+
# Get brokerages
|
632
|
+
# Returns a list of all defined Brokerage objects.
|
593
633
|
# @param [Hash] opts the optional parameters
|
594
634
|
# @return [Array<(Array<Brokerage>, Integer, Hash)>] Array<Brokerage> data, response status code and response headers
|
595
635
|
private def list_all_brokerages_with_http_info_impl(opts = {})
|
@@ -637,7 +677,9 @@ module SnapTrade
|
|
637
677
|
end
|
638
678
|
|
639
679
|
|
640
|
-
#
|
680
|
+
# Get currencies
|
681
|
+
#
|
682
|
+
# Returns a list of all defined Currency objects.
|
641
683
|
#
|
642
684
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
643
685
|
def list_all_currencies(extra: {})
|
@@ -645,14 +687,17 @@ module SnapTrade
|
|
645
687
|
data
|
646
688
|
end
|
647
689
|
|
648
|
-
#
|
690
|
+
# Get currencies
|
691
|
+
#
|
692
|
+
# Returns a list of all defined Currency objects.
|
649
693
|
#
|
650
694
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
651
695
|
def list_all_currencies_with_http_info(extra: {})
|
652
696
|
list_all_currencies_with_http_info_impl(extra)
|
653
697
|
end
|
654
698
|
|
655
|
-
#
|
699
|
+
# Get currencies
|
700
|
+
# Returns a list of all defined Currency objects.
|
656
701
|
# @param [Hash] opts the optional parameters
|
657
702
|
# @return [Array<Currency>]
|
658
703
|
private def list_all_currencies_impl(opts = {})
|
@@ -660,7 +705,8 @@ module SnapTrade
|
|
660
705
|
data
|
661
706
|
end
|
662
707
|
|
663
|
-
#
|
708
|
+
# Get currencies
|
709
|
+
# Returns a list of all defined Currency objects.
|
664
710
|
# @param [Hash] opts the optional parameters
|
665
711
|
# @return [Array<(Array<Currency>, Integer, Hash)>] Array<Currency> data, response status code and response headers
|
666
712
|
private def list_all_currencies_with_http_info_impl(opts = {})
|
@@ -708,7 +754,9 @@ module SnapTrade
|
|
708
754
|
end
|
709
755
|
|
710
756
|
|
711
|
-
#
|
757
|
+
# Get currency exchange rates
|
758
|
+
#
|
759
|
+
# Returns a list of all Exchange Rate Pairs for all supported Currencies.
|
712
760
|
#
|
713
761
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
714
762
|
def list_all_currencies_rates(extra: {})
|
@@ -716,14 +764,17 @@ module SnapTrade
|
|
716
764
|
data
|
717
765
|
end
|
718
766
|
|
719
|
-
#
|
767
|
+
# Get currency exchange rates
|
768
|
+
#
|
769
|
+
# Returns a list of all Exchange Rate Pairs for all supported Currencies.
|
720
770
|
#
|
721
771
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
722
772
|
def list_all_currencies_rates_with_http_info(extra: {})
|
723
773
|
list_all_currencies_rates_with_http_info_impl(extra)
|
724
774
|
end
|
725
775
|
|
726
|
-
#
|
776
|
+
# Get currency exchange rates
|
777
|
+
# Returns a list of all Exchange Rate Pairs for all supported Currencies.
|
727
778
|
# @param [Hash] opts the optional parameters
|
728
779
|
# @return [Array<ExchangeRatePairs>]
|
729
780
|
private def list_all_currencies_rates_impl(opts = {})
|
@@ -731,7 +782,8 @@ module SnapTrade
|
|
731
782
|
data
|
732
783
|
end
|
733
784
|
|
734
|
-
#
|
785
|
+
# Get currency exchange rates
|
786
|
+
# Returns a list of all Exchange Rate Pairs for all supported Currencies.
|
735
787
|
# @param [Hash] opts the optional parameters
|
736
788
|
# @return [Array<(Array<ExchangeRatePairs>, Integer, Hash)>] Array<ExchangeRatePairs> data, response status code and response headers
|
737
789
|
private def list_all_currencies_rates_with_http_info_impl(opts = {})
|
@@ -143,7 +143,9 @@ module SnapTrade
|
|
143
143
|
end
|
144
144
|
|
145
145
|
|
146
|
-
# Check impact of
|
146
|
+
# Check the impact of a trade on an account
|
147
|
+
#
|
148
|
+
# Return the trade object and it's impact on the account for the specified order.
|
147
149
|
#
|
148
150
|
# @param user_id [String]
|
149
151
|
# @param user_secret [String]
|
@@ -174,7 +176,9 @@ module SnapTrade
|
|
174
176
|
data
|
175
177
|
end
|
176
178
|
|
177
|
-
# Check impact of
|
179
|
+
# Check the impact of a trade on an account
|
180
|
+
#
|
181
|
+
# Return the trade object and it's impact on the account for the specified order.
|
178
182
|
#
|
179
183
|
# @param user_id [String]
|
180
184
|
# @param user_secret [String]
|
@@ -204,7 +208,8 @@ module SnapTrade
|
|
204
208
|
get_order_impact_with_http_info_impl(user_id, user_secret, manual_trade_form, extra)
|
205
209
|
end
|
206
210
|
|
207
|
-
# Check impact of
|
211
|
+
# Check the impact of a trade on an account
|
212
|
+
# Return the trade object and it's impact on the account for the specified order.
|
208
213
|
# @param user_id [String]
|
209
214
|
# @param user_secret [String]
|
210
215
|
# @param manual_trade_form [ManualTradeForm]
|
@@ -215,7 +220,8 @@ module SnapTrade
|
|
215
220
|
data
|
216
221
|
end
|
217
222
|
|
218
|
-
# Check impact of
|
223
|
+
# Check the impact of a trade on an account
|
224
|
+
# Return the trade object and it's impact on the account for the specified order.
|
219
225
|
# @param user_id [String]
|
220
226
|
# @param user_secret [String]
|
221
227
|
# @param manual_trade_form [ManualTradeForm]
|
@@ -406,6 +412,8 @@ module SnapTrade
|
|
406
412
|
|
407
413
|
# Place a trade with NO validation.
|
408
414
|
#
|
415
|
+
# Places a specified trade in the specified account.
|
416
|
+
#
|
409
417
|
# @param user_id [String]
|
410
418
|
# @param user_secret [String]
|
411
419
|
# @param account_id [String]
|
@@ -437,6 +445,8 @@ module SnapTrade
|
|
437
445
|
|
438
446
|
# Place a trade with NO validation.
|
439
447
|
#
|
448
|
+
# Places a specified trade in the specified account.
|
449
|
+
#
|
440
450
|
# @param user_id [String]
|
441
451
|
# @param user_secret [String]
|
442
452
|
# @param account_id [String]
|
@@ -466,6 +476,7 @@ module SnapTrade
|
|
466
476
|
end
|
467
477
|
|
468
478
|
# Place a trade with NO validation.
|
479
|
+
# Places a specified trade in the specified account.
|
469
480
|
# @param user_id [String]
|
470
481
|
# @param user_secret [String]
|
471
482
|
# @param manual_trade_form [ManualTradeForm]
|
@@ -477,6 +488,7 @@ module SnapTrade
|
|
477
488
|
end
|
478
489
|
|
479
490
|
# Place a trade with NO validation.
|
491
|
+
# Places a specified trade in the specified account.
|
480
492
|
# @param user_id [String]
|
481
493
|
# @param user_secret [String]
|
482
494
|
# @param manual_trade_form [ManualTradeForm]
|
@@ -548,6 +560,9 @@ module SnapTrade
|
|
548
560
|
|
549
561
|
# Place order
|
550
562
|
#
|
563
|
+
# Places the specified trade object. This places the order in the account and
|
564
|
+
# returns the status of the order from the brokerage.
|
565
|
+
#
|
551
566
|
# @param trade_id [String] The ID of trade object obtained from trade/impact endpoint
|
552
567
|
# @param user_id [String]
|
553
568
|
# @param user_secret [String]
|
@@ -564,6 +579,9 @@ module SnapTrade
|
|
564
579
|
|
565
580
|
# Place order
|
566
581
|
#
|
582
|
+
# Places the specified trade object. This places the order in the account and
|
583
|
+
# returns the status of the order from the brokerage.
|
584
|
+
#
|
567
585
|
# @param trade_id [String] The ID of trade object obtained from trade/impact endpoint
|
568
586
|
# @param user_id [String]
|
569
587
|
# @param user_secret [String]
|
@@ -578,6 +596,7 @@ module SnapTrade
|
|
578
596
|
end
|
579
597
|
|
580
598
|
# Place order
|
599
|
+
# Places the specified trade object. This places the order in the account and returns the status of the order from the brokerage.
|
581
600
|
# @param trade_id [String] The ID of trade object obtained from trade/impact endpoint
|
582
601
|
# @param user_id [String]
|
583
602
|
# @param user_secret [String]
|
@@ -590,6 +609,7 @@ module SnapTrade
|
|
590
609
|
end
|
591
610
|
|
592
611
|
# Place order
|
612
|
+
# Places the specified trade object. This places the order in the account and returns the status of the order from the brokerage.
|
593
613
|
# @param trade_id [String] The ID of trade object obtained from trade/impact endpoint
|
594
614
|
# @param user_id [String]
|
595
615
|
# @param user_secret [String]
|
data/lib/snaptrade/version.rb
CHANGED
@@ -43,7 +43,7 @@ describe 'ConnectionsApi' do
|
|
43
43
|
|
44
44
|
# unit tests for list_brokerage_authorizations
|
45
45
|
# List all brokerage authorizations for the User
|
46
|
-
# Returns a list of Brokerage
|
46
|
+
# Returns a list of Brokerage Authorization objects for the user
|
47
47
|
# @param user_id
|
48
48
|
# @param user_secret
|
49
49
|
# @param [Hash] opts the optional parameters
|
@@ -28,7 +28,8 @@ describe 'ReferenceDataApi' do
|
|
28
28
|
end
|
29
29
|
|
30
30
|
# unit tests for get_currency_exchange_rate_pair
|
31
|
-
#
|
31
|
+
# Get exchange rate of a currency pair
|
32
|
+
# Returns an Exchange Rate Pair object for the specified Currency Pair.
|
32
33
|
# @param currency_pair A currency pair based on currency code for example, {CAD-USD}
|
33
34
|
# @param [Hash] opts the optional parameters
|
34
35
|
# @return [ExchangeRatePairs]
|
@@ -61,7 +62,8 @@ describe 'ReferenceDataApi' do
|
|
61
62
|
end
|
62
63
|
|
63
64
|
# unit tests for get_stock_exchanges
|
64
|
-
#
|
65
|
+
# Get exchanges
|
66
|
+
# Returns a list of all supported Exchanges.
|
65
67
|
# @param [Hash] opts the optional parameters
|
66
68
|
# @return [Array<Exchange>]
|
67
69
|
describe 'get_stock_exchanges test' do
|
@@ -72,6 +74,7 @@ describe 'ReferenceDataApi' do
|
|
72
74
|
|
73
75
|
# unit tests for get_symbols
|
74
76
|
# Search for symbols
|
77
|
+
# Returns a list of Universal Symbol objects that match a defined string. Matches on ticker or name.
|
75
78
|
# @param [Hash] opts the optional parameters
|
76
79
|
# @option opts [SymbolQuery] :symbol_query
|
77
80
|
# @return [Array<UniversalSymbol>]
|
@@ -82,7 +85,8 @@ describe 'ReferenceDataApi' do
|
|
82
85
|
end
|
83
86
|
|
84
87
|
# unit tests for get_symbols_by_ticker
|
85
|
-
# Get details of a symbol
|
88
|
+
# Get details of a symbol
|
89
|
+
# Returns the Universal Symbol object specified by the ticker or the universal_symbol_id.
|
86
90
|
# @param query The ticker or universal_symbol_id of the UniversalSymbol to get.
|
87
91
|
# @param [Hash] opts the optional parameters
|
88
92
|
# @return [UniversalSymbol]
|
@@ -93,7 +97,8 @@ describe 'ReferenceDataApi' do
|
|
93
97
|
end
|
94
98
|
|
95
99
|
# unit tests for list_all_brokerage_authorization_type
|
96
|
-
#
|
100
|
+
# Get all brokerage authorization types
|
101
|
+
# Returns a list of all defined Brokerage authorization Type objects.
|
97
102
|
# @param [Hash] opts the optional parameters
|
98
103
|
# @option opts [String] :brokerage Comma separated value of brokerage slugs
|
99
104
|
# @return [Array<BrokerageAuthorizationTypeReadOnly>]
|
@@ -104,7 +109,8 @@ describe 'ReferenceDataApi' do
|
|
104
109
|
end
|
105
110
|
|
106
111
|
# unit tests for list_all_brokerages
|
107
|
-
#
|
112
|
+
# Get brokerages
|
113
|
+
# Returns a list of all defined Brokerage objects.
|
108
114
|
# @param [Hash] opts the optional parameters
|
109
115
|
# @return [Array<Brokerage>]
|
110
116
|
describe 'list_all_brokerages test' do
|
@@ -114,7 +120,8 @@ describe 'ReferenceDataApi' do
|
|
114
120
|
end
|
115
121
|
|
116
122
|
# unit tests for list_all_currencies
|
117
|
-
#
|
123
|
+
# Get currencies
|
124
|
+
# Returns a list of all defined Currency objects.
|
118
125
|
# @param [Hash] opts the optional parameters
|
119
126
|
# @return [Array<Currency>]
|
120
127
|
describe 'list_all_currencies test' do
|
@@ -124,7 +131,8 @@ describe 'ReferenceDataApi' do
|
|
124
131
|
end
|
125
132
|
|
126
133
|
# unit tests for list_all_currencies_rates
|
127
|
-
#
|
134
|
+
# Get currency exchange rates
|
135
|
+
# Returns a list of all Exchange Rate Pairs for all supported Currencies.
|
128
136
|
# @param [Hash] opts the optional parameters
|
129
137
|
# @return [Array<ExchangeRatePairs>]
|
130
138
|
describe 'list_all_currencies_rates test' do
|
@@ -43,7 +43,8 @@ describe 'TradingApi' do
|
|
43
43
|
end
|
44
44
|
|
45
45
|
# unit tests for get_order_impact
|
46
|
-
# Check impact of
|
46
|
+
# Check the impact of a trade on an account
|
47
|
+
# Return the trade object and it's impact on the account for the specified order.
|
47
48
|
# @param user_id
|
48
49
|
# @param user_secret
|
49
50
|
# @param manual_trade_form
|
@@ -73,6 +74,7 @@ describe 'TradingApi' do
|
|
73
74
|
|
74
75
|
# unit tests for place_force_order
|
75
76
|
# Place a trade with NO validation.
|
77
|
+
# Places a specified trade in the specified account.
|
76
78
|
# @param user_id
|
77
79
|
# @param user_secret
|
78
80
|
# @param manual_trade_form
|
@@ -86,6 +88,7 @@ describe 'TradingApi' do
|
|
86
88
|
|
87
89
|
# unit tests for place_order
|
88
90
|
# Place order
|
91
|
+
# Places the specified trade object. This places the order in the account and returns the status of the order from the brokerage.
|
89
92
|
# @param trade_id The ID of trade object obtained from trade/impact endpoint
|
90
93
|
# @param user_id
|
91
94
|
# @param user_secret
|
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: 2.0.
|
4
|
+
version: 2.0.18
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- SnapTrade
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-05-
|
11
|
+
date: 2024-05-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|