- Resource: Chart
- Methods
Resource: Chart
Configurable dashboard's widget that displays data as a chart.
| JSON representation |
|---|
{ "name": string, "displayName": string, "description": string, "chartVisualizationType": enum ( |
| Fields | |
|---|---|
name |
Identifier. Chart resource name. Format: projects/{project}/locations/{location}/dashboards/{dashboard}/charts/{chart} |
displayName |
User provided display name of the chart. |
description |
Chart description |
chartVisualizationType |
Chart visualization type. |
createTime |
Output only. Chart create time. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: |
updateTime |
Output only. Chart last update time. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: |
chartType |
Output only. Chart type. |
dataSource |
|
width |
The width of the chart in grid units. |
height |
The height of the chart in grid units. |
filter |
Filter applied to all charts in the container. Should support scope later. |
dateRangeConfig |
Date range config applied to the chart. |
action |
Optional action to be taken when the chart is clicked. |
ChartVisualizationType
This enum represents the different types of charts that can be created.
| Enums | |
|---|---|
CHART_VISUALIZATION_TYPE_UNSPECIFIED |
Unspecified chart visualization type. |
BAR |
Bar chart. |
LINE |
Line chart. |
AREA |
Area chart. |
PIE |
Pie chart. |
SCATTER |
Scatter chart. |
TABLE |
Table chart. |
SCORE_CARD |
Score card chart. |
SUNBURST |
Sunburst chart. |
GAUGE |
Gauge chart. |
SANKEY |
Sankey chart. |
ChartType
Chart type enum.
| Enums | |
|---|---|
CHART_TYPE_UNSPECIFIED |
Unspecified chart type. |
SYSTEM_DEFINED |
Pre-defined chart type. |
USER_DEFINED |
Configurable chart type. |
ChartDataSource
The request data for visualizing the dataset in the chart.
| JSON representation |
|---|
{ // The following is a list of mutually exclusive fields. At most one of the // fields will be set in a response: "generativeInsights": { object ( |
| Fields | |
|---|---|
| The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: | |
generativeInsights |
Use natural language query to generate the chart. |
queryMetrics |
Use the existing QueryMetrics to generate the chart. |
| End of mutually exclusive fields. | |
GenerativeInsights
Request that use natural language query to generate the chart.
| JSON representation |
|---|
{ "request": { "@type": string, field1: ..., ... }, "chartSpec": { object }, "sqlQuery": string, "sqlComparisonKey": string, "chartConversations": [ { object ( |
| Fields | |
|---|---|
request |
An object containing fields of an arbitrary type. An additional field |
chartSpec |
Chart spec for the chart. |
sqlQuery |
SQL query used to generate the chart. |
sqlComparisonKey |
Optional. For charts with comparison, this key will determine the metric that will be compared between the current and another dataset. |
chartConversations[] |
Output only. The chart conversations used to generate the chart. |
chartCheckpoint |
The chart checkpoint used to generate the chart. |
ChartConversation
The conversation used to generate the chart.
| JSON representation |
|---|
{
"conversationId": string,
"createTime": string,
"updateTime": string,
"messages": [
{
object ( |
| Fields | |
|---|---|
conversationId |
The conversation id of the chart. |
createTime |
The create time of the conversation. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: |
updateTime |
The update time of the conversation. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: |
messages[] |
Ordered list of messages, including user inputs and system responses. |
Message
The message in the conversation.
| JSON representation |
|---|
{ "messageId": string, "createTime": string, // The following is a list of mutually exclusive fields. At most one of the // fields will be set in a response: "userMessage": { object ( |
| Fields | |
|---|---|
messageId |
The message id of the message. |
createTime |
For user messages, this is the time at which the system received the message. For system messages, this is the time at which the system generated the message. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: |
| The kind of message, can be user or system message. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: | |
userMessage |
A message from the user that is interacting with the system. |
systemMessage |
A message from the system in response to the user. |
| End of mutually exclusive fields. | |
UserMessage
The user message.
| JSON representation |
|---|
{ "text": string } |
| Fields | |
|---|---|
text |
A message from the user that is interacting with the system. |
SystemMessage
A message from the system in response to the user. This message can also be a message from the user as historical context for multiturn conversations with the system.
| JSON representation |
|---|
{
// The following is a list of mutually exclusive fields. At most one of the
// fields will be set in a response:
"textOutput": {
object ( |
| Fields | |
|---|---|
| The kind of content in the system message. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: | |
textOutput |
A direct natural language response to the user message. |
generatedSqlQuery |
Raw SQL from LLM, before templatization |
chartSpec |
Chart spec from LLM |
| End of mutually exclusive fields. | |
TextOutput
A text output message from the system.
| JSON representation |
|---|
{
"texts": [
string
],
"type": enum ( |
| Fields | |
|---|---|
texts[] |
The parts of the message. |
type |
The type of the text message. |
Type
The type of the text message.
| Enums | |
|---|---|
TYPE_UNSPECIFIED |
The default text type. |
THOUGHT |
The text is a thinking plan generated by the thinking tool. |
FINAL_RESPONSE |
The text is a final response to the user question. |
PROGRESS |
The text is an informational message about the agent's progress, such as a tool being invoked. This is distinct from the agent's internal thought process (THOUGHT) and the final answer to the user (FINAL_RESPONSE). These messages provide insight into the agent's actions. |
ChartCheckpoint
The current chart checkpoint state.
| JSON representation |
|---|
{ "sessionId": string, "revisionId": string } |
| Fields | |
|---|---|
sessionId |
The session id of the chart. |
revisionId |
The revision id of the chart. |
QueryMetrics
Request data that use the existing QueryMetrics.
| JSON representation |
|---|
{ "request": { "@type": string, field1: ..., ... } } |
| Fields | |
|---|---|
request |
An object containing fields of an arbitrary type. An additional field |
ChartAction
The action to be taken when the chart is clicked.
| JSON representation |
|---|
{
"conversationFilter": string,
// The following is a list of mutually exclusive fields. At most one of the
// fields will be set in a response:
"redirectAction": {
object ( |
| Fields | |
|---|---|
conversationFilter |
The conversation filter string. |
| The type of action to be taken when the chart is clicked. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: | |
redirectAction |
Redirect action. |
| End of mutually exclusive fields. | |
RedirectAction
The redirect action to be taken when the chart is clicked.
| JSON representation |
|---|
{ "relativePath": string, "queryParams": { string: string, ... } } |
| Fields | |
|---|---|
relativePath |
The relative path to redirect to. |
queryParams |
The query params to be added to the redirect path. An object containing a list of |
Methods |
|
|---|---|
|
Creates a Chart. |
|
Deletes a Chart. |
|
Gets a Chart. |
|
Lists Charts. |
|
Updates a Chart. |