deleteUserWithHttpInfo method
Deactivate a user account.
Deactivates the user and revokes all its sessions by archiving its user object. As of server version 5.28, optionally use the permanent=true
query parameter to permanently delete the user for compliance reasons. To use this feature ServiceSettings.EnableAPIUserDeletion
must be set to true
in the server's configuration. ##### Permissions Must be logged in as the user being deactivated or have the edit_other_users
permission.
Note: This method returns the HTTP Response
.
Parameters:
- String userId (required): User GUID
Implementation
Future<Response> deleteUserWithHttpInfo(
String userId,
) async {
// ignore: prefer_const_declarations
final path = r'/users/{user_id}'.replaceAll('{user_id}', userId);
// ignore: prefer_final_locals
Object? postBody;
final queryParams = <MmQueryParam>[];
final headerParams = <String, String>{};
final formParams = <String, String>{};
const contentTypes = <String>[];
return apiClient.invokeAPI(
path,
'DELETE',
queryParams,
postBody,
headerParams,
formParams,
contentTypes.isEmpty ? null : contentTypes.first,
);
}