SpendOwlError
Errors that can occur within the SpendOwl SDK.Error Cases
notConfigured
1001
Solution: Call SpendOwl.configure(apiKey:) before using other SDK methods.
invalidAPIKey
1002
Solution: Check that you’re using the correct API key from your SpendOwl dashboard.
networkError
2001
Associated Value: The underlying network error.
Notes:
- The SDK automatically retries failed requests with exponential backoff
- This error is returned after all retry attempts have failed
serverError
2002
Associated Values:
statusCode: The HTTP status codemessage: An optional error message from the server
attributionUnavailable
3001
Causes:
- iOS version below 14.3
- AdServices framework not available
- Running in certain simulator configurations
attributionDenied
3002
Causes:
- User has enabled “Limit Ad Tracking”
- MDM profile restricts ad tracking
- Device privacy settings
encodingError
4001
Notes: This is an internal error that should not occur in normal operation. If it does, please report it.
decodingError
4002
Associated Value: The underlying decoding error.
Solution: This may indicate an API version mismatch. Update to the latest SDK version.
unknown
9999
Associated Value: The underlying error for debugging.
Properties
errorDescription
errorCode
| Code Range | Category |
|---|---|
| 1000-1999 | Configuration errors |
| 2000-2999 | Network/server errors |
| 3000-3999 | Attribution errors |
| 4000-4999 | Data encoding/decoding errors |
| 9000-9999 | Unknown errors |
Error Handling Examples
Comprehensive Handling
Simple Handling
For most apps, simple error handling is sufficient:Completion Handler Pattern
Related
Debugging
Debug logging and troubleshooting
Troubleshooting
Common issues and solutions