---
title: GKError.Code
framework: gamekit
role: symbol
role_heading: Enumeration
path: gamekit/gkerror/code
---

# GKError.Code

Error codes for the GameKit error domain.

## Declaration

```swift
enum Code
```

## Topics

### Configuration Errors

- [GKError.Code.gameUnrecognized](gamekit/gkerror/code/gameunrecognized.md)
- [GKError.Code.notSupported](gamekit/gkerror/code/notsupported.md)
- [GKError.Code.appUnlisted](gamekit/gkerror/code/appunlisted.md)

### Communication Errors

- [GKError.Code.unknown](gamekit/gkerror/code/unknown.md)
- [GKError.Code.cancelled](gamekit/gkerror/code/cancelled.md)
- [GKError.Code.communicationsFailure](gamekit/gkerror/code/communicationsfailure.md)
- [GKError.Code.invalidPlayer](gamekit/gkerror/code/invalidplayer.md)
- [GKError.Code.invalidParameter](gamekit/gkerror/code/invalidparameter.md)
- [GKError.Code.gameSessionRequestInvalid](gamekit/gkerror/code/gamesessionrequestinvalid.md)
- [GKError.Code.apiNotAvailable](gamekit/gkerror/code/apinotavailable.md)
- [GKError.Code.connectionTimeout](gamekit/gkerror/code/connectiontimeout.md)
- [GKError.Code.apiObsolete](gamekit/gkerror/code/apiobsolete.md)

### Player-Related Errors

- [GKError.Code.userDenied](gamekit/gkerror/code/userdenied.md)
- [GKError.Code.invalidCredentials](gamekit/gkerror/code/invalidcredentials.md)
- [GKError.Code.notAuthenticated](gamekit/gkerror/code/notauthenticated.md)
- [GKError.Code.authenticationInProgress](gamekit/gkerror/code/authenticationinprogress.md)
- [GKError.Code.parentalControlsBlocked](gamekit/gkerror/code/parentalcontrolsblocked.md)
- [GKError.Code.playerStatusExceedsMaximumLength](gamekit/gkerror/code/playerstatusexceedsmaximumlength.md)
- [GKError.Code.playerStatusInvalid](gamekit/gkerror/code/playerstatusinvalid.md)
- [GKError.Code.underage](gamekit/gkerror/code/underage.md)
- [GKError.Code.playerPhotoFailure](gamekit/gkerror/code/playerphotofailure.md)
- [GKError.Code.ubiquityContainerUnavailable](gamekit/gkerror/code/ubiquitycontainerunavailable.md)
- [GKError.Code.notAuthorized](gamekit/gkerror/code/notauthorized.md)
- [GKError.Code.iCloudUnavailable](gamekit/gkerror/code/icloudunavailable.md)
- [GKError.Code.lockdownMode](gamekit/gkerror/code/lockdownmode.md)

### Friend List Errors

- [GKError.Code.friendListDescriptionMissing](gamekit/gkerror/code/friendlistdescriptionmissing.md)
- [GKError.Code.friendListRestricted](gamekit/gkerror/code/friendlistrestricted.md)
- [GKError.Code.friendListDenied](gamekit/gkerror/code/friendlistdenied.md)
- [GKError.Code.friendRequestNotAvailable](gamekit/gkerror/code/friendrequestnotavailable.md)

### Matchmaking Errors

- [GKError.Code.matchRequestInvalid](gamekit/gkerror/code/matchrequestinvalid.md)
- [GKError.Code.unexpectedConnection](gamekit/gkerror/code/unexpectedconnection.md)
- [GKError.Code.invitationsDisabled](gamekit/gkerror/code/invitationsdisabled.md)
- [GKError.Code.matchNotConnected](gamekit/gkerror/code/matchnotconnected.md)
- [GKError.Code.restrictedToAutomatch](gamekit/gkerror/code/restrictedtoautomatch.md)

### Turn-Based Game Errors

- [GKError.Code.turnBasedMatchDataTooLarge](gamekit/gkerror/code/turnbasedmatchdatatoolarge.md)
- [GKError.Code.turnBasedTooManySessions](gamekit/gkerror/code/turnbasedtoomanysessions.md)
- [GKError.Code.turnBasedInvalidParticipant](gamekit/gkerror/code/turnbasedinvalidparticipant.md)
- [GKError.Code.turnBasedInvalidTurn](gamekit/gkerror/code/turnbasedinvalidturn.md)
- [GKError.Code.turnBasedInvalidState](gamekit/gkerror/code/turnbasedinvalidstate.md)

### Leaderboard Errors

- [GKError.Code.scoreNotSet](gamekit/gkerror/code/scorenotset.md)

### Challenges Errors

- [GKError.Code.challengeInvalid](gamekit/gkerror/code/challengeinvalid.md)

### Enumeration Cases

- [GKError.Code.debugMode](gamekit/gkerror/code/debugmode.md)

### Initializers

- [init(rawValue:)](gamekit/gkerror/code/init(rawvalue:).md)

## Relationships

### Conforms To

- [BitwiseCopyable](swift/bitwisecopyable.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [RawRepresentable](swift/rawrepresentable.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### Errors

- [GKError](gamekit/gkerror.md)
- [GKErrorDomain](gamekit/gkerrordomain.md)
