PHP code example of pinga / desec-php

1. Go to this page and download the library: Download pinga/desec-php 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/ */

    

pinga / desec-php example snippets




= new \deSEC\deSEC("your-api-token");  // Replace with your actual API token

try {
    $response = $api->getDomain('example.com');
    print_r($response);
} catch (Exception $e) {
    echo 'Caught exception: ',  $e->getMessage(), "\n";
}
bash
composer