snaptrade 2.0.10 → 2.0.11

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: 0130fc8648616d97147b5551e18bb8398f9aff59da30dfea88bc6b0ac4e47d8a
4
- data.tar.gz: b54d55b20054ff17e6cc0ab9e0b3cdcf73c8c1ce0a2e944b87e20a79a2b6c211
3
+ metadata.gz: 2bfbd727c7a26875a01440c29a79f5bda33a674cd414dbc629e08fe154a05ba4
4
+ data.tar.gz: e66bdf08d806e98a23771c8bf535284d6a9272aabec2b45efaa5c7b7379b0873
5
5
  SHA512:
6
- metadata.gz: 9ab9d690927682bf09ba21c79c4bcde054e997e37127c92b7d49e756b0cb618099802fc1f1b9735b8869353f8497be0f2ff292cb7f424304eb4a692b2647bae5
7
- data.tar.gz: 5c07cce9b0b3f463d2290693d8d8d836ca782400c8d126713f2ef5794e84ba630ec2a394d04656d1815068713068fc1b3daaf2dad683cbcfe476a01a5d5e47ae
6
+ metadata.gz: bdfcb22e02ba35317fe08de340b986733de2d386f49589090a3505b3ff218f23dd5bc13b84109f75e27ac8a9abc5971d3eda25b0c27406fd6b8dd6759ef98351
7
+ data.tar.gz: 87af6400f2d03b7d25a3c0d13dd9b7ef76b88f65205757a0ebe5c83ed4ddfc777d13dd9aab39374d96750bc189ba89a5b00c4f8caf537a12f91b0425eb09c002
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- snaptrade (2.0.10)
4
+ snaptrade (2.0.11)
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.10-blue)](https://rubygems.org/gems/snaptrade/versions/2.0.10)
9
+ [![npm](https://img.shields.io/badge/gem-v2.0.11-blue)](https://rubygems.org/gems/snaptrade/versions/2.0.11)
10
10
  [![More Info](https://img.shields.io/badge/More%20Info-Click%20Here-orange)](https://snaptrade.com/)
11
11
 
12
12
  </div>
@@ -71,7 +71,7 @@ Connect brokerage accounts to your app for live positions and trading
71
71
  Add to Gemfile:
72
72
 
73
73
  ```ruby
74
- gem 'snaptrade', '~> 2.0.10'
74
+ gem 'snaptrade', '~> 2.0.11'
75
75
  ```
76
76
 
77
77
  ## Getting Started<a id="getting-started"></a>
@@ -19,6 +19,8 @@ module SnapTrade
19
19
 
20
20
  attr_accessor :positions
21
21
 
22
+ attr_accessor :option_postions
23
+
22
24
  attr_accessor :orders
23
25
 
24
26
  attr_accessor :total_value
@@ -29,6 +31,7 @@ module SnapTrade
29
31
  :'account' => :'account',
30
32
  :'balances' => :'balances',
31
33
  :'positions' => :'positions',
34
+ :'option_postions' => :'option_postions',
32
35
  :'orders' => :'orders',
33
36
  :'total_value' => :'total_value'
34
37
  }
@@ -45,6 +48,7 @@ module SnapTrade
45
48
  :'account' => :'SnapTradeHoldingsAccountAccountId',
46
49
  :'balances' => :'Array<Balance>',
47
50
  :'positions' => :'Array<Position>',
51
+ :'option_postions' => :'Array<OptionsPosition>',
48
52
  :'orders' => :'Array<AccountOrderRecord>',
49
53
  :'total_value' => :'SnapTradeHoldingsTotalValue'
50
54
  }
@@ -55,6 +59,7 @@ module SnapTrade
55
59
  Set.new([
56
60
  :'balances',
57
61
  :'positions',
62
+ :'option_postions',
58
63
  :'orders',
59
64
  ])
60
65
  end
@@ -90,6 +95,12 @@ module SnapTrade
90
95
  end
91
96
  end
92
97
 
98
+ if attributes.key?(:'option_postions')
99
+ if (value = attributes[:'option_postions']).is_a?(Array)
100
+ self.option_postions = value
101
+ end
102
+ end
103
+
93
104
  if attributes.key?(:'orders')
94
105
  if (value = attributes[:'orders']).is_a?(Array)
95
106
  self.orders = value
@@ -122,6 +133,7 @@ module SnapTrade
122
133
  account == o.account &&
123
134
  balances == o.balances &&
124
135
  positions == o.positions &&
136
+ option_postions == o.option_postions &&
125
137
  orders == o.orders &&
126
138
  total_value == o.total_value
127
139
  end
@@ -135,7 +147,7 @@ module SnapTrade
135
147
  # Calculates hash code according to all attributes.
136
148
  # @return [Integer] Hash code
137
149
  def hash
138
- [account, balances, positions, orders, total_value].hash
150
+ [account, balances, positions, option_postions, orders, total_value].hash
139
151
  end
140
152
 
141
153
  # Builds the object from hash
@@ -8,5 +8,5 @@ Contact: api@snaptrade.com
8
8
  =end
9
9
 
10
10
  module SnapTrade
11
- VERSION = '2.0.10'
11
+ VERSION = '2.0.11'
12
12
  end
@@ -38,6 +38,12 @@ describe SnapTrade::AccountHoldingsAccount do
38
38
  end
39
39
  end
40
40
 
41
+ describe 'test attribute "option_postions"' do
42
+ it 'should work' do
43
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
44
+ end
45
+ end
46
+
41
47
  describe 'test attribute "orders"' do
42
48
  it 'should work' do
43
49
  # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
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.10
4
+ version: 2.0.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - SnapTrade
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-03-12 00:00:00.000000000 Z
11
+ date: 2024-03-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday