install-php-sdk-low-code

Install PHP Web SDK

Download the PayU PHP SDK

You can download the PayU PHP SDK from the following GitHub link: https://github.com/payu-intrepos/web-sdk-php.

Build PayU Object

Use the following code snippet to create the instance of the PayU class object:

namespace <namespace_name>;
require_once('PayU.php');
$payu_obj = new PayU();

Set the credentials data and URL using the following code sample:

$payu_obj->env_prod = 0;  //  1 for Live Environment/ 0 for SandBox Environment
    $payu_obj->key = '<key>';
    $payu_obj->salt = '<salt>';

    $res = $payu_obj->initGateway();