Skip to main content

netbox-types

A helper package for NetBox plugin and script developers that provides development-time type hints and module resolution.

Purpose

netbox-types makes it possible to install NetBox components as development dependencies, enabling proper IDE support, type checking, and module resolution when developing NetBox plugins and custom scripts. This allows you to import and use NetBox modules like dcim, ipam, circuits, and others during development without having a full NetBox installation.

Important Note

This package is a republish of the official NetBox source code in the form of a types package. The source code does not differ from NetBox itself - it's simply repackaged to be installable as a development dependency.

Installation

Install netbox-types as a development dependency only:

# Using uv
uv add --dev netbox-types

# Using pip
pip install --dev netbox-types

# Using poetry
poetry add --group dev netbox-types

⚠️ Important: Do NOT install this package in production environments. When your plugin or script is deployed to an actual NetBox instance, the real NetBox modules will be available via internal imports.

Usage

During Development

With netbox-types installed, you can develop your plugins and scripts with full IDE support:

# Your IDE will now resolve these imports during development
from dcim.models import Device, Site
from ipam.models import IPAddress, Prefix
from circuits.models import Circuit, Provider
from extras.scripts import Script

In Production

When deployed to NetBox, your code uses the exact same imports, but they resolve to the actual NetBox installation:

# Same imports work in production - no changes needed!
from dcim.models import Device, Site
from ipam.models import IPAddress, Prefix

Common Use Cases

  • Plugin Development: Develop NetBox plugins with full type hints and autocomplete
  • Custom Scripts: Write custom scripts with IDE support for NetBox models
  • Testing: Run unit tests for your NetBox extensions locally
  • CI/CD: Install in development mode for linting and type checking in your pipeline

Example Project Setup

# pyproject.toml
[project]
name = "my-netbox-plugin"
dependencies = [
    # Your plugin's runtime dependencies (no netbox-types here!)
]

[project.optional-dependencies]
dev = [
    "netbox-types",
    "pytest",
    "ruff",
]

Reporting Issues

If you encounter problems with missing modules, incorrect type hints, or any other issues related to this package, please report them directly to this repository. Since this package mirrors the NetBox source structure, issues are typically related to:

  • Missing modules that should be included
  • Packaging or distribution problems
  • Version mismatches

For issues with NetBox itself (not this types package), please report to the official NetBox repository.

Version Compatibility

This package follows NetBox's versioning. Install a version that matches your target NetBox version:

# For NetBox 4.0.x
uv add --dev netbox-types==4.0.*

# For NetBox 3.7.x
uv add --dev netbox-types==3.7.*

What's Included

This package includes all standard NetBox modules:

  • circuits - Circuit and provider management
  • core - Core NetBox functionality
  • dcim - Data center infrastructure management
  • extras - Custom fields, scripts, webhooks, etc.
  • ipam - IP address management
  • tenancy - Multi-tenancy support
  • utilities - Helper utilities and base classes
  • virtualization - Virtual machine management
  • vpn - VPN tunnel and termination management
  • wireless - Wireless LAN management
  • And more...

License

This package contains NetBox source code and is distributed under the same license as NetBox. See the LICENSE.txt file for details.

Metadata

Release files for netbox-types 4.7.4.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for netbox-types 4.7.4.1
File Size Uploaded Provenance Actions
netbox_types-4.7.4.1.tar.gz 21.6 MB Without provenance Details for netbox_types-4.7.4.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for netbox-types 4.7.4.1
File Interpreter ABI Platform Actions
netbox_types-4.7.4.1-py3-none-any.whl Python 3 none any Details for netbox_types-4.7.4.1-py3-none-any.whl

Total release size: 25.5 MB

Release files / netbox_types-4.7.4.1.tar.gz

Download URL netbox_types-4.7.4.1.tar.gz
Size 21.6 MB
Tags Source
SHA-256 checksum
How to use checksums
46f89b834ee66ff53682a187a8657f837909e31bcc34833f0e62c88e254a0d33
BLAKE2b-256 checksum
How to use checksums
5de6b626533299de3bbdc0030e5e3e2ea77e61d182ba0696fdf3a19f499bc506
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.7 {"installer":{"name":"uv","version":"0.13.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / netbox_types-4.7.4.1-py3-none-any.whl

Download URL netbox_types-4.7.4.1-py3-none-any.whl
Size 3.9 MB
Tags Python 3
SHA-256 checksum
How to use checksums
2125c14a7e35f3cde9a088030102b5ac8a6043b8f19026de96c8ed8e739db87a
BLAKE2b-256 checksum
How to use checksums
0c55f924872ea44f0f8e846d0d40329a9083d7a4fc1a535469182bd13f789107
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.7 {"installer":{"name":"uv","version":"0.13.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for netbox-types 4.7.4.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page