dashboards
Creates, updates, deletes, gets or lists a dashboards resource.
Overview
| Name | dashboards |
| Type | Resource |
| Id | aws.bcm_dashboards.dashboards |
Fields
The following fields are returned by SELECT queries:
- get_dashboard
- list_dashboards
| Name | Datatype | Description |
|---|---|---|
name | string | The name of the retrieved dashboard. (pattern: <code>(?!.* {2})[a-zA-Z][a-zA-Z0-9 -]{0,48}[a-zA-Z0-9-]</code>) |
arn | string | The ARN of the retrieved dashboard. (pattern: <code>arn:aws[-a-z0-9]*:bcm-dashboards::[0-9]{12}:dashboard/(*|[-a-z0-9]+)</code>) |
created_at | string (date-time) | The timestamp when the dashboard was created. |
description | string | The description of the retrieved dashboard. (pattern: <code>(?!.* {2})[ a-zA-Z0-9.,!?;:@#$%&-_/\]*</code>) |
type_ | string | Indicates the dashboard type. (CUSTOM) |
updated_at | string (date-time) | The timestamp when the dashboard was last modified. |
widgets | array | An array of widget configurations that make up the dashboard. |
| Name | Datatype | Description |
|---|---|---|
name | string | The name of the referenced dashboard. (pattern: <code>(?!.* {2})[a-zA-Z][a-zA-Z0-9 -]{0,48}[a-zA-Z0-9-]</code>) |
arn | string | The ARN of the referenced dashboard. (pattern: <code>arn:aws[-a-z0-9]*:bcm-dashboards::[0-9]{12}:dashboard/(*|[-a-z0-9]+)</code>) |
created_at | string (date-time) | The timestamp when the dashboard was created. |
description | string | The description of the referenced dashboard. (pattern: <code>(?!.* {2})[ a-zA-Z0-9.,!?;:@#$%&-_/\]*</code>) |
type_ | string | The dashboard type. (CUSTOM) |
updated_at | string (date-time) | The timestamp when the dashboard was last modified. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_dashboard | select | region | Retrieves the configuration and metadata of a specified dashboard, including its widgets and layout settings. | |
list_dashboards | select | region | Returns a list of all dashboards in your account. | |
create_dashboard | insert | region, name, widgets | Creates a new dashboard that can contain multiple widgets displaying cost and usage data. You can add custom widgets or use predefined widgets, arranging them in your preferred layout. | |
update_dashboard | update | region, arn, name | Updates an existing dashboard's properties, including its name, description, and widget configurations. | |
delete_dashboard | delete | region | Deletes a specified dashboard. This action cannot be undone. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
region | string | AWS region (default: us-east-1) |
SELECT examples
- get_dashboard
- list_dashboards
Retrieves the configuration and metadata of a specified dashboard, including its widgets and layout settings.
SELECT
name,
arn,
created_at,
description,
type_,
updated_at,
widgets
FROM aws.bcm_dashboards.dashboards
WHERE region = '{{ region }}' -- required
;
Returns a list of all dashboards in your account.
SELECT
name,
arn,
created_at,
description,
type_,
updated_at
FROM aws.bcm_dashboards.dashboards
WHERE region = '{{ region }}' -- required
;
INSERT examples
- create_dashboard
- Manifest
Creates a new dashboard that can contain multiple widgets displaying cost and usage data. You can add custom widgets or use predefined widgets, arranging them in your preferred layout.
INSERT INTO aws.bcm_dashboards.dashboards (
name,
description,
widgets,
resourceTags,
region
)
SELECT
'{{ name }}' /* required */,
'{{ description }}',
'{{ widgets }}' /* required */,
'{{ resourceTags }}',
'{{ region }}'
RETURNING
arn
;
# Description fields are for documentation purposes
- name: dashboards
props:
- name: region
value: "{{ region }}"
description: Required parameter for the dashboards resource.
- name: name
value: "{{ name }}"
description: |
The name of the dashboard. The name must be unique within your account.
- name: description
value: "{{ description }}"
description: |
A description of the dashboard's purpose or contents.
- name: widgets
description: |
An array of widget configurations that define the visualizations to be displayed in the dashboard. Each dashboard can contain up to 20 widgets.
value:
- id: "{{ id }}"
title_: "{{ title_ }}"
description: "{{ description }}"
width: {{ width }}
height: {{ height }}
horizontalOffset: {{ horizontalOffset }}
configs: "{{ configs }}"
- name: resourceTags
description: |
The tags to apply to the dashboard resource for organization and management.
value:
- key: "{{ key }}"
value: "{{ value }}"
UPDATE examples
- update_dashboard
Updates an existing dashboard's properties, including its name, description, and widget configurations.
UPDATE aws.bcm_dashboards.dashboards
SET
arn = '{{ arn }}',
name = '{{ name }}',
description = '{{ description }}',
widgets = '{{ widgets }}'
WHERE
region = '{{ region }}' --required
AND arn = '{{ arn }}' --required
AND name = '{{ name }}' --required
RETURNING
arn;
DELETE examples
- delete_dashboard
Deletes a specified dashboard. This action cannot be undone.
DELETE FROM aws.bcm_dashboards.dashboards
WHERE region = '{{ region }}' --required
;