transferzero-sdk 1.7.0 → 1.8.0

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.
Files changed (130) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +5 -7
  3. data/docs/AccountMeta.md +1 -1
  4. data/docs/Currency.md +1 -1
  5. data/docs/CurrencyExchange.md +1 -1
  6. data/docs/CurrencyOpposite.md +1 -1
  7. data/docs/Document.md +3 -3
  8. data/docs/DocumentsApi.md +74 -2
  9. data/docs/FieldSelectValidation.md +1 -1
  10. data/docs/FieldValidation.md +1 -1
  11. data/docs/PayinMethodDetails.md +1 -3
  12. data/docs/PayinMethodDetailsMobile.md +1 -1
  13. data/docs/PaymentMethod.md +2 -2
  14. data/docs/PaymentMethodOpposite.md +2 -2
  15. data/docs/PayoutMethodDetails.md +1 -7
  16. data/docs/PayoutMethodDetailsIBAN.md +1 -1
  17. data/docs/Recipient.md +4 -4
  18. data/docs/RecipientsApi.md +1 -1
  19. data/docs/Sender.md +33 -63
  20. data/lib/transferzero-sdk.rb +0 -3
  21. data/lib/transferzero-sdk/api/documents_api.rb +63 -0
  22. data/lib/transferzero-sdk/api/recipients_api.rb +2 -2
  23. data/lib/transferzero-sdk/api_client.rb +3 -5
  24. data/lib/transferzero-sdk/models/account.rb +69 -70
  25. data/lib/transferzero-sdk/models/account_list_response.rb +66 -67
  26. data/lib/transferzero-sdk/models/account_meta.rb +60 -61
  27. data/lib/transferzero-sdk/models/account_response.rb +65 -66
  28. data/lib/transferzero-sdk/models/account_validation_error.rb +60 -61
  29. data/lib/transferzero-sdk/models/account_validation_request.rb +163 -164
  30. data/lib/transferzero-sdk/models/account_validation_response.rb +65 -66
  31. data/lib/transferzero-sdk/models/account_validation_result.rb +60 -61
  32. data/lib/transferzero-sdk/models/api_log.rb +135 -136
  33. data/lib/transferzero-sdk/models/api_log_list_response.rb +69 -70
  34. data/lib/transferzero-sdk/models/api_log_response.rb +59 -60
  35. data/lib/transferzero-sdk/models/currency.rb +141 -142
  36. data/lib/transferzero-sdk/models/currency_exchange.rb +157 -158
  37. data/lib/transferzero-sdk/models/currency_exchange_list_response.rb +61 -62
  38. data/lib/transferzero-sdk/models/currency_list_response.rb +61 -62
  39. data/lib/transferzero-sdk/models/currency_opposite.rb +165 -166
  40. data/lib/transferzero-sdk/models/debit.rb +150 -151
  41. data/lib/transferzero-sdk/models/debit_list_request.rb +60 -61
  42. data/lib/transferzero-sdk/models/debit_list_response.rb +66 -67
  43. data/lib/transferzero-sdk/models/debit_request.rb +59 -60
  44. data/lib/transferzero-sdk/models/debit_request_wrapper.rb +79 -80
  45. data/lib/transferzero-sdk/models/debit_response.rb +59 -60
  46. data/lib/transferzero-sdk/models/document.rb +177 -179
  47. data/lib/transferzero-sdk/models/document_list_response.rb +66 -67
  48. data/lib/transferzero-sdk/models/document_request.rb +59 -60
  49. data/lib/transferzero-sdk/models/document_response.rb +59 -60
  50. data/lib/transferzero-sdk/models/document_webhook.rb +95 -96
  51. data/lib/transferzero-sdk/models/error_status.rb +65 -66
  52. data/lib/transferzero-sdk/models/field_description.rb +94 -95
  53. data/lib/transferzero-sdk/models/field_select_validation.rb +69 -70
  54. data/lib/transferzero-sdk/models/field_validation.rb +77 -78
  55. data/lib/transferzero-sdk/models/pagination.rb +96 -97
  56. data/lib/transferzero-sdk/models/pagination_meta.rb +59 -60
  57. data/lib/transferzero-sdk/models/payin_method.rb +96 -97
  58. data/lib/transferzero-sdk/models/payin_method_details.rb +110 -122
  59. data/lib/transferzero-sdk/models/payin_method_details_mobile.rb +74 -75
  60. data/lib/transferzero-sdk/models/payin_method_details_ngn_bank.rb +70 -71
  61. data/lib/transferzero-sdk/models/payin_method_request.rb +59 -60
  62. data/lib/transferzero-sdk/models/payment_method.rb +108 -109
  63. data/lib/transferzero-sdk/models/payment_method_list_response.rb +60 -61
  64. data/lib/transferzero-sdk/models/payment_method_opposite.rb +123 -124
  65. data/lib/transferzero-sdk/models/payout_method.rb +106 -107
  66. data/lib/transferzero-sdk/models/payout_method_bank_account_type_enum.rb +19 -14
  67. data/lib/transferzero-sdk/models/payout_method_details.rb +297 -337
  68. data/lib/transferzero-sdk/models/payout_method_details_balance.rb +60 -61
  69. data/lib/transferzero-sdk/models/payout_method_details_ghs_bank.rb +96 -97
  70. data/lib/transferzero-sdk/models/payout_method_details_iban.rb +104 -100
  71. data/lib/transferzero-sdk/models/payout_method_details_mad_cash.rb +161 -162
  72. data/lib/transferzero-sdk/models/payout_method_details_mobile.rb +85 -86
  73. data/lib/transferzero-sdk/models/payout_method_details_ngn_bank.rb +103 -104
  74. data/lib/transferzero-sdk/models/payout_method_details_xof_bank.rb +107 -108
  75. data/lib/transferzero-sdk/models/payout_method_details_xof_mobile.rb +96 -97
  76. data/lib/transferzero-sdk/models/payout_method_gender_enum.rb +19 -14
  77. data/lib/transferzero-sdk/models/payout_method_identity_card_type_enum.rb +20 -15
  78. data/lib/transferzero-sdk/models/payout_method_list_response.rb +66 -67
  79. data/lib/transferzero-sdk/models/payout_method_mobile_provider_enum.rb +19 -14
  80. data/lib/transferzero-sdk/models/payout_method_request.rb +59 -60
  81. data/lib/transferzero-sdk/models/payout_method_response.rb +59 -60
  82. data/lib/transferzero-sdk/models/payout_method_webhook.rb +95 -96
  83. data/lib/transferzero-sdk/models/politically_exposed_person.rb +123 -123
  84. data/lib/transferzero-sdk/models/recipient.rb +229 -230
  85. data/lib/transferzero-sdk/models/recipient_list_response.rb +66 -67
  86. data/lib/transferzero-sdk/models/recipient_request.rb +59 -60
  87. data/lib/transferzero-sdk/models/recipient_response.rb +59 -60
  88. data/lib/transferzero-sdk/models/recipient_state.rb +27 -22
  89. data/lib/transferzero-sdk/models/recipient_webhook.rb +95 -96
  90. data/lib/transferzero-sdk/models/sender.rb +358 -521
  91. data/lib/transferzero-sdk/models/sender_list_response.rb +66 -67
  92. data/lib/transferzero-sdk/models/sender_request.rb +59 -60
  93. data/lib/transferzero-sdk/models/sender_response.rb +65 -66
  94. data/lib/transferzero-sdk/models/sender_response_existing.rb +59 -60
  95. data/lib/transferzero-sdk/models/sender_response_meta.rb +59 -60
  96. data/lib/transferzero-sdk/models/sender_state.rb +24 -19
  97. data/lib/transferzero-sdk/models/sender_webhook.rb +95 -96
  98. data/lib/transferzero-sdk/models/transaction.rb +191 -192
  99. data/lib/transferzero-sdk/models/transaction_list_response.rb +66 -67
  100. data/lib/transferzero-sdk/models/transaction_request.rb +59 -60
  101. data/lib/transferzero-sdk/models/transaction_response.rb +65 -66
  102. data/lib/transferzero-sdk/models/transaction_response_existing.rb +65 -66
  103. data/lib/transferzero-sdk/models/transaction_response_meta.rb +59 -60
  104. data/lib/transferzero-sdk/models/transaction_state.rb +28 -23
  105. data/lib/transferzero-sdk/models/transaction_traits.rb +70 -71
  106. data/lib/transferzero-sdk/models/transaction_webhook.rb +95 -96
  107. data/lib/transferzero-sdk/models/validation_error_description.rb +61 -62
  108. data/lib/transferzero-sdk/models/webhook.rb +91 -92
  109. data/lib/transferzero-sdk/models/webhook_definition.rb +106 -107
  110. data/lib/transferzero-sdk/models/webhook_definition_event_list_response.rb +60 -61
  111. data/lib/transferzero-sdk/models/webhook_definition_list_response.rb +66 -67
  112. data/lib/transferzero-sdk/models/webhook_definition_request.rb +59 -60
  113. data/lib/transferzero-sdk/models/webhook_definition_response.rb +59 -60
  114. data/lib/transferzero-sdk/models/webhook_log.rb +96 -97
  115. data/lib/transferzero-sdk/models/webhook_log_list_response.rb +69 -70
  116. data/lib/transferzero-sdk/models/webhook_log_metadata.rb +128 -129
  117. data/lib/transferzero-sdk/models/webhook_log_metadata_request.rb +79 -80
  118. data/lib/transferzero-sdk/models/webhook_log_metadata_response.rb +80 -81
  119. data/lib/transferzero-sdk/models/webhook_log_response.rb +59 -60
  120. data/lib/transferzero-sdk/version.rb +1 -1
  121. metadata +3 -15
  122. data/docs/PayinMethodDetailsBTC.md +0 -17
  123. data/docs/PayoutMethodDetailsBTC.md +0 -23
  124. data/docs/PayoutMethodDetailsGBPBank.md +0 -29
  125. data/lib/transferzero-sdk/models/payin_method_details_btc.rb +0 -204
  126. data/lib/transferzero-sdk/models/payout_method_details_btc.rb +0 -250
  127. data/lib/transferzero-sdk/models/payout_method_details_gbp_bank.rb +0 -267
  128. data/spec/models/payin_method_details_btc_spec.rb +0 -41
  129. data/spec/models/payout_method_details_btc_spec.rb +0 -59
  130. data/spec/models/payout_method_details_gbp_bank_spec.rb +0 -77
