<!--
{
  "availability" : [
    "iOS: 12.0.0 -",
    "iPadOS: 12.0.0 -",
    "macCatalyst: 12.0.0 -",
    "macOS: 10.15.0 -",
    "tvOS: 16.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 6.2.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AuthenticationServices",
  "identifier" : "/documentation/AuthenticationServices/ASWebAuthenticationSessionError/Code",
  "metadataVersion" : "0.1.0",
  "role" : "Enumeration",
  "symbol" : {
    "kind" : "Enumeration",
    "modules" : [
      "Authentication Services"
    ],
    "preciseIdentifier" : "c:@E@ASWebAuthenticationSessionErrorCode"
  },
  "title" : "ASWebAuthenticationSessionError.Code"
}
-->

# ASWebAuthenticationSessionError.Code

The error code for a web authentication session error.

```
enum Code
```

## Topics

### Codes

[`case canceledLogin`](/documentation/AuthenticationServices/ASWebAuthenticationSessionError/Code/canceledLogin)

The login has been canceled.

[`case presentationContextNotProvided`](/documentation/AuthenticationServices/ASWebAuthenticationSessionError/Code/presentationContextNotProvided)

A context wasn’t provided.

[`case presentationContextInvalid`](/documentation/AuthenticationServices/ASWebAuthenticationSessionError/Code/presentationContextInvalid)

The context was invalid.

### Initializers

[`init?(rawValue: Int)`](/documentation/AuthenticationServices/ASWebAuthenticationSessionError/Code/init(rawValue:))

## Relationships

### Conforms To

[`Equatable`](/documentation/Swift/Equatable)

[`Sendable`](/documentation/Swift/Sendable)

[`RawRepresentable`](/documentation/Swift/RawRepresentable)

[`Hashable`](/documentation/Swift/Hashable)

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

[`BitwiseCopyable`](/documentation/Swift/BitwiseCopyable)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)