io.enterpriseai.errors.AuthException
Source: sdks/java/enterprise-ai-java/src/main/java/io/enterpriseai/errors/AuthException.java. Back to the Java SDK reference index.
note
This page is generated by tools/docs/gen_sdk_reference.py from the SDK sources and the OpenAPI text folders. Do not edit it by hand: change the source and regenerate.
Class AuthException
Raised on HTTP 401/403 for missing, invalid or insufficient credentials.
EaiException
Constructor AuthException
AuthException(int status, String code, String message, JsonNode details, String requestId, Long retryAfterSeconds)
Creates the exception from the fields of the error envelope; EaiException.fromResponse picks it from the code.
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
status | int | yes | HTTP status of the response, 0 for a network error. | |
code | String | yes | Stable machine code of the error, such as policy_denied. | |
message | String | yes | Message already localized in the client language. | |
details | JsonNode | yes | error.details of the envelope, redacted; null becomes a MissingNode. | |
requestId | String | yes | error.request_id or the X-Request-Id header, may be null. | |
retryAfterSeconds | Long | yes | Retry-After delay in seconds, or null. |