altapay / api-php
AltaPay: Payments less complicated
Installs: 119 931
Dependents: 2
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 9
Open Issues: 0
Requires
- php: ^5.6 || ^7.0 || ^8.0
- ext-date: *
- ext-filter: *
- ext-mbstring: *
- ext-pcre: *
- ext-reflection: *
- ext-simplexml: *
- ext-spl: *
- guzzlehttp/guzzle: ^6.0 || ^7.0
- symfony/event-dispatcher: ^2.1 || ^3.0 || ^4.0 || ^5.0 || ^6.0 || ^7.0
- symfony/options-resolver: ^2.6 || ^3.0 || ^4.0 || ^5.0 || ^6.0 || ^7.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.0
- fzaninotto/faker: ^1.6
- phpstan/phpstan: ^1.8
- phpstan/phpstan-phpunit: *
- phpstan/phpstan-strict-rules: *
- phpunit/phpunit: ^7.0 || ^8.0 || ^9.0
- dev-main
- 3.4.5
- 3.4.4
- 3.4.3
- 3.4.2
- 3.4.1
- 3.4.0
- 3.3.9
- 3.3.8
- 3.3.7
- 3.3.6
- 3.3.5
- 3.3.4
- 3.3.3
- 3.3.2
- 3.3.1
- 3.3.0
- 3.2.9
- 3.2.8
- 3.2.7
- 3.2.6
- 3.2.5
- 3.2.4
- 3.2.3
- 3.2.2
- 3.2.1
- 3.2.0
- 3.1.1
- 3.1.0
- v3.0.0
- v2.1.0
- v2.0.0
- v1.8.0
- v1.7.0
- v1.6.3
- v1.6.2
- v1.6.1
- v1.6
- v1.5
- v1.4
- v1.3
- v1.2
- v1.1
- v1.0
- dev-update-capture-reservation-response
This package is auto-updated.
Last update: 2024-11-06 06:53:14 UTC
README
For accessing AltaPay payment gateway through the API
Installation
composer require altapay/api-php
Usage
For doing a capture
the following can be used
$auth = new \Altapay\Authentication('username', 'password' , 'myshop.gateway.com'); $api = new \Altapay\Api\Payments\CaptureReservation($auth); $api->setTransactionId('transaction id'); // Or you can use a transaction object you got from a previous API call // $api->setTransaction($transactionObject); try { $response = $api->call(); // If everything went perfect, you will get a \Altapay\Api\Document\Capture in the response } catch (\Altapay\Api\Exceptions\ClientException $e) { // If anything went wrong, you will get a exception where you can see the raw request and the raw response }
Requirements
The AltaPay API PHP requires PHP 5.6.0 or greater with the following extensions installed:
- date
- filter
- mbstring
- pcre
- Reflection
- SimpleXML
- spl
Changelog
See Changelog for all the release notes.
License
Distributed under the MIT License. See LICENSE for more information.
Documentation
For more details please see documentation