DigitalCredential
@ExperimentalDigitalCredentialApi
class DigitalCredential : Credential
Represents the user's digital credential, generally used for verification or sign-in purposes.
Notice, this class does not necessarily always represents a successful digital credential. Depending on the protocol in your request, the credentialJson may contain a failure response generated from the provider. Therefore, please follow the protocol specification to parse the credentialJson and determine the failure / success response. For example, here is the error response definition for the OpenID for Verifiable Presentations protocol.
Summary
Constants |
|
|---|---|
const String |
The type value for public key credential related operations. |
Public constructors |
|---|
DigitalCredential(credentialJson: String)Constructs a |
Public properties |
|
|---|---|
String |
the digital credential in the JSON format; the latest format is defined at https://wicg.github.io/digital-credentials/#the-digitalcredential-interface |
Inherited properties |
||||
|---|---|---|---|---|
|
Constants
TYPE_DIGITAL_CREDENTIAL
const val TYPE_DIGITAL_CREDENTIAL: String
The type value for public key credential related operations.
Public constructors
DigitalCredential
DigitalCredential(credentialJson: String)
Constructs a DigitalCredential.
| Parameters | |
|---|---|
credentialJson: String |
the digital credential in the JSON format; the latest format is defined at https://wicg.github.io/digital-credentials/#the-digitalcredential-interface |
| Throws | |
|---|---|
kotlin.IllegalArgumentException |
if the |
Public properties
credentialJson
val credentialJson: String
the digital credential in the JSON format; the latest format is defined at https://wicg.github.io/digital-credentials/#the-digitalcredential-interface