@@ -13,75 +13,75 @@ OpenAPI Generator version: 4.0.0-beta3
13
13
  require 'date'
14
14
 
15
15
  module TransferZero
16
- class DebitResponse
17
- attr_accessor :object
18
-
19
- # Attribute mapping from ruby-style variable name to JSON key.
20
- def self.attribute_map
21
- {
22
- :'object' => :'object'
23
- }
24
- end
25
-
26
- # Attribute type mapping.
27
- def self.openapi_types
28
- {
29
- :'object' => :'Debit'
30
- }
31
- end
16
+ class DebitResponse
17
+ attr_accessor :object
18
+
19
+ # Attribute mapping from ruby-style variable name to JSON key.
20
+ def self.attribute_map
21
+ {
22
+ :'object' => :'object'
23
+ }
24
+ end
32
25
 
33
- # Initializes the object
34
- # @param [Hash] attributes Model attributes in the form of hash
35
- def initialize(attributes = {})
36
- if (!attributes.is_a?(Hash))
37
- fail ArgumentError, "The input argument (attributes) must be a hash in `TransferZero::DebitResponse` initialize method"
26
+ # Attribute type mapping.
27
+ def self.openapi_types
28
+ {
29
+ :'object' => :'Debit'
30
+ }
38
31
  end
