Deep merge for Config Context Data Set via API #2491

Closed
opened 2025-12-29 18:19:19 +01:00 by adam · 1 comment
Owner

Originally created by @dnyt84 on GitHub (Apr 3, 2019).

Environment

  • Python version: 3.6.3
  • NetBox version: 2.5.8

Proposed Functionality
Currently when doing an API Patch to /extras/config-contexts/{id}/ it overwrites all existing Data stored.

Use Case
A Deep merge feature would make smaller changes easier as I would not necessary need to know what else is stored in the Data set.

I would imagine this could be done via a new API endpoint
/extras/config-contexts-merge/{id}/
or possibly via a flag that would allow a deep merge or overwrite.

We would not want to loose the option to complacently overwrite the current Data Set.
Database Changes
None
External Dependencies
None

Originally created by @dnyt84 on GitHub (Apr 3, 2019). **Environment** * Python version: 3.6.3 * NetBox version: 2.5.8 **Proposed Functionality** Currently when doing an API Patch to /extras/config-contexts/{id}/ it overwrites all existing Data stored. **Use Case** A Deep merge feature would make smaller changes easier as I would not necessary need to know what else is stored in the Data set. I would imagine this could be done via a new API endpoint /extras/config-contexts-merge/{id}/ or possibly via a flag that would allow a deep merge or overwrite. We would not want to loose the option to complacently overwrite the current Data Set. **Database Changes** None **External Dependencies** None
adam closed this issue 2025-12-29 18:19:19 +01:00
Author
Owner

@jeremystretch commented on GitHub (Apr 4, 2019):

This would deviate from the expected behavior of the REST API, which is standard across all objects. You'll need to retrieve the data first and then update accordingly.

@jeremystretch commented on GitHub (Apr 4, 2019): This would deviate from the expected behavior of the REST API, which is standard across all objects. You'll need to retrieve the data first and then update accordingly.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#2491