IoT / Client / get_cardinality
get_cardinality#
- IoT.Client.get_cardinality(**kwargs)#
Returns the approximate count of unique values that match the query.
Requires permission to access the GetCardinality action.
See also: AWS API Documentation
Request Syntax
response = client.get_cardinality( indexName='string', queryString='string', aggregationField='string', queryVersion='string' )
- Parameters:
indexName (string) – The name of the index to search.
queryString (string) –
[REQUIRED]
The search query string.
aggregationField (string) – The field to aggregate.
queryVersion (string) – The query version.
- Return type:
dict
- Returns:
Response Syntax
{ 'cardinality': 123 }
Response Structure
(dict) –
cardinality (integer) –
The approximate count of unique values that match the query.
Exceptions
IoT.Client.exceptions.InvalidRequestExceptionIoT.Client.exceptions.ThrottlingExceptionIoT.Client.exceptions.UnauthorizedExceptionIoT.Client.exceptions.ServiceUnavailableExceptionIoT.Client.exceptions.InternalFailureExceptionIoT.Client.exceptions.ResourceNotFoundExceptionIoT.Client.exceptions.InvalidQueryExceptionIoT.Client.exceptions.InvalidAggregationExceptionIoT.Client.exceptions.IndexNotReadyException