transferzero-sdk 1.22.0 → 1.23.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a6ec24346563dd2a0a0080678a49e90a5b92a52d55fc22382fbae9b6d6eeb450
4
- data.tar.gz: d93e10ea062d689b9250ea4032cf7fa81922822d6251de65ed61481972bda723
3
+ metadata.gz: 6ef35d260fdb8491f6c57060b3597adf5ab4bfd2778213c2904c479f82801d6d
4
+ data.tar.gz: 9b80b4dccc67d68f7cc22526834a9647e5a4b715a536f666f537cc93aeffaad1
5
5
  SHA512:
6
- metadata.gz: 581f78102bbd05ae44a48690f9f930361aea8837f9465cd88a9c614586bd20f4ee99fb44e907b30016a558be90e72fa0d1de4984fb346293874c4df0286082f4
7
- data.tar.gz: 20b2840dc7c9320515fe8d72d303af8e96e7774d2898d58a16dc95bb46c518f5366b8c1dc7498ec317243058507ac0fd71218e2541bd05d3de6f95287da0deb7
6
+ metadata.gz: 28b7fff73e9a77cbaeb9e4e708451bd1aff743475c061b365a6f886d6215a9adeeca0bb1b88389bfc09b1829ccc425cdbbac65ea9ef2a2f8e50db5b6b6016db4
7
+ data.tar.gz: 187df95aa34be68988f5c20ad8d022bf1890383dcb3f3fe5c4b28e0b1e604fe461c15ddd11aba0c4f67005a2e1722a0cb0e7b8e734229d91343846a4ea802b88
data/README.md CHANGED
@@ -7,7 +7,7 @@ Reference documentation for the TransferZero API V1
7
7
  This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
8
8
 
9
9
  - API version: 1.0
10
- - Package version: 1.22.0
10
+ - Package version: 1.23.0
11
11
  - Build package: org.openapitools.codegen.languages.RubyClientCodegen
12
12
 
13
13
  For more information, please visit:
@@ -31,15 +31,15 @@ gem build transferzero-sdk.gemspec
31
31
  Then either install the gem locally:
32
32
 
33
33
  ```shell
34
- gem install ./transferzero-sdk-1.22.0.gem
34
+ gem install ./transferzero-sdk-1.23.0.gem
35
35
  ```
36
- (for development, run `gem install --dev ./transferzero-sdk-1.22.0.gem` to install the development dependencies)
36
+ (for development, run `gem install --dev ./transferzero-sdk-1.23.0.gem` to install the development dependencies)
37
37
 
38
38
  or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
39
39
 
40
40
  Finally add this to the Gemfile:
41
41
 
42
- gem 'transferzero-sdk', '~> 1.22.0'
42
+ gem 'transferzero-sdk', '~> 1.23.0'
43
43
 
44
44
  ### Install from Git
45
45
 
@@ -207,6 +207,7 @@ Class | Method | HTTP request | Description
207
207
  - [TransferZero::PayoutMethodCashProviderEnum](docs/PayoutMethodCashProviderEnum.md)
208
208
  - [TransferZero::PayoutMethodCountryEnum](docs/PayoutMethodCountryEnum.md)
209
209
  - [TransferZero::PayoutMethodDetails](docs/PayoutMethodDetails.md)
210
+ - [TransferZero::PayoutMethodDetailsBRLBank](docs/PayoutMethodDetailsBRLBank.md)
210
211
  - [TransferZero::PayoutMethodDetailsBTC](docs/PayoutMethodDetailsBTC.md)
211
212
  - [TransferZero::PayoutMethodDetailsBalance](docs/PayoutMethodDetailsBalance.md)
212
213
  - [TransferZero::PayoutMethodDetailsGBPBank](docs/PayoutMethodDetailsGBPBank.md)
data/docs/PayoutMethod.md CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  Name | Type | Description | Notes
6
6
  ------------ | ------------- | ------------- | -------------
