CredentialRef
Category: Credentials
Source: credential_ref.dart
Sealed reference to a credential source.
Separates where a secret comes from from what the secret is. Adapters receive a resolved string (via [CredentialStore.resolve]) and never read the environment or credentials file themselves.
Classes
sealed CredentialRef
Constructor
dart
const CredentialRef()EnvCredential
The credential is read from an environment variable.
Constructor
dart
const EnvCredential(this.name)Properties
| Property | Type | Description |
|---|---|---|
name | String | |
operator | bool | |
hashCode | int get | |
hashCode | int get |
StoredCredential
The credential is stored under a provider id in ~/.glue/credentials.json.
Constructor
dart
const StoredCredential(this.key)Properties
| Property | Type | Description |
|---|---|---|
key | String | |
operator | bool | |
hashCode | int get | |
hashCode | int get |
InlineCredential
An inline secret parsed from a user-owned file (not recommended).
Constructor
dart
const InlineCredential(this.value)Properties
| Property | Type | Description |
|---|---|---|
value | String | |
operator | bool | |
hashCode | int get | |
hashCode | int get |
NoCredential
The provider needs no credential (e.g. Ollama with auth: api_key: none).
Constructor
dart
const NoCredential()Properties
| Property | Type | Description |
|---|---|---|
operator | bool | |
hashCode | int get | |
hashCode | int get |