PHP code example of unificationengine / ue-php-sdk
1. Go to this page and download the library: Download unificationengine/ue-php-sdk 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/ */
unificationengine / ue-php-sdk example snippets
use UnificationEngine\Models\UEApp;
$app = new UEApp("APP_KEY","APP_SECRET");
use UnificationEngine\Models\UEApp;
use UnificationEngine\Models\UEUser;
//Use our app
$app = new UEApp("APP_KEY","APP_SECRET");
//Creating a new user
$user = $app->create_user();
//Using existing user using key and secret
$user = new UEUser("USER_KEY","USER_SECRET");
//Using existing user using it's uri
$user = new UEUser("user://USER_KEY:USER_SECRET@");
$connection = $user->add_connection("connection_name", "service", "service_access_token", $optional_params);
//connection is an instance of UEConnection
$connections = $user->list_connections()
// connections is an array of UEConnection objects