Download the PHP package ogunsakindamilola/laravel-interswitch without Composer

On this page you can find all versions of the php package ogunsakindamilola/laravel-interswitch. 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 laravel-interswitch

laravel-interswitch

Latest Stable Version Total Downloads GitHub Actions

A laravel package for Interswitch

Installation

PHP ^7.4|^8.0, and Composer are required.

To get the latest version of Laravel Interswitch, simply require it

Configuration

You can publish the configuration file using this command:

Then select ogunsakin01/laravel-interswitch

A configuration-file named interswitch.php with some sensible defaults will be placed in your config directory:

Open your .env file and add the following

INTERSWITCH_ENV=can be set to eitherLIVEorTEST. INTERSWITCH_GATEWAY=can be set tot eitherWEBPAYorPAYDIRECT. The redirect URL must be a get url declared in your route where you wish to redirect to when a payment process is complete. Make sure this route is defined in your web.php as aGET` route. Make sure to replace the other env variables withe the details you received from Interswitch.

While still in your env file, make sure you set up your database environment Replace the variables with your database connection variables the runphp artisan migrate`. When the migration is complete. Return to your env file and set up your mailing environment

` When this is done, then you can proceed to using this package.

Usage

Interswitch requires you to follow some specific steps when implementing their payment gateway

1 Initiate transaction

This initiate transaction sends a post request to the payment gateway and redirects to the payment page

2 Customer Prepayment Notification Email

You are meant to send a prepayment notification email to your customers informaing them about the transaction they are about to make.

3 Store Transaction Details

You are suppose to store all transactions in db even before they are completed

4 Payment Confirmation Notification Email

You must send a payment confirmation email to your customer stating whether the transaction was successful or not and stating your reasons.

5 Transaction Logs Table and Requery

Interswitch requires that you have a page where all transactions are displayed and that you have a requery button which can be used to reconfirm the status of the transaction.

Phew, life hard. Writing that out alone is exhausting, I can imagine how implementing it will feel like. Don't worry, I know exactly how it feels. Well, on this package, all you have to do is add this on your payment page.

If you wish to use a transaction reference defined by you, simply add <input type="hidden" name="reference" value="87YYUIJIJ" /> to the filed you are sending .

That's it, when the pay button is clicked, all the dirty work is done for you behind the scene. When the payment is complete, you will be redirected to the INTERSWITCH_REDIRECT_URL= you set in your .env with the following query parameters ``

To view your transaction logs, go to this route

That's it, you are good to go

Now that you are here

Thank you for taking your time with my package.


All versions of laravel-interswitch with dependencies

PHP Build Version
Package Version
Requires php Version ^7.4|^8.0
illuminate/support Version ^8.0
doctrine/dbal Version ^2.10
laravel/legacy-factories Version ^1.1
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 ogunsakindamilola/laravel-interswitch contains the following files

Loading the files please wait ....