Add search for custom fields to device, device-virtual-context and virtual machine API #8684

Closed
opened 2025-12-29 20:39:53 +01:00 by adam · 3 comments
Owner

Originally created by @empusas on GitHub (Sep 27, 2023).

NetBox version

v3.6.3

Feature type

New functionality

Proposed functionality

We have used the customer fields to store some supplemental data to sync our data with ServiceNow. The problem I am facing is that if I need to get a specific device, context or vm by this reference, the only possible way right now is to pull all data and then search thru the data to find a match.
This is of course not very efficient, it uses lots of resources on the net box system and on the automation server.
On the net box system itself this would be just a simple DB query which is way more sufficient.
We ended up having a simple sqllight db for the mapping only, but that requires a UI etc to manage it.

Use case

When a device, context or vm should be fetched via API from netbox if a customer field has a certain value.

Database changes

none

External dependencies

add search field to API for custom field content

Originally created by @empusas on GitHub (Sep 27, 2023). ### NetBox version v3.6.3 ### Feature type New functionality ### Proposed functionality We have used the customer fields to store some supplemental data to sync our data with ServiceNow. The problem I am facing is that if I need to get a specific device, context or vm by this reference, the only possible way right now is to pull all data and then search thru the data to find a match. This is of course not very efficient, it uses lots of resources on the net box system and on the automation server. On the net box system itself this would be just a simple DB query which is way more sufficient. We ended up having a simple sqllight db for the mapping only, but that requires a UI etc to manage it. ### Use case When a device, context or vm should be fetched via API from netbox if a customer field has a certain value. ### Database changes none ### External dependencies add search field to API for custom field content
adam added the type: featurestatus: revisions needed labels 2025-12-29 20:39:53 +01:00
adam closed this issue 2025-12-29 20:39:53 +01:00
Author
Owner

@jeremystretch commented on GitHub (Nov 6, 2023):

Thank you for your interest in extending NetBox. Unfortunately, the information you have provided does not constitute an actionable feature request. Per our contributing guide, a feature request must include a thorough description of the proposed functionality, including any database changes, new views or API endpoints, and so on. It must also include a detailed use case justifying its implementation. If you would like to elaborate on your proposal, please modify your post above. If sufficient detail is not added, this issue will be closed.

@jeremystretch commented on GitHub (Nov 6, 2023): Thank you for your interest in extending NetBox. Unfortunately, the information you have provided does not constitute an actionable feature request. Per our [contributing guide](https://github.com/netbox-community/netbox/blob/develop/CONTRIBUTING.md), a feature request must include a thorough description of the proposed functionality, including any database changes, new views or API endpoints, and so on. It must also include a detailed use case justifying its implementation. If you would like to elaborate on your proposal, please modify your post above. If sufficient detail is not added, this issue will be closed.
Author
Owner

@jeremystretch commented on GitHub (Dec 8, 2023):

This issue is being closed as no further information has been provided. If you would like to revisit this topic, please first modify your original post to include all the requested detail, and then ask that the issue be reopened.

@jeremystretch commented on GitHub (Dec 8, 2023): This issue is being closed as no further information has been provided. If you would like to revisit this topic, please first modify your original post to include all the requested detail, and then ask that the issue be reopened.
Author
Owner

@konstantin-volkov-db commented on GitHub (Jan 4, 2024):

Hi, I have similar need with netbox. Could you please suggest how to search config context data? I would like to find all config contexts (or device names) which contain specific string in it's context data. Thank you.

@konstantin-volkov-db commented on GitHub (Jan 4, 2024): Hi, I have similar need with netbox. Could you please suggest how to search config context data? I would like to find all config contexts (or device names) which contain specific string in it's context data. Thank you.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#8684