39
32
 
40
- # check to see if the attribute exists and convert string to symbol for hash key
41
- attributes = attributes.each_with_object({}) { |(k, v), h|
42
- if (!self.class.attribute_map.key?(k.to_sym))
43
- fail ArgumentError, "`#{k}` is not a valid attribute in `TransferZero::DebitResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
33
+ # Initializes the object
34
+ # @param [Hash] attributes Model attributes in the form of hash
35
+ def initialize(attributes = {})
36
+ if (!attributes.is_a?(Hash))
37
+ fail ArgumentError, "The input argument (attributes) must be a hash in `TransferZero::DebitResponse` initialize method"
44
38
  end
45
- h[k.to_sym] = v
46
- }
47
39
 
48
- if attributes.key?(:'object')
49
- self.object = attributes[:'object']
40
+ # check to see if the attribute exists and convert string to symbol for hash key
41
+ attributes = attributes.each_with_object({}) { |(k, v), h|
42
+ if (!self.class.attribute_map.key?(k.to_sym))
43
+ fail ArgumentError, "`#{k}` is not a valid attribute in `TransferZero::DebitResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
44
+ end
45
+ h[k.to_sym] = v
46
+ }
47
+
48
+ if attributes.key?(:'object')
49
+ self.object = attributes[:'object']
50
+ end
50
51
  end
