Skip to main content

NetBox plugin to display PRTG monitoring status on device pages

Project description

NetBox PRTG Plugin

NetBox PRTG Plugin

A NetBox plugin that displays PRTG Network Monitor status on Device and Virtual Machine detail pages.

NetBox Version Python Version License CI PyPI

Features

  • Device Tab: Shows PRTG monitoring summary on device detail pages
  • Virtual Machine Tab: Shows PRTG monitoring summary on VM detail pages
  • Sensor Summary: Displays sensor counts by status (Up, Warning, Down, Paused)
  • Export to PRTG: Create devices in PRTG directly from NetBox with auto-discovery
  • Virtual Chassis Support: Monitors entire stack using VC name and master IP
  • Direct Links: Quick link to view the device in PRTG
  • Caching: Configurable caching to minimize API calls
  • Custom Field: Optional prtg_device_id field for explicit device mapping

Screenshots

Device Tab

Shows sensor status summary with color-coded badges for quick status overview.

Device Tab

Export to PRTG

Export devices from NetBox to PRTG with one click.

Export

Export Confirmation

Confirmation dialog showing device details before export.

Export Confirmation

Settings Page

Displays current configuration and connection status.

Settings Page

Requirements

  • NetBox 4.0.0 or higher
  • PRTG Network Monitor with API access
  • PRTG API Token

Note: This plugin is developed and tested exclusively on NetBox 4.x. It is not compatible with NetBox 3.x due to API and model changes.

Installation

Via pip (recommended)

pip install netbox-prtg

From source

git clone https://github.com/sieteunoseis/netbox-prtg.git
cd netbox-prtg
pip install .

Configuration

  1. Add the plugin to your NetBox configuration.py:
PLUGINS = [
    'netbox_prtg',
]

PLUGINS_CONFIG = {
    'netbox_prtg': {
        'prtg_url': 'https://prtg.example.com',
        'prtg_api_token': 'your-api-token-here',
        'timeout': 30,
        'cache_timeout': 60,
        'verify_ssl': True,
    }
}
  1. Restart NetBox to load the plugin.

Configuration Options

Option Type Default Description
prtg_url string "" PRTG server URL (e.g., https://prtg.example.com)
prtg_api_token string "" API token from PRTG account settings
timeout int 30 API request timeout in seconds
cache_timeout int 60 How long to cache API responses in seconds
verify_ssl bool True Verify SSL certificates

Getting a PRTG API Token

  1. Log into your PRTG web interface
  2. Go to Setup > Account Settings > My Account
  3. Under API Keys, click Create API Key
  4. Copy the token and add it to your NetBox configuration

Usage

Device Matching

The plugin matches NetBox devices to PRTG devices by hostname. The device name in NetBox must match the device name in PRTG.

For explicit mapping, you can set the prtg_device_id custom field on a device with the PRTG object ID.

Virtual Chassis Support

For devices that are members of a Virtual Chassis (VC), the plugin:

  • Uses the VC name for PRTG device lookup/export (not individual member names)
  • Uses the VC master's IP address as the host for monitoring
  • Displays VC information in the PRTG tab

This allows you to monitor an entire switch stack as a single PRTG device.

Viewing Monitoring Status

  1. Navigate to any device or virtual machine detail page
  2. Click the PRTG tab
  3. View the sensor status summary

Exporting Devices to PRTG

When a device is not found in PRTG, you can export it directly:

  1. Click the Export to PRTG button
  2. The device is created in the "NetBox Import" group
  3. Auto-discovery runs to detect available sensors
  4. Move the device to the appropriate group in PRTG as needed

Status Indicators

Status Color Description
Up Green Sensor is healthy
Warning Orange Sensor has warnings
Down Red Sensor is down/critical
Paused Gray Sensor is paused
Unusual Amber Sensor has unusual readings

Development

Setup

cd ~/development
git clone https://github.com/sieteunoseis/netbox-prtg.git
cd netbox-prtg
python -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"

Running Lint Checks

black netbox_prtg/
isort netbox_prtg/
flake8 netbox_prtg/

Testing with NetBox Dev Instance

  1. Add to netbox-dev/configuration/plugins.py
  2. Mount in netbox-dev/docker-compose.yml
  3. Restart: docker-compose restart netbox

API Endpoints Used

The plugin uses the following PRTG API endpoints:

  • GET /api/status.json - Test connection
  • GET /api/table.json?content=devices - Find devices by hostname
  • GET /api/table.json?content=sensors - Get device sensors
  • GET /api/table.json?content=groups - Find groups
  • GET /api/addgroup.htm - Create groups
  • GET /api/adddevice2.htm - Create devices with auto-discovery

Future Enhancements

  • Detailed sensor list view
  • Sensor alerts history
  • Bulk device status view
  • Conditional tab visibility

License

Apache License 2.0

Author

Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

netbox_prtg-0.4.1.tar.gz (23.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

netbox_prtg-0.4.1-py3-none-any.whl (25.1 kB view details)

Uploaded Python 3

File details

Details for the file netbox_prtg-0.4.1.tar.gz.

File metadata

  • Download URL: netbox_prtg-0.4.1.tar.gz
  • Upload date:
  • Size: 23.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for netbox_prtg-0.4.1.tar.gz
Algorithm Hash digest
SHA256 29e5f99ab6a9347ec5bd8261d68d8081dbc0bc752be721e3f90422678d6e6926
MD5 91a15be3acac0d8d09c941dadb878b61
BLAKE2b-256 c1b220a6b182f854be4ed49fb3ad5f2afc928891c674ea0e3e1a99ec81a10015

See more details on using hashes here.

Provenance

The following attestation bundles were made for netbox_prtg-0.4.1.tar.gz:

Publisher: release.yml on sieteunoseis/netbox-prtg

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file netbox_prtg-0.4.1-py3-none-any.whl.

File metadata

  • Download URL: netbox_prtg-0.4.1-py3-none-any.whl
  • Upload date:
  • Size: 25.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for netbox_prtg-0.4.1-py3-none-any.whl
Algorithm Hash digest
SHA256 78b9d3aa9ee8b29c172bbe98baf8f49e79bd59a181ed578e74e32e4a8759b02d
MD5 ac274c1b5446e355d1079eb8511bbd7d
BLAKE2b-256 8ead499fc03e24fa3b02c4195bf2e5988d705cd1613229829fda15c8c413aba2

See more details on using hashes here.

Provenance

The following attestation bundles were made for netbox_prtg-0.4.1-py3-none-any.whl:

Publisher: release.yml on sieteunoseis/netbox-prtg

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page