1919from datadog_api_client .v2 .model .get_device_response import GetDeviceResponse
2020from datadog_api_client .v2 .model .get_interfaces_response import GetInterfacesResponse
2121from datadog_api_client .v2 .model .list_tags_response import ListTagsResponse
22+ from datadog_api_client .v2 .model .list_interface_tags_response import ListInterfaceTagsResponse
2223
2324
2425class NetworkDeviceMonitoringApi :
@@ -142,6 +143,29 @@ def __init__(self, api_client=None):
142143 api_client = api_client ,
143144 )
144145
146+ self ._list_interface_user_tags_endpoint = _Endpoint (
147+ settings = {
148+ "response_type" : (ListInterfaceTagsResponse ,),
149+ "auth" : ["apiKeyAuth" , "appKeyAuth" ],
150+ "endpoint_path" : "/api/v2/ndm/tags/interfaces/{interface_id}" ,
151+ "operation_id" : "list_interface_user_tags" ,
152+ "http_method" : "GET" ,
153+ "version" : "v2" ,
154+ },
155+ params_map = {
156+ "interface_id" : {
157+ "required" : True ,
158+ "openapi_types" : (str ,),
159+ "attribute" : "interface_id" ,
160+ "location" : "path" ,
161+ },
162+ },
163+ headers_map = {
164+ "accept" : ["application/json" ],
165+ },
166+ api_client = api_client ,
167+ )
168+
145169 self ._update_device_user_tags_endpoint = _Endpoint (
146170 settings = {
147171 "response_type" : (ListTagsResponse ,),
@@ -168,6 +192,32 @@ def __init__(self, api_client=None):
168192 api_client = api_client ,
169193 )
170194
195+ self ._update_interface_user_tags_endpoint = _Endpoint (
196+ settings = {
197+ "response_type" : (ListInterfaceTagsResponse ,),
198+ "auth" : ["apiKeyAuth" , "appKeyAuth" ],
199+ "endpoint_path" : "/api/v2/ndm/tags/interfaces/{interface_id}" ,
200+ "operation_id" : "update_interface_user_tags" ,
201+ "http_method" : "PATCH" ,
202+ "version" : "v2" ,
203+ },
204+ params_map = {
205+ "interface_id" : {
206+ "required" : True ,
207+ "openapi_types" : (str ,),
208+ "attribute" : "interface_id" ,
209+ "location" : "path" ,
210+ },
211+ "body" : {
212+ "required" : True ,
213+ "openapi_types" : (ListInterfaceTagsResponse ,),
214+ "location" : "body" ,
215+ },
216+ },
217+ headers_map = {"accept" : ["application/json" ], "content_type" : ["application/json" ]},
218+ api_client = api_client ,
219+ )
220+
171221 def get_device (
172222 self ,
173223 device_id : str ,
@@ -312,6 +362,23 @@ def list_device_user_tags(
312362
313363 return self ._list_device_user_tags_endpoint .call_with_http_info (** kwargs )
314364
365+ def list_interface_user_tags (
366+ self ,
367+ interface_id : str ,
368+ ) -> ListInterfaceTagsResponse :
369+ """List tags for an interface.
370+
371+ Returns the tags associated with the specified interface.
372+
373+ :param interface_id: The ID of the interface for which to retrieve tags.
374+ :type interface_id: str
375+ :rtype: ListInterfaceTagsResponse
376+ """
377+ kwargs : Dict [str , Any ] = {}
378+ kwargs ["interface_id" ] = interface_id
379+
380+ return self ._list_interface_user_tags_endpoint .call_with_http_info (** kwargs )
381+
315382 def update_device_user_tags (
316383 self ,
317384 device_id : str ,
@@ -332,3 +399,24 @@ def update_device_user_tags(
332399 kwargs ["body" ] = body
333400
334401 return self ._update_device_user_tags_endpoint .call_with_http_info (** kwargs )
402+
403+ def update_interface_user_tags (
404+ self ,
405+ interface_id : str ,
406+ body : ListInterfaceTagsResponse ,
407+ ) -> ListInterfaceTagsResponse :
408+ """Update the tags for an interface.
409+
410+ Updates the tags associated with the specified interface.
411+
412+ :param interface_id: The ID of the interface for which to update tags.
413+ :type interface_id: str
414+ :type body: ListInterfaceTagsResponse
415+ :rtype: ListInterfaceTagsResponse
416+ """
417+ kwargs : Dict [str , Any ] = {}
418+ kwargs ["interface_id" ] = interface_id
419+
420+ kwargs ["body" ] = body
421+
422+ return self ._update_interface_user_tags_endpoint .call_with_http_info (** kwargs )
0 commit comments