Skip to main content

asset_properties

Creates, updates, deletes, gets or lists an asset_properties resource.

Overview

Nameasset_properties
TypeResource
Idaws.iotsitewise.asset_properties

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
asset_external_idstringThe external ID of the asset. For more information, see Using external IDs in the IoT SiteWise User Guide. (pattern: <code>[a-zA-Z0-9_][a-zA-Z_-0-9.:]*[a-zA-Z0-9_]+</code>)
asset_idstringThe ID of the asset, in UUID format. (pattern: <code>^(?!00000000-0000-0000-0000-000000000000)[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$</code>)
asset_model_idstringThe ID of the asset model, in UUID format. (pattern: <code>^(?!00000000-0000-0000-0000-000000000000)[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$</code>)
asset_namestringThe name of the asset. (pattern: <code>[^\u0000-\u001F\u007F]+</code>)
asset_propertyobjectThe asset property's definition, alias, and notification state. This response includes this object for normal asset properties. If you describe an asset property in a composite model, this response includes the asset property information in compositeModel.
composite_modelobjectThe composite model that declares this asset property, if this asset property exists in a composite model.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
describe_asset_propertyselectasset_id, property_id, regionRetrieves information about an asset property. When you call this operation for an attribute property, this response includes the default attribute value that you define in the asset model. If you update the default value in the model, this operation's response includes the new default value. This operation doesn't return the value of the asset property. To get the value of an asset property, use GetAssetPropertyValue.
list_asset_propertiesselectasset_id, regionnextToken, maxResults, filterRetrieves a paginated list of properties associated with an asset. If you update properties associated with the model before you finish listing all the properties, you need to start all over again.
associate_time_series_to_asset_propertyupdatealias, assetId, propertyId, regionAssociates a time series (data stream) with an asset property.
update_asset_propertyupdateasset_id, property_id, regionUpdates an asset property's alias and notification state. This operation overwrites the property's existing alias and notification state. To keep your existing property's alias or notification state, you must include the existing values in the UpdateAssetProperty request. For more information, see DescribeAssetProperty.
disassociate_time_series_from_asset_propertyexecalias, assetId, propertyId, regionDisassociates a time series (data stream) from an asset property.

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
aliasstringThe alias that identifies the time series.
assetIdstringThe ID of the asset in which the asset property was created. This can be either the actual ID in UUID format, or else externalId: followed by the external ID, if it has one. For more information, see Referencing objects with external IDs in the IoT SiteWise User Guide.
asset_idstringThe ID of the asset to be updated. This can be either the actual ID in UUID format, or else externalId: followed by the external ID, if it has one. For more information, see Referencing objects with external IDs in the IoT SiteWise User Guide.
propertyIdstringThe ID of the asset property. This can be either the actual ID in UUID format, or else externalId: followed by the external ID, if it has one. For more information, see Referencing objects with external IDs in the IoT SiteWise User Guide.
property_idstringThe ID of the asset property to be updated. This can be either the actual ID in UUID format, or else externalId: followed by the external ID, if it has one. For more information, see Referencing objects with external IDs in the IoT SiteWise User Guide.
regionstringAWS region (default: us-east-1)
filterstringFilters the requested list of asset properties. You can choose one of the following options: ALL – The list includes all asset properties for a given asset model ID. BASE – The list includes only base asset properties for a given asset model ID. Default: BASE
maxResultsintegerThe maximum number of results to return for each paginated request. If not specified, the default value is 50.
nextTokenstringThe token to be used for the next set of paginated results.

SELECT examples

Retrieves information about an asset property. When you call this operation for an attribute property, this response includes the default attribute value that you define in the asset model. If you update the default value in the model, this operation's response includes the new default value. This operation doesn't return the value of the asset property. To get the value of an asset property, use GetAssetPropertyValue.

SELECT
asset_external_id,
asset_id,
asset_model_id,
asset_name,
asset_property,
composite_model
FROM aws.iotsitewise.asset_properties
WHERE asset_id = '{{ asset_id }}' -- required
AND property_id = '{{ property_id }}' -- required
AND region = '{{ region }}' -- required
;

UPDATE examples

Associates a time series (data stream) with an asset property.

UPDATE aws.iotsitewise.asset_properties
SET
clientToken = '{{ clientToken }}'
WHERE
alias = '{{ alias }}' --required
AND assetId = '{{ assetId }}' --required
AND propertyId = '{{ propertyId }}' --required
AND region = '{{ region }}' --required;

Lifecycle Methods

Disassociates a time series (data stream) from an asset property.

EXEC aws.iotsitewise.asset_properties.disassociate_time_series_from_asset_property
@alias='{{ alias }}' --required,
@assetId='{{ assetId }}' --required,
@propertyId='{{ propertyId }}' --required,
@region='{{ region }}' --required
@@json=
'{
"clientToken": "{{ clientToken }}"
}'
;