> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Subscribing to resources for real-time messages

> Subscribe PlayFab Lobby and Matchmaking clients to resource topics over the real-time messages SignalR Hub using a connection handle from StartOrRecoverSession.

<Note>
  The REST and SignalR APIs documented here are more complex than the client SDKs. Consider using the [Lobby C++ SDK](/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pflobby/pflobby_members) or [Matchmaking C++ SDK](/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmatchmaking/pfmatchmaking_members) instead, unless those SDKs don't meet your needs.
</Note>

After the client [connects to the SignalR
Hub](/services/playfab/multiplayer/real-time-messages/signalr-hub#connecting-to-the-signalr-hub), and calls
[StartOrRecoverSession](/services/playfab/multiplayer/real-time-messages/server-methods/start-or-recover-session) to receive a
`Connection Handle`, it's ready to subscribe to topics and receive messages.
When subscribing to Lobby or Matchmaking resources, the client will need to
provide the `Connection Handle` that they received when starting the session.
For more information about starting and managing a session, see the [SignalR
Hub](/services/playfab/multiplayer/real-time-messages/signalr-hub) overview.

To manage resource subscriptions with the services that publish messages,
see:

| Service             | Subscription API                                                                                                                               | Unsubscription API                                                                                                                                     |
| ------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Lobby service       | [SubscribeToLobbyResource](https://learn.microsoft.com/en-us/rest/api/playfab/multiplayer/lobby/subscribe-to-lobby-resource)                   | [UnsubscribeFromLobbyResource](https://learn.microsoft.com/en-us/rest/api/playfab/multiplayer/lobby/unsubscribe-from-lobby-resource)                   |
| Matchmaking service | [SubscribeToMatchmakingResource](https://learn.microsoft.com/en-us/rest/api/playfab/multiplayer/matchmaking/subscribe-to-matchmaking-resource) | [UnsubscribeFromMatchmakingResource](https://learn.microsoft.com/en-us/rest/api/playfab/multiplayer/matchmaking/unsubscribe-from-matchmaking-resource) |

## See also

* [Real-time messages SignalR Hub](/services/playfab/multiplayer/real-time-messages/signalr-hub)
* [Real-time messages for Lobby and Matchmaking APIs](/services/playfab/multiplayer/real-time-messages/overview)


## Related topics

- [Real-time messages SignalR Hub](/services/playfab/multiplayer/real-time-messages/signalr-hub.md)
- [Real-time messages for Lobby and Matchmaking APIs](/services/playfab/multiplayer/real-time-messages/overview.md)
- [SubscriptionChangeMessage real-time messages type](/services/playfab/multiplayer/real-time-messages/types/subscription-change-message.md)
- [Message real-time messages type](/services/playfab/multiplayer/real-time-messages/types/message.md)
- [StartOrRecoverSessionResponse real-time messages type](/services/playfab/multiplayer/real-time-messages/types/start-or-recover-session-response.md)
