Constructor DiscordOAuth2Client
- Namespace
- DisCatSharp
- Assembly
- DisCatSharp.dll
DiscordOAuth2Client(ulong, string, string, IServiceProvider, IWebProxy, TimeSpan?, bool, ILoggerFactory, LogLevel, string)
Creates a new OAuth2 client.
public DiscordOAuth2Client(ulong clientId, string clientSecret, string redirectUri, IServiceProvider provider = null, IWebProxy proxy = null, TimeSpan? timeout = null, bool useRelativeRateLimit = true, ILoggerFactory loggerFactory = null, LogLevel minimumLogLevel = LogLevel.Information, string logTimestampFormat = "yyyy-MM-dd HH:mm:ss zzz")
Parameters
clientIdulongThe client id.
clientSecretstringThe client secret.
redirectUristringThe redirect uri.
providerIServiceProviderThe service provider.
proxyIWebProxyThe proxy to use for HTTP connections. Defaults to null.
timeoutTimeSpan?The optional timeout to use for HTTP requests. Set to InfiniteTimeSpan to disable timeouts. Defaults to null.
useRelativeRateLimitboolWhether to use the system clock for computing rate limit resets. See UseRelativeRatelimit for more details. Defaults to true.
loggerFactoryILoggerFactoryThe optional logging factory to use for this client. Defaults to null.
minimumLogLevelLogLevelThe minimum logging level for messages. Defaults to information.
logTimestampFormatstringThe timestamp format to use for the logger.