@twin.org/identity-cli 0.0.3-next.2 → 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.
Files changed (49) hide show
  1. package/README.md +5 -5
  2. package/dist/es/cli.js +9 -1
  3. package/dist/es/cli.js.map +1 -1
  4. package/dist/es/commands/alsoKnownAsAdd.js +108 -0
  5. package/dist/es/commands/alsoKnownAsAdd.js.map +1 -0
  6. package/dist/es/commands/alsoKnownAsRemove.js +106 -0
  7. package/dist/es/commands/alsoKnownAsRemove.js.map +1 -0
  8. package/dist/es/commands/identityCreate.js +2 -1
  9. package/dist/es/commands/identityCreate.js.map +1 -1
  10. package/dist/es/commands/proofCreate.js +4 -9
  11. package/dist/es/commands/proofCreate.js.map +1 -1
  12. package/dist/es/commands/serviceAdd.js +4 -3
  13. package/dist/es/commands/serviceAdd.js.map +1 -1
  14. package/dist/es/commands/serviceRemove.js +3 -3
  15. package/dist/es/commands/serviceRemove.js.map +1 -1
  16. package/dist/es/commands/verifiableCredentialCreate.js +18 -16
  17. package/dist/es/commands/verifiableCredentialCreate.js.map +1 -1
  18. package/dist/es/commands/verifiableCredentialVerify.js +24 -5
  19. package/dist/es/commands/verifiableCredentialVerify.js.map +1 -1
  20. package/dist/es/commands/verifiablePresentationCreate.js +137 -0
  21. package/dist/es/commands/verifiablePresentationCreate.js.map +1 -0
  22. package/dist/es/commands/verifiablePresentationVerify.js +107 -0
  23. package/dist/es/commands/verifiablePresentationVerify.js.map +1 -0
  24. package/dist/es/commands/verificationMethodAdd.js +31 -10
  25. package/dist/es/commands/verificationMethodAdd.js.map +1 -1
  26. package/dist/es/index.js +2 -0
  27. package/dist/es/index.js.map +1 -1
  28. package/dist/locales/en.json +196 -38
  29. package/dist/types/commands/alsoKnownAsAdd.d.ts +30 -0
  30. package/dist/types/commands/alsoKnownAsRemove.d.ts +30 -0
  31. package/dist/types/commands/identityCreate.d.ts +1 -0
  32. package/dist/types/commands/proofCreate.d.ts +0 -2
  33. package/dist/types/commands/verifiableCredentialCreate.d.ts +4 -4
  34. package/dist/types/commands/verifiableCredentialVerify.d.ts +3 -1
  35. package/dist/types/commands/verifiablePresentationCreate.d.ts +32 -0
  36. package/dist/types/commands/verifiablePresentationVerify.d.ts +24 -0
  37. package/dist/types/index.d.ts +2 -0
  38. package/docs/changelog.md +404 -90
  39. package/docs/reference/classes/CLI.md +1 -1
  40. package/docs/reference/functions/actionCommandVerifiablePresentationCreate.md +17 -0
  41. package/docs/reference/functions/actionCommandVerifiablePresentationVerify.md +17 -0
  42. package/docs/reference/functions/buildCommandVerifiablePresentationCreate.md +11 -0
  43. package/docs/reference/functions/buildCommandVerifiablePresentationVerify.md +11 -0
  44. package/docs/reference/index.md +4 -0
  45. package/docs/reference/variables/IdentityConnectorTypes.md +1 -1
  46. package/docs/reference/variables/IdentityResolverConnectorTypes.md +1 -1
  47. package/docs/{examples.md → usage.md} +23 -27
  48. package/locales/en.json +153 -12
  49. package/package.json +5 -5
@@ -47,9 +47,9 @@
47
47
  "atLeastOneNumber": "The value should contain at least one number",
48
48
  "atLeastOneSpecialChar": "The value should contain at least one symbol",
49
49
  "schema": {
50
- "failedValidation": "The JSON schema failed validation, {message}",
51
50
  "missingType": "Failed to validate as there is no handler for type \"{dataType}\""
52
- }
51
+ },
52
+ "schemaFailed": "Schema failed validation, \"{message}\", keyword: \"{keyword}\", schemaPath: \"{schemaPath}\""
53
53
  },
