CmdID / aws / aws iotthingsgraph
aws iotthingsgraph search-entities
Searches for entities of the specified type. AWS CLI reference
1 example 5 options Its page in the AWS CLI reference
Examples
To search for entities
The following search-entities example searches for all entities of type EVENT.
aws iotthingsgraph search-entities --entity-types "EVENT"Identify--entity-typesThe entity types for which to search.Its output
{
"descriptions": [
{
"id": "urn:tdm:aws/examples:Event:MotionSensorEvent",
"type": "EVENT",
"definition": {
"language": "GRAPHQL",
"text": "##\n# Description of events emitted by motion sensor.\n##\ntype MotionSensorEvent @eventType(id: \"urn:tdm:aws/examples:event:MotionSensorEvent\",\n payload: \"urn:tdm:aws/examples:property:MotionSensorStateProperty\") {ignore:void}"
}
},
{
"id": "urn:tdm:us-west-2/123456789012/default:Event:CameraClickedEventV2",
"type": "EVENT",
"definition": {
"language": "GRAPHQL",
"text": "type CameraClickedEventV2 @eventType(id: \"urn:tdm:us-west-2/123456789012/default:event:CameraClickedEventV2\",\r\npayload: \"urn:tdm:aws:Property:Boolean\"){ignore:void}"
}
},
{
"id": "urn:tdm:us-west-2/123456789012/default:Event:MotionSensorEventV2",
"type": "EVENT",
"definition": {
"language": "GRAPHQL",
"text": "# Event emitted by the motion sensor.\r\ntype MotionSensorEventV2 @eventType(id: \"urn:tdm:us-west-2/123456789012/default:event:MotionSensorEventV2\",\r\npayload: \"urn:tdm:us-west-2/123456789012/default:property:MotionSensorStateProperty2\") {ignore:void}"
}
}
],
"nextToken": "urn:tdm:us-west-2/123456789012/default:Event:MotionSensorEventV2"
}Options
--entity-typesThe entity types for which to search.--filtersOptional filter to apply to the search.--max-resultsThe maximum number of results to return in the response.--namespace-versionThe version of the user's namespace.--next-tokenThe string that specifies the next page of results.