customCheckout()

customCheckout() is a part of SSO integration. Using generated by prepareRemoteAuth url, pass it to customCheckout method.

1. Usage

Example of showing inline checkout inside #my-container element. Also it triggers option for customer to choose offer.

CleengApi.customCheckout({
    displayType: overlay
    customUrl: "https:\/\/cleeng.com\/auth\/2\/purchase?v=2.1&popup=1&remote_token=4a05f0bd07870f4cec92456a7a38452059a4a394:6484554b9bfd9b1609a51f3dcb0b3077d5e11ab6&redirectUri=https%3A%2F%2Fcleeng.com%2Fjs-api%2F2.0%2Fdefault-channel.html&offerId="
    completed : function(result){}
});

2. Params

displayType:choose from popup / inline / overlay
containerId:optional for in-line checkout, otherwise ignored. Put the id of dom element inside where you want to put your checkout.
customUrl:required, generated by prepareRemoteAuth
completed:as a result you receive detailed information about purchase made


Back to API Reference