Class: CyberSource::BillingAgreementsApi
- Inherits:
-
Object
- Object
- CyberSource::BillingAgreementsApi
- Defined in:
- lib/cybersource_rest_client/api/billing_agreements_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#billing_agreements_de_registration(modify_billing_agreement, id, opts = {}) ⇒ PtsV2CreditsPost201Response1
Standing Instruction Cancellation or Modification Standing Instruction with or without Token.
-
#billing_agreements_de_registration_with_http_info(modify_billing_agreement, id, opts = {}) ⇒ Array<(PtsV2CreditsPost201Response1, Fixnum, Hash)>
Standing Instruction Cancellation or Modification Standing Instruction with or without Token.
-
#billing_agreements_intimation(intimate_billing_agreement, id, opts = {}) ⇒ PtsV2CreditsPost201Response1
Standing Instruction intimation Standing Instruction with or without Token.
-
#billing_agreements_intimation_with_http_info(intimate_billing_agreement, id, opts = {}) ⇒ Array<(PtsV2CreditsPost201Response1, Fixnum, Hash)>
Standing Instruction intimation Standing Instruction with or without Token.
-
#billing_agreements_registration(create_billing_agreement, opts = {}) ⇒ PtsV2CreditsPost201Response1
Standing Instruction completion registration Standing Instruction with or without Token.
-
#billing_agreements_registration_with_http_info(create_billing_agreement, opts = {}) ⇒ Array<(PtsV2CreditsPost201Response1, Fixnum, Hash)>
Standing Instruction completion registration Standing Instruction with or without Token.
-
#initialize(api_client = ApiClient.default, config) ⇒ BillingAgreementsApi
constructor
A new instance of BillingAgreementsApi.
Constructor Details
#initialize(api_client = ApiClient.default, config) ⇒ BillingAgreementsApi
Returns a new instance of BillingAgreementsApi.
19 20 21 22 |
# File 'lib/cybersource_rest_client/api/billing_agreements_api.rb', line 19 def initialize(api_client = ApiClient.default, config) @api_client = api_client @api_client.set_configuration(config) end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
17 18 19 |
# File 'lib/cybersource_rest_client/api/billing_agreements_api.rb', line 17 def api_client @api_client end |
Instance Method Details
#billing_agreements_de_registration(modify_billing_agreement, id, opts = {}) ⇒ PtsV2CreditsPost201Response1
Standing Instruction Cancellation or Modification Standing Instruction with or without Token
31 32 33 34 |
# File 'lib/cybersource_rest_client/api/billing_agreements_api.rb', line 31 def billing_agreements_de_registration(modify_billing_agreement, id, opts = {}) data, status_code, headers = billing_agreements_de_registration_with_http_info(modify_billing_agreement, id, opts) return data, status_code, headers end |
#billing_agreements_de_registration_with_http_info(modify_billing_agreement, id, opts = {}) ⇒ Array<(PtsV2CreditsPost201Response1, Fixnum, Hash)>
Standing Instruction Cancellation or Modification Standing Instruction with or without Token
42 43 44 45 46 47 48 49 50 51 52 53 54 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 |
# File 'lib/cybersource_rest_client/api/billing_agreements_api.rb', line 42 def billing_agreements_de_registration_with_http_info(modify_billing_agreement, id, opts = {}) if @api_client.config.debugging begin raise @api_client.config.logger.debug 'Calling API: BillingAgreementsApi.billing_agreements_de_registration ...' rescue puts 'Cannot write to log' end end # verify the required parameter 'modify_billing_agreement' is set if @api_client.config.client_side_validation && modify_billing_agreement.nil? fail ArgumentError, "Missing the required parameter 'modify_billing_agreement' when calling BillingAgreementsApi.billing_agreements_de_registration" end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling BillingAgreementsApi.billing_agreements_de_registration" end # resource path local_var_path = 'pts/v2/billing-agreements/{id}'.sub('{' + 'id' + '}', id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/hal+json;charset=utf-8']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json;charset=utf-8']) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(modify_billing_agreement) sdk_tracker = SdkTracker.new post_body = sdk_tracker.insert_developer_id_tracker(post_body, 'ModifyBillingAgreement', @api_client.config.host) auth_names = [] data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'PtsV2CreditsPost201Response1') if @api_client.config.debugging begin raise @api_client.config.logger.debug "API called: BillingAgreementsApi#billing_agreements_de_registration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" rescue puts 'Cannot write to log' end end return data, status_code, headers end |
#billing_agreements_intimation(intimate_billing_agreement, id, opts = {}) ⇒ PtsV2CreditsPost201Response1
Standing Instruction intimation Standing Instruction with or without Token.
106 107 108 109 |
# File 'lib/cybersource_rest_client/api/billing_agreements_api.rb', line 106 def billing_agreements_intimation(intimate_billing_agreement, id, opts = {}) data, status_code, headers = billing_agreements_intimation_with_http_info(intimate_billing_agreement, id, opts) return data, status_code, headers end |
#billing_agreements_intimation_with_http_info(intimate_billing_agreement, id, opts = {}) ⇒ Array<(PtsV2CreditsPost201Response1, Fixnum, Hash)>
Standing Instruction intimation Standing Instruction with or without Token.
117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 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 |
# File 'lib/cybersource_rest_client/api/billing_agreements_api.rb', line 117 def billing_agreements_intimation_with_http_info(intimate_billing_agreement, id, opts = {}) if @api_client.config.debugging begin raise @api_client.config.logger.debug 'Calling API: BillingAgreementsApi.billing_agreements_intimation ...' rescue puts 'Cannot write to log' end end # verify the required parameter 'intimate_billing_agreement' is set if @api_client.config.client_side_validation && intimate_billing_agreement.nil? fail ArgumentError, "Missing the required parameter 'intimate_billing_agreement' when calling BillingAgreementsApi.billing_agreements_intimation" end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling BillingAgreementsApi.billing_agreements_intimation" end # resource path local_var_path = 'pts/v2/billing-agreements/{id}/intimations'.sub('{' + 'id' + '}', id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/hal+json;charset=utf-8']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json;charset=utf-8']) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(intimate_billing_agreement) sdk_tracker = SdkTracker.new post_body = sdk_tracker.insert_developer_id_tracker(post_body, 'IntimateBillingAgreement', @api_client.config.host) 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 => 'PtsV2CreditsPost201Response1') if @api_client.config.debugging begin raise @api_client.config.logger.debug "API called: BillingAgreementsApi#billing_agreements_intimation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" rescue puts 'Cannot write to log' end end return data, status_code, headers end |
#billing_agreements_registration(create_billing_agreement, opts = {}) ⇒ PtsV2CreditsPost201Response1
Standing Instruction completion registration Standing Instruction with or without Token. Transaction amount in case First payment is coming along with registration. Only 2 decimal places allowed
180 181 182 183 |
# File 'lib/cybersource_rest_client/api/billing_agreements_api.rb', line 180 def billing_agreements_registration(create_billing_agreement, opts = {}) data, status_code, headers = billing_agreements_registration_with_http_info(create_billing_agreement, opts) return data, status_code, headers end |
#billing_agreements_registration_with_http_info(create_billing_agreement, opts = {}) ⇒ Array<(PtsV2CreditsPost201Response1, Fixnum, Hash)>
Standing Instruction completion registration Standing Instruction with or without Token. Transaction amount in case First payment is coming along with registration. Only 2 decimal places allowed
190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 |
# File 'lib/cybersource_rest_client/api/billing_agreements_api.rb', line 190 def billing_agreements_registration_with_http_info(create_billing_agreement, opts = {}) if @api_client.config.debugging begin raise @api_client.config.logger.debug 'Calling API: BillingAgreementsApi.billing_agreements_registration ...' rescue puts 'Cannot write to log' end end # verify the required parameter 'create_billing_agreement' is set if @api_client.config.client_side_validation && create_billing_agreement.nil? fail ArgumentError, "Missing the required parameter 'create_billing_agreement' when calling BillingAgreementsApi.billing_agreements_registration" end # resource path local_var_path = 'pts/v2/billing-agreements' # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/hal+json;charset=utf-8']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json;charset=utf-8']) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(create_billing_agreement) sdk_tracker = SdkTracker.new post_body = sdk_tracker.insert_developer_id_tracker(post_body, 'CreateBillingAgreement', @api_client.config.host) 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 => 'PtsV2CreditsPost201Response1') if @api_client.config.debugging begin raise @api_client.config.logger.debug "API called: BillingAgreementsApi#billing_agreements_registration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" rescue puts 'Cannot write to log' end end return data, status_code, headers end |