snaptrade 2.0.96 → 2.0.98
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 +4 -4
- data/README.md +5 -5
- data/lib/snaptrade/api/trading_api.rb +6 -6
- data/lib/snaptrade/models/{mleg_trading_instrument_type.rb → mleg_instrument_type.rb} +3 -3
- data/lib/snaptrade/models/{mleg_order_request_body_type.rb → mleg_order_type_strict.rb} +3 -3
- data/lib/snaptrade/models/mleg_trading_instrument.rb +10 -10
- data/lib/snaptrade/models/trading_place_mleg_order_request.rb +10 -10
- data/lib/snaptrade/version.rb +1 -1
- data/lib/snaptrade.rb +2 -2
- data/spec/models/mleg_instrument_type_spec.rb +23 -0
- data/spec/models/mleg_order_type_strict_spec.rb +23 -0
- data/spec/models/mleg_trading_instrument_spec.rb +1 -1
- data/spec/models/trading_place_mleg_order_request_spec.rb +1 -1
- metadata +134 -134
- data/spec/models/mleg_order_request_body_type_spec.rb +0 -23
- data/spec/models/mleg_trading_instrument_type_spec.rb +0 -23
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dbb3a7c6a8a254744c5fb4b9dab60bb4f04727f08bf1e9ce9a7e4e2310d22da2
|
4
|
+
data.tar.gz: 8b2aad12663cfa9dc10ef26017c0493851b3fa683cf0c9f4cab1efecbda7eebe
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b9e5056402e94e440cf0db0f25eaf40864d5574c85453341b0015d18c68df5dff9fc6f4664169b307019c9c390707b9a9af538b0c1ec544e673c3791ebc67332
|
7
|
+
data.tar.gz: 16f1a44e855952124afa548a2ea4a92a74e40d32484d22cb3c00807b8c9321d02d418729b345a7f1ca41246b12bc685372704f6f30386515d2011d2b7e0e7ae1
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
snaptrade (2.0.
|
4
|
+
snaptrade (2.0.98)
|
5
5
|
faraday (>= 1.0.1, < 3.0)
|
6
6
|
faraday-multipart (~> 1.0, >= 1.0.4)
|
7
7
|
|
@@ -52,13 +52,13 @@ GEM
|
|
52
52
|
rspec-mocks (~> 3.13.0)
|
53
53
|
rspec-core (3.13.3)
|
54
54
|
rspec-support (~> 3.13.0)
|
55
|
-
rspec-expectations (3.13.
|
55
|
+
rspec-expectations (3.13.4)
|
56
56
|
diff-lcs (>= 1.2.0, < 2.0)
|
57
57
|
rspec-support (~> 3.13.0)
|
58
|
-
rspec-mocks (3.13.
|
58
|
+
rspec-mocks (3.13.4)
|
59
59
|
diff-lcs (>= 1.2.0, < 2.0)
|
60
60
|
rspec-support (~> 3.13.0)
|
61
|
-
rspec-support (3.13.
|
61
|
+
rspec-support (3.13.3)
|
62
62
|
rubocop (1.12.1)
|
63
63
|
parallel (~> 1.10)
|
64
64
|
parser (>= 3.0.0.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
|
-
[](https://rubygems.org/gems/snaptrade/versions/2.0.98)
|
10
10
|
[](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.
|
85
|
+
gem 'snaptrade', '~> 2.0.98'
|
86
86
|
```
|
87
87
|
|
88
88
|
## Getting Started<a id="getting-started"></a>
|
@@ -2004,13 +2004,13 @@ Places a multi-leg option order. Only supported on certain option trading broker
|
|
2004
2004
|
|
2005
2005
|
```ruby
|
2006
2006
|
result = snaptrade.trading.place_mleg_order(
|
2007
|
-
|
2007
|
+
order_type: "MARKET",
|
2008
2008
|
time_in_force: "Day",
|
2009
2009
|
legs: [
|
2010
2010
|
{
|
2011
2011
|
"instrument" => {
|
2012
2012
|
"symbol" => "PBI 250718C00006000",
|
2013
|
-
"
|
2013
|
+
"instrument_type" => "OPTION",
|
2014
2014
|
},
|
2015
2015
|
"action" => "BUY_TO_OPEN",
|
2016
2016
|
"units" => 1,
|
@@ -2027,7 +2027,7 @@ p result
|
|
2027
2027
|
|
2028
2028
|
#### ⚙️ Parameters<a id="⚙️-parameters"></a>
|
2029
2029
|
|
2030
|
-
#####
|
2030
|
+
##### order_type: [`MlegOrderTypeStrict`](./lib/snaptrade/models/mleg_order_type_strict.rb)<a id="order_type-mlegordertypestrictlibsnaptrademodelsmleg_order_type_strictrb"></a>
|
2031
2031
|
The type of order to place.
|
2032
2032
|
|
2033
2033
|
##### time_in_force: [`TimeInForceStrict`](./lib/snaptrade/models/time_in_force_strict.rb)<a id="time_in_force-timeinforcestrictlibsnaptrademodelstime_in_force_strictrb"></a>
|
@@ -956,7 +956,7 @@ module SnapTrade
|
|
956
956
|
#
|
957
957
|
# Places a multi-leg option order. Only supported on certain option trading brokerages. https://snaptrade.notion.site/brokerages has information on brokerage trading support
|
958
958
|
#
|
959
|
-
# @param
|
959
|
+
# @param order_type [MlegOrderTypeStrict] The type of order to place.
|
960
960
|
# @param time_in_force [TimeInForceStrict] The Time in Force type for the order. This field indicates how long the order will remain active before it is executed or expires. Here are the supported values: - `Day` - Day. The order is valid only for the trading day on which it is placed. - `GTC` - Good Til Canceled. The order is valid until it is executed or canceled. - `FOK` - Fill Or Kill. The order must be executed in its entirety immediately or be canceled completely. - `IOC` - Immediate Or Cancel. The order must be executed immediately. Any portion of the order that cannot be filled immediately will be canceled.
|
961
961
|
# @param legs [Array<MlegLeg>]
|
962
962
|
# @param user_id [String]
|
@@ -966,9 +966,9 @@ module SnapTrade
|
|
966
966
|
# @param stop_price [Float] The stop price. Required if the order type is STOP_LOSS_MARKET, STOP_LOSS_LIMIT.
|
967
967
|
# @param body [TradingPlaceMlegOrderRequest]
|
968
968
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
969
|
-
def place_mleg_order(
|
969
|
+
def place_mleg_order(order_type:, time_in_force:, legs:, user_id:, user_secret:, account_id:, limit_price: SENTINEL, stop_price: SENTINEL, extra: {})
|
970
970
|
_body = {}
|
971
|
-
_body[:
|
971
|
+
_body[:order_type] = order_type if order_type != SENTINEL
|
972
972
|
_body[:time_in_force] = time_in_force if time_in_force != SENTINEL
|
973
973
|
_body[:limit_price] = limit_price if limit_price != SENTINEL
|
974
974
|
_body[:stop_price] = stop_price if stop_price != SENTINEL
|
@@ -982,7 +982,7 @@ module SnapTrade
|
|
982
982
|
#
|
983
983
|
# Places a multi-leg option order. Only supported on certain option trading brokerages. https://snaptrade.notion.site/brokerages has information on brokerage trading support
|
984
984
|
#
|
985
|
-
# @param
|
985
|
+
# @param order_type [MlegOrderTypeStrict] The type of order to place.
|
986
986
|
# @param time_in_force [TimeInForceStrict] The Time in Force type for the order. This field indicates how long the order will remain active before it is executed or expires. Here are the supported values: - `Day` - Day. The order is valid only for the trading day on which it is placed. - `GTC` - Good Til Canceled. The order is valid until it is executed or canceled. - `FOK` - Fill Or Kill. The order must be executed in its entirety immediately or be canceled completely. - `IOC` - Immediate Or Cancel. The order must be executed immediately. Any portion of the order that cannot be filled immediately will be canceled.
|
987
987
|
# @param legs [Array<MlegLeg>]
|
988
988
|
# @param user_id [String]
|
@@ -992,9 +992,9 @@ module SnapTrade
|
|
992
992
|
# @param stop_price [Float] The stop price. Required if the order type is STOP_LOSS_MARKET, STOP_LOSS_LIMIT.
|
993
993
|
# @param body [TradingPlaceMlegOrderRequest]
|
994
994
|
# @param [Hash] extra additional parameters to pass along through :header_params, :query_params, or parameter name
|
995
|
-
def place_mleg_order_with_http_info(
|
995
|
+
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, extra: {})
|
996
996
|
_body = {}
|
997
|
-
_body[:
|
997
|
+
_body[:order_type] = order_type if order_type != SENTINEL
|
998
998
|
_body[:time_in_force] = time_in_force if time_in_force != SENTINEL
|
999
999
|
_body[:limit_price] = limit_price if limit_price != SENTINEL
|
1000
1000
|
_body[:stop_price] = stop_price if stop_price != SENTINEL
|
@@ -11,7 +11,7 @@ require 'date'
|
|
11
11
|
require 'time'
|
12
12
|
|
13
13
|
module SnapTrade
|
14
|
-
class
|
14
|
+
class MlegInstrumentType
|
15
15
|
OPTION = "OPTION".freeze
|
16
16
|
EQUITY = "EQUITY".freeze
|
17
17
|
|
@@ -30,8 +30,8 @@ module SnapTrade
|
|
30
30
|
# @param [String] The enum value in the form of the string
|
31
31
|
# @return [String] The enum value
|
32
32
|
def build_from_hash(value)
|
33
|
-
return value if
|
34
|
-
raise "Invalid ENUM value #{value} for class #
|
33
|
+
return value if MlegInstrumentType.all_vars.include?(value)
|
34
|
+
raise "Invalid ENUM value #{value} for class #MlegInstrumentType"
|
35
35
|
end
|
36
36
|
end
|
37
37
|
end
|
@@ -11,7 +11,7 @@ require 'date'
|
|
11
11
|
require 'time'
|
12
12
|
|
13
13
|
module SnapTrade
|
14
|
-
class
|
14
|
+
class MlegOrderTypeStrict
|
15
15
|
MARKET = "MARKET".freeze
|
16
16
|
LIMIT = "LIMIT".freeze
|
17
17
|
STOP_LOSS_MARKET = "STOP_LOSS_MARKET".freeze
|
@@ -32,8 +32,8 @@ module SnapTrade
|
|
32
32
|
# @param [String] The enum value in the form of the string
|
33
33
|
# @return [String] The enum value
|
34
34
|
def build_from_hash(value)
|
35
|
-
return value if
|
36
|
-
raise "Invalid ENUM value #{value} for class #
|
35
|
+
return value if MlegOrderTypeStrict.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #MlegOrderTypeStrict"
|
37
37
|
end
|
38
38
|
end
|
39
39
|
end
|
@@ -16,13 +16,13 @@ module SnapTrade
|
|
16
16
|
attr_accessor :symbol
|
17
17
|
|
18
18
|
# The instrument's type
|
19
|
-
attr_accessor :
|
19
|
+
attr_accessor :instrument_type
|
20
20
|
|
21
21
|
# Attribute mapping from ruby-style variable name to JSON key.
|
22
22
|
def self.attribute_map
|
23
23
|
{
|
24
24
|
:'symbol' => :'symbol',
|
25
|
-
:'
|
25
|
+
:'instrument_type' => :'instrument_type'
|
26
26
|
}
|
27
27
|
end
|
28
28
|
|
@@ -35,7 +35,7 @@ module SnapTrade
|
|
35
35
|
def self.openapi_types
|
36
36
|
{
|
37
37
|
:'symbol' => :'String',
|
38
|
-
:'
|
38
|
+
:'instrument_type' => :'MlegInstrumentType'
|
39
39
|
}
|
40
40
|
end
|
41
41
|
|
@@ -64,8 +64,8 @@ module SnapTrade
|
|
64
64
|
self.symbol = attributes[:'symbol']
|
65
65
|
end
|
66
66
|
|
67
|
-
if attributes.key?(:'
|
68
|
-
self.
|
67
|
+
if attributes.key?(:'instrument_type')
|
68
|
+
self.instrument_type = attributes[:'instrument_type']
|
69
69
|
end
|
70
70
|
end
|
71
71
|
|
@@ -77,8 +77,8 @@ module SnapTrade
|
|
77
77
|
invalid_properties.push('invalid value for "symbol", symbol cannot be nil.')
|
78
78
|
end
|
79
79
|
|
80
|
-
if @
|
81
|
-
invalid_properties.push('invalid value for "
|
80
|
+
if @instrument_type.nil?
|
81
|
+
invalid_properties.push('invalid value for "instrument_type", instrument_type cannot be nil.')
|
82
82
|
end
|
83
83
|
|
84
84
|
invalid_properties
|
@@ -88,7 +88,7 @@ module SnapTrade
|
|
88
88
|
# @return true if the model is valid
|
89
89
|
def valid?
|
90
90
|
return false if @symbol.nil?
|
91
|
-
return false if @
|
91
|
+
return false if @instrument_type.nil?
|
92
92
|
true
|
93
93
|
end
|
94
94
|
|
@@ -98,7 +98,7 @@ module SnapTrade
|
|
98
98
|
return true if self.equal?(o)
|
99
99
|
self.class == o.class &&
|
100
100
|
symbol == o.symbol &&
|
101
|
-
|
101
|
+
instrument_type == o.instrument_type
|
102
102
|
end
|
103
103
|
|
104
104
|
# @see the `==` method
|
@@ -110,7 +110,7 @@ module SnapTrade
|
|
110
110
|
# Calculates hash code according to all attributes.
|
111
111
|
# @return [Integer] Hash code
|
112
112
|
def hash
|
113
|
-
[symbol,
|
113
|
+
[symbol, instrument_type].hash
|
114
114
|
end
|
115
115
|
|
116
116
|
# Builds the object from hash
|
@@ -13,7 +13,7 @@ require 'time'
|
|
13
13
|
module SnapTrade
|
14
14
|
class TradingPlaceMlegOrderRequest
|
15
15
|
# The type of order to place.
|
16
|
-
attr_accessor :
|
16
|
+
attr_accessor :order_type
|
17
17
|
|
18
18
|
# The Time in Force type for the order. This field indicates how long the order will remain active before it is executed or expires. Here are the supported values: - `Day` - Day. The order is valid only for the trading day on which it is placed. - `GTC` - Good Til Canceled. The order is valid until it is executed or canceled. - `FOK` - Fill Or Kill. The order must be executed in its entirety immediately or be canceled completely. - `IOC` - Immediate Or Cancel. The order must be executed immediately. Any portion of the order that cannot be filled immediately will be canceled.
|
19
19
|
attr_accessor :time_in_force
|
@@ -29,7 +29,7 @@ module SnapTrade
|
|
29
29
|
# Attribute mapping from ruby-style variable name to JSON key.
|
30
30
|
def self.attribute_map
|
31
31
|
{
|
32
|
-
:'
|
32
|
+
:'order_type' => :'order_type',
|
33
33
|
:'time_in_force' => :'time_in_force',
|
34
34
|
:'limit_price' => :'limit_price',
|
35
35
|
:'stop_price' => :'stop_price',
|
@@ -45,7 +45,7 @@ module SnapTrade
|
|
45
45
|
# Attribute type mapping.
|
46
46
|
def self.openapi_types
|
47
47
|
{
|
48
|
-
:'
|
48
|
+
:'order_type' => :'MlegOrderTypeStrict',
|
49
49
|
:'time_in_force' => :'TimeInForceStrict',
|
50
50
|
:'limit_price' => :'Float',
|
51
51
|
:'stop_price' => :'Float',
|
@@ -76,8 +76,8 @@ module SnapTrade
|
|
76
76
|
h[k.to_sym] = v
|
77
77
|
}
|
78
78
|
|
79
|
-
if attributes.key?(:'
|
80
|
-
self.
|
79
|
+
if attributes.key?(:'order_type')
|
80
|
+
self.order_type = attributes[:'order_type']
|
81
81
|
end
|
82
82
|
|
83
83
|
if attributes.key?(:'time_in_force')
|
@@ -103,8 +103,8 @@ module SnapTrade
|
|
103
103
|
# @return Array for valid properties with the reasons
|
104
104
|
def list_invalid_properties
|
105
105
|
invalid_properties = Array.new
|
106
|
-
if @
|
107
|
-
invalid_properties.push('invalid value for "
|
106
|
+
if @order_type.nil?
|
107
|
+
invalid_properties.push('invalid value for "order_type", order_type cannot be nil.')
|
108
108
|
end
|
109
109
|
|
110
110
|
if @time_in_force.nil?
|
@@ -121,7 +121,7 @@ module SnapTrade
|
|
121
121
|
# Check to see if the all the properties in the model are valid
|
122
122
|
# @return true if the model is valid
|
123
123
|
def valid?
|
124
|
-
return false if @
|
124
|
+
return false if @order_type.nil?
|
125
125
|
return false if @time_in_force.nil?
|
126
126
|
return false if @legs.nil?
|
127
127
|
true
|
@@ -132,7 +132,7 @@ module SnapTrade
|
|
132
132
|
def ==(o)
|
133
133
|
return true if self.equal?(o)
|
134
134
|
self.class == o.class &&
|
135
|
-
|
135
|
+
order_type == o.order_type &&
|
136
136
|
time_in_force == o.time_in_force &&
|
137
137
|
limit_price == o.limit_price &&
|
138
138
|
stop_price == o.stop_price &&
|
@@ -148,7 +148,7 @@ module SnapTrade
|
|
148
148
|
# Calculates hash code according to all attributes.
|
149
149
|
# @return [Integer] Hash code
|
150
150
|
def hash
|
151
|
-
[
|
151
|
+
[order_type, time_in_force, limit_price, stop_price, legs].hash
|
152
152
|
end
|
153
153
|
|
154
154
|
# Builds the object from hash
|
data/lib/snaptrade/version.rb
CHANGED
data/lib/snaptrade.rb
CHANGED
@@ -75,11 +75,11 @@ require 'snaptrade/models/manual_trade_impact'
|
|
75
75
|
require 'snaptrade/models/manual_trade_replace_form'
|
76
76
|
require 'snaptrade/models/manual_trade_symbol'
|
77
77
|
require 'snaptrade/models/mleg_action_strict'
|
78
|
+
require 'snaptrade/models/mleg_instrument_type'
|
78
79
|
require 'snaptrade/models/mleg_leg'
|
79
|
-
require 'snaptrade/models/mleg_order_request_body_type'
|
80
80
|
require 'snaptrade/models/mleg_order_response'
|
81
|
+
require 'snaptrade/models/mleg_order_type_strict'
|
81
82
|
require 'snaptrade/models/mleg_trading_instrument'
|
82
|
-
require 'snaptrade/models/mleg_trading_instrument_type'
|
83
83
|
require 'snaptrade/models/model400_failed_request_response'
|
84
84
|
require 'snaptrade/models/model401_failed_request_response'
|
85
85
|
require 'snaptrade/models/model402_brokerage_auth_already_disabled_exception'
|
@@ -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::MlegInstrumentType
|
15
|
+
describe SnapTrade::MlegInstrumentType do
|
16
|
+
let(:instance) { SnapTrade::MlegInstrumentType.new }
|
17
|
+
|
18
|
+
describe 'test an instance of MlegInstrumentType' do
|
19
|
+
it 'should create an instance of MlegInstrumentType' do
|
20
|
+
expect(instance).to be_instance_of(SnapTrade::MlegInstrumentType)
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
@@ -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::MlegOrderTypeStrict
|
15
|
+
describe SnapTrade::MlegOrderTypeStrict do
|
16
|
+
let(:instance) { SnapTrade::MlegOrderTypeStrict.new }
|
17
|
+
|
18
|
+
describe 'test an instance of MlegOrderTypeStrict' do
|
19
|
+
it 'should create an instance of MlegOrderTypeStrict' do
|
20
|
+
expect(instance).to be_instance_of(SnapTrade::MlegOrderTypeStrict)
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
@@ -26,7 +26,7 @@ describe SnapTrade::MlegTradingInstrument do
|
|
26
26
|
end
|
27
27
|
end
|
28
28
|
|
29
|
-
describe 'test attribute "
|
29
|
+
describe 'test attribute "instrument_type"' do
|
30
30
|
it 'should work' do
|
31
31
|
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
32
32
|
end
|
@@ -20,7 +20,7 @@ describe SnapTrade::TradingPlaceMlegOrderRequest do
|
|
20
20
|
expect(instance).to be_instance_of(SnapTrade::TradingPlaceMlegOrderRequest)
|
21
21
|
end
|
22
22
|
end
|
23
|
-
describe 'test attribute "
|
23
|
+
describe 'test attribute "order_type"' do
|
24
24
|
it 'should work' do
|
25
25
|
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
26
26
|
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.
|
4
|
+
version: 2.0.98
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- SnapTrade
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-
|
11
|
+
date: 2025-05-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -154,11 +154,11 @@ files:
|
|
154
154
|
- lib/snaptrade/models/manual_trade_replace_form.rb
|
155
155
|
- lib/snaptrade/models/manual_trade_symbol.rb
|
156
156
|
- lib/snaptrade/models/mleg_action_strict.rb
|
157
|
+
- lib/snaptrade/models/mleg_instrument_type.rb
|
157
158
|
- lib/snaptrade/models/mleg_leg.rb
|
158
|
-
- lib/snaptrade/models/mleg_order_request_body_type.rb
|
159
159
|
- lib/snaptrade/models/mleg_order_response.rb
|
160
|
+
- lib/snaptrade/models/mleg_order_type_strict.rb
|
160
161
|
- lib/snaptrade/models/mleg_trading_instrument.rb
|
161
|
-
- lib/snaptrade/models/mleg_trading_instrument_type.rb
|
162
162
|
- lib/snaptrade/models/model400_failed_request_response.rb
|
163
163
|
- lib/snaptrade/models/model401_failed_request_response.rb
|
164
164
|
- lib/snaptrade/models/model402_brokerage_auth_already_disabled_exception.rb
|
@@ -313,11 +313,11 @@ files:
|
|
313
313
|
- spec/models/manual_trade_spec.rb
|
314
314
|
- spec/models/manual_trade_symbol_spec.rb
|
315
315
|
- spec/models/mleg_action_strict_spec.rb
|
316
|
+
- spec/models/mleg_instrument_type_spec.rb
|
316
317
|
- spec/models/mleg_leg_spec.rb
|
317
|
-
- spec/models/mleg_order_request_body_type_spec.rb
|
318
318
|
- spec/models/mleg_order_response_spec.rb
|
319
|
+
- spec/models/mleg_order_type_strict_spec.rb
|
319
320
|
- spec/models/mleg_trading_instrument_spec.rb
|
320
|
-
- spec/models/mleg_trading_instrument_type_spec.rb
|
321
321
|
- spec/models/model400_failed_request_response_spec.rb
|
322
322
|
- spec/models/model401_failed_request_response_spec.rb
|
323
323
|
- spec/models/model402_brokerage_auth_already_disabled_exception_spec.rb
|
@@ -427,161 +427,161 @@ signing_key:
|
|
427
427
|
specification_version: 4
|
428
428
|
summary: SnapTrade Ruby Gem
|
429
429
|
test_files:
|
430
|
-
- spec/api/authentication_api_spec.rb
|
431
430
|
- spec/api/api_status_api_spec.rb
|
432
431
|
- spec/api/reference_data_api_spec.rb
|
432
|
+
- spec/api/account_information_api_spec.rb
|
433
|
+
- spec/api/options_api_spec.rb
|
433
434
|
- spec/api/trading_api_spec.rb
|
434
435
|
- spec/api/connections_api_spec.rb
|
435
|
-
- spec/api/account_information_api_spec.rb
|
436
436
|
- spec/api/transactions_and_reporting_api_spec.rb
|
437
|
-
- spec/api/
|
437
|
+
- spec/api/authentication_api_spec.rb
|
438
438
|
- spec/api_client_spec.rb
|
439
439
|
- spec/configuration_spec.rb
|
440
440
|
- spec/getting_started_spec.rb
|
441
|
-
- spec/models/
|
442
|
-
- spec/models/
|
443
|
-
- spec/models/
|
444
|
-
- spec/models/
|
445
|
-
- spec/models/
|
446
|
-
- spec/models/
|
447
|
-
- spec/models/
|
448
|
-
- spec/models/option_leg_spec.rb
|
449
|
-
- spec/models/manual_trade_form_notional_value_spec.rb
|
450
|
-
- spec/models/login_redirect_uri_spec.rb
|
451
|
-
- spec/models/options_symbol_spec.rb
|
452
|
-
- spec/models/cryptocurrency_pair_spec.rb
|
453
|
-
- spec/models/account_sync_status_spec.rb
|
454
|
-
- spec/models/universal_symbol_spec.rb
|
455
|
-
- spec/models/model404_failed_request_response_spec.rb
|
441
|
+
- spec/models/stop_loss_spec.rb
|
442
|
+
- spec/models/options_get_option_strategy_request_spec.rb
|
443
|
+
- spec/models/type_spec.rb
|
444
|
+
- spec/models/brokerage_authorization_spec.rb
|
445
|
+
- spec/models/us_exchange_spec.rb
|
446
|
+
- spec/models/underlying_symbol_type_spec.rb
|
447
|
+
- spec/models/validated_trade_body_spec.rb
|
456
448
|
- spec/models/account_order_record_universal_symbol_spec.rb
|
457
|
-
- spec/models/option_strategy_spec.rb
|
458
|
-
- spec/models/exchange_spec.rb
|
459
|
-
- spec/models/brokerage_authorization_type_read_only_brokerage_spec.rb
|
460
|
-
- spec/models/option_type_spec.rb
|
461
|
-
- spec/models/model402_brokerage_auth_already_disabled_exception_spec.rb
|
462
|
-
- spec/models/option_chain_inner_chain_per_root_inner_spec.rb
|
463
|
-
- spec/models/simple_order_preview_estimated_fee_spec.rb
|
464
|
-
- spec/models/holdings_status_spec.rb
|
465
449
|
- spec/models/encrypted_response_encrypted_message_data_spec.rb
|
466
|
-
- spec/models/
|
467
|
-
- spec/models/brokerage_authorization_spec.rb
|
450
|
+
- spec/models/action_strict_spec.rb
|
468
451
|
- spec/models/trading_place_simple_order_request_spec.rb
|
469
|
-
- spec/models/
|
452
|
+
- spec/models/status_spec.rb
|
453
|
+
- spec/models/strategy_quotes_spec.rb
|
470
454
|
- spec/models/mleg_action_strict_spec.rb
|
471
|
-
- spec/models/
|
472
|
-
- spec/models/
|
473
|
-
- spec/models/
|
474
|
-
- spec/models/auth_type_spec.rb
|
475
|
-
- spec/models/account_spec.rb
|
455
|
+
- spec/models/mleg_order_type_strict_spec.rb
|
456
|
+
- spec/models/snap_trade_holdings_account_spec.rb
|
457
|
+
- spec/models/universal_activity_spec.rb
|
476
458
|
- spec/models/brokerage_type_spec.rb
|
477
|
-
- spec/models/paginated_universal_activity_spec.rb
|
478
|
-
- spec/models/encrypted_response_spec.rb
|
479
|
-
- spec/models/partner_data_spec.rb
|
480
|
-
- spec/models/symbols_quotes_inner_spec.rb
|
481
|
-
- spec/models/recent_orders_response_spec.rb
|
482
|
-
- spec/models/figi_instrument_spec.rb
|
483
|
-
- spec/models/underlying_symbol_spec.rb
|
484
|
-
- spec/models/model403_feature_not_enabled_response_spec.rb
|
485
|
-
- spec/models/manual_trade_form_bracket_spec.rb
|
486
|
-
- spec/models/type_spec.rb
|
487
|
-
- spec/models/symbol_currency_spec.rb
|
488
|
-
- spec/models/option_brokerage_symbol_spec.rb
|
489
|
-
- spec/models/underlying_symbol_type_spec.rb
|
490
|
-
- spec/models/mleg_trading_instrument_spec.rb
|
491
|
-
- spec/models/position_symbol_spec.rb
|
492
|
-
- spec/models/past_value_spec.rb
|
493
|
-
- spec/models/brokerage_authorization_type_read_only_spec.rb
|
494
|
-
- spec/models/option_chain_inner_chain_per_root_inner_chain_per_strike_price_inner_spec.rb
|
495
|
-
- spec/models/brokerage_authorization_type_read_only_type_spec.rb
|
496
|
-
- spec/models/validated_trade_body_spec.rb
|
497
|
-
- spec/models/action_strict_with_options_spec.rb
|
498
459
|
- spec/models/account_order_record_quote_currency_spec.rb
|
460
|
+
- spec/models/child_brokerage_order_ids_spec.rb
|
499
461
|
- spec/models/sub_period_return_rate_spec.rb
|
500
|
-
- spec/models/
|
501
|
-
- spec/models/
|
502
|
-
- spec/models/
|
503
|
-
- spec/models/
|
504
|
-
- spec/models/
|
505
|
-
- spec/models/strategy_quotes_greek_spec.rb
|
506
|
-
- spec/models/net_dividend_spec.rb
|
507
|
-
- spec/models/currency_spec.rb
|
462
|
+
- spec/models/option_strategy_legs_inner_spec.rb
|
463
|
+
- spec/models/account_spec.rb
|
464
|
+
- spec/models/symbols_quotes_inner_spec.rb
|
465
|
+
- spec/models/monthly_dividends_spec.rb
|
466
|
+
- spec/models/option_type_spec.rb
|
508
467
|
- spec/models/options_position_currency_spec.rb
|
509
|
-
- spec/models/
|
468
|
+
- spec/models/performance_custom_spec.rb
|
469
|
+
- spec/models/strategy_type_spec.rb
|
470
|
+
- spec/models/option_leg_action_spec.rb
|
471
|
+
- spec/models/session_event_spec.rb
|
472
|
+
- spec/models/option_chain_inner_chain_per_root_inner_spec.rb
|
473
|
+
- spec/models/option_chain_inner_spec.rb
|
474
|
+
- spec/models/timeframe_spec.rb
|
475
|
+
- spec/models/manual_trade_and_impact_spec.rb
|
476
|
+
- spec/models/option_strategy_spec.rb
|
477
|
+
- spec/models/symbol_spec.rb
|
478
|
+
- spec/models/take_profit_spec.rb
|
479
|
+
- spec/models/strategy_order_record_status_spec.rb
|
480
|
+
- spec/models/time_in_force_strict_spec.rb
|
481
|
+
- spec/models/manual_trade_form_bracket_spec.rb
|
482
|
+
- spec/models/brokerage_authorization_type_read_only_spec.rb
|
510
483
|
- spec/models/mleg_order_response_spec.rb
|
511
|
-
- spec/models/
|
512
|
-
- spec/models/connection_portal_version_spec.rb
|
513
|
-
- spec/models/strategy_quotes_spec.rb
|
514
|
-
- spec/models/snap_trade_register_user_request_body_spec.rb
|
515
|
-
- spec/models/trading_place_mleg_order_request_spec.rb
|
516
|
-
- spec/models/account_holdings_spec.rb
|
517
|
-
- spec/models/account_order_record_quote_universal_symbol_spec.rb
|
484
|
+
- spec/models/account_sync_status_spec.rb
|
518
485
|
- spec/models/manual_trade_spec.rb
|
519
|
-
- spec/models/
|
520
|
-
- spec/models/model402_brokerage_auth_disabled_response_spec.rb
|
521
|
-
- spec/models/timeframe_spec.rb
|
522
|
-
- spec/models/order_updated_response_spec.rb
|
523
|
-
- spec/models/symbol_exchange_spec.rb
|
524
|
-
- spec/models/connections_session_events200_response_inner_spec.rb
|
525
|
-
- spec/models/position_spec.rb
|
486
|
+
- spec/models/position_symbol_spec.rb
|
526
487
|
- spec/models/account_universal_activity_symbol_spec.rb
|
488
|
+
- spec/models/trading_search_cryptocurrency_pair_instruments200_response_spec.rb
|
489
|
+
- spec/models/exchange_rate_pairs_spec.rb
|
490
|
+
- spec/models/net_dividend_spec.rb
|
491
|
+
- spec/models/auth_type_spec.rb
|
492
|
+
- spec/models/strategy_quotes_greek_spec.rb
|
493
|
+
- spec/models/manual_trade_replace_form_spec.rb
|
494
|
+
- spec/models/trading_cancel_user_account_order_request_spec.rb
|
495
|
+
- spec/models/universal_symbol_spec.rb
|
496
|
+
- spec/models/user_i_dand_secret_spec.rb
|
497
|
+
- spec/models/model403_feature_not_enabled_response_spec.rb
|
498
|
+
- spec/models/cryptocurrency_pair_spec.rb
|
499
|
+
- spec/models/balance_currency_spec.rb
|
500
|
+
- spec/models/model500_unexpected_exception_response_spec.rb
|
501
|
+
- spec/models/past_value_spec.rb
|
502
|
+
- spec/models/model401_failed_request_response_spec.rb
|
503
|
+
- spec/models/position_spec.rb
|
504
|
+
- spec/models/authentication_login_snap_trade_user200_response_spec.rb
|
505
|
+
- spec/models/snap_trade_register_user_request_body_spec.rb
|
506
|
+
- spec/models/order_type_strict_spec.rb
|
507
|
+
- spec/models/exchange_spec.rb
|
508
|
+
- spec/models/delete_user_response_spec.rb
|
509
|
+
- spec/models/net_contributions_spec.rb
|
527
510
|
- spec/models/transactions_status_spec.rb
|
528
|
-
- spec/models/
|
511
|
+
- spec/models/mleg_instrument_type_spec.rb
|
512
|
+
- spec/models/holdings_status_spec.rb
|
513
|
+
- spec/models/underlying_symbol_exchange_spec.rb
|
514
|
+
- spec/models/brokerage_authorization_disabled_confirmation_spec.rb
|
515
|
+
- spec/models/rate_of_return_response_spec.rb
|
516
|
+
- spec/models/encrypted_response_spec.rb
|
517
|
+
- spec/models/brokerage_authorization_refresh_confirmation_spec.rb
|
518
|
+
- spec/models/account_simple_spec.rb
|
519
|
+
- spec/models/model402_brokerage_auth_already_disabled_exception_spec.rb
|
520
|
+
- spec/models/option_chain_inner_chain_per_root_inner_chain_per_strike_price_inner_spec.rb
|
521
|
+
- spec/models/underlying_symbol_spec.rb
|
522
|
+
- spec/models/manual_trade_form_notional_value_spec.rb
|
523
|
+
- spec/models/manual_trade_impact_spec.rb
|
524
|
+
- spec/models/options_place_option_strategy_request_spec.rb
|
525
|
+
- spec/models/connection_portal_version_spec.rb
|
526
|
+
- spec/models/model402_brokerage_auth_disabled_response_spec.rb
|
527
|
+
- spec/models/model403_failed_request_response_spec.rb
|
528
|
+
- spec/models/account_balance_total_spec.rb
|
529
529
|
- spec/models/connection_type_spec.rb
|
530
|
+
- spec/models/manual_trade_form_spec.rb
|
531
|
+
- spec/models/recent_orders_response_spec.rb
|
532
|
+
- spec/models/snap_trade_holdings_total_value_spec.rb
|
533
|
+
- spec/models/dividend_at_date_spec.rb
|
534
|
+
- spec/models/balance_spec.rb
|
535
|
+
- spec/models/brokerage_authorization_type_read_only_brokerage_spec.rb
|
536
|
+
- spec/models/account_holdings_spec.rb
|
537
|
+
- spec/models/options_symbol_spec.rb
|
538
|
+
- spec/models/order_updated_response_spec.rb
|
539
|
+
- spec/models/simple_order_preview_spec.rb
|
540
|
+
- spec/models/manual_trade_form_with_options_spec.rb
|
541
|
+
- spec/models/symbol_query_spec.rb
|
542
|
+
- spec/models/notional_value_spec.rb
|
543
|
+
- spec/models/mleg_leg_spec.rb
|
530
544
|
- spec/models/account_balance_spec.rb
|
531
|
-
- spec/models/
|
532
|
-
- spec/models/
|
533
|
-
- spec/models/
|
534
|
-
- spec/models/action_strict_spec.rb
|
545
|
+
- spec/models/partner_data_spec.rb
|
546
|
+
- spec/models/simple_order_request_body_time_in_force_spec.rb
|
547
|
+
- spec/models/currency_spec.rb
|
535
548
|
- spec/models/account_order_record_option_symbol_spec.rb
|
536
|
-
- spec/models/
|
537
|
-
- spec/models/
|
538
|
-
- spec/models/
|
539
|
-
- spec/models/
|
549
|
+
- spec/models/symbol_exchange_spec.rb
|
550
|
+
- spec/models/account_order_record_child_brokerage_order_ids_spec.rb
|
551
|
+
- spec/models/account_universal_activity_currency_spec.rb
|
552
|
+
- spec/models/account_universal_activity_spec.rb
|
553
|
+
- spec/models/connections_session_events200_response_inner_spec.rb
|
554
|
+
- spec/models/manual_trade_balance_spec.rb
|
555
|
+
- spec/models/account_order_record_spec.rb
|
540
556
|
- spec/models/session_event_type_spec.rb
|
541
|
-
- spec/models/
|
542
|
-
- spec/models/
|
543
|
-
- spec/models/
|
557
|
+
- spec/models/snap_trade_login_user_request_body_spec.rb
|
558
|
+
- spec/models/brokerage_spec.rb
|
559
|
+
- spec/models/paginated_universal_activity_spec.rb
|
560
|
+
- spec/models/options_position_spec.rb
|
561
|
+
- spec/models/model425_failed_request_response_spec.rb
|
544
562
|
- spec/models/trading_instrument_type_spec.rb
|
545
|
-
- spec/models/
|
546
|
-
- spec/models/
|
563
|
+
- spec/models/option_leg_spec.rb
|
564
|
+
- spec/models/pagination_details_spec.rb
|
565
|
+
- spec/models/login_redirect_uri_spec.rb
|
547
566
|
- spec/models/account_order_record_status_spec.rb
|
548
|
-
- spec/models/option_chain_inner_spec.rb
|
549
|
-
- spec/models/brokerage_spec.rb
|
550
|
-
- spec/models/simple_order_request_body_time_in_force_spec.rb
|
551
|
-
- spec/models/exchange_rate_pairs_spec.rb
|
552
|
-
- spec/models/account_simple_spec.rb
|
553
|
-
- spec/models/delete_user_response_spec.rb
|
554
|
-
- spec/models/strategy_type_spec.rb
|
555
|
-
- spec/models/snap_trade_holdings_account_spec.rb
|
556
|
-
- spec/models/balance_currency_spec.rb
|
557
|
-
- spec/models/stop_loss_spec.rb
|
558
|
-
- spec/models/balance_spec.rb
|
559
|
-
- spec/models/net_contributions_spec.rb
|
560
|
-
- spec/models/universal_activity_spec.rb
|
561
|
-
- spec/models/dividend_at_date_spec.rb
|
562
|
-
- spec/models/child_brokerage_order_ids_spec.rb
|
563
|
-
- spec/models/take_profit_spec.rb
|
564
|
-
- spec/models/trading_instrument_spec.rb
|
565
|
-
- spec/models/brokerage_authorization_disabled_confirmation_spec.rb
|
566
|
-
- spec/models/model403_failed_request_response_spec.rb
|
567
|
-
- spec/models/session_event_spec.rb
|
568
|
-
- spec/models/account_holdings_account_spec.rb
|
569
|
-
- spec/models/performance_custom_spec.rb
|
570
|
-
- spec/models/rate_of_return_object_spec.rb
|
571
|
-
- spec/models/strategy_order_record_spec.rb
|
572
|
-
- spec/models/options_place_option_strategy_request_spec.rb
|
573
|
-
- spec/models/model401_failed_request_response_spec.rb
|
574
567
|
- spec/models/manual_trade_symbol_spec.rb
|
575
|
-
- spec/models/
|
576
|
-
- spec/models/
|
577
|
-
- spec/models/
|
568
|
+
- spec/models/symbol_figi_instrument_spec.rb
|
569
|
+
- spec/models/trading_place_mleg_order_request_spec.rb
|
570
|
+
- spec/models/account_holdings_account_spec.rb
|
571
|
+
- spec/models/option_brokerage_symbol_spec.rb
|
572
|
+
- spec/models/mleg_trading_instrument_spec.rb
|
578
573
|
- spec/models/cryptocurrency_pair_quote_spec.rb
|
579
|
-
- spec/models/
|
574
|
+
- spec/models/action_strict_with_options_spec.rb
|
580
575
|
- spec/models/account_universal_activity_option_symbol_spec.rb
|
581
|
-
- spec/models/
|
582
|
-
- spec/models/
|
583
|
-
- spec/models/
|
584
|
-
- spec/models/
|
585
|
-
- spec/models/
|
586
|
-
- spec/models/
|
576
|
+
- spec/models/model400_failed_request_response_spec.rb
|
577
|
+
- spec/models/rate_of_return_object_spec.rb
|
578
|
+
- spec/models/security_type_spec.rb
|
579
|
+
- spec/models/trading_instrument_spec.rb
|
580
|
+
- spec/models/model404_failed_request_response_spec.rb
|
581
|
+
- spec/models/symbol_currency_spec.rb
|
582
|
+
- spec/models/figi_instrument_spec.rb
|
583
|
+
- spec/models/simple_order_preview_estimated_fee_spec.rb
|
584
|
+
- spec/models/strategy_order_record_spec.rb
|
585
|
+
- spec/models/brokerage_authorization_type_read_only_type_spec.rb
|
586
|
+
- spec/models/account_order_record_quote_universal_symbol_spec.rb
|
587
587
|
- spec/spec_helper.rb
|
@@ -1,23 +0,0 @@
|
|
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::MlegOrderRequestBodyType
|
15
|
-
describe SnapTrade::MlegOrderRequestBodyType do
|
16
|
-
let(:instance) { SnapTrade::MlegOrderRequestBodyType.new }
|
17
|
-
|
18
|
-
describe 'test an instance of MlegOrderRequestBodyType' do
|
19
|
-
it 'should create an instance of MlegOrderRequestBodyType' do
|
20
|
-
expect(instance).to be_instance_of(SnapTrade::MlegOrderRequestBodyType)
|
21
|
-
end
|
22
|
-
end
|
23
|
-
end
|
@@ -1,23 +0,0 @@
|
|
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::MlegTradingInstrumentType
|
15
|
-
describe SnapTrade::MlegTradingInstrumentType do
|
16
|
-
let(:instance) { SnapTrade::MlegTradingInstrumentType.new }
|
17
|
-
|
18
|
-
describe 'test an instance of MlegTradingInstrumentType' do
|
19
|
-
it 'should create an instance of MlegTradingInstrumentType' do
|
20
|
-
expect(instance).to be_instance_of(SnapTrade::MlegTradingInstrumentType)
|
21
|
-
end
|
22
|
-
end
|
23
|
-
end
|