---
title: "POST /#X-Amz-Target=DeviceFarm_20150623.ListDeviceInstances"
method: POST
path: "/#X-Amz-Target=DeviceFarm_20150623.ListDeviceInstances"
---

# POST /#X-Amz-Target=DeviceFarm_20150623.ListDeviceInstances

`POST /#X-Amz-Target=DeviceFarm_20150623.ListDeviceInstances`

Returns information about the private device instances associated with one or more AWS accounts.

## Headers

- `X-Amz-Target` 'DeviceFarm_20150623.ListDeviceInstances', required

## Request body

- ListDeviceInstancesRequest
  - `maxResults` integer — An integer that specifies the maximum number of items you want to return in the API response.
  - `nextToken` string — An identifier that was returned from the previous call to this operation, which can be used to return the next set of items in the list.

## Response `200`

Success

- ListDeviceInstancesResult
  - `deviceInstances` DeviceInstance[] — An object that contains information about your device instances.
    - `arn` string — The Amazon Resource Name (ARN) of the device instance.
    - `deviceArn` string — The ARN of the device.
    - `labels` String[] — An array of strings that describe the device instance.
    - `status` 'IN_USE' | 'PREPARING' | 'AVAILABLE' | 'NOT_AVAILABLE' — The status of the device instance. Valid values are listed here.
    - `udid` string — Unique device identifier for the device instance.
    - `instanceProfile` object — A object that contains information about the instance profile.
      - `arn` string — The Amazon Resource Name (ARN) of the instance profile.
      - `packageCleanup` boolean — When set to <code>true</code>, Device Farm removes app packages after a test run. The default value is <code>false</code> for private devices.
      - `excludeAppPackagesFromCleanup` String[] — <p>An array of strings containing the list of app packages that should not be cleaned up from the device after a test run completes.</p> <p>The list of packages is considered only if you set <code>packageCleanup</code> to <code>true</code>.</p>
      - `rebootAfterUse` boolean — When set to <code>true</code>, Device Farm reboots the instance after a test run. The default value is <code>true</code>.
      - `name` string — The name of the instance profile.
      - `description` string — The description of the instance profile.
  - `nextToken` string — An identifier that can be used in the next call to this operation to return the next set of items in the list.

## Other responses

- `480` — ArgumentException
- `481` — NotFoundException
- `482` — LimitExceededException
- `483` — ServiceAccountException

---

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