NetBox icon

NetBox

Consume NetBox API

Actions243

Virtual Device Context → Create

AI-generated

Overview

This node interacts with the NetBox API to create a new Virtual Device Context within the DCIM domain. It is useful for network administrators or IT professionals who need to programmatically manage virtual device contexts in their infrastructure. For example, it can be used to automate the creation of virtual device contexts with specific attributes such as name, device ID, status, and additional optional fields like identifier, tenant ID, IP addresses, description, comments, tags, and custom fields.

Use Case Examples

  1. Automating the creation of virtual device contexts during network provisioning.
  2. Integrating with other systems to dynamically manage virtual device contexts based on real-time data.

Properties

Name Meaning
Domain Specifies the domain of the NetBox API to use, here it is set to 'dcim' for data center infrastructure management.
Virtual Device Context Name The name of the virtual device context to be created.
Device ID The ID of the device to which the virtual device context belongs.
Status The status of the virtual device context, such as active, planned, or offline.
Additional Fields Optional additional fields for the virtual device context, including identifier, tenant ID, primary IPv4 and IPv6 address IDs, description, comments, tags, and custom fields.

Output

JSON

  • id - The unique identifier of the created virtual device context.
  • name - The name of the created virtual device context.
  • device - The device ID associated with the virtual device context.
  • status - The status of the created virtual device context.
  • identifier - Optional numeric identifier of the virtual device context.
  • tenant - Optional tenant ID associated with the virtual device context.
  • primary_ip4 - Optional primary IPv4 address ID.
  • primary_ip6 - Optional primary IPv6 address ID.
  • description - Optional description of the virtual device context.
  • comments - Optional comments about the virtual device context.
  • tags - Optional tags associated with the virtual device context.
  • custom_fields - Optional custom fields for the virtual device context.

Dependencies

  • NetBox API with appropriate credentials

Troubleshooting

  • Ensure the device ID provided exists in the NetBox system to avoid errors.
  • Verify that the API credentials have sufficient permissions to create virtual device contexts.
  • Check that required fields such as virtual device context name, device ID, and status are provided and valid.
  • If the node throws an error, enabling 'Continue on Fail' will allow the workflow to proceed and output the error message for debugging.

Links

Discussion