SDJWT
@hyperledger/identus-sdk v8.0.0
@hyperledger/identus-sdk / overview / SDJWT
Class: SDJWT
Defined in: packages/lib/sdk/src/pollux/utils/jwt/SDJWT.ts:32
Extends
Runner
Constructors
Constructor
new SDJWT():
SDJWT
Returns
SDJWT
Inherited from
Task.Runner.constructor
Methods
clone()
clone():
SDJWT
Defined in: packages/lib/sdk/src/pollux/utils/jwt/SDJWT.ts:33
Returns
SDJWT
Overrides
Task.Runner.clone
createPresentationFor()
createPresentationFor<
T>(options: {jws:string;kb?:KBOptions;presentationFrame?:PFrame<T>;privateKey:PrivateKey; }):Promise<string>
Defined in: packages/lib/sdk/src/pollux/utils/jwt/SDJWT.ts:125
Type Parameters
| Type Parameter |
|---|
T extends SdJwtVcPayload |
Parameters
| Parameter | Type |
|---|---|
options | { jws: string; kb?: KBOptions; presentationFrame?: PFrame<T>; privateKey: PrivateKey; } |
options.jws | string |
options.kb? | KBOptions |
options.presentationFrame? | PFrame<T> |
options.privateKey | PrivateKey |
Returns
Promise<string>
decode()
decode(
jws:string):DecodedSDJwt
Defined in: packages/lib/sdk/src/pollux/utils/jwt/SDJWT.ts:37
Parameters
| Parameter | Type |
|---|---|
jws | string |
Returns
DecodedSDJwt
getPKConfig()
getPKConfig(
publicKey:PublicKey):SDJWTVCConfig
Defined in: packages/lib/sdk/src/pollux/utils/jwt/SDJWT.ts:150
Parameters
| Parameter | Type |
|---|---|
publicKey | PublicKey |
Returns
SDJWTVCConfig
getSKConfig()
getSKConfig(
privateKey:PrivateKey):SDJWTVCConfig
Defined in: packages/lib/sdk/src/pollux/utils/jwt/SDJWT.ts:184
Parameters
| Parameter | Type |
|---|---|
privateKey | PrivateKey |
Returns
SDJWTVCConfig
reveal()
reveal(
disclosedPayload:Record<string,unknown>,disclosures:Disclosure<unknown>[]):Promise<unknown>
Defined in: packages/lib/sdk/src/pollux/utils/jwt/SDJWT.ts:139
Parameters
| Parameter | Type |
|---|---|
disclosedPayload | Record<string, unknown> |
disclosures | Disclosure<unknown>[] |
Returns
Promise<unknown>
sign()
sign<
E>(options: {disclosureFrame:DisclosureFrame<E>;issuerDID:DID;kid?:string;payload:E;privateKey?:PrivateKey;purpose?:"ISSUING_KEY"|"AUTHENTICATION_KEY"; }):Promise<string>
Defined in: packages/lib/sdk/src/pollux/utils/jwt/SDJWT.ts:41
Type Parameters
| Type Parameter |
|---|
E extends SdJwtVcPayload |
Parameters
| Parameter | Type |
|---|---|
options | { disclosureFrame: DisclosureFrame<E>; issuerDID: DID; kid?: string; payload: E; privateKey?: PrivateKey; purpose?: "ISSUING_KEY" | "AUTHENTICATION_KEY"; } |
options.disclosureFrame | DisclosureFrame<E> |
options.issuerDID | DID |
options.kid? | string |
options.payload | E |
options.privateKey? | PrivateKey |
options.purpose? | "ISSUING_KEY" | "AUTHENTICATION_KEY" |
Returns
Promise<string>
verify()
verify(
options: {issuerDID:DID;jws:string;requiredClaimKeys?:string[];requiredKeyBindings?:boolean; }):Promise<boolean>
Defined in: packages/lib/sdk/src/pollux/utils/jwt/SDJWT.ts:59
Parameters
| Parameter | Type |
|---|---|
options | { issuerDID: DID; jws: string; requiredClaimKeys?: string[]; requiredKeyBindings?: boolean; } |
options.issuerDID | DID |
options.jws | string |
options.requiredClaimKeys? | string[] |
options.requiredKeyBindings? | boolean |
Returns
Promise<boolean>
withContext()
withContext(
ctx:ContextProxy):Runner
Defined in: packages/lib/sdk/src/utils/tasks.ts:108
Parameters
| Parameter | Type |
|---|---|
ctx | ContextProxy |
Returns
Runner
Inherited from
Task.Runner.withContext