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

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
File Size Uploaded Provenance Actions
netbox_types-4.7.4.tar.gz 21.6 MB Without provenance Details for netbox_types-4.7.4.tar.gz

Built distribution (wheel)

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

Total release size: 25.5 MB

Release files / netbox_types-4.7.4.tar.gz

Download URL netbox_types-4.7.4.tar.gz
Size 21.6 MB
Tags Source
SHA-256 checksum
How to use checksums
882e9a86416d5f6308286b3b4fd467dcc3f5b62cb10d0a587177f0d5b464a4e1
BLAKE2b-256 checksum
How to use checksums
944f6bab253b5faff99507b7f122f2f49eaea1a93b305f4f71f651f773b4673c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.6 {"installer":{"name":"uv","version":"0.13.6","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-py3-none-any.whl

Download URL netbox_types-4.7.4-py3-none-any.whl
Size 3.9 MB
Tags Python 3
SHA-256 checksum
How to use checksums
edbe4acddfb9db3b5f4413fdbb7b9e4817b8c6f0b40e5327f7d8f01fa8472016
BLAKE2b-256 checksum
How to use checksums
247b80eb5a4984199fc3d1aba180c4974c6f98649a00cb684da705d46fb04c4c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.6 {"installer":{"name":"uv","version":"0.13.6","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

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