54
54
  "guard": {
55
55
  "undefined": "Property \"{property}\" must be defined, it is \"{value}\"",
@@ -81,6 +81,8 @@
81
81
  "urn": "Property \"{property}\" must be a Urn formatted string, it is \"{value}\"",
82
82
  "url": "Property \"{property}\" must be a Url formatted string, it is \"{value}\"",
83
83
  "email": "Property \"{property}\" must be string in e-mail format, it is \"{value}\"",
84
+ "uuidV7": "Property \"{property}\" must be a UUIDv7 formatted string, it is \"{value}\"",
85
+ "uuidV7Compact": "Property \"{property}\" must be a UUIDv7 formatted string in compact mode, it is \"{value}\"",
84
86
  "length32Multiple": "Property \"{property}\" should be a multiple of 32, it is {value}",
85
87
  "lengthEntropy": "Property \"{property}\" should be a multiple of 4, >=16 and <= 32, it is {value}",
86
88
  "didPartsTooFew": "The DID \"{value}\" is invalid: expected at least 3 parts but got fewer",
@@ -97,7 +99,8 @@
97
99
  },
98
100
  "factory": {
99
101
  "noUnregister": "There is no {typeName} registered with the name \"{name}\"",
100
- "noGet": "The requested {typeName} \"{name}\" does not exist in the factory"
102
+ "noGet": "The requested {typeName} \"{name}\" does not exist in the factory",
103
+ "noCreate": "The requested {typeName} \"{name}\" cannot be created by the factory, with params \"{params}\""
101
104
  },
102
105
  "bitString": {
103
106
  "outOfRange": "The index should be >= 0 and less than the length of the bit string, the index is \"{index}\" and the number of bit is \"{numberBits}\""
@@ -159,6 +162,18 @@
159
162
  "optionMinValue": "The \"{option}\" option must be greater than or equal to {minValue}, it is {value}.",
160
163
  "optionMaxValue": "The \"{option}\" option must be less than or equal to {maxValue}, it is {value}."
161
164
  },
165
+ "verifiable-presentation-create": {
166
+ "noCredentialsProvided": "Either --jwt or --json-ld must be provided with at least one credential.",
167
+ "jsonLdFileNotFound": "The JSON-LD credential file was not found."
168
+ },
169
+ "verifiable-credential-verify": {
170
+ "noCredentialProvided": "Either --jwt or --json-ld must be provided.",
171
+ "jsonLdFileNotFound": "The JSON-LD file was not found."
172
+ },
173
+ "verifiable-presentation-verify": {
174
+ "noPresentationProvided": "Either --jwt or --json-ld must be provided.",
175
+ "jsonLdFileNotFound": "The JSON-LD file was not found."
176
+ },
162
177
  "verifiable-credential-create": {
163
178
  "subjectJsonFileNotFound": "The subject JSON file was not found."
164
179
  },
@@ -207,6 +222,10 @@
207
222
  "createFailed": "Failed to create JWS",
208
223
  "verifyFailed": "Failed to verify JWS"
209
224
  },
225
+ "headerHelper": {
226
+ "invalidLinkHeaderURL": "URL for Link header cannot contain \">\" character.",
227
+ "invalidLinkHeaderRel": "Relation type for Link header cannot contain \" character."
228
+ },
210
229
  "contextIdHelper": {
211
230
  "contextIdMissing": "The context ID \"{key}\" is missing from the provided context IDs",
212
231
  "contextIdSplitMismatch": "The context ID split parts length \"{actual}\" does not match the provided keys length \"{expected}\""
@@ -246,37 +265,41 @@
246
265
  "resolveDocumentFailed": "Resolving the document failed \"{documentId}\""
247
266
  },
