Method GenerateInAppOauthFor
- Namespace
- DisCatSharp
- Assembly
- DisCatSharp.dll
GenerateInAppOauthFor(DiscordUser, Permissions, OAuthScopes, string?, bool, ulong?, string?, string?, string?, bool, string?)
Generates an In-App OAuth Url for a specific bot
.
public Uri GenerateInAppOauthFor(DiscordUser bot, Permissions permissions = Permissions.None, OAuthScopes scopes = OAuthScopes.BOT_DEFAULT, string? redir = null, bool user_install = false, ulong? guild_id = null, string? state = null, string? access_type = null, string? response_type = null, bool prompt = true, string? manual_scopes = null)
Parameters
bot
DiscordUserThe bot to generate the url for.
permissions
PermissionsDefaults to None.
scopes
OAuthScopesThe scopes to send with the request. Defaults to BOT_DEFAULT. Mutually exclusive to
manual_scopes
.redir
stringRedirect Uri.
user_install
boolWhether to install as user app.
guild_id
ulong?The guild id to pre-select.
state
stringThe state to send with the request.
access_type
stringThe access type to send with the request (offline|online).
response_type
stringThe response type to send with the request (code|token).
prompt
boolWhether to prompt the user for authorization.
manual_scopes
stringThe scopes to send with the request. Mutually exclusive to
scopes
.
Returns
- Uri
The OAuth Url