> ## 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.

# PlayFabMultiplayer.JoinArrangedLobby

> PlayFabMultiplayer.JoinArrangedLobby

## Method (1 of 2)

Joins a lobby using an arrangement string provided by another service, such as matchmaking. If no one has joined the lobby yet, the lobby is initialized using the configuration parameters.

```csharp theme={null}
public static Lobby JoinArrangedLobby(PFEntityKey newMember, string arrangementString, 
    LobbyArrangedJoinConfiguration config)
```

| parameter         | description                                                                                      |
| ----------------- | ------------------------------------------------------------------------------------------------ |
| newMember         | The local PlayFab entity joining the lobby.                                                      |
| arrangementString | The arrangement string used by the entity to join the lobby.                                     |
| config            | The initial configuration data used to initialize the lobby, if no one has joined the lobby yet. |

## Return Value (1 of 2)

Output lobby object which can be used to queue operations for immediate execution of this operation

## Remarks (1 of 2)

This is an asynchronous operation. Upon successful completion, the title will be provided a [`OnLobbyMemberAdded`](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PlayFabMultiplayer/OnLobbyMemberAdded) followed by a [`OnLobbyJoinArrangedLobbyCompleted`](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PlayFabMultiplayer/OnLobbyJoinArrangedLobbyCompleted) with the `OnLobbyJoinArrangedLobbyCompleted.result` field set to [`Success`](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/LobbyError/Success). Upon a failed completion, the title will be provided a [`OnLobbyJoinArrangedLobbyCompleted`](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PlayFabMultiplayer/OnLobbyJoinArrangedLobbyCompleted) with the with the `result` field set to a failure.

When using matchmaking through this library, the [`LobbyArrangementString`](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/MatchmakingMatchDetails/LobbyArrangementString) can be used with this method to join a lobby with all of the users that have been matched together.

***

## Method (2 of 2)

Joins a lobby using an arrangement string provided by another service, such as matchmaking. If no one has joined the lobby yet, the lobby is initialized using the configuration parameters.

```csharp theme={null}
public static Lobby JoinArrangedLobby(PlayFabAuthenticationContext newMember, 
    string arrangementString, LobbyArrangedJoinConfiguration config)
```

| parameter         | description                                                                                      |
| ----------------- | ------------------------------------------------------------------------------------------------ |
| newMember         | The local PlayFab entity joining the lobby.                                                      |
| arrangementString | The arrangement string used by the entity to join the lobby.                                     |
| config            | The initial configuration data used to initialize the lobby, if no one has joined the lobby yet. |

## Return Value (2 of 2)

Output lobby object which can be used to queue operations for immediate execution of this operation

## Remarks (2 of 2)

This is an asynchronous operation. Upon successful completion, the title will be provided a [`OnLobbyMemberAdded`](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PlayFabMultiplayer/OnLobbyMemberAdded) followed by a [`OnLobbyJoinArrangedLobbyCompleted`](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PlayFabMultiplayer/OnLobbyJoinArrangedLobbyCompleted) with the `OnLobbyJoinArrangedLobbyCompleted.result` field set to [`Success`](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/LobbyError/Success). Upon a failed completion, the title will be provided a [`OnLobbyJoinArrangedLobbyCompleted`](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PlayFabMultiplayer/OnLobbyJoinArrangedLobbyCompleted) with the with the `result` field set to a failure.

When using matchmaking through this library, the [`LobbyArrangementString`](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/MatchmakingMatchDetails/LobbyArrangementString) can be used with this method to join a lobby with all of the users that have been matched together.

## See Also

* class [Lobby](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/Lobby/overview)
* class [PFEntityKey](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PFEntityKey/overview)
* class [LobbyArrangedJoinConfiguration](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/LobbyArrangedJoinConfiguration/overview)
* class [PlayFabMultiplayer](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PlayFabMultiplayer/overview)
* namespace [PlayFab.Multiplayer](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference)


## Related topics

- [PlayFabMultiplayer.OnLobbyJoinArrangedLobbyCompleted](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PlayFabMultiplayer/OnLobbyJoinArrangedLobbyCompleted.md)
- [PlayFabMultiplayer.JoinLobby](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PlayFabMultiplayer/JoinLobby.md)
- [PlayFabMultiplayer.OnLobbyJoinCompleted](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PlayFabMultiplayer/OnLobbyJoinCompleted.md)
- [PlayFabMultiplayer.CreateAndJoinLobby](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PlayFabMultiplayer/CreateAndJoinLobby.md)
- [PlayFabMultiplayer.OnLobbyCreateAndJoinCompleted](/services/playfab/multiplayer/lobby/unity-multiplayer-api-reference/PlayFab.Multiplayer/PlayFabMultiplayer/OnLobbyCreateAndJoinCompleted.md)
