Skip to content

Commit 2b6ffa7

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 0c9429e of spec repo
1 parent 2573319 commit 2b6ffa7

22 files changed

+3482
-0
lines changed

.generator/schemas/v2/openapi.yaml

Lines changed: 290 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5362,6 +5362,72 @@ 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+
type: object
5371+
AssignSeatsUserRequestData:
5372+
properties:
5373+
attributes:
5374+
$ref: '#/components/schemas/AssignSeatsUserRequestDataAttributes'
5375+
description: The attributes of the assign seats user request.
5376+
id:
5377+
description: The ID of the assign seats user request.
5378+
type: string
5379+
type:
5380+
$ref: '#/components/schemas/SeatAssignmentsDataType'
5381+
description: The type of the assign seats user request.
5382+
required:
5383+
- type
5384+
- attributes
5385+
type: object
5386+
AssignSeatsUserRequestDataAttributes:
5387+
properties:
5388+
product_code:
5389+
description: The product code for which to assign seats.
5390+
example: ''
5391+
type: string
5392+
user_uuids:
5393+
description: The list of user IDs to assign seats to.
5394+
example:
5395+
- ''
5396+
items:
5397+
type: string
5398+
type: array
5399+
required:
5400+
- product_code
5401+
- user_uuids
5402+
type: object
5403+
AssignSeatsUserResponse:
5404+
properties:
5405+
data:
5406+
$ref: '#/components/schemas/AssignSeatsUserResponseData'
5407+
description: The data for the assign seats user response.
5408+
type: object
5409+
AssignSeatsUserResponseData:
5410+
properties:
5411+
attributes:
5412+
$ref: '#/components/schemas/AssignSeatsUserResponseDataAttributes'
5413+
description: The attributes of the assign seats user response.
5414+
id:
5415+
description: The ID of the assign seats user response.
5416+
type: string
5417+
type:
5418+
$ref: '#/components/schemas/SeatAssignmentsDataType'
5419+
type: object
5420+
AssignSeatsUserResponseDataAttributes:
5421+
properties:
5422+
assigned_ids:
5423+
description: The list of user IDs to which the seats were assigned.
5424+
items:
5425+
type: string
5426+
type: array
5427+
product_code:
5428+
description: The product code for which the seats were assigned.
5429+
type: string
5430+
type: object
53655431
AttachCaseRequest:
53665432
description: Request for attaching security findings to a case.
53675433
properties:
@@ -52255,6 +52321,80 @@ components:
5225552321
- ISSUE_ASSIGNEE
5225652322
- ISSUE_CASE
5225752323
- ISSUE_TEAM_OWNERS
52324+
SeatAssignmentsDataType:
52325+
default: seat-assignments
52326+
description: Seat assignments resource type.
52327+
enum:
52328+
- seat-assignments
52329+
example: seat-assignments
52330+
type: string
52331+
x-enum-varnames:
52332+
- SEAT_ASSIGNMENTS
52333+
SeatUserData:
52334+
properties:
52335+
attributes:
52336+
$ref: '#/components/schemas/SeatUserDataAttributes'
52337+
description: The attributes of the seat user.
52338+
id:
52339+
description: The ID of the seat user.
52340+
example: 00000000-0000-0000-0000-000000000000
52341+
nullable: true
52342+
type: string
52343+
type:
52344+
$ref: '#/components/schemas/SeatUserDataType'
52345+
type: object
52346+
SeatUserDataArray:
52347+
properties:
52348+
data:
52349+
description: The list of seat users.
52350+
items:
52351+
$ref: '#/components/schemas/SeatUserData'
52352+
type: array
52353+
meta:
52354+
$ref: '#/components/schemas/SeatUserMeta'
52355+
description: The metadata of the seat users.
52356+
type: object
52357+
SeatUserDataAttributes:
52358+
properties:
52359+
assigned_at:
52360+
description: The date and time the seat was assigned.
52361+
example: '2021-01-01T00:00:00Z'
52362+
format: date-time
52363+
nullable: true
52364+
type: string
52365+
email:
52366+
description: The email of the user.
52367+
example: user@example.com
52368+
nullable: true
52369+
type: string
52370+
name:
52371+
description: The name of the user.
52372+
example: John Doe
52373+
nullable: true
52374+
type: string
52375+
type: object
52376+
SeatUserDataType:
52377+
default: seat-users
52378+
description: Seat users resource type.
52379+
enum:
52380+
- seat-users
52381+
example: seat-users
52382+
type: string
52383+
x-enum-varnames:
52384+
- SEAT_USERS
52385+
SeatUserMeta:
52386+
properties:
52387+
cursor:
52388+
description: The cursor for the seat users.
52389+
type: string
52390+
limit:
52391+
description: The limit for the seat users.
52392+
format: int64
52393+
type: integer
52394+
next_cursor:
52395+
description: The next cursor for the seat users.
52396+
type: string
52397+
type: object
5225852398
SecretRuleArray:
5225952399
properties:
5226052400
data:
@@ -64399,6 +64539,44 @@ components:
6439964539
type: string
6440064540
x-enum-varnames:
6440164541
- AZURE_UC_CONFIGS
64542+
UnassignSeatsUserRequest:
64543+
properties:
64544+
data:
64545+
$ref: '#/components/schemas/UnassignSeatsUserRequestData'
64546+
description: The data for the unassign seats user request.
64547+
type: object
64548+
UnassignSeatsUserRequestData:
64549+
properties:
64550+
attributes:
64551+
$ref: '#/components/schemas/UnassignSeatsUserRequestDataAttributes'
64552+
description: The attributes of the unassign seats user request.
64553+
id:
64554+
description: The ID of the unassign seats user request.
64555+
type: string
64556+
type:
64557+
$ref: '#/components/schemas/SeatAssignmentsDataType'
64558+
description: The type of the unassign seats user request.
64559+
required:
64560+
- type
64561+
- attributes
64562+
type: object
64563+
UnassignSeatsUserRequestDataAttributes:
64564+
properties:
64565+
product_code:
64566+
description: The product code for which to unassign seats.
64567+
example: ''
64568+
type: string
64569+
user_uuids:
64570+
description: The list of user IDs to unassign seats from.
64571+
example:
64572+
- ''
64573+
items:
64574+
type: string
64575+
type: array
64576+
required:
64577+
- product_code
64578+
- user_uuids
64579+
type: object
6440264580
Unit:
6440364581
description: Object containing the metric unit family, scale factor, name, and
6440464582
short name.
@@ -92716,6 +92894,115 @@ paths:
9271692894
x-unstable: '**Note**: This endpoint is in public beta.
9271792895

