Skip to content

Commit a95a478

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 71ffdbc of spec repo
1 parent 963308b commit a95a478

File tree

10 files changed

+382
-199
lines changed

10 files changed

+382
-199
lines changed

.generator/schemas/v1/openapi.yaml

Lines changed: 50 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -4179,7 +4179,7 @@ components:
41794179
example: false
41804180
type: boolean
41814181
type: object
4182-
HostTags:
4182+
HostTagsInput:
41834183
description: Set of tags to associate with your host.
41844184
properties:
41854185
host:
@@ -4194,6 +4194,21 @@ components:
41944194
type: string
41954195
type: array
41964196
type: object
4197+
HostTagsOutput:
4198+
description: Host name and an array of its tags
4199+
properties:
4200+
host:
4201+
description: Your host name.
4202+
example: test.host
4203+
type: string
4204+
tags:
4205+
description: A list of tags attached to a given host.
4206+
items:
4207+
description: A given tag in a list.
4208+
example: environment:production
4209+
type: string
4210+
type: array
4211+
type: object
41974212
HostTotals:
41984213
description: Total number of host currently monitored by Datadog.
41994214
properties:
@@ -18689,18 +18704,18 @@ components:
1868918704
- match
1869018705
type: object
1869118706
TagToHosts:
18692-
description: In this object, the key is the tag, the value is a list of host
18693-
names that are reporting that tag.
18707+
description: In this object, the key is the tag, and the value is a list of
18708+
host names that are reporting that tag.
1869418709
properties:
1869518710
tags:
1869618711
additionalProperties:
18697-
description: A list of additional properties for tags.
18712+
description: A list of host names which contain this tag
1869818713
items:
1869918714
description: A given tag in a list.
1870018715
example: test.metric.host
1870118716
type: string
1870218717
type: array
18703-
description: A list of tags to apply to the host.
18718+
description: A mapping of tags to host names
1870418719
type: object
1870518720
type: object
1870618721
TargetFormatType:
@@ -35712,11 +35727,13 @@ paths:
3571235727
- synthetics_global_variable_write
3571335728
/api/v1/tags/hosts:
3571435729
get:
35715-
description: Return a mapping of tags to hosts for your whole infrastructure.
35730+
description: Returns a mapping of tags to hosts. For each tag, the response
35731+
returns a list of host names that contain this tag. There is a restriction
35732+
of 10k total host names from the org that can be attached to tags and returned.
3571635733
operationId: ListHostTags
3571735734
parameters:
35718-
- description: When specified, filters host list to those tags with the specified
35719-
source.
35735+
- description: Source to filter. [Complete list of source attribute values](https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value).
35736+
Use "user" source for custom-defined tags.
3572035737
in: query
3572135738
name: source
3572235739
required: false
@@ -35747,29 +35764,28 @@ paths:
3574735764
- apiKeyAuth: []
3574835765
appKeyAuth: []
3574935766
- AuthZ: []
35750-
summary: Get Tags
35767+
summary: Get All Host Tags
3575135768
tags:
3575235769
- Tags
3575335770
x-permission:
3575435771
operator: OPEN
3575535772
permissions: []
3575635773
/api/v1/tags/hosts/{host_name}:
3575735774
delete:
35758-
description: 'This endpoint allows you to remove all user-assigned tags
35775+
description: 'This endpoint allows you to remove all tags
3575935776

