ticketpark / saferpay-json-api
A php library to use the json api of Saferpay
Installs: 227 492
Dependents: 1
Suggesters: 1
Security: 0
Stars: 32
Watchers: 6
Forks: 25
Open Issues: 1
Requires
- php: ~7.4|~8.0.0|~8.1.0|~8.2.0|~8.3.0
- doctrine/annotations: ^1.11|^2.0
- guzzlehttp/guzzle: ^6.3|^7.0
- jms/serializer: ^3.16
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.16
- phpstan/phpstan: ^1.6
- phpunit/phpunit: ^9.0
- rector/rector: ^1.1
This package is auto-updated.
Last update: 2024-10-26 15:29:11 UTC
README
A php library to use the Saferpay Json API.
Installation
Add the library in your composer.json:
composer require ticketpark/saferpay-json-api
Usage
In order to perform a payment as you would typically do it in an online shop, you need to handle the following steps:
- Initialize the payment page (see /example/PaymentPage/example-initialize.php)
- Redirect the user to the payment page and let them enter their payment data
- Assert that the payment was successfully done (see /example/PaymentPage/example-assert.php)
- Capture the payment to make it final (see /example/Transaction/example-capture.php)
Have a look at the example folder for more.
Documentation
This library is currently based on v1.40 of the Saferpay JSON API.
Find the most current documentation of the Saferpay JSON API here:
https://saferpay.github.io/jsonapi/
Contribution
You are welcome to contribute to this repo.