NetBox icon

NetBox

Consume NetBox API

Overview

This node interacts with the NetBox API to list Virtual Device Contexts within the DCIM domain. It allows users to retrieve information about virtual device contexts, which are logical groupings or contexts for devices in a data center infrastructure management system.

Common scenarios where this node is beneficial include:

  • Inventory management: Fetching all virtual device contexts to understand how devices are grouped.
  • Filtering specific virtual device contexts by attributes such as ID, device ID, name, status, or tenant.
  • Automating reporting or synchronization tasks that require up-to-date context information from NetBox.

Practical example:

  • A network engineer wants to get all active virtual device contexts related to a particular device or tenant to audit configurations or prepare for maintenance.

Properties

Name Meaning
Domain The domain of the NetBox API to use; for this operation, it must be "DCIM".
Return All Whether to return all results or limit the number of returned items.
Limit Maximum number of results to return if "Return All" is false (minimum 1, default 50).
Filters Collection of filters to narrow down the list of virtual device contexts:
   Virtual Device Context ID Filter by the unique ID of the virtual device context.
   Device ID Filter by the associated device's ID.
   Name Filter by the name of the virtual device context.
   Status Filter by status; options are "Active", "Planned", or "Offline".
   Tenant ID Filter by the tenant's ID associated with the virtual device context.

Output

The node outputs JSON data representing the list of virtual device contexts retrieved from the NetBox API. Each item in the output array corresponds to a virtual device context object containing its properties as defined by the NetBox API schema.

If the node supports binary data output (not indicated here), it would typically represent attachments or files related to the resource, but this operation focuses on JSON data only.

Dependencies

  • Requires an API key credential for authenticating with the NetBox API.
  • The node depends on the NetBox API being accessible and properly configured.
  • No additional external services are required beyond the NetBox instance.
  • Proper configuration of the domain ("dcim") and resource ("virtual-device-contexts") is necessary.

Troubleshooting

  • Common issues:

    • Authentication failures due to invalid or missing API credentials.
    • Network connectivity problems preventing access to the NetBox API.
    • Incorrect filter values leading to empty results.
    • Exceeding API rate limits or permissions restricting access to certain resources.
  • Error messages:

    • Errors during execution will be logged, and if "Continue on Fail" is enabled, the error message will be returned as part of the output JSON under an error field.
    • Common error messages might include authentication errors, invalid parameter errors, or HTTP errors from the API.
  • Resolutions:

    • Verify API credentials and permissions.
    • Check network connectivity and API endpoint URL.
    • Validate filter inputs for correctness.
    • Enable "Continue on Fail" to handle errors gracefully in workflows.

Links and References

Discussion