Package-level declarations

Types

Link copied to clipboard
data class AnoncredsInputFieldFilter(val type: String, val name: String, val gt: Any? = null, val gte: Any? = null, val lt: Any? = null, val lte: Any? = null)
Link copied to clipboard
interface Api

Interface that defines an API request

Link copied to clipboard
open class ApiImpl(var client: HttpClient) : Api

Implementation of API interface for http requests.

Link copied to clipboard

A class representing a known error in an Apollo.

Link copied to clipboard

The AttachmentData interface represents a generic attachment for a DIDComm Message. Any type that conforms to AttachmentData can be used as an attachment.

Link copied to clipboard

The AttachmentDataSerializer is responsible for serializing and deserializing instances of AttachmentData.

Link copied to clipboard
data class AttachmentDescriptor @JvmOverloads constructor(val id: String = UUID.randomUUID().toString(), val mediaType: String? = null, val data: AttachmentData, val filename: Array<String>? = null, val format: String? = null, val lastModTime: String? = null, val byteCount: Int? = null, val description: String? = null)

The AttachmentDescriptor data class represents metadata for a DIDComm attachment.

Link copied to clipboard

A class representing a known error in a Castor.

Link copied to clipboard
class Claim(val key: String, val value: ClaimType)

Represents a claim in a verifiable credential.

Link copied to clipboard

A sealed class representing different types of claims.

Link copied to clipboard

A class representing a common error in a PRISM.

Link copied to clipboard
data class CompressedPublicKey(val uncompressed: PublicKey, val value: ByteArray)

Represents a compressed public key and its uncompressed version.

Link copied to clipboard
interface Credential

Represents a verifiable credential that contains information about an entity or identity.

Link copied to clipboard
data class CredentialIssueOptions(val type: CredentialType, val linkSecret: String? = null)

Represents the options for issuing credentials.

Link copied to clipboard
Link copied to clipboard

Enum class representing different types of verifiable credentials. The CredentialType is used to indicate the type of verifiable credential. The possible values of the enum are jwt, w3c, and unknown.

Link copied to clipboard

Enumeration representing supported key curves.

Link copied to clipboard
data class DID @JvmOverloads constructor(val schema: String = DID, val method: String, val methodId: String, val alias: String? = null)

A DID is a unique and persistent identifier for a subject or object, such as a person, organization, or device. It is created and managed using a specific DID method, and consists of a schema, method, and method ID. The schema indicates the type of DID (e.g. "did"), the method indicates the specific interface or process used to resolve and manage the DID (e.g. "prism"), and the method ID is a unique identifier within the DID method. As specified in the W3C DID standards.

Link copied to clipboard
data class DIDDocument(val id: DID, val coreProperties: Array<DIDDocumentCoreProperty>)

Represents a DIDDocument with DID and DIDDocumentCoreProperty As specified in w3 standards A DID Document consists of a DID, public keys, authentication protocols, service endpoints, and other metadata. It is used to verify the authenticity and identity of the DID, and to discover and interact with the associated subjects or objects.

Link copied to clipboard

Represents a Core Property in a DID Document. This allows for extensibility of the properties. As specified in w3 standards

Link copied to clipboard
data class DIDPair(val holder: DID, val receiver: DID, val name: String?)

Represents a pair of DIDs, typically used for secure communication or delegation of capabilities or services.

Link copied to clipboard
interface DIDResolver

The DIDResolver protocol defines the interface for resolving DID document using a specific DID method. Implementations of this interface provide a resolve method that can be used to retrieve the DID document for a given DID.

Link copied to clipboard
data class DIDUrl @JvmOverloads constructor(val did: DID, val path: Array<String>? = arrayOf(), val parameters: Map<String, String>? = mapOf(), val fragment: String? = null)

Represents a DIDUrl with "did", "path", "parameters", "fragment" As specified in w3 standards

Link copied to clipboard
interface Error

An interface that represents a base error in the Prism SDK.

Link copied to clipboard
data class HttpResponse(val status: Int, val jsonString: JsonString)

Represents an HTTP response.

Link copied to clipboard
data class InputFieldFilter constructor(val type: String, val pattern: String? = null, val enum: List<Any>? = null, val const: List<Any>? = null, val value: Any? = null)
Link copied to clipboard

Custom serializer for InputFieldFilter. Used to serialized List contained by InputFieldFilter.

Link copied to clipboard
typealias JsonString = String

Alias for a JSON string.

Link copied to clipboard
interface JWTPayload
Link copied to clipboard
data class JWTPresentationClaims(val schema: String? = null, val issuer: String? = null, val claims: Map<String, InputFieldFilter>) : PresentationClaims
Link copied to clipboard
data class JWTVerifiableCredential constructor(val context: Array<String> = arrayOf(), val type: Array<String> = arrayOf(), val credentialSchema: VerifiableCredentialTypeContainer? = null, val credentialSubject: Map<String, String>, val credentialStatus: JWTVerifiableCredential.CredentialStatus? = null, val refreshService: VerifiableCredentialTypeContainer? = null, val evidence: VerifiableCredentialTypeContainer? = null, val termsOfUse: VerifiableCredentialTypeContainer? = null)

A struct representing the verifiable credential in a JWT credential payload.

Link copied to clipboard
data class JWTVerifiablePresentation(val context: Array<String>, val type: Array<String>, val verifiableCredential: Array<String>)
Link copied to clipboard
data class KeyCurve constructor(val curve: Curve, val index: Int? = 0)

