Giter Club home page Giter Club logo

ipsp's Introduction

IPSP (PHP) SDK

Payment service provider

A payment service provider (PSP) offers shops online services for accepting electronic payments by a variety of payment methods including credit card, bank-based payments such as direct debit, bank transfer, and real-time bank transfer based on online banking. Typically, they use a software as a service model and form a single payment gateway for their clients (merchants) to multiple payment methods. read more

Quick Start

<?php
require_once 'vendor/autoload.php';

use Ipsp\IpspApi;
use Ipsp\IpspClient;
define('MERCHANT_ID' , 'your_merchant_id');
define('MERCHANT_PASSWORD' , 'test');
define('IPSP_GATEWAY' , 'your_ipsp_gateway');
$client = new Ipsp_Client( MERCHANT_ID , MERCHANT_PASSWORD, IPSP_GATEWAY );
$ipsp   = new Ipsp_Api( $client );

Check response sign

<?php
require_once 'vendor/autoload.php';

use Ipsp\IpspVerification;

define('MERCHANT_ID', 1396424);
define('MERCHANT_PASSWORD', 'test'); 

$verify = new IpspVerification(MERCHANT_ID, MERCHANT_PASSWORD);

echo 'result '; var_dump($verify->check($_POST));

Generate Checkout

<?php
require_once 'vendor/autoload.php';

use Ipsp\IpspApi;
use Ipsp\IpspClient;

define('MERCHANT_ID', 1396424);
define('MERCHANT_PASSWORD', 'test');
define('IPSP_GATEWAY', 'api.fondy.eu');
$client = new IpspClient(MERCHANT_ID, MERCHANT_PASSWORD, IPSP_GATEWAY);
$ipsp = new IpspApi($client);
$data = array(
    'order_id' => time(),
    'order_desc' => 'Order Description',
    'currency' => $ipsp::UAH,
    'amount' => 100, // 1 UAH
    'response_url' => 'http://psr4/callback.php',
    'server_callback_url' => 'http://psr4/callback.php'
);
$data = $ipsp->call('checkout', $data)->getResponse();

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.