Skip to content

Commit 34244c8

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit a82ccfc of spec repo
1 parent 09fe883 commit 34244c8

20 files changed

+1153
-595
lines changed

.generator/schemas/v1/openapi.yaml

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23742,6 +23742,7 @@ components:
2374223742
- $ref: "#/components/schemas/ToplistWidgetDefinition"
2374323743
- $ref: "#/components/schemas/TopologyMapWidgetDefinition"
2374423744
- $ref: "#/components/schemas/TreeMapWidgetDefinition"
23745+
- $ref: "#/components/schemas/WildcardWidgetDefinition"
2374523746
WidgetDisplayType:
2374623747
description: Type of display to use for the request.
2374723748
enum:
@@ -24513,6 +24514,81 @@ components:
2451324514
x-enum-varnames:
2451424515
- TIMESERIES
2451524516
- TOPLIST
24517+
WildcardWidgetDefinition:
24518+
description: >-
24519+
Custom visualization widget using Vega or Vega-Lite specifications. Combines standard Datadog data requests with a Vega or Vega-Lite JSON specification for flexible, custom visualizations.
24520+
properties:
24521+
custom_links:
24522+
description: List of custom links.
24523+
items:
24524+
$ref: "#/components/schemas/WidgetCustomLink"
24525+
type: array
24526+
requests:
24527+
description: List of data requests for the wildcard widget.
24528+
example: [{"formulas": ["formula": "query1"], "queries": [{"aggregator": "avg", "data_source": "metrics", "name": "query1", "query": "avg:system.cpu.user{*} by {env}"}], "response_format": "scalar"}]
24529+
items:
24530+
$ref: "#/components/schemas/WildcardWidgetRequest"
24531+
type: array
24532+
specification:
24533+
$ref: "#/components/schemas/WildcardWidgetSpecification"
24534+
time:
24535+
$ref: "#/components/schemas/WidgetTime"
24536+
title:
24537+
description: Title of the widget.
24538+
type: string
24539+
title_align:
24540+
$ref: "#/components/schemas/WidgetTextAlign"
24541+
title_size:
24542+
description: Size of the title.
24543+
type: string
24544+
type:
24545+
$ref: "#/components/schemas/WildcardWidgetDefinitionType"
24546+
required:
24547+
- type
24548+
- requests
24549+
- specification
24550+
type: object
24551+
WildcardWidgetDefinitionType:
24552+
default: wildcard
24553+
description: Type of the wildcard widget.
24554+
enum:
24555+
- wildcard
24556+
example: wildcard
24557+
type: string
24558+
x-enum-varnames:
24559+
- WILDCARD
24560+
WildcardWidgetRequest:
24561+
description: >-
24562+
Request object for the wildcard widget. Each variant represents a distinct data-fetching pattern: scalar formulas, timeseries formulas, list streams, and histograms.
24563+
oneOf:
24564+
- $ref: "#/components/schemas/TreeMapWidgetRequest"
24565+
- $ref: "#/components/schemas/TimeseriesWidgetRequest"
24566+
- $ref: "#/components/schemas/ListStreamWidgetRequest"
24567+
- $ref: "#/components/schemas/DistributionWidgetRequest"
24568+
WildcardWidgetSpecification:
24569+
description: >-
24570+
Vega or Vega-Lite specification for custom visualization rendering. See https://vega.github.io/vega-lite/ for the full grammar reference.
24571+
properties:
24572+
contents:
24573+
description: The Vega or Vega-Lite JSON specification object.
24574+
example: {"$schema": "https://vega.github.io/schema/vega-lite/v5.json", "data": {"name": "table1"}, "description": "A simple bar chart", "encoding": {"x": {"field": "env", "sort": "-y", "type": "nominal"}, "y": {"field": "query1", "type": "quantitative"}}, "mark": "bar"}
24575+
type: object
24576+
type:
24577+
$ref: "#/components/schemas/WildcardWidgetSpecificationType"
24578+
required:
24579+
- type
24580+
- contents
24581+
type: object
24582+
WildcardWidgetSpecificationType:
24583+
description: Type of specification used by the wildcard widget.
24584+
enum:
24585+
- vega
24586+
- vega-lite
24587+
example: vega-lite
24588+
type: string
24589+
x-enum-varnames:
24590+
- VEGA
24591+
- VEGA_LITE
2451624592
securitySchemes:
2451724593
AuthZ:
2451824594
description: This API uses OAuth 2 with the implicit grant flow.

