PHP code example of dazza-dev / dgii-sv-signer
1. Go to this page and download the library: Download dazza-dev/dgii-sv-signer 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/ */
dazza-dev / dgii-sv-signer example snippets
use DazzaDev\DgiiSvSigner\Signer;
// Instanciar el signer
$signer = new Signer(
certificatePath: __DIR__ . '/certificado.crt',
privatePassword: 'clave_privada',
);
// Firmar el Json
$signedJson = $signer->sign($jsonDocument);