2017 © Pedro Peláez
 

library merchant-esolutions-php

A client library for Merchant e-Solutions' payment gateway and other APIs

image

opendns/merchant-esolutions-php

A client library for Merchant e-Solutions' payment gateway and other APIs

  • Wednesday, November 19, 2014
  • by tabacco
  • Repository
  • 14 Watchers
  • 2 Stars
  • 4,329 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 4 Forks
  • 0 Open issues
  • 4 Versions
  • 6 % Grown

The README.md

Build Status, (*1)

Introduction

merchant-esolutions-php is designed to make it easier to use the various payment APIs provided by Merchant e-Solutions., (*2)

If you find any bugs, or have feature requests, please file an issue in GitHub or open a pull request., (*3)

Installation

Composer

Ensure that composer is installed on your machine. You will need to create a composer.json file in the root directory of your application., (*4)

{
    "require": {
        "opendns/merchant-solutions-php": "~0.1"
    }
}

Once the composer.json file is created, follow these steps from composer to install the merchant-esolutions-php package., (*5)

Composer creates its own autoloader. Include vendor/autoload.php in your application config file and you will have full access to the merchant-esolutions-php client., (*6)

APIs

This readme has a short description of the APIs and an example of each, but there's also a full api reference available on this project's Github page., (*7)

Trident

Trident is the payment gateway API, providing most card operations. A simple transaction might look like this:, (*8)

use OpenDNS\MES\Trident\Sale;

$response = Sale::factory(Sale::ENV_TEST)
    ->setAuthenticationInfo('xxxxxxxxxxx', 'yyyyyyy')
    ->setAmount(13.37)
    ->setCardNumber('3499-999999-99991')
    ->setCardExpiration(12, 2018)
    ->setCvv2(1234)
    ->execute();

echo $response['transaction_id'];

Reporting

The reporting API offers full access to any of the MeS gateway's reports as CSV data. Here's a sample report:, (*9)

use OpenDNS\MES\Reporting\Report;

$response = Report::factory(Report::ENV_PROD)
    ->setAuthenticationInfo('xxxxxxxxxxx', 'yyyyyyy')
    ->setNodeId('zzzzzzzzzz')
    ->setReportId(Report::REPORT_SETTLEMENT_SUMMARY)
    ->setBeginDate(new \DateTime('-1 week', new \DateTimeZone('UTC')))
    ->setEndDate(new \DateTime('now', new \DateTimeZone('UTC')))
    ->setIncludeTridentTransactionId(true)
    ->execute();

$stream = $response->getResponseBodyStream();
while ($row = fgetcsv($stream)) {
    echo implode(',', $row);
}

Recurring Billing

The recurring billing API allows you to create and manage recurring billing profiles., (*10)

Note: If you're building a new application, it's probably better to use the Trident API to store a card and issue additional Sale transactions against it, (*11)

Further Note: The recurring billing API support is experimental, please feel free to open bugs/pull requests if you find yourself using it., (*12)

The Versions

19/11 2014

dev-master

9999999-dev https://github.com/opendns/merchant-esolutions-php

A client library for Merchant e-Solutions' payment gateway and other APIs

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

by Doug Tabacco
by Josh Eveleth

payment credit card mes merchant e-solutions trident

19/11 2014

v0.1.2

0.1.2.0 https://github.com/opendns/merchant-esolutions-php

A client library for Merchant e-Solutions' payment gateway and other APIs

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

by Doug Tabacco
by Josh Eveleth

payment credit card mes merchant e-solutions trident

12/11 2014

v0.1.1

0.1.1.0 https://github.com/opendns/merchant-esolutions-php

A client library for Merchant e-Solutions' payment gateway and other APIs

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

by Doug Tabacco
by Josh Eveleth

payment credit card mes merchant e-solutions trident

11/11 2014

v0.1.0

0.1.0.0 http://github.com/opendns/merchant-esolutions-php

A client library for Merchant e-Solutions' payment gateway and other APIs

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

by Doug Tabacco
by Josh Eveleth

payment credit card mes merchant e-solutions trident