devdraft 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/Gemfile +9 -0
- data/README.md +1246 -0
- data/Rakefile +8 -0
- data/devdraft_ai_sdk.gemspec +38 -0
- data/docs/APIHealthApi.md +87 -0
- data/docs/AggregatedBalanceResponse.md +9 -0
- data/docs/AllBalancesResponse.md +9 -0
- data/docs/AllOfAllBalancesResponseEurc.md +9 -0
- data/docs/AllOfAllBalancesResponseUsdc.md +9 -0
- data/docs/AllOfCreateBankPaymentIntentDtoDestinationCurrency.md +6 -0
- data/docs/AllOfCreateBankPaymentIntentDtoDestinationNetwork.md +6 -0
- data/docs/AllOfCreateBankPaymentIntentDtoSourceCurrency.md +6 -0
- data/docs/AllOfCreateBankPaymentIntentDtoSourcePaymentRail.md +6 -0
- data/docs/AllOfCreateCustomerDtoStatus.md +6 -0
- data/docs/AllOfCreateLiquidationAddressDtoDestinationCurrency.md +6 -0
- data/docs/AllOfCreateLiquidationAddressDtoDestinationPaymentRail.md +6 -0
- data/docs/AllOfCreateStablePaymentIntentDtoDestinationCurrency.md +6 -0
- data/docs/AllOfCreateStablePaymentIntentDtoDestinationNetwork.md +6 -0
- data/docs/AllOfCreateStablePaymentIntentDtoSourceCurrency.md +6 -0
- data/docs/AllOfCreateStablePaymentIntentDtoSourceNetwork.md +6 -0
- data/docs/AllOfUpdateCustomerDtoStatus.md +6 -0
- data/docs/AppBalancesApi.md +169 -0
- data/docs/BridgePaymentRail.md +6 -0
- data/docs/CreateBankPaymentIntentDto.md +24 -0
- data/docs/CreateCustomerDto.md +12 -0
- data/docs/CreateDirectBankTransferDto.md +14 -0
- data/docs/CreateDirectWalletTransferDto.md +10 -0
- data/docs/CreateInvoiceDto.md +22 -0
- data/docs/CreateLiquidationAddressDto.md +21 -0
- data/docs/CreatePaymentLinkDto.md +31 -0
- data/docs/CreateProductDto.md +18 -0
- data/docs/CreateStablePaymentIntentDto.md +21 -0
- data/docs/CreateStablecoinConversionDto.md +11 -0
- data/docs/CreateTaxInput.md +6 -0
- data/docs/CreateWebhookDto.md +11 -0
- data/docs/CustomerStatus.md +6 -0
- data/docs/CustomersApi.md +250 -0
- data/docs/DestinationCurrency.md +6 -0
- data/docs/ExchangeRateResponseDto.md +12 -0
- data/docs/ExchangeRatesApi.md +176 -0
- data/docs/FiatCurrency.md +6 -0
- data/docs/HealthResponseDto.md +12 -0
- data/docs/InvoiceProductDto.md +8 -0
- data/docs/InvoicesApi.md +236 -0
- data/docs/LiquidationAddressResponseDto.md +20 -0
- data/docs/LiquidationAddressesApi.md +152 -0
- data/docs/PaymentIntentsApi.md +127 -0
- data/docs/PaymentLinkProductDto.md +8 -0
- data/docs/PaymentLinksApi.md +238 -0
- data/docs/PaymentRequestDto.md +10 -0
- data/docs/PaymentResponseDto.md +11 -0
- data/docs/ProductsApi.md +404 -0
- data/docs/PublicHealthResponseDto.md +9 -0
- data/docs/RefundResponseDto.md +11 -0
- data/docs/StableCoinCurrency.md +6 -0
- data/docs/TaxesApi.md +292 -0
- data/docs/TestPaymentsApi.md +150 -0
- data/docs/TransfersApi.md +175 -0
- data/docs/UpdateCustomerDto.md +12 -0
- data/docs/UpdatePaymentLinkDto.md +6 -0
- data/docs/UpdatePreferenceInput.md +6 -0
- data/docs/UpdateProductDto.md +18 -0
- data/docs/UpdateTaxInput.md +6 -0
- data/docs/UpdateWebhookDto.md +11 -0
- data/docs/WalletsApi.md +58 -0
- data/docs/WebhookResponseDto.md +14 -0
- data/docs/WebhooksApi.md +307 -0
- data/git_push.sh +44 -0
- data/lib/devdraft/api/api_health_api.rb +116 -0
- data/lib/devdraft/api/app_balances_api.rb +170 -0
- data/lib/devdraft/api/customers_api.rb +258 -0
- data/lib/devdraft/api/exchange_rates_api.rb +184 -0
- data/lib/devdraft/api/invoices_api.rb +238 -0
- data/lib/devdraft/api/liquidation_addresses_api.rb +202 -0
- data/lib/devdraft/api/payment_intents_api.rb +150 -0
- data/lib/devdraft/api/payment_links_api.rb +240 -0
- data/lib/devdraft/api/products_api.rb +518 -0
- data/lib/devdraft/api/taxes_api.rb +290 -0
- data/lib/devdraft/api/test_payments_api.rb +202 -0
- data/lib/devdraft/api/transfers_api.rb +182 -0
- data/lib/devdraft/api/wallets_api.rb +66 -0
- data/lib/devdraft/api/webhooks_api.rb +310 -0
- data/lib/devdraft/api_client.rb +388 -0
- data/lib/devdraft/api_error.rb +57 -0
- data/lib/devdraft/configuration.rb +219 -0
- data/lib/devdraft/models/aggregated_balance_response.rb +278 -0
- data/lib/devdraft/models/all_balances_response.rb +242 -0
- data/lib/devdraft/models/all_of_all_balances_response_eurc.rb +283 -0
- data/lib/devdraft/models/all_of_all_balances_response_usdc.rb +283 -0
- data/lib/devdraft/models/all_of_create_bank_payment_intent_dto_destination_currency.rb +202 -0
- data/lib/devdraft/models/all_of_create_bank_payment_intent_dto_destination_network.rb +202 -0
- data/lib/devdraft/models/all_of_create_bank_payment_intent_dto_source_currency.rb +202 -0
- data/lib/devdraft/models/all_of_create_bank_payment_intent_dto_source_payment_rail.rb +202 -0
- data/lib/devdraft/models/all_of_create_customer_dto_status.rb +202 -0
- data/lib/devdraft/models/all_of_create_liquidation_address_dto_destination_currency.rb +202 -0
- data/lib/devdraft/models/all_of_create_liquidation_address_dto_destination_payment_rail.rb +202 -0
- data/lib/devdraft/models/all_of_create_stable_payment_intent_dto_destination_currency.rb +202 -0
- data/lib/devdraft/models/all_of_create_stable_payment_intent_dto_destination_network.rb +202 -0
- data/lib/devdraft/models/all_of_create_stable_payment_intent_dto_source_currency.rb +202 -0
- data/lib/devdraft/models/all_of_create_stable_payment_intent_dto_source_network.rb +202 -0
- data/lib/devdraft/models/all_of_update_customer_dto_status.rb +202 -0
- data/lib/devdraft/models/bridge_payment_rail.rb +43 -0
- data/lib/devdraft/models/create_bank_payment_intent_dto.rb +397 -0
- data/lib/devdraft/models/create_customer_dto.rb +308 -0
- data/lib/devdraft/models/create_direct_bank_transfer_dto.rb +302 -0
- data/lib/devdraft/models/create_direct_wallet_transfer_dto.rb +257 -0
- data/lib/devdraft/models/create_invoice_dto.rb +474 -0
- data/lib/devdraft/models/create_liquidation_address_dto.rb +408 -0
- data/lib/devdraft/models/create_payment_link_dto.rb +603 -0
- data/lib/devdraft/models/create_product_dto.rb +370 -0
- data/lib/devdraft/models/create_stable_payment_intent_dto.rb +362 -0
- data/lib/devdraft/models/create_stablecoin_conversion_dto.rb +272 -0
- data/lib/devdraft/models/create_tax_input.rb +197 -0
- data/lib/devdraft/models/create_webhook_dto.rb +271 -0
- data/lib/devdraft/models/customer_status.rb +29 -0
- data/lib/devdraft/models/destination_currency.rb +34 -0
- data/lib/devdraft/models/exchange_rate_response_dto.rb +282 -0
- data/lib/devdraft/models/fiat_currency.rb +29 -0
- data/lib/devdraft/models/health_response_dto.rb +333 -0
- data/lib/devdraft/models/invoice_product_dto.rb +227 -0
- data/lib/devdraft/models/liquidation_address_response_dto.rb +377 -0
- data/lib/devdraft/models/payment_link_product_dto.rb +229 -0
- data/lib/devdraft/models/payment_request_dto.rb +252 -0
- data/lib/devdraft/models/payment_response_dto.rb +272 -0
- data/lib/devdraft/models/public_health_response_dto.rb +276 -0
- data/lib/devdraft/models/refund_response_dto.rb +272 -0
- data/lib/devdraft/models/stable_coin_currency.rb +28 -0
- data/lib/devdraft/models/update_customer_dto.rb +293 -0
- data/lib/devdraft/models/update_payment_link_dto.rb +197 -0
- data/lib/devdraft/models/update_preference_input.rb +197 -0
- data/lib/devdraft/models/update_product_dto.rb +355 -0
- data/lib/devdraft/models/update_tax_input.rb +197 -0
- data/lib/devdraft/models/update_webhook_dto.rb +251 -0
- data/lib/devdraft/models/webhook_response_dto.rb +317 -0
- data/lib/devdraft/version.rb +14 -0
- data/lib/devdraft.rb +101 -0
- data/spec/api/api_health_api_spec.rb +54 -0
- data/spec/api/app_balances_api_spec.rb +67 -0
- data/spec/api/customers_api_spec.rb +87 -0
- data/spec/api/exchange_rates_api_spec.rb +69 -0
- data/spec/api/invoices_api_spec.rb +80 -0
- data/spec/api/liquidation_addresses_api_spec.rb +72 -0
- data/spec/api/payment_intents_api_spec.rb +60 -0
- data/spec/api/payment_links_api_spec.rb +81 -0
- data/spec/api/products_api_spec.rb +130 -0
- data/spec/api/taxes_api_spec.rb +91 -0
- data/spec/api/test_payments_api_spec.rb +71 -0
- data/spec/api/transfers_api_spec.rb +67 -0
- data/spec/api/wallets_api_spec.rb +44 -0
- data/spec/api/webhooks_api_spec.rb +96 -0
- data/spec/api_client_spec.rb +225 -0
- data/spec/base_object_spec.rb +109 -0
- data/spec/configuration_spec.rb +41 -0
- data/spec/models/aggregated_balance_response_spec.rb +56 -0
- data/spec/models/all_balances_response_spec.rb +52 -0
- data/spec/models/all_of_all_balances_response_eurc_spec.rb +56 -0
- data/spec/models/all_of_all_balances_response_usdc_spec.rb +56 -0
- data/spec/models/all_of_create_bank_payment_intent_dto_destination_currency_spec.rb +34 -0
- data/spec/models/all_of_create_bank_payment_intent_dto_destination_network_spec.rb +34 -0
- data/spec/models/all_of_create_bank_payment_intent_dto_source_currency_spec.rb +34 -0
- data/spec/models/all_of_create_bank_payment_intent_dto_source_payment_rail_spec.rb +34 -0
- data/spec/models/all_of_create_customer_dto_status_spec.rb +34 -0
- data/spec/models/all_of_create_liquidation_address_dto_destination_currency_spec.rb +34 -0
- data/spec/models/all_of_create_liquidation_address_dto_destination_payment_rail_spec.rb +34 -0
- data/spec/models/all_of_create_stable_payment_intent_dto_destination_currency_spec.rb +34 -0
- data/spec/models/all_of_create_stable_payment_intent_dto_destination_network_spec.rb +34 -0
- data/spec/models/all_of_create_stable_payment_intent_dto_source_currency_spec.rb +34 -0
- data/spec/models/all_of_create_stable_payment_intent_dto_source_network_spec.rb +34 -0
- data/spec/models/all_of_update_customer_dto_status_spec.rb +34 -0
- data/spec/models/bridge_payment_rail_spec.rb +34 -0
- data/spec/models/create_bank_payment_intent_dto_spec.rb +142 -0
- data/spec/models/create_customer_dto_spec.rb +74 -0
- data/spec/models/create_direct_bank_transfer_dto_spec.rb +82 -0
- data/spec/models/create_direct_wallet_transfer_dto_spec.rb +58 -0
- data/spec/models/create_invoice_dto_spec.rb +146 -0
- data/spec/models/create_liquidation_address_dto_spec.rb +132 -0
- data/spec/models/create_payment_link_dto_spec.rb +200 -0
- data/spec/models/create_product_dto_spec.rb +110 -0
- data/spec/models/create_stable_payment_intent_dto_spec.rb +124 -0
- data/spec/models/create_stablecoin_conversion_dto_spec.rb +64 -0
- data/spec/models/create_tax_input_spec.rb +34 -0
- data/spec/models/create_webhook_dto_spec.rb +64 -0
- data/spec/models/customer_status_spec.rb +34 -0
- data/spec/models/destination_currency_spec.rb +34 -0
- data/spec/models/exchange_rate_response_dto_spec.rb +70 -0
- data/spec/models/fiat_currency_spec.rb +34 -0
- data/spec/models/health_response_dto_spec.rb +78 -0
- data/spec/models/invoice_product_dto_spec.rb +46 -0
- data/spec/models/liquidation_address_response_dto_spec.rb +118 -0
- data/spec/models/payment_link_product_dto_spec.rb +46 -0
- data/spec/models/payment_request_dto_spec.rb +58 -0
- data/spec/models/payment_response_dto_spec.rb +64 -0
- data/spec/models/public_health_response_dto_spec.rb +56 -0
- data/spec/models/refund_response_dto_spec.rb +64 -0
- data/spec/models/stable_coin_currency_spec.rb +34 -0
- data/spec/models/update_customer_dto_spec.rb +74 -0
- data/spec/models/update_payment_link_dto_spec.rb +34 -0
- data/spec/models/update_preference_input_spec.rb +34 -0
- data/spec/models/update_product_dto_spec.rb +110 -0
- data/spec/models/update_tax_input_spec.rb +34 -0
- data/spec/models/update_webhook_dto_spec.rb +64 -0
- data/spec/models/webhook_response_dto_spec.rb +82 -0
- data/spec/spec_helper.rb +110 -0
- metadata +375 -0
@@ -0,0 +1,240 @@
|
|
1
|
+
=begin
|
2
|
+
#Devdraft AI Payment & Business Management API
|
3
|
+
|
4
|
+
# A comprehensive payment processing and business management API that enables seamless integration of cryptocurrency and traditional payment methods.
|
5
|
+
|
6
|
+
OpenAPI spec version: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 3.0.65
|
10
|
+
=end
|
11
|
+
|
12
|
+
module DevDraftAI
|
13
|
+
class PaymentLinksApi
|
14
|
+
attr_accessor :api_client
|
15
|
+
|
16
|
+
def initialize(api_client = ApiClient.default)
|
17
|
+
@api_client = api_client
|
18
|
+
end
|
19
|
+
# Create a new payment link
|
20
|
+
# Creates a new payment link with the provided details. Supports both simple one-time payments and complex product bundles.
|
21
|
+
# @param body Payment link creation data
|
22
|
+
# @param [Hash] opts the optional parameters
|
23
|
+
# @return [nil]
|
24
|
+
def payment_links_controller_create(body, opts = {})
|
25
|
+
payment_links_controller_create_with_http_info(body, opts)
|
26
|
+
nil
|
27
|
+
end
|
28
|
+
|
29
|
+
# Create a new payment link
|
30
|
+
# Creates a new payment link with the provided details. Supports both simple one-time payments and complex product bundles.
|
31
|
+
# @param body Payment link creation data
|
32
|
+
# @param [Hash] opts the optional parameters
|
33
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
34
|
+
def payment_links_controller_create_with_http_info(body, opts = {})
|
35
|
+
if @api_client.config.debugging
|
36
|
+
@api_client.config.logger.debug 'Calling API: PaymentLinksApi.payment_links_controller_create ...'
|
37
|
+
end
|
38
|
+
# verify the required parameter 'body' is set
|
39
|
+
if @api_client.config.client_side_validation && body.nil?
|
40
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling PaymentLinksApi.payment_links_controller_create"
|
41
|
+
end
|
42
|
+
# resource path
|
43
|
+
local_var_path = '/api/v0/payment-links'
|
44
|
+
|
45
|
+
# query parameters
|
46
|
+
query_params = opts[:query_params] || {}
|
47
|
+
|
48
|
+
# header parameters
|
49
|
+
header_params = opts[:header_params] || {}
|
50
|
+
# HTTP header 'Content-Type'
|
51
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
52
|
+
|
53
|
+
# form parameters
|
54
|
+
form_params = opts[:form_params] || {}
|
55
|
+
|
56
|
+
# http body (model)
|
57
|
+
post_body = opts[:body] || @api_client.object_to_http_body(body)
|
58
|
+
|
59
|
+
return_type = opts[:return_type]
|
60
|
+
|
61
|
+
auth_names = opts[:auth_names] || ['x-client-key', 'x-client-secret']
|
62
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
63
|
+
:header_params => header_params,
|
64
|
+
:query_params => query_params,
|
65
|
+
:form_params => form_params,
|
66
|
+
:body => post_body,
|
67
|
+
:auth_names => auth_names,
|
68
|
+
:return_type => return_type)
|
69
|
+
|
70
|
+
if @api_client.config.debugging
|
71
|
+
@api_client.config.logger.debug "API called: PaymentLinksApi#payment_links_controller_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
72
|
+
end
|
73
|
+
return data, status_code, headers
|
74
|
+
end
|
75
|
+
# Get all payment links
|
76
|
+
# @param [Hash] opts the optional parameters
|
77
|
+
# @option opts [String] :skip Number of records to skip (must be non-negative)
|
78
|
+
# @option opts [String] :take Number of records to take (must be positive)
|
79
|
+
# @return [nil]
|
80
|
+
def payment_links_controller_find_all(opts = {})
|
81
|
+
payment_links_controller_find_all_with_http_info(opts)
|
82
|
+
nil
|
83
|
+
end
|
84
|
+
|
85
|
+
# Get all payment links
|
86
|
+
# @param [Hash] opts the optional parameters
|
87
|
+
# @option opts [String] :skip Number of records to skip (must be non-negative)
|
88
|
+
# @option opts [String] :take Number of records to take (must be positive)
|
89
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
90
|
+
def payment_links_controller_find_all_with_http_info(opts = {})
|
91
|
+
if @api_client.config.debugging
|
92
|
+
@api_client.config.logger.debug 'Calling API: PaymentLinksApi.payment_links_controller_find_all ...'
|
93
|
+
end
|
94
|
+
# resource path
|
95
|
+
local_var_path = '/api/v0/payment-links'
|
96
|
+
|
97
|
+
# query parameters
|
98
|
+
query_params = opts[:query_params] || {}
|
99
|
+
query_params[:'skip'] = opts[:'skip'] if !opts[:'skip'].nil?
|
100
|
+
query_params[:'take'] = opts[:'take'] if !opts[:'take'].nil?
|
101
|
+
|
102
|
+
# header parameters
|
103
|
+
header_params = opts[:header_params] || {}
|
104
|
+
|
105
|
+
# form parameters
|
106
|
+
form_params = opts[:form_params] || {}
|
107
|
+
|
108
|
+
# http body (model)
|
109
|
+
post_body = opts[:body]
|
110
|
+
|
111
|
+
return_type = opts[:return_type]
|
112
|
+
|
113
|
+
auth_names = opts[:auth_names] || ['x-client-key', 'x-client-secret']
|
114
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
115
|
+
:header_params => header_params,
|
116
|
+
:query_params => query_params,
|
117
|
+
:form_params => form_params,
|
118
|
+
:body => post_body,
|
119
|
+
:auth_names => auth_names,
|
120
|
+
:return_type => return_type)
|
121
|
+
|
122
|
+
if @api_client.config.debugging
|
123
|
+
@api_client.config.logger.debug "API called: PaymentLinksApi#payment_links_controller_find_all\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
124
|
+
end
|
125
|
+
return data, status_code, headers
|
126
|
+
end
|
127
|
+
# Get a payment link by ID
|
128
|
+
# @param id Payment Link ID
|
129
|
+
# @param [Hash] opts the optional parameters
|
130
|
+
# @return [nil]
|
131
|
+
def payment_links_controller_find_one(id, opts = {})
|
132
|
+
payment_links_controller_find_one_with_http_info(id, opts)
|
133
|
+
nil
|
134
|
+
end
|
135
|
+
|
136
|
+
# Get a payment link by ID
|
137
|
+
# @param id Payment Link ID
|
138
|
+
# @param [Hash] opts the optional parameters
|
139
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
140
|
+
def payment_links_controller_find_one_with_http_info(id, opts = {})
|
141
|
+
if @api_client.config.debugging
|
142
|
+
@api_client.config.logger.debug 'Calling API: PaymentLinksApi.payment_links_controller_find_one ...'
|
143
|
+
end
|
144
|
+
# verify the required parameter 'id' is set
|
145
|
+
if @api_client.config.client_side_validation && id.nil?
|
146
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling PaymentLinksApi.payment_links_controller_find_one"
|
147
|
+
end
|
148
|
+
# resource path
|
149
|
+
local_var_path = '/api/v0/payment-links/{id}'.sub('{' + 'id' + '}', id.to_s)
|
150
|
+
|
151
|
+
# query parameters
|
152
|
+
query_params = opts[:query_params] || {}
|
153
|
+
|
154
|
+
# header parameters
|
155
|
+
header_params = opts[:header_params] || {}
|
156
|
+
|
157
|
+
# form parameters
|
158
|
+
form_params = opts[:form_params] || {}
|
159
|
+
|
160
|
+
# http body (model)
|
161
|
+
post_body = opts[:body]
|
162
|
+
|
163
|
+
return_type = opts[:return_type]
|
164
|
+
|
165
|
+
auth_names = opts[:auth_names] || ['x-client-key', 'x-client-secret']
|
166
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
167
|
+
:header_params => header_params,
|
168
|
+
:query_params => query_params,
|
169
|
+
:form_params => form_params,
|
170
|
+
:body => post_body,
|
171
|
+
:auth_names => auth_names,
|
172
|
+
:return_type => return_type)
|
173
|
+
|
174
|
+
if @api_client.config.debugging
|
175
|
+
@api_client.config.logger.debug "API called: PaymentLinksApi#payment_links_controller_find_one\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
176
|
+
end
|
177
|
+
return data, status_code, headers
|
178
|
+
end
|
179
|
+
# Update a payment link
|
180
|
+
# @param body
|
181
|
+
# @param id Payment Link ID
|
182
|
+
# @param [Hash] opts the optional parameters
|
183
|
+
# @return [nil]
|
184
|
+
def payment_links_controller_update(body, id, opts = {})
|
185
|
+
payment_links_controller_update_with_http_info(body, id, opts)
|
186
|
+
nil
|
187
|
+
end
|
188
|
+
|
189
|
+
# Update a payment link
|
190
|
+
# @param body
|
191
|
+
# @param id Payment Link ID
|
192
|
+
# @param [Hash] opts the optional parameters
|
193
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
194
|
+
def payment_links_controller_update_with_http_info(body, id, opts = {})
|
195
|
+
if @api_client.config.debugging
|
196
|
+
@api_client.config.logger.debug 'Calling API: PaymentLinksApi.payment_links_controller_update ...'
|
197
|
+
end
|
198
|
+
# verify the required parameter 'body' is set
|
199
|
+
if @api_client.config.client_side_validation && body.nil?
|
200
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling PaymentLinksApi.payment_links_controller_update"
|
201
|
+
end
|
202
|
+
# verify the required parameter 'id' is set
|
203
|
+
if @api_client.config.client_side_validation && id.nil?
|
204
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling PaymentLinksApi.payment_links_controller_update"
|
205
|
+
end
|
206
|
+
# resource path
|
207
|
+
local_var_path = '/api/v0/payment-links/{id}'.sub('{' + 'id' + '}', id.to_s)
|
208
|
+
|
209
|
+
# query parameters
|
210
|
+
query_params = opts[:query_params] || {}
|
211
|
+
|
212
|
+
# header parameters
|
213
|
+
header_params = opts[:header_params] || {}
|
214
|
+
# HTTP header 'Content-Type'
|
215
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
216
|
+
|
217
|
+
# form parameters
|
218
|
+
form_params = opts[:form_params] || {}
|
219
|
+
|
220
|
+
# http body (model)
|
221
|
+
post_body = opts[:body] || @api_client.object_to_http_body(body)
|
222
|
+
|
223
|
+
return_type = opts[:return_type]
|
224
|
+
|
225
|
+
auth_names = opts[:auth_names] || ['x-client-key', 'x-client-secret']
|
226
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
|
227
|
+
:header_params => header_params,
|
228
|
+
:query_params => query_params,
|
229
|
+
:form_params => form_params,
|
230
|
+
:body => post_body,
|
231
|
+
:auth_names => auth_names,
|
232
|
+
:return_type => return_type)
|
233
|
+
|
234
|
+
if @api_client.config.debugging
|
235
|
+
@api_client.config.logger.debug "API called: PaymentLinksApi#payment_links_controller_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
236
|
+
end
|
237
|
+
return data, status_code, headers
|
238
|
+
end
|
239
|
+
end
|
240
|
+
end
|