Method GetGuildPruneCount
| Improve this Doc View SourceGetGuildPruneCount(Snowflake, int?, IEnumerable<Snowflake>?)
Returns the number of members that would be kicked from a guild prune operation.
Requires KickMembers.
Declaration
public Task<int> GetGuildPruneCount(Snowflake guildId, int? days = null, IEnumerable<Snowflake>? includeRoles = null)
Parameters
| Type | Name | Description |
|---|---|---|
| Snowflake | guildId | |
| int? | days | The number of days to count prune for (1-30). |
| IEnumerable<Snowflake> | includeRoles | By default, prune will not remove users with roles. You can optionally include specific
roles in your prune by providing the |
Returns
| Type | Description |
|---|---|
| Task<int> |
Exceptions
| Type | Condition |
|---|---|
| DiscordHttpApiException |
GetGuildPruneCount(DiscordGuild, int?, IEnumerable<DiscordRole>?)
Returns the number of members that would be kicked from a guild prune operation.
Requires KickMembers.
Declaration
public Task<int> GetGuildPruneCount(DiscordGuild guild, int? days = null, IEnumerable<DiscordRole>? includeRoles = null)
Parameters
| Type | Name | Description |
|---|---|---|
| DiscordGuild | guild | |
| int? | days | The number of days to count prune for (1-30). |
| IEnumerable<DiscordRole> | includeRoles | By default, prune will not remove users with roles. You can optionally include specific
roles in your prune by providing the |
Returns
| Type | Description |
|---|---|
| Task<int> |
Exceptions
| Type | Condition |
|---|---|
| ArgumentNullException | |
| DiscordHttpApiException |