# Method: projects.locations.machines.list

- [HTTP request](https://docs.cloud.google.com/distributed-cloud/connected/latest/docs/reference/container/rest/v1/projects.locations.machines/list#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/distributed-cloud/connected/latest/docs/reference/container/rest/v1/projects.locations.machines/list#body.PATH_PARAMETERS)
- [Query parameters](https://docs.cloud.google.com/distributed-cloud/connected/latest/docs/reference/container/rest/v1/projects.locations.machines/list#body.QUERY_PARAMETERS)
- [Request body](https://docs.cloud.google.com/distributed-cloud/connected/latest/docs/reference/container/rest/v1/projects.locations.machines/list#body.request_body)
- [Response body](https://docs.cloud.google.com/distributed-cloud/connected/latest/docs/reference/container/rest/v1/projects.locations.machines/list#body.response_body)
  - [JSON representation](https://docs.cloud.google.com/distributed-cloud/connected/latest/docs/reference/container/rest/v1/projects.locations.machines/list#body.ListMachinesResponse.SCHEMA_REPRESENTATION)
- [Authorization scopes](https://docs.cloud.google.com/distributed-cloud/connected/latest/docs/reference/container/rest/v1/projects.locations.machines/list#body.aspect)
- [Try it!](https://docs.cloud.google.com/distributed-cloud/connected/latest/docs/reference/container/rest/v1/projects.locations.machines/list#try-it)

Lists Machines in a given project and location.

### HTTP request

`GET https://edgecontainer.googleapis.com/v1/{parent=projects/*/locations/*}/machines`

The URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.

### Path parameters

| Parameters ||
|---|---|
| `parent` | `string` Required. The parent site, which owns this collection of machines. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `parent`: - `edgecontainer.machines.list` |

### Query parameters

| Parameters ||
|---|---|
| `pageSize` | `integer` The maximum number of resources to list. |
| `pageToken` | `string` A page token received from previous list request. |
| `filter` | `string` Only resources matching this filter will be listed. |
| `orderBy` | `string` Specifies the order in which machines will be listed. In accordance with AIP-132, the value should be a comma-separated list of fields. A " desc" may be appended to a field to specify descending order. Supported fields: \* `name` (default) : Canonical resource name of the machine. Example: "name desc". |

### Request body

The request body must be empty.

### Response body

List of machines in a site.

If successful, the response body contains data with the following structure:

| JSON representation |
|---|
| ``` { "machines": [ { object (`https://docs.cloud.google.com/distributed-cloud/connected/latest/docs/reference/container/rest/v1/projects.locations.machines#Machine`) } ], "nextPageToken": string, "unreachable": [ string ] } ``` |

| Fields ||
|---|---|
| `machines[]` | ``object (`https://docs.cloud.google.com/distributed-cloud/connected/latest/docs/reference/container/rest/v1/projects.locations.machines#Machine`)`` Machines in the site. |
| `nextPageToken` | `string` A token to retrieve next page of results. |
| `unreachable[]` | `string` Locations that could not be reached. |

### Authorization scopes

Requires the following OAuth scope:

- `https://www.googleapis.com/auth/cloud-platform`

For more information, see the [Authentication Overview](https://docs.cloud.google.com/docs/authentication#authorization-gcp).