9271892896
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
92897+
/api/v2/seats/users:
92898+
delete:
92899+
description: Unassign seats from users for a product code.
92900+
operationId: UnassignSeatsUserV2
92901+
requestBody:
92902+
content:
92903+
application/json:
92904+
schema:
92905+
$ref: '#/components/schemas/UnassignSeatsUserRequest'
92906+
required: true
92907+
responses:
92908+
'204':
92909+
description: No Content
92910+
'400':
92911+
$ref: '#/components/responses/BadRequestResponse'
92912+
'422':
92913+
description: Unprocessable Entity
92914+
'429':
92915+
$ref: '#/components/responses/TooManyRequestsResponse'
92916+
'500':
92917+
description: Internal Server Error
92918+
summary: Unassign seats from users
92919+
tags:
92920+
- Seats
92921+
x-permission:
92922+
operator: OR
92923+
permissions:
92924+
- billing_edit
92925+
- incident_write
92926+
- on_call_write
92927+
get:
92928+
description: Get the list of users assigned seats for a product code.
92929+
operationId: GetSeatsUsersV2
92930+
parameters:
92931+
- description: The product code for which to retrieve seat users.
92932+
in: query
92933+
name: product_code
92934+
required: true
92935+
schema:
92936+
type: string
92937+
- description: Maximum number of results to return.
92938+
in: query
92939+
name: page[limit]
92940+
required: false
92941+
schema:
92942+
type: integer
92943+
- description: Cursor for pagination.
92944+
in: query
92945+
name: page[cursor]
92946+
required: false
92947+
schema:
92948+
type: string
92949+
responses:
92950+
'200':
92951+
content:
92952+
application/json:
92953+
schema:
92954+
$ref: '#/components/schemas/SeatUserDataArray'
92955+
description: OK
92956+
'400':
92957+
$ref: '#/components/responses/BadRequestResponse'
92958+
'422':
92959+
description: Unprocessable Entity
92960+
'429':
92961+
$ref: '#/components/responses/TooManyRequestsResponse'
92962+
'500':
92963+
description: Internal Server Error
92964+
summary: Get users with seats
92965+
tags:
92966+
- Seats
92967+
x-permission:
92968+
operator: OR
92969+
permissions:
92970+
- billing_read
92971+
- incident_read
92972+
- on_call_read
92973+
post:
92974+
description: Assign seats to users for a product code.
92975+
operationId: AssignSeatsUserV2
92976+
requestBody:
92977+
content:
92978+
application/json:
92979+
schema:
92980+
$ref: '#/components/schemas/AssignSeatsUserRequest'
92981+
required: true
92982+
responses:
92983+
'201':
92984+
content:
92985+
application/json:
92986+
schema:
92987+
$ref: '#/components/schemas/AssignSeatsUserResponse'
92988+
description: Created
92989+
'400':
92990+
$ref: '#/components/responses/BadRequestResponse'
92991+
'422':
92992+
description: Unprocessable Entity
92993+
'429':
92994+
$ref: '#/components/responses/TooManyRequestsResponse'
92995+
'500':
92996+
description: Internal Server Error
92997+
summary: Assign seats to users
92998+
tags:
92999+
- Seats
93000+
x-permission:
93001+
operator: OR
93002+
permissions:
93003+
- billing_edit
93004+
- incident_write
93005+
- on_call_write
9271993006
/api/v2/security-entities/risk-scores:
9272093007
get:
9272193008
description: Get a list of entity risk scores for your organization. Entity
@@ -103849,6 +104136,9 @@ tags:
103849104136
- description: Manage retention filters through [Manage Applications](https://app.datadoghq.com/rum/list)
103850104137
of RUM for your organization.
103851104138
name: Rum Retention Filters
104139+
- description: The seats API allows you to view, assign, and unassign seats for your
104140+
organization.
104141+
name: Seats
103852104142
- description: Create and manage your security rules, signals, filters, and more.
103853104143
See the [Datadog Security page](https://docs.datadoghq.com/security/) for more
103854104144
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)