7
- **type** | **String** | Contains the currency to send the money to, and the type of the money movement Commonly used payout types are: - `NGN::Bank` - for Nigerian bank account payments. - `NGN::Mobile` - for Nigerian mobile money payments. - `GHS::Bank` - for Ghanaian bank account payments. - `GHS::Mobile` - for Ghanaian mobile money payments. - `GHS::Cash` - for Ghanaian cash remittance payments. - `UGX::Mobile` - for Ugandan mobile money payments. - `TZS::Mobile` - for Tanzanian mobile money payments. - `XOF::Mobile` - for mobile money payments to West-Africa. - `XOF::Bank` - for Senegalese bank account payments. - `XOF::Cash` - for Senegalese cash remittance payments. - `MAD::Cash` - for Moroccan cash remittance payments. - `EUR::Bank` - for IBAN bank transfers in EUR. - `GBP::Bank` - for IBAN bank and FP accounts transfers in GBP. - `ZAR::Bank` - for South Africa bank account payments. - `USD::Bank` - for USD account payments. *** Currently Nigeria only and in Beta phase *** - `USD::Cash` - for USD cash remittance payments. *** Currently Nigeria only and in Beta phase *** - `KES::Bank` - for Kenyan bank account payments. - `KES::Mobile` - for Kenyan mobile money payments. - `XAF::Mobile` - for mobile money payments to Cameroon. - `XAF::Bank` - for Cameroon bank account payments.. - `GNF::Mobile` - for mobile money payments to Guinea. You can also send funds to the internal balance using `CCY::Balance`, where `CCY` is the appropriate currency. See [Collection from senders](https://docs.transferzero.com/docs/additional-features/#collections-from-senders) for more info on how to collect money into internal balance | [optional]
7
+ **type** | **String** | Contains the currency to send the money to, and the type of the money movement Commonly used payout types are: - `NGN::Bank` - for Nigerian bank account payments. - `GHS::Bank` - for Ghanaian bank account payments. - `GHS::Mobile` - for Ghanaian mobile money payments. - `GHS::Cash` - for Ghanaian cash remittance payments. - `UGX::Mobile` - for Ugandan mobile money payments. - `XOF::Mobile` - for mobile money payments to West-Africa. - `XOF::Bank` - for Senegalese bank account payments. - `XOF::Cash` - for Senegalese cash remittance payments. - `MAD::Cash` - for Moroccan cash remittance payments. - `EUR::Bank` - for IBAN bank transfers in EUR. - `GBP::Bank` - for IBAN bank and FP accounts transfers in GBP. - `ZAR::Bank` - for South Africa bank account payments. - `USD::Bank` - for USD account payments. *** Currently Nigeria only and in Beta phase *** - `USD::Cash` - for USD cash remittance payments. *** Currently Nigeria only and in Beta phase *** - `KES::Bank` - for Kenyan bank account payments. - `KES::Mobile` - for Kenyan mobile money payments. - `XAF::Mobile` - for mobile money payments to Cameroon. - `XAF::Bank` - for Cameroon bank account payments.. - `GNF::Mobile` - for mobile money payments to Guinea. - `BRL::Bank` - for Brazilian bank account payments. You can also send funds to the internal balance using `CCY::Balance`, where `CCY` is the appropriate currency. See [Collection from senders](https://docs.transferzero.com/docs/additional-features/#collections-from-senders) for more info on how to collect money into internal balance | [optional]
8
8
  **details** | [**PayoutMethodDetails**](PayoutMethodDetails.md) | | [optional]
9
9
  **metadata** | [**Object**](.md) | Metadata of payout method. You can store any kind of information in this field. | [optional]
10
10
  **id** | **String** | | [optional]
@@ -8,11 +8,11 @@ Name | Type | Description | Notes
8
8
  **last_name** | **String** | |
9
9
  **bank_code** | **String** | |
10
10
  **bank_account** | **String** | |
11
- **bank_account_type** | [**PayoutMethodBankAccountTypeEnum**](PayoutMethodBankAccountTypeEnum.md) | | [optional]
11
+ **bank_account_type** | [**PayoutMethodBankAccountTypeEnum**](PayoutMethodBankAccountTypeEnum.md) | |
12
12
  **phone_number** | **String** | |
13
13
  **mobile_provider** | [**PayoutMethodMobileProviderEnum**](PayoutMethodMobileProviderEnum.md) | |
14
14
  **country** | [**PayoutMethodCountryEnum**](PayoutMethodCountryEnum.md) | |
15
- **transfer_reason** | [**PayoutMethodTransferReasonEnum**](PayoutMethodTransferReasonEnum.md) | | [optional]
15
+ **transfer_reason** | [**PayoutMethodTransferReasonEnum**](PayoutMethodTransferReasonEnum.md) | |
16
16
  **iban** | **String** | |
17
17
  **bank_name** | **String** | |
18
18
  **bank_country** | **String** | | [optional]
@@ -40,7 +40,7 @@ Name | Type | Description | Notes
40
40
  **registration_number** | **String** | | [optional]
41
41
  **nature_of_business** | [**PayoutMethodNatureOfBusinessEnum**](PayoutMethodNatureOfBusinessEnum.md) | | [optional]
42
42
  **legal_entity_type** | [**PayoutMethodLegalEntityTypeEnum**](PayoutMethodLegalEntityTypeEnum.md) | | [optional]
43
- **branch_code** | **String** | | [optional]
43
+ **branch_code** | **String** | |
44
44
  **swift_code** | **String** | |
45
45
 
46
46
  ## Code Sample
@@ -0,0 +1,33 @@
1
+ # TransferZero::PayoutMethodDetailsBRLBank
2
+
3
+ ## Properties
4
+
5
+ Name | Type | Description | Notes
6
+ ------------ | ------------- | ------------- | -------------
7
+ **first_name** | **String** | |
8
+ **last_name** | **String** | |
9
+ **bank_code** | **String** | |
10
+ **branch_code** | **String** | |
11
+ **bank_account** | **String** | |
12
+ **bank_account_type** | [**PayoutMethodBankAccountTypeEnum**](PayoutMethodBankAccountTypeEnum.md) | |
13
+ **identity_card_type** | [**PayoutMethodIdentityCardTypeEnum**](PayoutMethodIdentityCardTypeEnum.md) | |
14
+ **identity_card_id** | **String** | |
15
+ **transfer_reason** | [**PayoutMethodTransferReasonEnum**](PayoutMethodTransferReasonEnum.md) | |
16
+
17
+ ## Code Sample
18
+
19
+ ```ruby
20
+ require 'TransferZero'
21
+
22
+ instance = TransferZero::PayoutMethodDetailsBRLBank.new(first_name: null,
23
+ last_name: null,
24
+ bank_code: null,
25
+ branch_code: null,
26
+ bank_account: null,
27
+ bank_account_type: null,
28
+ identity_card_type: null,
29
+ identity_card_id: null,
30
+ transfer_reason: null)
31
+ ```
32
+
33
+
@@ -36,7 +36,7 @@ module TransferZero
36
36
  # @option config [Configuration] Configuration for initializing the object, default to Configuration.default
37
37
  def initialize(config = Configuration.default)
38
38
  @config = config
39
- @user_agent = "TransferZero-SDK/Ruby/1.22.0"
39
+ @user_agent = "TransferZero-SDK/Ruby/1.23.0"
40
40
  @default_headers = {
41
41
  'Content-Type' => 'application/json',
42
42
  'User-Agent' => @user_agent
@@ -13,7 +13,7 @@ OpenAPI Generator version: 4.0.0-beta3
13
13
  require 'date'
14
14
 
15
15
  module TransferZero
16
- # Fields needed by the payment processor. Depends on the chose payin type. See the appropriate model details for more info: - `NGN::Bank`: see [`PayinMethodDetailsNGNBank`](#model-PayinMethodDetailsNGNBank) - `GHS::Mobile`: see [`PayinMethodDetailsMobile`](#model-PayinMethodDetailsMobile) - `UGX::Mobile`: see [`PayinMethodDetailsMobile`](#model-PayinMethodDetailsMobile) - `TZS::Mobile`: see [`PayinMethodDetailsMobile`](#model-PayinMethodDetailsMobile) Note that some payin processors don't require additional input, these include `paga` through `NGN::Mobile`, `lhv` through `EUR::Bank` and `GBP::Bank`. Some providers like `providus` also have all of their fields set as optional, so you might not want to set any values. To use these providers please set this value to `{}` (an empty hash)
16
+ # Fields needed by the payment processor. Depends on the chose payin type. See the appropriate model details for more info: - `NGN::Bank`: see [`PayinMethodDetailsNGNBank`](#model-PayinMethodDetailsNGNBank) - `GHS::Mobile`: see [`PayinMethodDetailsMobile`](#model-PayinMethodDetailsMobile) - `UGX::Mobile`: see [`PayinMethodDetailsMobile`](#model-PayinMethodDetailsMobile) Note that some payin processors don't require additional input, these include `lhv` through `EUR::Bank` and `GBP::Bank`. Some providers like `providus` also have all of their fields set as optional, so you might not want to set any values. To use these providers please set this value to `{}` (an empty hash)
17
17
  class PayinMethodDetails
18
18
  # The payment method which the sender will use to make the payments. Options are `bank`, `card` or you can leave empty to support both.
19
19
  attr_accessor :payment_method
@@ -15,7 +15,7 @@ require 'date'
15
15
  module TransferZero
16
16
  # This describes the specific details on how the payment has to be routed to the recipient.
17
17
  class PayoutMethod
18
- # Contains the currency to send the money to, and the type of the money movement Commonly used payout types are: - `NGN::Bank` - for Nigerian bank account payments. - `NGN::Mobile` - for Nigerian mobile money payments. - `GHS::Bank` - for Ghanaian bank account payments. - `GHS::Mobile` - for Ghanaian mobile money payments. - `GHS::Cash` - for Ghanaian cash remittance payments. - `UGX::Mobile` - for Ugandan mobile money payments. - `TZS::Mobile` - for Tanzanian mobile money payments. - `XOF::Mobile` - for mobile money payments to West-Africa. - `XOF::Bank` - for Senegalese bank account payments. - `XOF::Cash` - for Senegalese cash remittance payments. - `MAD::Cash` - for Moroccan cash remittance payments. - `EUR::Bank` - for IBAN bank transfers in EUR. - `GBP::Bank` - for IBAN bank and FP accounts transfers in GBP. - `ZAR::Bank` - for South Africa bank account payments. - `USD::Bank` - for USD account payments. *** Currently Nigeria only and in Beta phase *** - `USD::Cash` - for USD cash remittance payments. *** Currently Nigeria only and in Beta phase *** - `KES::Bank` - for Kenyan bank account payments. - `KES::Mobile` - for Kenyan mobile money payments. - `XAF::Mobile` - for mobile money payments to Cameroon. - `XAF::Bank` - for Cameroon bank account payments.. - `GNF::Mobile` - for mobile money payments to Guinea. You can also send funds to the internal balance using `CCY::Balance`, where `CCY` is the appropriate currency. See [Collection from senders](https://docs.transferzero.com/docs/additional-features/#collections-from-senders) for more info on how to collect money into internal balance
18
+ # Contains the currency to send the money to, and the type of the money movement Commonly used payout types are: - `NGN::Bank` - for Nigerian bank account payments. - `GHS::Bank` - for Ghanaian bank account payments. - `GHS::Mobile` - for Ghanaian mobile money payments. - `GHS::Cash` - for Ghanaian cash remittance payments. - `UGX::Mobile` - for Ugandan mobile money payments. - `XOF::Mobile` - for mobile money payments to West-Africa. - `XOF::Bank` - for Senegalese bank account payments. - `XOF::Cash` - for Senegalese cash remittance payments. - `MAD::Cash` - for Moroccan cash remittance payments. - `EUR::Bank` - for IBAN bank transfers in EUR. - `GBP::Bank` - for IBAN bank and FP accounts transfers in GBP. - `ZAR::Bank` - for South Africa bank account payments. - `USD::Bank` - for USD account payments. *** Currently Nigeria only and in Beta phase *** - `USD::Cash` - for USD cash remittance payments. *** Currently Nigeria only and in Beta phase *** - `KES::Bank` - for Kenyan bank account payments. - `KES::Mobile` - for Kenyan mobile money payments. - `XAF::Mobile` - for mobile money payments to Cameroon. - `XAF::Bank` - for Cameroon bank account payments.. - `GNF::Mobile` - for mobile money payments to Guinea. - `BRL::Bank` - for Brazilian bank account payments. You can also send funds to the internal balance using `CCY::Balance`, where `CCY` is the appropriate currency. See [Collection from senders](https://docs.transferzero.com/docs/additional-features/#collections-from-senders) for more info on how to collect money into internal balance
19
19
  attr_accessor :type
20
20
 
21
21
  attr_accessor :details
@@ -181,6 +181,7 @@ class PayoutMethodDetails
181
181
  # List of class defined in oneOf (OpenAPI v3)
182
182
  def self.openapi_one_of
183
183
  [
184
+ :'PayoutMethodDetailsBRLBank',
184
185
  :'PayoutMethodDetailsBTC',
185
186
  :'PayoutMethodDetailsBalance',
186
187
  :'PayoutMethodDetailsGBPBank',
@@ -392,6 +393,10 @@ class PayoutMethodDetails
392
393
  invalid_properties.push('invalid value for "bank_account", bank_account cannot be nil.')
393
394
  end
394
395
 
396
+ if @bank_account_type.nil?
397
+ invalid_properties.push('invalid value for "bank_account_type", bank_account_type cannot be nil.')
398
+ end
399
+
395
400
  if @phone_number.nil?
396
401
  invalid_properties.push('invalid value for "phone_number", phone_number cannot be nil.')
397
402
  end
@@ -404,6 +409,10 @@ class PayoutMethodDetails
404
409
  invalid_properties.push('invalid value for "country", country cannot be nil.')
405
410
  end
406
411
 
412
+ if @transfer_reason.nil?
413
+ invalid_properties.push('invalid value for "transfer_reason", transfer_reason cannot be nil.')
414
+ end
415
+
407
416
  if @iban.nil?
408
417
  invalid_properties.push('invalid value for "iban", iban cannot be nil.')
409
418
  end
@@ -452,6 +461,10 @@ class PayoutMethodDetails
452
461
  invalid_properties.push('invalid value for "city", city cannot be nil.')
453
462
  end
454
463
 
464
+ if @branch_code.nil?
465
+ invalid_properties.push('invalid value for "branch_code", branch_code cannot be nil.')
466
+ end
467
+
455
468
  if @swift_code.nil?
456
469
  invalid_properties.push('invalid value for "swift_code", swift_code cannot be nil.')
457
470
  end
@@ -466,9 +479,11 @@ class PayoutMethodDetails
466
479
  return false if @last_name.nil?
467
480
  return false if @bank_code.nil?
468
481
  return false if @bank_account.nil?
482
+ return false if @bank_account_type.nil?
469
483
  return false if @phone_number.nil?
470
484
  return false if @mobile_provider.nil?
471
485
  return false if @country.nil?
486
+ return false if @transfer_reason.nil?
472
487
  return false if @iban.nil?
473
488
  return false if @bank_name.nil?
474
489
  return false if @cash_provider.nil?
@@ -481,6 +496,7 @@ class PayoutMethodDetails
481
496
  return false if @street.nil?
482
497
  return false if @postal_code.nil?
483
498
  return false if @city.nil?
499
+ return false if @branch_code.nil?
484
500
  return false if @swift_code.nil?
485
501
  _one_of_found = false
486
502
  openapi_one_of.each do |_class|
@@ -0,0 +1,320 @@
1
+ =begin
2
+ #TransferZero API
3
+
4
+ #Reference documentation for the TransferZero API V1
5
+
6
+ OpenAPI spec version: 1.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 4.0.0-beta3
10
+
11
+ =end
12
+
13
+ require 'date'
14
+
15
+ module TransferZero
16
+ # ```JSON \"details\": { \"first_name\": \"First\", \"last_name\": \"Last\", \"bank_code\": \"104\", \"branch_code\": \"00001\", \"bank_account\": \"0009795493\", \"bank_account_type\": \"10\", \"identity_card_type\": \"ID\", \"identity_card_id\": \"01234567890\", \"transfer_reason\": \"personal_account\" } ``` See [BRL Bank](https://docs.transferzero.com/docs/payout-details/#brlbank) documentation for the bank_code and transfer_reason lists
17
+ class PayoutMethodDetailsBRLBank
18
+ attr_accessor :first_name
19
+
20
+ attr_accessor :last_name
21
+
22
+ attr_accessor :bank_code
23
+
24
+ attr_accessor :branch_code
25
+
26
+ attr_accessor :bank_account
27
+
28
+ attr_accessor :bank_account_type
29
+
30
+ attr_accessor :identity_card_type
31
+
32
+ attr_accessor :identity_card_id
33
+
34
+ attr_accessor :transfer_reason
35
+
36
+ # Attribute mapping from ruby-style variable name to JSON key.
37
+ def self.attribute_map
38
+ {
39
+ :'first_name' => :'first_name',
40
+ :'last_name' => :'last_name',
41
+ :'bank_code' => :'bank_code',
42
+ :'branch_code' => :'branch_code',
43
+ :'bank_account' => :'bank_account',
44
+ :'bank_account_type' => :'bank_account_type',
45
+ :'identity_card_type' => :'identity_card_type',
46
+ :'identity_card_id' => :'identity_card_id',
47
+ :'transfer_reason' => :'transfer_reason'
48
+ }
49
+ end
50
+
51
+ # Attribute type mapping.
52
+ def self.openapi_types
53
+ {
54
+ :'first_name' => :'String',
55
+ :'last_name' => :'String',
56
+ :'bank_code' => :'String',
57
+ :'branch_code' => :'String',
58
+ :'bank_account' => :'String',
59
+ :'bank_account_type' => :'PayoutMethodBankAccountTypeEnum',
60
+ :'identity_card_type' => :'PayoutMethodIdentityCardTypeEnum',
61
+ :'identity_card_id' => :'String',
62
+ :'transfer_reason' => :'PayoutMethodTransferReasonEnum'
63
+ }
64
+ end
65
+
66
+ # Initializes the object
67
+ # @param [Hash] attributes Model attributes in the form of hash
68
+ def initialize(attributes = {})
69
+ if (!attributes.is_a?(Hash))
70
+ fail ArgumentError, "The input argument (attributes) must be a hash in `TransferZero::PayoutMethodDetailsBRLBank` initialize method"
71
+ end
72
+
73
+ # check to see if the attribute exists and convert string to symbol for hash key
74
+ attributes = attributes.each_with_object({}) { |(k, v), h|
75
+ if (!self.class.attribute_map.key?(k.to_sym))
76
+ fail ArgumentError, "`#{k}` is not a valid attribute in `TransferZero::PayoutMethodDetailsBRLBank`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
77
+ end
78
+ h[k.to_sym] = v
79
+ }
80
+
81
+ if attributes.key?(:'first_name')
82
+ self.first_name = attributes[:'first_name']
83
+ end
84
+
85
+ if attributes.key?(:'last_name')
86
+ self.last_name = attributes[:'last_name']
87
+ end
88
+
89
+ if attributes.key?(:'bank_code')
90
+ self.bank_code = attributes[:'bank_code']
91
+ end
92
+
93
+ if attributes.key?(:'branch_code')
94
+ self.branch_code = attributes[:'branch_code']
95
+ end
96
+
97
+ if attributes.key?(:'bank_account')
98
+ self.bank_account = attributes[:'bank_account']
99
+ end
100
+
101
+ if attributes.key?(:'bank_account_type')
102
+ self.bank_account_type = attributes[:'bank_account_type']
103
+ end
104
+
105
+ if attributes.key?(:'identity_card_type')
106
+ self.identity_card_type = attributes[:'identity_card_type']
107
+ end
108
+
109
+ if attributes.key?(:'identity_card_id')
110
+ self.identity_card_id = attributes[:'identity_card_id']
111
+ end
112
+
113
+ if attributes.key?(:'transfer_reason')
114
+ self.transfer_reason = attributes[:'transfer_reason']
115
+ end
116
+ end
117
+
118
+ # Show invalid properties with the reasons. Usually used together with valid?
119
+ # @return Array for valid properties with the reasons
120
+ def list_invalid_properties
121
+ invalid_properties = Array.new
122
+ if @first_name.nil?
123
+ invalid_properties.push('invalid value for "first_name", first_name cannot be nil.')
124
+ end
125
+
126
+ if @last_name.nil?
127
+ invalid_properties.push('invalid value for "last_name", last_name cannot be nil.')
128
+ end
129
+
130
+ if @bank_code.nil?
131
+ invalid_properties.push('invalid value for "bank_code", bank_code cannot be nil.')
132
+ end
133
+
134
+ if @branch_code.nil?
135
+ invalid_properties.push('invalid value for "branch_code", branch_code cannot be nil.')
136
+ end
137
+
138
+ if @bank_account.nil?
139
+ invalid_properties.push('invalid value for "bank_account", bank_account cannot be nil.')
140
+ end
141
+
142
+ if @bank_account_type.nil?
143
+ invalid_properties.push('invalid value for "bank_account_type", bank_account_type cannot be nil.')
144
+ end
145
+
146
+ if @identity_card_type.nil?
147
+ invalid_properties.push('invalid value for "identity_card_type", identity_card_type cannot be nil.')
148
+ end
149
+
150
+ if @identity_card_id.nil?
151
+ invalid_properties.push('invalid value for "identity_card_id", identity_card_id cannot be nil.')
152
+ end
153
+
154
+ if @transfer_reason.nil?
155
+ invalid_properties.push('invalid value for "transfer_reason", transfer_reason cannot be nil.')
156
+ end
157
+
158
+ invalid_properties
159
+ end
160
+
161
+ # Check to see if the all the properties in the model are valid
162
+ # @return true if the model is valid
163
+ def valid?
164
+ return false if @first_name.nil?
165
+ return false if @last_name.nil?
166
+ return false if @bank_code.nil?
167
+ return false if @branch_code.nil?
168
+ return false if @bank_account.nil?
169
+ return false if @bank_account_type.nil?
170
+ return false if @identity_card_type.nil?
171
+ return false if @identity_card_id.nil?
172
+ return false if @transfer_reason.nil?
173
+ true
174
+ end
175
+
176
+ # Checks equality by comparing each attribute.
177
+ # @param [Object] Object to be compared
178
+ def ==(o)
179
+ return true if self.equal?(o)
180
+ self.class == o.class &&
181
+ first_name == o.first_name &&
182
+ last_name == o.last_name &&
183
+ bank_code == o.bank_code &&
184
+ branch_code == o.branch_code &&
185
+ bank_account == o.bank_account &&
186
+ bank_account_type == o.bank_account_type &&
187
+ identity_card_type == o.identity_card_type &&
188
+ identity_card_id == o.identity_card_id &&
189
+ transfer_reason == o.transfer_reason
190
+ end
191
+
192
+ # @see the `==` method
193
+ # @param [Object] Object to be compared
194
+ def eql?(o)
195
+ self == o
196
+ end
197
+
198
+ # Calculates hash code according to all attributes.
199
+ # @return [Integer] Hash code
200
+ def hash
201
+ [first_name, last_name, bank_code, branch_code, bank_account, bank_account_type, identity_card_type, identity_card_id, transfer_reason].hash
202
+ end
203
+
204
+ require 'active_support/core_ext/hash'
205
+ require 'active_support/hash_with_indifferent_access.rb'
206
+ # Builds the object from hash
207
+ # @param [Hash] attributes Model attributes in the form of hash
208
+ # @return [Object] Returns the model itself
209
+ def build_from_hash(attributes)
210
+ return nil unless attributes.is_a?(Hash)
211
+ self.class.openapi_types.each_pair do |key, type|
212
+ if type =~ /\AArray<(.*)>/i
213
+ # check to ensure the input is an array given that the the attribute
214
+ # is documented as an array but the input is not
215
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
216
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
217
+ end
218
+ elsif !attributes[self.class.attribute_map[key]].nil?
219
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
220
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
221
+ end
222
+
223
+ self
224
+ end
225
+
226
+ # Deserializes the data based on type
227
+ # @param string type Data type
228
+ # @param string value Value to be deserialized
229
+ # @return [Object] Deserialized data
230
+ def _deserialize(type, value)
231
+ case type.to_sym
232
+ when :DateTime
233
+ DateTime.parse(value)
234
+ when :Date
235
+ Date.parse(value)
236
+ when :String
237
+ value.to_s
238
+ when :Integer
239
+ value.to_i
240
+ when :Float
241
+ value.to_f
242
+ when :Boolean
243
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
244
+ true
245
+ else
246
+ false
247
+ end
248
+ when :Object
249
+ # generic object (usually a Hash), return directly
250
+ value
251
+ when /\AArray<(?<inner_type>.+)>\z/
252
+ inner_type = Regexp.last_match[:inner_type]
253
+ value.map { |v| _deserialize(inner_type, v) }
254
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
255
+ k_type = Regexp.last_match[:k_type]
256
+ v_type = Regexp.last_match[:v_type]
257
+ {}.tap do |hash|
258
+ value.each do |k, v|
259
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
260
+ end
261
+ end
262
+ else # model
263
+ temp_model = TransferZero.const_get(type).new
264
+ temp_model.build_from_hash(value)
265
+ end
266
+ end
267
+
268
+ # Returns the string representation of the object
269
+ # @return [String] String presentation of the object
270
+ def to_s
271
+ to_hash.to_s
272
+ end
273
+
274
+ # to_body is an alias to to_hash (backward compatibility)
275
+ # @return [Hash] Returns the object in the form of hash
276
+ def to_body
277
+ to_hash
278
+ end
279
+
280
+ # Returns the object in the form of hash
281
+ # @return [Hash] Returns the object in the form of hash
282
+ def to_hash
283
+ hash = {}
284
+ self.class.attribute_map.each_pair do |attr, param|
285
+ value = self.send(attr)
286
+ next if value.nil?
287
+ hash[param] = _to_hash(value)
288
+ end
289
+ ::ActiveSupport::HashWithIndifferentAccess.new(hash)
290
+ end
291
+
292
+ def [](key)
293
+ to_hash[key]
294
+ end
295
+
296
+ def dig(*args)
297
+ to_hash.dig(*args)
298
+ end
299
+
300
+ # Outputs non-array value in the form of hash
301
+ # For object, use to_hash. Otherwise, just return the value
302
+ # @param [Object] value Any valid value
303
+ # @return [Hash] Returns the value in the form of hash
304
+ def _to_hash(value)
305
+ if value.is_a?(Array)
306
+ value.compact.map { |v| _to_hash(v) }
307
+ elsif value.is_a?(Hash)
308
+ {}.tap do |hash|
309
+ value.each { |k, v| hash[k] = _to_hash(v) }
310
+ end
311
+ elsif value.respond_to? :to_hash
312
+ value.to_hash
313
+ else
314
+ value
315
+ end
316
+ end
317
+
318
+ end
319
+
320
+ end
@@ -11,5 +11,5 @@ OpenAPI Generator version: 4.0.0-beta3
11
11
  =end
12
12
 
13
13
  module TransferZero
14
- VERSION = '1.22.0'
14
+ VERSION = '1.23.0'
15
15
  end
@@ -67,6 +67,7 @@ require 'transferzero-sdk/models/payout_method_bank_account_type_enum'
67
67
  require 'transferzero-sdk/models/payout_method_cash_provider_enum'
68
68
  require 'transferzero-sdk/models/payout_method_country_enum'
69
69
  require 'transferzero-sdk/models/payout_method_details'
70
+ require 'transferzero-sdk/models/payout_method_details_brl_bank'
70
71
  require 'transferzero-sdk/models/payout_method_details_btc'
71
72
  require 'transferzero-sdk/models/payout_method_details_balance'
72
73
  require 'transferzero-sdk/models/payout_method_details_gbp_bank'
@@ -0,0 +1,89 @@
1
+ =begin
2
+ #TransferZero API
3
+
4
+ #Reference documentation for the TransferZero API V1
5
+
6
+ OpenAPI spec version: 1.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 4.0.0-beta3
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+ require 'date'
16
+
17
+ # Unit tests for TransferZero::PayoutMethodDetailsBRLBank
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe 'PayoutMethodDetailsBRLBank' do
21
+ before do
22
+ # run before each test
23
+ @instance = TransferZero::PayoutMethodDetailsBRLBank.new
24
+ end
25
+
26
+ after do
27
+ # run after each test
28
+ end
29
+
30
+ describe 'test an instance of PayoutMethodDetailsBRLBank' do
31
+ it 'should create an instance of PayoutMethodDetailsBRLBank' do
32
+ expect(@instance).to be_instance_of(TransferZero::PayoutMethodDetailsBRLBank)
33
+ end
34
+ end
35
+ describe 'test attribute "first_name"' do
36
+ it 'should work' do
37
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
38
+ end
39
+ end
40
+
41
+ describe 'test attribute "last_name"' do
42
+ it 'should work' do
43
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
44
+ end
45
+ end
46
+
47
+ describe 'test attribute "bank_code"' do
48
+ it 'should work' do
49
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
50
+ end
51
+ end
52
+
53
+ describe 'test attribute "branch_code"' do
54
+ it 'should work' do
55
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
56
+ end
57
+ end
58
+
59
+ describe 'test attribute "bank_account"' do
60
+ it 'should work' do
61
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
62
+ end
63
+ end
64
+
65
+ describe 'test attribute "bank_account_type"' do
66
+ it 'should work' do
67
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
68
+ end
69
+ end
70
+
71
+ describe 'test attribute "identity_card_type"' do
72
+ it 'should work' do
73
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
74
+ end
75
+ end
76
+
77
+ describe 'test attribute "identity_card_id"' do
78
+ it 'should work' do
79
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
80
+ end
81
+ end
82
+
83
+ describe 'test attribute "transfer_reason"' do
84
+ it 'should work' do
85
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
86
+ end
87
+ end
88
+
89
+ end
Binary file
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: transferzero-sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.22.0
4
+ version: 1.23.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - TransferZero
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-08-30 00:00:00.000000000 Z
11
+ date: 2022-10-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -155,6 +155,7 @@ files:
155
155
  - docs/PayoutMethodCashProviderEnum.md
156
156
  - docs/PayoutMethodCountryEnum.md
157
157
  - docs/PayoutMethodDetails.md
158
+ - docs/PayoutMethodDetailsBRLBank.md
158
159
  - docs/PayoutMethodDetailsBTC.md
159
160
  - docs/PayoutMethodDetailsBalance.md
160
161
  - docs/PayoutMethodDetailsGBPBank.md
@@ -302,6 +303,7 @@ files:
302
303
  - lib/transferzero-sdk/models/payout_method_country_enum.rb
303
304
  - lib/transferzero-sdk/models/payout_method_details.rb
304
305
  - lib/transferzero-sdk/models/payout_method_details_balance.rb
306
+ - lib/transferzero-sdk/models/payout_method_details_brl_bank.rb
305
307
  - lib/transferzero-sdk/models/payout_method_details_btc.rb
306
308
  - lib/transferzero-sdk/models/payout_method_details_gbp_bank.rb
307
309
  - lib/transferzero-sdk/models/payout_method_details_ghs_bank.rb
@@ -437,6 +439,7 @@ files:
437
439
  - spec/models/payout_method_cash_provider_enum_spec.rb
438
440
  - spec/models/payout_method_country_enum_spec.rb
439
441
  - spec/models/payout_method_details_balance_spec.rb
442
+ - spec/models/payout_method_details_brl_bank_spec.rb
440
443
  - spec/models/payout_method_details_btc_spec.rb
441
444
  - spec/models/payout_method_details_gbp_bank_spec.rb
442
445
  - spec/models/payout_method_details_ghs_bank_spec.rb
@@ -517,6 +520,7 @@ files:
517
520
  - transferzero-sdk-1.19.5.gem
518
521
  - transferzero-sdk-1.20.1.gem
519
522
  - transferzero-sdk-1.21.0.gem
523
+ - transferzero-sdk-1.22.0.gem
520
524
  - transferzero-sdk.gemspec
521
525
  homepage: https://github.com/transferzero/transferzero-sdk-ruby
522
526
  licenses:
@@ -604,6 +608,7 @@ test_files:
604
608
  - spec/models/payin_method_state_spec.rb
605
609
  - spec/models/document_response_spec.rb
606
610
  - spec/models/currency_exchange_list_response_spec.rb
611
+ - spec/models/payout_method_details_brl_bank_spec.rb
607
612
  - spec/models/validation_error_description_spec.rb
608
613
  - spec/models/payin_method_request_spec.rb
609
614
  - spec/models/proof_of_payment_list_response_spec.rb