@twin.org/identity-cli 0.0.3-next.19 → 0.0.3-next.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/es/cli.js +9 -1
- package/dist/es/cli.js.map +1 -1
- package/dist/es/commands/alsoKnownAsAdd.js +108 -0
- package/dist/es/commands/alsoKnownAsAdd.js.map +1 -0
- package/dist/es/commands/alsoKnownAsRemove.js +106 -0
- package/dist/es/commands/alsoKnownAsRemove.js.map +1 -0
- package/dist/es/commands/verifiableCredentialCreate.js +10 -7
- package/dist/es/commands/verifiableCredentialCreate.js.map +1 -1
- package/dist/es/commands/verifiableCredentialVerify.js +24 -5
- package/dist/es/commands/verifiableCredentialVerify.js.map +1 -1
- package/dist/es/commands/verifiablePresentationCreate.js +137 -0
- package/dist/es/commands/verifiablePresentationCreate.js.map +1 -0
- package/dist/es/commands/verifiablePresentationVerify.js +107 -0
- package/dist/es/commands/verifiablePresentationVerify.js.map +1 -0
- package/dist/es/index.js +2 -0
- package/dist/es/index.js.map +1 -1
- package/dist/locales/en.json +142 -2
- package/dist/types/commands/alsoKnownAsAdd.d.ts +30 -0
- package/dist/types/commands/alsoKnownAsRemove.d.ts +30 -0
- package/dist/types/commands/verifiableCredentialCreate.d.ts +2 -2
- package/dist/types/commands/verifiableCredentialVerify.d.ts +3 -1
- package/dist/types/commands/verifiablePresentationCreate.d.ts +32 -0
- package/dist/types/commands/verifiablePresentationVerify.d.ts +24 -0
- package/dist/types/index.d.ts +2 -0
- package/docs/changelog.md +15 -0
- package/docs/reference/functions/actionCommandVerifiablePresentationCreate.md +17 -0
- package/docs/reference/functions/actionCommandVerifiablePresentationVerify.md +17 -0
- package/docs/reference/functions/buildCommandVerifiablePresentationCreate.md +11 -0
- package/docs/reference/functions/buildCommandVerifiablePresentationVerify.md +11 -0
- package/docs/reference/index.md +4 -0
- package/locales/en.json +142 -2
- package/package.json +3 -3
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { type CliOutputOptions } from "@twin.org/cli-core";
|
|
2
|
+
import { Command } from "commander";
|
|
3
|
+
import { IdentityConnectorTypes } from "../models/identityConnectorTypes.js";
|
|
4
|
+
/**
|
|
5
|
+
* Build the verifiable presentation verify command for the CLI.
|
|
6
|
+
* @returns The command.
|
|
7
|
+
*/
|
|
8
|
+
export declare function buildCommandVerifiablePresentationVerify(): Command;
|
|
9
|
+
/**
|
|
10
|
+
* Action the verifiable presentation verify command.
|
|
11
|
+
* @param opts The options for the command.
|
|
12
|
+
* @param opts.jwt The JSON web token for the verifiable presentation.
|
|
13
|
+
* @param opts.jsonLd The filename of a JSON-LD verifiable presentation to verify.
|
|
14
|
+
* @param opts.connector The connector to perform the operations with.
|
|
15
|
+
* @param opts.node The node URL.
|
|
16
|
+
* @param opts.network The network name.
|
|
17
|
+
*/
|
|
18
|
+
export declare function actionCommandVerifiablePresentationVerify(opts: {
|
|
19
|
+
jwt?: string;
|
|
20
|
+
jsonLd?: string;
|
|
21
|
+
connector?: IdentityConnectorTypes;
|
|
22
|
+
node: string;
|
|
23
|
+
network?: string;
|
|
24
|
+
} & CliOutputOptions): Promise<void>;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -7,6 +7,8 @@ export * from "./commands/serviceAdd.js";
|
|
|
7
7
|
export * from "./commands/serviceRemove.js";
|
|
8
8
|
export * from "./commands/setupCommands.js";
|
|
9
9
|
export * from "./commands/verifiableCredentialCreate.js";
|
|
10
|
+
export * from "./commands/verifiablePresentationCreate.js";
|
|
11
|
+
export * from "./commands/verifiablePresentationVerify.js";
|
|
10
12
|
export * from "./commands/verifiableCredentialRevoke.js";
|
|
11
13
|
export * from "./commands/verifiableCredentialUnrevoke.js";
|
|
12
14
|
export * from "./commands/verifiableCredentialVerify.js";
|
package/docs/changelog.md
CHANGED
|
@@ -1,5 +1,20 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.0.3-next.20](https://github.com/twinfoundation/twin-identity/compare/identity-cli-v0.0.3-next.19...identity-cli-v0.0.3-next.20) (2026-04-29)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* expanded cli methods ([#121](https://github.com/twinfoundation/twin-identity/issues/121)) ([80a52b7](https://github.com/twinfoundation/twin-identity/commit/80a52b779237cd633d1f2813fa976585cef6e551))
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Dependencies
|
|
12
|
+
|
|
13
|
+
* The following workspace dependencies were updated
|
|
14
|
+
* dependencies
|
|
15
|
+
* @twin.org/identity-models bumped from 0.0.3-next.19 to 0.0.3-next.20
|
|
16
|
+
* @twin.org/identity-connector-iota bumped from 0.0.3-next.19 to 0.0.3-next.20
|
|
17
|
+
|
|
3
18
|
## [0.0.3-next.19](https://github.com/twinfoundation/twin-identity/compare/identity-cli-v0.0.3-next.18...identity-cli-v0.0.3-next.19) (2026-04-29)
|
|
4
19
|
|
|
5
20
|
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Function: actionCommandVerifiablePresentationCreate()
|
|
2
|
+
|
|
3
|
+
> **actionCommandVerifiablePresentationCreate**(`opts`): `Promise`\<`void`\>
|
|
4
|
+
|
|
5
|
+
Action the verifiable presentation create command.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### opts
|
|
10
|
+
|
|
11
|
+
`object` & `ICliOutputOptionsConsole` & `ICliOutputOptionsEnv` & `ICliOutputOptionsJson`
|
|
12
|
+
|
|
13
|
+
The options for the command.
|
|
14
|
+
|
|
15
|
+
## Returns
|
|
16
|
+
|
|
17
|
+
`Promise`\<`void`\>
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Function: actionCommandVerifiablePresentationVerify()
|
|
2
|
+
|
|
3
|
+
> **actionCommandVerifiablePresentationVerify**(`opts`): `Promise`\<`void`\>
|
|
4
|
+
|
|
5
|
+
Action the verifiable presentation verify command.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### opts
|
|
10
|
+
|
|
11
|
+
`object` & `ICliOutputOptionsConsole` & `ICliOutputOptionsEnv` & `ICliOutputOptionsJson`
|
|
12
|
+
|
|
13
|
+
The options for the command.
|
|
14
|
+
|
|
15
|
+
## Returns
|
|
16
|
+
|
|
17
|
+
`Promise`\<`void`\>
|
package/docs/reference/index.md
CHANGED
|
@@ -39,6 +39,10 @@
|
|
|
39
39
|
- [actionCommandVerifiableCredentialUnrevoke](functions/actionCommandVerifiableCredentialUnrevoke.md)
|
|
40
40
|
- [buildCommandVerifiableCredentialVerify](functions/buildCommandVerifiableCredentialVerify.md)
|
|
41
41
|
- [actionCommandVerifiableCredentialVerify](functions/actionCommandVerifiableCredentialVerify.md)
|
|
42
|
+
- [buildCommandVerifiablePresentationCreate](functions/buildCommandVerifiablePresentationCreate.md)
|
|
43
|
+
- [actionCommandVerifiablePresentationCreate](functions/actionCommandVerifiablePresentationCreate.md)
|
|
44
|
+
- [buildCommandVerifiablePresentationVerify](functions/buildCommandVerifiablePresentationVerify.md)
|
|
45
|
+
- [actionCommandVerifiablePresentationVerify](functions/actionCommandVerifiablePresentationVerify.md)
|
|
42
46
|
- [buildCommandVerificationMethodAdd](functions/buildCommandVerificationMethodAdd.md)
|
|
43
47
|
- [actionCommandVerificationMethodAdd](functions/actionCommandVerificationMethodAdd.md)
|
|
44
48
|
- [buildCommandVerificationMethodRemove](functions/buildCommandVerificationMethodRemove.md)
|
package/locales/en.json
CHANGED
|
@@ -1,6 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"error": {
|
|
3
3
|
"commands": {
|
|
4
|
+
"verifiable-presentation-create": {
|
|
5
|
+
"noCredentialsProvided": "Either --jwt or --json-ld must be provided with at least one credential.",
|
|
6
|
+
"jsonLdFileNotFound": "The JSON-LD credential file was not found."
|
|
7
|
+
},
|
|
8
|
+
"verifiable-credential-verify": {
|
|
9
|
+
"noCredentialProvided": "Either --jwt or --json-ld must be provided.",
|
|
10
|
+
"jsonLdFileNotFound": "The JSON-LD file was not found."
|
|
11
|
+
},
|
|
12
|
+
"verifiable-presentation-verify": {
|
|
13
|
+
"noPresentationProvided": "Either --jwt or --json-ld must be provided.",
|
|
14
|
+
"jsonLdFileNotFound": "The JSON-LD file was not found."
|
|
15
|
+
},
|
|
4
16
|
"verifiable-credential-create": {
|
|
5
17
|
"subjectJsonFileNotFound": "The subject JSON file was not found."
|
|
6
18
|
},
|
|
@@ -185,12 +197,77 @@
|
|
|
185
197
|
"addressIndex": "Address Index"
|
|
186
198
|
}
|
|
187
199
|
},
|
|
200
|
+
"verifiable-presentation-create": {
|
|
201
|
+
"summary": "Create a verifiable presentation.",
|
|
202
|
+
"description": "Create a verifiable presentation.",
|
|
203
|
+
"options": {
|
|
204
|
+
"verification-method-id": {
|
|
205
|
+
"param": "--verification-method-id '<'verification-method-id'>'",
|
|
206
|
+
"description": "The full verification method id including did, or start with ! to read environment variable."
|
|
207
|
+
},
|
|
208
|
+
"private-key": {
|
|
209
|
+
"param": "--private-key '<'private-key'>'",
|
|
210
|
+
"description": "The private key for the verification method id, in either hex or base64 form, or start with ! to read environment variable."
|
|
211
|
+
},
|
|
212
|
+
"presentation-id": {
|
|
213
|
+
"param": "--presentation-id '<'presentation-id'>'",
|
|
214
|
+
"description": "The presentation id which uniquely identifies the presentation."
|
|
215
|
+
},
|
|
216
|
+
"jwt": {
|
|
217
|
+
"param": "--jwt '<'jwt'>'",
|
|
218
|
+
"description": "Comma-separated list of verifiable credential JWTs to include in the presentation, or start with ! to read environment variable."
|
|
219
|
+
},
|
|
220
|
+
"json-ld": {
|
|
221
|
+
"param": "--json-ld '<'json-ld'>'",
|
|
222
|
+
"description": "Comma-separated list of JSON-LD filenames containing verifiable credentials to include in the presentation."
|
|
223
|
+
},
|
|
224
|
+
"expiration-date": {
|
|
225
|
+
"param": "--expiration-date '<'ISO Date'>'",
|
|
226
|
+
"description": "The expiration date for the presentation."
|
|
227
|
+
}
|
|
228
|
+
},
|
|
229
|
+
"progress": {
|
|
230
|
+
"creatingVerifiablePresentation": "Creating Verifiable Presentation",
|
|
231
|
+
"loadingCredentialData": "Loading Credential Data"
|
|
232
|
+
},
|
|
233
|
+
"labels": {
|
|
234
|
+
"verificationMethodId": "Verification Method Id",
|
|
235
|
+
"presentationId": "Presentation Id",
|
|
236
|
+
"jwt": "JWT Credentials",
|
|
237
|
+
"jsonLd": "JSON-LD Credentials",
|
|
238
|
+
"verifiablePresentation": "Verifiable Presentation",
|
|
239
|
+
"expirationDate": "Expiration Date"
|
|
240
|
+
}
|
|
241
|
+
},
|
|
242
|
+
"verifiable-presentation-verify": {
|
|
243
|
+
"summary": "Verify a verifiable presentation.",
|
|
244
|
+
"description": "Verify a verifiable presentation.",
|
|
245
|
+
"options": {
|
|
246
|
+
"jwt": {
|
|
247
|
+
"param": "--jwt '<'jwt'>'",
|
|
248
|
+
"description": "The verifiable presentation as a JSON web token to verify, or start with ! to read environment variable."
|
|
249
|
+
},
|
|
250
|
+
"json-ld": {
|
|
251
|
+
"param": "--json-ld '<'json-ld'>'",
|
|
252
|
+
"description": "A JSON-LD file containing the verifiable presentation to verify."
|
|
253
|
+
}
|
|
254
|
+
},
|
|
255
|
+
"progress": {
|
|
256
|
+
"verifyingPresentation": "Verifying Presentation"
|
|
257
|
+
},
|
|
258
|
+
"labels": {
|
|
259
|
+
"jwt": "JWT",
|
|
260
|
+
"jsonLd": "JSON-LD",
|
|
261
|
+
"isVerified": "Is Verified",
|
|
262
|
+
"isRevoked": "Is Revoked"
|
|
263
|
+
}
|
|
264
|
+
},
|
|
188
265
|
"verifiable-credential-create": {
|
|
189
266
|
"summary": "Create a verifiable credential.",
|
|
190
267
|
"description": "Create a verifiable credential.",
|
|
191
268
|
"options": {
|
|
192
|
-
"id": {
|
|
193
|
-
"param": "--id '<'id'>'",
|
|
269
|
+
"verification-method-id": {
|
|
270
|
+
"param": "--verification-method-id '<'verification-method-id'>'",
|
|
194
271
|
"description": "The full verification method id including did, or start with ! to read environment variable."
|
|
195
272
|
},
|
|
196
273
|
"private-key": {
|
|
@@ -234,6 +311,10 @@
|
|
|
234
311
|
"jwt": {
|
|
235
312
|
"param": "--jwt '<'jwt'>'",
|
|
236
313
|
"description": "The verifiable credential as a JSON web token to verify, or start with ! to read environment variable."
|
|
314
|
+
},
|
|
315
|
+
"json-ld": {
|
|
316
|
+
"param": "--json-ld '<'json-ld'>'",
|
|
317
|
+
"description": "A JSON-LD file containing the verifiable credential to verify."
|
|
237
318
|
}
|
|
238
319
|
},
|
|
239
320
|
"progress": {
|
|
@@ -241,6 +322,7 @@
|
|
|
241
322
|
},
|
|
242
323
|
"labels": {
|
|
243
324
|
"jwt": "JWT",
|
|
325
|
+
"jsonLd": "JSON-LD",
|
|
244
326
|
"isVerified": "Is Verified",
|
|
245
327
|
"isRevoked": "Is Revoked"
|
|
246
328
|
}
|
|
@@ -350,6 +432,64 @@
|
|
|
350
432
|
"isVerified": "Is Verified"
|
|
351
433
|
}
|
|
352
434
|
},
|
|
435
|
+
"also-known-as-add": {
|
|
436
|
+
"summary": "Add an alias (alsoKnownAs) to a DID.",
|
|
437
|
+
"description": "Add an alias (alsoKnownAs) to a DID.",
|
|
438
|
+
"options": {
|
|
439
|
+
"seed": {
|
|
440
|
+
"param": "--seed '<'seed'>'",
|
|
441
|
+
"description": "The seed for the private key for the controller address of the document in hex or base64, or start with ! to read environment variable."
|
|
442
|
+
},
|
|
443
|
+
"did": {
|
|
444
|
+
"param": "--did '<'did'>'",
|
|
445
|
+
"description": "The identifier to add the alias to, or start with ! to read environment variable."
|
|
446
|
+
},
|
|
447
|
+
"alias": {
|
|
448
|
+
"param": "--alias '<'alias'>'",
|
|
449
|
+
"description": "The alias (alsoKnownAs) value to add."
|
|
450
|
+
},
|
|
451
|
+
"addressIndex": {
|
|
452
|
+
"param": "--address-index '<'index'>'",
|
|
453
|
+
"description": "The address index to use for the identity controller."
|
|
454
|
+
}
|
|
455
|
+
},
|
|
456
|
+
"progress": {
|
|
457
|
+
"addingAlsoKnownAs": "Adding Alias (alsoKnownAs)"
|
|
458
|
+
},
|
|
459
|
+
"labels": {
|
|
460
|
+
"alias": "Alias (alsoKnownAs)",
|
|
461
|
+
"addressIndex": "Address Index"
|
|
462
|
+
}
|
|
463
|
+
},
|
|
464
|
+
"also-known-as-remove": {
|
|
465
|
+
"summary": "Remove an alias (alsoKnownAs) from a DID.",
|
|
466
|
+
"description": "Remove an alias (alsoKnownAs) from a DID.",
|
|
467
|
+
"options": {
|
|
468
|
+
"seed": {
|
|
469
|
+
"param": "--seed '<'seed'>'",
|
|
470
|
+
"description": "The seed for the private key for the controller address of the document in hex or base64, or start with ! to read environment variable."
|
|
471
|
+
},
|
|
472
|
+
"did": {
|
|
473
|
+
"param": "--did '<'did'>'",
|
|
474
|
+
"description": "The identifier to remove the alias from, or start with ! to read environment variable."
|
|
475
|
+
},
|
|
476
|
+
"alias": {
|
|
477
|
+
"param": "--alias '<'alias'>'",
|
|
478
|
+
"description": "The alias (alsoKnownAs) value to remove."
|
|
479
|
+
},
|
|
480
|
+
"addressIndex": {
|
|
481
|
+
"param": "--address-index '<'index'>'",
|
|
482
|
+
"description": "The address index to use for the identity controller."
|
|
483
|
+
}
|
|
484
|
+
},
|
|
485
|
+
"progress": {
|
|
486
|
+
"removingAlsoKnownAs": "Removing Alias (alsoKnownAs)"
|
|
487
|
+
},
|
|
488
|
+
"labels": {
|
|
489
|
+
"alias": "Alias (alsoKnownAs)",
|
|
490
|
+
"addressIndex": "Address Index"
|
|
491
|
+
}
|
|
492
|
+
},
|
|
353
493
|
"common": {
|
|
354
494
|
"options": {
|
|
355
495
|
"connector": {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@twin.org/identity-cli",
|
|
3
|
-
"version": "0.0.3-next.
|
|
3
|
+
"version": "0.0.3-next.20",
|
|
4
4
|
"description": "Command line tool for running identity workflows in local development and automation pipelines.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
"@twin.org/data-json-ld": "next",
|
|
22
22
|
"@twin.org/entity": "next",
|
|
23
23
|
"@twin.org/entity-storage-connector-memory": "next",
|
|
24
|
-
"@twin.org/identity-connector-iota": "0.0.3-next.
|
|
25
|
-
"@twin.org/identity-models": "0.0.3-next.
|
|
24
|
+
"@twin.org/identity-connector-iota": "0.0.3-next.20",
|
|
25
|
+
"@twin.org/identity-models": "0.0.3-next.20",
|
|
26
26
|
"@twin.org/nameof": "next",
|
|
27
27
|
"@twin.org/standards-w3c-did": "next",
|
|
28
28
|
"@twin.org/vault-connector-entity-storage": "next",
|