NetBox icon

NetBox

Consume NetBox API

Actions243

Interface → Update

AI-generated

Overview

This node updates an existing interface record in the NetBox API under the DCIM domain. It is useful for network administrators who need to modify interface details such as device association, interface name, type, status, VLAN settings, and custom fields. For example, updating the MAC address or enabling/disabling an interface on a device.

Use Case Examples

  1. Updating the MAC address of a specific interface on a device.
  2. Changing the interface type from virtual to a physical type like 1000BASE-T.
  3. Enabling or disabling an interface.
  4. Modifying VLAN tagging and mode settings for an interface.

Properties

Name Meaning
Domain Specifies the domain of the NetBox API to interact with, here it is 'dcim' for device and infrastructure management.
Interface ID The unique identifier of the interface to update.
Update Fields Collection of fields to update on the interface, including device ID, name, type, enabled status, LAG interface ID, MTU, MAC address, management-only flag, description, mode, VLAN settings, connection marking, tags, and custom fields.
ID ID of the record, used in tenancy domain operations but not relevant for this interface update operation.

Output

JSON

  • id - Unique identifier of the updated interface record.
  • name - Name of the updated interface.
  • type - Type of the updated interface.
  • enabled - Whether the interface is enabled.
  • device - ID of the device the interface belongs to.
  • mac_address - MAC address of the interface.
  • description - Description of the interface.
  • mode - Mode of the interface for Layer 2 interfaces.
  • untagged_vlan - ID of the untagged VLAN.
  • tagged_vlans - List or string of tagged VLAN IDs.
  • custom_fields - Custom fields associated with the interface.

Dependencies

  • NetBox API
  • An API key credential for authentication

Troubleshooting

  • Common issues include invalid interface ID, insufficient permissions, or malformed update fields.
  • Error messages may indicate missing required fields or invalid data types; ensure all required fields are correctly provided and formatted.
  • Network connectivity issues to the NetBox API endpoint can cause failures; verify API endpoint accessibility and credentials.

Links

  • NetBox API Documentation - Official documentation for the NetBox API, useful for understanding available resources and operations.

Discussion