scenes
Creates, updates, deletes or gets a scene
resource or lists scenes
in a region
Overview
Name | scenes |
Type | Resource |
Description | Resource schema for AWS::IoTTwinMaker::Scene |
Id | aws.iottwinmaker.scenes |
Fields
Name | Datatype | Description |
---|---|---|
scene_id | string | The ID of the scene. |
arn | string | The ARN of the scene. |
description | string | The description of the scene. |
content_location | string | The relative path that specifies the location of the content definition file. |
creation_date_time | string | The date and time when the scene was created. |
update_date_time | string | The date and time of the current update. |
tags | object | A key-value pair to associate with a resource. |
workspace_id | string | The ID of the scene. |
capabilities | array | A list of capabilities that the scene uses to render. |
scene_metadata | object | A key-value pair of scene metadata for the scene. |
generated_scene_metadata | object | A key-value pair of generated scene metadata for the scene. |
region | string | AWS region. |
Methods
Name | Accessible by | Required Params |
---|---|---|
create_resource | INSERT | WorkspaceId, SceneId, ContentLocation, region |
delete_resource | DELETE | data__Identifier, region |
update_resource | UPDATE | data__Identifier, data__PatchDocument, region |
list_resources | SELECT | region |
get_resource | SELECT | data__Identifier, region |
SELECT
examples
Gets all scenes
in a region.
SELECT
region,
scene_id,
arn,
description,
content_location,
creation_date_time,
update_date_time,
tags,
workspace_id,
capabilities,
scene_metadata,
generated_scene_metadata
FROM aws.iottwinmaker.scenes
WHERE region = 'us-east-1';
Gets all properties from an individual scene
.
SELECT
region,
scene_id,
arn,
description,
content_location,
creation_date_time,
update_date_time,
tags,
workspace_id,
capabilities,
scene_metadata,
generated_scene_metadata
FROM aws.iottwinmaker.scenes
WHERE region = 'us-east-1' AND data__Identifier = '<WorkspaceId>|<SceneId>';
INSERT
example
Use the following StackQL query and manifest file to create a new scene
resource, using stack-deploy
.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO aws.iottwinmaker.scenes (
SceneId,
ContentLocation,
WorkspaceId,
region
)
SELECT
'{{ SceneId }}',
'{{ ContentLocation }}',
'{{ WorkspaceId }}',
'{{ region }}';
/*+ create */
INSERT INTO aws.iottwinmaker.scenes (
SceneId,
Description,
ContentLocation,
Tags,
WorkspaceId,
Capabilities,
SceneMetadata,
region
)
SELECT
'{{ SceneId }}',
'{{ Description }}',
'{{ ContentLocation }}',
'{{ Tags }}',
'{{ WorkspaceId }}',
'{{ Capabilities }}',
'{{ SceneMetadata }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: scene
props:
- name: SceneId
value: '{{ SceneId }}'
- name: Description
value: '{{ Description }}'
- name: ContentLocation
value: '{{ ContentLocation }}'
- name: Tags
value: {}
- name: WorkspaceId
value: '{{ WorkspaceId }}'
- name: Capabilities
value:
- '{{ Capabilities[0] }}'
- name: SceneMetadata
value: {}
DELETE
example
/*+ delete */
DELETE FROM aws.iottwinmaker.scenes
WHERE data__Identifier = '<WorkspaceId|SceneId>'
AND region = 'us-east-1';
Permissions
To operate on the scenes
resource, the following permissions are required:
Create
iottwinmaker:CreateScene,
iottwinmaker:GetScene,
iottwinmaker:GetWorkspace,
iottwinmaker:ListTagsForResource,
iottwinmaker:TagResource
Read
iottwinmaker:GetWorkspace,
iottwinmaker:GetScene,
iottwinmaker:ListTagsForResource
Update
iottwinmaker:GetScene,
iottwinmaker:GetWorkspace,
iottwinmaker:ListTagsForResource,
iottwinmaker:TagResource,
iottwinmaker:UntagResource,
iottwinmaker:UpdateScene
Delete
iottwinmaker:DeleteScene,
iottwinmaker:GetScene,
iottwinmaker:GetWorkspace
List
iottwinmaker:GetWorkspace,
iottwinmaker:ListTagsForResource,
iottwinmaker:ListScenes