smplkit 3.0.102 → 3.0.103
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/lib/smplkit/_generated/app/lib/smplkit_app_client/models/plan_definition.rb +17 -4
- data/lib/smplkit/_generated/app/lib/smplkit_app_client/models/product.rb +13 -1
- data/lib/smplkit/_generated/app/spec/models/plan_definition_spec.rb +6 -0
- data/lib/smplkit/_generated/app/spec/models/product_spec.rb +6 -0
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: b4885e5b0997b0792d5b2a40437167f76818c0dca5185d78428d54ef6b650f4c
|
|
4
|
+
data.tar.gz: 75915674e533382f9ce457cffe2f5347c15bf24c2f26ec105fb3503d28c3b442
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e4fc9b5b6206da24bf576cc7c9e4a5f1dab28ffa58b53d5d41c41b78092d61ebdf8708a0024efa79c1d593d725237363a45db30a82a2a7de29af6f08ae509cf7
|
|
7
|
+
data.tar.gz: b2096cc388bde3c892b48235e826c3418dba647abde121f42190007015c4102dee95b6949e2d54e9a962d33da17a932721491b0cf623976ce09fc9a23e24ec6c
|
|
@@ -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
|
|
@@ -34,6 +34,9 @@ module SmplkitGeneratedClient::App
|
|
|
34
34
|
# Map of limit key to limit definition for this product.
|
|
35
35
|
attr_accessor :limits
|
|
36
36
|
|
|
37
|
+
# 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.
|
|
38
|
+
attr_accessor :metered_limits
|
|
39
|
+
|
|
37
40
|
# Map of plan key to plan definition for this product.
|
|
38
41
|
attr_accessor :plans
|
|
39
42
|
|
|
@@ -46,6 +49,7 @@ module SmplkitGeneratedClient::App
|
|
|
46
49
|
:'features' => :'features',
|
|
47
50
|
:'coming_soon' => :'coming_soon',
|
|
48
51
|
:'limits' => :'limits',
|
|
52
|
+
:'metered_limits' => :'metered_limits',
|
|
49
53
|
:'plans' => :'plans'
|
|
50
54
|
}
|
|
51
55
|
end
|
|
@@ -69,6 +73,7 @@ module SmplkitGeneratedClient::App
|
|
|
69
73
|
:'features' => :'Array<String>',
|
|
70
74
|
:'coming_soon' => :'Boolean',
|
|
71
75
|
:'limits' => :'Hash<String, LimitDefinition>',
|
|
76
|
+
:'metered_limits' => :'Array<String>',
|
|
72
77
|
:'plans' => :'Hash<String, PlanDefinition>'
|
|
73
78
|
}
|
|
74
79
|
end
|
|
@@ -132,6 +137,12 @@ module SmplkitGeneratedClient::App
|
|
|
132
137
|
self.limits = nil
|
|
133
138
|
end
|
|
134
139
|
|
|
140
|
+
if attributes.key?(:'metered_limits')
|
|
141
|
+
if (value = attributes[:'metered_limits']).is_a?(Array)
|
|
142
|
+
self.metered_limits = value
|
|
143
|
+
end
|
|
144
|
+
end
|
|
145
|
+
|
|
135
146
|
if attributes.key?(:'plans')
|
|
136
147
|
if (value = attributes[:'plans']).is_a?(Hash)
|
|
137
148
|
self.plans = value
|
|
@@ -227,6 +238,7 @@ module SmplkitGeneratedClient::App
|
|
|
227
238
|
features == o.features &&
|
|
228
239
|
coming_soon == o.coming_soon &&
|
|
229
240
|
limits == o.limits &&
|
|
241
|
+
metered_limits == o.metered_limits &&
|
|
230
242
|
plans == o.plans
|
|
231
243
|
end
|
|
232
244
|
|
|
@@ -239,7 +251,7 @@ module SmplkitGeneratedClient::App
|
|
|
239
251
|
# Calculates hash code according to all attributes.
|
|
240
252
|
# @return [Integer] Hash code
|
|
241
253
|
def hash
|
|
242
|
-
[display_name, description, tagline, features, coming_soon, limits, plans].hash
|
|
254
|
+
[display_name, description, tagline, features, coming_soon, limits, metered_limits, plans].hash
|
|
243
255
|
end
|
|
244
256
|
|
|
245
257
|
# Builds the object from hash
|
|
@@ -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
|
|
@@ -63,6 +63,12 @@ describe SmplkitGeneratedClient::App::Product do
|
|
|
63
63
|
end
|
|
64
64
|
end
|
|
65
65
|
|
|
66
|
+
describe 'test attribute "metered_limits"' do
|
|
67
|
+
it 'should work' do
|
|
68
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
69
|
+
end
|
|
70
|
+
end
|
|
71
|
+
|
|
66
72
|
describe 'test attribute "plans"' do
|
|
67
73
|
it 'should work' do
|
|
68
74
|
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|