51
- end
52
52
 
53
- # Show invalid properties with the reasons. Usually used together with valid?
54
- # @return Array for valid properties with the reasons
55
- def list_invalid_properties
56
- invalid_properties = Array.new
57
- invalid_properties
58
- end
53
+ # Show invalid properties with the reasons. Usually used together with valid?
54
+ # @return Array for valid properties with the reasons
55
+ def list_invalid_properties
56
+ invalid_properties = Array.new
57
+ invalid_properties
58
+ end
59
59
 
60
- # Check to see if the all the properties in the model are valid
61
- # @return true if the model is valid
62
- def valid?
63
- true
64
- end
60
+ # Check to see if the all the properties in the model are valid
61
+ # @return true if the model is valid
62
+ def valid?
63
+ true
64
+ end
65
65
 
66
- # Checks equality by comparing each attribute.
67
- # @param [Object] Object to be compared
68
- def ==(o)
69
- return true if self.equal?(o)
70
- self.class == o.class &&
71
- object == o.object
72
- end
66
+ # Checks equality by comparing each attribute.
67
+ # @param [Object] Object to be compared
68
+ def ==(o)
69
+ return true if self.equal?(o)
70
+ self.class == o.class &&
71
+ object == o.object
72
+ end
73
73
 
74
- # @see the `==` method
75
- # @param [Object] Object to be compared
76
- def eql?(o)
77
- self == o
78
- end
74
+ # @see the `==` method
75
+ # @param [Object] Object to be compared
76
+ def eql?(o)
77
+ self == o
78
+ end
79
79
 
80
- # Calculates hash code according to all attributes.
81
- # @return [Integer] Hash code
82
- def hash
83
- [object].hash
84
- end
80
+ # Calculates hash code according to all attributes.
81
+ # @return [Integer] Hash code
82
+ def hash
83
+ [object].hash
84
+ end
85
85
 
86
86
  require 'active_support/core_ext/hash'
87
87
  require 'active_support/hash_with_indifferent_access.rb'
@@ -197,6 +197,5 @@ def _to_hash(value)
197
197
  end
198
198
  end
199
199
 
200
- end
201
-
200
+ end
202
201
  end
@@ -13,229 +13,228 @@ OpenAPI Generator version: 4.0.0-beta3
13
13
  require 'date'
14
14
 
15
15
  module TransferZero
16
- class Document
17
- # Base64 encoded data uri of an image/pdf file or a fully qualified url
18
- attr_accessor :upload
16
+ class Document
17
+ attr_accessor :sender_id
19
18
 
20
- # URL of the document location
21
- attr_accessor :url
19
+ # Base64 encoded data uri of an image/pdf file or a fully qualified url
20
+ attr_accessor :upload
22
21
 
23
- # Name of the upload
24
- attr_accessor :upload_file_name
22
+ # Name of the upload
23
+ attr_accessor :upload_file_name
25
24
 
26
- # Metadata of document
27
- attr_accessor :metadata
25
+ # Metadata of document
26
+ attr_accessor :metadata
28
27
 
29
- attr_accessor :upload_content_type
28
+ attr_accessor :upload_content_type
30
29
 
31
- attr_accessor :upload_file_size
30
+ attr_accessor :upload_file_size
32
31
 
33
- # uncategorised
34
- attr_accessor :category
32
+ # uncategorised
33
+ attr_accessor :category
35
34
 
36
- # The side of the KYC ID. One of 'front' or 'back'
37
- attr_accessor :side
35
+ # The side of the KYC ID. One of 'front' or 'back'
36
+ attr_accessor :side
38
37
 
39
- # This is a brief description of the document type
40
- attr_accessor :document_type
38
+ # This is a brief description of the document type
39
+ attr_accessor :document_type
41
40
 
42
- # Issuing country of ID in 2-character alpha ISO 3166-2 country format
43
- attr_accessor :issuing_country
41
+ # Issuing country of ID in 2-character alpha ISO 3166-2 country format
42
+ attr_accessor :issuing_country
44
43
 
45
- attr_accessor :id
44
+ attr_accessor :id
46
45
 
47
- # The fields that have some problems and don't pass validation
48
- attr_accessor :errors
46
+ # The fields that have some problems and don't pass validation
47
+ attr_accessor :errors
49
48
 
