Discore
Show / Hide Table of Contents

Method ListGuildMembers

| Improve this Doc View Source

ListGuildMembers(Snowflake, int?, Snowflake?)

Gets a list of members in a guild. This method is paged, and cannot always return every member at once.

Declaration
public Task<IReadOnlyList<DiscordGuildMember>> ListGuildMembers(Snowflake guildId, int? limit = null, Snowflake? after = null)
Parameters
Type Name Description
Snowflake guildId

The ID of the guild.

int? limit

Max number of members to return (1-1000).

Snowflake? after

The highest user ID in the previous page.

Returns
Type Description
Task<IReadOnlyList<DiscordGuildMember>>
Exceptions
Type Condition
DiscordHttpApiException
| Improve this Doc View Source

ListGuildMembers(DiscordGuild, int?, Snowflake?)

Gets a list of members in a guild. This method is paged, and cannot always return every member at once.

Declaration
public Task<IReadOnlyList<DiscordGuildMember>> ListGuildMembers(DiscordGuild guild, int? limit = null, Snowflake? after = null)
Parameters
Type Name Description
DiscordGuild guild

The guild.

int? limit

Max number of members to return (1-1000).

Snowflake? after

The highest user ID in the previous page.

Returns
Type Description
Task<IReadOnlyList<DiscordGuildMember>>
Exceptions
Type Condition
ArgumentNullException
DiscordHttpApiException
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX