AuthRequestError enum

The possible errors as defined by the OAuth 2.0 specification.

Auth endpoints will use this list of values to determine the response sent back to a client upon a failed request.



invalidRequest → const AuthRequestError

The request was invalid...

The request is missing a required parameter, includes an unsupported parameter value (other than grant type), repeats a parameter, includes multiple credentials, utilizes more than one mechanism for authenticating the client, or is otherwise malformed.

invalidClient → const AuthRequestError

The client was invalid...

Client authentication failed (e.g., unknown client, no client authentication included, or unsupported authentication method). The authorization server MAY return an HTTP 401 (Unauthorized) status code to indicate which HTTP authentication schemes are supported. If the client attempted to authenticate via the "Authorization" request header field, the authorization server MUST respond with an HTTP 401 (Unauthorized) status code and include the "WWW-Authenticate" response header field matching the authentication scheme used by the client.

invalidGrant → const AuthRequestError

The grant was invalid...

The provided authorization grant (e.g., authorization code, resource owner credentials) or refresh token is invalid, expired, revoked, does not match the redirection URI used in the authorization request, or was issued to another client.

invalidScope → const AuthRequestError

The requested scope is invalid, unknown, malformed, or exceeds the scope granted by the resource owner.

unsupportedGrantType → const AuthRequestError

The authorization grant type is not supported by the authorization server.

unsupportedResponseType → const AuthRequestError

The authorization server does not support obtaining an authorization code using this method.

unauthorizedClient → const AuthRequestError

The authenticated client is not authorized to use this authorization grant type.

accessDenied → const AuthRequestError

The resource owner or authorization server denied the request.

serverError → const AuthRequestError

The server encountered an error during processing the request.

temporarilyUnavailable → const AuthRequestError

The server is temporarily unable to fulfill the request.

invalidToken → const AuthRequestError

Indicates that the token is invalid.

This particular error reason is not part of the OAuth 2.0 spec.


hashCode int
The hash code for this object.
no setterinherited
index int
A numeric identifier for the enumerated value.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited


noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
toString() String
A string representation of this object.


operator ==(Object other) bool
The equality operator.


values → const List<AuthRequestError>
A constant List of the values in this enum, in order of their declaration.