SDK C# v2.x

DeleteMyCredentialsAsync #

Deletes the current user's credentials for the specified strategy. If the credentials that generated the current authentication token are removed, the user will remain logged in until he logs out or his session expires. After that they will no longer be able to log in with the deleted credentials.

Arguments #

Copied to clipboard!
public async Task DeleteMyCredentialsAsync(string strategy);
Argument Type Description
Strategy to use

Exceptions #

Throws a KuzzleException if there is an error. See how to handle error.

Usage #

Copied to clipboard!
try {
  await kuzzle.Auth.LoginAsync(
    JObject.Parse("{username: 'foo', password: 'bar'}"));
  await kuzzle.Auth.DeleteMyCredentialsAsync("local");
  Console.WriteLine("Credentials Successfully deleted");
} catch (KuzzleException e) {