2017 © Pedro Peláez
 

library omnitest

Omnipay Payment Gateway

image

adee2210/omnitest

Omnipay Payment Gateway

  • Saturday, May 30, 2015
  • by adee2210
  • Repository
  • 1 Watchers
  • 0 Stars
  • 14 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

omnitest

Gateway Operations, (*1)

Operation Decription
ccPurchase Allow you to test Payment Gateway without transfer money.

ccPurchase elements, (*2)

Element Child Element Required Type Description
sid --- Yes String Site id (unique identifier for the web site)
rcode --- Yes String Site RCODE
country --- Yes String Country of the user - will provide the list of payments available for that country
addfee --- No Boolean This will add the processing fees on top of the amount.
cart --- Yes Array Information about the purchase items. This is only compulsory for feeapi, do not sent the cart to rawfeeapi.
summary amount Yes Float Contains a summary of price amount (without commas and only 2 decimals places)
summary quantity Yes Integer Contains a summary of cart quantity
currency_code --- Yes String 3 digit currency code
items --- Yes Array Contains the cart items
--- (numerical index) Yes Array Contains information about one item in the cart (Repeat until all cart items are listed)
--- name Yes String Category, can be used freely
--- quantity Yes Integer Quantity of the item
--- amount_unit Yes String Unit price amount (without commas and only 2 decimals places)
--- item_no Yes String Article number
--- item_desc Yes String Item description

Installation, (*3)

composer require adee2210/omnitest:dev-master

How to use, (*4)

Step 1 : Initialize, (*5)

$gateway = new Adee2210\Omnitest\Gateway;

Step 2 : Call Gateway Operation (ie. ccPurchase), (*6)

$args = $gateway->getConfig(array('run' => 'ccPurchase'));

Step 3 : Get all Operation fields, (*7)

$Fields = $args['args'];
$OptionalField = $args['optional'];

Step 4 : Post variable or Get Gateway result, (*8)

$response = $gateway->postForm('ccPurchase', $app['request']->request->all());

Response, (*9)

Success, (*10)

[ { "mxsid": "10146", "payby": "bpay", "title": "BPay", "display_title": null, "description": null, "transfertime": null, "transferlimit": null, "currency_code": "AUD", "currency_symbol": "$", "image": "--Logo URL--", "fee": { "srccode": "AUD", "destcode": "USD", "rate": 0.96801106010318, "effectivedate": "2011-04-04",  "flatfee": 3, "mdr": 1 }, "fields": { "card_no": { "description": "", "type": "hidden", "value": "70720297711", "title": "" }, "description": { "description": "", "type": "span", "value": "--HTML String--" }, } }]

Fail, (*11)

{"status":"EXC","msg":"Some error message here"}

The Versions

30/05 2015

dev-master

9999999-dev

Omnipay Payment Gateway

  Sources   Download

MIT

The Requires

 

by Adel Waehayi