# CustomResourceSnapshot Properties

- Package: [Aspire.Hosting](/reference/api/csharp/aspire.hosting.md)
- Type: [CustomResourceSnapshot](/reference/api/csharp/aspire.hosting/customresourcesnapshot.md)
- Kind: `Properties`
- Members: `17`

An immutable snapshot of the state of a resource.

## Commands

- Name: `Commands`
- Modifiers: `get; init`
- Returns: `ImmutableArray<ResourceCommandSnapshot>`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The commands available in the dashboard for this resource.

```csharp
public ImmutableArray<ResourceCommandSnapshot> Commands { get; init; }
```

## CreationTimeStamp

- Name: `CreationTimeStamp`
- Modifiers: `nullable` `get; init`
- Returns: `DateTime?`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The creation timestamp of the resource.

```csharp
public DateTime? CreationTimeStamp { get; init; }
```

## EnvironmentVariables

- Name: `EnvironmentVariables`
- Modifiers: `get; init`
- Returns: `ImmutableArray<EnvironmentVariableSnapshot>`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The environment variables that should show up in the dashboard for this resource.

```csharp
public ImmutableArray<EnvironmentVariableSnapshot> EnvironmentVariables { get; init; }
```

## ExitCode

- Name: `ExitCode`
- Modifiers: `nullable` `get; init`
- Returns: `int?`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The exit code of the resource.

```csharp
public int? ExitCode { get; init; }
```

## HealthReports

- Name: `HealthReports`
- Modifiers: `get`
- Returns: `ImmutableArray<HealthReportSnapshot>`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The health reports for this resource.

```csharp
public ImmutableArray<HealthReportSnapshot> HealthReports { get; }
```

## Remarks

May be zero or more. If there are no health reports, the resource is considered healthy so long as no heath checks are registered for the resource.

## HealthStatus

- Name: `HealthStatus`
- Modifiers: `nullable` `get`
- Returns: `HealthStatus??`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

Gets the health status of the resource.

```csharp
public HealthStatus?? HealthStatus { get; }
```

## Remarks

This value is derived from [CustomResourceSnapshot.HealthReports](/reference/api/csharp/aspire.hosting/customresourcesnapshot/properties.md#healthreports).

## IconName

- Name: `IconName`
- Modifiers: `nullable` `get; init`
- Returns: `string?`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The custom icon name for the resource. This should be a valid FluentUI icon name. If not specified, the dashboard will use default icons based on the resource type.

```csharp
public string? IconName { get; init; }
```

## IconVariant

- Name: `IconVariant`
- Modifiers: `nullable` `get; init`
- Returns: [IconVariant?](/reference/api/csharp/aspire.hosting/iconvariant.md)
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The custom icon variant for the resource.

```csharp
public IconVariant? IconVariant { get; init; }
```

## IsHidden

- Name: `IsHidden`
- Modifiers: `get; init`
- Returns: `bool`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

Whether this resource should be hidden in UI.

```csharp
public bool IsHidden { get; init; }
```

## Properties

- Name: `Properties`
- Modifiers: `get; init`
- Returns: `ImmutableArray<ResourcePropertySnapshot>`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The properties that should show up in the dashboard for this resource.

```csharp
public ImmutableArray<ResourcePropertySnapshot> Properties { get; init; }
```

## Relationships

- Name: `Relationships`
- Modifiers: `get; init`
- Returns: `ImmutableArray<RelationshipSnapshot>`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The relationships to other resources.

```csharp
public ImmutableArray<RelationshipSnapshot> Relationships { get; init; }
```

## ResourceType

- Name: `ResourceType`
- Modifiers: `get; init`
- Returns: `string`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The type of the resource.

```csharp
public string ResourceType { get; init; }
```

## StartTimeStamp

- Name: `StartTimeStamp`
- Modifiers: `nullable` `get; init`
- Returns: `DateTime?`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The start timestamp of the resource.

```csharp
public DateTime? StartTimeStamp { get; init; }
```

## State

- Name: `State`
- Modifiers: `nullable` `get; init`
- Returns: [ResourceStateSnapshot?](/reference/api/csharp/aspire.hosting/resourcestatesnapshot.md)
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

Represents the state of the resource.

```csharp
public ResourceStateSnapshot? State { get; init; }
```

## StopTimeStamp

- Name: `StopTimeStamp`
- Modifiers: `nullable` `get; init`
- Returns: `DateTime?`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The stop timestamp of the resource.

```csharp
public DateTime? StopTimeStamp { get; init; }
```

## Urls

- Name: `Urls`
- Modifiers: `get; init`
- Returns: `ImmutableArray<UrlSnapshot>`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The URLs that should show up in the dashboard for this resource.

```csharp
public ImmutableArray<UrlSnapshot> Urls { get; init; }
```

## Volumes

- Name: `Volumes`
- Modifiers: `get; init`
- Returns: `ImmutableArray<VolumeSnapshot>`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs)

The volumes that should show up in the dashboard for this resource.

```csharp
public ImmutableArray<VolumeSnapshot> Volumes { get; init; }
```
