Unknown SDK

CreateMyCredentialsAsync

Create the current user's credentials for the specified strategy.

Arguments

Copied to clipboard!
public async Task<JObject> CreateMyCredentialsAsync(
      string strategy,
      JObject credentials);
Argument Type Description
strategy
string
Strategy to use
credentials
JObject
JObject representing the credentials

Return

A JObject representing the new credentials.

Usage

Copied to clipboard!
await kuzzle.Auth.LoginAsync(
  "local",
  JObject.Parse("{username: 'foo', password: 'bar'}"));
await kuzzle.Auth.CreateMyCredentialsAsync(
  "other",
  JObject.Parse("{username: 'foo', password: 'bar'}"));