LaravelPackages.net
Acme Inc.
Toggle sidebar
jsiebach/laravel-cheddar

An unofficial service provider for using CheddarGetter in Laravel

1.408
0
v1.0.0
About jsiebach/laravel-cheddar

jsiebach/laravel-cheddar is a Laravel package for an unofficial service provider for using cheddargetter in laravel. It currently has 0 GitHub stars and 1.408 downloads on Packagist (latest version v1.0.0). Install it with composer require jsiebach/laravel-cheddar. Discover more Laravel packages by jsiebach or browse all Laravel packages to compare alternatives.

Last updated

laravel-cheddar

A service provider for using CheddarGetter in Laravel.

This package simply provides an easy way to pull an authenticated CheddarGetter PHP Wrapper Client into your Laravel app. See the documentation for the CheddarGetter PHP Wrapper here: https://github.com/marcguyer/cheddargetter-client-php

Set Up

  1. Add this package to your composer.json -
    "require": {
        "jsiebach/laravel-cheddar": "^1.0"
    }
  1. Run composer update

  2. Add \JSiebach\Cheddar\CheddarServiceProvider::class to your array of service providers in /config/app.php

  3. Run php artisan vendor:publish to create the config file

  4. In /config/cheddar.php, add your credentials for Cheddar Getter.

Usage

You can now use dependency-injection to load a CheddarGetter_Client with your credentials automatically set. In any controller:

Class PaymentController extends Controller {
	
	public $client;

	__construct(CheddarGetter_Client $client){
		$this->client = $client;
	}

	public function customerList(){

		$response = $this->client->getAllCustomers();

		//handle response...

	}

}
Comments