35760-
for a single host.'
35777+
for a single host. If no source is specified, only deletes tags with no source.'
3576135778
operationId: DeleteHostTags
3576235779
parameters:
35763-
- description: This endpoint allows you to remove all user-assigned tags for
35764-
a single host.
35780+
- description: Specified host name to delete tags
3576535781
in: path
3576635782
name: host_name
3576735783
required: true
3576835784
schema:
3576935785
type: string
35770-
- description: 'The source of the tags (for example chef, puppet).
35771-
35772-
[Complete list of source attribute values](https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value).'
35786+
- description: Source of the tags to be deleted. [Complete list of source attribute
35787+
values](https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value).
35788+
Use "user" source for custom-defined tags.
3577335789
in: query
3577435790
name: source
3577535791
required: false
@@ -35799,14 +35815,14 @@ paths:
3579935815
description: Return the list of tags that apply to a given host.
3580035816
operationId: GetHostTags
3580135817
parameters:
35802-
- description: When specified, filters list of tags to those tags with the specified
35803-
source.
35818+
- description: Name of the host to retrieve tags for
3580435819
in: path
3580535820
name: host_name
3580635821
required: true
3580735822
schema:
3580835823
type: string
35809-
- description: Source to filter.
35824+
- description: Source to filter. [Complete list of source attribute values](https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value).
35825+
Use "user" source for custom-defined tags.
3581035826
in: query
3581135827
name: source
3581235828
required: false
@@ -35817,7 +35833,7 @@ paths:
3581735833
content:
3581835834
application/json:
3581935835
schema:
35820-
$ref: '#/components/schemas/HostTags'
35836+
$ref: '#/components/schemas/HostTagsOutput'
3582135837
description: OK
3582235838
'403':
3582335839
content:
@@ -35833,25 +35849,23 @@ paths:
3583335849
description: Not Found
3583435850
'429':
3583535851
$ref: '#/components/responses/TooManyRequestsResponse'
35836-
summary: Get host tags
35852+
summary: Get Host Tags
3583735853
tags:
3583835854
- Tags
3583935855
post:
3584035856
description: 'This endpoint allows you to add new tags to a host,
3584135857

35842-
optionally specifying where these tags come from.'
35858+
optionally specifying what source these tags come from.'
3584335859
operationId: CreateHostTags
3584435860
parameters:
35845-
- description: This endpoint allows you to add new tags to a host, optionally
35846-
specifying where the tags came from.
35861+
- description: Specified host name to add new tags
3584735862
in: path
3584835863
name: host_name
3584935864
required: true
3585035865
schema:
3585135866
type: string
35852-
- description: 'The source of the tags.
35853-
35854-
[Complete list of source attribute values](https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value).'
35867+
- description: Source to filter. [Complete list of source attribute values](https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value).
35868+
Use "user" source for custom-defined tags.
3585535869
example: chef
3585635870
in: query
3585735871
name: source
@@ -35862,15 +35876,15 @@ paths:
3586235876
content:
3586335877
application/json:
3586435878
schema:
35865-
$ref: '#/components/schemas/HostTags'
35879+
$ref: '#/components/schemas/HostTagsInput'
3586635880
description: Update host tags request body.
3586735881
required: true
3586835882
responses:
3586935883
'201':
3587035884
content:
3587135885
application/json:
3587235886
schema:
35873-
$ref: '#/components/schemas/HostTags'
35887+
$ref: '#/components/schemas/HostTagsOutput'
3587435888
description: Created
3587535889
'403':
3587635890
content:
@@ -35896,16 +35910,14 @@ paths:
3589635910
an integration source with those supplied in the request.'
3589735911
operationId: UpdateHostTags
3589835912
parameters:
35899-
- description: This endpoint allows you to update/replace all in an integration
35900-
source with those supplied in the request.
35913+
- description: Specified host name to change tags
3590135914
in: path
3590235915
name: host_name
3590335916
required: true
3590435917
schema:
3590535918
type: string
35906-
- description: 'The source of the tags (for example chef, puppet).
35907-
35908-
[Complete list of source attribute values](https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value)'
35919+
- description: Source to filter. [Complete list of source attribute values](https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value).
35920+
Use "user" source for custom-defined tags.
3590935921
in: query
3591035922
name: source
3591135923
required: false
@@ -35915,15 +35927,15 @@ paths:
3591535927
content:
3591635928
application/json:
3591735929
schema:
35918-
$ref: '#/components/schemas/HostTags'
35930+
$ref: '#/components/schemas/HostTagsInput'
3591935931
description: Add tags to host
3592035932
required: true
3592135933
responses:
3592235934
'201':
3592335935
content:
3592435936
application/json:
3592535937
schema:
35926-
$ref: '#/components/schemas/HostTags'
35938+
$ref: '#/components/schemas/HostTagsOutput'
3592735939
description: OK
3592835940
'403':
3592935941
content:
@@ -38918,7 +38930,8 @@ tags:
3891838930

3891938931
by a source. For example, some valid sources include nagios, hudson, jenkins,
3892038932