248
267
  "iotaIdentityConnector": {
249
- "createDocumentFailed": "Creating the document failed",
250
- "removeDocumentFailed": "Removing the document failed",
251
- "missingDid": "The full id including DID is required",
252
- "addVerificationMethodFailed": "Adding the verification method failed",
253
- "removeVerificationMethodFailed": "Removing the verification method failed",
268
+ "addAlsoKnownAsFailed": "Adding to the alsoKnownAs property failed",
254
269
  "addServiceFailed": "Adding the service failed",
255
- "removeServiceFailed": "Removing the service failed",
256
- "documentNotFound": "The document could not be found",
257
- "verificationMethodNotFound": "The verification method could not be found",
258
- "serviceNotFound": "The service could not be found",
259
- "publicKeyJwkMissing": "The verification method contains no publicKeyJwk in JWK \"{jwk}\"",
260
- "publicKeyJwkMethodMissing": "The verification method contains no publicKeyJwk in method \"{method}\"",
261
- "privateKeyMissing": "The verification method contains no privateKey \"{keyId}\"",
262
- "verificationKeyMissing": "The verification key is missing from the vault for method \"{method}\"",
263
- "createVerifiableCredentialFailed": "Creating the verifiable credential failed",
270
+ "addVerificationMethodFailed": "Adding the verification method failed",
271
+ "algorithmKeyTypeMismatch": "Algorithm \"{algorithm}\" requires key type \"{expectedKeyType}\", but key \"{keyId}\" has type \"{actualKeyType}\"",
264
272
  "checkingVerifiableCredentialFailed": "Checking the verifiable credential failed",
265
- "createVerifiablePresentationFailed": "Creating the verifiable presentation failed",
266
273
  "checkingVerifiablePresentationFailed": "Checking the verifiable presentation failed",
274
+ "createDocumentFailed": "Creating the document failed",
267
275
  "createProofFailed": "Creating the signature for the data failed",
268
- "methodMissing": "The verification method specified does not exist \"{method}\"",
269
- "verifyProofFailed": "Verifying the signature for the data failed",
270
- "revokeVerifiableCredentialsFailed": "Revoking verifiable credentials failed",
271
- "unrevokeVerifiableCredentialsFailed": "Unrevoking verifiable credentials failed",
276
+ "createVerifiableCredentialFailed": "Creating the verifiable credential failed",
277
+ "createVerifiablePresentationFailed": "Creating the verifiable presentation failed",
278
+ "didExtractionFailed": "Extracting the DID from the document id failed",
279
+ "documentNotFound": "The document could not be found",
280
+ "gasStationTransactionBuildFailed": "Building the gas station transaction failed",
281
+ "identityNotFound": "The identity could not be found \"{notFoundId}\"",
282
+ "invalidAlias": "The alias is invalid it must be a Url or Urn, it is \"{alias}\"",
272
283
  "invalidSubjectId": "The subject id format is invalid it must be a Url or Urn, it is \"{subjectId}\"",
284
+ "methodMissing": "The verification method specified does not exist \"{method}\"",
273
285
  "missingControllerToken": "The controller token is missing",
274
- "identityNotFound": "The identity could not be found \"{notFoundId}\"",
286
+ "missingDid": "The full id including DID is required",
287
+ "privateKeyMissing": "The verification method contains no privateKey \"{keyId}\"",
288
+ "publicKeyJwkMethodMissing": "The verification method contains no publicKeyJwk in method \"{method}\"",
289
+ "publicKeyJwkMissing": "The verification method contains no publicKeyJwk in JWK \"{jwk}\"",
290
+ "removeAlsoKnownAsFailed": "Removing from the alsoKnownAs property failed",
291
+ "removeDocumentFailed": "Removing the document failed",
292
+ "removeServiceFailed": "Removing the service failed",
293
+ "removeVerificationMethodFailed": "Removing the verification method failed",
275
294
  "revocationServiceNotFound": "The revocation service could not be found in the document",
276
- "didExtractionFailed": "Extracting the DID from the document id failed",
277
- "transactionConfirmationTimeout": "The transaction was not confirmed in the expected time",
295
+ "revokeVerifiableCredentialsFailed": "Revoking verifiable credentials failed",
296
+ "serviceNotFound": "The service could not be found",
278
297
  "transactionBuildFailed": "Building the transaction failed",
279
- "gasStationTransactionBuildFailed": "Building the gas station transaction failed"
298
+ "transactionConfirmationTimeout": "The transaction was not confirmed in the expected time",
299
+ "unrevokeVerifiableCredentialsFailed": "Unrevoking verifiable credentials failed",
300
+ "verificationKeyMissing": "The verification key is missing from the vault for method \"{method}\"",
301
+ "verificationMethodNotFound": "The verification method could not be found",
302
+ "verifyProofFailed": "Verifying the signature for the data failed"
280
303
  },
281
304
  "iota": {
282
305
  "insufficientFunds": "There were insufficient funds to complete the operation",
@@ -288,6 +311,12 @@
288
311
  "gasStationTransactionFailed": "The gas station transaction failed",
289
312
  "dryRunFailed": "The dry run execution failed"
290
313
  },
