# Method: projects.locations.datasets.list

- [HTTP request](https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets/list#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets/list#body.PATH_PARAMETERS)
- [Query parameters](https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets/list#body.QUERY_PARAMETERS)
- [Request body](https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets/list#body.request_body)
- [Response body](https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets/list#body.response_body)
  - [JSON representation](https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets/list#body.ListDatasetsResponse.SCHEMA_REPRESENTATION)
- [Authorization Scopes](https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets/list#body.aspect)

Lists datasets in a project.

### HTTP request

`GET https://automl.googleapis.com/v1beta1/{parent}/datasets`

### Path parameters

| Parameters ||
|---|---|
| `parent` | `string` The resource name of the project from which to list datasets. Authorization requires the following [Google IAM](https://cloud.google.com/iam) permission on the specified resource `parent`: - `automl.datasets.list` <br /> |

### Query parameters

| Parameters ||
|---|---|
| `filter` | `string` An expression for filtering the results of the request. - `dataset_metadata` - for existence of the case. An example of using the filter is: - `translationDatasetMetadata:*` --\> The dataset has translationDatasetMetadata. <br /> |
| `pageSize` | `number` Requested page size. Server may return fewer results than requested. If unspecified, server will pick a default size. |
| `pageToken` | `string` A token identifying a page of results for the server to return Typically obtained via `https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets/list#body.ListDatasetsResponse.FIELDS.next_page_token` of the previous `https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets/list#google.cloud.automl.v1beta1.AutoMl.ListDatasets` call. |

### Request body

The request body must be empty.

### Response body

If successful, the response body contains data with the following structure:
Response message for `https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets/list#google.cloud.automl.v1beta1.AutoMl.ListDatasets`.

| JSON representation ||
|---|---|
| ``` { "datasets": [ { object(`https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets#Dataset`) } ], "nextPageToken": string } ``` |

| Fields ||
|---|---|
| `datasets[]` | ``object(`https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets#Dataset`)`` The datasets read. |
| `nextPageToken` | `string` A token to retrieve next page of results. Pass to `https://docs.cloud.google.com/translate/automl/docs/reference/rest/v1beta1/projects.locations.datasets/list#body.QUERY_PARAMETERS.page_token` to obtain that page. |

### Authorization Scopes

Requires the following OAuth scope:

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

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