snaptrade 1.6.0 → 1.7.0

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: 14075a4d12a4c260869173b2e8192facd70bf9447f4ff4c40b1731b0cb1164d2
4
- data.tar.gz: 501d4d74ea5f545afb73d283258ba9887c281f154081133176c576d4579b2c98
3
+ metadata.gz: 1769673c853617ca0e94a2acc4eaadaba1831a2971f291b80c576ca7e5464dd2
4
+ data.tar.gz: 5c5c775a28a00d28f89f8b20f6dc7461827295858ac259e5e27858a47b25c4d2
5
5
  SHA512:
6
- metadata.gz: 201c1932753bad106179cba4a7caffec2b31d5f51149d24f650c09bec64a303d91aa555549e465278f0f34533de6fb0c9c59cdbeae8732de8873c3f86227e36d
7
- data.tar.gz: bc4347bdeba124ad9cb39b911783de86f936e3e8660ae7cea4683fa455618a3d09ad92c8a1c5b23e54ee401fee55f90f1fc8402c9fb5ac574e9545c8f3476c12
6
+ metadata.gz: 868307b18a77b533051cb5cbeeb70b3e2e0d2d91459c975b676460472afc834fc12c52f352a0c56d86b8dd1609042a6dcba8a40107db387ba23ce03a3907b4d0
7
+ data.tar.gz: 9463a53e1b49cd98e299eb699c2ed6e223f2e3ab79deca8cf8ccd5f370fdb042f2d5e0252d55ed96c643784272311216e2a887da8be0fce92558f97cc4749fcd
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- snaptrade (1.6.0)
4
+ snaptrade (1.7.0)
5
5
  faraday (>= 1.0.1, < 3.0)
6
6
  faraday-multipart (~> 1.0, >= 1.0.4)
7
7
 
@@ -15,7 +15,7 @@ GEM
15
15
  irb (>= 1.5.0)
16
16
  reline (>= 0.3.1)
17
17
  diff-lcs (1.5.0)
18
- faraday (2.7.6)
18
+ faraday (2.7.7)
19
19
  faraday-net_http (>= 2.0, < 3.1)
20
20
  ruby2_keywords (>= 0.0.4)
21
21
  faraday-multipart (1.0.4)
