jamm 1.3.0 → 1.4.1
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/jamm.gemspec +1 -1
- data/lib/jamm/api/api/customer_api.rb +82 -52
- data/lib/jamm/api/api/healthcheck_api.rb +18 -15
- data/lib/jamm/api/api/payment_api.rb +113 -62
- data/lib/jamm/api/api/webhook_service_api.rb +41 -28
- data/lib/jamm/api/api_client.rb +74 -66
- data/lib/jamm/api/api_error.rb +16 -16
- data/lib/jamm/api/configuration.rb +42 -34
- data/lib/jamm/api/models/apiv1_error.rb +56 -44
- data/lib/jamm/api/models/apiv1_status.rb +57 -47
- data/lib/jamm/api/models/customer_service_update_customer_body.rb +107 -69
- data/lib/jamm/api/models/googlerpc_status.rb +61 -45
- data/lib/jamm/api/models/protobuf_any.rb +42 -35
- data/lib/jamm/api/models/v1_add_charge_request.rb +59 -44
- data/lib/jamm/api/models/v1_add_charge_response.rb +59 -44
- data/lib/jamm/api/models/v1_bank.rb +150 -95
- data/lib/jamm/api/models/v1_bank_assets.rb +60 -47
- data/lib/jamm/api/models/v1_bank_branch.rb +83 -56
- data/lib/jamm/api/models/v1_bank_information.rb +71 -51
- data/lib/jamm/api/models/v1_bank_quota.rb +99 -64
- data/lib/jamm/api/models/v1_bank_scheduled_maintenance_period.rb +75 -52
- data/lib/jamm/api/models/v1_buyer.rb +104 -76
- data/lib/jamm/api/models/v1_charge.rb +67 -52
- data/lib/jamm/api/models/v1_charge_message.rb +151 -93
- data/lib/jamm/api/models/v1_charge_message_status.rb +17 -18
- data/lib/jamm/api/models/v1_charge_result.rb +152 -93
- data/lib/jamm/api/models/v1_contract.rb +64 -52
- data/lib/jamm/api/models/v1_contract_message.rb +67 -48
- data/lib/jamm/api/models/v1_contract_status.rb +20 -21
- data/lib/jamm/api/models/v1_create_contract_with_charge_request.rb +59 -44
- data/lib/jamm/api/models/v1_create_contract_with_charge_response.rb +67 -48
- data/lib/jamm/api/models/v1_create_contract_without_charge_request.rb +51 -40
- data/lib/jamm/api/models/v1_create_contract_without_charge_response.rb +59 -44
- data/lib/jamm/api/models/v1_create_customer_request.rb +42 -35
- data/lib/jamm/api/models/v1_create_customer_response.rb +42 -35
- data/lib/jamm/api/models/v1_customer.rb +91 -60
- data/lib/jamm/api/models/v1_delete_customer_response.rb +42 -35
- data/lib/jamm/api/models/v1_deposit_type.rb +14 -15
- data/lib/jamm/api/models/v1_error_detail.rb +57 -44
- data/lib/jamm/api/models/v1_error_response.rb +46 -38
- data/lib/jamm/api/models/v1_error_type.rb +30 -31
- data/lib/jamm/api/models/v1_event_type.rb +20 -21
- data/lib/jamm/api/models/v1_get_bank_response.rb +42 -35
- data/lib/jamm/api/models/v1_get_branch_response.rb +42 -35
- data/lib/jamm/api/models/v1_get_branches_response.rb +44 -36
- data/lib/jamm/api/models/v1_get_charge_response.rb +51 -40
- data/lib/jamm/api/models/v1_get_charges_response.rb +60 -45
- data/lib/jamm/api/models/v1_get_contract_response.rb +51 -40
- data/lib/jamm/api/models/v1_get_customer_response.rb +42 -35
- data/lib/jamm/api/models/v1_get_major_banks_response.rb +59 -44
- data/lib/jamm/api/models/v1_initial_charge.rb +61 -48
- data/lib/jamm/api/models/v1_kyc_status.rb +16 -17
- data/lib/jamm/api/models/v1_merchant.rb +51 -40
- data/lib/jamm/api/models/v1_merchant_customer.rb +51 -40
- data/lib/jamm/api/models/v1_merchant_webhook_message.rb +75 -57
- data/lib/jamm/api/models/v1_message_response.rb +67 -48
- data/lib/jamm/api/models/v1_off_session_payment_request.rb +51 -40
- data/lib/jamm/api/models/v1_off_session_payment_response.rb +51 -40
- data/lib/jamm/api/models/v1_on_session_payment_data.rb +67 -48
- data/lib/jamm/api/models/v1_on_session_payment_error.rb +55 -45
- data/lib/jamm/api/models/v1_on_session_payment_error_code.rb +21 -22
- data/lib/jamm/api/models/v1_on_session_payment_request.rb +67 -48
- data/lib/jamm/api/models/v1_on_session_payment_response.rb +59 -44
- data/lib/jamm/api/models/v1_pagination.rb +51 -40
- data/lib/jamm/api/models/v1_payment_authorization_status.rb +14 -15
- data/lib/jamm/api/models/v1_payment_link.rb +57 -44
- data/lib/jamm/api/models/v1_ping_response.rb +42 -35
- data/lib/jamm/api/models/v1_search_banks_response.rb +44 -36
- data/lib/jamm/api/models/v1_search_branches_response.rb +44 -36
- data/lib/jamm/api/models/v1_update_customer_response.rb +42 -35
- data/lib/jamm/api/models/v1_url.rb +48 -39
- data/lib/jamm/api/models/v1_user_account_message.rb +67 -48
- data/lib/jamm/api/models/v1_withdraw_request.rb +51 -40
- data/lib/jamm/api/models/v1_withdraw_response.rb +51 -40
- data/lib/jamm/api/version.rb +11 -11
- data/lib/jamm/api.rb +10 -10
- data/lib/jamm/charge.rb +12 -0
- data/lib/jamm/deprecation.rb +13 -0
- data/lib/jamm/payment.rb +61 -0
- data/lib/jamm/version.rb +1 -1
- data/lib/jamm.rb +2 -0
- metadata +5 -3
@@ -1,24 +1,27 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
#
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
1
|
+
=begin
|
2
|
+
#Jamm API
|
3
|
+
|
4
|
+
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.9.0
|
10
|
+
|
11
|
+
=end
|
12
12
|
|
13
13
|
require 'date'
|
14
14
|
require 'time'
|
15
15
|
|
16
16
|
module Api
|
17
17
|
class Apiv1Status
|
18
|
-
attr_accessor :payment
|
18
|
+
attr_accessor :payment
|
19
|
+
|
20
|
+
attr_accessor :kyc
|
19
21
|
|
20
22
|
class EnumAttributeValidator
|
21
|
-
attr_reader :datatype
|
23
|
+
attr_reader :datatype
|
24
|
+
attr_reader :allowable_values
|
22
25
|
|
23
26
|
def initialize(datatype, allowable_values)
|
24
27
|
@allowable_values = allowable_values.map do |value|
|
@@ -41,8 +44,8 @@ module Api
|
|
41
44
|
# Attribute mapping from ruby-style variable name to JSON key.
|
42
45
|
def self.attribute_map
|
43
46
|
{
|
44
|
-
:payment => :payment,
|
45
|
-
:kyc => :kyc
|
47
|
+
:'payment' => :'payment',
|
48
|
+
:'kyc' => :'kyc'
|
46
49
|
}
|
47
50
|
end
|
48
51
|
|
@@ -54,46 +57,51 @@ module Api
|
|
54
57
|
# Attribute type mapping.
|
55
58
|
def self.openapi_types
|
56
59
|
{
|
57
|
-
:payment => :PaymentAuthorizationStatus,
|
58
|
-
:kyc => :KycStatus
|
60
|
+
:'payment' => :'PaymentAuthorizationStatus',
|
61
|
+
:'kyc' => :'KycStatus'
|
59
62
|
}
|
60
63
|
end
|
61
64
|
|
62
65
|
# List of attributes with nullable: true
|
63
66
|
def self.openapi_nullable
|
64
|
-
Set.new([
|
67
|
+
Set.new([
|
68
|
+
])
|
65
69
|
end
|
66
70
|
|
67
71
|
# Initializes the object
|
68
72
|
# @param [Hash] attributes Model attributes in the form of hash
|
69
73
|
def initialize(attributes = {})
|
70
|
-
|
74
|
+
if (!attributes.is_a?(Hash))
|
75
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Api::Apiv1Status` initialize method"
|
76
|
+
end
|
71
77
|
|
72
78
|
# check to see if the attribute exists and convert string to symbol for hash key
|
73
|
-
attributes = attributes.each_with_object({})
|
74
|
-
|
75
|
-
|
79
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
80
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
81
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Api::Apiv1Status`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
82
|
+
end
|
76
83
|
h[k.to_sym] = v
|
77
|
-
|
84
|
+
}
|
78
85
|
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
86
|
+
if attributes.key?(:'payment')
|
87
|
+
self.payment = attributes[:'payment']
|
88
|
+
else
|
89
|
+
self.payment = 'PAYMENT_AUTHORIZATION_STATUS_UNSPECIFIED'
|
90
|
+
end
|
84
91
|
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
92
|
+
if attributes.key?(:'kyc')
|
93
|
+
self.kyc = attributes[:'kyc']
|
94
|
+
else
|
95
|
+
self.kyc = 'KYC_STATUS_UNSPECIFIED'
|
96
|
+
end
|
90
97
|
end
|
91
98
|
|
92
99
|
# Show invalid properties with the reasons. Usually used together with valid?
|
93
100
|
# @return Array for valid properties with the reasons
|
94
101
|
def list_invalid_properties
|
95
102
|
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
96
|
-
|
103
|
+
invalid_properties = Array.new
|
104
|
+
invalid_properties
|
97
105
|
end
|
98
106
|
|
99
107
|
# Check to see if the all the properties in the model are valid
|
@@ -105,18 +113,17 @@ module Api
|
|
105
113
|
|
106
114
|
# Checks equality by comparing each attribute.
|
107
115
|
# @param [Object] Object to be compared
|
108
|
-
def ==(
|
109
|
-
return true if equal?(
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
kyc == other.kyc
|
116
|
+
def ==(o)
|
117
|
+
return true if self.equal?(o)
|
118
|
+
self.class == o.class &&
|
119
|
+
payment == o.payment &&
|
120
|
+
kyc == o.kyc
|
114
121
|
end
|
115
122
|
|
116
123
|
# @see the `==` method
|
117
124
|
# @param [Object] Object to be compared
|
118
|
-
def eql?(
|
119
|
-
self ==
|
125
|
+
def eql?(o)
|
126
|
+
self == o
|
120
127
|
end
|
121
128
|
|
122
129
|
# Calculates hash code according to all attributes.
|
@@ -130,18 +137,19 @@ module Api
|
|
130
137
|
# @return [Object] Returns the model itself
|
131
138
|
def self.build_from_hash(attributes)
|
132
139
|
return nil unless attributes.is_a?(Hash)
|
133
|
-
|
134
140
|
attributes = attributes.transform_keys(&:to_sym)
|
135
141
|
transformed_hash = {}
|
136
142
|
openapi_types.each_pair do |key, type|
|
137
143
|
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
138
|
-
transformed_hash[key
|
144
|
+
transformed_hash["#{key}"] = nil
|
139
145
|
elsif type =~ /\AArray<(.*)>/i
|
140
146
|
# check to ensure the input is an array given that the attribute
|
141
147
|
# is documented as an array but the input is not
|
142
|
-
|
148
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
149
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
150
|
+
end
|
143
151
|
elsif !attributes[attribute_map[key]].nil?
|
144
|
-
transformed_hash[key
|
152
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
145
153
|
end
|
146
154
|
end
|
147
155
|
new(transformed_hash)
|
@@ -207,7 +215,7 @@ module Api
|
|
207
215
|
def to_hash
|
208
216
|
hash = {}
|
209
217
|
self.class.attribute_map.each_pair do |attr, param|
|
210
|
-
value = send(attr)
|
218
|
+
value = self.send(attr)
|
211
219
|
if value.nil?
|
212
220
|
is_nullable = self.class.openapi_nullable.include?(attr)
|
213
221
|
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
@@ -235,5 +243,7 @@ module Api
|
|
235
243
|
value
|
236
244
|
end
|
237
245
|
end
|
246
|
+
|
238
247
|
end
|
248
|
+
|
239
249
|
end
|
@@ -1,14 +1,14 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
#
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
1
|
+
=begin
|
2
|
+
#Jamm API
|
3
|
+
|
4
|
+
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.9.0
|
10
|
+
|
11
|
+
=end
|
12
12
|
|
13
13
|
require 'date'
|
14
14
|
require 'time'
|
@@ -16,7 +16,21 @@ require 'time'
|
|
16
16
|
module Api
|
17
17
|
# UpdateCustomerRequest is the request to update a customer. We strongly recommend to call this endpoint when you need to update the customer's information for better experience on our dashboard and customer support. UpdateCustomerRequest はCustomerを更新するためのリクエストです。 加盟店の管理画面でより良い体験を提供し、カスタマーサポートを向上させるため、ストアの顧客情報が変更されたら 当エンドポイントを呼び出すことを推奨します。
|
18
18
|
class CustomerServiceUpdateCustomerBody
|
19
|
-
attr_accessor :email
|
19
|
+
attr_accessor :email
|
20
|
+
|
21
|
+
attr_accessor :force_kyc
|
22
|
+
|
23
|
+
attr_accessor :name
|
24
|
+
|
25
|
+
attr_accessor :katakana_last_name
|
26
|
+
|
27
|
+
attr_accessor :katakana_first_name
|
28
|
+
|
29
|
+
attr_accessor :address
|
30
|
+
|
31
|
+
attr_accessor :birth_date
|
32
|
+
|
33
|
+
attr_accessor :gender
|
20
34
|
|
21
35
|
# Arbitrary key-value additional information about the customer. All the existing metadata will be overwritten by the new metadata. Customerに関する任意のキーと値の追加情報。 すべての既存のメタデータは新しいメタデータで上書きされます。
|
22
36
|
attr_accessor :metadata
|
@@ -24,15 +38,15 @@ module Api
|
|
24
38
|
# Attribute mapping from ruby-style variable name to JSON key.
|
25
39
|
def self.attribute_map
|
26
40
|
{
|
27
|
-
:email => :email,
|
28
|
-
:force_kyc => :forceKyc,
|
29
|
-
:name => :name,
|
30
|
-
:katakana_last_name => :katakanaLastName,
|
31
|
-
:katakana_first_name => :katakanaFirstName,
|
32
|
-
:address => :address,
|
33
|
-
:birth_date => :birthDate,
|
34
|
-
:gender => :gender,
|
35
|
-
:metadata => :metadata
|
41
|
+
:'email' => :'email',
|
42
|
+
:'force_kyc' => :'forceKyc',
|
43
|
+
:'name' => :'name',
|
44
|
+
:'katakana_last_name' => :'katakanaLastName',
|
45
|
+
:'katakana_first_name' => :'katakanaFirstName',
|
46
|
+
:'address' => :'address',
|
47
|
+
:'birth_date' => :'birthDate',
|
48
|
+
:'gender' => :'gender',
|
49
|
+
:'metadata' => :'metadata'
|
36
50
|
}
|
37
51
|
end
|
38
52
|
|
@@ -44,62 +58,84 @@ module Api
|
|
44
58
|
# Attribute type mapping.
|
45
59
|
def self.openapi_types
|
46
60
|
{
|
47
|
-
:email => :String,
|
48
|
-
:force_kyc => :Boolean,
|
49
|
-
:name => :String,
|
50
|
-
:katakana_last_name => :String,
|
51
|
-
:katakana_first_name => :String,
|
52
|
-
:address => :String,
|
53
|
-
:birth_date => :String,
|
54
|
-
:gender => :String,
|
55
|
-
:metadata => :'Hash<String, String>'
|
61
|
+
:'email' => :'String',
|
62
|
+
:'force_kyc' => :'Boolean',
|
63
|
+
:'name' => :'String',
|
64
|
+
:'katakana_last_name' => :'String',
|
65
|
+
:'katakana_first_name' => :'String',
|
66
|
+
:'address' => :'String',
|
67
|
+
:'birth_date' => :'String',
|
68
|
+
:'gender' => :'String',
|
69
|
+
:'metadata' => :'Hash<String, String>'
|
56
70
|
}
|
57
71
|
end
|
58
72
|
|
59
73
|
# List of attributes with nullable: true
|
60
74
|
def self.openapi_nullable
|
61
|
-
Set.new([
|
75
|
+
Set.new([
|
76
|
+
])
|
62
77
|
end
|
63
78
|
|
64
79
|
# Initializes the object
|
65
80
|
# @param [Hash] attributes Model attributes in the form of hash
|
66
81
|
def initialize(attributes = {})
|
67
|
-
|
82
|
+
if (!attributes.is_a?(Hash))
|
83
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Api::CustomerServiceUpdateCustomerBody` initialize method"
|
84
|
+
end
|
68
85
|
|
69
86
|
# check to see if the attribute exists and convert string to symbol for hash key
|
70
|
-
attributes = attributes.each_with_object({})
|
71
|
-
|
72
|
-
|
87
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
88
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
89
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Api::CustomerServiceUpdateCustomerBody`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
90
|
+
end
|
73
91
|
h[k.to_sym] = v
|
74
|
-
|
75
|
-
|
76
|
-
self.email = attributes[:email] if attributes.key?(:email)
|
92
|
+
}
|
77
93
|
|
78
|
-
|
94
|
+
if attributes.key?(:'email')
|
95
|
+
self.email = attributes[:'email']
|
96
|
+
end
|
79
97
|
|
80
|
-
|
98
|
+
if attributes.key?(:'force_kyc')
|
99
|
+
self.force_kyc = attributes[:'force_kyc']
|
100
|
+
end
|
81
101
|
|
82
|
-
|
102
|
+
if attributes.key?(:'name')
|
103
|
+
self.name = attributes[:'name']
|
104
|
+
end
|
83
105
|
|
84
|
-
|
106
|
+
if attributes.key?(:'katakana_last_name')
|
107
|
+
self.katakana_last_name = attributes[:'katakana_last_name']
|
108
|
+
end
|
85
109
|
|
86
|
-
|
110
|
+
if attributes.key?(:'katakana_first_name')
|
111
|
+
self.katakana_first_name = attributes[:'katakana_first_name']
|
112
|
+
end
|
87
113
|
|
88
|
-
|
114
|
+
if attributes.key?(:'address')
|
115
|
+
self.address = attributes[:'address']
|
116
|
+
end
|
89
117
|
|
90
|
-
|
118
|
+
if attributes.key?(:'birth_date')
|
119
|
+
self.birth_date = attributes[:'birth_date']
|
120
|
+
end
|
91
121
|
|
92
|
-
|
93
|
-
|
122
|
+
if attributes.key?(:'gender')
|
123
|
+
self.gender = attributes[:'gender']
|
124
|
+
end
|
94
125
|
|
95
|
-
|
126
|
+
if attributes.key?(:'metadata')
|
127
|
+
if (value = attributes[:'metadata']).is_a?(Hash)
|
128
|
+
self.metadata = value
|
129
|
+
end
|
130
|
+
end
|
96
131
|
end
|
97
132
|
|
98
133
|
# Show invalid properties with the reasons. Usually used together with valid?
|
99
134
|
# @return Array for valid properties with the reasons
|
100
135
|
def list_invalid_properties
|
101
136
|
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
102
|
-
|
137
|
+
invalid_properties = Array.new
|
138
|
+
invalid_properties
|
103
139
|
end
|
104
140
|
|
105
141
|
# Check to see if the all the properties in the model are valid
|
@@ -111,25 +147,24 @@ module Api
|
|
111
147
|
|
112
148
|
# Checks equality by comparing each attribute.
|
113
149
|
# @param [Object] Object to be compared
|
114
|
-
def ==(
|
115
|
-
return true if equal?(
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
metadata == other.metadata
|
150
|
+
def ==(o)
|
151
|
+
return true if self.equal?(o)
|
152
|
+
self.class == o.class &&
|
153
|
+
email == o.email &&
|
154
|
+
force_kyc == o.force_kyc &&
|
155
|
+
name == o.name &&
|
156
|
+
katakana_last_name == o.katakana_last_name &&
|
157
|
+
katakana_first_name == o.katakana_first_name &&
|
158
|
+
address == o.address &&
|
159
|
+
birth_date == o.birth_date &&
|
160
|
+
gender == o.gender &&
|
161
|
+
metadata == o.metadata
|
127
162
|
end
|
128
163
|
|
129
164
|
# @see the `==` method
|
130
165
|
# @param [Object] Object to be compared
|
131
|
-
def eql?(
|
132
|
-
self ==
|
166
|
+
def eql?(o)
|
167
|
+
self == o
|
133
168
|
end
|
134
169
|
|
135
170
|
# Calculates hash code according to all attributes.
|
@@ -143,18 +178,19 @@ module Api
|
|
143
178
|
# @return [Object] Returns the model itself
|
144
179
|
def self.build_from_hash(attributes)
|
145
180
|
return nil unless attributes.is_a?(Hash)
|
146
|
-
|
147
181
|
attributes = attributes.transform_keys(&:to_sym)
|
148
182
|
transformed_hash = {}
|
149
183
|
openapi_types.each_pair do |key, type|
|
150
184
|
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
151
|
-
transformed_hash[key
|
185
|
+
transformed_hash["#{key}"] = nil
|
152
186
|
elsif type =~ /\AArray<(.*)>/i
|
153
187
|
# check to ensure the input is an array given that the attribute
|
154
188
|
# is documented as an array but the input is not
|
155
|
-
|
189
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
190
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
191
|
+
end
|
156
192
|
elsif !attributes[attribute_map[key]].nil?
|
157
|
-
transformed_hash[key
|
193
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
158
194
|
end
|
159
195
|
end
|
160
196
|
new(transformed_hash)
|
@@ -220,7 +256,7 @@ module Api
|
|
220
256
|
def to_hash
|
221
257
|
hash = {}
|
222
258
|
self.class.attribute_map.each_pair do |attr, param|
|
223
|
-
value = send(attr)
|
259
|
+
value = self.send(attr)
|
224
260
|
if value.nil?
|
225
261
|
is_nullable = self.class.openapi_nullable.include?(attr)
|
226
262
|
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
@@ -248,5 +284,7 @@ module Api
|
|
248
284
|
value
|
249
285
|
end
|
250
286
|
end
|
287
|
+
|
251
288
|
end
|
289
|
+
|
252
290
|
end
|
@@ -1,28 +1,32 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
#
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
1
|
+
=begin
|
2
|
+
#Jamm API
|
3
|
+
|
4
|
+
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.9.0
|
10
|
+
|
11
|
+
=end
|
12
12
|
|
13
13
|
require 'date'
|
14
14
|
require 'time'
|
15
15
|
|
16
16
|
module Api
|
17
17
|
class GooglerpcStatus
|
18
|
-
attr_accessor :code
|
18
|
+
attr_accessor :code
|
19
|
+
|
20
|
+
attr_accessor :message
|
21
|
+
|
22
|
+
attr_accessor :details
|
19
23
|
|
20
24
|
# Attribute mapping from ruby-style variable name to JSON key.
|
21
25
|
def self.attribute_map
|
22
26
|
{
|
23
|
-
:code => :code,
|
24
|
-
:message => :message,
|
25
|
-
:details => :details
|
27
|
+
:'code' => :'code',
|
28
|
+
:'message' => :'message',
|
29
|
+
:'details' => :'details'
|
26
30
|
}
|
27
31
|
end
|
28
32
|
|
@@ -34,44 +38,54 @@ module Api
|
|
34
38
|
# Attribute type mapping.
|
35
39
|
def self.openapi_types
|
36
40
|
{
|
37
|
-
:code => :Integer,
|
38
|
-
:message => :String,
|
39
|
-
:details => :'Array<ProtobufAny>'
|
41
|
+
:'code' => :'Integer',
|
42
|
+
:'message' => :'String',
|
43
|
+
:'details' => :'Array<ProtobufAny>'
|
40
44
|
}
|
41
45
|
end
|
42
46
|
|
43
47
|
# List of attributes with nullable: true
|
44
48
|
def self.openapi_nullable
|
45
|
-
Set.new([
|
49
|
+
Set.new([
|
50
|
+
])
|
46
51
|
end
|
47
52
|
|
48
53
|
# Initializes the object
|
49
54
|
# @param [Hash] attributes Model attributes in the form of hash
|
50
55
|
def initialize(attributes = {})
|
51
|
-
|
56
|
+
if (!attributes.is_a?(Hash))
|
57
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Api::GooglerpcStatus` initialize method"
|
58
|
+
end
|
52
59
|
|
53
60
|
# check to see if the attribute exists and convert string to symbol for hash key
|
54
|
-
attributes = attributes.each_with_object({})
|
55
|
-
|
56
|
-
|
61
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
62
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
63
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Api::GooglerpcStatus`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
64
|
+
end
|
57
65
|
h[k.to_sym] = v
|
58
|
-
|
59
|
-
|
60
|
-
self.code = attributes[:code] if attributes.key?(:code)
|
66
|
+
}
|
61
67
|
|
62
|
-
|
68
|
+
if attributes.key?(:'code')
|
69
|
+
self.code = attributes[:'code']
|
70
|
+
end
|
63
71
|
|
64
|
-
|
65
|
-
|
72
|
+
if attributes.key?(:'message')
|
73
|
+
self.message = attributes[:'message']
|
74
|
+
end
|
66
75
|
|
67
|
-
|
76
|
+
if attributes.key?(:'details')
|
77
|
+
if (value = attributes[:'details']).is_a?(Array)
|
78
|
+
self.details = value
|
79
|
+
end
|
80
|
+
end
|
68
81
|
end
|
69
82
|
|
70
83
|
# Show invalid properties with the reasons. Usually used together with valid?
|
71
84
|
# @return Array for valid properties with the reasons
|
72
85
|
def list_invalid_properties
|
73
86
|
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
74
|
-
|
87
|
+
invalid_properties = Array.new
|
88
|
+
invalid_properties
|
75
89
|
end
|
76
90
|
|
77
91
|
# Check to see if the all the properties in the model are valid
|
@@ -83,19 +97,18 @@ module Api
|
|
83
97
|
|
84
98
|
# Checks equality by comparing each attribute.
|
85
99
|
# @param [Object] Object to be compared
|
86
|
-
def ==(
|
87
|
-
return true if equal?(
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
details == other.details
|
100
|
+
def ==(o)
|
101
|
+
return true if self.equal?(o)
|
102
|
+
self.class == o.class &&
|
103
|
+
code == o.code &&
|
104
|
+
message == o.message &&
|
105
|
+
details == o.details
|
93
106
|
end
|
94
107
|
|
95
108
|
# @see the `==` method
|
96
109
|
# @param [Object] Object to be compared
|
97
|
-
def eql?(
|
98
|
-
self ==
|
110
|
+
def eql?(o)
|
111
|
+
self == o
|
99
112
|
end
|
100
113
|
|
101
114
|
# Calculates hash code according to all attributes.
|
@@ -109,18 +122,19 @@ module Api
|
|
109
122
|
# @return [Object] Returns the model itself
|
110
123
|
def self.build_from_hash(attributes)
|
111
124
|
return nil unless attributes.is_a?(Hash)
|
112
|
-
|
113
125
|
attributes = attributes.transform_keys(&:to_sym)
|
114
126
|
transformed_hash = {}
|
115
127
|
openapi_types.each_pair do |key, type|
|
116
128
|
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
117
|
-
transformed_hash[key
|
129
|
+
transformed_hash["#{key}"] = nil
|
118
130
|
elsif type =~ /\AArray<(.*)>/i
|
119
131
|
# check to ensure the input is an array given that the attribute
|
120
132
|
# is documented as an array but the input is not
|
121
|
-
|
133
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
134
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
135
|
+
end
|
122
136
|
elsif !attributes[attribute_map[key]].nil?
|
123
|
-
transformed_hash[key
|
137
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
124
138
|
end
|
125
139
|
end
|
126
140
|
new(transformed_hash)
|
@@ -186,7 +200,7 @@ module Api
|
|
186
200
|
def to_hash
|
187
201
|
hash = {}
|
188
202
|
self.class.attribute_map.each_pair do |attr, param|
|
189
|
-
value = send(attr)
|
203
|
+
value = self.send(attr)
|
190
204
|
if value.nil?
|
191
205
|
is_nullable = self.class.openapi_nullable.include?(attr)
|
192
206
|
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
@@ -214,5 +228,7 @@ module Api
|
|
214
228
|
value
|
215
229
|
end
|
216
230
|
end
|
231
|
+
|
217
232
|
end
|
233
|
+
|
218
234
|
end
|