Download the PHP package mazimez/laravel-gigapay without Composer

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

Laravel-Gigapay

A simple API wrapper for Gigapay's APIs. It gives you helper methods that will make your work with gigapay's API easy, fast and efficient

Laravel-Gigapay manage resources like Employees, Invoices, Payouts, Pricing and Webhooks.

It uses the APIs provided by Gigapay, here is it's API documentation

You can also look into the postman collection to call the API by yourself to better understand it.

To understand the Event flow of Gigapay, you can see it's Event Documentation

Table of contents

Installation

Install the package via composer:

composer require mazimez/laravel-gigapay

Publish the config file:

php artisan vendor:publish --provider="Mazimez\Gigapay\GigapayServiceProvider"

Configuration

The published config file config/gigapay.php looks like:

once the config file is ready, you need to add some variables into your .env file. there are 4 variables

keep in mind that Gigapay has separate token and integration id for each server, so whenever you switch server, remember to update SERVER URL with tokens and integration id too.

Employee

An Employee is an individual performing tasks within your organization, employed or sub-contracted by Gigapay. To add an Employee to your organization you can create an Employee object. The Employee will be notified and Gigapay will verify their identity and working permits. you can learn more about that from Gigapay doc

employee-creation

the getJson() method will return the Employee's object in JSON format

employee-update

employee-list

The Employee::list() method will return the Gigapay doc

employee-retrieve

You can retrieve any employee by it's id. you can get more info from Gigapay doc

employee-replace

Replacing any Employee will actually change the ID of that employee as well as all the data of that employee with the data you have provided. keep in mind that other connect with this employee (like it's payouts) will still stay connected to it. so here you are not creating a new employee, you can just replace an existing employee with new data. refer to Gigapay doc for more info.

employee-delete

You can delete any employee by calling the destroy method on Employee instance but we can not delete an Employee after a Payout has been registered to it. get for info from Gigapay doc

employee-resend

Employee will get 1 email to join, on the mail-id that we provided while creating the Employee, we can also resend that mail in case something gets wrong. After resending, you need to wait at least 24 hours before resending again. get for info from Gigapay doc

employee-helper

There are some helper methods that you can use on employee instance. for example:

Payout

To make a payout to an Employee you need to create a Payout object. The Employee is notified of the Payout once the corresponding Invoice is paid. The Employee will need to sign and accept the Payout before it is disbursed to their account. you can learn more about that from Gigapay doc

payout-creation

the getJson() method will return the Payout's object in JSON format

payout-inline-creation

payout-multiple-creation

payout-list

The Payout::list() method will return the Gigapay doc

payout-retrieve

You can retrieve any payout by it's id. you can get more info from Gigapay doc

payout-delete

You can delete any payout by calling the destroy method on Payout instance but we can not delete a payout belonging to a paid Invoice or an Invoice on credit. get more info from Gigapay doc

payout-resend

Once the Payout is been paid, Employee should get the mail about his/her payout. you can also resend the mail using the resend() method on payout instance. keep in mind that mail can only be sent once the Payout has been paid. get more info from Gigapay doc

payout-helper

There are some helper methods that you can use on payout instance. for example:

you can also chain this method on same Payout instance

invoice

An Invoice groups Payouts together. It is a managed object, you can not create them directly. When a Payout is created it is added to the Invoice that is currently open. If there is no open Invoice, a new will be created. you can learn more about that from Gigapay doc

invoice-list

The Invoice::list() method will return the Gigapay doc

invoice-retrieve

You can retrieve any invoice by it's id. you can get more info from Gigapay doc

invoice-update

invoice-delete

You can delete any invoice by calling the destroy method on invoice instance but we can not delete a paid Invoice or an Invoice on credit. get for info from Gigapay doc

Pricing

Pricing-Retrieve

You can retrieve any payout's Pricing info by payout's id. you can get more info from Gigapay doc

Pricing-Calculate

pricing-calculate-bulk

Webhook

  1. Event Discovery : in order for your Listeners to directly discover the Events from larave-gigapay. you need to enable the Auto discovery.
    • you can do that by going to your project's EventServiceProvider and change the method shouldDiscoverEvents to return true.
  1. Command gigapay:webhook: laravel-gigapay provides the command that will register all the webhooks with the APP_URL and it also has a route that will receive this webhooks and fire the events. so once you run this command with artisan you webhooks will get registered

php artisan gigapay:webhook

webhook-list

The Webhook::list() method will return the Gigapay doc

webhook-creation

webhook-retrieve

You can retrieve any webhook by it's id. you can get more info from Gigapay doc

webhook-update

webhook-replace

similar to employee, webhook can also be replaced. this will update the ID of webhook too. you can get more info from Gigapay doc.

webhook-delete

You can delete any webhook by calling the destroy method on Webhook instance. get for info from Gigapay doc

ListResource

This is the class that provides you with some helper methods to get the list of Any resource from Gigapay. The methods that you can use is:

paginate

This will add the parameter for pagination into Gigapay's APIs. it take 2 parameter, page and page_size. you can directly chain this method on any ListResource instance, you can also refer the Gigapay doc for this.

search

This will add the parameter for searching into Gigapay's APIs. it take 1 parameter, search. you can directly chain this method on any ListResource instance.

expand

This will add the parameter to expand any resource, for example a Payout has an associated Employee identifier. Those objects can be expanded

you can also expand multiple resource just by chaining the expand method. you can also refer the Gigapay doc for this.

addFilter

This will add the parameter for filtering regarding timestamp or relational filters. you just need to add the suffix like _before or _after. you can also refer the Gigapay doc for this. keep in mind that here all the timestamps are in ISO 8601 string. you can also chain this method and add multiple filters

getJson

This will return the JSON response we get from Gigapay API with all our filters applied.

Exception-Handling

Gigapay Exception


All versions of laravel-gigapay with dependencies

PHP Build Version
Package Version
Requires guzzlehttp/guzzle Version ^7.4
symfony/psr-http-message-bridge Version ^2.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 mazimez/laravel-gigapay contains the following files

Loading the files please wait ....