PHP code example of alexis-riot / laravel-yousign

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

    

alexis-riot / laravel-yousign example snippets


return [
    'api_key' => env('YOUSIGN_API_KEY', 'production'), // ['production', 'staging']
    'api_env' => env('YOUSIGN_API_ENV'),
];

use AlexisRiot\Yousign\Facades\Yousign;

$users = Yousign::getUsers();

use AlexisRiot\Yousign\Facades\Yousign;

$file = Yousign::createFile([
    "name" => "devis.pdf",
    "content" => "JVBERi0xLjUKJb/3ov4KNiA...",
]);

use AlexisRiot\Yousign\Facades\Yousign;
use AlexisRiot\Yousign\YousignProcedure;

$file = Yousign::createFile([
    "name" => "devis.pdf",
    "content" => "JVBERi0xLjUKJb/3ov4KNiA...",
]);

$procedure = new YousignProcedure();
$procedure
    ->withName("My procedure")
    ->withDescription("The description of my procedure")
    ->addMember([
        'firstname' => "Alexis",
        'lastname' => "Riot",
        'email' => "[email protected]",
        'phone' => "+33 600000000",
    ], [$file])
    ->send();
bash
php artisan vendor:publish --provider="AlexisRiot\Yousign\YousignServiceProvider" --tag="config"