PHP code example of cbs-software / smarteru-php-client
1. Go to this page and download the library: Download cbs-software/smarteru-php-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/ */
cbs-software / smarteru-php-client example snippets
use CBS\SmarterU\Client;
$accountAPIkey = 'insert your account API key here';
$userAPIkey = 'insert your user API key here';
$client = new Client($accountAPIkey, $userAPIkey);
use CBS\SmarterU\Queries\ListUsersQuery;
use CBS\SmarterU\Queries\Tags\MatchTag;
$matchTag = (new MatchTag())
->setMatchType('EXACT')
->setValue('John Smith');
$query = (new ListUsersQuery())
->setName($matchTag);
use CBS\SmarterU\Queries\ListUsersQuery;
use CBS\SmarterU\Queries\Tags\MatchTag;
$matchTag = (new MatchTag())
->setMatchType('CONTAINS')
->setValue('@example.com');
$query = (new ListUsersQuery())
->setEmail($matchTag);