# ResourceReadyEvent Constructors

- Package: [Aspire.Hosting](/reference/api/csharp/aspire.hosting.md)
- Type: [ResourceReadyEvent](/reference/api/csharp/aspire.hosting/resourcereadyevent.md)
- Kind: `Constructors`
- Members: `1`

Event that is raised when a resource initially transitions to a ready state.

## ResourceReadyEvent(IResource, IServiceProvider)

- Name: `Constructor(IResource, IServiceProvider)`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/a3766e994fd2cba86c8ac60b8a80268cab7e6383/src/Aspire.Hosting/ApplicationModel/ResourceReadyEvent.cs#L17)

Event that is raised when a resource initially transitions to a ready state.

```csharp
public class ResourceReadyEvent
{
    public ResourceReadyEvent(
        IResource resource,
        IServiceProvider services)
    {
        // ...
    }
}
```

## Parameters

- `resource` ([IResource](/reference/api/csharp/aspire.hosting/iresource.md))
  The resource that is in a ready state.
- `services` (`IServiceProvider`)
  The service provider for the app host.

## Remarks

This event is only fired the first time a resource transitions to a ready state after starting.
