# List Instance

Endpoint for listing instances, with the option of filtering for a specific infrastructure.

Endpoint: GET /api/instances
Version: 1.0
Security: x-api-key

## Query parameters:

  - `infrastructureID` (string)
    ID of an Infrastructure to filter by

  - `orgIdentifier` (string)
    Org is the organization identifier.

  - `projectIdentifier` (string)
    Project is the project identifier.

  - `offset` (integer)
    Offset for pagination

  - `limit` (integer)
    Limit for pagination

  - `desc` (boolean)
    Order by descending order

## Header parameters:

  - `Harness-Account` (string, required)
    Account is the internal customer account ID.

## Response 200 fields (application/json):

  - `instances` (array)

  - `instances.appliedRevision` (integer)
    Revision of the instance that is currently active

  - `instances.backend` (string)

  - `instances.createdAt` (string)

  - `instances.currentState` (object)

  - `instances.currentState.state` (string, required)
    Enum: "unknown", "inactive", "instantiated", "running", "paused"

  - `instances.id` (string)

  - `instances.infrastructureId` (string)

  - `instances.message` (string)

  - `instances.outputs` (object)

  - `instances.progress` (object)

  - `instances.progress.progress` (string, required)
    Enum: "unknown", "pending", "running", "done", "failed", "aborted", "skipped"

  - `instances.step` (object)

  - `instances.step.step` (string, required)
    Enum: "unknown", "apply", "destroy", "create", "delete", "pause", "resume"

  - `instances.targetRevision` (integer)
    Target revision of the instance

  - `instances.targetState` (object)

  - `instances.updatedAt` (string)

  - `instances.url` (string)

  - `total` (integer)

## Response 400 fields (application/json):

  - `code` (string)

  - `details` (object)

  - `message` (string, required)

  - `name` (string, required)


