Skip to content

Commit 216468e

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 081d3b61 of spec repo
1 parent d6cf483 commit 216468e

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-23 16:55:09.087295",
8-
"spec_repo_commit": "6a0ddfd8"
7+
"regenerated": "2025-05-23 18:31:02.709057",
8+
"spec_repo_commit": "081d3b61"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2025-05-23 16:55:09.104040",
13-
"spec_repo_commit": "6a0ddfd8"
12+
"regenerated": "2025-05-23 18:31:02.725183",
13+
"spec_repo_commit": "081d3b61"
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:
@@ -20881,6 +20889,28 @@ components:
2088120889
- ms_channel_name
2088220890
- redirect_url
2088320891
type: object
20892+
MemberTeam:
20893+
description: A member team
20894+
properties:
20895+
id:
20896+
description: The member team's identifier
20897+
example: aeadc05e-98a8-11ec-ac2c-da7ad0900001
20898+
type: string
20899+
type:
20900+
$ref: '#/components/schemas/MemberTeamType'
20901+
required:
20902+
- id
20903+
- type
20904+
type: object
20905+
MemberTeamType:
20906+
default: member_teams
20907+
description: Member team type
20908+
enum:
20909+
- member_teams
20910+
example: member_teams
20911+
type: string
20912+
x-enum-varnames:
20913+
- MEMBER_TEAMS
2088420914
Metadata:
2088520915
description: The metadata related to this request.
2088620916
properties:
@@ -59548,6 +59578,156 @@ paths:
5954859578
permissions:
5954959579
- teams_read
5955059580
- teams_manage
59581+
/api/v2/team/{super_team_id}/member_teams:
59582+
get:
59583+
description: Get all member teams.
59584+
operationId: ListMemberTeams
59585+
parameters:
59586+
- description: None
59587+
in: path
59588+
name: super_team_id
59589+
required: true
59590+
schema:
59591+
type: string
59592+
- $ref: '#/components/parameters/PageSize'
59593+
- $ref: '#/components/parameters/PageNumber'
59594+
- description: List of fields that need to be fetched.
59595+
explode: false
59596+
in: query
59597+
name: fields[team]
59598+
required: false
59599+
schema:
59600+
items:
59601+
$ref: '#/components/schemas/TeamsField'
59602+
type: array
59603+
responses:
59604+
'200':
59605+
content:
59606+
application/json:
59607+
schema:
59608+
$ref: '#/components/schemas/TeamsResponse'
59609+
description: OK
59610+
'403':
59611+
$ref: '#/components/responses/ForbiddenResponse'
59612+
'404':
59613+
content:
59614+
application/json:
59615+
schema:
59616+
$ref: '#/components/schemas/APIErrorResponse'
59617+
description: API error response.
59618+
'429':
59619+
$ref: '#/components/responses/TooManyRequestsResponse'
59620+
security:
59621+
- apiKeyAuth: []
59622+
appKeyAuth: []
59623+
- AuthZ:
59624+
- teams_read
59625+
summary: Get all member teams
59626+
tags:
59627+
- Teams
59628+
x-pagination:
59629+
limitParam: page[size]
59630+
pageParam: page[number]
59631+
resultsPath: data
59632+
x-permission:
59633+
operator: OR
59634+
permissions:
59635+
- teams_read
59636+
x-unstable: '**Note**: This endpoint is in Preview. If you have any feedback,
59637+
59638+
contact [Datadog support](https://docs.datadoghq.com/help/).'
59639+
post:
59640+
description: 'Add a member team.
59641+
59642+
Adds the team given by the `id` in the body as a member team of the super
59643+
team.'
59644+
operationId: AddMemberTeam
59645+
parameters:
59646+
- description: None
59647+
in: path
59648+
name: super_team_id
59649+
required: true
59650+
schema:
59651+
type: string
59652+
requestBody:
59653+
content:
59654+
application/json:
59655+
schema:
59656+
$ref: '#/components/schemas/AddMemberTeamRequest'
59657+
required: true
59658+
responses:
59659+
'204':
59660+
description: Added
59661+
'403':
59662+
$ref: '#/components/responses/ForbiddenResponse'
59663+
'409':
59664+
content:
59665+
application/json:
59666+
schema:
59667+
$ref: '#/components/schemas/APIErrorResponse'
59668+
description: API error response.
59669+
'429':
59670+
$ref: '#/components/responses/TooManyRequestsResponse'
59671+
security:
59672+
- apiKeyAuth: []
59673+
appKeyAuth: []
59674+
- AuthZ:
59675+
- teams_read
59676+
summary: Add a member team
59677+
tags:
59678+
- Teams
59679+
x-permission:
59680+
operator: OR
59681+
permissions:
59682+
- teams_read
59683+
x-unstable: '**Note**: This endpoint is in Preview. If you have any feedback,
59684+
59685+
contact [Datadog support](https://docs.datadoghq.com/help/).'
59686+
/api/v2/team/{super_team_id}/member_teams/{member_team_id}:
59687+
delete:
59688+
description: Remove a super team's member team identified by `member_team_id`.
59689+
operationId: RemoveMemberTeam
59690+
parameters:
59691+
- description: None
59692+
in: path
59693+
name: super_team_id
59694+
required: true
59695+
schema:
59696+
type: string
59697+
- description: None
59698+
in: path
59699+
name: member_team_id
59700+
required: true
59701+
schema:
59702+
type: string
59703+
responses:
59704+
'204':
59705+
description: No Content
59706+
'403':
59707+
$ref: '#/components/responses/ForbiddenResponse'
59708+
'404':
59709+
content:
59710+
application/json:
59711+
schema:
59712+
$ref: '#/components/schemas/APIErrorResponse'
59713+
description: API error response.
59714+
'429':
59715+
$ref: '#/components/responses/TooManyRequestsResponse'
59716+
security:
59717+
- apiKeyAuth: []
59718+
appKeyAuth: []
59719+
- AuthZ:
59720+
- teams_read
59721+
summary: Remove a member team
59722+
tags:
59723+
- Teams
59724+
x-permission:
59725+
operator: OR
59726+
permissions:
59727+
- teams_read
59728+
x-unstable: '**Note**: This endpoint is in Preview. If you have any feedback,
59729+
59730+
contact [Datadog support](https://docs.datadoghq.com/help/).'
5955159731
/api/v2/team/{team_id}:
5955259732
delete:
5955359733
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)