monthly-cloud/monthly-sdk-laravel

Laravel SDK for monthly.cloud.

0.4.0 2018-12-07 00:17 UTC

README

Laravel SDK used to connect with monthly cloud.

Installation

composer require monthly-cloud/monthly-sdk-laravel

Add Monthly Cloud service provider and alias to your config/app.php config:

'providers' => [
    ...
    MonthlyCloud\Laravel\MonthlyCloudServiceProvider::class,
],
'aliases' => [
    ...
    'MonthlyCloud' => MonthlyCloud\Laravel\MonthlyCloud::class,
],

Configuration

To create configuration file run:

php artisan vendor:publish --provider="MonthlyCloud\Laravel\MonthlyCloudServiceProvider"

Update .env file MONTHLY_CLOUD_ACCESS_TOKEN variable or config/monthlycloud.php access_token with access token generated in cloud settings.

Usage

Documentation is still in progress. Example usage:

$property = MonthlyCloud::endpoint('properties')->find(1); // Single property
$properties = MonthlyCloud::endpoint('properties')->get(); // List of properties