PayPro gateway for Omnipay

dev-master / 0.1.x-dev 2015-06-01 12:54 UTC

This package is not auto-updated.

Last update: 2024-04-13 15:39:20 UTC


PayPro gateway for the Omnipay PHP payment processing library

Software License Build Status

Omnipay is a framework agnostic, multi-gateway payment processing library for PHP 5.3+. This package implements paypro support for Omnipay.

This is where your description should go. Try and limit it to a paragraph or two, and maybe throw in a mention of what PSRs you support to avoid any confusion with users and contributors.


This gateway can be installed with Composer:

$ composer require paypronl/omnipay-paypro:0.1.x@dev


The following gateways are provided by this package:

  • PayPro


require_once  __DIR__ . '/vendor/autoload.php';

use Omnipay\Omnipay;

/** @var \Omnipay\PayPro\Gateway $gateway */
$gateway = Omnipay::create('PayPro');

    'apiKey' => 'YOUR API KEY HERE',
    'productId' => null,
    'testMode' => true,

$params = array(
    'amount' => 12.34,
    'description' => 'Payment test',
    'returnUrl' => '',
    'notifyUrl' => '', //see
    'transactionId' => 'abc12345',
    'issuer' => 'ideal/RABONL2U',
    'productId' => 12345,
    'card' => array(
        'email' => '',
        'name' => 'My name',

$response = $gateway->purchase($params)->send();

if ($response->isSuccessful()) {
    echo 'Success!';
} elseif ($response->isRedirect()) {
} else {
    echo 'Failed';

For general usage instructions, please see the main Omnipay repository.


You can set the following parameters:

  • apiKey (required): The Api Key
  • amount (required): The amount, as float/decimal
  • productId: Your product Id
  • description: The order description
  • transactionId: A custom transactionId
  • issuer: A payment method, see for all pay methods (select get_all_pay_methods)
  • vat: The VAT percentage
  • returnUrl: The URL to show after payment has been completed.
  • notifyUrl: The URL to post the status to (postback url)
  • testMode: Boolean to indicate testing.

Card information

You can set the following information, using the Card object.

  • name / firstName + lastName
  • email
  • address1 / billingAddress1
  • address2 / billingAddress2
  • postcode / billingPostcode
  • city / billingCity
  • country / billingCountry

See for more information.

Payment methods

You can get all available payment methods with fetchPaymentMethods() and the available issuers for all methods with fetchIssuers(). The Issuer ID can be passed to the purchase() method to directly configure the payment method.

$methods = $gateway->fetchPaymentMethods()->send()->getPaymentMethods();

/** @var \Omnipay\Common\PaymentMethod $method */
foreach ($methods as $method) {
    echo $method->getId();
    echo $method->getName();

$issuers = $gateway->fetchIssuers()->send()->getIssuers();

/** @var \Omnipay\Common\Issuer $issuer */
foreach ($issuers as $issuer) {
    echo $issuer->getId();
    echo $issuer->getName();
    echo $issuer->getPaymentMethod();


If you are having general issues with Omnipay, we suggest posting on Stack Overflow. Be sure to add the omnipay tag so it can be easily found.

If you want to keep up to date with release anouncements, discuss ideas for the project, or ask more detailed questions, there is also a mailing list which you can subscribe to.

If you believe you have found a bug, please report it using the GitHub issue tracker, or better yet, fork the library and submit a pull request.

Change log

Please see CHANGELOG for more information what has changed recently.


$ composer test


Please see CONTRIBUTING for details.


If you discover any security related issues, please email instead of using the issue tracker.



The MIT License (MIT). Please see License File for more information.