2017 © Pedro PelĂĄez
 

library phaybox

Phaybox is a small library wrote in PHP allowing e-commerce website to interact easily with the Paybox API.

image

keeguon/phaybox

Phaybox is a small library wrote in PHP allowing e-commerce website to interact easily with the Paybox API.

  • Monday, August 26, 2013
  • by Keeguon
  • Repository
  • 1 Watchers
  • 2 Stars
  • 489 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 9 Versions
  • 1 % Grown

The README.md

Phaybox

Phaybox is a small library wrote in PHP allowing e-commerce website to interact easily with the Paybox API., (*1)

Requirements

  • PHP 5.3.x

Installation

Using composer

To install Phaybox with composer you simply need to create a composer.json in your project root and add:, (*2)

{
    "require": {
        "keeguon/phaybox"
    }
}

Then run, (*3)

$ wget --quiet http://getcomposer.org/composer.phar
$ php composer.phar install --install-suggest

You have now Phaybox installed in vendor/friendspray/phaybox, (*4)

And an handy autoload file to include in you project in vendor/.composer/autoload.php, (*5)

Using git

To install Phaybox using git you just have to run the following command:, (*6)

$ git clone https://github.com/Keeguon/Phaybox.git --recursive

Testing

The library is fully tested with PHPUnit for unit tests. To run tests you need PHPUnit installed on your system., (*7)

Go to the base library folder and run the test suites, (*8)

$ phpunit

Code style

How to use

<?php

use Phaybox\Client;
$client = new Client('your_client_id', 'your_client_secret', 'your_client_rang', 'your_client_site', array(
    'algorithm'     => '' // Optional, see hash_algos(), defaults to 'sha512'
  , 'callback'      => '' // Optional, see PBX_RETOUR in the Paybox documentation, defaults to 'Amt:M;Ref:R;Auth:A;Err:E'
  , 'path_prefix'   => '' // Optional, the path which prefix the different phases for HTTP transactions, defaults to 'paybox'
  , 'request_path'  => '' // Optional, the path pointing to the request phase
  , 'callback_path' => '' // Optional, the path pointing to the callback phase
));
$transaction = $client->getTransaction(array(
    'PBX_TOTAL'   => 0000          // required
  , 'PBX_DEVISE'  => 978           // required
  , 'PBX_CMD'     => 'test'        // required
  , 'PBX_PORTEUR' => 'me@mail.com' // required
  , // optional params...
));
$formFields = $transaction->getFormattedParams();

Using the snippets above should provide you the fields you need in your form (you would still have to url encode some of them according to the Paybox documentation)., (*9)

Optional fields will be located at the end but before the HMAC signature and they should be in the same order as you entered them in your form (see 4.3 in Paybox documentation)., (*10)

For more in-depth informations there's an exhaustive example in the the examples folder., (*11)

The Versions

26/08 2013

dev-master

9999999-dev https://github.com/Keeguon/Phaybox

Phaybox is a small library wrote in PHP allowing e-commerce website to interact easily with the Paybox API.

  Sources   Download

MIT

The Requires

  • php >=5.3.2

 

The Development Requires

paybox

26/08 2013

1.2.1

1.2.1.0 https://github.com/Keeguon/Phaybox

Phaybox is a small library wrote in PHP allowing e-commerce website to interact easily with the Paybox API.

  Sources   Download

MIT

The Requires

  • php >=5.3.2

 

The Development Requires

paybox

25/03 2013

1.2.0

1.2.0.0 https://github.com/Keeguon/Phaybox

Phaybox is a small library wrote in PHP allowing e-commerce website to interact easily with the Paybox API.

  Sources   Download

MIT

The Requires

  • php >=5.3.2

 

The Development Requires

paybox

19/07 2012

1.1.5

1.1.5.0 https://github.com/Keeguon/Phaybox

Phaybox is a small library wrote in PHP allowing e-commerce website to interact easily with the Paybox API.

  Sources   Download

MIT

The Requires

  • php >=5.3.2

 

paybox

12/03 2012

1.1.3

1.1.3.0 https://github.com/Keeguon/Phaybox

Phaybox is a small library wrote in PHP allowing e-commerce website to interact easily with the Paybox API.

  Sources   Download

MIT

The Requires

  • php >=5.3.2

 

paybox

06/02 2012

1.1.2

1.1.2.0 https://github.com/Keeguon/Phaybox

Phaybox is a small library wrote in PHP allowing e-commerce website to interact easily with the Paybox API.

  Sources   Download

MIT

The Requires

  • php >=5.3.2

 

paybox

02/02 2012

1.1.1

1.1.1.0 https://github.com/Keeguon/Phaybox

Phaybox is a small library wrote in PHP allowing e-commerce website to interact easily with the Paybox API.

  Sources   Download

MIT

The Requires

  • php >=5.3.2

 

paybox

02/02 2012

1.1.0

1.1.0.0 https://github.com/Keeguon/Phaybox

Phaybox is a small library wrote in PHP allowing e-commerce website to interact easily with the Paybox API.

  Sources   Download

MIT

The Requires

  • php >=5.3.2

 

paybox

02/02 2012

1.0.0

1.0.0.0 https://github.com/Keeguon/Phaybox

Phaybox is a small library wrote in PHP allowing e-commerce website to interact easily with the Paybox API.

  Sources   Download

MIT

The Requires

  • php >=5.3.2

 

paybox