Codes for errors that may occur.


struct ACErrorCode



var ACErrorUnknown: ACErrorCode

An unknown error occurred.

var ACErrorAccountMissingRequiredProperty: ACErrorCode

An account was not saved because a required property is missing.

var ACErrorAccountAuthenticationFailed: ACErrorCode

An account was not saved because authentication of its credential failed.

var ACErrorAccountTypeInvalid: ACErrorCode

An account was not saved because its account type is invalid.

var ACErrorAccountAlreadyExists: ACErrorCode

An account was not added because it already exists.

var ACErrorAccountNotFound: ACErrorCode

An account was not deleted because it could not be found.

var ACErrorPermissionDenied: ACErrorCode

The operation failed because the application does not have permission to perform the operation.

var ACErrorAccessInfoInvalid: ACErrorCode

The client's access info dictionary has incorrect or missing values.

var ACErrorClientPermissionDenied: ACErrorCode

The client does not have access to the requested data.

var ACErrorAccessDeniedByProtectionPolicy: ACErrorCode

Due to the current protection policy, the credentials could not be fetched.

var ACErrorFetchCredentialFailed: ACErrorCode

The credentials could not be fetched from Keychain.

var ACErrorStoreCredentialFailed: ACErrorCode

The credentials could not be stored in Keychain.

var ACErrorRemoveCredentialFailed: ACErrorCode

The credentials could not be removed from Keychain.

var ACErrorUpdatingNonexistentAccount: ACErrorCode

Account save failed because the account being updated has been removed.

var ACErrorInvalidClientBundleID: ACErrorCode

The client making the request does not have a valid bundle ID.

Instance Properties


See Also


let ACErrorDomain: String

The error domain for the Accounts framework.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software