Errors¶
Exception hierarchy¶
OkatanaException
├── OkatanaConfigurationException
├── OkatanaRequestValidationException
├── OkatanaTransportException
├── OkatanaUnexpectedResponseException
└── OkatanaApiException
├── OkatanaAuthenticationException 401
├── OkatanaAuthorizationException 403
├── OkatanaNotFoundException 404
├── OkatanaValidationException 422
└── OkatanaRateLimitException 429
Validation responses¶
Laravel validation errors can include a message and errors map. OkatanaValidationException.errors() converts field arrays to Map<String,List<String>>.
Business-rule failures may return 422 with only a message. In that case errors() is empty and the exception message remains available.
Generic API error details¶
OkatanaApiException exposes:
- HTTP status;
- method;
- URI;
- parsed response body;
- response headers.
Do not automatically log the complete body if the endpoint may contain sensitive project/document content.