Download the PHP package mammutgroup/gateway without Composer

On this page you can find all versions of the php package mammutgroup/gateway. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package gateway

package's home : larabook.ir

by this package we are able to connect to all Iranian bank with one unique API.

Please inform us once you've encountered bug or issue .

Available Banks:

  1. MELLAT
  2. SADAD
  3. PARSIAN
  4. PASARGAD
  5. ZARINPAL
  6. JAHANPAY
  7. PAYLINE

SAMAN bank will be added asap.


Installation:

Run below statements on your terminal :

STEP 1 :

composer require larabook/gateway

STEP 2 : Add provider and facade in config/app.php

'providers' => [
  ...
  Larabookir\Gateway\GatewayServiceProvider::class, // <-- add this line at the end of provider array
],

'aliases' => [
  ...
  'Gateway' => Larabookir\Gateway\Gateway::class, // <-- add this line at the end of aliases array
]

Step 3:

php artisan vendor:publish --provider="Larabookir\Gateway\GatewayServiceProvider"

Step 4:

php artisan migrate

Configuration file is placed in config/gateway.php , open it and enter your banks credential:

You can make connection to bank by several way (Facade , Service container):

try {

   $gateway = \Gateway::make(new \Mellat());
   // $gateway->setCallback(url('/path/to/calback/route')); You can also change the callback
   $gateway->price(1000)->ready();
   $refId =  $gateway->refId();
   $transID = $gateway->transactionId();

   // Your code here

   return $gateway->redirect();

} catch (Exception $e) {

    echo $e->getMessage();
}

you can call the gateway by these ways :

  1. Gateway::make(new Mellat());
  2. Gateway::mellat()
  3. app('gateway')->make(new Mellat());
  4. app('gateway')->mellat();

Instead of MELLAT you can enter other banks Name as we introduced above .

In set method you should enter the price in IRR (RIAL)

and in your callback :

try { 

   $gateway = \Gateway::verify();
   $trackingCode = $gateway->trackingCode();
   $refId = $gateway->refId();
   $cardNumber = $gateway->cardNumber();

   // Your code here

} catch (Exception $e) {

   echo $e->getMessage();
}  

If you are intrested to developing this package you can help us by these ways :

  1. Improving documents.
  2. Reporting issue or bugs.
  3. Collaboration in writing codes and other banks modules.

This package is extended from PoolPort but we've changed some functionality and improved it .


All versions of gateway with dependencies

PHP Build Version
Package Version
Requires nesbot/carbon Version ~1.20
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package mammutgroup/gateway contains the following files

Loading the files please wait ....