# Method: projects.locations.inputs.preview

- [HTTP request](https://docs.cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.inputs/preview#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.inputs/preview#body.PATH_PARAMETERS)
- [Request body](https://docs.cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.inputs/preview#body.request_body)
- [Response body](https://docs.cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.inputs/preview#body.response_body)
  - [JSON representation](https://docs.cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.inputs/preview#body.PreviewInputResponse.SCHEMA_REPRESENTATION)
- [Authorization scopes](https://docs.cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.inputs/preview#body.aspect)
- [IAM Permissions](https://docs.cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.inputs/preview#body.aspect_1)

Preview the streaming content of the specified input.

### HTTP request

`POST https://livestream.googleapis.com/v1/{name=projects/*/locations/*/inputs/*}:preview`

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

### Path parameters

| Parameters ||
|---|---|
| `name` | `string` Required. The name of the input resource, in the form of: `projects/{project}/locations/{location}/inputs/{inputId}`. |

### Request body

The request body must be empty.

### Response body

Response message for "LivestreamService.PreviewInput"

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

| JSON representation |
|---|
| ``` { "uri": string, "bearerToken": string } ``` |

| Fields ||
|---|---|
| `uri` | `string` URI to display the preview content. |
| `bearerToken` | `string` A bearer token used to authenticate connections that display the preview content. The token expires after one hour. For HTTP connections, this token should be included as a bearer token inside the Authorization header. |

### 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:

- `livestream.inputs.preview`

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