UNPKG

@credo-ts/core

Version:

<p align="center"> <br /> <img alt="Credo Logo" src="https://github.com/openwallet-foundation/credo-ts/blob/c7886cb8377ceb8ee4efe8d264211e561a75072d/images/credo-logo.png" height="250px" /> </p> <h1 align="center"><b>Credo - Core</b></h1

56 lines (55 loc) • 1.85 kB
import { KnownJwaSignatureAlgorithm } from "../kms/jwk/jwa.mjs"; import { ClaimFormat } from "../vc/models/ClaimFormat.mjs"; import { MdocNameSpaces, MdocSignOptions, MdocVerifyOptions } from "./MdocOptions.mjs"; import "../vc/index.mjs"; import { PublicJwk } from "../kms/jwk/PublicJwk.mjs"; import "../kms/index.mjs"; import { AgentContext } from "../../agent/context/AgentContext.mjs"; import "../../agent/index.mjs"; import { IssuerSigned } from "@owf/mdoc"; //#region src/modules/mdoc/Mdoc.d.ts /** * This class represents a IssuerSigned Mdoc Document, * which are the actual credentials being issued to holders. */ declare class Mdoc { #private; issuerSigned: IssuerSigned; get base64Url(): string; constructor(issuerSigned: IssuerSigned); /** * claim format is convenience method added to all credential instances */ get claimFormat(): ClaimFormat.MsoMdoc; /** * Encoded is convenience method added to all credential instances */ get encoded(): string; /** * Get the device key to which the mdoc is bound */ get deviceKey(): PublicJwk; set deviceKeyId(keyId: string | undefined); get deviceKeyId(): string | undefined; static fromBase64Url(mdocBase64Url: string): Mdoc; get docType(): string; get alg(): KnownJwaSignatureAlgorithm; get validityInfo(): { signed: Date; validFrom: Date; validUntil: Date; }; get issuerSignedCertificateChain(): Uint8Array<ArrayBufferLike>[]; get signingCertificate(): Uint8Array<ArrayBufferLike>; get issuerSignedNamespaces(): MdocNameSpaces; static sign(agentContext: AgentContext, options: MdocSignOptions): Promise<Mdoc>; verify(agentContext: AgentContext, options?: MdocVerifyOptions): Promise<{ isValid: true; } | { isValid: false; error: string; }>; } //#endregion export { Mdoc }; //# sourceMappingURL=Mdoc.d.mts.map