netbox_search_objects
Perform global search across NetBox for names, IPs, serial numbers, and other key fields. Limit results by object type and field projection.
Instructions
Perform global search across NetBox infrastructure.
Searches names, descriptions, IP addresses, serial numbers, asset tags,
and other key fields across multiple object types.
Args:
query: Search term (device names, IPs, serial numbers, hostnames, site names)
Examples: 'switch01', '192.168.1.1', 'NYC-DC1', 'SN123456'
object_types: Limit search to specific types (optional)
Default: [dcim.device', 'dcim.site', 'ipam.ipaddress', 'dcim.interface', 'dcim.rack', 'ipam.vlan', 'circuits.circuit', 'virtualization.virtualmachine]
Examples: ['dcim.device', 'ipam.ipaddress', 'dcim.site']
fields: Optional list of specific fields to return (reduces response size) IT IS STRONGLY RECOMMENDED TO USE THIS PARAMETER TO MINIMIZE TOKEN USAGE.
- None or [] = returns all fields (no filtering)
- ['id', 'name'] = returns only specified fields
Examples: ['id', 'name', 'status'], ['address', 'dns_name']
Uses NetBox's native field filtering via ?fields= parameter
limit: Max results per object type (default 5, max 100)
Returns:
Dictionary with object_type keys and list of matching objects.
All searched types present in result (empty list if no matches).
Example:
# Search for anything matching "switch"
results = netbox_search_objects('switch')
# Returns: {
# 'dcim.device': [{'id': 1, 'name': 'switch-01', ...}],
# 'dcim.site': [],
# ...
# }
# Search for IP address
results = netbox_search_objects('192.168.1.100')
# Returns: {
# 'ipam.ipaddress': [{'id': 42, 'address': '192.168.1.100/24', ...}],
# ...
# }
# Limit search to specific types with field projection
results = netbox_search_objects(
'NYC',
object_types=['dcim.site', 'dcim.location'],
fields=['id', 'name', 'status']
)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | ||
| query | Yes | ||
| fields | No | ||
| object_types | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||