snaptrade 2.0.124 → 2.0.126

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c52a939d269906ab92631ba9806d1d7a9f6fc2b06badd2260018ca5046b9e6f5
4
- data.tar.gz: 1d7b5eee9b5ae12d88c244aa086c0c2a7d5e428b3defec7e64a433ded17ffb22
3
+ metadata.gz: 43137f138b8350fe0965e3a2a323075c292dc33820eb0f0e9539a18919627bd1
4
+ data.tar.gz: 4abe81884e2b96419e60f492ee407f042f30f032b1dc529a24b89ec6bb3b3321
5
5
  SHA512:
6
- metadata.gz: 406fe1174adad1ec1ad3962dae8c0c2098c9fc31ad30adbd6cbd8346a271ebf42f06285b129bd8d4f9283cdc16278125e5317aa245e9c4d36205c0b1ab5e8d3e
7
- data.tar.gz: 710d59a5c10de48f22b51b9a36dd2077cdeb5a498c70e2553ae7cd8b012b6a62e2cf27854865479c289001f2dd70c780e182e45d2b5ab834f7ac261bb45e12fc
6
+ metadata.gz: 60cf996815603a779d72c3aa5e4cb88e704004e88c09f11e00fc75808c6a649fb93d10abba6fe15a7f278466165a0bb0906cfabc9aa5562f8272fa56594897dc
7
+ data.tar.gz: 3aff0d1f2d907de76459213fc6d2a2b17f0eeb88c4dce9029ea4ce7ab306177c8b65d76798b77449edadd89d5f970c1c26d50a1196775d69f7dd447467506305
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- snaptrade (2.0.124)
4
+ snaptrade (2.0.126)
5
5
  faraday (>= 1.0.1, < 3.0)
6
6
  faraday-multipart (~> 1.0, >= 1.0.4)
