Skip to content

Commit 6f1163e

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 7131a437 of spec repo
1 parent 65aeae8 commit 6f1163e

File tree

13 files changed

+1401
-4
lines changed

13 files changed

+1401
-4
lines changed

.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-27 17:12:14.968856",
8-
"spec_repo_commit": "ed439f7c"
7+
"regenerated": "2025-05-27 19:53:24.941357",
8+
"spec_repo_commit": "7131a437"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2025-05-27 17:12:14.988382",
13-
"spec_repo_commit": "ed439f7c"
12+
"regenerated": "2025-05-27 19:53:24.957810",
13+
"spec_repo_commit": "7131a437"
1414
}
1515
}
1616
}

.generator/schemas/v2/openapi.yaml

Lines changed: 180 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2192,6 +2192,14 @@ components:
21922192
type: string
21932193
x-enum-varnames:
21942194
- BILLING_DIMENSIONS
2195+
AddMemberTeamRequest:
2196+
description: Request to add a member team to super team's hierarchy
2197+
properties:
2198+
data:
2199+
$ref: '#/components/schemas/MemberTeam'
2200+
required:
2201+
- data
2202+
type: object
21952203
Advisory:
21962204
description: Advisory.
21972205
properties:
@@ -21003,6 +21011,28 @@ components:
2100321011
- ms_channel_name
2100421012
- redirect_url
2100521013
type: object
21014+
MemberTeam:
21015+
description: A member team
21016+
properties:
21017+
id:
21018+
description: The member team's identifier
21019+
example: aeadc05e-98a8-11ec-ac2c-da7ad0900001
21020+
type: string
21021+
type:
21022+
$ref: '#/components/schemas/MemberTeamType'
21023+
required:
21024+
- id
21025+
- type
21026+
type: object
21027+
MemberTeamType:
21028+
default: member_teams
21029+
description: Member team type
21030+
enum:
21031+
- member_teams
21032+
example: member_teams
21033+
type: string
21034+
x-enum-varnames:
21035+
- MEMBER_TEAMS
2100621036
Metadata:
2100721037
description: The metadata related to this request.
2100821038
properties:
@@ -59781,6 +59811,156 @@ paths:
5978159811
permissions:
5978259812
- teams_read
5978359813
- teams_manage
59814+
/api/v2/team/{super_team_id}/member_teams:
59815+
get:
59816+
description: Get all member teams.
59817+
operationId: ListMemberTeams
59818+
parameters:
59819+
- description: None
59820+
in: path
59821+
name: super_team_id
59822+
required: true
59823+
schema:
59824+
type: string
59825+
- $ref: '#/components/parameters/PageSize'
59826+
- $ref: '#/components/parameters/PageNumber'
59827+
- description: List of fields that need to be fetched.
59828+
explode: false
59829+
in: query
59830+
name: fields[team]
59831+
required: false
59832+
schema:
59833+
items:
59834+
$ref: '#/components/schemas/TeamsField'
59835+
type: array
59836+
responses:
59837+
'200':
59838+
content:
59839+
application/json:
59840+
schema:
59841+
$ref: '#/components/schemas/TeamsResponse'
59842+
description: OK
59843+
'403':
59844+
$ref: '#/components/responses/ForbiddenResponse'
59845+
'404':
59846+
content:
59847+
application/json:
59848+
schema:
59849+
$ref: '#/components/schemas/APIErrorResponse'
59850+
description: API error response.
59851+
'429':
59852+
$ref: '#/components/responses/TooManyRequestsResponse'
59853+
security:
59854+
- apiKeyAuth: []
59855+
appKeyAuth: []
59856+
- AuthZ:
59857+
- teams_read
59858+
summary: Get all member teams
59859+
tags:
59860+
- Teams
59861+
x-pagination:
59862+
limitParam: page[size]
59863+
pageParam: page[number]
59864+
resultsPath: data
59865+
x-permission:
59866+
operator: OR
59867+
permissions:
59868+
- teams_read
59869+
x-unstable: '**Note**: This endpoint is in Preview. If you have any feedback,
59870+
59871+
contact [Datadog support](https://docs.datadoghq.com/help/).'
59872+
post:
59873+
description: 'Add a member team.
59874+
59875+
Adds the team given by the `id` in the body as a member team of the super
59876+
team.'
59877+
operationId: AddMemberTeam
59878+
parameters:
59879+
- description: None
59880+
in: path
59881+
name: super_team_id
59882+
required: true
59883+
schema:
59884+
type: string
59885+
requestBody:
59886+
content:
59887+
application/json:
59888+
schema:
59889+
$ref: '#/components/schemas/AddMemberTeamRequest'
59890+
required: true
59891+
responses:
59892+
'204':
59893+
description: Added
59894+
'403':
59895+
$ref: '#/components/responses/ForbiddenResponse'
59896+
'409':
59897+
content:
59898+
application/json:
59899+
schema:
59900+
$ref: '#/components/schemas/APIErrorResponse'
59901+
description: API error response.
59902+
'429':
59903+
$ref: '#/components/responses/TooManyRequestsResponse'
59904+
security:
59905+
- apiKeyAuth: []
59906+
appKeyAuth: []
59907+
- AuthZ:
59908+
- teams_read
59909+
summary: Add a member team
59910+
tags:
59911+
- Teams
59912+
x-permission:
59913+
operator: OR
59914+
permissions:
59915+
- teams_read
59916+
x-unstable: '**Note**: This endpoint is in Preview. If you have any feedback,
59917+
59918+
contact [Datadog support](https://docs.datadoghq.com/help/).'
59919+
/api/v2/team/{super_team_id}/member_teams/{member_team_id}:
59920+
delete:
59921+
description: Remove a super team's member team identified by `member_team_id`.
59922+
operationId: RemoveMemberTeam
59923+
parameters:
59924+
- description: None
59925+
in: path
59926+
name: super_team_id
59927+
required: true
59928+
schema:
59929+
type: string
59930+
- description: None
59931+
in: path
59932+
name: member_team_id
59933+
required: true
59934+
schema:
59935+
type: string
59936+
responses:
59937+
'204':
59938+
description: No Content
59939+
'403':
59940+
$ref: '#/components/responses/ForbiddenResponse'
59941+
'404':
59942+
content:
59943+
application/json:
59944+
schema:
59945+
$ref: '#/components/schemas/APIErrorResponse'
59946+
description: API error response.
59947+
'429':
59948+
$ref: '#/components/responses/TooManyRequestsResponse'
59949+
security:
59950+
- apiKeyAuth: []
59951+
appKeyAuth: []
59952+
- AuthZ:
59953+
- teams_read
59954+
summary: Remove a member team
59955+
tags:
59956+
- Teams
59957+
x-permission:
59958+
operator: OR
59959+
permissions:
59960+
- teams_read
59961+
x-unstable: '**Note**: This endpoint is in Preview. If you have any feedback,
59962+
59963+
contact [Datadog support](https://docs.datadoghq.com/help/).'
5978459964
/api/v2/team/{team_id}:
5978559965
delete:
5978659966
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)