import type { DidDocumentService } from './service'; import { Key } from '../../../crypto/Key'; import { IndyAgentService, DidCommV1Service } from './service'; import { VerificationMethod } from './verificationMethod'; export type DidPurpose = 'authentication' | 'keyAgreement' | 'assertionMethod' | 'capabilityInvocation' | 'capabilityDelegation'; interface DidDocumentOptions { context?: string | string[]; id: string; alsoKnownAs?: string[]; controller?: string[]; verificationMethod?: VerificationMethod[]; service?: DidDocumentService[]; authentication?: Array; assertionMethod?: Array; keyAgreement?: Array; capabilityInvocation?: Array; capabilityDelegation?: Array; } export declare class DidDocument { context: string | string[]; id: string; alsoKnownAs?: string[]; controller?: string | string[]; verificationMethod?: VerificationMethod[]; service?: DidDocumentService[]; authentication?: Array; assertionMethod?: Array; keyAgreement?: Array; capabilityInvocation?: Array; capabilityDelegation?: Array; constructor(options: DidDocumentOptions); dereferenceVerificationMethod(keyId: string): VerificationMethod; dereferenceKey(keyId: string, allowedPurposes?: DidPurpose[]): VerificationMethod; /** * Returns all of the service endpoints matching the given type. * * @param type The type of service(s) to query. */ getServicesByType(type: string): S[]; /** * Returns all of the service endpoints matching the given class * * @param classType The class to query services. */ getServicesByClassType(classType: new (...args: never[]) => S): S[]; /** * Get all DIDComm services ordered by priority descending. This means the highest * priority will be the first entry. */ get didCommServices(): Array; get recipientKeys(): Key[]; toJSON(): Record; } export declare function keyReferenceToKey(didDocument: DidDocument, keyId: string): Key; /** * Extracting the verification method for signature type * @param type Signature type * @param didDocument DidDocument * @returns verification method */ export declare function findVerificationMethodByKeyType(keyType: string, didDocument: DidDocument): Promise; export {};