unbanMember static method

Future<Int32Response> unbanMember(
  1. HttpClient client,
  2. String groupId,
  3. String membershipId,
  4. BungieMembershipType membershipType,
)

Unbans the requested member, allowing them to re-apply for membership.

Implementation

static Future<Int32Response> unbanMember (
    HttpClient client,
    String groupId,
    String membershipId,
    BungieMembershipType membershipType,
) async {
    final Map<String, dynamic> params = Map<String, dynamic>();
    final String _groupId = '$groupId';
    final String _membershipId = '$membershipId';
    final String _membershipType = '${membershipType.value}';
    final HttpClientConfig config = HttpClientConfig('POST', '/GroupV2/$_groupId/Members/$_membershipType/$_membershipId/Unban/', params);
    config.bodyContentType = null;
    final HttpResponse response = await client.request(config);
    if(response.statusCode == 200) {
        return Int32Response.asyncFromJson(response.mappedBody);
    }
    throw Exception(response.mappedBody);
}