Package com.anthropic.errors
Class NoCredentialsException
-
- All Implemented Interfaces:
-
java.io.Serializable
public final class NoCredentialsException extends AnthropicException
Thrown when no credentials could be obtained from any of the sources the client tried (environment variables, auth tokens, configured profiles, etc.).
sources records each source that was attempted and why it did not yield usable credentials, so the error message can point the user at the most likely fix.
-
-
Field Summary
Fields Modifier and Type Field Description private final List<CredentialSource>sourcesprivate final Stringmessageprivate final Throwablecauseprivate final StringlocalizedMessageprivate final Array<Throwable>suppressedprivate Array<StackTraceElement>stackTrace
-
Method Summary
Modifier and Type Method Description final List<CredentialSource>sources()-
Methods inherited from class kotlin.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
sources
final List<CredentialSource> sources()
-
-
-
-