snaptrade 2.0.115 → 2.0.116

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: 289f8f6b3dd3b14d2f30c87e69895b56466bc3a7bf1520e8cc3086d982875764
4
- data.tar.gz: c7235747e9001f46554d09b8b5cc4d9cc272f54c03e2d528e14faf44f8f91d5a
3
+ metadata.gz: 286bc72cce7d1cedbfdbb66011245dfdca9ad4d1639aeb1fccd7321bfbc991a3
4
+ data.tar.gz: 3f3cd48fa580c1045df50c4a9cfef7375d023bcdc6dbf1da7d5d0886c58ed03b
5
5
  SHA512:
6
- metadata.gz: 0c418a315f398d1ee0e2f448922208e75c12493da92a4573295704e401773bf0c1a3400790273173cf2c273536468491279ea46d266d989a5af8bdc187e1f505
7
- data.tar.gz: 9324b3c512006aa4a1c674f258b76beffc0c2aed1223fa8bd6160abb3a30631d61ed1f55986bf56564c99dbb47267b94c0fe0c01b57c9bee75ce81a66927286c
6
+ metadata.gz: f64fb103fde2f463dce48793529c00452040b1f4b5d204c27e6687b0823a12b998a4b0fc4896d9506036b99a7e02fc58b4ad5095a6c540194a679aa901ff5e86
7
+ data.tar.gz: e171eb9563c35a6006e90d1579e2b10c51c520957151ab524aa8b19b6d2230406849f73a60730ea5db35b717233e3ce040b969b8f746fa9a3d9842713306093c
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- snaptrade (2.0.115)
4
+ snaptrade (2.0.116)
5
5
  faraday (>= 1.0.1, < 3.0)
6
6
  faraday-multipart (~> 1.0, >= 1.0.4)
7
7
 
@@ -43,7 +43,7 @@ GEM
43
43
  rainbow (3.1.1)
44
44
  rake (13.0.6)
45
45
  regexp_parser (2.10.0)
46
- reline (0.6.1)
46
+ reline (0.6.2)
47
47
  io-console (~> 0.5)
48
48
  rexml (3.4.1)
49
49
  rspec (3.13.1)
@@ -68,7 +68,7 @@ GEM
68
68
  rubocop-ast (>= 1.2.0, < 2.0)
69
69
  ruby-progressbar (~> 1.7)
70
70
  unicode-display_width (>= 1.4.0, < 3.0)
71
- rubocop-ast (1.45.1)
71
+ rubocop-ast (1.46.0)
72
72
  parser (>= 3.3.7.2)
73
73
  prism (~> 1.4)