data/README.md CHANGED
@@ -9,7 +9,7 @@ For more information, please visit [https://snaptrade.com/](https://snaptrade.co
9
9
  Add to Gemfile:
10
10
 
11
11
  ```ruby
12
- gem 'snaptrade', '~> 1.6.0'
12
+ gem 'snaptrade', '~> 1.7.0'
13
13
  ```
14
14
 
15
15
  ## Getting Started
@@ -16,7 +16,7 @@
16
16
  | **filled_quantity** | **Float** | Trade Units | [optional] |
17
17
  | **execution_price** | **Float** | Trade Price if limit or stop limit order | [optional] |
18
18
  | **limit_price** | **Float** | Trade Price if limit or stop limit order | [optional] |
19
- | **stop_price** | **Float** | Trade Price if limit or stop limit order | [optional] |
19
+ | **stop_price** | **Float** | Stop Price. If stop loss or stop limit order, the price to trigger the stop | [optional] |
20
20
  | **order_type** | [**OrderType**](OrderType.md) | | [optional] |
21
21
  | **time_in_force** | [**TimeInForce**](TimeInForce.md) | | [optional] |
22
22
  | **time_placed** | **String** | Time | [optional] |
@@ -1991,6 +1991,7 @@ symbol = {
1991
1991
  percent = 90
1992
1992
  is_supported = True
1993
1993
  is_excluded = True
1994
+ meta = {}
1994
1995
 
1995
1996
  begin
1996
1997
  # Update a TargetAsset under the specified PortfolioGroup.
@@ -2002,6 +2003,7 @@ begin
2002
2003
  percent: percent,
2003
2004
  is_supported: is_supported,
2004
2005
  is_excluded: is_excluded,
2006
+ meta: meta,
2005
2007
  )
2006
2008
  p result
2007
2009
  rescue SnapTrade::ApiError => e
@@ -2026,6 +2028,7 @@ symbol = {
2026
2028
  percent = 90
2027
2029
  is_supported = True
2028
2030
  is_excluded = True
2031
+ meta = {}
2029
2032
 
2030
2033
  begin
2031
2034
  # Update a TargetAsset under the specified PortfolioGroup.
@@ -2037,6 +2040,7 @@ begin
2037
2040
  percent: percent,
2038
2041
  is_supported: is_supported,
2039
2042
  is_excluded: is_excluded,
2043
+ meta: meta,
2040
2044
  )
2041
2045
  p status_code # => 2xx
2042
2046
  p headers # => { ... }
@@ -2742,15 +2742,17 @@ module SnapTrade
2742
2742
  # @param percent [Float]
2743
2743
  # @param is_supported [Boolean]
2744
2744
  # @param is_excluded [Boolean]
2745
+ # @param meta [Hash<String, Object>]
2745
2746
  # @param body [TargetAsset]
2746
2747
  # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
2747
- def update_portfolio_target_by_id(portfolio_group_id:, target_asset_id:, id: SENTINEL, symbol: SENTINEL, percent: SENTINEL, is_supported: SENTINEL, is_excluded: SENTINEL, extra: {})
2748
+ def update_portfolio_target_by_id(portfolio_group_id:, target_asset_id:, id: SENTINEL, symbol: SENTINEL, percent: SENTINEL, is_supported: SENTINEL, is_excluded: SENTINEL, meta: SENTINEL, extra: {})
2748
2749
  _body = {}
2749
2750
  _body[:id] = id if id != SENTINEL
2750
2751
  _body[:symbol] = symbol if symbol != SENTINEL
2751
2752
  _body[:percent] = percent if percent != SENTINEL
2752
2753
  _body[:is_supported] = is_supported if is_supported != SENTINEL
2753
2754
  _body[:is_excluded] = is_excluded if is_excluded != SENTINEL
2755
+ _body[:meta] = meta if meta != SENTINEL
2754
2756
  target_asset = _body
2755
2757
 
2756
2758
  data, _status_code, _headers = update_portfolio_target_by_id_with_http_info_impl(portfolio_group_id, target_asset_id, target_asset, extra)
@@ -2765,15 +2767,17 @@ module SnapTrade
2765
2767
  # @param percent [Float]
2766
2768
  # @param is_supported [Boolean]
2767
2769
  # @param is_excluded [Boolean]
2770
+ # @param meta [Hash<String, Object>]
2768
2771
  # @param body [TargetAsset]
2769
2772
  # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
2770
- def update_portfolio_target_by_id_with_http_info(portfolio_group_id:, target_asset_id:, id: SENTINEL, symbol: SENTINEL, percent: SENTINEL, is_supported: SENTINEL, is_excluded: SENTINEL, extra: {})
2773
+ def update_portfolio_target_by_id_with_http_info(portfolio_group_id:, target_asset_id:, id: SENTINEL, symbol: SENTINEL, percent: SENTINEL, is_supported: SENTINEL, is_excluded: SENTINEL, meta: SENTINEL, extra: {})
2771
2774
  _body = {}
2772
2775
  _body[:id] = id if id != SENTINEL
2773
2776
  _body[:symbol] = symbol if symbol != SENTINEL
2774
2777
  _body[:percent] = percent if percent != SENTINEL
2775
2778
  _body[:is_supported] = is_supported if is_supported != SENTINEL
2776
2779
  _body[:is_excluded] = is_excluded if is_excluded != SENTINEL
2780
+ _body[:meta] = meta if meta != SENTINEL
2777
2781
  target_asset = _body
2778
2782
 
2779
2783
  update_portfolio_target_by_id_with_http_info_impl(portfolio_group_id, target_asset_id, target_asset, extra)
@@ -45,7 +45,7 @@ module SnapTrade
45
45
  # Trade Price if limit or stop limit order
46
46
  attr_accessor :limit_price
47
47
 
48
- # Trade Price if limit or stop limit order
48
+ # Stop Price. If stop loss or stop limit order, the price to trigger the stop
49
49
  attr_accessor :stop_price
50
50
 
51
51
  attr_accessor :order_type
@@ -117,6 +117,9 @@ module SnapTrade
117
117
  # List of attributes with nullable: true
118
118
  def self.openapi_nullable
119
119
  Set.new([
120
+ :'open_quantity',
121
+ :'canceled_quantity',
122
+ :'filled_quantity',
120
123
  :'execution_price',
121
124
  :'limit_price',
122
125
  :'stop_price',
@@ -9,5 +9,5 @@ Contact: api@snaptrade.com
9
9
  =end
10
10
 
11
11
  module SnapTrade
12
- VERSION = '1.6.0'
12
+ VERSION = '1.7.0'
13
13
  end
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: 1.6.0
4
+ version: 1.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - SnapTrade
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-06-13 00:00:00.000000000 Z
11
+ date: 2023-06-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday