# Cloud Workstations v1 API - Class Workstation (1.5.0)

1.5.0 (latest) 1.4.0 1.3.0 1.2.0 1.1.0 1.0.0

    public sealed class Workstation : IMessage<Workstation>, IEquatable<Workstation>, IDeepCloneable<Workstation>, IBufferMessage, IMessage

Reference documentation and code samples for the Cloud Workstations v1 API class Workstation.

A single instance of a developer workstation with its own persistent storage.

## Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) \> Workstation

## Implements

[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[Workstation](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstation), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[Workstation](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstation), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[Workstation](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstation), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html)

## Inherited Members

[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

## Namespace

[Google.Cloud.Workstations.V1](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1)

## Assembly

Google.Cloud.Workstations.V1.dll

## Constructors

### Workstation()

    public Workstation()

### Workstation(Workstation)

    public Workstation(Workstation other)

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `other` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstation` |

## Properties

### Annotations

    public MapField<string, string> Annotations { get; }

Optional. Client-specified annotations.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.Collections.MapField-2.htmlhttps://learn.microsoft.com/dotnet/api/system.stringhttps://learn.microsoft.com/dotnet/api/system.string` |   |

### CreateTime

    public Timestamp CreateTime { get; set; }

Output only. Time when this workstation was created.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Timestamp.html` |   |

### DeleteTime

    public Timestamp DeleteTime { get; set; }

Output only. Time when this workstation was soft-deleted.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Timestamp.html` |   |

### DisplayName

    public string DisplayName { get; set; }

Optional. Human-readable name for this workstation.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### Env

    public MapField<string, string> Env { get; }

Optional. Environment variables passed to the workstation container's
entrypoint.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.Collections.MapField-2.htmlhttps://learn.microsoft.com/dotnet/api/system.stringhttps://learn.microsoft.com/dotnet/api/system.string` |   |

### Etag

    public string Etag { get; set; }

Optional. Checksum computed by the server. May be sent on update and delete
requests to make sure that the client has an up-to-date value before
proceeding.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### Host

    public string Host { get; set; }

Output only. Host to which clients can send HTTPS traffic that will be
received by the workstation. Authorized traffic will be received to the
workstation as HTTP on port 80. To send traffic to a different port,
clients may prefix the host with the destination port in the format
`{port}-{host}`.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### KmsKey

    public string KmsKey { get; set; }

Output only. The name of the Google Cloud KMS encryption key used to
encrypt this workstation. The KMS key can only be configured in the
WorkstationConfig. The expected format is
`projects/*/locations/*/keyRings/*/cryptoKeys/*`.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### Labels

    public MapField<string, string> Labels { get; }

Optional.
[Labels](https://cloud.google.com/workstations/docs/label-resources) that
are applied to the workstation and that are also propagated to the
underlying Compute Engine resources.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.Collections.MapField-2.htmlhttps://learn.microsoft.com/dotnet/api/system.stringhttps://learn.microsoft.com/dotnet/api/system.string` |   |

### Name

    public string Name { get; set; }

Identifier. Full name of this workstation.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### PersistentDirectories

    public RepeatedField<Workstation.Types.WorkstationPersistentDirectory> PersistentDirectories { get; }

Optional. Directories to persist across workstation sessions.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.Collections.RepeatedField-1.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstationhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstation.Typeshttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstation.Types.WorkstationPersistentDirectory` |   |

### Reconciling

    public bool Reconciling { get; set; }

Output only. Indicates whether this workstation is currently being updated
to match its intended state.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### RuntimeHost

    public Workstation.Types.RuntimeHost RuntimeHost { get; set; }

Optional. Output only. Runtime host for the workstation when in
STATE_RUNNING.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstationhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstation.Typeshttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstation.Types.RuntimeHost` |   |

### SourceWorkstation

    public string SourceWorkstation { get; set; }

Optional. The source workstation from which this workstation's persistent
directories were cloned on creation.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### StartTime

    public Timestamp StartTime { get; set; }

Output only. Time when this workstation was most recently successfully
started, regardless of the workstation's initial state.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Timestamp.html` |   |

### State

    public Workstation.Types.State State { get; set; }

Output only. Current state of the workstation.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstationhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstation.Typeshttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstation.Types.State` |   |

### Uid

    public string Uid { get; set; }

Output only. A system-assigned unique identifier for this workstation.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### UpdateTime

    public Timestamp UpdateTime { get; set; }

Output only. Time when this workstation was most recently updated.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Timestamp.html` |   |

### WorkstationName

    public WorkstationName WorkstationName { get; set; }

[WorkstationName](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.WorkstationName)-typed view over the [Name](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.Workstation#Google_Cloud_Workstations_V1_Workstation_Name) resource name property.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workstations.V1/latest/Google.Cloud.Workstations.V1.WorkstationName` |   |