TrustedDevice

@Serializable(with = TrustedDeviceSerializer::class)
data class TrustedDevice

A biometric-gated trusted-device credential associated with a user.

Trusted devices allow users to sign in with device biometrics instead of their regular first factor. The private key used to sign server challenges never leaves the device.

Constructors

Link copied to clipboard
constructor(id: String, platform: TrustedDevice.Platform = Platform.UNKNOWN, appIdentifier: String, name: String? = null, algorithm: String = ES256_ALGORITHM, status: TrustedDevice.Status = Status.UNKNOWN, createdAt: Long, updatedAt: Long, lastUsedAt: Long? = null, revokedAt: Long? = null)

Types

Link copied to clipboard
object Companion
Link copied to clipboard
@Serializable
enum Platform : Enum<TrustedDevice.Platform>

The platform a trusted-device credential belongs to.

Link copied to clipboard
@Serializable
enum Status : Enum<TrustedDevice.Status>

The server-side trusted-device credential status.

Properties

Link copied to clipboard

The signature algorithm used by the credential.

Link copied to clipboard
@SerialName(value = "app_identifier")
val appIdentifier: String

The native app identifier this credential is bound to.

Link copied to clipboard
@SerialName(value = "created_at")
val createdAt: Long

The time when the credential was created, in milliseconds since epoch.

Link copied to clipboard
val id: String

The unique identifier of the trusted-device credential.

Link copied to clipboard
@SerialName(value = "last_used_at")
val lastUsedAt: Long?

The time when the credential was last used, in milliseconds since epoch.

Link copied to clipboard
val name: String?

The user-facing credential name.

Link copied to clipboard

The platform this credential belongs to.

Link copied to clipboard

The platform value exactly as returned by the Clerk API.

Link copied to clipboard
@SerialName(value = "revoked_at")
val revokedAt: Long?

The time when the credential was revoked, in milliseconds since epoch.

Link copied to clipboard

The credential status.

Link copied to clipboard

The status value exactly as returned by the Clerk API.

Link copied to clipboard
@SerialName(value = "updated_at")
val updatedAt: Long

The time when the credential was last updated, in milliseconds since epoch.

Functions

Link copied to clipboard
fun copy(id: String = this.id, platform: TrustedDevice.Platform = this.platform, appIdentifier: String = this.appIdentifier, name: String? = this.name, algorithm: String = this.algorithm, status: TrustedDevice.Status = this.status, createdAt: Long = this.createdAt, updatedAt: Long = this.updatedAt, lastUsedAt: Long? = this.lastUsedAt, revokedAt: Long? = this.revokedAt): TrustedDevice