class MastercardMasterpassMerchant::Api::ExpressCheckoutApi
Public Class Methods
create(oauth_token, express_checkout_request, api_config = nil)
click to toggle source
Express Checkout
Service This provides qualified merchants with ability to provide the express checkout experience (wherein the consumer does not have to have log into the MasterPass wallet and thereby remains within the merchant experience throughout the transaction) to its MasterPass consumers. @param oauth_token Long access token, which is used to retrieve precheckout data. @param express_checkout_request Express Checkout
Request. @param api_config Optional ApiConfig object specifying configuration : consumer key, private key, host URL. @return [ExpressCheckoutResponse]
# File lib/mastercard_masterpass_merchant/api/express_checkout_api.rb, line 21 def self.create(oauth_token, express_checkout_request, api_config = nil) path = "/masterpass/v6/expresscheckout" service_request = ServiceRequest.new service_request.headers["oauth_token"] = oauth_token service_request.body = express_checkout_request service_request.content_type = "application/xml" api_client = ApiClient.new(api_config) api_client.api_tracker = SdkApiTracker.new api_client.error_handler = ErrorHandler.new return api_client.call(path, service_request, "POST",ExpressCheckoutResponse) end