Interface ICredentialStore
- Namespace
- JD.AI.Core.Providers.Credentials
- Assembly
- JD.AI.Core.dll
Provides secure storage for provider API keys and secrets.
public interface ICredentialStore
Properties
IsAvailable
Whether this store is available on the current platform.
bool IsAvailable { get; }
Property Value
StoreName
Human-readable name of the backing store.
string StoreName { get; }
Property Value
Methods
GetAsync(string, CancellationToken)
Gets a stored credential value.
Task<string?> GetAsync(string key, CancellationToken ct = default)
Parameters
keystringctCancellationToken
Returns
ListKeysAsync(string, CancellationToken)
Lists all keys matching a prefix.
Task<IReadOnlyList<string>> ListKeysAsync(string prefix, CancellationToken ct = default)
Parameters
prefixstringctCancellationToken
Returns
RemoveAsync(string, CancellationToken)
Removes a stored credential.
Task RemoveAsync(string key, CancellationToken ct = default)
Parameters
keystringctCancellationToken
Returns
SetAsync(string, string, CancellationToken)
Stores a credential value.
Task SetAsync(string key, string value, CancellationToken ct = default)
Parameters
keystringvaluestringctCancellationToken