midsonlajeanty/php-moncash-sdk

Minimum SDK to process payment with Digicel Moncash Payment Gateway

1.0.1 2024-09-13 15:55 UTC

This package is auto-updated.

Last update: 2025-06-13 17:43:40 UTC


README

Moncash Logo

Build Status Total Downloads Latest Stable Version License

Minimum SDK to process payment with Digicel Moncash Payment Gateway

Features

  • Create Payment Transaction and get gateway URL (Moncash Checkout)
  • Get Transaction Details by Transaction and Order ID

Getting started

composer require midsonlajeanty/php-moncash-sdk 

Usage

Init Payment and get Payment URL (Moncash Checkout)

// Init Payment
use Mds\Moncash\Moncash;

// Create Moncash Instance
$moncash = new Moncash(CLIENT_ID, CLIENT_SECRET);

// Make Paiment with OrderId and Amount
$payment = $moncash->makePayment('ORDER-001', 100);

// Get Payment URL  (Moncash Checkout)
$payment->getRedirect();

Get Transaction Details by Transaction and Order ID

// Init Payment
use Mds\Moncash\Moncash;

// Create Moncash Instance
$moncash = new Moncash(CLIENT_ID, CLIENT_SECRET);

// Get Payment Details with TransactionId provided by Moncash.
$details = $moncash->getPaymentDetailsByTransactionId('TRANSACTION_ID');

// Get Payment Details with OrderId provided by your app.
$details = $moncash->getPaymentDetailsByOrderId('ORDER_ID');

Contributing

You have a lot of options to contribute to this project ! You can :