7
7
 
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.124-blue)](https://rubygems.org/gems/snaptrade/versions/2.0.124)
9
+ [![npm](https://img.shields.io/badge/gem-v2.0.126-blue)](https://rubygems.org/gems/snaptrade/versions/2.0.126)
10
10
  [![More Info](https://img.shields.io/badge/More%20Info-Click%20Here-orange)](https://snaptrade.com/)
11
11
 
12
12
  </div>
@@ -44,11 +44,8 @@ Connect brokerage accounts to your app for live positions and trading
44
44
  * [`snaptrade.connections.remove_brokerage_authorization`](#snaptradeconnectionsremove_brokerage_authorization)
45
45
  * [`snaptrade.connections.return_rates`](#snaptradeconnectionsreturn_rates)
46
46
  * [`snaptrade.connections.session_events`](#snaptradeconnectionssession_events)
47
- * [`snaptrade.options.get_option_strategy`](#snaptradeoptionsget_option_strategy)
48
47
  * [`snaptrade.options.get_options_chain`](#snaptradeoptionsget_options_chain)
49
- * [`snaptrade.options.get_options_strategy_quote`](#snaptradeoptionsget_options_strategy_quote)
50
48
  * [`snaptrade.options.list_option_holdings`](#snaptradeoptionslist_option_holdings)
51
- * [`snaptrade.options.place_option_strategy`](#snaptradeoptionsplace_option_strategy)
52
49
  * [`snaptrade.reference_data.get_currency_exchange_rate_pair`](#snaptradereference_dataget_currency_exchange_rate_pair)
53
50
  * [`snaptrade.reference_data.get_partner_info`](#snaptradereference_dataget_partner_info)
54
51
  * [`snaptrade.reference_data.get_security_types`](#snaptradereference_dataget_security_types)
@@ -84,7 +81,7 @@ Connect brokerage accounts to your app for live positions and trading
84
81
  Add to Gemfile:
85
82
 
86
83
  ```ruby
87
- gem 'snaptrade', '~> 2.0.124'
84
+ gem 'snaptrade', '~> 2.0.126'
88
85
  ```
89
86
 
90
87
  ## Getting Started<a id="getting-started"></a>
@@ -323,7 +320,11 @@ p result
323
320
 
324
321
  ### `snaptrade.account_information.get_user_account_order_detail`<a id="snaptradeaccount_informationget_user_account_order_detail"></a>
325
322
 
326
- Returns the detail of a single order in the specified account. This endpoint is always realtime and does not rely on cached data.
323
+ Returns the detail of a single order in the specified account.
324
+
325
+ This endpoint is always realtime and does not rely on cached data.
326
+
327
+ This endpoint only returns orders placed through SnapTrade. In other words, orders placed outside of the SnapTrade network are not returned by this endpoint.
327
328
 
328
329
 
329
330
  #### 🛠️ Usage<a id="🛠️-usage"></a>
@@ -1085,54 +1086,6 @@ specific users
1085
1086
  ---
1086
1087
 
1087
1088
 
1088
- ### `snaptrade.options.get_option_strategy`<a id="snaptradeoptionsget_option_strategy"></a>
1089
-
1090
- Creates an option strategy object that will be used to place an option strategy order.
1091
-
1092
-
1093
- #### 🛠️ Usage<a id="🛠️-usage"></a>
1094
-
1095
- ```ruby
1096
- result = snaptrade.options.get_option_strategy(
1097
- underlying_symbol_id: "2bcd7cc3-e922-4976-bce1-9858296801c3",
1098
- legs: [
1099
- {
1100
- "action" => "BUY_TO_OPEN",
1101
- "option_symbol_id" => "SPY220819P00200000",
1102
- "quantity" => 1,
1103
- }
1104
- ],
1105
- strategy_type: "CUSTOM",
1106
- user_id: "snaptrade-user-123",
1107
- user_secret: "adf2aa34-8219-40f7-a6b3-60156985cc61",
1108
- account_id: "accountId_example",
1109
- )
1110
- p result
1111
- ```
1112
-
1113
- #### ⚙️ Parameters<a id="⚙️-parameters"></a>
1114
-
1115
- ##### underlying_symbol_id: `String`<a id="underlying_symbol_id-string"></a>
1116
- ##### legs: Array<[`OptionLeg`](./lib/snaptrade/models/option_leg.rb)><a id="legs-array"></a>
1117
- ##### strategy_type: [`StrategyType`](./lib/snaptrade/models/strategy_type.rb)<a id="strategy_type-strategytypelibsnaptrademodelsstrategy_typerb"></a>
1118
- ##### user_id: `String`<a id="user_id-string"></a>
1119
- ##### user_secret: `String`<a id="user_secret-string"></a>
1120
- ##### account_id: `String`<a id="account_id-string"></a>
1121
- The ID of the account to create the option strategy object in.
1122
-
1123
- #### 🔄 Return<a id="🔄-return"></a>
1124
-
1125
- [StrategyQuotes](./lib/snaptrade/models/strategy_quotes.rb)
1126
-
1127
- #### 🌐 Endpoint<a id="🌐-endpoint"></a>
1128
-
1129
- `/accounts/{accountId}/optionStrategy` `POST`
1130
-
1131
- [🔙 **Back to Table of Contents**](#table-of-contents)
1132
-
1133
- ---
1134
-
1135
-
1136
1089
  ### `snaptrade.options.get_options_chain`<a id="snaptradeoptionsget_options_chain"></a>
1137
1090
 
1138
1091
  Returns the option chain for the specified symbol in the specified account.
@@ -1172,46 +1125,6 @@ Universal symbol ID if symbol
1172
1125
  ---
1173
1126
 
1174
1127
 
1175
- ### `snaptrade.options.get_options_strategy_quote`<a id="snaptradeoptionsget_options_strategy_quote"></a>
1176
-
1177
- Returns a Strategy Quotes object which has latest market data of the specified option strategy.
1178
-
1179
-
1180
- #### 🛠️ Usage<a id="🛠️-usage"></a>
1181
-
1182
- ```ruby
1183
- result = snaptrade.options.get_options_strategy_quote(
1184
- user_id: "snaptrade-user-123",
1185
- user_secret: "adf2aa34-8219-40f7-a6b3-60156985cc61",
1186
- account_id: "accountId_example",
1187
- option_strategy_id: "2bcd7cc3-e922-4976-bce1-9858296801c3",
1188
- )
1189
- p result
1190
- ```
1191
-
1192
- #### ⚙️ Parameters<a id="⚙️-parameters"></a>
1193
-
1194
- ##### user_id: `String`<a id="user_id-string"></a>
1195
- ##### user_secret: `String`<a id="user_secret-string"></a>
1196
- ##### account_id: `String`<a id="account_id-string"></a>
1197
- The ID of the account the strategy will be placed in.
1198
-
1199
- ##### option_strategy_id: `String`<a id="option_strategy_id-string"></a>
1200
- Option strategy id obtained from response when creating option strategy object
1201
-
1202
- #### 🔄 Return<a id="🔄-return"></a>
1203
-
1204
- [StrategyQuotes](./lib/snaptrade/models/strategy_quotes.rb)
1205
-
1206
- #### 🌐 Endpoint<a id="🌐-endpoint"></a>
1207
-
1208
- `/accounts/{accountId}/optionStrategy/{optionStrategyId}` `GET`
1209
-
1210
- [🔙 **Back to Table of Contents**](#table-of-contents)
1211
-
1212
- ---
1213
-
1214
-
1215
1128
  ### `snaptrade.options.list_option_holdings`<a id="snaptradeoptionslist_option_holdings"></a>
1216
1129
 
1217
1130
  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).
@@ -1248,66 +1161,6 @@ p result
1248
1161
  ---
1249
1162
 
1250
1163
 
1251
- ### `snaptrade.options.place_option_strategy`<a id="snaptradeoptionsplace_option_strategy"></a>
1252
-
1253
- Places the option strategy order and returns the order record received from the brokerage.
1254
-
1255
- #### 🛠️ Usage<a id="🛠️-usage"></a>
1256
-
1257
- ```ruby
1258
- result = snaptrade.options.place_option_strategy(
1259
- order_type: "Market",
1260
- time_in_force: "Day",
1261
- user_id: "snaptrade-user-123",
1262
- user_secret: "adf2aa34-8219-40f7-a6b3-60156985cc61",
1263
- account_id: "2bcd7cc3-e922-4976-bce1-9858296801c3",
1264
- option_strategy_id: "2bcd7cc3-e922-4976-bce1-9858296801c3",
1265
- price: 31.33,
1266
- )
1267
- p result
1268
- ```
1269
-
1270
- #### ⚙️ Parameters<a id="⚙️-parameters"></a>
1271
-
1272
- ##### order_type: [`OrderTypeStrict`](./lib/snaptrade/models/order_type_strict.rb)<a id="order_type-ordertypestrictlibsnaptrademodelsorder_type_strictrb"></a>
1273
- The type of order to place. - For `Limit` and `StopLimit` orders, the `price`
1274
- field is required. - For `Stop` and `StopLimit` orders, the `stop` field is
1275
- required.
1276
-
1277
- ##### time_in_force: [`TimeInForceStrict`](./lib/snaptrade/models/time_in_force_strict.rb)<a id="time_in_force-timeinforcestrictlibsnaptrademodelstime_in_force_strictrb"></a>
1278
- The Time in Force type for the order. This field indicates how long the order
1279
- will remain active before it is executed or expires. Here are the supported
1280
- values: - `Day` - Day. The order is valid only for the trading day on which it
1281
- is placed. - `GTC` - Good Til Canceled. The order is valid until it is executed
1282
- or canceled. - `FOK` - Fill Or Kill. The order must be executed in its entirety
1283
- immediately or be canceled completely. - `IOC` - Immediate Or Cancel. The order
1284
- must be executed immediately. Any portion of the order that cannot be filled
1285
- immediately will be canceled.
1286
-
1287
- ##### user_id: `String`<a id="user_id-string"></a>
1288
- ##### user_secret: `String`<a id="user_secret-string"></a>
1289
- ##### account_id: `String`<a id="account_id-string"></a>
1290
- The ID of the account to execute the strategy in.
1291
-
1292
- ##### option_strategy_id: `String`<a id="option_strategy_id-string"></a>
1293
- Option strategy id obtained from response when creating option strategy object
1294
-
1295
- ##### price: `Float`<a id="price-float"></a>
1296
- Trade Price if limit or stop limit order
1297
-
1298
- #### 🔄 Return<a id="🔄-return"></a>
1299
-
1300
- [StrategyOrderRecord](./lib/snaptrade/models/strategy_order_record.rb)
1301
-
1302
- #### 🌐 Endpoint<a id="🌐-endpoint"></a>
1303
-
1304
- `/accounts/{accountId}/optionStrategy/{optionStrategyId}/execute` `POST`
1305
-
1306
- [🔙 **Back to Table of Contents**](#table-of-contents)
1307
-
1308
- ---
1309
-
1310
-
1311
1164
  ### `snaptrade.reference_data.get_currency_exchange_rate_pair`<a id="snaptradereference_dataget_currency_exchange_rate_pair"></a>
1312
1165
 
1313
1166
  Returns an Exchange Rate Pair object for the specified Currency Pair.
@@ -1840,7 +1693,14 @@ The price at which a stop order is triggered for `Stop` and `StopLimit` orders.
1840
1693
 
1841
1694
  ### `snaptrade.trading.get_user_account_quotes`<a id="snaptradetradingget_user_account_quotes"></a>
1842
1695
 
1843
- Returns quotes from the brokerage for the specified symbols and account. The quotes returned can be delayed depending on the brokerage the account belongs to. It is highly recommended that you use your own market data provider for real-time quotes instead of relying on this endpoint. This endpoint does not work for options quotes.
1696
+ Returns quotes from the brokerage for the specified symbols and account.
1697
+
1698
+ The quotes returned can be delayed depending on the brokerage the account belongs to. It is highly recommended that you use your own market data provider for real-time quotes instead of relying on this endpoint.
1699
+
1700
+ This endpoint does not work for options quotes.
1701
+
1702
+ This endpoint is disabled for free plans by default. Please contact support to enable this endpoint if needed.
1703
+
1844
1704
 
1845
1705
  #### 🛠️ Usage<a id="🛠️-usage"></a>
1846
1706
 
@@ -499,7 +499,11 @@ module SnapTrade
499
499
 
500
500
  # Get account order detail
501
501
  #
502
- # Returns the detail of a single order in the specified account. This endpoint is always realtime and does not rely on cached data.
502
+ # Returns the detail of a single order in the specified account.
503
+ #
504
+ # This endpoint is always realtime and does not rely on cached data.
505
+ #
506
+ # This endpoint only returns orders placed through SnapTrade. In other words, orders placed outside of the SnapTrade network are not returned by this endpoint.
503
507
  #
504
508
  # @param user_id [String]
505
509
  # @param user_secret [String]
@@ -513,7 +517,11 @@ module SnapTrade
513
517
 
514
518
  # Get account order detail
515
519
  #
516
- # Returns the detail of a single order in the specified account. This endpoint is always realtime and does not rely on cached data.
520
+ # Returns the detail of a single order in the specified account.
521
+ #
522
+ # This endpoint is always realtime and does not rely on cached data.
523
+ #
524
+ # This endpoint only returns orders placed through SnapTrade. In other words, orders placed outside of the SnapTrade network are not returned by this endpoint.
517
525
  #
518
526
  # @param user_id [String]
519
527
  # @param user_secret [String]
@@ -525,7 +533,7 @@ module SnapTrade
525
533
  end
526
534
 
527
535
  # Get account order detail
528
- # Returns the detail of a single order in the specified account. This endpoint is always realtime and does not rely on cached data.
536
+ # Returns the detail of a single order in the specified account. This endpoint is always realtime and does not rely on cached data. This endpoint only returns orders placed through SnapTrade. In other words, orders placed outside of the SnapTrade network are not returned by this endpoint.
529
537
  # @param user_id [String]
530
538
  # @param user_secret [String]
531
539
  # @param account_id [String]
@@ -538,7 +546,7 @@ module SnapTrade
538
546
  end
539
547
 
540
548
  # Get account order detail
541
- # Returns the detail of a single order in the specified account. This endpoint is always realtime and does not rely on cached data.
549
+ # Returns the detail of a single order in the specified account. This endpoint is always realtime and does not rely on cached data. This endpoint only returns orders placed through SnapTrade. In other words, orders placed outside of the SnapTrade network are not returned by this endpoint.
542
550
  # @param user_id [String]
543
551
  # @param user_secret [String]
544
552
  # @param account_id [String]