SearchSystemInstancesCommand

  • since: 2022-08-30

Searches for system instances in the user's account.

Example Syntax

Use a bare-bones client and the command you need to make an API call.

import { IoTThingsGraphClient, SearchSystemInstancesCommand } from "@aws-sdk/client-iotthingsgraph"; // ES Modules import
// const { IoTThingsGraphClient, SearchSystemInstancesCommand } = require("@aws-sdk/client-iotthingsgraph"); // CommonJS import
const client = new IoTThingsGraphClient(config);
const input = { // SearchSystemInstancesRequest
  filters: [ // SystemInstanceFilters
    { // SystemInstanceFilter
      name: "SYSTEM_TEMPLATE_ID" || "STATUS" || "GREENGRASS_GROUP_NAME",
      value: [ // SystemInstanceFilterValues
        "STRING_VALUE",
      ],
    },
  ],
  nextToken: "STRING_VALUE",
  maxResults: Number("int"),
};
const command = new SearchSystemInstancesCommand(input);
const response = await client.send(command);
// { // SearchSystemInstancesResponse
//   summaries: [ // SystemInstanceSummaries
//     { // SystemInstanceSummary
//       id: "STRING_VALUE",
//       arn: "STRING_VALUE",
//       status: "NOT_DEPLOYED" || "BOOTSTRAP" || "DEPLOY_IN_PROGRESS" || "DEPLOYED_IN_TARGET" || "UNDEPLOY_IN_PROGRESS" || "FAILED" || "PENDING_DELETE" || "DELETED_IN_TARGET",
//       target: "GREENGRASS" || "CLOUD",
//       greengrassGroupName: "STRING_VALUE",
//       createdAt: new Date("TIMESTAMP"),
//       updatedAt: new Date("TIMESTAMP"),
//       greengrassGroupId: "STRING_VALUE",
//       greengrassGroupVersionId: "STRING_VALUE",
//     },
//   ],
//   nextToken: "STRING_VALUE",
// };

SearchSystemInstancesCommand Input

Parameter
Type
Description
filters
SystemInstanceFilter[] | undefined

Optional filter to apply to the search. Valid filters are SYSTEM_TEMPLATE_ID, STATUS, and GREENGRASS_GROUP_NAME.

Multiple filters function as OR criteria in the query. Multiple values passed inside the filter function as AND criteria.

maxResults
number | undefined

The maximum number of results to return in the response.

nextToken
string | undefined

The string that specifies the next page of results. Use this when you're paginating results.

SearchSystemInstancesCommand Output

Parameter
Type
Description
$metadata
Required
ResponseMetadata
Metadata pertaining to this request.
nextToken
string | undefined

The string to specify as nextToken when you request the next page of results.

summaries
SystemInstanceSummary[] | undefined

An array of objects that contain summary data abour the system instances in the result set.

Throws

Name
Fault
Details
InternalFailureException
server

InvalidRequestException
client

ThrottlingException
client

IoTThingsGraphServiceException
Base exception class for all service exceptions from IoTThingsGraph service.