scenes
Creates, updates, deletes, gets or lists a scenes resource.
Overview
| Name | scenes |
| Type | Resource |
| Id | aws.iottwinmaker.scenes |
Fields
The following fields are returned by SELECT queries:
- get_scene
- list_scenes
| Name | Datatype | Description |
|---|---|---|
arn | string | The ARN of the scene. (pattern: <code>arn:((aws)|(aws-cn)|(aws-us-gov)):iottwinmaker:[a-z0-9-]+:[0-9]{12}:[/a-zA-Z0-9_-.:]+</code>) |
capabilities | array | A list of capabilities that the scene uses to render. |
content_location | string | The relative path that specifies the location of the content definition file. (pattern: <code>[sS]3://[A-Za-z0-9._/-]+</code>) |
creation_date_time | string (date-time) | The date and time when the scene was created. |
description | string | The description of the scene. (pattern: <code>.*</code>) |
error | object | The SceneResponse error. |
generated_scene_metadata | object | The generated scene metadata. |
scene_id | string | The ID of the scene. (pattern: <code>[a-zA-Z_0-9][a-zA-Z_-0-9]*[a-zA-Z0-9]+</code>) |
scene_metadata | object | The response metadata. |
update_date_time | string (date-time) | The date and time when the scene was last updated. |
workspace_id | string | The ID of the workspace that contains the scene. (pattern: <code>[a-zA-Z_0-9][a-zA-Z_-0-9]*[a-zA-Z0-9]+</code>) |
| Name | Datatype | Description |
|---|---|---|
next_token | string | The string that specifies the next page of results. (pattern: <code>.*</code>) |
scene_summaries | array | A list of objects that contain information about the scenes. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_scene | select | workspace_id, scene_id, region | Retrieves information about a scene. | |
list_scenes | select | workspace_id, region | Lists all scenes in a workspace. | |
create_scene | insert | workspace_id, region, sceneId, contentLocation | Creates a scene. | |
update_scene | update | workspace_id, scene_id, region | Updates a scene. | |
delete_scene | delete | workspace_id, scene_id, region | Deletes a scene. |
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) |
scene_id | string | The ID of the scene to delete. |
workspace_id | string | The ID of the workspace. |
SELECT examples
- get_scene
- list_scenes
Retrieves information about a scene.
SELECT
arn,
capabilities,
content_location,
creation_date_time,
description,
error,
generated_scene_metadata,
scene_id,
scene_metadata,
update_date_time,
workspace_id
FROM aws.iottwinmaker.scenes
WHERE workspace_id = '{{ workspace_id }}' -- required
AND scene_id = '{{ scene_id }}' -- required
AND region = '{{ region }}' -- required
;
Lists all scenes in a workspace.
SELECT
next_token,
scene_summaries
FROM aws.iottwinmaker.scenes
WHERE workspace_id = '{{ workspace_id }}' -- required
AND region = '{{ region }}' -- required
;
INSERT examples
- create_scene
- Manifest
Creates a scene.
INSERT INTO aws.iottwinmaker.scenes (
sceneId,
contentLocation,
description,
capabilities,
tags,
sceneMetadata,
workspace_id,
region
)
SELECT
'{{ sceneId }}' /* required */,
'{{ contentLocation }}' /* required */,
'{{ description }}',
'{{ capabilities }}',
'{{ tags }}',
'{{ sceneMetadata }}',
'{{ workspace_id }}',
'{{ region }}'
RETURNING
arn,
creation_date_time
;
# Description fields are for documentation purposes
- name: scenes
props:
- name: workspace_id
value: "{{ workspace_id }}"
description: Required parameter for the scenes resource.
- name: region
value: "{{ region }}"
description: Required parameter for the scenes resource.
- name: sceneId
value: "{{ sceneId }}"
- name: contentLocation
value: "{{ contentLocation }}"
- name: description
value: "{{ description }}"
- name: capabilities
value:
- "{{ capabilities }}"
- name: tags
value: "{{ tags }}"
- name: sceneMetadata
value: "{{ sceneMetadata }}"
UPDATE examples
- update_scene
Updates a scene.
UPDATE aws.iottwinmaker.scenes
SET
contentLocation = '{{ contentLocation }}',
description = '{{ description }}',
capabilities = '{{ capabilities }}',
sceneMetadata = '{{ sceneMetadata }}'
WHERE
workspace_id = '{{ workspace_id }}' --required
AND scene_id = '{{ scene_id }}' --required
AND region = '{{ region }}' --required
RETURNING
update_date_time;
DELETE examples
- delete_scene
Deletes a scene.
DELETE FROM aws.iottwinmaker.scenes
WHERE workspace_id = '{{ workspace_id }}' --required
AND scene_id = '{{ scene_id }}' --required
AND region = '{{ region }}' --required
;