74
74
  ruby-progressbar (1.13.0)
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.115-blue)](https://rubygems.org/gems/snaptrade/versions/2.0.115)
9
+ [![npm](https://img.shields.io/badge/gem-v2.0.116-blue)](https://rubygems.org/gems/snaptrade/versions/2.0.116)
10
10
  [![More Info](https://img.shields.io/badge/More%20Info-Click%20Here-orange)](https://snaptrade.com/)
11
11
 
12
12
  </div>
@@ -82,7 +82,7 @@ Connect brokerage accounts to your app for live positions and trading
82
82
  Add to Gemfile:
83
83
 
84
84
  ```ruby
85
- gem 'snaptrade', '~> 2.0.115'
85
+ gem 'snaptrade', '~> 2.0.116'
86
86
  ```
87
87
 
88
88
  ## Getting Started<a id="getting-started"></a>
@@ -2051,7 +2051,7 @@ The limit price. Required if the order type is LIMIT, STOP_LOSS_LIMIT.
2051
2051
  ##### stop_price: `Float`<a id="stop_price-float"></a>
2052
2052
  The stop price. Required if the order type is STOP_LOSS_MARKET, STOP_LOSS_LIMIT.
2053
2053
 
2054
- ##### price_effect: [`String`](./lib/snaptrade/models/string.rb)<a id="price_effect-stringlibsnaptrademodelsstringrb"></a>
2054
+ ##### price_effect: [`MlegPriceEffectStrict`](./lib/snaptrade/models/mleg_price_effect_strict.rb)<a id="price_effect-mlegpriceeffectstrictlibsnaptrademodelsmleg_price_effect_strictrb"></a>
2055
2055
  #### 🔄 Return<a id="🔄-return"></a>
2056
2056
 
2057
2057
  [MlegOrderResponse](./lib/snaptrade/models/mleg_order_response.rb)
@@ -964,7 +964,7 @@ module SnapTrade
964
964
  # @param account_id [String]
965
965
  # @param limit_price [Float] The limit price. Required if the order type is LIMIT, STOP_LOSS_LIMIT.
966
966
  # @param stop_price [Float] The stop price. Required if the order type is STOP_LOSS_MARKET, STOP_LOSS_LIMIT.
967
- # @param price_effect [String]
967
+ # @param price_effect [MlegPriceEffectStrict]
968
968
  # @param body [MlegTradeForm]
969
969
  # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
970
970
  def place_mleg_order(order_type:, time_in_force:, legs:, user_id:, user_secret:, account_id:, limit_price: SENTINEL, stop_price: SENTINEL, price_effect: SENTINEL, extra: {})
@@ -992,7 +992,7 @@ module SnapTrade
992
992
  # @param account_id [String]
993
993
  # @param limit_price [Float] The limit price. Required if the order type is LIMIT, STOP_LOSS_LIMIT.
994
994
  # @param stop_price [Float] The stop price. Required if the order type is STOP_LOSS_MARKET, STOP_LOSS_LIMIT.
995
- # @param price_effect [String]
995
+ # @param price_effect [MlegPriceEffectStrict]
996
996
  # @param body [MlegTradeForm]
997
997
  # @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
998
998
  def place_mleg_order_with_http_info(order_type:, time_in_force:, legs:, user_id:, user_secret:, account_id:, limit_price: SENTINEL, stop_price: SENTINEL, price_effect: SENTINEL, extra: {})
@@ -0,0 +1,38 @@
1
+ =begin
2
+ #SnapTrade
3
+
4
+ #Connect brokerage accounts to your app for live positions and trading
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+ Contact: api@snaptrade.com
8
+ =end
9
+
10
+ require 'date'
11
+ require 'time'
12
+
13
+ module SnapTrade
14
+ class MlegPriceEffectStrict
15
+ CREDIT = "CREDIT".freeze
16
+ DEBIT = "DEBIT".freeze
17
+ EVEN = "EVEN".freeze
18
+
19
+ def self.all_vars
20
+ @all_vars ||= [CREDIT, DEBIT, EVEN].freeze
21
+ end
22
+
23
+ # Builds the enum from string
24
+ # @param [String] The enum value in the form of the string
25
+ # @return [String] The enum value
26
+ def self.build_from_hash(value)
27
+ new.build_from_hash(value)
28
+ end
29
+
30
+ # Builds the enum from string
31
+ # @param [String] The enum value in the form of the string
32
+ # @return [String] The enum value
33
+ def build_from_hash(value)
34
+ return value if MlegPriceEffectStrict.all_vars.include?(value)
35
+ raise "Invalid ENUM value #{value} for class #MlegPriceEffectStrict"
36
+ end
37
+ end
38
+ end
@@ -53,7 +53,7 @@ module SnapTrade
53
53
  :'time_in_force' => :'TimeInForceStrict',
54
54
  :'limit_price' => :'Float',
55
55
  :'stop_price' => :'Float',
56
- :'price_effect' => :'String',
56
+ :'price_effect' => :'MlegPriceEffectStrict',
57
57
  :'legs' => :'Array<MlegLeg>'
58
58
  }
59
59
  end
@@ -8,5 +8,5 @@ Contact: api@snaptrade.com
8
8
  =end
9
9
 
10
10
  module SnapTrade
11
- VERSION = '2.0.115'
11
+ VERSION = '2.0.116'
12
12
  end
data/lib/snaptrade.rb CHANGED
@@ -79,6 +79,7 @@ require 'snaptrade/models/mleg_instrument_type'
79
79
  require 'snaptrade/models/mleg_leg'
80
80
  require 'snaptrade/models/mleg_order_response'
81
81
  require 'snaptrade/models/mleg_order_type_strict'
82
+ require 'snaptrade/models/mleg_price_effect_strict'
82
83
  require 'snaptrade/models/mleg_trade_form'
83
84
  require 'snaptrade/models/mleg_trading_instrument'
84
85
  require 'snaptrade/models/model400_failed_request_response'
@@ -0,0 +1,23 @@
1
+ =begin
2
+ #SnapTrade
3
+
4
+ #Connect brokerage accounts to your app for live positions and trading
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+ Contact: api@snaptrade.com
8
+ =end
9
+
10
+ require 'spec_helper'
11
+ require 'json'
12
+ require 'date'
13
+
14
+ # Unit tests for SnapTrade::MlegPriceEffectStrict
15
+ describe SnapTrade::MlegPriceEffectStrict do
16
+ let(:instance) { SnapTrade::MlegPriceEffectStrict.new }
17
+
18
+ describe 'test an instance of MlegPriceEffectStrict' do
19
+ it 'should create an instance of MlegPriceEffectStrict' do
20
+ expect(instance).to be_instance_of(SnapTrade::MlegPriceEffectStrict)
21
+ end
22
+ end
23
+ 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: 2.0.115
4
+ version: 2.0.116
5
5
  platform: ruby
6
6
  authors:
7
7
  - SnapTrade
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-07-15 00:00:00.000000000 Z
11
+ date: 2025-07-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -158,6 +158,7 @@ files:
158
158
  - lib/snaptrade/models/mleg_leg.rb
159
159
  - lib/snaptrade/models/mleg_order_response.rb
160
160
  - lib/snaptrade/models/mleg_order_type_strict.rb
161
+ - lib/snaptrade/models/mleg_price_effect_strict.rb
161
162
  - lib/snaptrade/models/mleg_trade_form.rb
162
163
  - lib/snaptrade/models/mleg_trading_instrument.rb
163
164
  - lib/snaptrade/models/model400_failed_request_response.rb
@@ -318,6 +319,7 @@ files:
318
319
  - spec/models/mleg_leg_spec.rb
319
320
  - spec/models/mleg_order_response_spec.rb
320
321
  - spec/models/mleg_order_type_strict_spec.rb
322
+ - spec/models/mleg_price_effect_strict_spec.rb
321
323
  - spec/models/mleg_trade_form_spec.rb
322
324
  - spec/models/mleg_trading_instrument_spec.rb
323
325
  - spec/models/model400_failed_request_response_spec.rb
@@ -516,6 +518,7 @@ test_files:
516
518
  - spec/models/universal_activity_spec.rb
517
519
  - spec/models/account_sync_status_spec.rb
518
520
  - spec/models/mleg_trade_form_spec.rb
521
+ - spec/models/mleg_price_effect_strict_spec.rb
519
522
  - spec/models/options_position_spec.rb
520
523
  - spec/models/manual_trade_spec.rb
521
524
  - spec/models/time_in_force_strict_spec.rb