User Interface
Light & Dark Mode
The NetBox user interface supports toggling between light and dark versions of the theme. If needed, a plugin can determine the currently active color theme by inspecting window.localStorage['netbox-color-mode'], which will indicate either light or dark.
Additionally, when the color scheme is toggled by the user, a custom event netbox.colorModeChanged indicating the new scheme is dispatched. A plugin can listen for this event if needed to react to the change:
window.addEventListener('netbox.colorModeChanged', e => {
const customEvent = e as CustomEvent<ColorModeData>;
console.log('New color mode:', customEvent.detail.netboxColorMode);
});Webhooks
NetBox supports the configuration of outbound webhooks which can be triggered by custom event rules. By default, a webhook's payload will contain a serialize...
REST API
Plugins can declare custom endpoints on NetBox's REST API to retrieve or manipulate models or other data. These behave very similarly to views, except that i...