gitwtfhub

wtf is netbox-grafana-annotations-plugin?

mfarook2/netbox-grafana-annotations-plugin — explained in plain English

Analysis updated 2026-05-18

2PythonAudience · ops devopsComplexity · 3/5LicenseSetup · moderate

TL;DR

A NetBox plugin that automatically posts a Grafana graph annotation the moment a tracked NetBox object changes.

Mindmap

mindmap
  root((repo))
    What it does
      Auto Grafana annotations
      Triggered by NetBox events
      Verifies webhook signature
    Tech stack
      Python
      NetBox plugin API
      Grafana Annotations API
    Use cases
      Incident investigation
      Change to behavior correlation
      Network ops visibility
    Audience
      Network operations teams
      DevOps engineers
    Requirements
      NetBox 4.6 or later
      Grafana API token

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Why would anyone build with this?

REASON 1

Automatically mark on a Grafana graph the exact moment a device's role or status was changed in NetBox.

REASON 2

Speed up incident investigation by seeing NetBox changes overlaid directly on the graphs they may have affected.

REASON 3

Give a network operations team a shared visual timeline connecting configuration records to observed behavior.

What's in the stack?

PythonNetBoxGrafana APIWebhooks

How it stacks up

mfarook2/netbox-grafana-annotations-plugin0-bingwu-0/live-interpreter010zx00x1/faresnipe
Stars222
LanguagePythonPythonPython
Setup difficultymoderatemoderateeasy
Complexity3/52/52/5
Audienceops devopsgeneralgeneral

Figures from each repo's GitHub metadata at analysis time.

How do you spin it up?

Difficulty · moderate Time to first run · 30min

Requires NetBox 4.6+, Python 3.12+, and a Grafana instance with an API token that can create annotations.

Released under the Apache 2.0 license, which allows free use, modification, and commercial use as long as you keep the copyright and license notices.

Wtf does this do

NetBox Grafana Annotations Plugin connects two tools that network teams commonly use but that normally do not talk to each other. NetBox is where you record what your network is supposed to look like, such as a device's role or status, while Grafana is where you watch graphs of how the network actually behaves over time. This plugin makes sure that when someone changes something in NetBox, a marker automatically appears on the matching Grafana graph at that exact moment. The problem it solves is a familiar one for anyone managing infrastructure: a graph shows a spike or a drop, and the first question is whether anything changed around that time. Without this plugin, answering that means manually digging through NetBox's own change log and comparing timestamps by eye. With it, the marker is already sitting on the graph, so the connection between a NetBox edit and a Grafana graph is visible at a glance. Under the hood, it relies entirely on NetBox's built in Event Rule and Webhook system, so no custom code changes are needed inside NetBox itself. When a rule fires, it sends a signed request to the plugin, which verifies the signature, figures out which Grafana dashboard or panel the changed object relates to, either through a manually set field or by searching Grafana's tags, and then posts an annotation using Grafana's own API. Every attempt, whether it succeeds or fails, is logged inside NetBox so you can check what happened. The author is upfront about a limitation: the marker only shows when something was recorded in NetBox, not necessarily the exact moment a device's real behavior changed, since NetBox does not push configuration to devices itself. It requires NetBox 4.6 or later, Python 3.12 or later, and a reachable Grafana instance with an API token, with no other services like a database or message queue needed. It is installed with pip directly from the GitHub repository since it is not yet published to PyPI, and it is released under the Apache 2.0 license.

Yoink these prompts

Prompt 1
Help me configure a NetBox Event Rule and Webhook to send events to this plugin.
Prompt 2
Walk me through setting the grafana_url, grafana_token, and webhook_secret configuration options.
Prompt 3
Explain how the plugin decides which Grafana dashboard or panel to annotate for a given NetBox object.
Prompt 4
Show me how to check the plugin's Annotation Logs in NetBox to confirm an event was sent successfully.

Frequently asked questions

wtf is netbox-grafana-annotations-plugin?

A NetBox plugin that automatically posts a Grafana graph annotation the moment a tracked NetBox object changes.

What language is netbox-grafana-annotations-plugin written in?

Mainly Python. The stack also includes Python, NetBox, Grafana API.

What license does netbox-grafana-annotations-plugin use?

Released under the Apache 2.0 license, which allows free use, modification, and commercial use as long as you keep the copyright and license notices.

How hard is netbox-grafana-annotations-plugin to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is netbox-grafana-annotations-plugin for?

Mainly ops devops.

View the repo → Decode another repo

This repo across BitVibe Labs

Don't trust strangers blindly. Verify against the repo.