-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathDiscordOptions.cs
26 lines (24 loc) · 1.13 KB
/
DiscordOptions.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Http;
namespace Discord.OAuth2
{
/// <summary> Configuration options for <see cref="DiscordMiddleware"/>. </summary>
public class DiscordOptions : OAuthOptions
{
/// <summary> Initializes a new <see cref="DiscordOptions"/>. </summary>
public DiscordOptions()
{
AuthenticationScheme = DiscordDefaults.AuthenticationScheme;
DisplayName = AuthenticationScheme;
CallbackPath = new PathString("/signin-discord");
AuthorizationEndpoint = DiscordDefaults.AuthorizationEndpoint;
TokenEndpoint = DiscordDefaults.TokenEndpoint;
UserInformationEndpoint = DiscordDefaults.UserInformationEndpoint;
Scope.Add("identify");
}
/// <summary> Gets or sets the Discord-assigned appId. </summary>
public string AppId { get { return ClientId; } set { ClientId = value; } }
/// <summary> Gets or sets the Discord-assigned app secret. </summary>
public string AppSecret { get { return ClientSecret; } set { ClientSecret = value; } }
}
}