setVerificationLevel method

Future<void> setVerificationLevel(
  1. VerificationLevel level
)

Modifies the verificationLevel of the current Guild.

Example :

import 'package:mineral/api.dart'; 👈 // then you can use VerificationLevel enum

await guild.setVerificationLevel(VerificationLevel.veryHigh);

Implementation

Future<void> setVerificationLevel (VerificationLevel level) async {
  Http http = ioc.singleton(Service.http);
  Response response = await http.patch(url: "/guilds/$id", payload: { 'verification_level': level.value });

  if (response.statusCode == 200) {
    _verificationLevel = level;
  }
}