Skip to content

Commit 175b991

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 1bbeea1d of spec repo
1 parent 8ab2b04 commit 175b991

File tree

40 files changed

+3150
-4
lines changed

40 files changed

+3150
-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.5",
7-
"regenerated": "2023-09-14 14:35:26.859009",
8-
"spec_repo_commit": "1d834ec1"
7+
"regenerated": "2023-09-15 20:36:18.537239",
8+
"spec_repo_commit": "1bbeea1d"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.5",
12-
"regenerated": "2023-09-14 14:35:26.875218",
13-
"spec_repo_commit": "1d834ec1"
12+
"regenerated": "2023-09-15 20:36:18.550992",
13+
"spec_repo_commit": "1bbeea1d"
1414
}
1515
}
1616
}

.generator/schemas/v2/openapi.yaml

Lines changed: 279 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5472,6 +5472,15 @@ components:
54725472
type: string
54735473
x-enum-varnames:
54745474
- GCP_SERVICE_ACCOUNT
5475+
GetAllPowerpacksResponse:
5476+
description: Response object which includes all powerpack configurations.
5477+
properties:
5478+
data:
5479+
description: List of powerpack definitions.
5480+
items:
5481+
$ref: '#/components/schemas/PowerpackData'
5482+
type: array
5483+
type: object
54755484
GetFindingResponse:
54765485
description: The expected response schema when getting a finding.
54775486
properties:
@@ -10555,6 +10564,95 @@ components:
1055510564
type: string
1055610565
x-enum-varnames:
1055710566
- PERMISSIONS
10567+
Powerpack:
10568+
description: Powerpacks are templated groups of dashboard widgets you can save
10569+
from an existing dashboard and turn into reusable packs in the widget tray.
10570+
properties:
10571+
data:
10572+
$ref: '#/components/schemas/PowerpackData'
10573+
type: object
10574+
PowerpackAttributes:
10575+
description: Powerpack attribute object.
10576+
properties:
10577+
description:
10578+
description: Description of this powerpack.
10579+
example: Powerpack for ABC
10580+
type: string
10581+
group_widget:
10582+
additionalProperties: {}
10583+
description: Templated group of dashboard widgets for the powerpack.
10584+
example:
10585+
layout_type: ordered
10586+
tags:
10587+
- tag:foo1
10588+
type: group
10589+
widgets:
10590+
- definition:
10591+
content: example
10592+
type: note
10593+
type: object
10594+
name:
10595+
description: Name of the powerpack.
10596+
example: Sample Powerpack
10597+
type: string
10598+
tags:
10599+
description: List of tags to identify this powerpack.
10600+
example:
10601+
- tag:foo1
10602+
items:
10603+
maxLength: 80
10604+
type: string
10605+
maxItems: 8
10606+
type: array
10607+
template_variables:
10608+
description: List of template variables for this powerpack.
10609+
example:
10610+
- defaults:
10611+
- '*'
10612+
name: test
10613+
items:
10614+
$ref: '#/components/schemas/PowerpackTemplateVariable'
10615+
type: array
10616+
required:
10617+
- group_widget
10618+
- name
10619+
type: object
10620+
PowerpackData:
10621+
description: Powerpack data object.
10622+
properties:
10623+
attributes:
10624+
$ref: '#/components/schemas/PowerpackAttributes'
10625+
id:
10626+
description: ID of the powerpack.
10627+
type: string
10628+
type:
10629+
description: Type of widget, must be powerpack.
10630+
example: powerpack
10631+
type: string
10632+
type: object
10633+
PowerpackResponse:
10634+
description: Response object which includes a single powerpack configuration.
10635+
properties:
10636+
data:
10637+
$ref: '#/components/schemas/PowerpackData'
10638+
readOnly: true
10639+
type: object
10640+
PowerpackTemplateVariable:
10641+
description: Powerpack template variables.
10642+
properties:
10643+
defaults:
10644+
description: One or many template variable default values within the saved
10645+
view, which will be unioned together using `OR` if more than one is specified.
10646+
items:
10647+
description: One or many default values of the template variable.
10648+
minLength: 1
10649+
type: string
10650+
minItems: 1
10651+
type: array
10652+
name:
10653+
description: The name of the variable.
10654+
type: string
10655+
type: object
1055810656
ProcessSummariesMeta:
1055910657
description: Response metadata object.
1056010658
properties:
@@ -22896,6 +22994,171 @@ paths:
2289622994
x-unstable: '**Note**: This endpoint is in public beta.
2289722995

