2017 © Pedro Peláez
 

library gestpayws

PHP implementation of GestPay (Banca Sella) Web Services

image

endelwar/gestpayws

PHP implementation of GestPay (Banca Sella) Web Services

  • Friday, April 13, 2018
  • by endelwar
  • Repository
  • 3 Watchers
  • 6 Stars
  • 225 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 6 Forks
  • 2 Open issues
  • 11 Versions
  • 24 % Grown

The README.md

GestPayWS

License Latest Stable Version Build Status Scrutinizer Code Quality Coverage Status, (*1)

PHP implementation of GestPay (Banca Sella) Web Services, (*2)

Highlights

  • Simple API
  • Decoupled classes
  • PHPUnit tested
  • Framework agnostic
  • Composer ready, PSR-2 and PSR-4 compliant

System Requirements

You need PHP >= 5.6 and the soap extension to use the library, but the latest stable version of PHP is recommended., (*3)

Install

Install EndelWar/GestPayWS using Composer., (*4)

$ composer require endelwar/gestpayws

Using

Crypt

``` php require DIR . '/../vendor/autoload.php';, (*5)

use EndelWar\GestPayWS\WSCryptDecryptSoapClient; use EndelWar\GestPayWS\WSCryptDecrypt; use EndelWar\GestPayWS\Parameter\EncryptParameter; use EndelWar\GestPayWS\Data;, (*6)

// enable or disable test environment $enableTestEnv = true; $soapClient = new WSCryptDecryptSoapClient($enableTestEnv); try { $gestpay = new WSCryptDecrypt($soapClient->getSoapClient()); } catch (\Exception $e) { var_dump($e->getCode(), $e->getMessage()); }, (*7)

// set mandatory info $encryptParameter = new EncryptParameter(); $encryptParameter->shopLogin = 'GESPAY12345'; $encryptParameter->amount = '1.23'; $encryptParameter->shopTransactionId = '1'; $encryptParameter->uicCode = Data\Currency::EUR; $encryptParameter->languageId = Data\Language::ITALIAN;, (*8)

// set optional custom info as array $customArray = array('STORE_ID' => '42', 'STORE_NAME' => 'Shop Abc123'); $encryptParameter->setCustomInfo($customArray);, (*9)

// encrypt data $encryptResult = $gestpay->encrypt($encryptParameter);, (*10)

// get redirect link to Banca Sella echo $encryptResult->getPaymentPageUrl($encryptParameter->shopLogin, $soapClient->wsdlEnvironment);, (*11)


### Decrypt ``` php require __DIR__ . '/../vendor/autoload.php'; use EndelWar\GestPayWS\Parameter\DecryptParameter; use EndelWar\GestPayWS\WSCryptDecryptSoapClient; use EndelWar\GestPayWS\WSCryptDecrypt; // $_GET['a'] and $_GET['b'] are received from Banca Sella $param = array( 'shopLogin' => $_GET['a'], 'CryptedString' => $_GET['b'] ); $decryptParam = new DecryptParameter($param); // enable or disable test environment $enableTestEnv = true; $soapClient = new WSCryptDecryptSoapClient($enableTestEnv); try { $gestpay = new WSCryptDecrypt($soapClient->getSoapClient()); $decryptResult = $gestpay->decrypt($decryptParam); echo $decryptResult->TransactionResult; } catch (\Exception $e) { var_dump($e->getCode(), $e->getMessage()); }

Testing

EndelWar/GestPayWS has a PHPUnit test suite. To run the tests, run the following command from the project folder., (*12)

bash $ vendor/bin/phpunit, (*13)

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

Versioning

Semantic versioning (semver) is applied., (*14)

License

This library is under the MIT license. For the full copyright and license information, please view the LICENSE file that was distributed with this source code., (*15)

The Versions

13/04 2018

dev-master

9999999-dev

PHP implementation of GestPay (Banca Sella) Web Services

  Sources   Download

MIT

The Requires

  • ext-soap *
  • ext-openssl *
  • php >=5.6

 

The Development Requires

by Manuel Dalla Lana

webservice gestpay bancasella

09/02 2018

v1.3.1

1.3.1.0

PHP implementation of GestPay (Banca Sella) Web Services

  Sources   Download

MIT

The Requires

  • php >=5.3.3
  • ext-openssl *
  • ext-soap *

 

The Development Requires

by Manuel Dalla Lana

webservice gestpay bancasella

06/11 2015

v1.3.0

1.3.0.0

PHP implementation of GestPay (Banca Sella) Web Services

  Sources   Download

MIT

The Requires

  • php >=5.3.3
  • ext-openssl *
  • ext-soap *

 

The Development Requires

by Manuel Dalla Lana

webservice gestpay bancasella

23/10 2015

v1.2.1

1.2.1.0

PHP implementation of GestPay (Banca Sella) Web Services

  Sources   Download

MIT

The Requires

  • php >=5.3.3
  • ext-openssl *
  • ext-soap *

 

The Development Requires

by Manuel Dalla Lana

webservice gestpay bancasella

23/10 2015

v1.2.0

1.2.0.0

PHP implementation of GestPay (Banca Sella) Web Services

  Sources   Download

MIT

The Requires

  • php >=5.3.3
  • ext-openssl *
  • ext-soap *

 

The Development Requires

by Manuel Dalla Lana

webservice gestpay bancasella

13/10 2015

v1.1.2

1.1.2.0

PHP implementation of GestPay (Banca Sella) Web Services

  Sources   Download

MIT

The Requires

  • php >=5.3.3
  • ext-openssl *
  • ext-soap *

 

The Development Requires

by Manuel Dalla Lana

webservice gestpay bancasella

08/09 2015

dev-analysis-8LZKkq

dev-analysis-8LZKkq

PHP implementation of GestPay (Banca Sella) Web Services

  Sources   Download

MIT

The Requires

  • php >=5.3.3
  • ext-openssl *
  • ext-soap *

 

The Development Requires

by Manuel Dalla Lana

webservice gestpay bancasella

11/05 2015

v1.1.1

1.1.1.0

PHP implementation of GestPay (Banca Sella) Web Services

  Sources   Download

MIT

The Requires

  • php >=5.3.3
  • ext-openssl *
  • ext-soap *

 

The Development Requires

by Manuel Dalla Lana

webservice gestpay bancasella

11/05 2015

v1.1.0

1.1.0.0

PHP implementation of GestPay (Banca Sella) Web Services

  Sources   Download

MIT

The Requires

  • php >=5.3.3
  • ext-openssl *
  • ext-soap *

 

The Development Requires

by Manuel Dalla Lana

gestpay bancasella

31/03 2015

v1.0.0

1.0.0.0

PHP implementation of GestPay (Banca Sella) Web Services

  Sources   Download

MIT

The Requires

  • php >=5.3.3
  • ext-soap *

 

The Development Requires

by Manuel Dalla Lana

gestpay bancasella

31/03 2015

v0.1.0

0.1.0.0

PHP implementation of GestPay (Banca Sella) Web Services

  Sources   Download

MIT

The Requires

  • php >=5.3.3
  • ext-soap *

 

The Development Requires

by Manuel Dalla Lana

gestpay bancasella