importMpzPass

suspend fun importMpzPass(mpzPass: MpzPass, isoMdocDomain: String = "mdoc", sdJwtVcDomain: String = "sdjwtvc", keylessSdJwtVcDomain: String = "sdjwtvc_keyless"): Document

Imports a MpzPass into a DocumentStore.

The returned document will have the Document.provisioned flag set to true and Document.mpzPassId will be set to MpzPass.uniqueId.

If the pass had been previously imported, the same Document will be returned and the credentials will be updated.

Return

An existing Document if updating, otherwise a newly created Document. In both cases the returned document will have the credentials included in mpzPass.

Parameters

mpzPass

The MpzPass to import.

isoMdocDomain

The domain string to use when creating ISO mdoc credentials.

sdJwtVcDomain

The domain string to use when creating SD-JWT VC credentials.

keylessSdJwtVcDomain

the domain string to use when creating keyless SD-JWT VC credentials.

Throws

if a SoftwareSecureArea implementation cannot be found in the repository.

if credential creation or certification fails.