alpaca-trade-api 0.7.0 → 0.8.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: dd1c174ba5c6598f9887738ad9cc14250e1dfb90e20c7566bccdf7f1e293c130
4
- data.tar.gz: 7855a473230181b698498c453bde427e82abb4c6d425828b461a24bb2b42ae1b
3
+ metadata.gz: 4655ddb2a2cedffa2c5eb1f5eb76fccb77077ae877f2b35a1becf22f50524946
4
+ data.tar.gz: 357663cde64a002a63fa9810984320184774edd5581fca1ae93dd3daa489e1a5
5
5
  SHA512:
6
- metadata.gz: bb7a080c7f81b837d0d330b2f5df96a5fe437a5be4223513cca9ba6156fbb127da56aaeed7e130c8565381264f9687def53afa6e61a395368052c942a4c94210
7
- data.tar.gz: d95a17099844cb82780b00f00e570362247f5739092029b8696b97b9222aba758ba1e4b499094a615b8adc88acad0f1df2aa7b8f0302d8749c75745031cf4d54
6
+ metadata.gz: aa58e42529f6901b14a010d9e406477744d2d15f64bc549983b082e4bd6ea9b771cd8ba2cae4df32efcf1dfd2aac21ebb7c6f9a8a61464f7991c59ba11ae2020
7
+ data.tar.gz: e79db3dbd7a4e0bd788e2930bbba1f0dc9cbe1f7949532f6495b5bd04f1b48fdd5e494c735c8c9fc83a0277638fd73556073cb8ba7c60551e4f043d9967389ef
data/Gemfile.lock CHANGED
@@ -7,46 +7,46 @@ PATH
7
7
  GEM
8
8
  remote: https://rubygems.org/
9
9
  specs:
10
- addressable (2.6.0)
11
- public_suffix (>= 2.0.2, < 4.0)
12
- byebug (11.0.1)
13
- crack (0.4.3)
14
- safe_yaml (~> 1.0.0)
15
- diff-lcs (1.3)
16
- docile (1.3.2)
10
+ addressable (2.7.0)
11
+ public_suffix (>= 2.0.2, < 5.0)
12
+ byebug (11.1.3)
13
+ crack (0.4.5)
14
+ rexml
15
+ diff-lcs (1.4.4)
16
+ docile (1.3.5)
17
17
  faraday (1.3.0)
18
18
  faraday-net_http (~> 1.0)
19
19
  multipart-post (>= 1.2, < 3)
20
20
  ruby2_keywords
21
21
  faraday-net_http (1.0.1)
22
- hashdiff (0.4.0)
23
- json (2.2.0)
22
+ hashdiff (1.0.1)
24
23
  multipart-post (2.1.1)
25
- public_suffix (3.1.1)
26
- rake (13.0.1)
24
+ public_suffix (4.0.6)
25
+ rake (13.0.3)
27
26
  rb-readline (0.5.5)
28
- rspec (3.8.0)
29
- rspec-core (~> 3.8.0)
30
- rspec-expectations (~> 3.8.0)
31
- rspec-mocks (~> 3.8.0)
32
- rspec-core (3.8.2)
33
- rspec-support (~> 3.8.0)
34
- rspec-expectations (3.8.4)
27
+ rexml (3.2.4)
28
+ rspec (3.10.0)
29
+ rspec-core (~> 3.10.0)
30
+ rspec-expectations (~> 3.10.0)
31
+ rspec-mocks (~> 3.10.0)
32
+ rspec-core (3.10.1)
33
+ rspec-support (~> 3.10.0)
34
+ rspec-expectations (3.10.1)
35
35
  diff-lcs (>= 1.2.0, < 2.0)
36
- rspec-support (~> 3.8.0)
37
- rspec-mocks (3.8.1)
36
+ rspec-support (~> 3.10.0)
37
+ rspec-mocks (3.10.2)
38
38
  diff-lcs (>= 1.2.0, < 2.0)
39
- rspec-support (~> 3.8.0)
40
- rspec-support (3.8.2)
39
+ rspec-support (~> 3.10.0)
40
+ rspec-support (3.10.2)
41
41
  ruby2_keywords (0.0.4)
42
- safe_yaml (1.0.5)
43
- simplecov (0.16.1)
42
+ simplecov (0.21.2)
44
43
  docile (~> 1.1)
45
- json (>= 1.8, < 3)
46
- simplecov-html (~> 0.10.0)
47
- simplecov-html (0.10.2)
48
- vcr (5.0.0)
49
- webmock (3.6.0)
44
+ simplecov-html (~> 0.11)
45
+ simplecov_json_formatter (~> 0.1)
46
+ simplecov-html (0.12.3)
47
+ simplecov_json_formatter (0.1.2)
48
+ vcr (5.1.0)
49
+ webmock (3.12.0)
50
50
  addressable (>= 2.3.6)
51
51
  crack (>= 0.3.2)
52
52
  hashdiff (>= 0.4.0, < 2.0.0)
@@ -5,7 +5,7 @@ module Alpaca
5
5
  module Api
6
6
  class Asset
7
7
  attr_reader :id, :asset_class, :exchange, :symbol, :status, :tradable, :marginable,
8
- :shortable, :easy_to_borrow
8
+ :shortable, :easy_to_borrow, :fractionable
9
9
 
10
10
  def initialize(json)
11
11
  @id = json['id']
@@ -17,6 +17,7 @@ module Alpaca
17
17
  @marginable = json['marginable']
18
18
  @shortable = json['shortable']
19
19
  @easy_to_borrow = json['easy_to_borrow']
20
+ @fractionable = json['fractionable']
20
21
  end
21
22
  end
22
23
  end
@@ -112,16 +112,17 @@ module Alpaca
112
112
  LastTrade.new(JSON.parse(response.body))
113
113
  end
114
114
 
115
- def new_order(symbol:, qty:, side:, type:, time_in_force:, limit_price: nil,
116
- stop_price: nil, extended_hours: false, client_order_id: nil, order_class: nil,
117
- take_profit: nil, stop_loss: nil)
115
+ def new_order(symbol:, side:, type:, time_in_force:, qty: nil, notional: nil,
116
+ limit_price: nil, stop_price: nil, extended_hours: false, client_order_id: nil,
117
+ order_class: nil, take_profit: nil, stop_loss: nil)
118
118
 
119
119
  params = {
120
120
  symbol: symbol,
121
- qty: qty,
122
121
  side: side,
123
122
  type: type,
124
123
  time_in_force: time_in_force,
124
+ qty: qty,
125
+ notional: notional,
125
126
  limit_price: limit_price,
126
127
  order_class: order_class,
127
128
  stop_price: stop_price,
@@ -3,7 +3,7 @@
3
3
  module Alpaca
4
4
  module Trade
5
5
  module Api
6
- VERSION = '0.7.0'
6
+ VERSION = '0.8.0'
7
7
  end
8
8
  end
9
9
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: alpaca-trade-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.0
4
+ version: 0.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cloves Carneiro Jr
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-02-28 00:00:00.000000000 Z
11
+ date: 2021-04-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler