From 2b06998e59d286622cf6642bc92f51aa8800993c Mon Sep 17 00:00:00 2001 From: "ci.datadog-api-spec" Date: Wed, 25 Nov 2026 18:28:33 +0000 Subject: [PATCH] Regenerate client from commit 5ced7e1 of spec repo --- .generator/schemas/v2/openapi.yaml | 76 +++++++++++++++---- .../datadog/api/client/v2/api/EventsApi.java | 58 ++++++++++++-- .../client/v2/model/EventsListRequest.java | 4 +- .../client/v2/model/EventsQueryFilter.java | 9 ++- .../api/client/v2/model/EventsSort.java | 5 +- 5 files changed, 123 insertions(+), 29 deletions(-) diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 368bc0d9a4e..ba987fecbc1 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -51167,18 +51167,19 @@ components: from: default: "now-15m" description: |- - The minimum time for the requested events. Supports date math and regular timestamps in milliseconds. + The minimum time for the requested events. Supports date math, ISO 8601, and timestamps in milliseconds. + Set an earlier time than the default to search beyond the last 15 minutes. example: "now-15m" type: string query: default: "*" - description: The search query following the event search syntax. - example: "service:web* AND @http.status_code:[200 TO 299]" + description: The search query following the event search syntax. Attributes take `@` (`@evt.category:alert`); tags and reserved fields don't (`service:web`). + example: "@evt.integration_id:kubernetes @evt.category:alert" type: string to: default: "now" description: |- - The maximum time for the requested events. Supports date math and regular timestamps in milliseconds. + The maximum time for the requested events. Supports date math, ISO 8601, and timestamps in milliseconds. example: "now" type: string type: object @@ -51292,7 +51293,9 @@ components: type: string type: object EventsSort: - description: The sort parameters when querying events. + description: |- + The sort order of events. `-timestamp` (the default) returns the newest events first, and `timestamp` returns + the oldest first. The client libraries reject any other value. enum: - timestamp - -timestamp @@ -189946,21 +189949,33 @@ paths: [Results are paginated similarly to logs](https://docs.datadoghq.com/logs/guide/collect-multiple-logs-with-pagination). Use this endpoint to see your latest events. + + Query syntax: Attributes take `@` (`@evt.integration_id:kubernetes`, `@evt.category:alert`), while tags and + reserved fields don't (`kube_cluster_name:gizmo`, `service:web`, `source:oom_kill`). A name that needs `@` + matches nothing without it. To filter by integration, prefer `@evt.integration_id`, whose values use hyphens + (`oom-kill`), over `source`, whose values use underscores (`oom_kill`). Bare words search the event text. + Quoted phrases, `OR`, `-` negation, and value wildcards are supported. Wildcards in attribute names, such as + `@*.name`, are not supported. + + Without `filter[from]`, the endpoint searches only the last 15 minutes. Widen the time window before concluding that no event exists. + Each event's own fields are under `data[].attributes.attributes`, for example `evt.integration_id`, `evt.category`, + `title`, and `service`. To fetch one event with `GetEvent`, use its `evt.id` or `evt.uid`, not the top-level `data[].id`. operationId: ListEvents parameters: - - description: Search query following events syntax. + - description: Search query following events syntax. Attributes take `@` (`@evt.category:alert`); tags and reserved fields don't (`service:web`). + example: "@evt.integration_id:kubernetes @evt.category:alert" in: query name: filter[query] required: false schema: type: string - - description: Minimum timestamp for requested events, in milliseconds. + - description: Minimum time for requested events, as date math (`now-1h`), ISO 8601, or a timestamp in milliseconds. Defaults to `now-15m`. in: query name: filter[from] required: false schema: type: string - - description: Maximum timestamp for requested events, in milliseconds. + - description: Maximum time for requested events, as date math, ISO 8601, or a timestamp in milliseconds. Defaults to `now`. in: query name: filter[to] required: false @@ -190187,23 +190202,52 @@ paths: [Results are paginated similarly to logs](https://docs.datadoghq.com/logs/guide/collect-multiple-logs-with-pagination). Use this endpoint to build complex events filtering and search. + + Query syntax: Attributes take `@` (`@evt.integration_id:kubernetes`, `@evt.category:alert`), while tags and + reserved fields don't (`kube_cluster_name:gizmo`, `service:web`, `source:oom_kill`). A name that needs `@` + matches nothing without it. To filter by integration, prefer `@evt.integration_id`, whose values use hyphens + (`oom-kill`), over `source`, whose values use underscores (`oom_kill`). Bare words search the event text. + Quoted phrases, `OR`, `-` negation, and value wildcards are supported. Wildcards in attribute names, such as + `@*.name`, are not supported. + + Without `filter.from`, the endpoint searches only the last 15 minutes. Widen the time window before concluding that no event exists. + Each event's own fields are under `data[].attributes.attributes`, for example `evt.integration_id`, `evt.category`, + `title`, and `service`. To fetch one event with `GetEvent`, use its `evt.id` or `evt.uid`, not the top-level `data[].id`. operationId: SearchEvents requestBody: content: "application/json": examples: default: + summary: Alert events from an integration at a cluster, newest first value: filter: - from: now-15m - query: service:web* AND @http.status_code:[200 TO 299] + from: now-1h + query: "@evt.integration_id:kubernetes @evt.category:alert kube_cluster_name:prod-cluster" to: now - options: - timezone: GMT page: - cursor: eyJzdGFydEF0IjoiQVFBQUFYS2tMS3pPbm40NGV3QUFBQUJCV0V0clRFdDZVbG8zY3pCRmNsbHJiVmxDWlEifQ== - limit: 25 - sort: timestamp + limit: 100 + sort: -timestamp + impacted_resource_changes: + summary: Changes that name an impacted resource + value: + filter: + from: now-24h + query: '@evt.integration_id:change-tracking @impacted_resources.name:"checkout-api"' + to: now + page: + limit: 100 + sort: -timestamp + service_changes: + summary: Changes to a service over the last day + value: + filter: + from: now-24h + query: "@evt.category:change service:checkout" + to: now + page: + limit: 100 + sort: -timestamp schema: $ref: "#/components/schemas/EventsListRequest" required: false @@ -190256,7 +190300,7 @@ paths: Get the details of an event by `event_id`. operationId: GetEvent parameters: - - description: The UID of the event. + - description: The event's `evt.id` or `evt.uid`, read from `data[].attributes.attributes.evt` in `ListEvents` or `SearchEvents` results. The top-level `data[].id` is not accepted. in: path name: event_id required: true diff --git a/src/main/java/com/datadog/api/client/v2/api/EventsApi.java b/src/main/java/com/datadog/api/client/v2/api/EventsApi.java index 34ceecabd0d..ee59c3e39b6 100644 --- a/src/main/java/com/datadog/api/client/v2/api/EventsApi.java +++ b/src/main/java/com/datadog/api/client/v2/api/EventsApi.java @@ -202,7 +202,9 @@ public CompletableFuture> createEventWit * *

See {@link #getEventWithHttpInfo}. * - * @param eventId The UID of the event. (required) + * @param eventId The event's evt.id or evt.uid, read from + * data[].attributes.attributes.evt in ListEvents or SearchEvents + * results. The top-level data[].id is not accepted. (required) * @return V2EventResponse * @throws ApiException if fails to make API call */ @@ -215,7 +217,9 @@ public V2EventResponse getEvent(String eventId) throws ApiException { * *

See {@link #getEventWithHttpInfoAsync}. * - * @param eventId The UID of the event. (required) + * @param eventId The event's evt.id or evt.uid, read from + * data[].attributes.attributes.evt in ListEvents or SearchEvents + * results. The top-level data[].id is not accepted. (required) * @return CompletableFuture<V2EventResponse> */ public CompletableFuture getEventAsync(String eventId) { @@ -229,7 +233,9 @@ public CompletableFuture getEventAsync(String eventId) { /** * Get the details of an event by event_id. * - * @param eventId The UID of the event. (required) + * @param eventId The event's evt.id or evt.uid, read from + * data[].attributes.attributes.evt in ListEvents or SearchEvents + * results. The top-level data[].id is not accepted. (required) * @return ApiResponse<V2EventResponse> * @throws ApiException if fails to make API call * @http.response.details @@ -283,7 +289,9 @@ public ApiResponse getEventWithHttpInfo(String eventId) throws * *

See {@link #getEventWithHttpInfo}. * - * @param eventId The UID of the event. (required) + * @param eventId The event's evt.id or evt.uid, read from + * data[].attributes.attributes.evt in ListEvents or SearchEvents + * results. The top-level data[].id is not accepted. (required) * @return CompletableFuture<ApiResponse<V2EventResponse>> */ public CompletableFuture> getEventWithHttpInfoAsync(String eventId) { @@ -342,7 +350,9 @@ public static class ListEventsOptionalParameters { /** * Set filterQuery. * - * @param filterQuery Search query following events syntax. (optional) + * @param filterQuery Search query following events syntax. Attributes take @ ( + * @evt.category:alert); tags and reserved fields don't (service:web + * ). (optional) * @return ListEventsOptionalParameters */ public ListEventsOptionalParameters filterQuery(String filterQuery) { @@ -353,7 +363,8 @@ public ListEventsOptionalParameters filterQuery(String filterQuery) { /** * Set filterFrom. * - * @param filterFrom Minimum timestamp for requested events, in milliseconds. (optional) + * @param filterFrom Minimum time for requested events, as date math (now-1h), ISO + * 8601, or a timestamp in milliseconds. Defaults to now-15m. (optional) * @return ListEventsOptionalParameters */ public ListEventsOptionalParameters filterFrom(String filterFrom) { @@ -364,7 +375,8 @@ public ListEventsOptionalParameters filterFrom(String filterFrom) { /** * Set filterTo. * - * @param filterTo Maximum timestamp for requested events, in milliseconds. (optional) + * @param filterTo Maximum time for requested events, as date math, ISO 8601, or a timestamp in + * milliseconds. Defaults to now. (optional) * @return ListEventsOptionalParameters */ public ListEventsOptionalParameters filterTo(String filterTo) { @@ -526,6 +538,22 @@ public PaginationIterable listEventsWithPagination( * *

Use this endpoint to see your latest events. * + *

Query syntax: Attributes take @ (@evt.integration_id:kubernetes, + * @evt.category:alert), while tags and reserved fields don't ( + * kube_cluster_name:gizmo, service:web, source:oom_kill). A name + * that needs @ matches nothing without it. To filter by integration, prefer + * @evt.integration_id, whose values use hyphens (oom-kill), over source + * , whose values use underscores (oom_kill). Bare words search the event + * text. Quoted phrases, OR, - negation, and value wildcards are + * supported. Wildcards in attribute names, such as @*.name, are not supported. + * + *

Without filter[from], the endpoint searches only the last 15 minutes. Widen the + * time window before concluding that no event exists. Each event's own fields are under + * data[].attributes.attributes, for example evt.integration_id, + * evt.category, title, and service. To fetch one event with + * GetEvent, use its evt.id or evt.uid, not the top-level + * data[].id. + * * @param parameters Optional parameters for the request. * @return ApiResponse<EventsListResponse> * @throws ApiException if fails to make API call @@ -781,6 +809,22 @@ public PaginationIterable searchEventsWithPagination( * *

Use this endpoint to build complex events filtering and search. * + *

Query syntax: Attributes take @ (@evt.integration_id:kubernetes, + * @evt.category:alert), while tags and reserved fields don't ( + * kube_cluster_name:gizmo, service:web, source:oom_kill). A name + * that needs @ matches nothing without it. To filter by integration, prefer + * @evt.integration_id, whose values use hyphens (oom-kill), over source + * , whose values use underscores (oom_kill). Bare words search the event + * text. Quoted phrases, OR, - negation, and value wildcards are + * supported. Wildcards in attribute names, such as @*.name, are not supported. + * + *

Without filter.from, the endpoint searches only the last 15 minutes. Widen the + * time window before concluding that no event exists. Each event's own fields are under + * data[].attributes.attributes, for example evt.integration_id, + * evt.category, title, and service. To fetch one event with + * GetEvent, use its evt.id or evt.uid, not the top-level + * data[].id. + * * @param parameters Optional parameters for the request. * @return ApiResponse<EventsListResponse> * @throws ApiException if fails to make API call diff --git a/src/main/java/com/datadog/api/client/v2/model/EventsListRequest.java b/src/main/java/com/datadog/api/client/v2/model/EventsListRequest.java index d159bceaf78..212bdc09e46 100644 --- a/src/main/java/com/datadog/api/client/v2/model/EventsListRequest.java +++ b/src/main/java/com/datadog/api/client/v2/model/EventsListRequest.java @@ -122,7 +122,9 @@ public EventsListRequest sort(EventsSort sort) { } /** - * The sort parameters when querying events. + * The sort order of events. -timestamp (the default) returns the newest events + * first, and timestamp returns the oldest first. The client libraries reject any + * other value. * * @return sort */ diff --git a/src/main/java/com/datadog/api/client/v2/model/EventsQueryFilter.java b/src/main/java/com/datadog/api/client/v2/model/EventsQueryFilter.java index 66f360fcc1d..2359c3da6fb 100644 --- a/src/main/java/com/datadog/api/client/v2/model/EventsQueryFilter.java +++ b/src/main/java/com/datadog/api/client/v2/model/EventsQueryFilter.java @@ -41,8 +41,8 @@ public EventsQueryFilter from(String from) { } /** - * The minimum time for the requested events. Supports date math and regular timestamps in - * milliseconds. + * The minimum time for the requested events. Supports date math, ISO 8601, and timestamps in + * milliseconds. Set an earlier time than the default to search beyond the last 15 minutes. * * @return from */ @@ -63,7 +63,8 @@ public EventsQueryFilter query(String query) { } /** - * The search query following the event search syntax. + * The search query following the event search syntax. Attributes take @ ( + * @evt.category:alert); tags and reserved fields don't (service:web). * * @return query */ @@ -84,7 +85,7 @@ public EventsQueryFilter to(String to) { } /** - * The maximum time for the requested events. Supports date math and regular timestamps in + * The maximum time for the requested events. Supports date math, ISO 8601, and timestamps in * milliseconds. * * @return to diff --git a/src/main/java/com/datadog/api/client/v2/model/EventsSort.java b/src/main/java/com/datadog/api/client/v2/model/EventsSort.java index 1948d3653e0..ed0dc76abe5 100644 --- a/src/main/java/com/datadog/api/client/v2/model/EventsSort.java +++ b/src/main/java/com/datadog/api/client/v2/model/EventsSort.java @@ -18,7 +18,10 @@ import java.util.HashSet; import java.util.Set; -/** The sort parameters when querying events. */ +/** + * The sort order of events. -timestamp (the default) returns the newest events first, + * and timestamp returns the oldest first. The client libraries reject any other value. + */ @JsonSerialize(using = EventsSort.EventsSortSerializer.class) public class EventsSort extends ModelEnum {