Skip to content

Commit bec09cf

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit e78ef8d of spec repo
1 parent aae9a2e commit bec09cf

3 files changed

Lines changed: 41 additions & 9 deletions

File tree

‎.generator/schemas/v2/openapi.yaml‎

Lines changed: 23 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2381,6 +2381,18 @@ components:
23812381
schema:
23822382
$ref: "#/components/schemas/HTTPCDRulesNotFoundResponse"
23832383
description: Deployment rule not found.
2384+
NDMBadRequestResponse:
2385+
content:
2386+
application/json:
2387+
schema:
2388+
$ref: "#/components/schemas/JSONAPIErrorResponse"
2389+
description: Bad Request
2390+
NDMNotFoundResponse:
2391+
content:
2392+
application/json:
2393+
schema:
2394+
$ref: "#/components/schemas/JSONAPIErrorResponse"
2395+
description: Not Found
23842396
NotAuthorizedResponse:
23852397
content:
23862398
"application/json":
@@ -203394,7 +203406,7 @@ paths:
203394203406
parameters:
203395203407
- $ref: "#/components/parameters/NDMPageSize"
203396203408
- $ref: "#/components/parameters/NDMPageNumber"
203397-
- description: The field to sort the devices by. Defaults to `name`.
203409+
- description: The field to sort devices by. Defaults to `name`. Prefix the field with `-` to sort in descending order, for example, `-name`.
203398203410
example: status
203399203411
in: query
203400203412
name: sort
@@ -203432,7 +203444,7 @@ paths:
203432203444
$ref: "#/components/schemas/ListDevicesResponse"
203433203445
description: OK
203434203446
"400":
203435-
$ref: "#/components/responses/BadRequestResponse"
203447+
$ref: "#/components/responses/NDMBadRequestResponse"
203436203448
"403":
203437203449
$ref: "#/components/responses/ForbiddenResponse"
203438203450
"429":
@@ -203480,7 +203492,7 @@ paths:
203480203492
"403":
203481203493
$ref: "#/components/responses/ForbiddenResponse"
203482203494
"404":
203483-
$ref: "#/components/responses/NotFoundResponse"
203495+
$ref: "#/components/responses/NDMNotFoundResponse"
203484203496
"429":
203485203497
$ref: "#/components/responses/TooManyRequestsResponse"
203486203498
summary: Get the device details
@@ -203577,7 +203589,7 @@ paths:
203577203589
"403":
203578203590
$ref: "#/components/responses/ForbiddenResponse"
203579203591
"404":
203580-
$ref: "#/components/responses/NotFoundResponse"
203592+
$ref: "#/components/responses/NDMNotFoundResponse"
203581203593
"429":
203582203594
$ref: "#/components/responses/TooManyRequestsResponse"
203583203595
summary: Get the list of tags for a device
@@ -203629,10 +203641,12 @@ paths:
203629203641
schema:
203630203642
$ref: "#/components/schemas/ListTagsResponse"
203631203643
description: OK
203644+
"400":
203645+
$ref: "#/components/responses/NDMBadRequestResponse"
203632203646
"403":
203633203647
$ref: "#/components/responses/ForbiddenResponse"
203634203648
"404":
203635-
$ref: "#/components/responses/NotFoundResponse"
203649+
$ref: "#/components/responses/NDMNotFoundResponse"
203636203650
"429":
203637203651
$ref: "#/components/responses/TooManyRequestsResponse"
203638203652
summary: Update the tags for a device
@@ -203670,7 +203684,7 @@ paths:
203670203684
"403":
203671203685
$ref: "#/components/responses/ForbiddenResponse"
203672203686
"404":
203673-
$ref: "#/components/responses/NotFoundResponse"
203687+
$ref: "#/components/responses/NDMNotFoundResponse"
203674203688
"429":
203675203689
$ref: "#/components/responses/TooManyRequestsResponse"
203676203690
summary: List tags for an interface
@@ -203720,10 +203734,12 @@ paths:
203720203734
schema:
203721203735
$ref: "#/components/schemas/ListInterfaceTagsResponse"
203722203736
description: OK
203737+
"400":
203738+
$ref: "#/components/responses/NDMBadRequestResponse"
203723203739
"403":
203724203740
$ref: "#/components/responses/ForbiddenResponse"
203725203741
"404":
203726-
$ref: "#/components/responses/NotFoundResponse"
203742+
$ref: "#/components/responses/NDMNotFoundResponse"
203727203743
"429":
203728203744
$ref: "#/components/responses/TooManyRequestsResponse"
203729203745
summary: Update the tags for an interface

‎src/datadog_api_client/v2/api/network_device_monitoring_api.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,7 @@ def list_devices(
275275
:type page_size: int, optional
276276
:param page_number: Specific page number to return. Defaults to 0.
277277
:type page_number: int, optional
278-
:param sort: The field to sort the devices by. Defaults to ``name``.
278+
:param sort: The field to sort devices by. Defaults to ``name``. Prefix the field with ``-`` to sort in descending order, for example, ``-name``.
279279
:type sort: str, optional
280280
:param filter_tag: Filter devices by tag.
281281
:type filter_tag: str, optional
@@ -312,7 +312,7 @@ def list_devices_with_pagination(
312312
:type page_size: int, optional
313313
:param page_number: Specific page number to return. Defaults to 0.
314314
:type page_number: int, optional
315-
:param sort: The field to sort the devices by. Defaults to ``name``.
315+
:param sort: The field to sort devices by. Defaults to ``name``. Prefix the field with ``-`` to sort in descending order, for example, ``-name``.
316316
:type sort: str, optional
317317
:param filter_tag: Filter devices by tag.
318318
:type filter_tag: str, optional

‎tests/v2/features/network_device_monitoring.feature‎

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,14 @@ Feature: Network Device Monitoring
142142
And the response "data.attributes.tags[0]" is equal to "tag:test"
143143
And the response "data.attributes.tags[1]" is equal to "tag:testbis"
144144

145+
@generated @skip @team:ddoghq/network-device-monitoring
146+
Scenario: Update the tags for a device returns "Bad Request" response
147+
Given new "UpdateDeviceUserTags" request
148+
And request contains "device_id" parameter from "REPLACE.ME"
149+
And body with value {"data": {"attributes": {"tags": ["tag:test", "tag:testbis"]}, "id": "example:1.2.3.4"}}
150+
When the request is sent
151+
Then the response status is 400 Bad Request
152+
145153
@replay-only @team:ddoghq/network-device-monitoring
146154
Scenario: Update the tags for a device returns "Not Found" response
147155
Given new "UpdateDeviceUserTags" request
@@ -162,6 +170,14 @@ Feature: Network Device Monitoring
162170
And the response "data.attributes.tags[0]" is equal to "tag:test"
163171
And the response "data.attributes.tags[1]" is equal to "tag:testbis"
164172

173+
@generated @skip @team:ddoghq/network-device-monitoring
174+
Scenario: Update the tags for an interface returns "Bad Request" response
175+
Given new "UpdateInterfaceUserTags" request
176+
And request contains "interface_id" parameter from "REPLACE.ME"
177+
And body with value {"data": {"attributes": {"tags": ["tag:test", "tag:testbis"]}, "id": "example:1.2.3.4:1"}}
178+
When the request is sent
179+
Then the response status is 400 Bad Request
180+
165181
@replay-only @team:ddoghq/network-device-monitoring
166182
Scenario: Update the tags for an interface returns "Not Found" response
167183
Given new "UpdateInterfaceUserTags" request

0 commit comments

Comments
 (0)