GreengrassV2 / Client / list_core_devices
list_core_devices#
- GreengrassV2.Client.list_core_devices(**kwargs)#
Retrieves a paginated list of Greengrass core devices.
Note
IoT Greengrass relies on individual devices to send status updates to the Amazon Web Services Cloud. If the IoT Greengrass Core software isn’t running on the device, or if device isn’t connected to the Amazon Web Services Cloud, then the reported status of that device might not reflect its current status. The status timestamp indicates when the device status was last updated.
Core devices send status updates at the following times:
When the IoT Greengrass Core software starts
When the core device receives a deployment from the Amazon Web Services Cloud
For Greengrass nucleus 2.12.2 and earlier, the core device sends status updates when the status of any component on the core device becomes
ERRORED
orBROKEN
.For Greengrass nucleus 2.12.3 and later, the core device sends status updates when the status of any component on the core device becomes
ERRORED
,BROKEN
,RUNNING
, orFINISHED
.At a regular interval that you can configure, which defaults to 24 hours
For IoT Greengrass Core v2.7.0, the core device sends status updates upon local deployment and cloud deployment
See also: AWS API Documentation
Request Syntax
response = client.list_core_devices( thingGroupArn='string', status='HEALTHY'|'UNHEALTHY', maxResults=123, nextToken='string', runtime='string' )
- Parameters:
thingGroupArn (string) – The ARN of the IoT thing group by which to filter. If you specify this parameter, the list includes only core devices that have successfully deployed a deployment that targets the thing group. When you remove a core device from a thing group, the list continues to include that core device.
status (string) –
The core device status by which to filter. If you specify this parameter, the list includes only core devices that have this status. Choose one of the following options:
HEALTHY
– The IoT Greengrass Core software and all components run on the core device without issue.UNHEALTHY
– The IoT Greengrass Core software or a component is in a failed state on the core device.
maxResults (integer) – The maximum number of results to be returned per paginated request.
nextToken (string) – The token to be used for the next set of paginated results.
runtime (string) –
The runtime to be used by the core device. The runtime can be:
aws_nucleus_classic
aws_nucleus_lite
- Return type:
dict
- Returns:
Response Syntax
{ 'coreDevices': [ { 'coreDeviceThingName': 'string', 'status': 'HEALTHY'|'UNHEALTHY', 'lastStatusUpdateTimestamp': datetime(2015, 1, 1), 'platform': 'string', 'architecture': 'string', 'runtime': 'string' }, ], 'nextToken': 'string' }
Response Structure
(dict) –
coreDevices (list) –
A list that summarizes each core device.
(dict) –
Contains information about a Greengrass core device, which is an IoT thing that runs the IoT Greengrass Core software.
coreDeviceThingName (string) –
The name of the core device. This is also the name of the IoT thing.
status (string) –
The status of the core device. Core devices can have the following statuses:
HEALTHY
– The IoT Greengrass Core software and all components run on the core device without issue.UNHEALTHY
– The IoT Greengrass Core software or a component is in a failed state on the core device.
lastStatusUpdateTimestamp (datetime) –
The time at which the core device’s status last updated, expressed in ISO 8601 format.
platform (string) –
The operating system platform that the core device runs.
architecture (string) –
The computer architecture of the core device.
runtime (string) –
The runtime for the core device. The runtime can be:
aws_nucleus_classic
aws_nucleus_lite
nextToken (string) –
The token for the next set of results, or null if there are no additional results.
Exceptions
GreengrassV2.Client.exceptions.ValidationException
GreengrassV2.Client.exceptions.AccessDeniedException
GreengrassV2.Client.exceptions.InternalServerException
GreengrassV2.Client.exceptions.ThrottlingException