314
+ "iotaIdentityUtils": {
315
+ "getControllerCapInfoFailed": "Getting the controller capability info for the identity failed",
316
+ "identityNotFound": "The identity could not be found \"{notFoundId}\"",
317
+ "identityDeleted": "The identity \"{identityId}\" has been deleted and cannot be used for minting",
318
+ "controllerTokenNotFound": "No controller token found for the identity \"{notFoundId}\" with the provided controller address"
319
+ },
291
320
  "iotaSmartContractUtils": {
292
321
  "migrationFailed": "Smart contract migration failed",
293
322
  "migrateSmartContractFailed": "Failed to migrate smart contract for object \"{objectId}\"",
@@ -552,6 +581,10 @@
552
581
  "param": "--seed '<'seed'>'",
553
582
  "description": "The seed for the controller address in hex or base64 used to create the DID, or start with ! to read environment variable."
554
583
  },
584
+ "controller": {
585
+ "param": "--controller '<'controller'>'",
586
+ "description": "The controller for the DID, or start with ! to read environment variable."
587
+ },
555
588
  "addressIndex": {
556
589
  "param": "--address-index '<'index'>'",
557
590
  "description": "The address index to use for the creation."
@@ -612,6 +645,8 @@
612
645
  "labels": {
613
646
  "verificationMethodType": "Verification Method Type",
614
647
  "verificationMethodId": "Verification Method Id",
648
+ "privateKeyBase64Url": "Private Key Base64 Url",
649
+ "publicKeyBase64Url": "Public Key Base64 Url",
615
650
  "privateKeyBase64": "Private Key Base64",
616
651
  "publicKeyBase64": "Public Key Base64",
617
652
  "privateKeyHex": "Private Key Hex",
@@ -709,12 +744,77 @@
709
744
  "addressIndex": "Address Index"
710
745
  }
711
746
  },
