themes
Creates, updates, deletes or gets a theme resource or lists themes in a region
Overview
| Name | themes |
| Type | Resource |
| Description | Definition of the AWS::QuickSight::Theme Resource Type. |
| Id | awscc.quicksight.themes |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
arn | string | The Amazon Resource Name (ARN) of the theme. |
aws_account_id | string | |
base_theme_id | string | |
configuration | object | a theme. |
created_time | string | The date and time that the theme was created. |
last_updated_time | string | The date and time that the theme was last updated. |
name | string | |
permissions | array | |
tags | array | |
theme_id | string | |
type | string | |
version | object | A version of a theme. |
version_description | string | |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
aws_account_id | string | |
theme_id | string | |
region | string | AWS region. |
For more information, see AWS::QuickSight::Theme.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | themes | INSERT | AwsAccountId, ThemeId, BaseThemeId, Configuration, Name, region |
delete_resource | themes | DELETE | Identifier, region |
update_resource | themes | UPDATE | Identifier, PatchDocument, region |
list_resources | themes_list_only | SELECT | region |
get_resource | themes | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual theme.
SELECT
region,
arn,
aws_account_id,
base_theme_id,
configuration,
created_time,
last_updated_time,
name,
permissions,
tags,
theme_id,
type,
version,
version_description
FROM awscc.quicksight.themes
WHERE
region = '{{ region }}' AND
Identifier = '{{ theme_id }}|{{ aws_account_id }}';
Lists all themes in a region.
SELECT
region,
theme_id,
aws_account_id
FROM awscc.quicksight.themes_list_only
WHERE
region = '{{ region }}';
INSERT example
Use the following StackQL query and manifest file to create a new theme resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.quicksight.themes (
AwsAccountId,
BaseThemeId,
Configuration,
Name,
ThemeId,
region
)
SELECT
'{{ aws_account_id }}',
'{{ base_theme_id }}',
'{{ configuration }}',
'{{ name }}',
'{{ theme_id }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
/*+ create */
INSERT INTO awscc.quicksight.themes (
AwsAccountId,
BaseThemeId,
Configuration,
Name,
Permissions,
Tags,
ThemeId,
VersionDescription,
region
)
SELECT
'{{ aws_account_id }}',
'{{ base_theme_id }}',
'{{ configuration }}',
'{{ name }}',
'{{ permissions }}',
'{{ tags }}',
'{{ theme_id }}',
'{{ version_description }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: theme
props:
- name: aws_account_id
value: '{{ aws_account_id }}'
- name: base_theme_id
value: '{{ base_theme_id }}'
- name: configuration
value:
data_color_palette:
colors:
- '{{ colors[0] }}'
min_max_gradient:
- '{{ min_max_gradient[0] }}'
empty_fill_color: '{{ empty_fill_color }}'
u_icolor_palette:
primary_foreground: '{{ primary_foreground }}'
primary_background: '{{ primary_background }}'
secondary_foreground: '{{ secondary_foreground }}'
secondary_background: '{{ secondary_background }}'
accent: '{{ accent }}'
accent_foreground: '{{ accent_foreground }}'
danger: '{{ danger }}'
danger_foreground: '{{ danger_foreground }}'
warning: '{{ warning }}'
warning_foreground: '{{ warning_foreground }}'
success: '{{ success }}'
success_foreground: '{{ success_foreground }}'
dimension: '{{ dimension }}'
dimension_foreground: '{{ dimension_foreground }}'
measure: '{{ measure }}'
measure_foreground: '{{ measure_foreground }}'
sheet:
tile:
border:
show: '{{ show }}'
tile_layout:
gutter:
show: '{{ show }}'
margin:
show: '{{ show }}'
typography:
font_families:
- font_family: '{{ font_family }}'
- name: name
value: '{{ name }}'
- name: permissions
value:
- principal: '{{ principal }}'
actions:
- '{{ actions[0] }}'
- name: tags
value:
- key: '{{ key }}'
value: '{{ value }}'
- name: theme_id
value: '{{ theme_id }}'
- name: version_description
value: '{{ version_description }}'
UPDATE example
Use the following StackQL query and manifest file to update a theme resource, using stack-deploy.
/*+ update */
UPDATE awscc.quicksight.themes
SET PatchDocument = string('{{ {
"BaseThemeId": base_theme_id,
"Configuration": configuration,
"Name": name,
"Permissions": permissions,
"Tags": tags,
"VersionDescription": version_description
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ theme_id }}|{{ aws_account_id }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
DELETE example
/*+ delete */
DELETE FROM awscc.quicksight.themes
WHERE
Identifier = '{{ theme_id }}|{{ aws_account_id }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
Additional Parameters
Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:
| Parameter | Description |
|---|---|
ClientToken | A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.A client token is valid for 36 hours once used. After that, a resource request with the same client token is treated as a new request. If you do not specify a client token, one is generated for inclusion in the request. |
RoleArn | The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.If you do not specify a role, a temporary session is created using your AWS user credentials. |
TypeVersionId | For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used. |
Permissions
To operate on the themes resource, the following permissions are required:
- Read
- Create
- List
- Update
- Delete
quicksight:DescribeTheme,
quicksight:DescribeThemePermissions,
quicksight:ListTagsForResource
quicksight:DescribeTheme,
quicksight:DescribeThemePermissions,
quicksight:CreateTheme,
quicksight:TagResource,
quicksight:UntagResource,
quicksight:ListTagsForResource
quicksight:ListThemes
quicksight:DescribeTheme,
quicksight:DescribeThemePermissions,
quicksight:UpdateTheme,
quicksight:UpdateThemePermissions,
quicksight:TagResource,
quicksight:UntagResource,
quicksight:ListTagsForResource
quicksight:DescribeTheme,
quicksight:DeleteTheme