2017 © Pedro Peláez
 

library laravel5-afterpay

Afterpay API integration exposed via Laravel5 services'

image

culturekings/laravel5-afterpay

Afterpay API integration exposed via Laravel5 services'

  • Friday, May 12, 2017
  • by jared-fraser
  • Repository
  • 5 Watchers
  • 2 Stars
  • 8 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 14 Versions
  • 0 % Grown

The README.md

Afterpay for Laravel 5

This packages exposes services from CultureKings/Afterpay in Laravel5., (*1)

Coverage Status CircleCI Scrutinizer SensioLabsInsight, (*2)

Version Compatibility

Laravel Laravel5 Afterpay
5.3.x @dev

Installation

The recommended way to install is via Composer., (*3)

composer require culturekings/laravel5-afterpay

Find the providers key in your config/app.php and register the Afterpay Service Provider, (*4)

'providers' => array(
    // ...
    CultureKings\LaravelAfterpay\Provider\AfterpayProvider::class,
)

Configuration

Merchant API Configuration

By default, the package uses the following environment variables to auto-configure the plugin without modification:, (*5)

AFTERPAY_API_URL (defaults to sandbox url)
AFTERPAY_MERCHANT_ID
AWS_AFTERPAY_SECRET_KEY

InStore API Configuration

AFTERPAY_INSTORE_API_URL (defaults to sandbox url)

To customize the configuration file, publish the package configuration using Artisan., (*6)

php artisan vendor:publish, (*7)

Update your settings in the generated app/config/afterpay.php configuration file., (*8)

Usage

Merchant API Facades

This package exposes multiple facades for you to use., (*9)

Using the facades allows you not to worry about the Authorisation object that is required for calls., (*10)

Configuration, (*11)

$api = \App::make('afterpay_merchant_configuration');
$api::get();

Payments, (*12)

$api = \App::make('afterpay_merchant_payments');
$payments = $api::listPayments();

Orders, (*13)

$api = \App::make('afterpay_merchant_orders');
$order = $api::get(ORDER_TOKEN);

InStore API Facades

This package exposes multiple facades for you to use., (*14)

Authentication is more manual with this API and it is required for you to manually set the details on \CultureKings\Afterpay\Model\InStore\Authorization., (*15)

Customer, (*16)

$api = \App::make('afterpay_instore_customer');
$api::invite();

Device, (*17)

$api = \App::make('afterpay_instore_device');
$api::activate();

Order, (*18)

$api = \App::make('afterpay_instore_order');
$order = $api::create();

PreApproval, (*19)

$api = \App::make('afterpay_instore_preapproval');
$order = $api::enquiry();

Refund, (*20)

$api = \App::make('afterpay_instore_refund');
$order = $api::create();

Raw

read the documentation, (*21)

Raw does away with the Facade and hits the services directly, giving you more flexibility. The trade off is that your now responsible for creating your own Authentication object and injecting it into the services. You can still ask Laravel to create you an Authentication object with your credentials loaded from config., (*22)

$auth = \App::make(CultureKings\Afterpay\Model\Merchant\Authorization::class);

The Versions

12/05 2017

dev-master

9999999-dev

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

12/05 2017

v2.1.1

2.1.1.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

03/03 2017

v2.1.0

2.1.0.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

28/02 2017

v2.0.3

2.0.3.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

23/02 2017

v2.0.2

2.0.2.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

21/02 2017

v2.0.1

2.0.1.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

20/02 2017

v2.0.0

2.0.0.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

13/02 2017

v1.1.3

1.1.3.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

05/02 2017

v1.1.2

1.1.2.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

02/02 2017

v1.1.0

1.1.0.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

23/01 2017

v1.0.0

1.0.0.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

06/09 2016

v0.1.2

0.1.2.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

06/09 2016

v0.1.1

0.1.1.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay

31/08 2016

v0.1.0

0.1.0.0

Afterpay API integration exposed via Laravel5 services'

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jared Fraser

payments laravel5 shopping afterpay