PHP code example of dev-lancer / von-halsky-php-sdk

1. Go to this page and download the library: Download dev-lancer/von-halsky-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/ */

    

dev-lancer / von-halsky-php-sdk example snippets




declare(strict_types=1);

use DateTimeImmutable;
use DevLancer\VonHalsky\Auth\AccessToken;
use DevLancer\VonHalsky\Auth\StaticTokenProvider;
use DevLancer\VonHalsky\Environment\Environment;
use DevLancer\VonHalsky\VonHalskyClient;

$client = VonHalskyClient::create(
    new StaticTokenProvider(new AccessToken('access-token', new DateTimeImmutable('+5 minutes'))),
    Environment::stage(),
);

$organizations = $client->organizations()->list()->data;
bash
composer