A php library to use the json api of Saferpay

v4.4 2023-05-09 14:38 UTC

This package is auto-updated.

Last update: 2023-09-09 16:06:50 UTC


Build Status

A php library to use the Saferpay Json API.


Add the library in your composer.json:

composer require ticketpark/saferpay-json-api


In order to perform a payment as you would typically do it in an online shop, you need to handle the following steps:

  1. Initialize the payment page (see /example/PaymentPage/example-initialize.php)
  2. Redirect the user to the payment page and let them enter their payment data
  3. Assert that the payment was successfully done (see /example/PaymentPage/example-assert.php)
  4. Capture the payment to make it final (see /example/Transaction/example-capture.php)

Have a look at the example folder for more.


Find the most current documentation of the Saferpay JSON API here:

This library is currently based on v1.20 of the Saferpay JSON API.


You are welcome to contribute to this repo.