SDK
SDK Java v3.x
2

This SDK is deprecated. We recommend to use the Kuzzle SDK-JVM.
A migration guide is available here

UpdateMyCredentials #

Updates the current user's credentials for the specified strategy. The credentials to send will depend on the authentication plugin and the authentication strategy.

Arguments #

CompletableFuture<ConcurrentHashMap<String, Object>> updateMyCredentials(
  final String strategy,
  final ConcurrentHashMap<String, Object> credentials)
  throws NotConnectedException, InternalException
ArgumentTypeDescription
strategy
String
Strategy to use
credentials
ConcurrentHashMap<String, Object>
JObject representing the credentials

Return #

A ConcurrentHashMap representing the updated credentials with the following properties:

PropertyTypeDescription
username
String
The Username
kuid
String
The user's kuid

Usage #

ConcurrentHashMap<String, Object> credentials = new ConcurrentHashMap<>();
credentials.put("username", "foo");
credentials.put("password", "bar");
kuzzle.getAuthController().login("local", credentials).get();
ConcurrentHashMap<String, Object> result = kuzzle.getAuthController().updateMyCredentials("local", credentials).get();