NetBox Plugins to Present External Data

I have worked with NetBox for over five years now, and NetBox plugins feature has existed since version 2.8 in April 2020, but it was only recently that I got a need to start leveraging plugins to extend the NetBox functionalities.

Most of the publicly available plugins work with Django model-based data that is saved in the NetBox database. The models are either built-in NetBox models (like sites or prefixes) or custom models defined by the plugins (like DNS entries or BGP peers).

My first use cases for NetBox plugins do not deal with model-based data within NetBox database but something totally external to NetBox. Basically I just want to show the specific external data nicely in the NetBox GUI.

NetBox has long supported custom links that can point to whatever external URLs, like monitoring or management systems that offer further information about devices or other items. In my case the external data is coming and enriched from external APIs, there is no direct URL or GUI that I can link to.

NetBox also has custom scripts that can be linked to, but I didn’t want to show the extra “run the script now” page to run the script and get the output. The output possibilities of custom scripts are also very limited.

That led me to study the topic a bit and publish two example plugins:

The first one is a simple example of showing some HTML or other content in the NetBox GUI.

The second one is a step further, showing how to view table-formatted external data.

Both are working independently of any NetBox model, so they don’t integrate to any tabs or menus of existing items. They have main menu items though to access the views (pages), but you can also leave the menu items out and just configure model-specific custom links to link to your plugin views if that works better for the use case.

Check them out if you are having similar ideas to extend using NetBox in your automation or management environment.

For more information about developing and using NetBox plugins, see the Plugins Wiki page in NetBox repository.

Leave a Reply