.generator/schemas/v2/openapi.yaml

Lines changed: 7 additions & 84 deletions
Original file line numberDiff line numberDiff line change
@@ -65885,8 +65885,6 @@ components:
6588565885
properties:
6588665886
frequency:
6588765887
$ref: "#/components/schemas/TeamSyncAttributesFrequency"
65888-
selection_state:
65889-
$ref: "#/components/schemas/TeamSyncAttributesSelectionState"
6589065888
source:
6589165889
$ref: "#/components/schemas/TeamSyncAttributesSource"
6589265890
sync_membership:
@@ -65909,14 +65907,6 @@ components:
6590965907
- ONCE
6591065908
- CONTINUOUSLY
6591165909
- PAUSED
65912-
TeamSyncAttributesSelectionState:
65913-
description: |-
65914-
Specifies which teams or organizations to sync. When
65915-
provided, synchronization is limited to the specified
65916-
items and their subtrees.
65917-
items:
65918-
$ref: "#/components/schemas/TeamSyncSelectionStateItem"
65919-
type: array
6592065910
TeamSyncAttributesSource:
6592165911
description: The external source platform for team synchronization. Only "github" is supported.
6592265912
enum:
@@ -65926,7 +65916,6 @@ components:
6592665916
x-enum-varnames:
6592765917
- GITHUB
6592865918
TeamSyncAttributesSyncMembership:
65929-
default: false
6593065919
description: Whether to sync members from the external team to the Datadog team. Defaults to `false` when not provided.
6593165920
example: true
6593265921
type: boolean
@@ -65986,72 +65975,6 @@ components:
6598665975
$ref: "#/components/schemas/TeamSyncData"
6598765976
type: array
6598865977
type: object
65989-
TeamSyncSelectionStateExternalId:
65990-
description: The external identifier for a team or organization in the source platform.
65991-
properties:
65992-
type:
65993-
$ref: "#/components/schemas/TeamSyncSelectionStateExternalIdType"
65994-
value:
65995-
$ref: "#/components/schemas/TeamSyncSelectionStateExternalIdValue"
65996-
required:
65997-
- type
65998-
- value
65999-
type: object
66000-
TeamSyncSelectionStateExternalIdType:
66001-
description: |-
66002-
The type of external identifier for the selection state item.
66003-
For GitHub synchronization, the allowed values are `team` and
66004-
`organization`.
66005-
enum:
66006-
- team
66007-
- organization
66008-
example: team
66009-
type: string
66010-
x-enum-varnames:
66011-
- TEAM
66012-
- ORGANIZATION
66013-
TeamSyncSelectionStateExternalIdValue:
66014-
description: |-
66015-
The external identifier value from the source
66016-
platform. For GitHub, this is the string
66017-
representation of a GitHub organization ID or team
66018-
ID.
66019-
example: "1"
66020-
type: string
66021-
TeamSyncSelectionStateItem:
66022-
description: Identifies a team or organization hierarchy to include in synchronization.
66023-
properties:
66024-
external_id:
66025-
$ref: "#/components/schemas/TeamSyncSelectionStateExternalId"
66026-
operation:
66027-
$ref: "#/components/schemas/TeamSyncSelectionStateOperation"
66028-
scope:
66029-
$ref: "#/components/schemas/TeamSyncSelectionStateScope"
66030-
required:
66031-
- external_id
66032-
type: object
66033-
TeamSyncSelectionStateOperation:
66034-
description: |-
66035-
The operation to perform on the selected hierarchy.
66036-
When set to `include`, synchronization covers the
66037-
referenced teams or organizations.
66038-
enum:
66039-
- include
66040-
example: include
66041-
type: string
66042-
x-enum-varnames:
66043-
- INCLUDE
66044-
TeamSyncSelectionStateScope:
66045-
description: |-
66046-
The scope of the selection. When set to `subtree`,
66047-
synchronization includes the referenced team or
66048-
organization and everything nested under it.
66049-
enum:
66050-
- subtree
66051-
example: subtree
66052-
type: string
66053-
x-enum-varnames:
66054-
- SUBTREE
6605565978
TeamTarget:
6605665979
description: "Represents a team target for an escalation policy step, including the team's ID and resource type."
6605765980
properties:
@@ -105511,6 +105434,12 @@ paths:
105511105434
description: OK
105512105435
"403":
105513105436
$ref: "#/components/responses/ForbiddenResponse"
105437+
"404":
105438+
content:
105439+
application/json:
105440+
schema:
105441+
$ref: "#/components/schemas/APIErrorResponse"
105442+
description: Team sync configurations not found
105514105443
"429":
105515105444
$ref: "#/components/responses/TooManyRequestsResponse"
105516105445
security:
@@ -105527,17 +105456,13 @@ paths:
105527105456
- teams_read
105528105457
post:
105529105458
description: |-
105530-
This endpoint configures synchronization between your existing Datadog teams and GitHub teams by matching their names.
105459+
This endpoint attempts to link your existing Datadog teams with GitHub teams by matching their names.
105531105460
It evaluates all current Datadog teams and compares them against teams in the GitHub organization
105532105461
connected to your Datadog account, based on Datadog Team handle and GitHub Team slug
105533105462
(lowercased and kebab-cased).
105534105463

