Download the PHP package alejobit/placetopay-pse-php without Composer
On this page you can find all versions of the php package alejobit/placetopay-pse-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download alejobit/placetopay-pse-php
More information about alejobit/placetopay-pse-php
Files in alejobit/placetopay-pse-php
Package placetopay-pse-php
Short Description Use PlacetoPay PSE service in your PHP project
License MIT
Informations about the package placetopay-pse-php
PlacetoPay PSE SDK for PHP
Use PlacetoPay PSE service in your PHP project
Requirements
Installattion
Add alejobit/placetopay-pse-php
as a require dependency in your composer.json
file:
For the best operation of the client it is necessary to implement a caching library compatible with the standard PSR-6.
If your project does not have a compatible implementation, you can proceed to install the following library:
Usage
Create a PSE client instance, note that the $login
and $tranKey
are given by PlacetoPay to be able to perform transactions on behalf of a collection site
Setting the PSR-6 cache adapter instance (which must implement Psr\Cache\CacheItemPoolInterface
)
Obtains the list of banks available for the trading establishment in the PSE system of ACH Colombia
This method returns a PlacetoPay\PSE\Struct\ArrayOfBanks
object (which implements \Iterator
and \Countable
interfaces)
Create transactions with the createTransaction()
and createTransactionMultiCredit()
methods:
Load the transaction information as follows:
MultiCredit transactions have an additional method to add credit concepts of the same as follows
Once loaded all the necessary data is sent the transaction with the method send()
The send()
method return a PlacetoPay\PSE\Struct\PSETransactionResponse
with the result of the operation
To obtain the information of a specific transaction can use the method getTransactionInformation($id)
passing the unique identifier of the transaction to consult
Related project
- PlacetoPay PSE Pimple Service Provider, this library is compatible with Pimple based projects, such as the Silex micro-framework