NetBox icon

NetBox

Consume NetBox API

Actions243

Device Type → Create

AI-generated

Overview

This node interacts with the NetBox API to create a new Device Type within the DCIM domain. It is useful for network administrators or IT professionals who want to automate the addition of device types in their NetBox inventory management system. For example, it can be used to add a new device type by specifying the manufacturer ID, model name, and optional additional fields such as slug, part number, height, airflow, weight, comments, tags, and custom fields.

Use Case Examples

  1. Creating a new device type for a specific manufacturer with detailed specifications to keep the inventory up to date.
  2. Automating the addition of device types during network expansion or equipment upgrades.

Properties

Name Meaning
Domain Specifies the domain of the NetBox API to use, here it is set to 'dcim' for device management.
Manufacturer ID The unique identifier of the manufacturer for the device type to be created.
Model The model name of the device type to be created.
Additional Fields Optional additional properties for the device type such as slug, part number, height, full depth status, subdevice role, airflow direction, weight, weight unit, comments, tags, and custom fields.

Output

JSON

  • id - Unique identifier of the created device type.
  • manufacturer - Manufacturer ID associated with the device type.
  • model - Model name of the created device type.
  • slug - Slug identifier of the device type.
  • part_number - Manufacturer part number.
  • u_height - Height in rack units.
  • is_full_depth - Boolean indicating if device is full depth.
  • subdevice_role - Role of the device in rack hierarchy.
  • airflow - Airflow direction.
  • weight - Weight of the device.
  • weight_unit - Unit of the weight.
  • comments - Comments associated with the device type.
  • tags - Tags associated with the device type.
  • custom_fields - Custom fields in JSON format.

Dependencies

  • NetBox API with appropriate authentication credentials

Troubleshooting

  • Common issues include invalid manufacturer ID or missing required fields such as model name, which will cause API errors.
  • Network connectivity issues to the NetBox API endpoint can cause failures.
  • Ensure the API credentials have sufficient permissions to create device types.
  • Error messages typically include HTTP status codes and descriptive messages from the NetBox API; verify input data and credentials accordingly.

Links

Discussion