<!--
{
  "availability" : [
    "iOS: 5.0.0 -",
    "iPadOS: 5.0.0 -",
    "macCatalyst: 13.0.0 -",
    "macOS: 10.8.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Accounts",
  "identifier" : "/documentation/Accounts/ACErrorCode",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "Accounts"
    ],
    "preciseIdentifier" : "c:@E@ACErrorCode"
  },
  "title" : "ACErrorCode"
}
-->

# ACErrorCode

Codes for errors that may occur.

```
struct ACErrorCode
```

## Topics

### Errors

[`ACErrorUnknown`](/documentation/Accounts/ACErrorUnknown)

Error code that indicates an unknown error occurred.

[`ACErrorAccountMissingRequiredProperty`](/documentation/Accounts/ACErrorAccountMissingRequiredProperty)

Error code that indicates an account wasn’t saved because a required property is missing.

[`ACErrorAccountAuthenticationFailed`](/documentation/Accounts/ACErrorAccountAuthenticationFailed)

Error code that indicates an account wasn’t saved because authentication of its credential failed.

[`ACErrorAccountTypeInvalid`](/documentation/Accounts/ACErrorAccountTypeInvalid)

Error code that indicates an account wasn’t saved because its account type is invalid.

[`ACErrorAccountAlreadyExists`](/documentation/Accounts/ACErrorAccountAlreadyExists)

Error code that indicates an account wasn’t added because it already exists.

[`ACErrorAccountNotFound`](/documentation/Accounts/ACErrorAccountNotFound)

Error code that indicates an account wasn’t deleted because it couldn’t be found.

[`ACErrorPermissionDenied`](/documentation/Accounts/ACErrorPermissionDenied)

Error code that indicates the operation failed because the application doesn’t have permission to perform the operation.

[`ACErrorAccessInfoInvalid`](/documentation/Accounts/ACErrorAccessInfoInvalid)

Error code that indicates the client’s access info dictionary has incorrect or missing values.

[`ACErrorClientPermissionDenied`](/documentation/Accounts/ACErrorClientPermissionDenied)

Error code that indicates the client doesn’t have access to the requested data.

[`ACErrorAccessDeniedByProtectionPolicy`](/documentation/Accounts/ACErrorAccessDeniedByProtectionPolicy)

Error code that indicates due to the current protection policy, the credentials couldn’t be fetched.

[`ACErrorCredentialNotFound`](/documentation/Accounts/ACErrorCredentialNotFound)

Error code that indicates no credentials were found.

[`ACErrorFetchCredentialFailed`](/documentation/Accounts/ACErrorFetchCredentialFailed)

Error code that indicates the credentials couldn’t be fetched from Keychain.

[`ACErrorStoreCredentialFailed`](/documentation/Accounts/ACErrorStoreCredentialFailed)

Error code that indicates the credentials couldn’t be stored in Keychain.

[`ACErrorRemoveCredentialFailed`](/documentation/Accounts/ACErrorRemoveCredentialFailed)

Error code that indicates the credentials couldn’t be removed from Keychain.

[`ACErrorUpdatingNonexistentAccount`](/documentation/Accounts/ACErrorUpdatingNonexistentAccount)

Error code that indicates an account save failed because the account being updated has been removed.

[`ACErrorInvalidClientBundleID`](/documentation/Accounts/ACErrorInvalidClientBundleID)

Error code that indicates the client making the request doesn’t have a valid bundle ID.

[`ACErrorDeniedByPlugin`](/documentation/Accounts/ACErrorDeniedByPlugin)

Error code that indicates a plugin prevented the expected action from occurring.

[`ACErrorCoreDataSaveFailed`](/documentation/Accounts/ACErrorCoreDataSaveFailed)

Error code that indicates an error occurred while trying to save to a Core Data store.

[`ACErrorFailedSerializingAccountInfo`](/documentation/Accounts/ACErrorFailedSerializingAccountInfo)

Error code that indicates an account’s information couldn’t be serialized.

[`ACErrorInvalidCommand`](/documentation/Accounts/ACErrorInvalidCommand)

Error code that indicates an invalid command was attempted.

[`ACErrorMissingTransportMessageID`](/documentation/Accounts/ACErrorMissingTransportMessageID)

Error code that indicates an expected message identifier wasn’t found while performing a command.

[`ACErrorCredentialItemNotFound`](/documentation/Accounts/ACErrorCredentialItemNotFound)

Error code that indicates a credential item wasn’t saved because it couldn’t be found.

[`ACErrorCredentialItemNotExpired`](/documentation/Accounts/ACErrorCredentialItemNotExpired)

Error code that indicates a credential item wasn’t removed because it hasn’t yet expired.

### Initializers

[`init(_:)`](/documentation/Accounts/ACErrorCode/init(_:))

Initializes a new error code structure.

[`init(rawValue:)`](/documentation/Accounts/ACErrorCode/init(rawValue:))

Initializes a new error code structure.

### Instance Properties

[`rawValue`](/documentation/Accounts/ACErrorCode/rawValue)

The raw integer value of the error code.

## Relationships

### Conforms To

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

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

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

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

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

---

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)