Table of Contents

Method OAuth2GetGuildMemberAsync

Namespace
DisCatSharp.Entities
Assembly
DisCatSharp.dll

OAuth2GetGuildMemberAsync(DiscordOAuth2Client, DiscordGuild)

Gets the current user's member object for given guild.

Requires a DiscordAccessToken set in AccessToken.

public Task<DiscordMember> OAuth2GetGuildMemberAsync(DiscordOAuth2Client oauth2Client, DiscordGuild guild)

Parameters

oauth2Client DiscordOAuth2Client

The oauth2 client.

guild DiscordGuild

The guild to get the member object for.

Returns

Task<DiscordMember>

Exceptions

NullReferenceException

Thrown when AccessToken is not present.

OAuth2GetGuildMemberAsync(DiscordOAuth2Client, ulong)

Gets the current user's member object for given guildId.

Requires a DiscordAccessToken set in AccessToken.

public Task<DiscordMember> OAuth2GetGuildMemberAsync(DiscordOAuth2Client oauth2Client, ulong guildId)

Parameters

oauth2Client DiscordOAuth2Client

The oauth2 client.

guildId ulong

The guild id to get the member object for.

Returns

Task<DiscordMember>

Exceptions

NullReferenceException

Thrown when AccessToken is not present.