---
title: CNError.Code
framework: contacts
role: symbol
role_heading: Enumeration
path: contacts/cnerror/code
---

# CNError.Code

Error codes that the system may return when you use Contacts framework methods.

## Declaration

```swift
enum Code
```

## Topics

### Errors

- [CNError.Code.authorizationDenied](contacts/cnerror/code/authorizationdenied.md)
- [CNError.Code.changeHistoryExpired](contacts/cnerror/code/changehistoryexpired.md)
- [CNError.Code.changeHistoryInvalidAnchor](contacts/cnerror/code/changehistoryinvalidanchor.md)
- [CNError.Code.changeHistoryInvalidFetchRequest](contacts/cnerror/code/changehistoryinvalidfetchrequest.md)
- [CNError.Code.clientIdentifierCollision](contacts/cnerror/code/clientidentifiercollision.md)
- [CNError.Code.clientIdentifierInvalid](contacts/cnerror/code/clientidentifierinvalid.md)
- [CNError.Code.clientIdentifierDoesNotExist](contacts/cnerror/code/clientidentifierdoesnotexist.md)
- [CNError.Code.communicationError](contacts/cnerror/code/communicationerror.md)
- [CNError.Code.containmentCycle](contacts/cnerror/code/containmentcycle.md)
- [CNError.Code.containmentScope](contacts/cnerror/code/containmentscope.md)
- [CNError.Code.dataAccessError](contacts/cnerror/code/dataaccesserror.md)
- [CNError.Code.featureDisabledByUser](contacts/cnerror/code/featuredisabledbyuser.md)
- [CNError.Code.featureNotAvailable](contacts/cnerror/code/featurenotavailable.md)
- [CNError.Code.insertedRecordAlreadyExists](contacts/cnerror/code/insertedrecordalreadyexists.md)
- [CNError.Code.noAccessableWritableContainers](contacts/cnerror/code/noaccessablewritablecontainers.md)
- [CNError.Code.parentContainerNotWritable](contacts/cnerror/code/parentcontainernotwritable.md)
- [CNError.Code.parentRecordDoesNotExist](contacts/cnerror/code/parentrecorddoesnotexist.md)
- [CNError.Code.policyViolation](contacts/cnerror/code/policyviolation.md)
- [CNError.Code.predicateInvalid](contacts/cnerror/code/predicateinvalid.md)
- [CNError.Code.recordDoesNotExist](contacts/cnerror/code/recorddoesnotexist.md)
- [CNError.Code.recordIdentifierInvalid](contacts/cnerror/code/recordidentifierinvalid.md)
- [CNError.Code.recordNotWritable](contacts/cnerror/code/recordnotwritable.md)
- [CNError.Code.unauthorizedKeys](contacts/cnerror/code/unauthorizedkeys.md)
- [CNError.Code.validationMultipleErrors](contacts/cnerror/code/validationmultipleerrors.md)
- [CNError.Code.validationTypeMismatch](contacts/cnerror/code/validationtypemismatch.md)
- [CNError.Code.validationConfigurationError](contacts/cnerror/code/validationconfigurationerror.md)
- [CNError.Code.vCardMalformed](contacts/cnerror/code/vcardmalformed.md)
- [CNError.Code.vCardSummarizationError](contacts/cnerror/code/vcardsummarizationerror.md)

### Initializers

- [init(rawValue:)](contacts/cnerror/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

### Error codes

- [CNError](contacts/cnerror.md)
