ban method

Future<bool> ban(
  1. Snowflake memberId, {
  2. String? reason,
})

Unbanned this from the Guild and deleted its messages for a given period

Example :

await member.unban();

Implementation

Future<bool> ban (Snowflake memberId, { String? reason }) async {
  Response response = await ioc.use<DiscordApiHttpService>().destroy(url: '/guilds/$id/bans/$memberId')
    .auditLog(reason)
    .build();

  return response.statusCode == 200;
}