PHP code example of olsgreen / sage-business-cloud-accounting-api
1. Go to this page and download the library: Download olsgreen/sage-business-cloud-accounting-api library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
olsgreen / sage-business-cloud-accounting-api example snippets
$sage = new \Olsgreen\SageBusinessCloud\Accounting\Client([
'access_token' => 'your_acess_token'
]);
$contact = $sage->contacts()->create('Peter Jones', ['CUSTOMER']);
// [
// "id" => "4d63c58e4a8943ff81a5b1809b98e58a",
// "displayed_as" => "Peter Jones",
// "$path" => "/contacts/4d63c58e4a8943ff81a5b1809b98e58a",
// "created_at" => "2021-08-10T15:57:42Z",
// "updated_at" => "2021-08-10T15:57:42Z",
// ...
// ]