747
+ "verifiable-presentation-create": {
748
+ "summary": "Create a verifiable presentation.",
749
+ "description": "Create a verifiable presentation.",
750
+ "options": {
751
+ "verification-method-id": {
752
+ "param": "--verification-method-id '<'verification-method-id'>'",
753
+ "description": "The full verification method id including did, or start with ! to read environment variable."
754
+ },
755
+ "private-key": {
756
+ "param": "--private-key '<'private-key'>'",
757
+ "description": "The private key for the verification method id, in either hex or base64 form, or start with ! to read environment variable."
758
+ },
759
+ "presentation-id": {
760
+ "param": "--presentation-id '<'presentation-id'>'",
761
+ "description": "The presentation id which uniquely identifies the presentation."
762
+ },
763
+ "jwt": {
764
+ "param": "--jwt '<'jwt'>'",
765
+ "description": "Comma-separated list of verifiable credential JWTs to include in the presentation, or start with ! to read environment variable."
766
+ },
767
+ "json-ld": {
768
+ "param": "--json-ld '<'json-ld'>'",
769
+ "description": "Comma-separated list of JSON-LD filenames containing verifiable credentials to include in the presentation."
770
+ },
771
+ "expiration-date": {
772
+ "param": "--expiration-date '<'ISO Date'>'",
773
+ "description": "The expiration date for the presentation."
774
+ }
775
+ },
776
+ "progress": {
777
+ "creatingVerifiablePresentation": "Creating Verifiable Presentation",
778
+ "loadingCredentialData": "Loading Credential Data"
779
+ },
780
+ "labels": {
781
+ "verificationMethodId": "Verification Method Id",
782
+ "presentationId": "Presentation Id",
783
+ "jwt": "JWT Credentials",
784
+ "jsonLd": "JSON-LD Credentials",
785
+ "verifiablePresentation": "Verifiable Presentation",
786
+ "expirationDate": "Expiration Date"
787
+ }
788
+ },
789
+ "verifiable-presentation-verify": {
790
+ "summary": "Verify a verifiable presentation.",
791
+ "description": "Verify a verifiable presentation.",
792
+ "options": {
793
+ "jwt": {
794
+ "param": "--jwt '<'jwt'>'",
795
+ "description": "The verifiable presentation as a JSON web token to verify, or start with ! to read environment variable."
796
+ },
797
+ "json-ld": {
798
+ "param": "--json-ld '<'json-ld'>'",
799
+ "description": "A JSON-LD file containing the verifiable presentation to verify."
800
+ }
801
+ },
802
+ "progress": {
803
+ "verifyingPresentation": "Verifying Presentation"
804
+ },
805
+ "labels": {
806
+ "jwt": "JWT",
807
+ "jsonLd": "JSON-LD",
808
+ "isVerified": "Is Verified",
809
+ "isRevoked": "Is Revoked"
810
+ }
811
+ },
712
812
  "verifiable-credential-create": {
713
813
  "summary": "Create a verifiable credential.",
714
814
  "description": "Create a verifiable credential.",
715
815
  "options": {
716
- "id": {
717
- "param": "--id '<'id'>'",
816
+ "verification-method-id": {
817
+ "param": "--verification-method-id '<'verification-method-id'>'",
718
818
  "description": "The full verification method id including did, or start with ! to read environment variable."
719
819
  },
720
820
  "private-key": {
@@ -733,9 +833,9 @@
733
833
  "param": "--revocation-index '<'revocation-index'>'",
734
834
  "description": "The revocation index in the issuing document to use if revoking the credential."
735
835
  },
736
- "addressIndex": {
737
- "param": "--address-index '<'index'>'",
738
- "description": "The address index to use for the identity controller."
836
+ "expiration-date": {
837
+ "param": "--expiration-date '<'ISO Date'>'",
838
+ "description": "The expiration date for the credential."
739
839
  }
740
840
  },
741
841
  "progress": {
@@ -748,7 +848,7 @@
748
848
  "subjectJson": "Subject JSON",
749
849
  "revocationIndex": "Revocation Index",
750
850
  "verifiableCredential": "Verifiable Credential",
751
- "addressIndex": "Address Index"
851
+ "expirationDate": "Expiration Date"
752
852
  }
753
853
  },
754
854
  "verifiable-credential-verify": {
@@ -758,6 +858,10 @@
758
858
  "jwt": {
759
859
  "param": "--jwt '<'jwt'>'",
760
860
  "description": "The verifiable credential as a JSON web token to verify, or start with ! to read environment variable."
861
+ },
862
+ "json-ld": {
863
+ "param": "--json-ld '<'json-ld'>'",
864
+ "description": "A JSON-LD file containing the verifiable credential to verify."
761
865
  }
762
866
  },
763
867
  "progress": {
@@ -765,6 +869,7 @@
765
869
  },
766
870
  "labels": {
767
871
  "jwt": "JWT",
872
+ "jsonLd": "JSON-LD",
768
873
  "isVerified": "Is Verified",
769
874
  "isRevoked": "Is Revoked"
770
875
  }
@@ -842,10 +947,6 @@
842
947
  "document-filename": {
843
948
  "param": "--document-filename '<'document-filename'>'",
844
949
  "description": "The filename of a JSON-LD document to create the proof for."
845
- },
846
- "addressIndex": {
847
- "param": "--address-index '<'index'>'",
848
- "description": "The address index to use for the identity controller."
849
950
  }
850
951
  },
851
952
  "progress": {
@@ -853,8 +954,7 @@
853
954
  },
854
955
  "labels": {
855
956
  "documentFilename": "Document Filename",
856
- "verificationMethodId": "Verification Method Id",
857
- "addressIndex": "Address Index"
957
+ "verificationMethodId": "Verification Method Id"
858
958
  }
859
959
  },
860
960
  "proof-verify": {
@@ -878,6 +978,64 @@
878
978
  "proofFilename": "Proof Filename",
879
979
  "isVerified": "Is Verified"
880
980
  }
