class XmBindIdSdk

Entry point interface to the BindID Client SDK.

This interface declares all top level services supported by the SDK. An instance of this interface is available to client applications as window.XmBindId.

Before the BindID SDK can be used, the XmBindIdSdk.initialize call must be invoked, with proper configuration for the client application using BindID.


public abstract PromiseFuture< Boolean, XmBindIdError > initialize(@NonNull XmBindIdConfig config)

Initialize the BindID Client SDK and set application-wide configuration.

All BindID Client SDK calls must be invoked only after succesful completion of this asynchornous initialization call.

The returned promise will either be resolved with a boolean 'true' value, or rejected with an error.


public abstract PromiseFuture< XmBindIdResponse, XmBindIdError > authenticate(@NonNull XmBindIdAuthenticationRequest bindIdRequestParams)

Invoke a BindID authentication flow.

This call will start a user login flow using BindID. The browser will be redirected to BindID's login page, where user identity will be established. Once complete, BindID will redirect the user back to the invoking web/mobile application based on the URL provided in the authentication request parameters, sending back authentication result information.

If invoked by a web application, the web application should invoke #processRedirectResponse to extract the information returned in the response and complete the authentication process.

The returned Promise will either be rejected with an error, or never complete (since this call may redirect the user agent to another page).


public abstract PromiseFuture< XmBindIdResponse, XmBindIdError > signTransaction(@NonNull XmBindIdTransactionSigningRequest bindIdTransactionRequest)

Invoke BindID authentication flow for transaction signing.

This request will behave similarly to an authentication request, with the following additions:

OIDC claims parameter will be added to the request to indicate the BindID server that this is a transaction signing request. By default the request will be sent as an encrypted JWT. BindID server will show the transaction details to the user. BindID server will include the transaction claim in the id_token upon successful authentication and token exchange.


public abstract PromiseFuture< XmBindIdExchangeTokenResponse, XmBindIdError > exchangeToken(@NonNull XmBindIdExchangeTokenRequest exchangeRequest)