50
- class EnumAttributeValidator
51
- attr_reader :datatype
52
- attr_reader :allowable_values
49
+ class EnumAttributeValidator
50
+ attr_reader :datatype
51
+ attr_reader :allowable_values
53
52
 
54
- def initialize(datatype, allowable_values)
55
- @allowable_values = allowable_values.map do |value|
56
- case datatype.to_s
57
- when /Integer/i
58
- value.to_i
59
- when /Float/i
60
- value.to_f
61
- else
62
- value
53
+ def initialize(datatype, allowable_values)
54
+ @allowable_values = allowable_values.map do |value|
55
+ case datatype.to_s
56
+ when /Integer/i
57
+ value.to_i
58
+ when /Float/i
59
+ value.to_f
60
+ else
61
+ value
62
+ end
63
63
  end
64
64
  end
65
+
66
+ def valid?(value)
67
+ !value || allowable_values.include?(value)
68
+ end
65
69
  end
66
70
 
67
- def valid?(value)
68
- !value || allowable_values.include?(value)
71
+ # Attribute mapping from ruby-style variable name to JSON key.
72
+ def self.attribute_map
73
+ {
74
+ :'sender_id' => :'sender_id',
75
+ :'upload' => :'upload',
76
+ :'upload_file_name' => :'upload_file_name',
77
+ :'metadata' => :'metadata',
78
+ :'upload_content_type' => :'upload_content_type',
79
+ :'upload_file_size' => :'upload_file_size',
80
+ :'category' => :'category',
81
+ :'side' => :'side',
82
+ :'document_type' => :'document_type',
83
+ :'issuing_country' => :'issuing_country',
84
+ :'id' => :'id',
85
+ :'errors' => :'errors'
86
+ }
69
87
  end
70
- end
71
88
 
72
- # Attribute mapping from ruby-style variable name to JSON key.
73
- def self.attribute_map
74
- {
75
- :'upload' => :'upload',
76
- :'url' => :'url',
77
- :'upload_file_name' => :'upload_file_name',
78
- :'metadata' => :'metadata',
79
- :'upload_content_type' => :'upload_content_type',
80
- :'upload_file_size' => :'upload_file_size',
81
- :'category' => :'category',
82
- :'side' => :'side',
83
- :'document_type' => :'document_type',
84
- :'issuing_country' => :'issuing_country',
85
- :'id' => :'id',
86
- :'errors' => :'errors'
87
- }
88
- end
89
+ # Attribute type mapping.
90
+ def self.openapi_types
91
+ {
92
+ :'sender_id' => :'String',
93
+ :'upload' => :'String',
94
+ :'upload_file_name' => :'String',
95
+ :'metadata' => :'Object',
96
+ :'upload_content_type' => :'String',
97
+ :'upload_file_size' => :'Integer',
98
+ :'category' => :'String',
99
+ :'side' => :'String',
100
+ :'document_type' => :'String',
101
+ :'issuing_country' => :'String',
102
+ :'id' => :'String',
103
+ :'errors' => :'Hash<String, Array<ValidationErrorDescription>>'
104
+ }
105
+ end
89
106
 
90
- # Attribute type mapping.
91
- def self.openapi_types
92
- {
93
- :'upload' => :'String',
94
- :'url' => :'String',
95
- :'upload_file_name' => :'String',
96
- :'metadata' => :'Object',
97
- :'upload_content_type' => :'String',
98
- :'upload_file_size' => :'Integer',
99
- :'category' => :'String',
100
- :'side' => :'String',
101
- :'document_type' => :'String',
102
- :'issuing_country' => :'String',
103
- :'id' => :'String',
104
- :'errors' => :'Hash<String, Array<ValidationErrorDescription>>'
105
- }
106
- end
107
+ # Initializes the object
108
+ # @param [Hash] attributes Model attributes in the form of hash
109
+ def initialize(attributes = {})
110
+ if (!attributes.is_a?(Hash))
111
+ fail ArgumentError, "The input argument (attributes) must be a hash in `TransferZero::Document` initialize method"
112
+ end
107
113
 
108
- # Initializes the object
109
- # @param [Hash] attributes Model attributes in the form of hash
110
- def initialize(attributes = {})
111
- if (!attributes.is_a?(Hash))
112
- fail ArgumentError, "The input argument (attributes) must be a hash in `TransferZero::Document` initialize method"
113
- end
114
+ # check to see if the attribute exists and convert string to symbol for hash key
115
+ attributes = attributes.each_with_object({}) { |(k, v), h|
116
+ if (!self.class.attribute_map.key?(k.to_sym))
117
+ fail ArgumentError, "`#{k}` is not a valid attribute in `TransferZero::Document`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
118
+ end
119
+ h[k.to_sym] = v
120
+ }
114
121
 
