Class: CyberSource::MerchantBoardingApi
- Inherits:
-
Object
- Object
- CyberSource::MerchantBoardingApi
- Defined in:
- lib/cybersource_rest_client/api/merchant_boarding_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#get_registration(registration_id, opts = {}) ⇒ InlineResponse2005
Gets all the information on a boarding registration This end point will get all information of a boarding registration.
-
#get_registration_with_http_info(registration_id, opts = {}) ⇒ Array<(InlineResponse2005, Fixnum, Hash)>
Gets all the information on a boarding registration This end point will get all information of a boarding registration.
-
#initialize(api_client = ApiClient.default, config) ⇒ MerchantBoardingApi
constructor
A new instance of MerchantBoardingApi.
-
#patch_registration(registration_id, patch_registration_body, opts = {}) ⇒ InlineResponse2005
Updates the information on a boarding registration This end point will partially update a boarding registration.
-
#patch_registration_with_http_info(registration_id, patch_registration_body, opts = {}) ⇒ Array<(InlineResponse2005, Fixnum, Hash)>
Updates the information on a boarding registration This end point will partially update a boarding registration.
-
#post_registration(post_registration_body, opts = {}) ⇒ InlineResponse2017
Create a boarding registration Boarding Product is specifically for resellers who onboard merchants to resell their services to merchants and help integrate REST API into their systems.
-
#post_registration_with_http_info(post_registration_body, opts = {}) ⇒ Array<(InlineResponse2017, Fixnum, Hash)>
Create a boarding registration Boarding Product is specifically for resellers who onboard merchants to resell their services to merchants and help integrate REST API into their systems.
Constructor Details
#initialize(api_client = ApiClient.default, config) ⇒ MerchantBoardingApi
Returns a new instance of MerchantBoardingApi.
18 19 20 21 |
# File 'lib/cybersource_rest_client/api/merchant_boarding_api.rb', line 18 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.
16 17 18 |
# File 'lib/cybersource_rest_client/api/merchant_boarding_api.rb', line 16 def api_client @api_client end |
Instance Method Details
#get_registration(registration_id, opts = {}) ⇒ InlineResponse2005
Gets all the information on a boarding registration This end point will get all information of a boarding registration
29 30 31 32 |
# File 'lib/cybersource_rest_client/api/merchant_boarding_api.rb', line 29 def get_registration(registration_id, opts = {}) data, status_code, headers = get_registration_with_http_info(registration_id, opts) return data, status_code, headers end |
#get_registration_with_http_info(registration_id, opts = {}) ⇒ Array<(InlineResponse2005, Fixnum, Hash)>
Gets all the information on a boarding registration This end point will get all information of a boarding registration
39 40 41 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 98 99 100 101 102 103 104 |
# File 'lib/cybersource_rest_client/api/merchant_boarding_api.rb', line 39 def get_registration_with_http_info(registration_id, opts = {}) if @api_client.config.debugging begin raise @api_client.config.logger.debug 'Calling API: MerchantBoardingApi.get_registration ...' rescue puts 'Cannot write to log' end end # verify the required parameter 'registration_id' is set if @api_client.config.client_side_validation && registration_id.nil? fail ArgumentError, "Missing the required parameter 'registration_id' when calling MerchantBoardingApi.get_registration" end # resource path local_var_path = 'boarding/v1/registrations/{registrationId}'.sub('{' + 'registrationId' + '}', registration_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/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = {} # http body (model) if 'GET' == 'POST' post_body = '{}' else post_body = nil end inbound_mle_status = "mandatory" if MLEUtility.check_is_mle_for_API(@api_client.merchantconfig, inbound_mle_status, ["get_registration","get_registration_with_http_info"]) begin post_body = MLEUtility.encrypt_request_payload(@api_client.merchantconfig, post_body) rescue raise end end is_response_mle_for_api = MLEUtility.check_is_response_mle_for_api(@api_client.merchantconfig, ["get_registration","get_registration_with_http_info"]) auth_names = [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'InlineResponse2005', :isResponseMLEForApi => is_response_mle_for_api) if @api_client.config.debugging begin raise @api_client.config.logger.debug "API called: MerchantBoardingApi#get_registration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" rescue puts 'Cannot write to log' end end return data, status_code, headers end |
#patch_registration(registration_id, patch_registration_body, opts = {}) ⇒ InlineResponse2005
Updates the information on a boarding registration This end point will partially update a boarding registration
114 115 116 117 |
# File 'lib/cybersource_rest_client/api/merchant_boarding_api.rb', line 114 def patch_registration(registration_id, patch_registration_body, opts = {}) data, status_code, headers = patch_registration_with_http_info(registration_id, patch_registration_body, opts) return data, status_code, headers end |
#patch_registration_with_http_info(registration_id, patch_registration_body, opts = {}) ⇒ Array<(InlineResponse2005, Fixnum, Hash)>
Updates the information on a boarding registration This end point will partially update a boarding registration
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 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 |
# File 'lib/cybersource_rest_client/api/merchant_boarding_api.rb', line 126 def patch_registration_with_http_info(registration_id, patch_registration_body, opts = {}) if @api_client.config.debugging begin raise @api_client.config.logger.debug 'Calling API: MerchantBoardingApi.patch_registration ...' rescue puts 'Cannot write to log' end end # verify the required parameter 'registration_id' is set if @api_client.config.client_side_validation && registration_id.nil? fail ArgumentError, "Missing the required parameter 'registration_id' when calling MerchantBoardingApi.patch_registration" end # verify the required parameter 'patch_registration_body' is set if @api_client.config.client_side_validation && patch_registration_body.nil? fail ArgumentError, "Missing the required parameter 'patch_registration_body' when calling MerchantBoardingApi.patch_registration" end # resource path local_var_path = 'boarding/v1/registrations/{registrationId}'.sub('{' + 'registrationId' + '}', registration_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/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) header_params[:'v-c-idempotency-id'] = opts[:'v_c_idempotency_id'] if !opts[:'v_c_idempotency_id'].nil? # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(patch_registration_body) sdk_tracker = SdkTracker.new post_body = sdk_tracker.insert_developer_id_tracker(post_body, 'PatchRegistrationBody', @api_client.config.host, @api_client.merchantconfig.defaultDeveloperId) inbound_mle_status = "optional" if MLEUtility.check_is_mle_for_API(@api_client.merchantconfig, inbound_mle_status, ["patch_registration","patch_registration_with_http_info"]) begin post_body = MLEUtility.encrypt_request_payload(@api_client.merchantconfig, post_body) rescue raise end end is_response_mle_for_api = MLEUtility.check_is_response_mle_for_api(@api_client.merchantconfig, ["patch_registration","patch_registration_with_http_info"]) 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 => 'InlineResponse2005', :isResponseMLEForApi => is_response_mle_for_api) if @api_client.config.debugging begin raise @api_client.config.logger.debug "API called: MerchantBoardingApi#patch_registration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" rescue puts 'Cannot write to log' end end return data, status_code, headers end |
#post_registration(post_registration_body, opts = {}) ⇒ InlineResponse2017
Create a boarding registration Boarding Product is specifically for resellers who onboard merchants to resell their services to merchants and help integrate REST API into their systems. The Boarding API is designed to simplify and streamline the onboarding process of merchants by enabling administrators and developers to: 1. Enable and Configure Products: The API helps in adding new products to an existing organization and configuring them to suit specific needs. 2. Update Merchant Information: The API allows for updating an organization's information efficiently. 3. Manage Payment Integration: It provides templates for secure payment integration and management.
203 204 205 206 |
# File 'lib/cybersource_rest_client/api/merchant_boarding_api.rb', line 203 def post_registration(post_registration_body, opts = {}) data, status_code, headers = post_registration_with_http_info(post_registration_body, opts) return data, status_code, headers end |
#post_registration_with_http_info(post_registration_body, opts = {}) ⇒ Array<(InlineResponse2017, Fixnum, Hash)>
Create a boarding registration Boarding Product is specifically for resellers who onboard merchants to resell their services to merchants and help integrate REST API into their systems. The Boarding API is designed to simplify and streamline the onboarding process of merchants by enabling administrators and developers to: 1. Enable and Configure Products: The API helps in adding new products to an existing organization and configuring them to suit specific needs. 2. Update Merchant Information: The API allows for updating an organization's information efficiently. 3. Manage Payment Integration: It provides templates for secure payment integration and management.
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 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 |
# File 'lib/cybersource_rest_client/api/merchant_boarding_api.rb', line 214 def post_registration_with_http_info(post_registration_body, opts = {}) if @api_client.config.debugging begin raise @api_client.config.logger.debug 'Calling API: MerchantBoardingApi.post_registration ...' rescue puts 'Cannot write to log' end end # verify the required parameter 'post_registration_body' is set if @api_client.config.client_side_validation && post_registration_body.nil? fail ArgumentError, "Missing the required parameter 'post_registration_body' when calling MerchantBoardingApi.post_registration" end # resource path local_var_path = 'boarding/v1/registrations' # 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[:'v-c-idempotency-id'] = opts[:'v_c_idempotency_id'] if !opts[:'v_c_idempotency_id'].nil? # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(post_registration_body) sdk_tracker = SdkTracker.new post_body = sdk_tracker.insert_developer_id_tracker(post_body, 'PostRegistrationBody', @api_client.config.host, @api_client.merchantconfig.defaultDeveloperId) inbound_mle_status = "optional" if MLEUtility.check_is_mle_for_API(@api_client.merchantconfig, inbound_mle_status, ["post_registration","post_registration_with_http_info"]) begin post_body = MLEUtility.encrypt_request_payload(@api_client.merchantconfig, post_body) rescue raise end end is_response_mle_for_api = MLEUtility.check_is_response_mle_for_api(@api_client.merchantconfig, ["post_registration","post_registration_with_http_info"]) 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 => 'InlineResponse2017', :isResponseMLEForApi => is_response_mle_for_api) if @api_client.config.debugging begin raise @api_client.config.logger.debug "API called: MerchantBoardingApi#post_registration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" rescue puts 'Cannot write to log' end end return data, status_code, headers end |