Table of Contents

Class StaticTokenProvider

Namespace
BpNexT.NET.GraphQL.Auth
Assembly
BpNexT.NET.GraphQL.dll

Provides a static bearer token.

public class StaticTokenProvider : IGraphQlAuthProvider
Inheritance
object
StaticTokenProvider
Implements

Constructors

StaticTokenProvider(string)

Initializes a new instance with the specified token.

public StaticTokenProvider(string token)

Parameters

token string

Methods

GetTokenAsync(CancellationToken)

Returns the current bearer token.

public Task<string> GetTokenAsync(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

Token to cancel the operation (e.g. a token-refresh request).

Returns

Task<string>