115
- # check to see if the attribute exists and convert string to symbol for hash key
116
- attributes = attributes.each_with_object({}) { |(k, v), h|
117
- if (!self.class.attribute_map.key?(k.to_sym))
118
- fail ArgumentError, "`#{k}` is not a valid attribute in `TransferZero::Document`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
122
+ if attributes.key?(:'sender_id')
123
+ self.sender_id = attributes[:'sender_id']
119
124
  end
120
- h[k.to_sym] = v
121
- }
122
125
 
123
- if attributes.key?(:'upload')
124
- self.upload = attributes[:'upload']
125
- end
126
+ if attributes.key?(:'upload')
127
+ self.upload = attributes[:'upload']
128
+ end
126
129
 
127
- if attributes.key?(:'url')
128
- self.url = attributes[:'url']
129
- end
130
+ if attributes.key?(:'upload_file_name')
131
+ self.upload_file_name = attributes[:'upload_file_name']
132
+ end
130
133
 
131
- if attributes.key?(:'upload_file_name')
132
- self.upload_file_name = attributes[:'upload_file_name']
133
- end
134
+ if attributes.key?(:'metadata')
135
+ self.metadata = attributes[:'metadata']
136
+ end
134
137
 
135
- if attributes.key?(:'metadata')
136
- self.metadata = attributes[:'metadata']
137
- end
138
+ if attributes.key?(:'upload_content_type')
139
+ self.upload_content_type = attributes[:'upload_content_type']
140
+ end
138
141
 
139
- if attributes.key?(:'upload_content_type')
140
- self.upload_content_type = attributes[:'upload_content_type']
141
- end
142
+ if attributes.key?(:'upload_file_size')
143
+ self.upload_file_size = attributes[:'upload_file_size']
144
+ end
142
145
 
143
- if attributes.key?(:'upload_file_size')
144
- self.upload_file_size = attributes[:'upload_file_size']
145
- end
146
+ if attributes.key?(:'category')
147
+ self.category = attributes[:'category']
148
+ end
146
149
 
147
- if attributes.key?(:'category')
148
- self.category = attributes[:'category']
149
- end
150
+ if attributes.key?(:'side')
151
+ self.side = attributes[:'side']
152
+ end
150
153
 
151
- if attributes.key?(:'side')
152
- self.side = attributes[:'side']
153
- end
154
+ if attributes.key?(:'document_type')
155
+ self.document_type = attributes[:'document_type']
156
+ end
154
157
 
155
- if attributes.key?(:'document_type')
156
- self.document_type = attributes[:'document_type']
157
- end
158
+ if attributes.key?(:'issuing_country')
159
+ self.issuing_country = attributes[:'issuing_country']
160
+ end
158
161
 
159
- if attributes.key?(:'issuing_country')
160
- self.issuing_country = attributes[:'issuing_country']
161
- end
162
+ if attributes.key?(:'id')
163
+ self.id = attributes[:'id']
164
+ end
162
165
 
163
- if attributes.key?(:'id')
164
- self.id = attributes[:'id']
166
+ if attributes.key?(:'errors')
167
+ if (value = attributes[:'errors']).is_a?(Hash)
168
+ self.errors = value
169
+ end
170
+ end
165
171
  end
166
172
 
167
- if attributes.key?(:'errors')
168
- if (value = attributes[:'errors']).is_a?(Hash)
169
- self.errors = value
173
+ # Show invalid properties with the reasons. Usually used together with valid?
174
+ # @return Array for valid properties with the reasons
175
+ def list_invalid_properties
176
+ invalid_properties = Array.new
177
+ if @upload.nil?
178
+ invalid_properties.push('invalid value for "upload", upload cannot be nil.')
170
179
  end
171
- end
172
- end
173
180
 
174
- # Show invalid properties with the reasons. Usually used together with valid?
175
- # @return Array for valid properties with the reasons
176
- def list_invalid_properties
177
- invalid_properties = Array.new
178
- if @upload.nil?
179
- invalid_properties.push('invalid value for "upload", upload cannot be nil.')
180
- end
181
+ if @upload_file_name.nil?
182
+ invalid_properties.push('invalid value for "upload_file_name", upload_file_name cannot be nil.')
183
+ end
181
184
 
