AWS IoT

2019/03/21 - AWS IoT - 1 new api methods

Changes  This release adds the GetStatistics API for the AWS IoT Fleet Indexing Service, which allows customers to query for statistics about registered devices that match a search query. This release only supports the count statistics. For more information about this API, see https://docs.aws.amazon.com/iot/latest/apireference/API_GetStatistics.html

GetStatistics (new) Link ΒΆ

Gets statistics about things that match the specified query.

See also: AWS API Documentation

Request Syntax

client.get_statistics(
    indexName='string',
    queryString='string',
    aggregationField='string',
    queryVersion='string'
)
type indexName

string

param indexName

The name of the index to search. The default value is AWS_Things .

type queryString

string

param queryString

[REQUIRED]

The query used to search. You can specify "*" for the query string to get the count of all indexed things in your AWS account.

type aggregationField

string

param aggregationField

The aggregation field name. Currently not supported.

type queryVersion

string

param queryVersion

The version of the query used to search.

rtype

dict

returns

Response Syntax

{
    'statistics': {
        'count': 123
    }
}

Response Structure

  • (dict) --

    • statistics (dict) --

      The statistics returned by the Fleet Indexing service based on the query and aggregation field.

      • count (integer) --

        The count of things that match the query.