---
title: "POST /properties/batch/aggregates"
method: POST
path: "/properties/batch/aggregates"
---

# POST /properties/batch/aggregates

`POST /properties/batch/aggregates`

Gets aggregated values (for example, average, minimum, and maximum) for one or more asset properties. For more information, see <a href="https://docs.aws.amazon.com/iot-sitewise/latest/userguide/query-industrial-data.html#aggregates">Querying aggregates</a> in the <i>IoT SiteWise User Guide</i>.

## Query parameters

- `maxResults` string
- `nextToken` string

## Request body

- object
  - `entries` BatchGetAssetPropertyAggregatesEntry[], required — The list of asset property aggregate entries for the batch get request. You can specify up to 16 entries per request.
    - `entryId` string, required — The ID of the entry.
    - `assetId` string — The ID of the asset in which the asset property was created.
    - `propertyId` string — The ID of the asset property.
    - `propertyAlias` string — The alias that identifies the property, such as an OPC-UA server data stream path (for example, <code>/company/windfarm/3/turbine/7/temperature</code>). For more information, see <a href="https://docs.aws.amazon.com/iot-sitewise/latest/userguide/connect-data-streams.html">Mapping industrial data streams to asset properties</a> in the <i>IoT SiteWise User Guide</i>.
    - `aggregateTypes` AggregateType[], required — The data aggregating function.
    - `resolution` string, required — The time interval over which to aggregate data.
    - `startDate` string, date-time, required — The exclusive start of the range from which to query historical data, expressed in seconds in Unix epoch time.
    - `endDate` string, date-time, required — The inclusive end of the range from which to query historical data, expressed in seconds in Unix epoch time.
    - `qualities` Quality[] — The quality by which to filter asset data.
    - `timeOrdering` 'ASCENDING' | 'DESCENDING' — <p>The chronological sorting order of the requested information.</p> <p>Default: <code>ASCENDING</code> </p>
  - `nextToken` string — The token to be used for the next set of paginated results.
  - `maxResults` integer — <p>The maximum number of results to return for each paginated request. A result set is returned in the two cases, whichever occurs first.</p> <ul> <li> <p>The size of the result set is less than 1 MB.</p> </li> <li> <p>The number of data points in the result set is less than the value of <code>maxResults</code>. The maximum value of <code>maxResults</code> is 4000.</p> </li> </ul>

## Response `200`

Success

- BatchGetAssetPropertyAggregatesResponse
  - `errorEntries` BatchGetAssetPropertyAggregatesErrorEntry[], required — A list of the errors (if any) associated with the batch request. Each error entry contains the <code>entryId</code> of the entry that failed.
    - `errorCode` 'ResourceNotFoundException' | 'InvalidRequestException' | 'AccessDeniedException', required — The error code.
    - `errorMessage` string, required — The associated error message.
    - `entryId` string, required — The ID of the entry.
  - `successEntries` BatchGetAssetPropertyAggregatesSuccessEntry[], required — A list of entries that were processed successfully by this batch request. Each success entry contains the <code>entryId</code> of the entry that succeeded and the latest query result.
    - `entryId` string, required — The ID of the entry.
    - `aggregatedValues` AggregatedValue[], required — The requested aggregated asset property values (for example, average, minimum, and maximum).
      - `timestamp` string, date-time, required — The date the aggregating computations occurred, in Unix epoch time.
      - `quality` 'GOOD' | 'BAD' | 'UNCERTAIN' — The quality of the aggregated data.
      - `value` object, required — The value of the aggregates.
        - `average` number, double — The average (mean) value of the time series over a time interval window.
        - `count` number, double — The count of data points in the time series over a time interval window.
        - `maximum` number, double — The maximum value of the time series over a time interval window.
        - `minimum` number, double — The minimum value of the time series over a time interval window.
        - `sum` number, double — The sum of the time series over a time interval window.
        - `standardDeviation` number, double — The standard deviation of the time series over a time interval window.
  - `skippedEntries` BatchGetAssetPropertyAggregatesSkippedEntry[], required — A list of entries that were not processed by this batch request. because these entries had been completely processed by previous paginated requests. Each skipped entry contains the <code>entryId</code> of the entry that skipped.
    - `entryId` string, required — The ID of the entry.
    - `completionStatus` 'SUCCESS' | 'ERROR', required — The completion status of each entry that is associated with the <a href="https://docs.aws.amazon.com/iot-sitewise/latest/APIReference/API_BatchGetAssetPropertyAggregates.html">BatchGetAssetPropertyAggregates</a> API.
    - `errorInfo` object — The error information, such as the error code and the timestamp.
      - `errorCode` 'ResourceNotFoundException' | 'InvalidRequestException' | 'AccessDeniedException', required — The error code.
      - `errorTimestamp` string, date-time, required — The date the error occurred, in Unix epoch time.
  - `nextToken` string — The token for the next set of results, or null if there are no additional results.

## Other responses

- `480` — InvalidRequestException
- `481` — InternalFailureException
- `482` — ThrottlingException
- `483` — ServiceUnavailableException

---

[API](https://skmtc.net/aws/apis/iotsitewise.md) · [All operations](https://skmtc.net/aws/apis/iotsitewise/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/aws/iotsitewise/versions/d13e5d3e0a6f/schema)
