PHP code example of kobas / api-client
1. Go to this page and download the library: Download kobas/api-client 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/ */
kobas / api-client example snippets
/**
* Setup
*/
$companyId = 0000;// company id provided by Kobas
$clientId = '';// client id provided by Kobas
$clientSecret = '';// client secret provided by Kobas
$clientScope = ''; // client scope provided by Kobas
$provider = new \Kobas\APIClient\Auth\Provider($companyId, $clientId, $clientSecret, $clientScope);
$client = new \Kobas\APIClient\Client($provider);
/**
* Usage
*/
$response = $client->get('customer/search', ['email' => '[email protected]']);
echo json_encode($response, JSON_PRETTY_PRINT);