AuthConfig class final
Tuning knobs for authInterceptor.
Constructors
- AuthConfig({required TokenSource source, String headerName = authorizationHeader, String prefix = bearerPrefix, bool overrideExisting = false})
-
Builds a config that injects
authorization: Bearer <token>fromsource.const
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- headerName → String
-
Where the credential lands. Override to
x-api-key(withprefix: '') for vendor API-key conventions.final - overrideExisting → bool
-
When true, overwrite a caller-supplied header. Default false: explicit
caller intent wins (useful for per-call credential overrides).
final
- prefix → String
-
String prepended to the token. Defaults to RFC 6750
Bearer. Set to the empty string for raw API-key headers.final - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- source → TokenSource
-
Source of the credential value.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited