PHP code example of carloshaam / d4sign-php-sdk
1. Go to this page and download the library: Download carloshaam/d4sign-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/ */
carloshaam / d4sign-php-sdk example snippets
declare(strict_types=1);
ocument\UploadDocumentFields;
$d4sign = new D4Sign('your_api_key', 'your_secret_key', 'your_api_url');
$filePath = '/path/to/filename.pdf';
try {
$fields = new UploadDocumentFields($filePath);
$fields->setUuidFolder('uuid-folder'); // opcional
$document = $d4sign->documents()->uploadDocumentToSafe('uuid-safe', $fields);
echo print_r($document->getJson(), true);
} catch (\Exception $e) {
echo $e->getMessage();
}
shell
composer