Novanet driver for the Omnipay payment processing library
novalnet/omnipay is a Laravel package for novanet driver for the omnipay payment processing library.
It currently has 0 GitHub stars and 19.054 downloads on Packagist (latest version 1.0.0).
Install it with composer require novalnet/omnipay.
Discover more Laravel packages by novalnet
or browse all Laravel packages to compare alternatives.
Last updated
Omnipay is a payment processing library for PHP. It has been designed based on ideas from Active Merchant, plus experience implementing dozens of gateways for CI Merchant. It has a clear and consistent API, is fully unit tested, and even comes with an example application to get you started.
The preferred way to install the library is using a composer. Run the composer required to add dependencies to composer.json:
composer require novalnet/omnipay
<?php
use Novalnet\Omnipay\Gateway;
require '../vendor/autoload.php';
try {
$data['customer'] = [
'first_name' => 'novalnet',
'last_name' => 'tester',
'email' => '[email protected]',
'customer_no' => '147',
'billing' => [
'street' => 'Feringastraße',
'house_no' => '4',
'city' => 'Unterföhring',
'zip' => '85774',
'country_code' => 'DE',
]
];
$data['transaction'] = [
'test_mode' => 1,
'payment_type' => 'DIRECT_DEBIT_SEPA',
'amount' => '1500',
'currency' => 'EUR',
'order_no' => '123456',
'payment_data' => [
'account_holder' => '###ACCOUNT_HOLDER###',
'iban' => '###IBAN###',
]
];
$data['custom'] = [
'lang' => 'EN'
];
$gateway = new Gateway();
$gateway->setPaymentAccessKey('###YOUR_PAYMENT_ACCESS_KEY###'); // Merchant need to provide the payment access key
$gateway->setSignature('###YOUR_API_SIGNATURE###'); // Merchant need to provide the Product activation key
$gateway->setTariff('###YOUR_TARIFF_ID###'); // Merchant need to provide the tariff id
$response = $gateway->authorize($data)->send();
if ($response->isSuccessful()) {
print_r($response->getData());
} elseif ($response->isRedirect()) {
$response->redirect();
} else {
echo $response->getMessage();
}
} catch (\Exception $e) {
throw $e;
}
Please find the relevant information about to load iframe credit/debit card form and to get the encrypted credit card values (pan_hash & unique_id) to process the payment developer portal.
<?php
use Novalnet\Omnipay\Gateway;
require '../vendor/autoload.php';
try {
$data['customer'] = [
'first_name' => 'novalnet',
'last_name' => 'tester',
'email' => '[email protected]',
'customer_no' => '147',
'billing' => [
'street' => 'Feringastraße',
'house_no' => '4',
'city' => 'Unterföhring',
'zip' => '85774',
'country_code' => 'DE',
]
];
$data['transaction'] = [
'test_mode' => 1,
'payment_type' => 'CREDITCARD',
'amount' => '1500',
'currency' => 'EUR',
'order_no' => '123456',
'return_url' => 'https://omnipay.novalnet.de/samples/payment/purchase.php', // Adapt your own return url (only for 3D secure)
'payment_data' => [
'pan_hash' => '###PAN_HASH###', // To store Novalnet's unique identifier for the given payment data
'unique_id' => '###UNIQUE_ID###' // To store the random id which belongs to a particular pan_hash
]
];
$data['custom'] = [
'lang' => 'EN'
];
$gateway = new Gateway();
$gateway->setPaymentAccessKey('###YOUR_PAYMENT_ACCESS_KEY###'); // Merchant need to provide the payment access key
$gateway->setSignature('###YOUR_API_SIGNATURE###'); // Merchant need to provide the Product activation key
$gateway->setTariff('###YOUR_TARIFF_ID###'); // Merchant need to provide the tariff id
$response = empty($_REQUEST['tid'])
? $gateway->authorize($data)->send()
: $gateway->completeAuthorize($_REQUEST)->send();
if ($response->isSuccessful()) {
print_r($response->getData());
} elseif ($response->isRedirect()) {
$response->redirect();
} else {
echo $response->getMessage();
}
} catch (\Exception $e) {
throw $e;
}
<?php
use Novalnet\Omnipay\Gateway;
require '../vendor/autoload.php';
try {
$data['customer'] = [
'first_name' => 'novalnet',
'last_name' => 'tester',
'email' => '[email protected]',
'customer_no' => '147',
'billing' => [
'street' => 'Feringastraße',
'house_no' => '4',
'city' => 'Unterföhring',
'zip' => '85774',
'country_code' => 'DE',
]
];
$data['transaction'] = [
'test_mode' => 1,
'payment_type' => 'ONLINE_BANK_TRANSFER',
'amount' => '1500',
'currency' => 'EUR',
'order_no' => '123456',
'return_url' => 'https://omnipay.novalnet.de/samples/payment/purchase.php', // Adapt your own return url
];
$data['custom'] = [
'lang' => 'EN'
];
$gateway = new Gateway();
$gateway->setPaymentAccessKey('###YOUR_PAYMENT_ACCESS_KEY###'); // Merchant need to provide the payment access key
$gateway->setSignature('###YOUR_API_SIGNATURE###'); // Merchant need to provide the Product activation key
$gateway->setTariff('###YOUR_TARIFF_ID###'); // Merchant need to provide the tariff id
$response = empty($_REQUEST['tid'])
? $gateway->purchase($data)->send()
: $gateway->completePurchase($_REQUEST)->send();
if ($response->isSuccessful()) {
print_r($response->getData());
} elseif ($response->isRedirect()) {
$response->redirect();
} else {
echo $response->getMessage();
}
} catch (\Exception $e) {
throw $e;
}
<?php
use Novalnet\Omnipay\Gateway;
require '../vendor/autoload.php';
try {
$data['transaction'] = [
'tid' => '14597800007520313',
'amount' => '100',
'reason' => ''
];
$data['custom'] = [
'lang' => 'EN'
];
$gateway = new Gateway();
$gateway->setPaymentAccessKey('###YOUR_PAYMENT_ACCESS_KEY###'); // Merchant need to provide the payment access key
$response = $gateway->refund($data)->send();
if ($response->isSuccessful()) {
print_r($response->getData());
} else {
echo $response->getMessage();
}
} catch (\Exception $e) {
throw $e;
}
<?php
use Novalnet\Omnipay\Gateway;
require '../vendor/autoload.php';
try {
$gateway = new Gateway();
$gateway->setPaymentAccessKey('###YOUR_PAYMENT_ACCESS_KEY###'); // Merchant need to provide the payment access key
$gateway->setTestMode(false);
$gateway->handleWebhookNotification();
} catch (\Exception $e) {
throw $e;
}
For Webhook synchronization, add the above code in your webhook handler file
For more information about payment integration see the developer portal. Please find the relevant documentation about payment integration there.
See our License Agreement at: https://www.novalnet.com/payment-plugins-free-license/
For more information about the omni Payment Integration by Novalnet, please get in touch with us: [email protected] or +49 89 9230683-20
Novalnet AG
Zahlungsinstitut (ZAG)
Gutenbergstraße 7
D-85748 Garching
Deutschland
E-mail: [email protected]
Tel: +49 89 9230683-20
Web: www.novalnet.de
Novalnet AG is a leading financial service institution offering payment gateways for processing online payments. Operating in the market as a full payment service provider Novalnet AG provides online merchants user-friendly payment integration with all major shop systems and self-programmed sites.
Accept, manage and monitor payments all on one platform with one single contract!
Our SaaS engine is PCI DSS certified and designed to enable real-time risk management, secured payments via escrow accounts, efficient receivables management, dynamic member and subscription management, customized payment solutions for various business models (e.g. marketplaces, affiliate programs etc.) etc.