---
title: GKSessionDelegate
framework: gamekit
role: symbol
role_heading: Protocol
path: gamekit/gksessiondelegate
---

# GKSessionDelegate

An object implements the GKSessionDelegate protocol to control the behavior of a GKSession object. The delegate is called when other visible peers change their state relative to the session. It is also called to determine whether another peer is allowed to connect to the session.

## Declaration

```swift
protocol GKSessionDelegate : NSObjectProtocol
```

## Topics

### Observing Changes to Peers

- [session(_:peer:didChange:)](gamekit/gksessiondelegate/session(_:peer:didchange:).md)

### Connection Requests from Other Peers

- [session(_:didReceiveConnectionRequestFromPeer:)](gamekit/gksessiondelegate/session(_:didreceiveconnectionrequestfrompeer:).md)

### Connection Errors

- [session(_:connectionWithPeerFailed:withError:)](gamekit/gksessiondelegate/session(_:connectionwithpeerfailed:witherror:).md)
- [session(_:didFailWithError:)](gamekit/gksessiondelegate/session(_:didfailwitherror:).md)

## Relationships

### Inherits From

- [NSObjectProtocol](objectivec/nsobjectprotocol.md)

## See Also

### Deprecated protocols

- [GKAchievementViewControllerDelegate](gamekit/gkachievementviewcontrollerdelegate.md)
- [GKChallengeEventHandlerDelegate](gamekit/gkchallengeeventhandlerdelegate.md)
- [GKChallengesViewControllerDelegate](gamekit/gkchallengesviewcontrollerdelegate.md)
- [GKChallengeListener](gamekit/gkchallengelistener.md)
- [GKFriendRequestComposeViewControllerDelegate](gamekit/gkfriendrequestcomposeviewcontrollerdelegate.md)
- [GKGameSessionEventListener](gamekit/gkgamesessioneventlistener.md)
- [GKLeaderboardViewControllerDelegate](gamekit/gkleaderboardviewcontrollerdelegate.md)
- [GKPeerPickerControllerDelegate](gamekit/gkpeerpickercontrollerdelegate.md)
- [GKTurnBasedEventHandlerDelegate](gamekit/gkturnbasedeventhandlerdelegate.md)
- [GKVoiceChatClient](gamekit/gkvoicechatclient.md)
