# Google Cloud Shell V1 Client - Class AuthorizeEnvironmentRequest (2.2.0)

2.2.0 (latest) 2.1.2 2.0.5 1.3.5 1.2.2 1.1.1 1.0.4 Reference documentation and code samples for the Google Cloud Shell V1 Client class AuthorizeEnvironmentRequest.

Request message for
[AuthorizeEnvironment](https://docs.cloud.google.com/php/docs/reference/cloud-shell/latest/V1.Client.CloudShellServiceClient#_Google_Cloud_Shell_V1_Client_CloudShellServiceClient__authorizeEnvironment__).

Generated from protobuf message `google.cloud.shell.v1.AuthorizeEnvironmentRequest`

## Namespace

Google \\ Cloud \\ Shell \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` Name of the resource that should receive the credentials, for example `users/me/environments/default` or `users/someone\@example.com/environments/default`. |
| `↳ access_token` | `string` The OAuth access token that should be sent to the environment. |
| `↳ id_token` | `string` The OAuth ID token that should be sent to the environment. |
| `↳ expire_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` The time when the credentials expire. If not set, defaults to one hour from when the server received the request. |

### getName

Name of the resource that should receive the credentials, for example
`users/me/environments/default` or
`users/someone\@example.com/environments/default`.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setName

Name of the resource that should receive the credentials, for example
`users/me/environments/default` or
`users/someone\@example.com/environments/default`.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAccessToken

The OAuth access token that should be sent to the environment.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setAccessToken

The OAuth access token that should be sent to the environment.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getIdToken

The OAuth ID token that should be sent to the environment.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setIdToken

The OAuth ID token that should be sent to the environment.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getExpireTime

The time when the credentials expire. If not set, defaults to one hour from
when the server received the request.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp|null` |   |

### hasExpireTime

### clearExpireTime

### setExpireTime

The time when the credentials expire. If not set, defaults to one hour from
when the server received the request.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |