Class MailAccessTokenUnavailableException
- Namespace
- MailFathom.Infrastructure.Mail.OAuth
- Assembly
- MailFathom.Infrastructure.dll
Indicates that an account's authorization server did not issue an access token its OAuth mechanisms require.
public sealed class MailAccessTokenUnavailableException : MailFathomException, ISerializable
- Inheritance
-
MailAccessTokenUnavailableException
- Implements
- Inherited Members
Remarks
The payload names the account and the authorization server's own error code — invalid_grant,
invalid_client, and their siblings — which is what an operator needs to tell a revoked refresh token from a
mistyped client secret. It arrives from a machine this process does not own and RFC 6749 bounds neither its length
nor its content, so AuthorizationServerErrorText reduces it before it reaches a message. Nothing
else from the response travels: the error_description is free text an authorization server may populate with
the request it rejected, so it is read by nobody here.
The token endpoint address is deliberately absent. It is a host name, which MailFathomException excludes from a message, and the account alias already identifies which configured endpoint was called.
Constructors
- MailAccessTokenUnavailableException(string, Exception)
Initializes a failure that happened before any response could state one.
- MailAccessTokenUnavailableException(string, string)
Initializes a failure the authorization server stated in its response.
Properties
- AccountId
Gets the local account identifier.
- AuthorizationServerErrorCode
Gets the authorization server's RFC 6749 error code, or null when it returned none.
- ErrorCode
Gets the stable code identifying this failure to a boundary that must report it without naming a type.