Data class representing supported key curves for key generation.

Link copied to clipboard
data class KeyValue(val key: String, val value: String)

Represents a key-value pair.

Link copied to clipboard
abstract class KnownPrismError constructor(message: String? = null, cause: Throwable? = null) : Throwable, Error

A class representing a known error in a PRISM.

Link copied to clipboard
data class Mediator(val id: String = UUID.randomUUID().toString(), val mediatorDID: DID, val hostDID: DID, val routingDID: DID)

Mediator is a data class that represents a mediator entity. It contains the mediator's ID, mediator DID, host DID, and routing DID.

Link copied to clipboard

A class representing a known error in a Mercury.

Link copied to clipboard
data class Message @JvmOverloads constructor(val id: String = UUID.randomUUID().toString(), val piuri: String, val from: DID? = null, val to: DID? = null, val fromPrior: String? = null, val body: String, val extraHeaders: Map<String, String> = emptyMap(), val createdTime: String = Clock.System.now().epochSeconds.toString(), val expiresTimePlus: String = Clock.System.now().plus(1.days).epochSeconds.toString(), val attachments: Array<AttachmentDescriptor> = arrayOf(), val thid: String? = null, val pthid: String? = null, val ack: Array<String>? = emptyArray(), val direction: Message.Direction = Direction.RECEIVED)

The Message data class represents a DIDComm message, which is used for secure, decentralized communication in the Atala PRISM architecture. A Message object includes information about the sender, recipient, message body, and other metadata. Message objects are typically exchanged between DID controllers using the Mercury building block.

Link copied to clipboard
data class NonRevoked(val from: Long, val to: Long)
Link copied to clipboard
data class PeerDID(val did: DID, val privateKeys: Array<out PrivateKey>)

Represents a PeerDID, which is used as a unique and persistent identifier for a subject or object. It consists of a DID and an array of PrivateKeys.

Link copied to clipboard
actual object Platform

The Platform object represents the platform on which the code is running.

expect object Platform

The Platform class provides information about the current platform.

actual object Platform
Link copied to clipboard

Represents the type of platform.

Link copied to clipboard

A class representing a known error in a Pluto.

Link copied to clipboard

A class representing a known error in a Pollux.

Link copied to clipboard
sealed interface PresentationClaims
Link copied to clipboard
data class PrismDIDInfo(val did: DID, val keyPathIndex: Int? = 0, val alias: String? = null)

A data class representing a conjunction of DID, keyPathIndex and alias.

Link copied to clipboard
Link copied to clipboard
data class PublicKey(val curve: KeyCurve, val value: ByteArray)

Represents a public key with a specific key curve and value.

Link copied to clipboard
data class RequestedAttributes(val name: String, val names: Set<String>, val restrictions: Map<String, String>, val nonRevoked: NonRevoked?)
Link copied to clipboard
data class RequestedPredicates(val name: String, val pType: String, val pValue: Int, val restrictions: Map<String, String>, val nonRevoked: NonRevoked?)
Link copied to clipboard
data class Secret(val id: String, val type: SecretType, val secretMaterial: SecretMaterialJWK)

Represents a secret, which is a piece of secret material and its type.

Link copied to clipboard
data class SecretMaterialJWK(val value: String)

Represents a secret material in the form of a JSON Web Key (JWK).

Link copied to clipboard
interface SecretResolver

Interface for resolving secrets by their ID.

Link copied to clipboard

Represents a type of secret.

Link copied to clipboard
data class Seed(val value: ByteArray)

Represents a seed used for key generation.

Link copied to clipboard
data class SeedWords(val mnemonics: Array<String>, val seed: Seed)

Represents a set of seed words along with the corresponding seed object.

Link copied to clipboard
data class Session @JvmOverloads constructor(val uuid: <Error class: unknown class> = UUID.randomUUID(), val seed: Seed)

Represents a session between two entities.

Link copied to clipboard
data class Signature(val value: ByteArray)

Represents a digital signature.

Link copied to clipboard

Represents a storable credential that can be stored and retrieved from a storage system.

Link copied to clipboard
abstract class UnknownError constructor(message: String? = null, cause: Throwable? = null) : UnknownPrismError

A class representing an unknown error if the error received does not conform to the KnownPrismError, it will be classified as an UnknownPrismError.

Link copied to clipboard
abstract class UnknownPrismError constructor(message: String? = null, cause: Throwable? = null) : Throwable, Error

A class representing an unknown error in a PRISM.

Link copied to clipboard

Interface for objects representing verifiable credentials.

Link copied to clipboard

A data class representing a container for verifiable credential types. This data class is used to encode and decode verifiable credential types for use with JSON. The VerifiableCredentialTypeContainer contains properties for the ID and type of the verifiable credential. ::: info The VerifiableCredentialTypeContainer is used to encode and decode verifiable credential types for use with JSON. :::

Functions

Link copied to clipboard

Retrieves the direction of a message based on the given value.

Link copied to clipboard
actual fun httpClient(config: HttpClientConfig<*>.() -> Unit): HttpClient

Creates an HTTP client with the specified configuration.

expect fun httpClient(config: HttpClientConfig<*>.() -> Unit = {}): HttpClient

Creates a new instance of HttpClient with the given configuration.

actual fun httpClient(config: HttpClientConfig<*>.() -> Unit): HttpClient