v1

latestOpenAPI 3.0.0Creative Commons Attribution 3.02026-07-1380629577.7 KB
projects

Natural language based Insights which powers the next generation of dashboards in Insights. Next generation of QueryMetrics.

post/v1/{+location}:generativeInsights

Path parameters

locationstring required

Required. The location of the data. "projects/{project}/locations/{location}"

Request body

sessionIdstring

Optional. The session id of the conversation. If the session id is not specified, backend will generate a random session id. If the session id is specified, will associate user-provided user_query with the provided session id.

userProvidedChartSpecobject

Optional. The user provided chart spec for the chart. This will be used to override the visual spec generated by the LLM.

revisionIdstring

Optional. The revision id that maps to the state of the chart state revision. When specified, the backend will reload the chart with the sql and visual spec from that revision.

filterstring

Filter for the data that can be specified in addition to the natural language query. Users are encouraged to use this field to populate time-windows.

naturalLanguageQuerystring

The natural language query specified by the user. If this field is specified, sql_query will be ignored.

chartstring

The full name of the chart resource this request corresponds to. Format: projects/{project}/locations/{location}/dashboards/{dashboard}/charts/{chart}

comparisonFilterstring

Optional. Filter for the data that can be specified in addition to the natural language query. This filter is specifically used for charts where comparisons are possible. For example, "compare to last month" or "compare to previous quarter".

sqlQuerystring

Optional. The SQL query specified by the user. This query must be in BigQuery SQL dialect. The filter field will also be ignored, as it is assumed that any filtering is already included in the SQL query.

sqlComparisonKeystring

Optional. For charts with comparison, this key will determine the metric that will be compared between the current and another dataset.

Response

Successful response