2017 © Pedro Peláez

library laravel-balanced



  • Thursday, March 12, 2015
  • by Patrickml
  • Repository
  • 2 Watchers
  • 2 Stars
  • 138 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown


Balanced Payments for Laravel 4

Integrates the Balanced Payments PHP library with Laravel 4 via a ServiceProvider and config extensions., (*1)


Include laravel-balanced as a dependency in composer.json:, (*2)

"revolt-visual/laravel-balanced": "dev-master"

Run composer install to download the dependency., (*3)

Add the ServiceProvider to your provider array within app/config/app.php:, (*4)

'providers' => array(



Finally, publish the configuration files via php artisan config:publish revolt-visual/laravel-balanced., (*5)


It is advisable to keep all of your sensitive configuration out of your configuration files. Instead, utilize Laravel's "dot files" to keep them out of source control and making them easily overridable on dev environments., (*6)

If you have not setup a "dot file", read Laravel's "Protecting Sensitive Configuration for detailed setup instructions. To quickly get up an running, simply create a .env.php file in the same directory as you apps composer.json file. Then add your Balanced API credentials to it., (*7)

return array(
  'balanced' => array(
    'api_key' => 'your-api-key',
    'secret_key' => 'your-secret-key'

If you insist on keeping your API credentials in your config, you can set your API Key and Publishable Key in app/config/packages/revolt-visual/laravel-balanced/balanced.php:, (*8)

return array(
    'api_key' => 'your-api-key',
    'secret_key' => 'your-secret-key'


You may use the Balanced PHP Library as normal within your application. The Balanced API will automatically be configured with your Secret Key, so you do not need to set it yourself., (*9)


Under you app.php file you may add aliases for each of the Balanced Payments Classes ex., (*10)

  'Balanced'          => 'Balanced\Marketplace',
  'Balanced_Card'         => 'Balanced\Card',

The Versions

12/03 2015



  Sources   Download

The Requires


by Patrick Lewis

laravel payments balanced