RKFL Payment Widget

RKFL JS CDN and Implementation

  • Add the script from CDN to the Merchant site.

  • Once we get the response with the UUID from the backend. We will initialize an object of the above-included script. We pass the following :

    • uuid

    • callback function

    • environment

    • Token

Copy

    const  uuidInfo = JSON.parse(result);
   
     if(uuidInfo.error !== undefined){
        alert("Order placement failed");
        return  false;
    }
    
    uuid = uuidInfo.uuid;
    
    rkfl = new RocketFuel({
        uuid,
        callback:  callBackFunc,
        environment:  "<%= developmentEnv %>"  // prod, preprod
    });
  • After initialising the object, start the payment by calling the initPayment method of the above script.

Copy

  • Callback payload

Copy

Last updated

Was this helpful?