981
+ },
982
+ "also-known-as-add": {
983
+ "summary": "Add an alias (alsoKnownAs) to a DID.",
984
+ "description": "Add an alias (alsoKnownAs) to a DID.",
985
+ "options": {
986
+ "seed": {
987
+ "param": "--seed '<'seed'>'",
988
+ "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."
989
+ },
990
+ "did": {
991
+ "param": "--did '<'did'>'",
992
+ "description": "The identifier to add the alias to, or start with ! to read environment variable."
993
+ },
994
+ "alias": {
995
+ "param": "--alias '<'alias'>'",
996
+ "description": "The alias (alsoKnownAs) value to add."
997
+ },
998
+ "addressIndex": {
999
+ "param": "--address-index '<'index'>'",
1000
+ "description": "The address index to use for the identity controller."
1001
+ }
1002
+ },
1003
+ "progress": {
1004
+ "addingAlsoKnownAs": "Adding Alias (alsoKnownAs)"
1005
+ },
1006
+ "labels": {
1007
+ "alias": "Alias (alsoKnownAs)",
1008
+ "addressIndex": "Address Index"
1009
+ }
1010
+ },
1011
+ "also-known-as-remove": {
1012
+ "summary": "Remove an alias (alsoKnownAs) from a DID.",
1013
+ "description": "Remove an alias (alsoKnownAs) from a DID.",
1014
+ "options": {
1015
+ "seed": {
1016
+ "param": "--seed '<'seed'>'",
1017
+ "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."
1018
+ },
1019
+ "did": {
1020
+ "param": "--did '<'did'>'",
1021
+ "description": "The identifier to remove the alias from, or start with ! to read environment variable."
1022
+ },
1023
+ "alias": {
1024
+ "param": "--alias '<'alias'>'",
1025
+ "description": "The alias (alsoKnownAs) value to remove."
1026
+ },
1027
+ "addressIndex": {
1028
+ "param": "--address-index '<'index'>'",
1029
+ "description": "The address index to use for the identity controller."
1030
+ }
1031
+ },
1032
+ "progress": {
1033
+ "removingAlsoKnownAs": "Removing Alias (alsoKnownAs)"
1034
+ },
1035
+ "labels": {
1036
+ "alias": "Alias (alsoKnownAs)",
1037
+ "addressIndex": "Address Index"
1038
+ }
881
1039
  }
882
1040
  },
