Skip to content

Commit ea9ae88

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit e1c5b899 of spec repo
1 parent 065e443 commit ea9ae88

13 files changed

Lines changed: 1401 additions & 4 deletions

File tree

.apigentools-info

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"spec_versions": {
55
"v1": {
66
"apigentools_version": "1.6.6",
7-
"regenerated": "2025-05-23 14:41:13.594077",
8-
"spec_repo_commit": "a4ecd4cf"
7+
"regenerated": "2025-05-23 16:10:02.658196",
8+
"spec_repo_commit": "e1c5b899"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2025-05-23 14:41:13.611442",
13-
"spec_repo_commit": "a4ecd4cf"
12+
"regenerated": "2025-05-23 16:10:02.676541",
13+
"spec_repo_commit": "e1c5b899"
1414
}
1515
}
1616
}

.generator/schemas/v2/openapi.yaml

Lines changed: 180 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2157,6 +2157,14 @@ components:
21572157
type: string
21582158
x-enum-varnames:
21592159
- BILLING_DIMENSIONS
2160+
AddMemberTeamRequest:
2161+
description: Request to add a member team to super team's hierarchy
2162+
properties:
2163+
data:
2164+
$ref: '#/components/schemas/MemberTeam'
2165+
required:
2166+
- data
2167+
type: object
21602168
Advisory:
21612169
description: Advisory.
21622170
properties:
@@ -20814,6 +20822,28 @@ components:
2081420822
- ms_channel_name
2081520823
- redirect_url
2081620824
type: object
20825+
MemberTeam:
20826+
description: A member team
20827+
properties:
20828+
id:
20829+
description: The member team's identifier
20830+
example: aeadc05e-98a8-11ec-ac2c-da7ad0900001
20831+
type: string
20832+
type:
20833+
$ref: '#/components/schemas/MemberTeamType'
20834+
required:
20835+
- id
20836+
- type
20837+
type: object
20838+
MemberTeamType:
20839+
default: member_teams
20840+
description: Member team type
20841+
enum:
20842+
- member_teams
20843+
example: member_teams
20844+
type: string
20845+
x-enum-varnames:
20846+
- MEMBER_TEAMS
2081720847
Metadata:
2081820848
description: The metadata related to this request.
2081920849
properties:
@@ -59331,6 +59361,156 @@ paths:
5933159361
permissions:
5933259362
- teams_read
5933359363
- teams_manage
59364+
/api/v2/team/{super_team_id}/member_teams:
59365+
get:
59366+
description: Get all member teams.
59367+
operationId: ListMemberTeams
59368+
parameters:
59369+
- description: None
59370+
in: path
59371+
name: super_team_id
59372+
required: true
59373+
schema:
59374+
type: string
59375+
- $ref: '#/components/parameters/PageSize'
59376+
- $ref: '#/components/parameters/PageNumber'
59377+
- description: List of fields that need to be fetched.
59378+
explode: false
59379+
in: query
59380+
name: fields[team]
59381+
required: false
59382+
schema:
59383+
items:
59384+
$ref: '#/components/schemas/TeamsField'
59385+
type: array
59386+
responses:
59387+
'200':
59388+
content:
59389+
application/json:
59390+
schema:
59391+
$ref: '#/components/schemas/TeamsResponse'
59392+
description: OK
59393+
'403':
59394+
$ref: '#/components/responses/ForbiddenResponse'
59395+
'404':
59396+
content:
59397+
application/json:
59398+
schema:
59399+
$ref: '#/components/schemas/APIErrorResponse'
59400+
description: API error response.
59401+
'429':
59402+
$ref: '#/components/responses/TooManyRequestsResponse'
59403+
security:
59404+
- apiKeyAuth: []
59405+
appKeyAuth: []
59406+
- AuthZ:
59407+
- teams_read
59408+
summary: Get all member teams
59409+
tags:
59410+
- Teams
59411+
x-pagination:
59412+
limitParam: page[size]
59413+
pageParam: page[number]
59414+
resultsPath: data
59415+
x-permission:
59416+
operator: OR
59417+
permissions:
59418+
- teams_read
59419+
x-unstable: '**Note**: This endpoint is in Preview. If you have any feedback,
59420+
59421+
contact [Datadog support](https://docs.datadoghq.com/help/).'
59422+
post:
59423+
description: 'Add a member team.
59424+
59425+
Adds the team given by the `id` in the body as a member team of the super
59426+
team.'
59427+
operationId: AddMemberTeam
59428+
parameters:
59429+
- description: None
59430+
in: path
59431+
name: super_team_id
59432+
required: true
59433+
schema:
59434+
type: string
59435+
requestBody:
59436+
content:
59437+
application/json:
59438+
schema:
59439+
$ref: '#/components/schemas/AddMemberTeamRequest'
59440+
required: true
59441+
responses:
59442+
'204':
59443+
description: Added
59444+
'403':
59445+
$ref: '#/components/responses/ForbiddenResponse'
59446+
'409':
59447+
content:
59448+
application/json:
59449+
schema:
59450+
$ref: '#/components/schemas/APIErrorResponse'
59451+
description: API error response.
59452+
'429':
59453+
$ref: '#/components/responses/TooManyRequestsResponse'
59454+
security:
59455+
- apiKeyAuth: []
59456+
appKeyAuth: []
59457+
- AuthZ:
59458+
- teams_read
59459+
summary: Add a member team
59460+
tags:
59461+
- Teams
59462+
x-permission:
59463+
operator: OR
59464+
permissions:
59465+
- teams_read
59466+
x-unstable: '**Note**: This endpoint is in Preview. If you have any feedback,
59467+
59468+
contact [Datadog support](https://docs.datadoghq.com/help/).'
59469+
/api/v2/team/{super_team_id}/member_teams/{member_team_id}:
59470+
delete:
59471+
description: Remove a super team's member team identified by `member_team_id`.
59472+
operationId: RemoveMemberTeam
59473+
parameters:
59474+
- description: None
59475+
in: path
59476+
name: super_team_id
59477+
required: true
59478+
schema:
59479+
type: string
59480+
- description: None
59481+
in: path
59482+
name: member_team_id
59483+
required: true
59484+
schema:
59485+
type: string
59486+
responses:
59487+
'204':
59488+
description: No Content
59489+
'403':
59490+
$ref: '#/components/responses/ForbiddenResponse'
59491+
'404':
59492+
content:
59493+
application/json:
59494+
schema:
59495+
$ref: '#/components/schemas/APIErrorResponse'
59496+
description: API error response.
59497+
'429':
59498+
$ref: '#/components/responses/TooManyRequestsResponse'
59499+
security:
59500+
- apiKeyAuth: []
59501+
appKeyAuth: []
59502+
- AuthZ:
59503+
- teams_read
59504+
summary: Remove a member team
59505+
tags:
59506+
- Teams
59507+
x-permission:
59508+
operator: OR
59509+
permissions:
59510+
- teams_read
59511+
x-unstable: '**Note**: This endpoint is in Preview. If you have any feedback,
59512+
59513+
contact [Datadog support](https://docs.datadoghq.com/help/).'
5933459514
/api/v2/team/{team_id}:
5933559515
delete:
5933659516
description: Remove a team using the team's `id`.
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
// Add a member team returns "Added" response
2+
3+
import com.datadog.api.client.ApiClient;
4+
import com.datadog.api.client.ApiException;
5+
import com.datadog.api.client.v2.api.TeamsApi;
6+
import com.datadog.api.client.v2.model.AddMemberTeamRequest;
7+
import com.datadog.api.client.v2.model.MemberTeam;
8+
import com.datadog.api.client.v2.model.MemberTeamType;
9+
10+
public class Example {
11+
public static void main(String[] args) {
12+
ApiClient defaultClient = ApiClient.getDefaultApiClient();
13+
defaultClient.setUnstableOperationEnabled("v2.addMemberTeam", true);
14+
TeamsApi apiInstance = new TeamsApi(defaultClient);
15+
16+
AddMemberTeamRequest body =
17+
new AddMemberTeamRequest()
18+
.data(
19+
new MemberTeam()
20+
.id("aeadc05e-98a8-11ec-ac2c-da7ad0900001")
21+
.type(MemberTeamType.MEMBER_TEAMS));
22+
23+
try {
24+
apiInstance.addMemberTeam("super_team_id", body);
25+
} catch (ApiException e) {
26+
System.err.println("Exception when calling TeamsApi#addMemberTeam");
27+
System.err.println("Status code: " + e.getCode());
28+
System.err.println("Reason: " + e.getResponseBody());
29+
System.err.println("Response headers: " + e.getResponseHeaders());
30+
e.printStackTrace();
31+
}
32+
}
33+
}
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
// Get all member teams returns "OK" response
2+
3+
import com.datadog.api.client.ApiClient;
4+
import com.datadog.api.client.ApiException;
5+
import com.datadog.api.client.v2.api.TeamsApi;
6+
import com.datadog.api.client.v2.model.TeamsResponse;
7+
8+
public class Example {
9+
public static void main(String[] args) {
10+
ApiClient defaultClient = ApiClient.getDefaultApiClient();
11+
defaultClient.setUnstableOperationEnabled("v2.listMemberTeams", true);
12+
TeamsApi apiInstance = new TeamsApi(defaultClient);
13+
14+
try {
15+
TeamsResponse result = apiInstance.listMemberTeams("super_team_id");
16+
System.out.println(result);
17+
} catch (ApiException e) {
18+
System.err.println("Exception when calling TeamsApi#listMemberTeams");
19+
System.err.println("Status code: " + e.getCode());
20+
System.err.println("Reason: " + e.getResponseBody());
21+
System.err.println("Response headers: " + e.getResponseHeaders());
22+
e.printStackTrace();
23+
}
24+
}
25+
}
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
// Get all member teams returns "OK" response with pagination
2+
3+
import com.datadog.api.client.ApiClient;
4+
import com.datadog.api.client.PaginationIterable;
5+
import com.datadog.api.client.v2.api.TeamsApi;
6+
import com.datadog.api.client.v2.model.Team;
7+
8+
public class Example {
9+
public static void main(String[] args) {
10+
ApiClient defaultClient = ApiClient.getDefaultApiClient();
11+
defaultClient.setUnstableOperationEnabled("v2.listMemberTeams", true);
12+
TeamsApi apiInstance = new TeamsApi(defaultClient);
13+
14+
try {
15+
PaginationIterable<Team> iterable =
16+
apiInstance.listMemberTeamsWithPagination("super_team_id");
17+
18+
for (Team item : iterable) {
19+
System.out.println(item);
20+
}
21+
} catch (RuntimeException e) {
22+
System.err.println("Exception when calling TeamsApi#listMemberTeamsWithPagination");
23+
System.err.println("Reason: " + e.getMessage());
24+
e.printStackTrace();
25+
}
26+
}
27+
}
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
// Remove a member team returns "No Content" response
2+
3+
import com.datadog.api.client.ApiClient;
4+
import com.datadog.api.client.ApiException;
5+
import com.datadog.api.client.v2.api.TeamsApi;
6+
7+
public class Example {
8+
public static void main(String[] args) {
9+
ApiClient defaultClient = ApiClient.getDefaultApiClient();
10+
defaultClient.setUnstableOperationEnabled("v2.removeMemberTeam", true);
11+
TeamsApi apiInstance = new TeamsApi(defaultClient);
12+
13+
try {
14+
apiInstance.removeMemberTeam("super_team_id", "member_team_id");
15+
} catch (ApiException e) {
16+
System.err.println("Exception when calling TeamsApi#removeMemberTeam");
17+
System.err.println("Status code: " + e.getCode());
18+
System.err.println("Reason: " + e.getResponseBody());
19+
System.err.println("Response headers: " + e.getResponseHeaders());
20+
e.printStackTrace();
21+
}
22+
}
23+
}

src/main/java/com/datadog/api/client/ApiClient.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -691,6 +691,9 @@ public class ApiClient {
691691
put("v2.createSLOReportJob", false);
692692
put("v2.getSLOReport", false);
693693
put("v2.getSLOReportJobStatus", false);
694+
put("v2.addMemberTeam", false);
695+
put("v2.listMemberTeams", false);
696+
put("v2.removeMemberTeam", false);
694697
put("v2.createIncidentTeam", false);
695698
put("v2.deleteIncidentTeam", false);
696699
put("v2.getIncidentTeam", false);

0 commit comments

Comments
 (0)