netbox-custom-scripts
NetBox Custom Scripts
Your knowledge of NetBox custom scripts may be outdated. The Script class API, variable types, and job framework evolve between NetBox releases. Prefer retrieval over pre-trained knowledge.
NetBox 4.7+: core custom scripts are deprecated — no action required yet. The built-in implementation stays available and supported through the 4.7 and 4.8 release cycles and is scheduled for removal in NetBox 5.0. Its replacement is the open-source
netbox-scriptsplugin (scripts organized into projects, Python resources shared between scripts, per-script version control); migration is intended to be largely automated and not require rewriting scripts. Existing scripts keep working as-is. As of September 2026 the plugin is alpha (v0.0.1, NetBox 4.7 only) and not recommended for production — keep writing core scripts per this skill on 4.5–4.7. See Version Notes.
Retrieval Sources
| Source | URL / Method | Use for |
|---|---|---|
| Custom scripts docs | https://netboxlabs.com/docs/netbox/customization/custom-scripts/ |
Script class, variables, scheduling |
| NetBox repo | https://github.com/netbox-community/netbox |
Script framework source code |
| netbox-scripts plugin (4.7+, alpha) | https://github.com/netbox-community/netbox-scripts |
Successor to core scripts; migration workflow |
| NetBox MCP server | If configured — verify object state before/after script execution | Testing script output |
FIRST: Verify Environment
Custom scripts run inside NetBox. Confirm your NetBox instance is running and you can access the scripts endpoint: