Skip to content

Commit 35d6bd5

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit a211158 of spec repo
1 parent 9727dd3 commit 35d6bd5

22 files changed

+3560
-0
lines changed

.generator/schemas/v2/openapi.yaml

Lines changed: 292 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5362,6 +5362,76 @@ components:
53625362
example: _latest
53635363
type: string
53645364
type: object
5365+
AssignSeatsUserRequest:
5366+
properties:
5367+
data:
5368+
$ref: '#/components/schemas/AssignSeatsUserRequestData'
5369+
description: The data for the assign seats user request.
5370+
required:
5371+
- data
5372+
type: object
5373+
AssignSeatsUserRequestData:
5374+
properties:
5375+
attributes:
5376+
$ref: '#/components/schemas/AssignSeatsUserRequestDataAttributes'
5377+
description: The attributes of the assign seats user request.
5378+
id:
5379+
description: The ID of the assign seats user request.
5380+
type: string
5381+
type:
5382+
$ref: '#/components/schemas/SeatAssignmentsDataType'
5383+
description: The type of the assign seats user request.
5384+
required:
5385+
- type
5386+
- attributes
5387+
type: object
5388+
AssignSeatsUserRequestDataAttributes:
5389+
properties:
5390+
product_code:
5391+
description: The product code for which to assign seats.
5392+
example: ''
5393+
type: string
5394+
user_uuids:
5395+
description: The list of user IDs to assign seats to.
5396+
example:
5397+
- ''
5398+
items:
5399+
type: string
5400+
type: array
5401+
required:
5402+
- product_code
5403+
- user_uuids
5404+
type: object
5405+
AssignSeatsUserResponse:
5406+
properties:
5407+
data:
5408+
$ref: '#/components/schemas/AssignSeatsUserResponseData'
5409+
description: The data for the assign seats user response.
5410+
type: object
5411+
AssignSeatsUserResponseData:
5412+
properties:
5413+
attributes:
5414+
$ref: '#/components/schemas/AssignSeatsUserResponseDataAttributes'
5415+
description: The attributes of the assign seats user response.
5416+
id:
5417+
description: The ID of the assign seats user response.
5418+
type: string
5419+
type:
5420+
$ref: '#/components/schemas/SeatAssignmentsDataType'
5421+
type: object
5422+
AssignSeatsUserResponseDataAttributes:
5423+
properties:
5424+
assigned_ids:
5425+
description: The list of user IDs to which the seats were assigned.
5426+
items:
5427+
type: string
5428+
nullable: true
5429+
type: array
5430+
product_code:
5431+
description: The product code for which the seats were assigned.
5432+
nullable: true
5433+
type: string
5434+
type: object
53655435
AttachCaseRequest:
53665436
description: Request for attaching security findings to a case.
53675437
properties:
@@ -52121,6 +52191,80 @@ components:
5212152191
- ISSUE_ASSIGNEE
5212252192
- ISSUE_CASE
5212352193
- ISSUE_TEAM_OWNERS
52194+
SeatAssignmentsDataType:
52195+
default: seat-assignments
52196+
description: Seat assignments resource type.
52197+
enum:
52198+
- seat-assignments
52199+
example: seat-assignments
52200+
type: string
52201+
x-enum-varnames:
52202+
- SEAT_ASSIGNMENTS
52203+
SeatUserData:
52204+
properties:
52205+
attributes:
52206+
$ref: '#/components/schemas/SeatUserDataAttributes'
52207+
description: The attributes of the seat user.
52208+
id:
52209+
description: The ID of the seat user.
52210+
nullable: true
52211+
type: string
52212+
type:
52213+
$ref: '#/components/schemas/SeatUserDataType'
52214+
type: object
52215+
SeatUserDataArray:
52216+
properties:
52217+
data:
52218+
description: The list of seat users.
52219+
items:
52220+
$ref: '#/components/schemas/SeatUserData'
52221+
nullable: true
52222+
type: array
52223+
meta:
52224+
$ref: '#/components/schemas/SeatUserMeta'
52225+
description: The metadata of the seat users.
52226+
type: object
52227+
SeatUserDataAttributes:
52228+
properties:
52229+
assigned_at:
52230+
description: The date and time the seat was assigned.
52231+
format: date-time
52232+
nullable: true
52233+
type: string
52234+
email:
52235+
description: The email of the user.
52236+
nullable: true
52237+
type: string
52238+
name:
52239+
description: The name of the user.
52240+
nullable: true
52241+
type: string
52242+
type: object
52243+
SeatUserDataType:
52244+
default: seat-users
52245+
description: Seat users resource type.
52246+
enum:
52247+
- seat-users
52248+
example: seat-users
52249+
type: string
52250+
x-enum-varnames:
52251+
- SEAT_USERS
52252+
SeatUserMeta:
52253+
properties:
52254+
cursor:
52255+
description: The cursor for the seat users.
52256+
nullable: true
52257+
type: string
52258+
limit:
52259+
description: The limit for the seat users.
52260+
format: int64
52261+
nullable: true
52262+
type: integer
52263+
next_cursor:
52264+
description: The next cursor for the seat users.
52265+
nullable: true
52266+
type: string
52267+
type: object
5212452268
SecretRuleArray:
5212552269
properties:
5212652270
data:
@@ -64224,6 +64368,44 @@ components:
6422464368
type: string
6422564369
x-enum-varnames:
6422664370
- AZURE_UC_CONFIGS
64371+
UnassignSeatsUserRequest:
64372+
properties:
64373+
data:
64374+
$ref: '#/components/schemas/UnassignSeatsUserRequestData'
64375+
description: The data for the unassign seats user request.
64376+
type: object
64377+
UnassignSeatsUserRequestData:
64378+
properties:
64379+
attributes:
64380+
$ref: '#/components/schemas/UnassignSeatsUserRequestDataAttributes'
64381+
description: The attributes of the unassign seats user request.
64382+
id:
64383+
description: The ID of the unassign seats user request.
64384+
type: string
64385+
type:
64386+
$ref: '#/components/schemas/SeatAssignmentsDataType'
64387+
description: The type of the unassign seats user request.
64388+
required:
64389+
- type
64390+
- attributes
64391+
type: object
64392+
UnassignSeatsUserRequestDataAttributes:
64393+
properties:
64394+
product_code:
64395+
description: The product code for which to unassign seats.
64396+
example: ''
64397+
type: string
64398+
user_uuids:
64399+
description: The list of user IDs to unassign seats from.
64400+
example:
64401+
- ''
64402+
items:
64403+
type: string
64404+
type: array
64405+
required:
64406+
- product_code
64407+
- user_uuids
64408+
type: object
6422764409
Unit:
6422864410
description: Object containing the metric unit family, scale factor, name, and
6422964411
short name.
@@ -92165,6 +92347,113 @@ paths:
9216592347
x-unstable: '**Note**: This endpoint is in public beta.
9216692348

9216792349
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
92350+
/api/v2/seats/users:
92351+
delete:
92352+
description: Unassign seats from users for a product code.
92353+
operationId: UnassignSeatsUserV2
92354+
requestBody:
92355+
content:
92356+
application/json:
92357+
schema:
92358+
$ref: '#/components/schemas/UnassignSeatsUserRequest'
92359+
required: true
92360+
responses:
92361+
'204':
92362+
description: No Content
92363+
'400':
92364+
$ref: '#/components/responses/BadRequestResponse'
92365+
'422':
92366+
description: Unprocessable Entity
92367+
'429':
92368+
$ref: '#/components/responses/TooManyRequestsResponse'
92369+
'500':
92370+
description: Internal Server Error
92371+
summary: Unassign seats from users
92372+
tags:
92373+
- Seats
92374+
x-permission:
92375+
operator: OR
92376+
permissions:
92377+
- billing_edit
92378+
- incident_write
92379+
- on_call_write
92380+
get:
92381+
description: Get the list of users assigned seats for a product code.
92382+
operationId: GetSeatsUsersV2
92383+
parameters:
92384+
- description: The product code for which to retrieve seat users.
92385+
in: query
92386+
name: product_code
92387+
required: true
92388+
schema:
92389+
type: string
92390+
- description: Maximum number of results to return.
92391+
in: query
92392+
name: page[limit]
92393+
schema:
92394+
type: integer
92395+
- description: Cursor for pagination.
92396+
in: query
92397+
name: page[cursor]
92398+
schema:
92399+
type: string
92400+
responses:
92401+
'200':
92402+
content:
92403+
application/json:
92404+
schema:
92405+
$ref: '#/components/schemas/SeatUserDataArray'
92406+
description: OK
92407+
'400':
92408+
$ref: '#/components/responses/BadRequestResponse'
92409+
'422':
92410+
description: Unprocessable Entity
92411+
'429':
92412+
$ref: '#/components/responses/TooManyRequestsResponse'
92413+
'500':
92414+
description: Internal Server Error
92415+
summary: Get users with seats
92416+
tags:
92417+
- Seats
92418+
x-permission:
92419+
operator: OR
92420+
permissions:
92421+
- billing_read
92422+
- incident_read
92423+
- on_call_read
92424+
post:
92425+
description: Assign seats to users for a product code.
92426+
operationId: AssignSeatsUserV2
92427+
requestBody:
92428+
content:
92429+
application/json:
92430+
schema:
92431+
$ref: '#/components/schemas/AssignSeatsUserRequest'
92432+
required: true
92433+
responses:
92434+
'201':
92435+
content:
92436+
application/json:
92437+
schema:
92438+
$ref: '#/components/schemas/AssignSeatsUserResponse'
92439+
description: Created
92440+
'400':
92441+
$ref: '#/components/responses/BadRequestResponse'
92442+
'422':
92443+
description: Unprocessable Entity
92444+
'429':
92445+
$ref: '#/components/responses/TooManyRequestsResponse'
92446+
'500':
92447+
description: Internal Server Error
92448+
summary: Assign seats to users
92449+
tags:
92450+
- Seats
92451+
x-permission:
92452+
operator: OR
92453+
permissions:
92454+
- billing_edit
92455+
- incident_write
92456+
- on_call_write
9216892457
/api/v2/security-entities/risk-scores:
9216992458
get:
9217092459
description: Get a list of entity risk scores for your organization. Entity
@@ -103298,6 +103587,9 @@ tags:
103298103587
- description: Manage retention filters through [Manage Applications](https://app.datadoghq.com/rum/list)
103299103588
of RUM for your organization.
103300103589
name: Rum Retention Filters
103590+
- description: The seats API allows you to view, assign, and unassign seats for your
103591+
organization.
103592+
name: Seats
103301103593
- description: Create and manage your security rules, signals, filters, and more.
103302103594
See the [Datadog Security page](https://docs.datadoghq.com/security/) for more
103303103595
information.
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
// Assign seats to users returns "Created" response
2+
3+
import com.datadog.api.client.ApiClient;
4+
import com.datadog.api.client.ApiException;
5+
import com.datadog.api.client.v2.api.SeatsApi;
6+
import com.datadog.api.client.v2.model.AssignSeatsUserRequest;
7+
import com.datadog.api.client.v2.model.AssignSeatsUserRequestData;
8+
import com.datadog.api.client.v2.model.AssignSeatsUserRequestDataAttributes;
9+
import com.datadog.api.client.v2.model.AssignSeatsUserResponse;
10+
import com.datadog.api.client.v2.model.SeatAssignmentsDataType;
11+
import java.util.Collections;
12+
13+
public class Example {
14+
public static void main(String[] args) {
15+
ApiClient defaultClient = ApiClient.getDefaultApiClient();
16+
SeatsApi apiInstance = new SeatsApi(defaultClient);
17+
18+
AssignSeatsUserRequest body =
19+
new AssignSeatsUserRequest()
20+
.data(
21+
new AssignSeatsUserRequestData()
22+
.attributes(
23+
new AssignSeatsUserRequestDataAttributes()
24+
.productCode("")
25+
.userUuids(Collections.singletonList("")))
26+
.type(SeatAssignmentsDataType.SEAT_ASSIGNMENTS));
27+
28+
try {
29+
AssignSeatsUserResponse result = apiInstance.assignSeatsUserV2(body);
30+
System.out.println(result);
31+
} catch (ApiException e) {
32+
System.err.println("Exception when calling SeatsApi#assignSeatsUserV2");
33+
System.err.println("Status code: " + e.getCode());
34+
System.err.println("Reason: " + e.getResponseBody());
35+
System.err.println("Response headers: " + e.getResponseHeaders());
36+
e.printStackTrace();
37+
}
38+
}
39+
}
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
// Get users with seats 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.SeatsApi;
6+
import com.datadog.api.client.v2.model.SeatUserDataArray;
7+
8+
public class Example {
9+
public static void main(String[] args) {
10+
ApiClient defaultClient = ApiClient.getDefaultApiClient();
11+
SeatsApi apiInstance = new SeatsApi(defaultClient);
12+
13+
try {
14+
SeatUserDataArray result = apiInstance.getSeatsUsersV2("product_code");
15+
System.out.println(result);
16+
} catch (ApiException e) {
17+
System.err.println("Exception when calling SeatsApi#getSeatsUsersV2");
18+
System.err.println("Status code: " + e.getCode());
19+
System.err.println("Reason: " + e.getResponseBody());
20+
System.err.println("Response headers: " + e.getResponseHeaders());
21+
e.printStackTrace();
22+
}
23+
}
24+
}

0 commit comments

Comments
 (0)