smplkit 3.0.102 → 3.0.104

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: 047e3fc0922ee25b1441a22a33addbba76e885b486414ac3ca99b31d07b17277
4
- data.tar.gz: 5ce032781cecf99066afb73359af216000039d158318dc427dfc456f159d35b3
3
+ metadata.gz: a6b1e8b774685d05ce4bee73144f57253d969daed3e2323dbd49d3f5bab869d2
4
+ data.tar.gz: 350b07f236f2682ecddc12859c7cc80b63c5877e10c144c7fc72329e31d78ca8
5
5
  SHA512:
6
- metadata.gz: 7c5a05ff1932b11b194a3405bb6f361763810c935e3e7bc924afb6431dfd201b6447020b117f14161dc209525a072e4a4afb9d6b467eb086bfd177c5f3f6400c
7
- data.tar.gz: cebda2b16e66a59fac937a6f135fdaeff3cdd727ff009637a77627efefc0eb2738a411dead73ccaf60d3f30edbd1416a6f55602bcfe4da2d00c891c14effefcc
6
+ metadata.gz: 405cde740a188a78963a8bd8af3477549246e4c01d346ec9c1cc09f592146c8745b73916444af4afbe7e92717b9e7b7c30487c3a85395ebb7523fc49078cd899
7
+ data.tar.gz: 8b26180fcdc3d293a8106cc46724970d3055f1025686109a609ce8fc1d94eca733a5c7af4de5b32f5081e2118cef74842048dda3f4afb7e02c6087bc6bad009b
@@ -20,7 +20,7 @@ module SmplkitGeneratedClient::App
20
20
  @api_client = api_client
21
21
  end
22
22
  # List Products
23
- # Return all flag-enabled products with their plans, limits, and marketing content. Default sort is `display_name` ascending.
23
+ # Return all products with their plans, limits, and marketing content. Default sort is `display_name` ascending.
24
24
  # @param [Hash] opts the optional parameters
25
25
  # @option opts [String] :sort Field to sort by. Prefix with `-` for descending order. Default: `display_name`. Allowed values: `display_name`, `-display_name`, `id`, `-id`. (default to 'display_name')
26
26
  # @option opts [Integer] :page_number 1-based page number to return. Optional; defaults to `1` when omitted. Must be `>= 1` — requests with a smaller value are rejected with a 400 error. (default to 1)
@@ -33,7 +33,7 @@ module SmplkitGeneratedClient::App
33
33
  end
34
34
 
35
35
  # List Products
36
- # Return all flag-enabled products with their plans, limits, and marketing content. Default sort is `display_name` ascending.
36
+ # Return all products with their plans, limits, and marketing content. Default sort is `display_name` ascending.
37
37
  # @param [Hash] opts the optional parameters
38
38
  # @option opts [String] :sort Field to sort by. Prefix with `-` for descending order. Default: `display_name`. Allowed values: `display_name`, `-display_name`, `id`, `-id`. (default to 'display_name')
39
39
  # @option opts [Integer] :page_number 1-based page number to return. Optional; defaults to `1` when omitted. Must be `>= 1` — requests with a smaller value are rejected with a 400 error. (default to 1)
@@ -22,11 +22,15 @@ module SmplkitGeneratedClient::App
22
22
  # Map of limit key to the cap that applies on this plan. `-1` indicates an unlimited cap.
23
23
  attr_accessor :limits
24
24
 
25
+ # For metered products only: map of metered limit key to the per-unit overage price in micro-USD ($0.000001) charged for each unit beyond the plan's included allotment. A rate of `0` means the plan stops at its allotment with no overage. Omitted for products that are not metered.
26
+ attr_accessor :overage_rates
27
+
25
28
  # Attribute mapping from ruby-style variable name to JSON key.
26
29
  def self.attribute_map
27
30
  {
28
31
  :'price_monthly_cents' => :'price_monthly_cents',
29
- :'limits' => :'limits'
32
+ :'limits' => :'limits',
33
+ :'overage_rates' => :'overage_rates'
30
34
  }
31
35
  end
32
36
 
@@ -44,13 +48,15 @@ module SmplkitGeneratedClient::App
44
48
  def self.openapi_types
45
49
  {
46
50
  :'price_monthly_cents' => :'Integer',
47
- :'limits' => :'Hash<String, Integer>'
51
+ :'limits' => :'Hash<String, Integer>',
52
+ :'overage_rates' => :'Hash<String, Integer>'
48
53
  }
49
54
  end
50
55
 
51
56
  # List of attributes with nullable: true
52
57
  def self.openapi_nullable
53
58
  Set.new([
59
+ :'overage_rates'
54
60
  ])
55
61
  end
56
62
 
@@ -83,6 +89,12 @@ module SmplkitGeneratedClient::App
83
89
  else
84
90
  self.limits = nil
85
91
  end
92
+
93
+ if attributes.key?(:'overage_rates')
94
+ if (value = attributes[:'overage_rates']).is_a?(Hash)
95
+ self.overage_rates = value
96
+ end
97
+ end
86
98
  end
87
99
 
88
100
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -136,7 +148,8 @@ module SmplkitGeneratedClient::App
136
148
  return true if self.equal?(o)
137
149
  self.class == o.class &&
138
150
  price_monthly_cents == o.price_monthly_cents &&
139
- limits == o.limits
151
+ limits == o.limits &&
152
+ overage_rates == o.overage_rates
140
153
  end
141
154
 
142
155
  # @see the `==` method
@@ -148,7 +161,7 @@ module SmplkitGeneratedClient::App
148
161
  # Calculates hash code according to all attributes.
149
162
  # @return [Integer] Hash code