883
1041
  "errorMessages": {
@@ -0,0 +1,30 @@
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 alsoKnownAs add command for the CLI.
6
+ * @returns The command.
7
+ */
8
+ export declare function buildCommandAlsoKnownAsAdd(): Command;
9
+ /**
10
+ * Action the alsoKnownAs add command.
11
+ * @param opts The options for the command.
12
+ * @param opts.seed The private key for the controller.
13
+ * @param opts.did The identity of the document to add to.
14
+ * @param opts.alias The alsoKnownAs value to add.
15
+ * @param opts.addressIndex The address index to use for key derivation (if applicable).
16
+ * @param opts.connector The connector to perform the operations with.
17
+ * @param opts.node The node URL.
18
+ * @param opts.network The network to use for connector.
19
+ * @param opts.explorer The explorer URL.
20
+ */
21
+ export declare function actionCommandAlsoKnownAsAdd(opts: {
22
+ seed: string;
23
+ did: string;
24
+ alias: string;
25
+ addressIndex?: string;
26
+ connector?: IdentityConnectorTypes;
27
+ node: string;
28
+ network?: string;
29
+ explorer: string;
30
+ } & CliOutputOptions): Promise<void>;
@@ -0,0 +1,30 @@
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 alsoKnownAs remove command for the CLI.
6
+ * @returns The command.
7
+ */
8
+ export declare function buildCommandAlsoKnownAsRemove(): Command;
9
+ /**
10
+ * Action the alsoKnownAs remove command.
11
+ * @param opts The options for the command.
12
+ * @param opts.seed The private key for the controller.
13
+ * @param opts.did The identity of the document to remove from.
14
+ * @param opts.alias The alsoKnownAs value to remove.
15
+ * @param opts.addressIndex The address index to use for key derivation (if applicable).
16
+ * @param opts.connector The connector to perform the operations with.
17
+ * @param opts.node The node URL.
18
+ * @param opts.network The network to use for connector.
19
+ * @param opts.explorer The explorer URL.
20
+ */
21
+ export declare function actionCommandAlsoKnownAsRemove(opts: {
22
+ seed: string;
23
+ did: string;
24
+ alias: string;
25
+ addressIndex?: string;
26
+ connector?: IdentityConnectorTypes;
27
+ node: string;
28
+ network?: string;
29
+ explorer: string;
30
+ } & CliOutputOptions): Promise<void>;
@@ -22,4 +22,5 @@ export declare function actionCommandIdentityCreate(opts: {
22
22
  network?: string;
23
23
  explorer: string;
24
24
  addressIndex?: string;
25
+ controller?: string;
25
26
  } & CliOutputOptions): Promise<void>;
@@ -12,7 +12,6 @@ export declare function buildCommandProofCreate(): Command;
12
12
  * @param opts.id The id of the verification method to use for the credential.
13
13
  * @param opts.privateKey The private key for the verification method.
14
14
  * @param opts.documentFilename The filename of the document to create the proof for.
15
- * @param opts.addressIndex The address index to use for key derivation (if applicable).
16
15
  * @param opts.data The data to create the proof for.
17
16
  * @param opts.connector The connector to perform the operations with.
18
17
  * @param opts.node The node URL.
@@ -22,7 +21,6 @@ export declare function actionCommandProofCreate(opts: {
22
21
  id: string;
23
22
  privateKey: string;
24
23
  documentFilename: string;
25
- addressIndex?: string;
26
24
  connector?: IdentityConnectorTypes;
27
25
  node: string;
28
26
  network?: string;
@@ -9,22 +9,22 @@ export declare function buildCommandVerifiableCredentialCreate(): Command;
9
9
  /**
10
10
  * Action the verifiable credential create command.
11
11
  * @param opts The options for the command.
12
- * @param opts.id The id of the verification method to use for the credential.
12
+ * @param opts.verificationMethodId The id of the verification method to use for the credential.
13
13
  * @param opts.privateKey The private key for the verification method.
14
14
  * @param opts.credentialId The id of the credential.
15
15
  * @param opts.subjectJson The JSON data for the subject.
16
+ * @param opts.expirationDate The expiration date for the credential.
16
17
  * @param opts.revocationIndex The revocation index for the credential.
17
- * @param opts.addressIndex The address index to use for key derivation (if applicable).
18
18
  * @param opts.connector The connector to perform the operations with.
19
19
  * @param opts.node The node URL.
20
20
  */
21
21
  export declare function actionCommandVerifiableCredentialCreate(opts: {
22
- id: string;
22
+ verificationMethodId: string;
23
23
  privateKey: string;
24
24
  credentialId?: string;
25
25
  subjectJson: string;
26
+ expirationDate?: string;
26
27
  revocationIndex?: string;
27
- addressIndex?: string;
28
28
  connector?: IdentityConnectorTypes;
29
29
  node: string;
30
30
  network?: string;
@@ -10,11 +10,13 @@ export declare function buildCommandVerifiableCredentialVerify(): Command;
10
10
  * Action the verifiable credential verify command.
11
11
  * @param opts The options for the command.
12
12
  * @param opts.jwt The JSON web token for the verifiable credential.
13
+ * @param opts.jsonLd The filename of a JSON-LD verifiable credential to verify.
13
14
  * @param opts.connector The connector to perform the operations with.
14
15
  * @param opts.node The node URL.
15
16
  */
16
17
  export declare function actionCommandVerifiableCredentialVerify(opts: {
17
- jwt: string;
18
+ jwt?: string;
19
+ jsonLd?: string;
18
20
  connector?: IdentityConnectorTypes;
19
21
  node: string;
20
22
  network?: string;
@@ -0,0 +1,32 @@
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 create command for the CLI.
6
+ * @returns The command.
7
+ */
8
+ export declare function buildCommandVerifiablePresentationCreate(): Command;
9
+ /**
10
+ * Action the verifiable presentation create command.
11
+ * @param opts The options for the command.
12
+ * @param opts.verificationMethodId The id of the verification method to use.
13
+ * @param opts.privateKey The private key for the verification method.
14
+ * @param opts.presentationId The optional id of the presentation.
15
+ * @param opts.jwt Comma-separated JWT credential strings to include.
16
+ * @param opts.jsonLd Comma-separated JSON-LD filenames to include.
17
+ * @param opts.expirationDate The expiration date for the presentation.
18
+ * @param opts.connector The connector to perform the operations with.
19
+ * @param opts.node The node URL.
20
+ * @param opts.network The network name.
21
+ */
22
+ export declare function actionCommandVerifiablePresentationCreate(opts: {
23
+ verificationMethodId: string;
24
+ privateKey: string;
25
+ presentationId?: string;
26
+ jwt?: string;
27
+ jsonLd?: string;
28
+ expirationDate?: string;
29
+ connector?: IdentityConnectorTypes;
30
+ node: string;
31
+ network?: string;
32
+ } & CliOutputOptions): Promise<void>;
@@ -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>;
@@ -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";