tesser-api-sdk 1.0.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.
- checksums.yaml +7 -0
- data/LICENSE +28 -0
- data/README.md +148 -0
- data/bin/console +15 -0
- data/lib/tesser_apiv1/api_helper.rb +10 -0
- data/lib/tesser_apiv1/client.rb +118 -0
- data/lib/tesser_apiv1/configuration.rb +182 -0
- data/lib/tesser_apiv1/controllers/accounts_controller.rb +193 -0
- data/lib/tesser_apiv1/controllers/base_controller.rb +60 -0
- data/lib/tesser_apiv1/controllers/counterparties_controller.rb +171 -0
- data/lib/tesser_apiv1/controllers/currencies_controller.rb +39 -0
- data/lib/tesser_apiv1/controllers/experimental_controller.rb +49 -0
- data/lib/tesser_apiv1/controllers/health_controller.rb +24 -0
- data/lib/tesser_apiv1/controllers/networks_controller.rb +39 -0
- data/lib/tesser_apiv1/controllers/payments_controller.rb +202 -0
- data/lib/tesser_apiv1/controllers/tenants_controller.rb +156 -0
- data/lib/tesser_apiv1/controllers/treasury_controller.rb +77 -0
- data/lib/tesser_apiv1/exceptions/api_exception.rb +21 -0
- data/lib/tesser_apiv1/http/auth/o_auth2.rb +53 -0
- data/lib/tesser_apiv1/http/http_call_back.rb +10 -0
- data/lib/tesser_apiv1/http/http_method_enum.rb +10 -0
- data/lib/tesser_apiv1/http/http_request.rb +10 -0
- data/lib/tesser_apiv1/http/http_response.rb +10 -0
- data/lib/tesser_apiv1/http/proxy_settings.rb +22 -0
- data/lib/tesser_apiv1/models/account.rb +230 -0
- data/lib/tesser_apiv1/models/account_list_item.rb +230 -0
- data/lib/tesser_apiv1/models/account_list_response.rb +69 -0
- data/lib/tesser_apiv1/models/account_response.rb +60 -0
- data/lib/tesser_apiv1/models/account_safe.rb +218 -0
- data/lib/tesser_apiv1/models/balance_status1_enum.rb +40 -0
- data/lib/tesser_apiv1/models/balance_status_enum.rb +40 -0
- data/lib/tesser_apiv1/models/base_model.rb +110 -0
- data/lib/tesser_apiv1/models/classification7_enum.rb +36 -0
- data/lib/tesser_apiv1/models/classification_enum.rb +36 -0
- data/lib/tesser_apiv1/models/counterparty.rb +411 -0
- data/lib/tesser_apiv1/models/counterparty_list_response.rb +69 -0
- data/lib/tesser_apiv1/models/counterparty_response.rb +60 -0
- data/lib/tesser_apiv1/models/create_bank_request.rb +122 -0
- data/lib/tesser_apiv1/models/create_bank_response.rb +60 -0
- data/lib/tesser_apiv1/models/create_counterparty_request.rb +350 -0
- data/lib/tesser_apiv1/models/create_counterparty_response.rb +60 -0
- data/lib/tesser_apiv1/models/create_deposit_request.rb +119 -0
- data/lib/tesser_apiv1/models/create_payment_request.rb +168 -0
- data/lib/tesser_apiv1/models/create_tenant_request.rb +183 -0
- data/lib/tesser_apiv1/models/create_tenant_response.rb +60 -0
- data/lib/tesser_apiv1/models/create_wallet_request.rb +112 -0
- data/lib/tesser_apiv1/models/create_wallet_response.rb +60 -0
- data/lib/tesser_apiv1/models/create_withdrawal_request.rb +130 -0
- data/lib/tesser_apiv1/models/currencies_response.rb +69 -0
- data/lib/tesser_apiv1/models/currency.rb +119 -0
- data/lib/tesser_apiv1/models/data.rb +221 -0
- data/lib/tesser_apiv1/models/data6.rb +242 -0
- data/lib/tesser_apiv1/models/data7.rb +419 -0
- data/lib/tesser_apiv1/models/data8.rb +200 -0
- data/lib/tesser_apiv1/models/direction1_enum.rb +40 -0
- data/lib/tesser_apiv1/models/direction_enum.rb +40 -0
- data/lib/tesser_apiv1/models/execute_payment_request_dto.rb +71 -0
- data/lib/tesser_apiv1/models/fee.rb +117 -0
- data/lib/tesser_apiv1/models/fee1.rb +117 -0
- data/lib/tesser_apiv1/models/network.rb +68 -0
- data/lib/tesser_apiv1/models/networks_response.rb +69 -0
- data/lib/tesser_apiv1/models/pagination.rb +104 -0
- data/lib/tesser_apiv1/models/payment.rb +421 -0
- data/lib/tesser_apiv1/models/payment_list_response.rb +79 -0
- data/lib/tesser_apiv1/models/payment_response.rb +60 -0
- data/lib/tesser_apiv1/models/payment_type3_enum.rb +52 -0
- data/lib/tesser_apiv1/models/payment_type_enum.rb +54 -0
- data/lib/tesser_apiv1/models/provider_key1_enum.rb +36 -0
- data/lib/tesser_apiv1/models/provider_key_enum.rb +36 -0
- data/lib/tesser_apiv1/models/response.rb +81 -0
- data/lib/tesser_apiv1/models/review_payment_request.rb +60 -0
- data/lib/tesser_apiv1/models/risk_status_enum.rb +44 -0
- data/lib/tesser_apiv1/models/status1_enum.rb +52 -0
- data/lib/tesser_apiv1/models/status_enum.rb +48 -0
- data/lib/tesser_apiv1/models/step.rb +421 -0
- data/lib/tesser_apiv1/models/step_type_enum.rb +44 -0
- data/lib/tesser_apiv1/models/tenant.rb +275 -0
- data/lib/tesser_apiv1/models/tenant_api_credentials.rb +88 -0
- data/lib/tesser_apiv1/models/tenant_list_response.rb +69 -0
- data/lib/tesser_apiv1/models/tenant_response.rb +60 -0
- data/lib/tesser_apiv1/models/transfer_step.rb +422 -0
- data/lib/tesser_apiv1/models/turnkey_stamp.rb +81 -0
- data/lib/tesser_apiv1/models/type3_enum.rb +40 -0
- data/lib/tesser_apiv1/models/type4_enum.rb +44 -0
- data/lib/tesser_apiv1/models/type_enum.rb +44 -0
- data/lib/tesser_apiv1/models/update_account_request.rb +62 -0
- data/lib/tesser_apiv1/models/update_account_response.rb +60 -0
- data/lib/tesser_apiv1/models/update_counterparty_request.rb +166 -0
- data/lib/tesser_apiv1/models/update_counterparty_response.rb +60 -0
- data/lib/tesser_apiv1/models/update_payment_request.rb +100 -0
- data/lib/tesser_apiv1/models/update_tenant_request.rb +111 -0
- data/lib/tesser_apiv1/models/update_tenant_response.rb +60 -0
- data/lib/tesser_apiv1/utilities/date_time_helper.rb +11 -0
- data/lib/tesser_apiv1/utilities/file_wrapper.rb +28 -0
- data/lib/tesser_apiv1/utilities/union_type_lookup.rb +1234 -0
- data/lib/tesser_apiv1.rb +116 -0
- data/test/controllers/controller_test_base.rb +23 -0
- data/test/controllers/test_health_controller.rb +31 -0
- data/test/controllers/test_tenants_controller.rb +133 -0
- data/test/http_response_catcher.rb +19 -0
- metadata +212 -0
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
# tesser_apiv1
|
|
2
|
+
#
|
|
3
|
+
# This file was automatically generated by APIMATIC v3.0 (
|
|
4
|
+
# https://www.apimatic.io ).
|
|
5
|
+
|
|
6
|
+
module TesserApiv1
|
|
7
|
+
# CreatePaymentRequest Model.
|
|
8
|
+
class CreatePaymentRequest < BaseModel
|
|
9
|
+
SKIP = Object.new
|
|
10
|
+
private_constant :SKIP
|
|
11
|
+
|
|
12
|
+
# Source currency code (e.g., 'USDC'). See GET /currencies for supported
|
|
13
|
+
# values.
|
|
14
|
+
# @return [String]
|
|
15
|
+
attr_accessor :from_currency
|
|
16
|
+
|
|
17
|
+
# Destination currency code (e.g., 'USD'). See GET /currencies for supported
|
|
18
|
+
# values.
|
|
19
|
+
# @return [String]
|
|
20
|
+
attr_accessor :to_currency
|
|
21
|
+
|
|
22
|
+
# Amount to send in source currency units. Required if to_amount is not
|
|
23
|
+
# provided.
|
|
24
|
+
# @return [String]
|
|
25
|
+
attr_accessor :from_amount
|
|
26
|
+
|
|
27
|
+
# Amount to receive in destination currency units. Required if from_amount
|
|
28
|
+
# is not provided.
|
|
29
|
+
# @return [String]
|
|
30
|
+
attr_accessor :to_amount
|
|
31
|
+
|
|
32
|
+
# Blockchain network for source currency (e.g., 'POLYGON'). See GET
|
|
33
|
+
# /networks for supported values.
|
|
34
|
+
# @return [String]
|
|
35
|
+
attr_accessor :from_network
|
|
36
|
+
|
|
37
|
+
# Blockchain network for destination currency (if applicable). See GET
|
|
38
|
+
# /networks for supported values.
|
|
39
|
+
# @return [String]
|
|
40
|
+
attr_accessor :to_network
|
|
41
|
+
|
|
42
|
+
# Optional external reference ID for the organization.
|
|
43
|
+
# @return [String]
|
|
44
|
+
attr_accessor :organization_reference_id
|
|
45
|
+
|
|
46
|
+
# ID of the account originating the payment.
|
|
47
|
+
# @return [String]
|
|
48
|
+
attr_accessor :originator_account_id
|
|
49
|
+
|
|
50
|
+
# ID of the source account (e.g., wallet).
|
|
51
|
+
# @return [String]
|
|
52
|
+
attr_accessor :source_account_id
|
|
53
|
+
|
|
54
|
+
# ID of the beneficiary account.
|
|
55
|
+
# @return [String]
|
|
56
|
+
attr_accessor :beneficiary_account_id
|
|
57
|
+
|
|
58
|
+
# A mapping from model property names to API property names.
|
|
59
|
+
def self.names
|
|
60
|
+
@_hash = {} if @_hash.nil?
|
|
61
|
+
@_hash['from_currency'] = 'from_currency'
|
|
62
|
+
@_hash['to_currency'] = 'to_currency'
|
|
63
|
+
@_hash['from_amount'] = 'from_amount'
|
|
64
|
+
@_hash['to_amount'] = 'to_amount'
|
|
65
|
+
@_hash['from_network'] = 'from_network'
|
|
66
|
+
@_hash['to_network'] = 'to_network'
|
|
67
|
+
@_hash['organization_reference_id'] = 'organization_reference_id'
|
|
68
|
+
@_hash['originator_account_id'] = 'originator_account_id'
|
|
69
|
+
@_hash['source_account_id'] = 'source_account_id'
|
|
70
|
+
@_hash['beneficiary_account_id'] = 'beneficiary_account_id'
|
|
71
|
+
@_hash
|
|
72
|
+
end
|
|
73
|
+
|
|
74
|
+
# An array for optional fields
|
|
75
|
+
def self.optionals
|
|
76
|
+
%w[
|
|
77
|
+
from_amount
|
|
78
|
+
to_amount
|
|
79
|
+
from_network
|
|
80
|
+
to_network
|
|
81
|
+
organization_reference_id
|
|
82
|
+
originator_account_id
|
|
83
|
+
source_account_id
|
|
84
|
+
beneficiary_account_id
|
|
85
|
+
]
|
|
86
|
+
end
|
|
87
|
+
|
|
88
|
+
# An array for nullable fields
|
|
89
|
+
def self.nullables
|
|
90
|
+
[]
|
|
91
|
+
end
|
|
92
|
+
|
|
93
|
+
def initialize(from_currency = nil, to_currency = nil, from_amount = SKIP,
|
|
94
|
+
to_amount = SKIP, from_network = SKIP, to_network = SKIP,
|
|
95
|
+
organization_reference_id = SKIP,
|
|
96
|
+
originator_account_id = SKIP, source_account_id = SKIP,
|
|
97
|
+
beneficiary_account_id = SKIP)
|
|
98
|
+
@from_currency = from_currency
|
|
99
|
+
@to_currency = to_currency
|
|
100
|
+
@from_amount = from_amount unless from_amount == SKIP
|
|
101
|
+
@to_amount = to_amount unless to_amount == SKIP
|
|
102
|
+
@from_network = from_network unless from_network == SKIP
|
|
103
|
+
@to_network = to_network unless to_network == SKIP
|
|
104
|
+
unless organization_reference_id == SKIP
|
|
105
|
+
@organization_reference_id =
|
|
106
|
+
organization_reference_id
|
|
107
|
+
end
|
|
108
|
+
@originator_account_id = originator_account_id unless originator_account_id == SKIP
|
|
109
|
+
@source_account_id = source_account_id unless source_account_id == SKIP
|
|
110
|
+
@beneficiary_account_id = beneficiary_account_id unless beneficiary_account_id == SKIP
|
|
111
|
+
end
|
|
112
|
+
|
|
113
|
+
# Creates an instance of the object from a hash.
|
|
114
|
+
def self.from_hash(hash)
|
|
115
|
+
return nil unless hash
|
|
116
|
+
|
|
117
|
+
# Extract variables from the hash.
|
|
118
|
+
from_currency = hash.key?('from_currency') ? hash['from_currency'] : nil
|
|
119
|
+
to_currency = hash.key?('to_currency') ? hash['to_currency'] : nil
|
|
120
|
+
from_amount = hash.key?('from_amount') ? hash['from_amount'] : SKIP
|
|
121
|
+
to_amount = hash.key?('to_amount') ? hash['to_amount'] : SKIP
|
|
122
|
+
from_network = hash.key?('from_network') ? hash['from_network'] : SKIP
|
|
123
|
+
to_network = hash.key?('to_network') ? hash['to_network'] : SKIP
|
|
124
|
+
organization_reference_id =
|
|
125
|
+
hash.key?('organization_reference_id') ? hash['organization_reference_id'] : SKIP
|
|
126
|
+
originator_account_id =
|
|
127
|
+
hash.key?('originator_account_id') ? hash['originator_account_id'] : SKIP
|
|
128
|
+
source_account_id =
|
|
129
|
+
hash.key?('source_account_id') ? hash['source_account_id'] : SKIP
|
|
130
|
+
beneficiary_account_id =
|
|
131
|
+
hash.key?('beneficiary_account_id') ? hash['beneficiary_account_id'] : SKIP
|
|
132
|
+
|
|
133
|
+
# Create object from extracted values.
|
|
134
|
+
CreatePaymentRequest.new(from_currency,
|
|
135
|
+
to_currency,
|
|
136
|
+
from_amount,
|
|
137
|
+
to_amount,
|
|
138
|
+
from_network,
|
|
139
|
+
to_network,
|
|
140
|
+
organization_reference_id,
|
|
141
|
+
originator_account_id,
|
|
142
|
+
source_account_id,
|
|
143
|
+
beneficiary_account_id)
|
|
144
|
+
end
|
|
145
|
+
|
|
146
|
+
# Provides a human-readable string representation of the object.
|
|
147
|
+
def to_s
|
|
148
|
+
class_name = self.class.name.split('::').last
|
|
149
|
+
"<#{class_name} from_currency: #{@from_currency}, to_currency: #{@to_currency},"\
|
|
150
|
+
" from_amount: #{@from_amount}, to_amount: #{@to_amount}, from_network: #{@from_network},"\
|
|
151
|
+
" to_network: #{@to_network}, organization_reference_id: #{@organization_reference_id},"\
|
|
152
|
+
" originator_account_id: #{@originator_account_id}, source_account_id:"\
|
|
153
|
+
" #{@source_account_id}, beneficiary_account_id: #{@beneficiary_account_id}>"
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
# Provides a debugging-friendly string with detailed object information.
|
|
157
|
+
def inspect
|
|
158
|
+
class_name = self.class.name.split('::').last
|
|
159
|
+
"<#{class_name} from_currency: #{@from_currency.inspect}, to_currency:"\
|
|
160
|
+
" #{@to_currency.inspect}, from_amount: #{@from_amount.inspect}, to_amount:"\
|
|
161
|
+
" #{@to_amount.inspect}, from_network: #{@from_network.inspect}, to_network:"\
|
|
162
|
+
" #{@to_network.inspect}, organization_reference_id: #{@organization_reference_id.inspect},"\
|
|
163
|
+
" originator_account_id: #{@originator_account_id.inspect}, source_account_id:"\
|
|
164
|
+
" #{@source_account_id.inspect}, beneficiary_account_id:"\
|
|
165
|
+
" #{@beneficiary_account_id.inspect}>"
|
|
166
|
+
end
|
|
167
|
+
end
|
|
168
|
+
end
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
# tesser_apiv1
|
|
2
|
+
#
|
|
3
|
+
# This file was automatically generated by APIMATIC v3.0 (
|
|
4
|
+
# https://www.apimatic.io ).
|
|
5
|
+
|
|
6
|
+
module TesserApiv1
|
|
7
|
+
# CreateTenantRequest Model.
|
|
8
|
+
class CreateTenantRequest < BaseModel
|
|
9
|
+
SKIP = Object.new
|
|
10
|
+
private_constant :SKIP
|
|
11
|
+
|
|
12
|
+
# Legal name of the business tenant.
|
|
13
|
+
# @return [String]
|
|
14
|
+
attr_accessor :business_legal_name
|
|
15
|
+
|
|
16
|
+
# Doing Business As name (optional).
|
|
17
|
+
# @return [Object]
|
|
18
|
+
attr_accessor :business_dba
|
|
19
|
+
|
|
20
|
+
# Country code for the business address.
|
|
21
|
+
# @return [Object]
|
|
22
|
+
attr_accessor :business_address_country
|
|
23
|
+
|
|
24
|
+
# Street address line 1 (for businesses).
|
|
25
|
+
# @return [Object]
|
|
26
|
+
attr_accessor :business_street_address1
|
|
27
|
+
|
|
28
|
+
# Street address line 2 (for businesses).
|
|
29
|
+
# @return [Object]
|
|
30
|
+
attr_accessor :business_street_address2
|
|
31
|
+
|
|
32
|
+
# City (for businesses).
|
|
33
|
+
# @return [Object]
|
|
34
|
+
attr_accessor :business_city
|
|
35
|
+
|
|
36
|
+
# State/region (for businesses).
|
|
37
|
+
# @return [Object]
|
|
38
|
+
attr_accessor :business_state
|
|
39
|
+
|
|
40
|
+
# Legal Entity Identifier (for businesses).
|
|
41
|
+
# @return [Object]
|
|
42
|
+
attr_accessor :business_legal_entity_identifier
|
|
43
|
+
|
|
44
|
+
# Webhook URL that will receive events related to this tenant (optional).
|
|
45
|
+
# @return [Object]
|
|
46
|
+
attr_accessor :webhook_url
|
|
47
|
+
|
|
48
|
+
# A mapping from model property names to API property names.
|
|
49
|
+
def self.names
|
|
50
|
+
@_hash = {} if @_hash.nil?
|
|
51
|
+
@_hash['business_legal_name'] = 'business_legal_name'
|
|
52
|
+
@_hash['business_dba'] = 'business_dba'
|
|
53
|
+
@_hash['business_address_country'] = 'business_address_country'
|
|
54
|
+
@_hash['business_street_address1'] = 'business_street_address1'
|
|
55
|
+
@_hash['business_street_address2'] = 'business_street_address2'
|
|
56
|
+
@_hash['business_city'] = 'business_city'
|
|
57
|
+
@_hash['business_state'] = 'business_state'
|
|
58
|
+
@_hash['business_legal_entity_identifier'] =
|
|
59
|
+
'business_legal_entity_identifier'
|
|
60
|
+
@_hash['webhook_url'] = 'webhook_url'
|
|
61
|
+
@_hash
|
|
62
|
+
end
|
|
63
|
+
|
|
64
|
+
# An array for optional fields
|
|
65
|
+
def self.optionals
|
|
66
|
+
%w[
|
|
67
|
+
business_dba
|
|
68
|
+
business_address_country
|
|
69
|
+
business_street_address1
|
|
70
|
+
business_street_address2
|
|
71
|
+
business_city
|
|
72
|
+
business_state
|
|
73
|
+
business_legal_entity_identifier
|
|
74
|
+
webhook_url
|
|
75
|
+
]
|
|
76
|
+
end
|
|
77
|
+
|
|
78
|
+
# An array for nullable fields
|
|
79
|
+
def self.nullables
|
|
80
|
+
[]
|
|
81
|
+
end
|
|
82
|
+
|
|
83
|
+
def initialize(business_legal_name = nil, business_dba = SKIP,
|
|
84
|
+
business_address_country = SKIP,
|
|
85
|
+
business_street_address1 = SKIP,
|
|
86
|
+
business_street_address2 = SKIP, business_city = SKIP,
|
|
87
|
+
business_state = SKIP,
|
|
88
|
+
business_legal_entity_identifier = SKIP, webhook_url = SKIP)
|
|
89
|
+
@business_legal_name = business_legal_name
|
|
90
|
+
@business_dba = business_dba unless business_dba == SKIP
|
|
91
|
+
@business_address_country = business_address_country unless business_address_country == SKIP
|
|
92
|
+
@business_street_address1 = business_street_address1 unless business_street_address1 == SKIP
|
|
93
|
+
@business_street_address2 = business_street_address2 unless business_street_address2 == SKIP
|
|
94
|
+
@business_city = business_city unless business_city == SKIP
|
|
95
|
+
@business_state = business_state unless business_state == SKIP
|
|
96
|
+
unless business_legal_entity_identifier == SKIP
|
|
97
|
+
@business_legal_entity_identifier =
|
|
98
|
+
business_legal_entity_identifier
|
|
99
|
+
end
|
|
100
|
+
@webhook_url = webhook_url unless webhook_url == SKIP
|
|
101
|
+
end
|
|
102
|
+
|
|
103
|
+
# Creates an instance of the object from a hash.
|
|
104
|
+
def self.from_hash(hash)
|
|
105
|
+
return nil unless hash
|
|
106
|
+
|
|
107
|
+
# Extract variables from the hash.
|
|
108
|
+
business_legal_name =
|
|
109
|
+
hash.key?('business_legal_name') ? hash['business_legal_name'] : nil
|
|
110
|
+
business_dba = hash.key?('business_dba') ? APIHelper.deserialize_union_type(
|
|
111
|
+
UnionTypeLookUp.get(:CreateTenantRequestBusinessDba), hash['business_dba']
|
|
112
|
+
) : SKIP
|
|
113
|
+
business_address_country = hash.key?('business_address_country') ? APIHelper.deserialize_union_type(
|
|
114
|
+
UnionTypeLookUp.get(:CreateTenantRequestBusinessAddressCountry), hash['business_address_country']
|
|
115
|
+
) : SKIP
|
|
116
|
+
business_street_address1 = hash.key?('business_street_address1') ? APIHelper.deserialize_union_type(
|
|
117
|
+
UnionTypeLookUp.get(:CreateTenantRequestBusinessStreetAddress1), hash['business_street_address1']
|
|
118
|
+
) : SKIP
|
|
119
|
+
business_street_address2 = hash.key?('business_street_address2') ? APIHelper.deserialize_union_type(
|
|
120
|
+
UnionTypeLookUp.get(:CreateTenantRequestBusinessStreetAddress2), hash['business_street_address2']
|
|
121
|
+
) : SKIP
|
|
122
|
+
business_city = hash.key?('business_city') ? APIHelper.deserialize_union_type(
|
|
123
|
+
UnionTypeLookUp.get(:CreateTenantRequestBusinessCity), hash['business_city']
|
|
124
|
+
) : SKIP
|
|
125
|
+
business_state = hash.key?('business_state') ? APIHelper.deserialize_union_type(
|
|
126
|
+
UnionTypeLookUp.get(:CreateTenantRequestBusinessState), hash['business_state']
|
|
127
|
+
) : SKIP
|
|
128
|
+
business_legal_entity_identifier = hash.key?('business_legal_entity_identifier') ? APIHelper.deserialize_union_type(
|
|
129
|
+
UnionTypeLookUp.get(:CreateTenantRequestBusinessLegalEntityIdentifier), hash['business_legal_entity_identifier']
|
|
130
|
+
) : SKIP
|
|
131
|
+
webhook_url = hash.key?('webhook_url') ? APIHelper.deserialize_union_type(
|
|
132
|
+
UnionTypeLookUp.get(:CreateTenantRequestWebhookUrl), hash['webhook_url']
|
|
133
|
+
) : SKIP
|
|
134
|
+
|
|
135
|
+
# Create object from extracted values.
|
|
136
|
+
CreateTenantRequest.new(business_legal_name,
|
|
137
|
+
business_dba,
|
|
138
|
+
business_address_country,
|
|
139
|
+
business_street_address1,
|
|
140
|
+
business_street_address2,
|
|
141
|
+
business_city,
|
|
142
|
+
business_state,
|
|
143
|
+
business_legal_entity_identifier,
|
|
144
|
+
webhook_url)
|
|
145
|
+
end
|
|
146
|
+
|
|
147
|
+
# Validates an instance of the object from a given value.
|
|
148
|
+
# @param [CreateTenantRequest | Hash] The value against the validation is performed.
|
|
149
|
+
def self.validate(value)
|
|
150
|
+
if value.instance_of? self
|
|
151
|
+
return APIHelper.valid_type?(value.business_legal_name,
|
|
152
|
+
->(val) { val.instance_of? String })
|
|
153
|
+
end
|
|
154
|
+
|
|
155
|
+
return false unless value.instance_of? Hash
|
|
156
|
+
|
|
157
|
+
APIHelper.valid_type?(value['business_legal_name'],
|
|
158
|
+
->(val) { val.instance_of? String })
|
|
159
|
+
end
|
|
160
|
+
|
|
161
|
+
# Provides a human-readable string representation of the object.
|
|
162
|
+
def to_s
|
|
163
|
+
class_name = self.class.name.split('::').last
|
|
164
|
+
"<#{class_name} business_legal_name: #{@business_legal_name}, business_dba:"\
|
|
165
|
+
" #{@business_dba}, business_address_country: #{@business_address_country},"\
|
|
166
|
+
" business_street_address1: #{@business_street_address1}, business_street_address2:"\
|
|
167
|
+
" #{@business_street_address2}, business_city: #{@business_city}, business_state:"\
|
|
168
|
+
" #{@business_state}, business_legal_entity_identifier:"\
|
|
169
|
+
" #{@business_legal_entity_identifier}, webhook_url: #{@webhook_url}>"
|
|
170
|
+
end
|
|
171
|
+
|
|
172
|
+
# Provides a debugging-friendly string with detailed object information.
|
|
173
|
+
def inspect
|
|
174
|
+
class_name = self.class.name.split('::').last
|
|
175
|
+
"<#{class_name} business_legal_name: #{@business_legal_name.inspect}, business_dba:"\
|
|
176
|
+
" #{@business_dba.inspect}, business_address_country: #{@business_address_country.inspect},"\
|
|
177
|
+
" business_street_address1: #{@business_street_address1.inspect}, business_street_address2:"\
|
|
178
|
+
" #{@business_street_address2.inspect}, business_city: #{@business_city.inspect},"\
|
|
179
|
+
" business_state: #{@business_state.inspect}, business_legal_entity_identifier:"\
|
|
180
|
+
" #{@business_legal_entity_identifier.inspect}, webhook_url: #{@webhook_url.inspect}>"
|
|
181
|
+
end
|
|
182
|
+
end
|
|
183
|
+
end
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
# tesser_apiv1
|
|
2
|
+
#
|
|
3
|
+
# This file was automatically generated by APIMATIC v3.0 (
|
|
4
|
+
# https://www.apimatic.io ).
|
|
5
|
+
|
|
6
|
+
module TesserApiv1
|
|
7
|
+
# CreateTenantResponse Model.
|
|
8
|
+
class CreateTenantResponse < BaseModel
|
|
9
|
+
SKIP = Object.new
|
|
10
|
+
private_constant :SKIP
|
|
11
|
+
|
|
12
|
+
# TODO: Write general description for this method
|
|
13
|
+
# @return [Data8]
|
|
14
|
+
attr_accessor :data
|
|
15
|
+
|
|
16
|
+
# A mapping from model property names to API property names.
|
|
17
|
+
def self.names
|
|
18
|
+
@_hash = {} if @_hash.nil?
|
|
19
|
+
@_hash['data'] = 'data'
|
|
20
|
+
@_hash
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
# An array for optional fields
|
|
24
|
+
def self.optionals
|
|
25
|
+
[]
|
|
26
|
+
end
|
|
27
|
+
|
|
28
|
+
# An array for nullable fields
|
|
29
|
+
def self.nullables
|
|
30
|
+
[]
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
def initialize(data = nil)
|
|
34
|
+
@data = data
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
# Creates an instance of the object from a hash.
|
|
38
|
+
def self.from_hash(hash)
|
|
39
|
+
return nil unless hash
|
|
40
|
+
|
|
41
|
+
# Extract variables from the hash.
|
|
42
|
+
data = Data8.from_hash(hash['data']) if hash['data']
|
|
43
|
+
|
|
44
|
+
# Create object from extracted values.
|
|
45
|
+
CreateTenantResponse.new(data)
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# Provides a human-readable string representation of the object.
|
|
49
|
+
def to_s
|
|
50
|
+
class_name = self.class.name.split('::').last
|
|
51
|
+
"<#{class_name} data: #{@data}>"
|
|
52
|
+
end
|
|
53
|
+
|
|
54
|
+
# Provides a debugging-friendly string with detailed object information.
|
|
55
|
+
def inspect
|
|
56
|
+
class_name = self.class.name.split('::').last
|
|
57
|
+
"<#{class_name} data: #{@data.inspect}>"
|
|
58
|
+
end
|
|
59
|
+
end
|
|
60
|
+
end
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
# tesser_apiv1
|
|
2
|
+
#
|
|
3
|
+
# This file was automatically generated by APIMATIC v3.0 (
|
|
4
|
+
# https://www.apimatic.io ).
|
|
5
|
+
|
|
6
|
+
module TesserApiv1
|
|
7
|
+
# CreateWalletRequest Model.
|
|
8
|
+
class CreateWalletRequest < BaseModel
|
|
9
|
+
SKIP = Object.new
|
|
10
|
+
private_constant :SKIP
|
|
11
|
+
|
|
12
|
+
# ID of the workspace.
|
|
13
|
+
# @return [String]
|
|
14
|
+
attr_accessor :workspace_id
|
|
15
|
+
|
|
16
|
+
# ID of the tenant that owns this wallet (optional). At most one of
|
|
17
|
+
# tenant_id or counterparty_id may be provided.
|
|
18
|
+
# @return [String]
|
|
19
|
+
attr_accessor :tenant_id
|
|
20
|
+
|
|
21
|
+
# ID of the counterparty that owns this wallet (optional). At most one of
|
|
22
|
+
# tenant_id or counterparty_id may be provided.
|
|
23
|
+
# @return [String]
|
|
24
|
+
attr_accessor :counterparty_id
|
|
25
|
+
|
|
26
|
+
# Name of the wallet account.
|
|
27
|
+
# @return [String]
|
|
28
|
+
attr_accessor :name
|
|
29
|
+
|
|
30
|
+
# Wallet type.
|
|
31
|
+
# @return [Type3Enum]
|
|
32
|
+
attr_accessor :type
|
|
33
|
+
|
|
34
|
+
# A cryptographic stamp used to verify the integrity and authenticity of the
|
|
35
|
+
# request. This ensures the request was signed by an authorized key. See
|
|
36
|
+
# Documentation > Signing for more details.
|
|
37
|
+
# @return [String]
|
|
38
|
+
attr_accessor :signature
|
|
39
|
+
|
|
40
|
+
# A mapping from model property names to API property names.
|
|
41
|
+
def self.names
|
|
42
|
+
@_hash = {} if @_hash.nil?
|
|
43
|
+
@_hash['workspace_id'] = 'workspace_id'
|
|
44
|
+
@_hash['tenant_id'] = 'tenant_id'
|
|
45
|
+
@_hash['counterparty_id'] = 'counterparty_id'
|
|
46
|
+
@_hash['name'] = 'name'
|
|
47
|
+
@_hash['type'] = 'type'
|
|
48
|
+
@_hash['signature'] = 'signature'
|
|
49
|
+
@_hash
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
# An array for optional fields
|
|
53
|
+
def self.optionals
|
|
54
|
+
%w[
|
|
55
|
+
tenant_id
|
|
56
|
+
counterparty_id
|
|
57
|
+
]
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
# An array for nullable fields
|
|
61
|
+
def self.nullables
|
|
62
|
+
[]
|
|
63
|
+
end
|
|
64
|
+
|
|
65
|
+
def initialize(workspace_id = nil, name = nil, type = nil, signature = nil,
|
|
66
|
+
tenant_id = SKIP, counterparty_id = SKIP)
|
|
67
|
+
@workspace_id = workspace_id
|
|
68
|
+
@tenant_id = tenant_id unless tenant_id == SKIP
|
|
69
|
+
@counterparty_id = counterparty_id unless counterparty_id == SKIP
|
|
70
|
+
@name = name
|
|
71
|
+
@type = type
|
|
72
|
+
@signature = signature
|
|
73
|
+
end
|
|
74
|
+
|
|
75
|
+
# Creates an instance of the object from a hash.
|
|
76
|
+
def self.from_hash(hash)
|
|
77
|
+
return nil unless hash
|
|
78
|
+
|
|
79
|
+
# Extract variables from the hash.
|
|
80
|
+
workspace_id = hash.key?('workspace_id') ? hash['workspace_id'] : nil
|
|
81
|
+
name = hash.key?('name') ? hash['name'] : nil
|
|
82
|
+
type = hash.key?('type') ? hash['type'] : nil
|
|
83
|
+
signature = hash.key?('signature') ? hash['signature'] : nil
|
|
84
|
+
tenant_id = hash.key?('tenant_id') ? hash['tenant_id'] : SKIP
|
|
85
|
+
counterparty_id =
|
|
86
|
+
hash.key?('counterparty_id') ? hash['counterparty_id'] : SKIP
|
|
87
|
+
|
|
88
|
+
# Create object from extracted values.
|
|
89
|
+
CreateWalletRequest.new(workspace_id,
|
|
90
|
+
name,
|
|
91
|
+
type,
|
|
92
|
+
signature,
|
|
93
|
+
tenant_id,
|
|
94
|
+
counterparty_id)
|
|
95
|
+
end
|
|
96
|
+
|
|
97
|
+
# Provides a human-readable string representation of the object.
|
|
98
|
+
def to_s
|
|
99
|
+
class_name = self.class.name.split('::').last
|
|
100
|
+
"<#{class_name} workspace_id: #{@workspace_id}, tenant_id: #{@tenant_id}, counterparty_id:"\
|
|
101
|
+
" #{@counterparty_id}, name: #{@name}, type: #{@type}, signature: #{@signature}>"
|
|
102
|
+
end
|
|
103
|
+
|
|
104
|
+
# Provides a debugging-friendly string with detailed object information.
|
|
105
|
+
def inspect
|
|
106
|
+
class_name = self.class.name.split('::').last
|
|
107
|
+
"<#{class_name} workspace_id: #{@workspace_id.inspect}, tenant_id: #{@tenant_id.inspect},"\
|
|
108
|
+
" counterparty_id: #{@counterparty_id.inspect}, name: #{@name.inspect}, type:"\
|
|
109
|
+
" #{@type.inspect}, signature: #{@signature.inspect}>"
|
|
110
|
+
end
|
|
111
|
+
end
|
|
112
|
+
end
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
# tesser_apiv1
|
|
2
|
+
#
|
|
3
|
+
# This file was automatically generated by APIMATIC v3.0 (
|
|
4
|
+
# https://www.apimatic.io ).
|
|
5
|
+
|
|
6
|
+
module TesserApiv1
|
|
7
|
+
# CreateWalletResponse Model.
|
|
8
|
+
class CreateWalletResponse < BaseModel
|
|
9
|
+
SKIP = Object.new
|
|
10
|
+
private_constant :SKIP
|
|
11
|
+
|
|
12
|
+
# TODO: Write general description for this method
|
|
13
|
+
# @return [AccountSafe]
|
|
14
|
+
attr_accessor :data
|
|
15
|
+
|
|
16
|
+
# A mapping from model property names to API property names.
|
|
17
|
+
def self.names
|
|
18
|
+
@_hash = {} if @_hash.nil?
|
|
19
|
+
@_hash['data'] = 'data'
|
|
20
|
+
@_hash
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
# An array for optional fields
|
|
24
|
+
def self.optionals
|
|
25
|
+
[]
|
|
26
|
+
end
|
|
27
|
+
|
|
28
|
+
# An array for nullable fields
|
|
29
|
+
def self.nullables
|
|
30
|
+
[]
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
def initialize(data = nil)
|
|
34
|
+
@data = data
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
# Creates an instance of the object from a hash.
|
|
38
|
+
def self.from_hash(hash)
|
|
39
|
+
return nil unless hash
|
|
40
|
+
|
|
41
|
+
# Extract variables from the hash.
|
|
42
|
+
data = AccountSafe.from_hash(hash['data']) if hash['data']
|
|
43
|
+
|
|
44
|
+
# Create object from extracted values.
|
|
45
|
+
CreateWalletResponse.new(data)
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# Provides a human-readable string representation of the object.
|
|
49
|
+
def to_s
|
|
50
|
+
class_name = self.class.name.split('::').last
|
|
51
|
+
"<#{class_name} data: #{@data}>"
|
|
52
|
+
end
|
|
53
|
+
|
|
54
|
+
# Provides a debugging-friendly string with detailed object information.
|
|
55
|
+
def inspect
|
|
56
|
+
class_name = self.class.name.split('::').last
|
|
57
|
+
"<#{class_name} data: #{@data.inspect}>"
|
|
58
|
+
end
|
|
59
|
+
end
|
|
60
|
+
end
|