snaptrade 2.0.192 → 2.0.193
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 +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +6 -4
- data/lib/snaptrade/api/account_information_api.rb +10 -8
- data/lib/snaptrade/models/account_position.rb +1 -1
- data/lib/snaptrade/models/future_instrument.rb +1 -0
- data/lib/snaptrade/models/option_instrument.rb +1 -0
- data/lib/snaptrade/version.rb +1 -1
- data/spec/api/account_information_api_spec.rb +2 -2
- 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: 0e3e610ad0276652d7dec99dd805f6d6cf99ad4ef97d7a2ede31548667e49745
|
|
4
|
+
data.tar.gz: d98a50011a177acff3e5089edc25a15a576a2183c9fe0fcc74f96145f4991c1c
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 178579414ee80484fa95cb6651d798ceee47638546007c14bf0f608513099a5ba78df45c311fd4c617ede809df44350e0f8ff283be114468390b947cfed8a231
|
|
7
|
+
data.tar.gz: 88d34c24b4f21855b6f14358b836f7630717025609a9745bdda15ecefaf9e4c60f87ab43f982e5b5795bf9b684a5169c1c38ddfbd96a03fe4ee64b7b5badd0d4
|
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
|
-
[](https://rubygems.org/gems/snaptrade/versions/2.0.193)
|
|
10
10
|
[](https://snaptrade.com/)
|
|
11
11
|
|
|
12
12
|
</div>
|
|
@@ -91,7 +91,7 @@ Connect brokerage accounts to your app for live positions and trading
|
|
|
91
91
|
Add to Gemfile:
|
|
92
92
|
|
|
93
93
|
```ruby
|
|
94
|
-
gem 'snaptrade', '~> 2.0.
|
|
94
|
+
gem 'snaptrade', '~> 2.0.193'
|
|
95
95
|
```
|
|
96
96
|
|
|
97
97
|
## Getting Started<a id="getting-started"></a>
|
|
@@ -258,7 +258,7 @@ Returns a list of all positions in the specified account.
|
|
|
258
258
|
|
|
259
259
|
The `results` list can contain multiple instrument types in the same response, including stocks, ADRs, ETFs, mutual funds, closed-end funds, crypto, futures, and option positions. Use the `instrument.kind` discriminator to determine the schema for each position's `instrument`.
|
|
260
260
|
|
|
261
|
-
|
|
261
|
+
`mutualfund` positions may also include `cash_equivalent`. `stock` positions may include `tax_lots` when tax lot data is enabled for the account.
|
|
262
262
|
|
|
263
263
|
If the connection has become disabled, it can no longer access the latest data from the brokerage, but will continue to return the last available cached state. Please see [this guide](/docs/fix-broken-connections) on how to fix a disabled connection.
|
|
264
264
|
|
|
@@ -634,8 +634,10 @@ returns all six supported timeframes.
|
|
|
634
634
|
|
|
635
635
|
|
|
636
636
|
### `snaptrade.account_information.get_user_holdings`<a id="snaptradeaccount_informationget_user_holdings"></a>
|
|
637
|
+

|
|
637
638
|
|
|
638
|
-
|
|
639
|
+
**Deprecated.** Use the finer-grained account data endpoints instead: [balances](/reference/Account%20Information/AccountInformation_getUserAccountBalance), [positions](/reference/Account%20Information/AccountInformation_getAllAccountPositions), and [orders](/reference/Account%20Information/AccountInformation_getUserAccountOrders).
|
|
640
|
+
Returns a list of balances, positions, and recent orders for the specified account.
|
|
639
641
|
|
|
640
642
|
Check your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing) to see if you have real-time data access:
|
|
641
643
|
- If you do, this endpoint returns real-time data.
|
|
@@ -288,7 +288,7 @@ module SnapTrade
|
|
|
288
288
|
#
|
|
289
289
|
# The `results` list can contain multiple instrument types in the same response, including stocks, ADRs, ETFs, mutual funds, closed-end funds, crypto, futures, and option positions. Use the `instrument.kind` discriminator to determine the schema for each position's `instrument`.
|
|
290
290
|
#
|
|
291
|
-
#
|
|
291
|
+
# `mutualfund` positions may also include `cash_equivalent`. `stock` positions may include `tax_lots` when tax lot data is enabled for the account.
|
|
292
292
|
#
|
|
293
293
|
# If the connection has become disabled, it can no longer access the latest data from the brokerage, but will continue to return the last available cached state. Please see [this guide](/docs/fix-broken-connections) on how to fix a disabled connection.
|
|
294
294
|
#
|
|
@@ -307,7 +307,7 @@ module SnapTrade
|
|
|
307
307
|
#
|
|
308
308
|
# The `results` list can contain multiple instrument types in the same response, including stocks, ADRs, ETFs, mutual funds, closed-end funds, crypto, futures, and option positions. Use the `instrument.kind` discriminator to determine the schema for each position's `instrument`.
|
|
309
309
|
#
|
|
310
|
-
#
|
|
310
|
+
# `mutualfund` positions may also include `cash_equivalent`. `stock` positions may include `tax_lots` when tax lot data is enabled for the account.
|
|
311
311
|
#
|
|
312
312
|
# If the connection has become disabled, it can no longer access the latest data from the brokerage, but will continue to return the last available cached state. Please see [this guide](/docs/fix-broken-connections) on how to fix a disabled connection.
|
|
313
313
|
#
|
|
@@ -320,7 +320,7 @@ module SnapTrade
|
|
|
320
320
|
end
|
|
321
321
|
|
|
322
322
|
# List all account positions
|
|
323
|
-
# Returns a list of all positions in the specified account. The `results` list can contain multiple instrument types in the same response, including stocks, ADRs, ETFs, mutual funds, closed-end funds, crypto, futures, and option positions. Use the `instrument.kind` discriminator to determine the schema for each position's `instrument`.
|
|
323
|
+
# Returns a list of all positions in the specified account. The `results` list can contain multiple instrument types in the same response, including stocks, ADRs, ETFs, mutual funds, closed-end funds, crypto, futures, and option positions. Use the `instrument.kind` discriminator to determine the schema for each position's `instrument`. `mutualfund` positions may also include `cash_equivalent`. `stock` positions may include `tax_lots` when tax lot data is enabled for the account. If the connection has become disabled, it can no longer access the latest data from the brokerage, but will continue to return the last available cached state. Please see [this guide](/docs/fix-broken-connections) on how to fix a disabled connection.
|
|
324
324
|
# @param user_id [String]
|
|
325
325
|
# @param user_secret [String]
|
|
326
326
|
# @param account_id [String]
|
|
@@ -332,7 +332,7 @@ module SnapTrade
|
|
|
332
332
|
end
|
|
333
333
|
|
|
334
334
|
# List all account positions
|
|
335
|
-
# Returns a list of all positions in the specified account. The `results` list can contain multiple instrument types in the same response, including stocks, ADRs, ETFs, mutual funds, closed-end funds, crypto, futures, and option positions. Use the `instrument.kind` discriminator to determine the schema for each position's `instrument`.
|
|
335
|
+
# Returns a list of all positions in the specified account. The `results` list can contain multiple instrument types in the same response, including stocks, ADRs, ETFs, mutual funds, closed-end funds, crypto, futures, and option positions. Use the `instrument.kind` discriminator to determine the schema for each position's `instrument`. `mutualfund` positions may also include `cash_equivalent`. `stock` positions may include `tax_lots` when tax lot data is enabled for the account. If the connection has become disabled, it can no longer access the latest data from the brokerage, but will continue to return the last available cached state. Please see [this guide](/docs/fix-broken-connections) on how to fix a disabled connection.
|
|
336
336
|
# @param user_id [String]
|
|
337
337
|
# @param user_secret [String]
|
|
338
338
|
# @param account_id [String]
|
|
@@ -1363,7 +1363,8 @@ module SnapTrade
|
|
|
1363
1363
|
|
|
1364
1364
|
# List account holdings
|
|
1365
1365
|
#
|
|
1366
|
-
#
|
|
1366
|
+
# **Deprecated.** Use the finer-grained account data endpoints instead: [balances](/reference/Account%20Information/AccountInformation_getUserAccountBalance), [positions](/reference/Account%20Information/AccountInformation_getAllAccountPositions), and [orders](/reference/Account%20Information/AccountInformation_getUserAccountOrders).
|
|
1367
|
+
# Returns a list of balances, positions, and recent orders for the specified account.
|
|
1367
1368
|
#
|
|
1368
1369
|
# Check your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing) to see if you have real-time data access:
|
|
1369
1370
|
# - If you do, this endpoint returns real-time data.
|
|
@@ -1382,7 +1383,8 @@ module SnapTrade
|
|
|
1382
1383
|
|
|
1383
1384
|
# List account holdings
|
|
1384
1385
|
#
|
|
1385
|
-
#
|
|
1386
|
+
# **Deprecated.** Use the finer-grained account data endpoints instead: [balances](/reference/Account%20Information/AccountInformation_getUserAccountBalance), [positions](/reference/Account%20Information/AccountInformation_getAllAccountPositions), and [orders](/reference/Account%20Information/AccountInformation_getUserAccountOrders).
|
|
1387
|
+
# Returns a list of balances, positions, and recent orders for the specified account.
|
|
1386
1388
|
#
|
|
1387
1389
|
# Check your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing) to see if you have real-time data access:
|
|
1388
1390
|
# - If you do, this endpoint returns real-time data.
|
|
@@ -1399,7 +1401,7 @@ module SnapTrade
|
|
|
1399
1401
|
end
|
|
1400
1402
|
|
|
1401
1403
|
# List account holdings
|
|
1402
|
-
#
|
|
1404
|
+
# **Deprecated.** Use the finer-grained account data endpoints instead: [balances](/reference/Account%20Information/AccountInformation_getUserAccountBalance), [positions](/reference/Account%20Information/AccountInformation_getAllAccountPositions), and [orders](/reference/Account%20Information/AccountInformation_getUserAccountOrders). Returns a list of balances, positions, and recent orders for the specified account. Check your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing) to see if you have real-time data access: - If you do, this endpoint returns real-time data. - If you don't, the data is cached and refreshed once a day. How long the data is cached for varies by brokerage. Check the [brokerage integrations doc](https://support.snaptrade.com/brokerages-table?v=d16c4c97b8d5438bbb2d8581ac53b11e) and look for \"Cache Expiry Time\" to see the exact value for a specific brokerage. If you need real-time, use the [manual refresh](/reference/Connections/Connections_refreshBrokerageAuthorization) endpoint. If the connection has become disabled, it can no longer access the latest data from the brokerage, but will continue to return the last available cached state. Please see [this guide](/docs/fix-broken-connections) on how to fix a disabled connection.
|
|
1403
1405
|
# @param account_id [String]
|
|
1404
1406
|
# @param user_id [String]
|
|
1405
1407
|
# @param user_secret [String]
|
|
@@ -1411,7 +1413,7 @@ module SnapTrade
|
|
|
1411
1413
|
end
|
|
1412
1414
|
|
|
1413
1415
|
# List account holdings
|
|
1414
|
-
#
|
|
1416
|
+
# **Deprecated.** Use the finer-grained account data endpoints instead: [balances](/reference/Account%20Information/AccountInformation_getUserAccountBalance), [positions](/reference/Account%20Information/AccountInformation_getAllAccountPositions), and [orders](/reference/Account%20Information/AccountInformation_getUserAccountOrders). Returns a list of balances, positions, and recent orders for the specified account. Check your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing) to see if you have real-time data access: - If you do, this endpoint returns real-time data. - If you don't, the data is cached and refreshed once a day. How long the data is cached for varies by brokerage. Check the [brokerage integrations doc](https://support.snaptrade.com/brokerages-table?v=d16c4c97b8d5438bbb2d8581ac53b11e) and look for \"Cache Expiry Time\" to see the exact value for a specific brokerage. If you need real-time, use the [manual refresh](/reference/Connections/Connections_refreshBrokerageAuthorization) endpoint. If the connection has become disabled, it can no longer access the latest data from the brokerage, but will continue to return the last available cached state. Please see [this guide](/docs/fix-broken-connections) on how to fix a disabled connection.
|
|
1415
1417
|
# @param account_id [String]
|
|
1416
1418
|
# @param user_id [String]
|
|
1417
1419
|
# @param user_secret [String]
|
|
@@ -27,7 +27,7 @@ module SnapTrade
|
|
|
27
27
|
# ISO-4217 currency code for the position `price` and `cost_basis`.
|
|
28
28
|
attr_accessor :currency
|
|
29
29
|
|
|
30
|
-
# Present for
|
|
30
|
+
# Present for mutual fund positions that are also counted in cash balance or buying power.
|
|
31
31
|
attr_accessor :cash_equivalent
|
|
32
32
|
|
|
33
33
|
# Present for stock positions when tax lot data is enabled for the account.
|
data/lib/snaptrade/version.rb
CHANGED
|
@@ -62,7 +62,7 @@ describe 'AccountInformationApi' do
|
|
|
62
62
|
|
|
63
63
|
# unit tests for get_all_account_positions
|
|
64
64
|
# List all account positions
|
|
65
|
-
# Returns a list of all positions in the specified account. The `results` list can contain multiple instrument types in the same response, including stocks, ADRs, ETFs, mutual funds, closed-end funds, crypto, futures, and option positions. Use the `instrument.kind` discriminator to determine the schema for each position's `instrument`.
|
|
65
|
+
# Returns a list of all positions in the specified account. The `results` list can contain multiple instrument types in the same response, including stocks, ADRs, ETFs, mutual funds, closed-end funds, crypto, futures, and option positions. Use the `instrument.kind` discriminator to determine the schema for each position's `instrument`. `mutualfund` positions may also include `cash_equivalent`. `stock` positions may include `tax_lots` when tax lot data is enabled for the account. If the connection has become disabled, it can no longer access the latest data from the brokerage, but will continue to return the last available cached state. Please see [this guide](/docs/fix-broken-connections) on how to fix a disabled connection.
|
|
66
66
|
# @param user_id
|
|
67
67
|
# @param user_secret
|
|
68
68
|
# @param account_id
|
|
@@ -193,7 +193,7 @@ describe 'AccountInformationApi' do
|
|
|
193
193
|
|
|
194
194
|
# unit tests for get_user_holdings
|
|
195
195
|
# List account holdings
|
|
196
|
-
#
|
|
196
|
+
# **Deprecated.** Use the finer-grained account data endpoints instead: [balances](/reference/Account%20Information/AccountInformation_getUserAccountBalance), [positions](/reference/Account%20Information/AccountInformation_getAllAccountPositions), and [orders](/reference/Account%20Information/AccountInformation_getUserAccountOrders). Returns a list of balances, positions, and recent orders for the specified account. Check your API key on the [Customer Dashboard billing page](https://dashboard.snaptrade.com/settings/billing) to see if you have real-time data access: - If you do, this endpoint returns real-time data. - If you don't, the data is cached and refreshed once a day. How long the data is cached for varies by brokerage. Check the [brokerage integrations doc](https://support.snaptrade.com/brokerages-table?v=d16c4c97b8d5438bbb2d8581ac53b11e) and look for \"Cache Expiry Time\" to see the exact value for a specific brokerage. If you need real-time, use the [manual refresh](/reference/Connections/Connections_refreshBrokerageAuthorization) endpoint. If the connection has become disabled, it can no longer access the latest data from the brokerage, but will continue to return the last available cached state. Please see [this guide](/docs/fix-broken-connections) on how to fix a disabled connection.
|
|
197
197
|
# @param account_id
|
|
198
198
|
# @param user_id
|
|
199
199
|
# @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.193
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- SnapTrade
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-05-
|
|
11
|
+
date: 2026-05-12 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: faraday
|