IoTSiteWise / Client / put_asset_model_interface_relationship
put_asset_model_interface_relationship¶
- IoTSiteWise.Client.put_asset_model_interface_relationship(**kwargs)¶
Creates or updates an interface relationship between an asset model and an interface asset model. This operation applies an interface to an asset model.
See also: AWS API Documentation
Request Syntax
response = client.put_asset_model_interface_relationship( assetModelId='string', interfaceAssetModelId='string', propertyMappingConfiguration={ 'matchByPropertyName': True|False, 'createMissingProperty': True|False, 'overrides': [ { 'assetModelPropertyId': 'string', 'interfaceAssetModelPropertyId': 'string' }, ] }, clientToken='string' )
- Parameters:
assetModelId (string) –
[REQUIRED]
The ID of the asset model. This can be either the actual ID in UUID format, or else externalId: followed by the external ID.
interfaceAssetModelId (string) –
[REQUIRED]
The ID of the interface asset model. This can be either the actual ID in UUID format, or else externalId: followed by the external ID.
propertyMappingConfiguration (dict) –
[REQUIRED]
The configuration for mapping properties from the interface asset model to the asset model where the interface is applied. This configuration controls how properties are matched and created during the interface application process.
matchByPropertyName (boolean) –
If true, properties are matched by name between the interface asset model and the asset model where the interface is applied.
createMissingProperty (boolean) –
If true, missing properties from the interface asset model are automatically created in the asset model where the interface is applied.
overrides (list) –
A list of specific property mappings that override the automatic mapping by name when an interface is applied to an asset model.
(dict) –
Maps a property from an interface asset model to a property in the asset model where the interface is applied.
assetModelPropertyId (string) – [REQUIRED]
The ID of the property in the asset model where the interface is applied.
interfaceAssetModelPropertyId (string) – [REQUIRED]
The ID of the property in the interface asset model.
clientToken (string) –
A unique case-sensitive identifier that you can provide to ensure the idempotency of the request. Don’t reuse this client token if a new idempotent request is required.
This field is autopopulated if not provided.
- Return type:
dict
- Returns:
Response Syntax
{ 'assetModelId': 'string', 'interfaceAssetModelId': 'string', 'assetModelArn': 'string', 'assetModelStatus': { 'state': 'CREATING'|'ACTIVE'|'UPDATING'|'PROPAGATING'|'DELETING'|'FAILED', 'error': { 'code': 'VALIDATION_ERROR'|'INTERNAL_FAILURE', 'message': 'string', 'details': [ { 'code': 'INCOMPATIBLE_COMPUTE_LOCATION'|'INCOMPATIBLE_FORWARDING_CONFIGURATION', 'message': 'string' }, ] } } }
Response Structure
(dict) –
assetModelId (string) –
The ID of the asset model.
interfaceAssetModelId (string) –
The ID of the interface asset model.
assetModelArn (string) –
The ARN of the asset model, which has the following format.
arn:${Partition}:iotsitewise:${Region}:${Account}:asset-model/${AssetModelId}
assetModelStatus (dict) –
Contains current status information for an asset model. For more information, see Asset and model states in the IoT SiteWise User Guide.
state (string) –
The current state of the asset model.
error (dict) –
Contains associated error information, if any.
code (string) –
The error code.
message (string) –
The error message.
details (list) –
A list of detailed errors.
(dict) –
Contains detailed error information.
code (string) –
The error code.
message (string) –
The error message.
Exceptions