PHP code example of timothecrespy / yousign-api-php-client

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

    

timothecrespy / yousign-api-php-client example snippets


// If you are using Laravel (https://github.com/laravel/laravel), you could specify the default Laravel logger:
$loggerInstance = Illuminate\Support\Facades\Log::getLogger();
$yousignClient->setLogger($loggerInstance);

$yousignClient->getUsers();
 bash
$ composer 
 php
use TimotheCrespy\YousignClient;

// It is recommended to store these values in a .env or equivalent file
const YOUSIGN_PRODUCTION_API_URL = 'https://api.yousign.com';
const YOUR_PRODUCTION_API_KEY = '[YOUR_PRODUCTION_API_KEY]';

$yousignClient = new YousignClient([
    'api_url' => self::YOUSIGN_PRODUCTION_API_URL,
    'api_key' => self::YOUR_PRODUCTION_API_KEY
]);
 php
use TimotheCrespy\YousignClient;

// It is recommended to store these values in a .env or equivalent file
const YOUSIGN_STAGING_API_URL = 'https://staging-api.yousign.com';
const YOUR_STAGING_API_KEY = '[YOUR_STAGING_API_KEY]';

$yousignClient = new YousignClient([
    'api_url' => self::YOUSIGN_STAGING_API_URL,
    'api_key' => self::YOUR_STAGING_API_KEY
]);