# ResourceEventDto

- Module: [Aspire.Hosting](/reference/api/go/aspire.hosting.md)
- Version: `17.0.0`
- Kind: `struct`
- Source: [GitHub](https://github.com/microsoft/aspire/tree/bcfa151cdca6d0a573f22d5d9c23f9c727cb3b2f)

DTO for resource events returned from notification service.

## Definition

```go
type ResourceEventDto struct {
    ResourceName string   `json:"ResourceName"`
    ResourceId   string   `json:"ResourceId"`
    State        *string  `json:"State"`
    StateStyle   *string  `json:"StateStyle"`
    HealthStatus *string  `json:"HealthStatus"`
    ExitCode     *float64 `json:"ExitCode"`
}
```

## Fields

- `ResourceName`: `string` -- The resource name.
- `ResourceId`: `string` -- The unique resource ID.
- `State`: `*string` `optional` -- The current state text.
- `StateStyle`: `*string` `optional` -- The state style (e.g., "success", "warn", "error").
- `HealthStatus`: `*string` `optional` -- The health status of the resource.
- `ExitCode`: `*float64` `optional` -- The exit code if the resource has exited.
