payjpv2 1.0.2 → 1.0.7
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 +1 -1
- data/README.md +2 -2
- data/docs/PaymentMethodsApi.md +2 -0
- data/docs/ProductDetailsResponse.md +7 -1
- data/docs/TaxRateDetailsResponse.md +6 -0
- data/docs/TaxRatesApi.md +5 -1
- data/lib/payjpv2/api/payment_methods_api.rb +1 -0
- data/lib/payjpv2/api/tax_rates_api.rb +4 -0
- data/lib/payjpv2/configuration.rb +2 -2
- data/lib/payjpv2/models/product_details_response.rb +71 -5
- data/lib/payjpv2/models/tax_rate_details_response.rb +67 -1
- data/lib/payjpv2/version.rb +1 -1
- data/spec/api/payment_methods_api_spec.rb +1 -0
- data/spec/api/tax_rates_api_spec.rb +2 -0
- data/spec/models/product_details_response_spec.rb +18 -0
- data/spec/models/tax_rate_details_response_spec.rb +18 -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: 4a58ee8213ca8a310e90d5999593ebecea269a9231585c2390c680a484ec1085
|
|
4
|
+
data.tar.gz: 052e9f2501f3e7f6f187fe5dc6b438997b015d6fd87856d111516e294a705f16
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 7a103ca37687b152ff1e3fdfc3b4d686f25eced72eb7a7f21e149b66ee50483e3ed2e48395bc8b3bd3c347dffb187688dc88c35c3802b993c014272007d8cd8f
|
|
7
|
+
data.tar.gz: a40f3f9ae3f7b127d36215fd3a81949ad89623a33a039eafe3dd9b62eea5423e2b6e55ef48cf1a8b9a58b671b9718d1aa9507c36da4491d2939f144c5f871733
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
|
@@ -5,7 +5,7 @@ A Ruby client library for the PAY.JP v2 API. This SDK provides a convenient way
|
|
|
5
5
|
This Ruby gem is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
|
|
6
6
|
|
|
7
7
|
- API version: 2.0.0
|
|
8
|
-
- Package version: 1.0.
|
|
8
|
+
- Package version: 1.0.7
|
|
9
9
|
- Generator version: 7.14.0
|
|
10
10
|
- Build package: org.openapitools.codegen.languages.RubyClientCodegen
|
|
11
11
|
|
|
@@ -26,7 +26,7 @@ gem install payjpv2
|
|
|
26
26
|
Add this line to your application's Gemfile:
|
|
27
27
|
|
|
28
28
|
```ruby
|
|
29
|
-
gem 'payjpv2', '~> 1.0.
|
|
29
|
+
gem 'payjpv2', '~> 1.0.7'
|
|
30
30
|
```
|
|
31
31
|
|
|
32
32
|
Then execute:
|
data/docs/PaymentMethodsApi.md
CHANGED
|
@@ -6,12 +6,15 @@
|
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
7
|
| **object** | **String** | | [optional][default to 'product'] |
|
|
8
8
|
| **id** | **String** | 商品 ID | |
|
|
9
|
+
| **livemode** | **Boolean** | 本番環境かどうか | |
|
|
9
10
|
| **name** | **String** | Checkout などで顧客に表示される商品名 | |
|
|
10
11
|
| **active** | **Boolean** | 商品が購入可能かどうか | |
|
|
11
12
|
| **default_price_id** | **String** | | |
|
|
12
13
|
| **description** | **String** | | |
|
|
13
14
|
| **unit_label** | **String** | | |
|
|
14
15
|
| **url** | **String** | | |
|
|
16
|
+
| **created_at** | **Time** | 作成日時 (UTC, ISO 8601 形式) | |
|
|
17
|
+
| **updated_at** | **Time** | 更新日時 (UTC, ISO 8601 形式) | |
|
|
15
18
|
|
|
16
19
|
## Example
|
|
17
20
|
|
|
@@ -21,12 +24,15 @@ require 'payjpv2'
|
|
|
21
24
|
instance = PAYJPv2::ProductDetailsResponse.new(
|
|
22
25
|
object: null,
|
|
23
26
|
id: null,
|
|
27
|
+
livemode: null,
|
|
24
28
|
name: null,
|
|
25
29
|
active: null,
|
|
26
30
|
default_price_id: null,
|
|
27
31
|
description: null,
|
|
28
32
|
unit_label: null,
|
|
29
|
-
url: null
|
|
33
|
+
url: null,
|
|
34
|
+
created_at: null,
|
|
35
|
+
updated_at: null
|
|
30
36
|
)
|
|
31
37
|
```
|
|
32
38
|
|
|
@@ -6,12 +6,15 @@
|
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
7
|
| **object** | **String** | | [optional][default to 'tax_rate'] |
|
|
8
8
|
| **id** | **String** | 税率 ID | |
|
|
9
|
+
| **livemode** | **Boolean** | 本番環境かどうか | |
|
|
9
10
|
| **display_name** | **String** | 表示名。顧客に表示されます。 | |
|
|
10
11
|
| **inclusive** | **Boolean** | 税込みかどうか。税込 = `true` 税抜 = `false` | |
|
|
11
12
|
| **percentage** | **Float** | 税率 (% 単位) | |
|
|
12
13
|
| **active** | **Boolean** | この税率が有効であるかどうか | |
|
|
13
14
|
| **country** | [**Country**](Country.md) | | |
|
|
14
15
|
| **description** | **String** | | |
|
|
16
|
+
| **created_at** | **Time** | 作成日時 (UTC, ISO 8601 形式) | |
|
|
17
|
+
| **updated_at** | **Time** | 更新日時 (UTC, ISO 8601 形式) | |
|
|
15
18
|
| **metadata** | [**Hash<String, MetadataValue>**](MetadataValue.md) | メタデータ | |
|
|
16
19
|
|
|
17
20
|
## Example
|
|
@@ -22,12 +25,15 @@ require 'payjpv2'
|
|
|
22
25
|
instance = PAYJPv2::TaxRateDetailsResponse.new(
|
|
23
26
|
object: null,
|
|
24
27
|
id: null,
|
|
28
|
+
livemode: null,
|
|
25
29
|
display_name: null,
|
|
26
30
|
inclusive: null,
|
|
27
31
|
percentage: null,
|
|
28
32
|
active: null,
|
|
29
33
|
country: null,
|
|
30
34
|
description: null,
|
|
35
|
+
created_at: null,
|
|
36
|
+
updated_at: null,
|
|
31
37
|
metadata: null
|
|
32
38
|
)
|
|
33
39
|
```
|
data/docs/TaxRatesApi.md
CHANGED
|
@@ -104,7 +104,9 @@ api_instance = PAYJPv2::TaxRatesApi.new
|
|
|
104
104
|
opts = {
|
|
105
105
|
limit: 56, # Integer | 取得するデータの最大件数
|
|
106
106
|
starting_after: 'starting_after_example', # String | このIDより後のデータを取得
|
|
107
|
-
ending_before: 'ending_before_example' # String | このIDより前のデータを取得
|
|
107
|
+
ending_before: 'ending_before_example', # String | このIDより前のデータを取得
|
|
108
|
+
active: true, # Boolean | この税率が有効であるかどうか。無効にした場合でも、すでに設定されている定期課金などでは使用可能です。
|
|
109
|
+
inclusive: true # Boolean | 税込みかどうか。税込 = `true` 税抜 = `false`
|
|
108
110
|
}
|
|
109
111
|
|
|
110
112
|
begin
|
|
@@ -139,6 +141,8 @@ end
|
|
|
139
141
|
| **limit** | **Integer** | 取得するデータの最大件数 | [optional][default to 10] |
|
|
140
142
|
| **starting_after** | **String** | このIDより後のデータを取得 | [optional] |
|
|
141
143
|
| **ending_before** | **String** | このIDより前のデータを取得 | [optional] |
|
|
144
|
+
| **active** | **Boolean** | この税率が有効であるかどうか。無効にした場合でも、すでに設定されている定期課金などでは使用可能です。 | [optional] |
|
|
145
|
+
| **inclusive** | **Boolean** | 税込みかどうか。税込 = `true` 税抜 = `false` | [optional] |
|
|
142
146
|
|
|
143
147
|
### Return type
|
|
144
148
|
|
|
@@ -90,6 +90,7 @@ module PAYJPv2
|
|
|
90
90
|
end
|
|
91
91
|
|
|
92
92
|
# Create Payment Method
|
|
93
|
+
# **このエンドポイントはテストモードでのみ使用できます。**
|
|
93
94
|
# @param payment_method_create_request [PaymentMethodCreateRequest]
|
|
94
95
|
# @param [Hash] opts the optional parameters
|
|
95
96
|
# @option opts [String] :idempotency_key Idempotency key for the request
|
|
@@ -89,6 +89,8 @@ module PAYJPv2
|
|
|
89
89
|
# @option opts [Integer] :limit 取得するデータの最大件数 (default to 10)
|
|
90
90
|
# @option opts [String] :starting_after このIDより後のデータを取得
|
|
91
91
|
# @option opts [String] :ending_before このIDより前のデータを取得
|
|
92
|
+
# @option opts [Boolean] :active この税率が有効であるかどうか。無効にした場合でも、すでに設定されている定期課金などでは使用可能です。
|
|
93
|
+
# @option opts [Boolean] :inclusive 税込みかどうか。税込 = `true` 税抜 = `false`
|
|
92
94
|
# @option opts [String] :idempotency_key Idempotency key for the request
|
|
93
95
|
# @option opts [Boolean] :include_http_info If true, returns [data, status_code, headers] instead of just data
|
|
94
96
|
# @return [TaxRateListResponse, Array] Returns data or [data, status_code, headers] if include_http_info is true
|
|
@@ -112,6 +114,8 @@ module PAYJPv2
|
|
|
112
114
|
query_params[:limit] = opts[:limit] if !opts[:limit].nil?
|
|
113
115
|
query_params[:starting_after] = opts[:starting_after] if !opts[:starting_after].nil?
|
|
114
116
|
query_params[:ending_before] = opts[:ending_before] if !opts[:ending_before].nil?
|
|
117
|
+
query_params[:active] = opts[:active] if !opts[:active].nil?
|
|
118
|
+
query_params[:inclusive] = opts[:inclusive] if !opts[:inclusive].nil?
|
|
115
119
|
|
|
116
120
|
# header parameters
|
|
117
121
|
header_params = opts[:header_params] || {}
|
|
@@ -20,6 +20,9 @@ module PAYJPv2
|
|
|
20
20
|
# 商品 ID
|
|
21
21
|
attr_accessor :id
|
|
22
22
|
|
|
23
|
+
# 本番環境かどうか
|
|
24
|
+
attr_accessor :livemode
|
|
25
|
+
|
|
23
26
|
# Checkout などで顧客に表示される商品名
|
|
24
27
|
attr_accessor :name
|
|
25
28
|
|
|
@@ -34,6 +37,12 @@ module PAYJPv2
|
|
|
34
37
|
|
|
35
38
|
attr_accessor :url
|
|
36
39
|
|
|
40
|
+
# 作成日時 (UTC, ISO 8601 形式)
|
|
41
|
+
attr_accessor :created_at
|
|
42
|
+
|
|
43
|
+
# 更新日時 (UTC, ISO 8601 形式)
|
|
44
|
+
attr_accessor :updated_at
|
|
45
|
+
|
|
37
46
|
class EnumAttributeValidator
|
|
38
47
|
attr_reader :datatype
|
|
39
48
|
attr_reader :allowable_values
|
|
@@ -61,12 +70,15 @@ module PAYJPv2
|
|
|
61
70
|
{
|
|
62
71
|
:object => :object,
|
|
63
72
|
:id => :id,
|
|
73
|
+
:livemode => :livemode,
|
|
64
74
|
:name => :name,
|
|
65
75
|
:active => :active,
|
|
66
76
|
:default_price_id => :default_price_id,
|
|
67
77
|
:description => :description,
|
|
68
78
|
:unit_label => :unit_label,
|
|
69
|
-
:url => :url
|
|
79
|
+
:url => :url,
|
|
80
|
+
:created_at => :created_at,
|
|
81
|
+
:updated_at => :updated_at
|
|
70
82
|
}
|
|
71
83
|
end
|
|
72
84
|
|
|
@@ -85,12 +97,15 @@ module PAYJPv2
|
|
|
85
97
|
{
|
|
86
98
|
:object => :'String',
|
|
87
99
|
:id => :'String',
|
|
100
|
+
:livemode => :'Boolean',
|
|
88
101
|
:name => :'String',
|
|
89
102
|
:active => :'Boolean',
|
|
90
103
|
:default_price_id => :'String',
|
|
91
104
|
:description => :'String',
|
|
92
105
|
:unit_label => :'String',
|
|
93
|
-
:url => :'String'
|
|
106
|
+
:url => :'String',
|
|
107
|
+
:created_at => :'Time',
|
|
108
|
+
:updated_at => :'Time'
|
|
94
109
|
}
|
|
95
110
|
end
|
|
96
111
|
|
|
@@ -100,7 +115,7 @@ module PAYJPv2
|
|
|
100
115
|
:default_price_id,
|
|
101
116
|
:description,
|
|
102
117
|
:unit_label,
|
|
103
|
-
:url
|
|
118
|
+
:url,
|
|
104
119
|
])
|
|
105
120
|
end
|
|
106
121
|
|
|
@@ -132,6 +147,12 @@ module PAYJPv2
|
|
|
132
147
|
self.id = nil
|
|
133
148
|
end
|
|
134
149
|
|
|
150
|
+
if attributes.key?(:livemode)
|
|
151
|
+
self.livemode = attributes[:livemode]
|
|
152
|
+
else
|
|
153
|
+
self.livemode = nil
|
|
154
|
+
end
|
|
155
|
+
|
|
135
156
|
if attributes.key?(:name)
|
|
136
157
|
self.name = attributes[:name]
|
|
137
158
|
else
|
|
@@ -167,6 +188,18 @@ module PAYJPv2
|
|
|
167
188
|
else
|
|
168
189
|
self.url = nil
|
|
169
190
|
end
|
|
191
|
+
|
|
192
|
+
if attributes.key?(:created_at)
|
|
193
|
+
self.created_at = attributes[:created_at]
|
|
194
|
+
else
|
|
195
|
+
self.created_at = nil
|
|
196
|
+
end
|
|
197
|
+
|
|
198
|
+
if attributes.key?(:updated_at)
|
|
199
|
+
self.updated_at = attributes[:updated_at]
|
|
200
|
+
else
|
|
201
|
+
self.updated_at = nil
|
|
202
|
+
end
|
|
170
203
|
end
|
|
171
204
|
|
|
172
205
|
# Custom attribute writer method checking allowed values (enum).
|
|
@@ -189,6 +222,16 @@ module PAYJPv2
|
|
|
189
222
|
@id = id
|
|
190
223
|
end
|
|
191
224
|
|
|
225
|
+
# Custom attribute writer method with validation
|
|
226
|
+
# @param [Object] livemode Value to be assigned
|
|
227
|
+
def livemode=(livemode)
|
|
228
|
+
if livemode.nil?
|
|
229
|
+
raise ArgumentError, 'livemode cannot be nil'
|
|
230
|
+
end
|
|
231
|
+
|
|
232
|
+
@livemode = livemode
|
|
233
|
+
end
|
|
234
|
+
|
|
192
235
|
# Custom attribute writer method with validation
|
|
193
236
|
# @param [Object] name Value to be assigned
|
|
194
237
|
def name=(name)
|
|
@@ -209,6 +252,26 @@ module PAYJPv2
|
|
|
209
252
|
@active = active
|
|
210
253
|
end
|
|
211
254
|
|
|
255
|
+
# Custom attribute writer method with validation
|
|
256
|
+
# @param [Object] created_at Value to be assigned
|
|
257
|
+
def created_at=(created_at)
|
|
258
|
+
if created_at.nil?
|
|
259
|
+
raise ArgumentError, 'created_at cannot be nil'
|
|
260
|
+
end
|
|
261
|
+
|
|
262
|
+
@created_at = created_at
|
|
263
|
+
end
|
|
264
|
+
|
|
265
|
+
# Custom attribute writer method with validation
|
|
266
|
+
# @param [Object] updated_at Value to be assigned
|
|
267
|
+
def updated_at=(updated_at)
|
|
268
|
+
if updated_at.nil?
|
|
269
|
+
raise ArgumentError, 'updated_at cannot be nil'
|
|
270
|
+
end
|
|
271
|
+
|
|
272
|
+
@updated_at = updated_at
|
|
273
|
+
end
|
|
274
|
+
|
|
212
275
|
# Checks equality by comparing each attribute.
|
|
213
276
|
# @param [Object] Object to be compared
|
|
214
277
|
def ==(o)
|
|
@@ -216,12 +279,15 @@ module PAYJPv2
|
|
|
216
279
|
self.class == o.class &&
|
|
217
280
|
object == o.object &&
|
|
218
281
|
id == o.id &&
|
|
282
|
+
livemode == o.livemode &&
|
|
219
283
|
name == o.name &&
|
|
220
284
|
active == o.active &&
|
|
221
285
|
default_price_id == o.default_price_id &&
|
|
222
286
|
description == o.description &&
|
|
223
287
|
unit_label == o.unit_label &&
|
|
224
|
-
url == o.url
|
|
288
|
+
url == o.url &&
|
|
289
|
+
created_at == o.created_at &&
|
|
290
|
+
updated_at == o.updated_at
|
|
225
291
|
end
|
|
226
292
|
|
|
227
293
|
# @see the `==` method
|
|
@@ -233,7 +299,7 @@ module PAYJPv2
|
|
|
233
299
|
# Calculates hash code according to all attributes.
|
|
234
300
|
# @return [Integer] Hash code
|
|
235
301
|
def hash
|
|
236
|
-
[object, id, name, active, default_price_id, description, unit_label, url].hash
|
|
302
|
+
[object, id, livemode, name, active, default_price_id, description, unit_label, url, created_at, updated_at].hash
|
|
237
303
|
end
|
|
238
304
|
|
|
239
305
|
# Builds the object from hash
|
|
@@ -20,6 +20,9 @@ module PAYJPv2
|
|
|
20
20
|
# 税率 ID
|
|
21
21
|
attr_accessor :id
|
|
22
22
|
|
|
23
|
+
# 本番環境かどうか
|
|
24
|
+
attr_accessor :livemode
|
|
25
|
+
|
|
23
26
|
# 表示名。顧客に表示されます。
|
|
24
27
|
attr_accessor :display_name
|
|
25
28
|
|
|
@@ -36,6 +39,12 @@ module PAYJPv2
|
|
|
36
39
|
|
|
37
40
|
attr_accessor :description
|
|
38
41
|
|
|
42
|
+
# 作成日時 (UTC, ISO 8601 形式)
|
|
43
|
+
attr_accessor :created_at
|
|
44
|
+
|
|
45
|
+
# 更新日時 (UTC, ISO 8601 形式)
|
|
46
|
+
attr_accessor :updated_at
|
|
47
|
+
|
|
39
48
|
# メタデータ
|
|
40
49
|
attr_accessor :metadata
|
|
41
50
|
|
|
@@ -66,12 +75,15 @@ module PAYJPv2
|
|
|
66
75
|
{
|
|
67
76
|
:object => :object,
|
|
68
77
|
:id => :id,
|
|
78
|
+
:livemode => :livemode,
|
|
69
79
|
:display_name => :display_name,
|
|
70
80
|
:inclusive => :inclusive,
|
|
71
81
|
:percentage => :percentage,
|
|
72
82
|
:active => :active,
|
|
73
83
|
:country => :country,
|
|
74
84
|
:description => :description,
|
|
85
|
+
:created_at => :created_at,
|
|
86
|
+
:updated_at => :updated_at,
|
|
75
87
|
:metadata => :metadata
|
|
76
88
|
}
|
|
77
89
|
end
|
|
@@ -91,12 +103,15 @@ module PAYJPv2
|
|
|
91
103
|
{
|
|
92
104
|
:object => :'String',
|
|
93
105
|
:id => :'String',
|
|
106
|
+
:livemode => :'Boolean',
|
|
94
107
|
:display_name => :'String',
|
|
95
108
|
:inclusive => :'Boolean',
|
|
96
109
|
:percentage => :'Float',
|
|
97
110
|
:active => :'Boolean',
|
|
98
111
|
:country => :'Country',
|
|
99
112
|
:description => :'String',
|
|
113
|
+
:created_at => :'Time',
|
|
114
|
+
:updated_at => :'Time',
|
|
100
115
|
:metadata => :'Hash<String, MetadataValue>'
|
|
101
116
|
}
|
|
102
117
|
end
|
|
@@ -137,6 +152,12 @@ module PAYJPv2
|
|
|
137
152
|
self.id = nil
|
|
138
153
|
end
|
|
139
154
|
|
|
155
|
+
if attributes.key?(:livemode)
|
|
156
|
+
self.livemode = attributes[:livemode]
|
|
157
|
+
else
|
|
158
|
+
self.livemode = nil
|
|
159
|
+
end
|
|
160
|
+
|
|
140
161
|
if attributes.key?(:display_name)
|
|
141
162
|
self.display_name = attributes[:display_name]
|
|
142
163
|
else
|
|
@@ -173,6 +194,18 @@ module PAYJPv2
|
|
|
173
194
|
self.description = nil
|
|
174
195
|
end
|
|
175
196
|
|
|
197
|
+
if attributes.key?(:created_at)
|
|
198
|
+
self.created_at = attributes[:created_at]
|
|
199
|
+
else
|
|
200
|
+
self.created_at = nil
|
|
201
|
+
end
|
|
202
|
+
|
|
203
|
+
if attributes.key?(:updated_at)
|
|
204
|
+
self.updated_at = attributes[:updated_at]
|
|
205
|
+
else
|
|
206
|
+
self.updated_at = nil
|
|
207
|
+
end
|
|
208
|
+
|
|
176
209
|
if attributes.key?(:metadata)
|
|
177
210
|
if (value = attributes[:metadata]).is_a?(Hash)
|
|
178
211
|
self.metadata = value
|
|
@@ -202,6 +235,16 @@ module PAYJPv2
|
|
|
202
235
|
@id = id
|
|
203
236
|
end
|
|
204
237
|
|
|
238
|
+
# Custom attribute writer method with validation
|
|
239
|
+
# @param [Object] livemode Value to be assigned
|
|
240
|
+
def livemode=(livemode)
|
|
241
|
+
if livemode.nil?
|
|
242
|
+
raise ArgumentError, 'livemode cannot be nil'
|
|
243
|
+
end
|
|
244
|
+
|
|
245
|
+
@livemode = livemode
|
|
246
|
+
end
|
|
247
|
+
|
|
205
248
|
# Custom attribute writer method with validation
|
|
206
249
|
# @param [Object] display_name Value to be assigned
|
|
207
250
|
def display_name=(display_name)
|
|
@@ -242,6 +285,26 @@ module PAYJPv2
|
|
|
242
285
|
@active = active
|
|
243
286
|
end
|
|
244
287
|
|
|
288
|
+
# Custom attribute writer method with validation
|
|
289
|
+
# @param [Object] created_at Value to be assigned
|
|
290
|
+
def created_at=(created_at)
|
|
291
|
+
if created_at.nil?
|
|
292
|
+
raise ArgumentError, 'created_at cannot be nil'
|
|
293
|
+
end
|
|
294
|
+
|
|
295
|
+
@created_at = created_at
|
|
296
|
+
end
|
|
297
|
+
|
|
298
|
+
# Custom attribute writer method with validation
|
|
299
|
+
# @param [Object] updated_at Value to be assigned
|
|
300
|
+
def updated_at=(updated_at)
|
|
301
|
+
if updated_at.nil?
|
|
302
|
+
raise ArgumentError, 'updated_at cannot be nil'
|
|
303
|
+
end
|
|
304
|
+
|
|
305
|
+
@updated_at = updated_at
|
|
306
|
+
end
|
|
307
|
+
|
|
245
308
|
# Custom attribute writer method with validation
|
|
246
309
|
# @param [Object] metadata Value to be assigned
|
|
247
310
|
def metadata=(metadata)
|
|
@@ -259,12 +322,15 @@ module PAYJPv2
|
|
|
259
322
|
self.class == o.class &&
|
|
260
323
|
object == o.object &&
|
|
261
324
|
id == o.id &&
|
|
325
|
+
livemode == o.livemode &&
|
|
262
326
|
display_name == o.display_name &&
|
|
263
327
|
inclusive == o.inclusive &&
|
|
264
328
|
percentage == o.percentage &&
|
|
265
329
|
active == o.active &&
|
|
266
330
|
country == o.country &&
|
|
267
331
|
description == o.description &&
|
|
332
|
+
created_at == o.created_at &&
|
|
333
|
+
updated_at == o.updated_at &&
|
|
268
334
|
metadata == o.metadata
|
|
269
335
|
end
|
|
270
336
|
|
|
@@ -277,7 +343,7 @@ module PAYJPv2
|
|
|
277
343
|
# Calculates hash code according to all attributes.
|
|
278
344
|
# @return [Integer] Hash code
|
|
279
345
|
def hash
|
|
280
|
-
[object, id, display_name, inclusive, percentage, active, country, description, metadata].hash
|
|
346
|
+
[object, id, livemode, display_name, inclusive, percentage, active, country, description, created_at, updated_at, metadata].hash
|
|
281
347
|
end
|
|
282
348
|
|
|
283
349
|
# Builds the object from hash
|
data/lib/payjpv2/version.rb
CHANGED
|
@@ -68,6 +68,7 @@ describe 'PaymentMethodsApi' do
|
|
|
68
68
|
|
|
69
69
|
# unit tests for create_payment_method
|
|
70
70
|
# Create Payment Method
|
|
71
|
+
# **このエンドポイントはテストモードでのみ使用できます。**
|
|
71
72
|
# @param payment_method_create_request
|
|
72
73
|
# @param [Hash] opts the optional parameters
|
|
73
74
|
# @return [PaymentMethodResponse]
|
|
@@ -71,6 +71,8 @@ describe 'TaxRatesApi' do
|
|
|
71
71
|
# @option opts [Integer] :limit 取得するデータの最大件数
|
|
72
72
|
# @option opts [String] :starting_after このIDより後のデータを取得
|
|
73
73
|
# @option opts [String] :ending_before このIDより前のデータを取得
|
|
74
|
+
# @option opts [Boolean] :active この税率が有効であるかどうか。無効にした場合でも、すでに設定されている定期課金などでは使用可能です。
|
|
75
|
+
# @option opts [Boolean] :inclusive 税込みかどうか。税込 = `true` 税抜 = `false`
|
|
74
76
|
# @return [TaxRateListResponse]
|
|
75
77
|
describe 'get_all_tax_rates test' do
|
|
76
78
|
it 'should work' do
|
|
@@ -43,6 +43,12 @@ describe PAYJPv2::ProductDetailsResponse do
|
|
|
43
43
|
end
|
|
44
44
|
end
|
|
45
45
|
|
|
46
|
+
describe 'test attribute "livemode"' do
|
|
47
|
+
it 'should work' do
|
|
48
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
49
|
+
end
|
|
50
|
+
end
|
|
51
|
+
|
|
46
52
|
describe 'test attribute "name"' do
|
|
47
53
|
it 'should work' do
|
|
48
54
|
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
@@ -79,4 +85,16 @@ describe PAYJPv2::ProductDetailsResponse do
|
|
|
79
85
|
end
|
|
80
86
|
end
|
|
81
87
|
|
|
88
|
+
describe 'test attribute "created_at"' do
|
|
89
|
+
it 'should work' do
|
|
90
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
91
|
+
end
|
|
92
|
+
end
|
|
93
|
+
|
|
94
|
+
describe 'test attribute "updated_at"' do
|
|
95
|
+
it 'should work' do
|
|
96
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
97
|
+
end
|
|
98
|
+
end
|
|
99
|
+
|
|
82
100
|
end
|
|
@@ -43,6 +43,12 @@ describe PAYJPv2::TaxRateDetailsResponse do
|
|
|
43
43
|
end
|
|
44
44
|
end
|
|
45
45
|
|
|
46
|
+
describe 'test attribute "livemode"' do
|
|
47
|
+
it 'should work' do
|
|
48
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
49
|
+
end
|
|
50
|
+
end
|
|
51
|
+
|
|
46
52
|
describe 'test attribute "display_name"' do
|
|
47
53
|
it 'should work' do
|
|
48
54
|
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
@@ -79,6 +85,18 @@ describe PAYJPv2::TaxRateDetailsResponse do
|
|
|
79
85
|
end
|
|
80
86
|
end
|
|
81
87
|
|
|
88
|
+
describe 'test attribute "created_at"' do
|
|
89
|
+
it 'should work' do
|
|
90
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
91
|
+
end
|
|
92
|
+
end
|
|
93
|
+
|
|
94
|
+
describe 'test attribute "updated_at"' do
|
|
95
|
+
it 'should work' do
|
|
96
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
97
|
+
end
|
|
98
|
+
end
|
|
99
|
+
|
|
82
100
|
describe 'test attribute "metadata"' do
|
|
83
101
|
it 'should work' do
|
|
84
102
|
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|