/payu-php-sdk

Public repository to integrate the PayU SDK developed by PayU through composer

Primary LanguagePHPBSD 3-Clause "New" or "Revised" LicenseBSD-3-Clause

PayU PHP SDK

A PHP package to access the PayU API by a comprehensive way.

This is an enhanced version of the original PayU PHP SDK developed by PayU that adds installation through composer, class namespacing and class autoloading instead of the old package full SDK require on initialization.

Installation

The preferred way to install this extension is through composer.

With Composer installed, you can then install the extension using the following commands:

$ php composer.phar require jlorente/payu-php-sdk

or add

...
    "require": {
        "jlorente/payu-php-sdk": "*"
    }

to the require section of your composer.json file.

Configuration

You have to set the configuration on runtime by using the static variables of the PayU class.

PayU::$apiKey = "xxxxxxxxxxxx";
PayU::$apiLogin = "xxxxxxxxxxxx";
PayU::$merchantId = "1";
PayU::$language = SupportedLanguages::ES;
PayU::$isTest = false;

License

Copyright © 2020 José Lorente Martín jose.lorente.martin@gmail.com.

Licensed under the BSD 3-Clause License. See LICENSE.txt for details.