1. Go to this page and download the library: Download wanecho/getui 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/ */
wanecho / getui example snippets
$config = (new \Getui\Config())->
setAppId('llUBYSt12xg2mPbnOh6')->
setAppKey('wP31m7pz12DVFmkHq9F6')->
setMasterSecret('qMyiA12qJ912auukl4Hf8');
$cache = new Doctrine\Common\Cache\RedisCache();
$redis = new \Redis();
$redis->connect('172.26.224.178',6379,5);
$cache->setRedis($redis);
$authorization = (new \Getui\Authorization($config))->withCacheDriver($cache);
(new \Getui\User())->withConfig($config)->withAuth($authorization)->aliasBind([
[
'cid'=>'ad9555f3c980cb0fe20de584ab9f0e3a',
'alias'=>'15093570968'
]
]);
$alias = (new \Getui\User())->
withConfig($config)->
withAuth($authorization)->
getAliasByClientId('ad9555f3c980cb0fe20de584ab9f0e3a');
var_dump($alias);