Skip to main content

state_templates

Creates, updates, deletes, gets or lists a state_templates resource.

Overview

Namestate_templates
TypeResource
Idaws.iotfleetwise.state_templates

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringThe unique ID of the state template. (pattern: <code>[A-Z0-9]+</code>)
namestringThe name of the state template. (pattern: <code>[a-zA-Z\d-_:]+</code>)
arnstringThe Amazon Resource Name (ARN) of the state template.
creation_timestring (date-time)The time the state template was created in seconds since epoch (January 1, 1970 at midnight UTC time).
data_extra_dimensionsarrayA list of vehicle attributes associated with the payload published on the state template's MQTT topic. Default: An empty array
descriptionstringA brief description of the state template. (pattern: <code>[^\u0000-\u001F\u007F]+</code>)
last_modification_timestring (date-time)The time the state template was last updated in seconds since epoch (January 1, 1970 at midnight UTC time).
metadata_extra_dimensionsarrayA list of vehicle attributes to associate with user properties of the messages published on the state template's MQTT topic. Default: An empty array
signal_catalog_arnstringThe ARN of the signal catalog associated with the state template.
state_template_propertiesarrayA list of signals from which data is collected. The state template properties contain the fully qualified names of the signals.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_state_templateselectregionRetrieves information about a state template. Access to certain Amazon Web Services IoT FleetWise features is currently gated. For more information, see Amazon Web Services Region and feature availability in the Amazon Web Services IoT FleetWise Developer Guide.
list_state_templatesselectregionLists information about created state templates. Access to certain Amazon Web Services IoT FleetWise features is currently gated. For more information, see Amazon Web Services Region and feature availability in the Amazon Web Services IoT FleetWise Developer Guide.
create_state_templateinsertregion, name, signalCatalogArn, stateTemplatePropertiesCreates a state template. State templates contain state properties, which are signals that belong to a signal catalog that is synchronized between the Amazon Web Services IoT FleetWise Edge and the Amazon Web Services Cloud. Access to certain Amazon Web Services IoT FleetWise features is currently gated. For more information, see Amazon Web Services Region and feature availability in the Amazon Web Services IoT FleetWise Developer Guide.
update_state_templateupdateregion, identifierUpdates a state template. Access to certain Amazon Web Services IoT FleetWise features is currently gated. For more information, see Amazon Web Services Region and feature availability in the Amazon Web Services IoT FleetWise Developer Guide.
delete_state_templatedeleteregionDeletes a state template.

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.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Retrieves information about a state template. Access to certain Amazon Web Services IoT FleetWise features is currently gated. For more information, see Amazon Web Services Region and feature availability in the Amazon Web Services IoT FleetWise Developer Guide.

SELECT
id,
name,
arn,
creation_time,
data_extra_dimensions,
description,
last_modification_time,
metadata_extra_dimensions,
signal_catalog_arn,
state_template_properties
FROM aws.iotfleetwise.state_templates
WHERE region = '{{ region }}' -- required
;

INSERT examples

Creates a state template. State templates contain state properties, which are signals that belong to a signal catalog that is synchronized between the Amazon Web Services IoT FleetWise Edge and the Amazon Web Services Cloud. Access to certain Amazon Web Services IoT FleetWise features is currently gated. For more information, see Amazon Web Services Region and feature availability in the Amazon Web Services IoT FleetWise Developer Guide.

INSERT INTO aws.iotfleetwise.state_templates (
name,
description,
signalCatalogArn,
stateTemplateProperties,
dataExtraDimensions,
metadataExtraDimensions,
tags,
region
)
SELECT
'{{ name }}' /* required */,
'{{ description }}',
'{{ signalCatalogArn }}' /* required */,
'{{ stateTemplateProperties }}' /* required */,
'{{ dataExtraDimensions }}',
'{{ metadataExtraDimensions }}',
'{{ tags }}',
'{{ region }}'
RETURNING
id,
name,
arn
;

UPDATE examples

Updates a state template. Access to certain Amazon Web Services IoT FleetWise features is currently gated. For more information, see Amazon Web Services Region and feature availability in the Amazon Web Services IoT FleetWise Developer Guide.

UPDATE aws.iotfleetwise.state_templates
SET
identifier = '{{ identifier }}',
description = '{{ description }}',
stateTemplatePropertiesToAdd = '{{ stateTemplatePropertiesToAdd }}',
stateTemplatePropertiesToRemove = '{{ stateTemplatePropertiesToRemove }}',
dataExtraDimensions = '{{ dataExtraDimensions }}',
metadataExtraDimensions = '{{ metadataExtraDimensions }}'
WHERE
region = '{{ region }}' --required
AND identifier = '{{ identifier }}' --required
RETURNING
id,
name,
arn;

DELETE examples

Deletes a state template.

DELETE FROM aws.iotfleetwise.state_templates
WHERE region = '{{ region }}' --required
;