# Method: projects.locations.fetchStaticIps

- [HTTP request](https://docs.cloud.google.com/datastream/docs/reference/rest/v1/projects.locations/fetchStaticIps#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/datastream/docs/reference/rest/v1/projects.locations/fetchStaticIps#body.PATH_PARAMETERS)
- [Query parameters](https://docs.cloud.google.com/datastream/docs/reference/rest/v1/projects.locations/fetchStaticIps#body.QUERY_PARAMETERS)
- [Request body](https://docs.cloud.google.com/datastream/docs/reference/rest/v1/projects.locations/fetchStaticIps#body.request_body)
- [Response body](https://docs.cloud.google.com/datastream/docs/reference/rest/v1/projects.locations/fetchStaticIps#body.response_body)
  - [JSON representation](https://docs.cloud.google.com/datastream/docs/reference/rest/v1/projects.locations/fetchStaticIps#body.FetchStaticIpsResponse.SCHEMA_REPRESENTATION)
- [Authorization scopes](https://docs.cloud.google.com/datastream/docs/reference/rest/v1/projects.locations/fetchStaticIps#body.aspect)
- [IAM Permissions](https://docs.cloud.google.com/datastream/docs/reference/rest/v1/projects.locations/fetchStaticIps#body.aspect_1)
- [Examples](https://docs.cloud.google.com/datastream/docs/reference/rest/v1/projects.locations/fetchStaticIps#examples)
- [Try it!](https://docs.cloud.google.com/datastream/docs/reference/rest/v1/projects.locations/fetchStaticIps#try-it)

The locations.fetchStaticIps API call exposes the static IP addresses used by Datastream.

### HTTP request

`GET https://datastream.googleapis.com/v1/{name}:fetchStaticIps`

### Path parameters

| Parameters ||
|---|---|
| `name` | `string` Required. The resource name for the location for which static IPs should be returned. Must be in the format `projects/*/locations/*`. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `name`: - `datastream.locations.fetchStaticIps` |

### Query parameters

| Parameters ||
|---|---|
| `pageSize` | `integer` Optional. Maximum number of Ips to return, will likely not be specified. |
| `pageToken` | `string` Optional. A page token, received from a previous `ListStaticIps` call. will likely not be specified. |

### Request body

The request body must be empty.

### Response body

Response message for a 'locations.fetchStaticIps' response.

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

| JSON representation |
|---|
| ``` { "staticIps": [ string ], "nextPageToken": string } ``` |

| Fields ||
|---|---|
| `staticIps[]` | `string` list of static ips by account |
| `nextPageToken` | `string` A token that can be sent as `pageToken` to retrieve the next page. If this field is omitted, there are no subsequent pages. |

### 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).

### IAM Permissions

Requires the following [IAM](https://cloud.google.com/iam/docs) permission on the `name` resource:

- `datastream.locations.fetchStaticIps`

For more information, see the [IAM documentation](https://cloud.google.com/iam/docs).