---
title: SAError.Code
framework: SafetyKit
role: symbol
role_heading: Enumeration
platforms: [iOS 16.0+, iPadOS 16.0+, Mac Catalyst 16.0+, macOS 13.0+, watchOS 10.1+]
path: safetykit/saerror/code
---

# SAError.Code

Codes for identifying errors in SafetyKit.

## Declaration

```swift
enum Code
```

## Topics

### Determining the error type

- [SAError.Code.invalidArgument](safetykit/saerror/code/invalidargument.md)
- [SAError.Code.notAllowed](safetykit/saerror/code/notallowed.md)
- [SAError.Code.notAuthorized](safetykit/saerror/code/notauthorized.md)
- [SAError.Code.operationFailed](safetykit/saerror/code/operationfailed.md)

### Initializers

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

### Handling errors

- [SAErrorDomain](safetykit/saerrordomain.md)
- [SAError](safetykit/saerror.md)
