Rename certain filters to be consistent #9348

Closed
opened 2025-12-29 20:48:52 +01:00 by adam · 0 comments
Owner

Originally created by @jeremystretch on GitHub (Mar 12, 2024).

Originally assigned to: @arthanson on GitHub.

Proposed Changes

As of v4.0, both names for the filters listed below are supported. In v4.1, support for the old names will be dropped.

Model Old filter New filter
Component templates devicetype_id device_type_id
Component templates moduletype_id module_type_id
extras.ConfigContext role device_role
extras.ConfigContext role_id device_role_id
ipam.Service ipaddress ip_address
ipam.Service ipaddress_id ip_address_id
ipam.VLANGroup sitegroup site_group
ipam.VLANGroup clustergroup cluster_group
vpn.IKEPolicy proposal ike_proposal
vpn.IKEPolicy proposal_id ike_proposal_id
vpn.IPSecPolicy proposal ipsec_proposal
vpn.IPSecPolicy proposal_id ipsec_proposal_id

Justification

Renaming these filters makes them consistent with how other filters in NetBox are named, which enables automated testing and helps avoid user confusion.

Impact

Both names for each filter listed above work in NetBox v4.0. Any API consumers which utilize the listed filters will need to be updated to use the new name for NetBox v4.1.

Originally created by @jeremystretch on GitHub (Mar 12, 2024). Originally assigned to: @arthanson on GitHub. ### Proposed Changes As of v4.0, both names for the filters listed below are supported. In v4.1, support for the old names will be dropped. | Model | Old filter | New filter | |-----------------------|---------------|-------------------| | _Component templates_ | devicetype_id | device_type_id | | _Component templates_ | moduletype_id | module_type_id | | extras.ConfigContext | role | device_role | | extras.ConfigContext | role_id | device_role_id | | ipam.Service | ipaddress | ip_address | | ipam.Service | ipaddress_id | ip_address_id | | ipam.VLANGroup | sitegroup | site_group | | ipam.VLANGroup | clustergroup | cluster_group | | vpn.IKEPolicy | proposal | ike_proposal | | vpn.IKEPolicy | proposal_id | ike_proposal_id | | vpn.IPSecPolicy | proposal | ipsec_proposal | | vpn.IPSecPolicy | proposal_id | ipsec_proposal_id | ### Justification Renaming these filters makes them consistent with how other filters in NetBox are named, which enables automated testing and helps avoid user confusion. ### Impact Both names for each filter listed above work in NetBox v4.0. Any API consumers which utilize the listed filters will need to be updated to use the new name for NetBox v4.1.
adam added the status: acceptedtype: deprecationbreaking change labels 2025-12-29 20:48:52 +01:00
adam closed this issue 2025-12-29 20:48:53 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#9348