# Method: projects.configs.variables.list

- [HTTP request](https://docs.cloud.google.com/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs.variables/list#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs.variables/list#body.PATH_PARAMETERS)
- [Query parameters](https://docs.cloud.google.com/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs.variables/list#body.QUERY_PARAMETERS)
- [Request body](https://docs.cloud.google.com/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs.variables/list#body.request_body)
- [Response body](https://docs.cloud.google.com/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs.variables/list#body.response_body)
  - [JSON representation](https://docs.cloud.google.com/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs.variables/list#body.ListVariablesResponse.SCHEMA_REPRESENTATION)
- [Authorization Scopes](https://docs.cloud.google.com/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs.variables/list#body.aspect)
- [Try it!](https://docs.cloud.google.com/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs.variables/list#try-it)

Lists variables within given a configuration, matching any provided filters. This only lists variable names, not the values, unless `returnValues` is true, in which case only variables that user has IAM permission to variables.get will be returned.

### HTTP request

`GET https://runtimeconfig.googleapis.com/v1beta1/{parent=projects/*/configs/*}/variables`

The URL uses [gRPC Transcoding](https://github.com/googleapis/googleapis/blob/master/google/api/http.proto) syntax.

### Path parameters

| Parameters ||
|---|---|
| `parent` | `string` The path to the RuntimeConfig resource for which you want to list variables. The configuration must exist beforehand; the path must be in the format: `projects/[PROJECT_ID]/configs/[CONFIG_NAME]` Authorization requires the following [Google IAM](https://cloud.google.com/iam) permission on the specified resource `parent`: - `runtimeconfig.variables.list` <br /> |

### Query parameters

| Parameters ||
|---|---|
| `filter` | `string` Filters variables by matching the specified filter. For example: `projects/example-project/config/[CONFIG_NAME]/variables/example-variable`. <br /> |
| `pageSize` | `number` Specifies the number of results to return per page. If there are fewer elements than the specified number, returns all elements. |
| `pageToken` | `string` Specifies a page token to use. Set `pageToken` to a `nextPageToken` returned by a previous list request to get the next page of results. |
| `returnValues` | `boolean` The flag indicates whether the user wants to return values of variables. If true, then only those variables that user has IAM variables.get permission will be returned along with their values. |

### Request body

The request body must be empty.

### Response body

If successful, the response body contains data with the following structure:
Response for the `variables.list()` method.

| JSON representation ||
|---|---|
| ``` { "variables": [ { object(`https://docs.cloud.google.com/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs.variables#Variable`) } ], "nextPageToken": string } ``` |

| Fields ||
|---|---|
| `variables[]` | ``object(`https://docs.cloud.google.com/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs.variables#Variable`)`` A list of variables and their values. The order of returned variable objects is arbitrary. |
| `nextPageToken` | `string` This token allows you to get the next page of results for list requests. If the number of results is larger than `pageSize`, use the `nextPageToken` as a value for the query parameter `pageToken` in the next list request. Subsequent list requests will have their own `nextPageToken` to continue paging through the results |

### Authorization Scopes

Requires one of the following OAuth scopes:

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

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

## Try it!