# IStreamSubscriptionObserver Methods

[Type overview](/orleans/docs/api/csharp/microsoft.orleans.streaming/orleans.streams.core.istreamsubscriptionobserver/)

## OnSubscribed(IStreamSubscriptionHandleFactory) {#onsubscribed-orleans-streams-core-istreamsubscriptionhandlefactory-81ff0baf}

[Dedicated page](/orleans/docs/api/csharp/microsoft.orleans.streaming/orleans.streams.core.istreamsubscriptionobserver/methods/onsubscribed-orleans-streams-core-istreamsubscriptionhandlefactory-81ff0baf/)

```csharp
public abstract Task OnSubscribed(IStreamSubscriptionHandleFactory handleFactory)
```

Called when this grain receives a message for a stream which it has not yet explicitly subscribed to or resumed.

### Parameters

- `handleFactory` (`IStreamSubscriptionHandleFactory`): The handle factory.

### Returns

A `System.Threading.Tasks.Task` representing the operation.
