Download the PHP package nestednet/gocardless-laravel without Composer

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

gocardless-laravel

Build Status Scrutinizer Code Quality Latest Stable Version Latest Unstable Version License

GoCardless Pro PHP Client package integration for Laravel.

This package tries to provide an easy, scalable and maintainable way to integrate Gocardless into your laravel project.

It provides a Facade that wraps the Gocardless PHP client and also an easy way to handle the webhooks that Gocardless sends. This is done following the steps that Spatie uses for their Stripe Laravel Webhooks package.

Installation

Get the package with composer:

1. If you are using Laravel >5.5 the package will be autodiscobered, for older versions add the service provider at your config/app.php file.

2. Publish the configuration file

This will publish both the configuration file and the migration file.

3. Review the configuration file

and add your Gocardless API token and environment to the .env file.

4. After publishing the migration you can run the migration and create the gocardless_webhooks_table

5. The package provides a Macro route (gocardlessWebhooks). You can create a route at your routes file of your app. This route will be the endpoint where Gocardless will send the webhooks, you should register this webhook endpoint at your Gocardless dashboard.

This will register a POST route to a the controller provided by this package. You should add the route to the except array of the VerifyCsrfToken middleware.

Usage

Once the package is properly installed you can use the Gocardless facade to access the methods of the Gocardless PHP client. The documentation of this methods can be found here: Gocardless PHP cleint documentation

If you use Gocardless at your project you provably will use webhooks to handle the asynchronous payment states. This package provides an easy way to handle the webhooks.

Gocardless will send you webhooks with events. This events will contain the updates of your Gocardless resources.

This package will verify the signature of the requests and if it's valid. Unless something goes terribly wrong, and even if one of the events inside the webhook fails the controller will reposnd with a 200 to Gocardless. This prevents Gocardless from spamming retries to the endpoint.

If an event fails to be processed the exception will be saved to the database into the gocardless_webhook_calls table, you can find the failed events there.

This package provides two ways to handle the webhook requests:

Using jobs

You can find a jobs array inside the config\gocardless.php.

You can register any job that you want to the gocardless events. An event from Gocardless references one resource resource_type and one action. In order to register a job to an action you should add it with the key {resource_type}_{action}.

In order to avoid timeouts it's highly recommended to use queued jobs.

Using events

Every time an event is processed by the package it will trigger an event with this structure:

gocardless-webhooks::{resource_type}_{action}

The payload of the event will be the GocardlessWebhookCall (or an extended model) instance created with the request.

You can register listeners to this events in the EventServiceProvider:


All versions of gocardless-laravel with dependencies

PHP Build Version
Package Version
Requires php Version >=7.1.3
illuminate/support Version >=5.5.0
gocardless/gocardless-pro Version ^3.0
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 nestednet/gocardless-laravel contains the following files

Loading the files please wait ....