@sphereon/pex
Version:
A Typescript implementation of the v1 and v2 DIF Presentation Exchange specification
14 lines (13 loc) • 1.04 kB
TypeScript
import { ICredential, SdJwtDecodedVerifiableCredential } from '@sphereon/ssi-types';
import { DiscoveredVersion, IPresentationDefinition } from '../types';
import { ValidationError } from '../validation/validators';
export declare function getSubjectIdsAsString(vc: ICredential | SdJwtDecodedVerifiableCredential): string[];
export declare function getIssuerString(vc: ICredential | SdJwtDecodedVerifiableCredential): string;
export declare function definitionVersionDiscovery(presentationDefinition: IPresentationDefinition): DiscoveredVersion;
export declare function formatValidationError(error: ValidationError): string;
export declare function formatValidationErrors(errors: ValidationError[] | undefined): string | undefined;
export declare function uniformDIDMethods(dids?: string[], opts?: {
removePrefix: 'did:';
}): string[];
export declare function isRestrictedDID(DID: string, restrictToDIDMethods: string[]): boolean;
export declare function filterToRestrictedDIDs(DIDs: string[], restrictToDIDMethods: string[]): string[];