150
163
  def hash
151
- [price_monthly_cents, limits].hash
164
+ [price_monthly_cents, limits, overage_rates].hash
152
165
  end
153
166
 
154
167
  # Builds the object from hash
@@ -28,12 +28,12 @@ module SmplkitGeneratedClient::App
28
28
  # Bullet-list feature highlights for the product.
29
29
  attr_accessor :features
30
30
 
31
- # When `true`, the product is listed but not yet available for subscription.
32
- attr_accessor :coming_soon
33
-
34
31
  # Map of limit key to limit definition for this product.
35
32
  attr_accessor :limits
36
33
 
34
+ # Limit keys on this product that are metered: each includes a monthly allotment in the plan price and bills per unit beyond it at the plan's `overage_rates` rate, rather than capping hard. Empty for products with no metered limits.
35
+ attr_accessor :metered_limits
36
+
37
37
  # Map of plan key to plan definition for this product.
38
38
  attr_accessor :plans
39
39
 
@@ -44,8 +44,8 @@ module SmplkitGeneratedClient::App
44
44
  :'description' => :'description',
45
45
  :'tagline' => :'tagline',
46
46
  :'features' => :'features',
47
- :'coming_soon' => :'coming_soon',
48
47
  :'limits' => :'limits',
48
+ :'metered_limits' => :'metered_limits',
49
49
  :'plans' => :'plans'
50
50
  }
51
51
  end
@@ -67,8 +67,8 @@ module SmplkitGeneratedClient::App
67
67
  :'description' => :'String',
68
68
  :'tagline' => :'String',
69
69
  :'features' => :'Array<String>',
70
- :'coming_soon' => :'Boolean',
71
70
  :'limits' => :'Hash<String, LimitDefinition>',
71
+ :'metered_limits' => :'Array<String>',
72
72
  :'plans' => :'Hash<String, PlanDefinition>'
73
73
  }
74
74
  end
@@ -118,12 +118,6 @@ module SmplkitGeneratedClient::App
118
118
  end
119
119
  end
120
120
 
121
- if attributes.key?(:'coming_soon')
122
- self.coming_soon = attributes[:'coming_soon']
123
- else
124
- self.coming_soon = false
125
- end
126
-
127
121
  if attributes.key?(:'limits')
128
122
  if (value = attributes[:'limits']).is_a?(Hash)
129
123
  self.limits = value
@@ -132,6 +126,12 @@ module SmplkitGeneratedClient::App
132
126
  self.limits = nil
133
127
  end
134
128
 
129
+ if attributes.key?(:'metered_limits')
130
+ if (value = attributes[:'metered_limits']).is_a?(Array)
131
+ self.metered_limits = value
132
+ end
133
+ end
134
+
135
135
  if attributes.key?(:'plans')
136
136
  if (value = attributes[:'plans']).is_a?(Hash)
137
137
  self.plans = value
@@ -225,8 +225,8 @@ module SmplkitGeneratedClient::App
225
225
  description == o.description &&
226
226
  tagline == o.tagline &&
227
227
  features == o.features &&
228
- coming_soon == o.coming_soon &&
229
228
  limits == o.limits &&
229
+ metered_limits == o.metered_limits &&
230
230
  plans == o.plans
231
231
  end
232
232
 
@@ -239,7 +239,7 @@ module SmplkitGeneratedClient::App
239
239
  # Calculates hash code according to all attributes.
240
240
  # @return [Integer] Hash code
241
241
  def hash
242
- [display_name, description, tagline, features, coming_soon, limits, plans].hash
242
+ [display_name, description, tagline, features, limits, metered_limits, plans].hash
243
243
  end
244
244
 
245
245
  # Builds the object from hash
@@ -34,7 +34,7 @@ describe 'ProductsApi' do
34
34
 
35
35
  # unit tests for list_products
36
36
  # List Products
37
- # Return all flag-enabled products with their plans, limits, and marketing content. Default sort is &#x60;display_name&#x60; ascending.
37
+ # Return all products with their plans, limits, and marketing content. Default sort is &#x60;display_name&#x60; ascending.
38
38
  # @param [Hash] opts the optional parameters
39
39
  # @option opts [String] :sort Field to sort by. Prefix with &#x60;-&#x60; for descending order. Default: &#x60;display_name&#x60;. Allowed values: &#x60;display_name&#x60;, &#x60;-display_name&#x60;, &#x60;id&#x60;, &#x60;-id&#x60;.
40
40
  # @option opts [Integer] :page_number 1-based page number to return. Optional; defaults to &#x60;1&#x60; when omitted. Must be &#x60;&gt;&#x3D; 1&#x60; — requests with a smaller value are rejected with a 400 error.
@@ -39,4 +39,10 @@ describe SmplkitGeneratedClient::App::PlanDefinition do
39
39
  end
40
40
  end
41
41
 
42
+ describe 'test attribute "overage_rates"' do
43
+ it 'should work' do
44
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
45
+ end
46
+ end
47
+
42
48
  end
@@ -51,13 +51,13 @@ describe SmplkitGeneratedClient::App::Product do
51
51
  end
52
52
  end
53
53
 
54
- describe 'test attribute "coming_soon"' do
54
+ describe 'test attribute "limits"' do
55
55
  it 'should work' do
56
56
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
57
57
  end
58
58
  end
59
59
 
60
- describe 'test attribute "limits"' do
60
+ describe 'test attribute "metered_limits"' do
61
61
  it 'should work' do
62
62
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
63
63
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: smplkit
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.102
4
+ version: 3.0.104
5
5
  platform: ruby
6
6
  authors:
7
7
  - Smpl Solutions LLC