create

fun <T> create(type: String? = null, issuer: String, subject: String, data: T, issuanceDate: Date = Date(), expirationDate: Date? = null, credentialStatus: <Error class: unknown class>? = null, credentialSchema: CredentialSchema? = null, evidence: List<Any>? = null): VerifiableCredential

Create a VerifiableCredential based on the provided parameters.

Return

A VerifiableCredential instance.

Example:

val vc = VerifiableCredential.create("ExampleCredential", "http://example.com/issuers/1", "http://example.com/subjects/1", myData)

Parameters

type

The type of the credential, as a String.

issuer

The issuer URI of the credential, as a String.

subject

The subject URI of the credential, as a String.

data

The credential data, as a generic type T.

issuanceDate

Optional date to set in the issuanceDate property of the credential.

expirationDate

Optional date to set in the expirationDate property of the credential.

evidence

Optional evidence property that gives additional supporting data