PHP code example of ln / threecx

1. Go to this page and download the library: Download ln/threecx 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/ */

    

ln / threecx example snippets


$client = new Client(new Host(string <fqdn>, int <port>, bool <debug, optional>));

$client->setUser(new User(string <username>, string <password>, string <mfa, optional>));
// or
$client->setRest(new Rest(string <clientId>, string <clientSecret>));
// or
$client->setToken(new Token(string <tokenType>, int <expires>, string <accessToken>, string <refreshToken>));

$client->get(string <uri>, array <query>)

$config->delete(string <uri>, array <query>)

$config-><post|put|patch>(string <uri>, array <payload>, array <query>)