PHP code example of coderjerk / hubsnot

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

    

coderjerk / hubsnot example snippets



$credentials = [
    'hubspot_access_token' => $_ENV['HUBSPOT_ACCESS_TOKEN']
];

$hubsnot = new Hubsnot($credentials);

$params = [
    'limit' => 200,
];

$forms = $hubsnot->forms()->getForms($params);

foreach ($forms->results as $form) {
    echo nl2br($form->name . "\r\n");
    echo nl2br($form->id . "\r\n");
}