Table of Contents

Class ProviderEndpointCredential

Namespace
MailFathom.AI.Providers
Assembly
MailFathom.AI.dll

What one request presents to one AI provider endpoint, already resolved from whatever reference declared it.

public sealed class ProviderEndpointCredential : IDisposable
Inheritance
ProviderEndpointCredential
Implements
Inherited Members

Remarks

The instance is owned by the request that resolved it and released when that request ends, which bounds the window in which a process dump could hold the key to one call rather than to process uptime. A key rotated behind an unchanged reference is therefore picked up by the next request, with no cache to invalidate.

A Microsoft Entra credential carries no material here at all. Its own secret, where the chosen shape has one, is resolved by whoever builds this value and released with it; what the request presents is an access token the credential fetches and caches for itself.

Properties

ApiKey

Gets the resolved provider key, or null when the credential is a Microsoft Entra one.

Entra

Gets what the Microsoft Entra credential is built from, or null when the credential is a key.

ExtraHeaders

Gets the headers this request carries beside whatever the credential writes, empty where the endpoint declared none.

Kind

Gets how the deployment proves its identity to the endpoint.

Methods

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

FromApiKey(string, IDisposable?, IReadOnlyList<ProviderEndpointHeader>?, IReadOnlyList<IDisposable>?)

Builds a credential that presents a provider-issued key.

FromEntra(EntraCredentialDeclaration, IDisposable?, IReadOnlyList<ProviderEndpointHeader>?, IReadOnlyList<IDisposable>?)

Builds a credential that presents a Microsoft Entra access token.

Unauthenticated(IReadOnlyList<ProviderEndpointHeader>?, IReadOnlyList<IDisposable>?)

Builds the credential of an endpoint that asks for none, which presents nothing.