182
- if @upload_file_name.nil?
183
- invalid_properties.push('invalid value for "upload_file_name", upload_file_name cannot be nil.')
185
+ invalid_properties
184
186
  end
185
187
 
186
- invalid_properties
187
- end
188
-
189
- # Check to see if the all the properties in the model are valid
190
- # @return true if the model is valid
191
- def valid?
192
- return false if @upload.nil?
193
- return false if @upload_file_name.nil?
194
- side_validator = EnumAttributeValidator.new('String', ["front", "back"])
195
- return false unless side_validator.valid?(@side)
196
- true
197
- end
188
+ # Check to see if the all the properties in the model are valid
189
+ # @return true if the model is valid
190
+ def valid?
191
+ return false if @upload.nil?
192
+ return false if @upload_file_name.nil?
193
+ side_validator = EnumAttributeValidator.new('String', ["front", "back"])
194
+ return false unless side_validator.valid?(@side)
195
+ true
196
+ end
198
197
 
199
- # Custom attribute writer method checking allowed values (enum).
200
- # @param [Object] side Object to be assigned
201
- def side=(side)
202
- validator = EnumAttributeValidator.new('String', ["front", "back"])
203
- unless validator.valid?(side) || side.empty?
204
- fail ArgumentError, "invalid value for \"side\", must be one of #{validator.allowable_values}."
198
+ # Custom attribute writer method checking allowed values (enum).
199
+ # @param [Object] side Object to be assigned
200
+ def side=(side)
201
+ validator = EnumAttributeValidator.new('String', ["front", "back"])
202
+ unless validator.valid?(side)
203
+ fail ArgumentError, "invalid value for \"side\", must be one of #{validator.allowable_values}."
204
+ end
205
+ @side = side
205
206
  end
206
- @side = side
207
- end
208
207
 
209
- # Checks equality by comparing each attribute.
210
- # @param [Object] Object to be compared
211
- def ==(o)
212
- return true if self.equal?(o)
213
- self.class == o.class &&
214
- upload == o.upload &&
215
- url == o.url &&
216
- upload_file_name == o.upload_file_name &&
217
- metadata == o.metadata &&
218
- upload_content_type == o.upload_content_type &&
219
- upload_file_size == o.upload_file_size &&
220
- category == o.category &&
221
- side == o.side &&
222
- document_type == o.document_type &&
223
- issuing_country == o.issuing_country &&
224
- id == o.id &&
225
- errors == o.errors
226
- end
208
+ # Checks equality by comparing each attribute.
209
+ # @param [Object] Object to be compared
210
+ def ==(o)
211
+ return true if self.equal?(o)
212
+ self.class == o.class &&
213
+ sender_id == o.sender_id &&
214
+ upload == o.upload &&
215
+ upload_file_name == o.upload_file_name &&
216
+ metadata == o.metadata &&
217
+ upload_content_type == o.upload_content_type &&
218
+ upload_file_size == o.upload_file_size &&
219
+ category == o.category &&
220
+ side == o.side &&
221
+ document_type == o.document_type &&
222
+ issuing_country == o.issuing_country &&
223
+ id == o.id &&
224
+ errors == o.errors
225
+ end
227
226
 
228
- # @see the `==` method
229
- # @param [Object] Object to be compared
230
- def eql?(o)
231
- self == o
232
- end
227
+ # @see the `==` method
228
+ # @param [Object] Object to be compared
229
+ def eql?(o)
230
+ self == o
231
+ end
233
232
 
234
- # Calculates hash code according to all attributes.
235
- # @return [Integer] Hash code
236
- def hash
237
- [upload, url, upload_file_name, metadata, upload_content_type, upload_file_size, category, side, document_type, issuing_country, id, errors].hash
238
- end
233
+ # Calculates hash code according to all attributes.
234
+ # @return [Integer] Hash code
235
+ def hash
236
+ [sender_id, upload, upload_file_name, metadata, upload_content_type, upload_file_size, category, side, document_type, issuing_country, id, errors].hash
237
+ end
239
238
 
240
239
  require 'active_support/core_ext/hash'
241
240
  require 'active_support/hash_with_indifferent_access.rb'
@@ -351,6 +350,5 @@ def _to_hash(value)
351
350
  end
352
351
  end
353
352
 
354
- end
355
-
353
+ end
356
354
  end