105535105464
This operation is read-only on the GitHub side, no teams will be modified or created.
105536105465

105537-
Optionally, provide `selection_state` to limit synchronization
105538-
to specific teams or organizations and their subtrees, instead
105539-
of syncing all teams.
105540-
105541105466
[A GitHub organization must be connected to your Datadog account](https://docs.datadoghq.com/integrations/github/),
105542105467
and the GitHub App integrated with Datadog must have the `Members Read` permission. Matching is performed by comparing the Datadog team handle to the GitHub team slug
105543105468
using a normalized exact match; case is ignored and spaces are removed. No modifications are made
@@ -105552,8 +105477,6 @@ paths:
105552105477
responses:
105553105478
"200":
105554105479
description: OK
105555-
"204":
105556-
description: No Content
105557105480
"403":
105558105481
$ref: "#/components/responses/ForbiddenResponse"
105559105482
"429":
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
// Sync 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.TeamSyncAttributes;
7+
import com.datadog.api.client.v2.model.TeamSyncAttributesSource;
8+
import com.datadog.api.client.v2.model.TeamSyncAttributesType;
9+
import com.datadog.api.client.v2.model.TeamSyncBulkType;
10+
import com.datadog.api.client.v2.model.TeamSyncData;
11+
import com.datadog.api.client.v2.model.TeamSyncRequest;
12+
13+
public class Example {
14+
public static void main(String[] args) {
15+
ApiClient defaultClient = ApiClient.getDefaultApiClient();
16+
TeamsApi apiInstance = new TeamsApi(defaultClient);
17+
18+
TeamSyncRequest body =
19+
new TeamSyncRequest()
20+
.data(
21+
new TeamSyncData()
22+
.attributes(
23+
new TeamSyncAttributes()
24+
.source(TeamSyncAttributesSource.GITHUB)
25+
.type(TeamSyncAttributesType.LINK))
26+
.type(TeamSyncBulkType.TEAM_SYNC_BULK));
27+
28+
try {
29+
apiInstance.syncTeams(body);
30+
} catch (ApiException e) {
31+
System.err.println("Exception when calling TeamsApi#syncTeams");
32+
System.err.println("Status code: " + e.getCode());
33+
System.err.println("Reason: " + e.getResponseBody());
34+
System.err.println("Response headers: " + e.getResponseHeaders());
35+
e.printStackTrace();
36+
}
37+
}
38+
}

0 commit comments

Comments
 (0)