Introducing VIDA Identity Stack: All of VIDA, in one place 🎉
For the complete documentation index, see llms.txt. This page is also available as Markdown.

Methods

updateToken(token)

Registers access token.

Param Description:

  • token: Access token

getCredentialId()

Retrieves the registered credential ID.

Returns: Credential ID

registerDevice(credentialId, password)

Binds a new credentialId to a device. If registration was successful, you can start signing messages. Password is an optional property, but registration will fail if a presence user registers without a password.

Returns: “Credentials registered” string if registration succeeds

Param Description:

  • credentialId: Credential ID to bind

  • password: Presence user’s password used to sign the message

signMessage(messageHash)

Signing message for silent user.

Returns: Message signature

Param Description:

  • messageHash: Hash of the message to sign

signMessageWithUserPresence(messageHash, password)

Signing message for a presence user with a password.

Returns: Message signature

Param Description:

  • messageHash: Hash of the message to sign

  • password: Password provided when registering the device

signMessageWithUserPresenceUsingBiometrics(messageHash, localizedBiometricReason, title, cancel)

Signing message for a presence user using a biometric sensor.

Returns: Message signature

Param Description:

  • messageHash: Hash of the message to sign

  • localizedBiometricReason: Description shown on the biometric dialog

  • title: Title of the biometric dialog

  • cancel: Cancel button caption of the biometric dialog

isBiometryAvailable()

Status of biometric sensor availability.

Returns: Boolean

enableBiometrics(password, localizedBiometricReason, title, cancel)

Enable singing with biometrics.

Returns: "Biometry enabled" string if biometrics enabled.

Param Description:

  • password: Password provided when registering the device

  • localizedBiometricReason: Description shown on the biometric dialog

  • title: Title of the biometric dialog

  • cancel: Cancel button caption of the biometric dialog

disableBiometrics(password)

Disable singing with biometrics.

Returns: "Biometry disabled" string if biometrics disabled.

Param Description:

  • password: Password provided when registering the device

hasSilentCredentials()

Check if the user is a silent user.

Returns: Boolean

hasPresenceCredentials()

Check if the user is a presence user and needs to provide a password.

Returns: Boolean

hasBiometryEnabled()

Check if biometry is enabled to sign the messages.

Returns: Boolean

wipeDevice(password)

Wipe credentials for the current device. Password should be provided.

Returns: "Device wiped" string on successful execution.

Param Description:

  • password: Password provided when registering the device

wipeForgotPassword()

Wipe credentials for the current device.

Returns: "Device wiped" string on successful execution.

registerTransaction(presence, messageHash)

Registers a transaction.

Returns: Transaction ID

Param Description:

  • presence: "SILENT_USER" or "ENFORCE_USER_PRESENCE"

  • messageHash: Hash of the message

finishTransaction(transactionId, password)

Finishes a transaction.

Returns: "Transaction complete" string if the transaction is finished.

Param Description:

  • transactionId: Transaction ID provided by registerTransaction

  • password: Password provided when registering the device

Last updated