3using System.Threading.Tasks;
6using HotChocolate.Types;
17 [GraphQLDescription(GraphQLDescription)]
32 public ValueTask<LoginResult>
Login(
34 CancellationToken cancellationToken)
36 ArgumentNullException.ThrowIfNull(loginAuthority);
39 authority => authority.AttemptLogin(cancellationToken));
51 CancellationToken cancellationToken)
53 ArgumentNullException.ThrowIfNull(loginAuthority);
56 authority => authority.AttemptOAuthGatewayLogin(cancellationToken));
Exception representing ErrorMessageResponses.
Root type for GraphQL mutations.
const string GraphQLDescription
Description to show on the Mutation type.
ValueTask< OAuthGatewayLoginResult > OAuthGateway([Service] IGraphQLAuthorityInvoker< ILoginAuthority > loginAuthority, CancellationToken cancellationToken)
Generate an OAuth user token for the requested service. This requires the OAuth authentication scheme...
ValueTask< LoginResult > Login([Service] IGraphQLAuthorityInvoker< ILoginAuthority > loginAuthority, CancellationToken cancellationToken)
Generate a JWT for authenticating with server. This requires either the Basic authentication or OAuth...
Success response for a login attempt.
Success result for an OAuth gateway login attempt.
Invokes TAuthority s from GraphQL endpoints.