38921-
users, feed, chef, puppet, git, bitbucket, fabric, capistrano, etc.
38933+
users, feed, chef, puppet, git, bitbucket, fabric, capistrano, etc. Find a complete
38934+
list of source type names under [API Source Attributes](https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value).
3892238935

3892338936

3892438937
Read more about tags on [Getting Started with Tags](https://docs.datadoghq.com/getting_started/tagging/).'

examples/v1/tags/CreateHostTags.java

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,22 @@
33
import com.datadog.api.client.ApiClient;
44
import com.datadog.api.client.ApiException;
55
import com.datadog.api.client.v1.api.TagsApi;
6-
import com.datadog.api.client.v1.model.HostTags;
6+
import com.datadog.api.client.v1.model.HostTagsInput;
7+
import com.datadog.api.client.v1.model.HostTagsOutput;
78
import java.util.Collections;
89

910
public class Example {
1011
public static void main(String[] args) {
1112
ApiClient defaultClient = ApiClient.getDefaultApiClient();
1213
TagsApi apiInstance = new TagsApi(defaultClient);
1314

14-
HostTags body =
15-
new HostTags().host("test.host").tags(Collections.singletonList("environment:production"));
15+
HostTagsInput body =
16+
new HostTagsInput()
17+
.host("test.host")
18+
.tags(Collections.singletonList("environment:production"));
1619

1720
try {
18-
HostTags result = apiInstance.createHostTags("host_name", body);
21+
HostTagsOutput result = apiInstance.createHostTags("host_name", body);
1922
System.out.println(result);
2023
} catch (ApiException e) {
2124
System.err.println("Exception when calling TagsApi#createHostTags");

examples/v1/tags/GetHostTags.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
1-
// Get host tags returns "OK" response
1+
// Get Host Tags returns "OK" response
22

33
import com.datadog.api.client.ApiClient;
44
import com.datadog.api.client.ApiException;
55
import com.datadog.api.client.v1.api.TagsApi;
6-
import com.datadog.api.client.v1.model.HostTags;
6+
import com.datadog.api.client.v1.model.HostTagsOutput;
77

88
public class Example {
99
public static void main(String[] args) {
1010
ApiClient defaultClient = ApiClient.getDefaultApiClient();
1111
TagsApi apiInstance = new TagsApi(defaultClient);
1212

1313
try {
14-
HostTags result = apiInstance.getHostTags("host_name");
14+
HostTagsOutput result = apiInstance.getHostTags("host_name");
1515
System.out.println(result);
1616
} catch (ApiException e) {
1717
System.err.println("Exception when calling TagsApi#getHostTags");

examples/v1/tags/ListHostTags.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Get Tags returns "OK" response
1+
// Get All Host Tags returns "OK" response
22

33
import com.datadog.api.client.ApiClient;
44
import com.datadog.api.client.ApiException;

examples/v1/tags/UpdateHostTags.java

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,22 @@
33
import com.datadog.api.client.ApiClient;
44
import com.datadog.api.client.ApiException;
55
import com.datadog.api.client.v1.api.TagsApi;
6-
import com.datadog.api.client.v1.model.HostTags;
6+
import com.datadog.api.client.v1.model.HostTagsInput;
7+
import com.datadog.api.client.v1.model.HostTagsOutput;
78
import java.util.Collections;
89

910
public class Example {
1011
public static void main(String[] args) {
1112
ApiClient defaultClient = ApiClient.getDefaultApiClient();
1213
TagsApi apiInstance = new TagsApi(defaultClient);
1314

14-
HostTags body =
15-
new HostTags().host("test.host").tags(Collections.singletonList("environment:production"));
15+
HostTagsInput body =
16+
new HostTagsInput()
17+
.host("test.host")
18+
.tags(Collections.singletonList("environment:production"));
1619

1720
try {
18-
HostTags result = apiInstance.updateHostTags("host_name", body);
21+
HostTagsOutput result = apiInstance.updateHostTags("host_name", body);
1922
System.out.println(result);
2023
} catch (ApiException e) {
2124
System.err.println("Exception when calling TagsApi#updateHostTags");

0 commit comments

Comments
 (0)