<!--
{
  "availability" : [
    "iOS: 26.0.0 -",
    "iPadOS: 26.0.0 -",
    "macCatalyst: -",
    "macOS: 26.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "IdentityDocumentServices",
  "identifier" : "/documentation/IdentityDocumentServices/IdentityDocumentPresentmentError/Code-swift.enum",
  "metadataVersion" : "0.1.0",
  "role" : "Enumeration",
  "symbol" : {
    "kind" : "Enumeration",
    "modules" : [
      "IdentityDocumentServices"
    ],
    "preciseIdentifier" : "s:24IdentityDocumentServices0aB16PresentmentErrorV4CodeO"
  },
  "title" : "IdentityDocumentPresentmentError.Code"
}
-->

# IdentityDocumentPresentmentError.Code

Error codes for identity document web presentment errors.

```
enum Code
```

## Topics

### Operators

[`static func ~= (IdentityDocumentPresentmentError.Code, any Error) -> Bool`](/documentation/IdentityDocumentServices/IdentityDocumentPresentmentError/Code-swift.enum/~=(_:_:))

A pattern-matching operator for matching error codes directly.
This operator enables traditional switch/case pattern matching on error codes.

### Enumeration Cases

[`case cancelled`](/documentation/IdentityDocumentServices/IdentityDocumentPresentmentError/Code-swift.enum/cancelled)

An error that indicates that the current request was canceled.

[`case invalidRequest`](/documentation/IdentityDocumentServices/IdentityDocumentPresentmentError/Code-swift.enum/invalidRequest)

An error that indicates an invalid request.

[`case notEntitled`](/documentation/IdentityDocumentServices/IdentityDocumentPresentmentError/Code-swift.enum/notEntitled)

An error that indicates the caller isn’t entitled.

[`case requestInProgress`](/documentation/IdentityDocumentServices/IdentityDocumentPresentmentError/Code-swift.enum/requestInProgress)

An error that indicates a request is in progress.

[`case unknown`](/documentation/IdentityDocumentServices/IdentityDocumentPresentmentError/Code-swift.enum/unknown)

An error that indicates that the framework encountered an unknown problem.

## Relationships

### Conforms To

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

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

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

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

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

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

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

---

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)