2289822996
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
22997+
/api/v2/powerpacks:
22998+
get:
22999+
description: Get a list of all powerpacks.
23000+
operationId: GetAllPowerpacks
23001+
responses:
23002+
'200':
23003+
content:
23004+
application/json:
23005+
schema:
23006+
$ref: '#/components/schemas/GetAllPowerpacksResponse'
23007+
description: OK
23008+
'429':
23009+
$ref: '#/components/responses/TooManyRequestsResponse'
23010+
security:
23011+
- apiKeyAuth: []
23012+
appKeyAuth: []
23013+
- AuthZ:
23014+
- dashboards_read
23015+
summary: Get all powerpacks
23016+
tags:
23017+
- Powerpack
23018+
post:
23019+
description: Create a powerpack.
23020+
operationId: CreatePowerpack
23021+
requestBody:
23022+
content:
23023+
application/json:
23024+
schema:
23025+
$ref: '#/components/schemas/Powerpack'
23026+
description: Create a powerpack request body.
23027+
required: true
23028+
responses:
23029+
'200':
23030+
content:
23031+
application/json:
23032+
schema:
23033+
$ref: '#/components/schemas/PowerpackResponse'
23034+
description: OK
23035+
'400':
23036+
content:
23037+
application/json:
23038+
schema:
23039+
$ref: '#/components/schemas/APIErrorResponse'
23040+
description: Bad Request
23041+
'429':
23042+
$ref: '#/components/responses/TooManyRequestsResponse'
23043+
security:
23044+
- apiKeyAuth: []
23045+
appKeyAuth: []
23046+
- AuthZ:
23047+
- dashboards_write
23048+
summary: Create a new powerpack
23049+
tags:
23050+
- Powerpack
23051+
x-codegen-request-body-name: body
23052+
/api/v2/powerpacks/{powerpack_id}:
23053+
delete:
23054+
description: Delete a powerpack.
23055+
operationId: DeletePowerpack
23056+
parameters:
23057+
- description: Powerpack id
23058+
in: path
23059+
name: powerpack_id
23060+
required: true
23061+
schema:
23062+
type: string
23063+
responses:
23064+
'204':
23065+
description: OK
23066+
'404':
23067+
content:
23068+
application/json:
23069+
schema:
23070+
$ref: '#/components/schemas/APIErrorResponse'
23071+
description: Powerpack Not Found
23072+
'429':
23073+
$ref: '#/components/responses/TooManyRequestsResponse'
23074+
security:
23075+
- apiKeyAuth: []
23076+
appKeyAuth: []
23077+
- AuthZ:
23078+
- dashboards_write
23079+
summary: Delete a powerpack
23080+
tags:
23081+
- Powerpack
23082+
get:
23083+
description: Get a powerpack.
23084+
operationId: GetPowerpack
23085+
parameters:
23086+
- description: Id of the powerpack.
23087+
in: path
23088+
name: powerpack_id
23089+
required: true
23090+
schema:
23091+
type: string
23092+
responses:
23093+
'200':
23094+
content:
23095+
application/json:
23096+
schema:
23097+
$ref: '#/components/schemas/PowerpackResponse'
23098+
description: OK
23099+
'404':
23100+
content:
23101+
application/json:
23102+
schema:
23103+
$ref: '#/components/schemas/APIErrorResponse'
23104+
description: Powerpack Not Found.
23105+
'429':
23106+
$ref: '#/components/responses/TooManyRequestsResponse'
23107+
security:
23108+
- apiKeyAuth: []
23109+
appKeyAuth: []
23110+
- AuthZ:
23111+
- dashboards_read
23112+
summary: Get a Powerpack
23113+
tags:
23114+
- Powerpack
23115+
patch:
23116+
description: Update a powerpack.
23117+
operationId: UpdatePowerpack
23118+
parameters:
23119+
- description: ID of the powerpack.
23120+
in: path
23121+
name: powerpack_id
23122+
required: true
23123+
schema:
23124+
type: string
23125+
requestBody:
23126+
content:
23127+
application/json:
23128+
schema:
23129+
$ref: '#/components/schemas/Powerpack'
23130+
description: Update a powerpack request body.
23131+
required: true
23132+
responses:
23133+
'200':
23134+
content:
23135+
application/json:
23136+
schema:
23137+
$ref: '#/components/schemas/PowerpackResponse'
23138+
description: OK
23139+
'400':
23140+
content:
23141+
application/json:
23142+
schema:
23143+
$ref: '#/components/schemas/APIErrorResponse'
23144+
description: Bad Request
23145+
'404':
23146+
content:
23147+
application/json:
23148+
schema:
23149+
$ref: '#/components/schemas/APIErrorResponse'
23150+
description: Powerpack Not Found
23151+
'429':
23152+
$ref: '#/components/responses/TooManyRequestsResponse'
23153+
security:
23154+
- apiKeyAuth: []
23155+
appKeyAuth: []
23156+
- AuthZ:
23157+
- dashboards_write
23158+
summary: Update a powerpack
23159+
tags:
23160+
- Powerpack
23161+
x-codegen-request-body-name: body
2289923162
/api/v2/processes:
2290023163
get:
2290123164
description: Get all processes for your organization.
@@ -27901,6 +28164,22 @@ tags:
2790128164
description: Find out more at
2790228165
url: https://docs.datadoghq.com/account_management/multi_organization
2790328166
name: Organizations
28167+
- description: 'The powerpack endpoints allow you to:
28168+
28169+
28170+
- Get a powerpack
28171+
28172+
- Create a powerpack
28173+
28174+
- Delete a powerpack
28175+
28176+
- Get a list of all powerpacks
28177+
28178+
28179+
The Patch and Delete API methods can only be performed on a powerpack by
28180+
28181+
a user who has the powerpack create permission for that specific powerpack.'
28182+
name: Powerpack
2790428183
- description: The processes API allows you to query processes data for your organization.
2790528184
name: Processes
2790628185
- description: Search or aggregate your RUM events over HTTP.
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
// Create a new powerpack 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.PowerpackApi;
6+
import com.datadog.api.client.v2.model.Powerpack;
7+
import com.datadog.api.client.v2.model.PowerpackAttributes;
8+
import com.datadog.api.client.v2.model.PowerpackData;
9+
import com.datadog.api.client.v2.model.PowerpackResponse;
10+
import com.datadog.api.client.v2.model.PowerpackTemplateVariable;
11+
import java.util.Collections;
12+
import java.util.Map;
13+
14+
public class Example {
15+
public static void main(String[] args) {
16+
ApiClient defaultClient = ApiClient.getDefaultApiClient();
17+
PowerpackApi apiInstance = new PowerpackApi(defaultClient);
18+
19+
Powerpack body =
20+
new Powerpack()
21+
.data(
22+
new PowerpackData()
23+
.attributes(
24+
new PowerpackAttributes()
25+
.description("Sample powerpack")
26+
.groupWidget(
27+
Map.ofEntries(
28+
Map.entry(
29+
"definition",
30+
"{'layout_type': 'ordered', 'show_title': True, 'title':"
31+
+ " 'Sample Powerpack', 'type': 'group', 'widgets':"
32+
+ " [{'definition': {'content': 'test', 'type':"
33+
+ " 'note'}}]}"),
34+
Map.entry(
35+
"layout", "{'height': 3, 'width': 12, 'x': 0, 'y': 0}")))
36+
.name("Sample Powerpack")
37+
.tags(Collections.singletonList("tag:sample"))
38+
.templateVariables(
39+
Collections.singletonList(
40+
new PowerpackTemplateVariable()
41+
.defaults(Collections.singletonList("*"))
42+
.name("sample"))))
43+
.type("powerpack"));
44+
45+
try {
46+
PowerpackResponse result = apiInstance.createPowerpack(body);
47+
System.out.println(result);
48+
} catch (ApiException e) {
49+
System.err.println("Exception when calling PowerpackApi#createPowerpack");
50+
System.err.println("Status code: " + e.getCode());
51+
System.err.println("Reason: " + e.getResponseBody());
52+
System.err.println("Response headers: " + e.getResponseHeaders());
53+
e.printStackTrace();
54+
}
55+
}
56+
}

0 commit comments

Comments
 (0)