ndamiens/netbox-client-php

Netbox client API

v0.0.12 2024-08-12 13:20 UTC

This package is auto-updated.

Last update: 2024-11-12 13:58:56 UTC


README

This project is an API client for Netbox

To iterate over your netbox entities

<?php

use ND\Netbox\Client;

$netbox = new Client("https://your-netbox/", "your-api-key");

foreach ($netbox->getSites() as $site) {
    echo $site["name"]."\n";
}

Read entities attribues as an associative array

Retrieve an entity

<?php

$site = $netbox->getSite(42);

To update an entity

after retrieve

$site['comments'] = "This is a test";
$site->save();