Class: OrbipayPaymentsapiClient::OrbipayPaymentsapiClientApis::PaymentAuthorizationApi
- Inherits:
-
Object
- Object
- OrbipayPaymentsapiClient::OrbipayPaymentsapiClientApis::PaymentAuthorizationApi
- Defined in:
- lib/orbipay_paymentsapi_client/api/payment_authorization_api.rb
Overview
.
############################################################################################
## This class subject to change without prior notice, Please dont use this class directly.##
############################################################################################
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#cancel_payment_authorization(channel, client_key, product, timestamp, idempotent_request_key, requestor_type, id_customer, id_authorization, cancel_payment_authorization_request, opts = {}) ⇒ nil
Cancel Payment Authorization The API is used to cancel a payment authorization.
-
#cancel_payment_authorization_with_http_info(channel, client_key, product, timestamp, idempotent_request_key, requestor_type, id_customer, id_authorization, cancel_payment_authorization_request, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>
Cancel Payment Authorization The API is used to cancel a payment authorization.
-
#create_payment_authorization(channel, client_key, product, timestamp, idempotent_request_key, requestor_type, create_payment_authorization_request, opts = {}) ⇒ [PaymentAuthorizationResponse, headers]
Create Payment Authorization The API is used to create a payment authorization with certain amount on a given card account.
-
#create_payment_authorization_with_http_info(channel, client_key, product, timestamp, idempotent_request_key, requestor_type, create_payment_authorization_request, opts = {}) ⇒ Array<(PaymentAuthorizationResponse, Fixnum, Hash)>
Create Payment Authorization The API is used to create a payment authorization with certain amount on a given card account.
-
#initialize(api_client = ApiClient.default) ⇒ PaymentAuthorizationApi
constructor
A new instance of PaymentAuthorizationApi.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ PaymentAuthorizationApi
Returns a new instance of PaymentAuthorizationApi.
15 16 17 |
# File 'lib/orbipay_paymentsapi_client/api/payment_authorization_api.rb', line 15 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
13 14 15 |
# File 'lib/orbipay_paymentsapi_client/api/payment_authorization_api.rb', line 13 def api_client @api_client end |
Instance Method Details
#cancel_payment_authorization(channel, client_key, product, timestamp, idempotent_request_key, requestor_type, id_customer, id_authorization, cancel_payment_authorization_request, opts = {}) ⇒ nil
Cancel Payment Authorization The API is used to cancel a payment authorization. Payment Authorizations that are already been processed into Payment cannot be cancelled. It returns 204 http status code with empty body in successful case.
34 35 36 37 |
# File 'lib/orbipay_paymentsapi_client/api/payment_authorization_api.rb', line 34 def (channel, client_key, product, , idempotent_request_key, requestor_type, id_customer, , , opts = {}) data, _status_code, _headers = (channel, client_key, product, , idempotent_request_key, requestor_type, id_customer, , , opts) [_status_code, _headers] end |
#cancel_payment_authorization_with_http_info(channel, client_key, product, timestamp, idempotent_request_key, requestor_type, id_customer, id_authorization, cancel_payment_authorization_request, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>
Cancel Payment Authorization The API is used to cancel a payment authorization. Payment Authorizations that are already been processed into Payment cannot be cancelled. It returns 204 http status code with empty body in successful case.
55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 |
# File 'lib/orbipay_paymentsapi_client/api/payment_authorization_api.rb', line 55 def (channel, client_key, product, , idempotent_request_key, requestor_type, id_customer, , , opts = {}) # resource path local_var_path = '/customers/{ID_CUSTOMER}/payments/auth/{ID_AUTHORIZATION}/cancel' if !id_customer.nil? && id_customer.to_s.strip != "" local_var_path = local_var_path.sub('{' + 'ID_CUSTOMER' + '}', id_customer.to_s) else fail ArgumentError, "Missing the required parameter 'id_customer' when calling PaymentAuthorizationApi.cancel_payment_authorization" end if !.nil? && .to_s.strip != "" local_var_path = local_var_path.sub('{' + 'ID_AUTHORIZATION' + '}', .to_s) else fail ArgumentError, "Missing the required parameter 'id_authorization' when calling PaymentAuthorizationApi.cancel_payment_authorization" end # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) header_params['channel'] = channel header_params['client_key'] = client_key header_params['product'] = product header_params['timestamp'] = header_params['idempotent_request_key'] = idempotent_request_key header_params['requestor_type'] = requestor_type header_params['requestor'] = opts[:'requestor'] if !opts[:'requestor'].nil? header_params['X-OPAY-Headers'] = opts[:'x_opay_headers'] if !opts[:'x_opay_headers'].nil? header_params['trace_id'] = opts[:'trace_id'] if !opts[:'trace_id'].nil? # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body() auth_names = [] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names) return data, status_code, headers end |
#create_payment_authorization(channel, client_key, product, timestamp, idempotent_request_key, requestor_type, create_payment_authorization_request, opts = {}) ⇒ [PaymentAuthorizationResponse, headers]
Create Payment Authorization The API is used to create a payment authorization with certain amount on a given card account. Client systems can provide the unique identifier for the payment authorization in their system as payment_auth_reference.
118 119 120 121 |
# File 'lib/orbipay_paymentsapi_client/api/payment_authorization_api.rb', line 118 def (channel, client_key, product, , idempotent_request_key, requestor_type, , opts = {}) data, _status_code, _headers = (channel, client_key, product, , idempotent_request_key, requestor_type, , opts) [data, _status_code, _headers] end |
#create_payment_authorization_with_http_info(channel, client_key, product, timestamp, idempotent_request_key, requestor_type, create_payment_authorization_request, opts = {}) ⇒ Array<(PaymentAuthorizationResponse, Fixnum, Hash)>
Create Payment Authorization The API is used to create a payment authorization with certain amount on a given card account. Client systems can provide the unique identifier for the payment authorization in their system as payment_auth_reference.
137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 |
# File 'lib/orbipay_paymentsapi_client/api/payment_authorization_api.rb', line 137 def (channel, client_key, product, , idempotent_request_key, requestor_type, , opts = {}) # resource path local_var_path = '/payments/auth' # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) header_params['channel'] = channel header_params['client_key'] = client_key header_params['product'] = product header_params['timestamp'] = header_params['idempotent_request_key'] = idempotent_request_key header_params['requestor_type'] = requestor_type header_params['requestor'] = opts[:'requestor'] if !opts[:'requestor'].nil? header_params['X-OPAY-Headers'] = opts[:'x_opay_headers'] if !opts[:'x_opay_headers'].nil? header_params['trace_id'] = opts[:'trace_id'] if !opts[:'trace_id'].nil? # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body() auth_names = [] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'PaymentAuthorizationResponse') return data, status_code, headers end |