@twin.org/immutable-proof-service 0.0.3-next.1 → 0.0.3-next.10
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/entities/immutableProof.js +19 -3
- package/dist/es/entities/immutableProof.js.map +1 -1
- package/dist/es/immutableProofRoutes.js +39 -23
- package/dist/es/immutableProofRoutes.js.map +1 -1
- package/dist/es/immutableProofService.js +114 -84
- package/dist/es/immutableProofService.js.map +1 -1
- package/dist/es/models/IImmutableProofServiceConstructorOptions.js.map +1 -1
- package/dist/types/entities/immutableProof.d.ts +11 -2
- package/dist/types/immutableProofService.d.ts +3 -2
- package/dist/types/models/IImmutableProofServiceConstructorOptions.d.ts +7 -2
- package/docs/changelog.md +135 -0
- package/docs/open-api/spec.json +580 -24
- package/docs/reference/classes/ImmutableProof.md +19 -3
- package/docs/reference/classes/ImmutableProofService.md +2 -2
- package/docs/reference/interfaces/IImmutableProofServiceConstructorOptions.md +17 -3
- package/locales/en.json +7 -1
- package/package.json +4 -3
package/docs/open-api/spec.json
CHANGED
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
"schema": {
|
|
64
64
|
"type": "string"
|
|
65
65
|
},
|
|
66
|
-
"description": "e.g. test
|
|
66
|
+
"description": "e.g. test%3A1234567890"
|
|
67
67
|
}
|
|
68
68
|
}
|
|
69
69
|
},
|
|
@@ -165,7 +165,7 @@
|
|
|
165
165
|
"type": "string"
|
|
166
166
|
},
|
|
167
167
|
"style": "simple",
|
|
168
|
-
"example": "
|
|
168
|
+
"example": "immutable-proof:1234567890"
|
|
169
169
|
},
|
|
170
170
|
{
|
|
171
171
|
"name": "accept",
|
|
@@ -189,26 +189,37 @@
|
|
|
189
189
|
"content": {
|
|
190
190
|
"application/json": {
|
|
191
191
|
"schema": {
|
|
192
|
-
"$ref": "
|
|
192
|
+
"$ref": "#/components/schemas/DidVerifiableCredential"
|
|
193
193
|
},
|
|
194
194
|
"examples": {
|
|
195
195
|
"immutableProofGetResponseExample": {
|
|
196
196
|
"value": {
|
|
197
197
|
"@context": [
|
|
198
|
+
"https://www.w3.org/2018/credentials/v1",
|
|
198
199
|
"https://schema.twindev.org/immutable-proof/",
|
|
199
200
|
"https://schema.twindev.org/common/"
|
|
200
201
|
],
|
|
201
|
-
"type":
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
202
|
+
"type": [
|
|
203
|
+
"VerifiableCredential",
|
|
204
|
+
"ImmutableProof"
|
|
205
|
+
],
|
|
206
|
+
"id": "immutable-proof:1234567890",
|
|
207
|
+
"credentialSubject": {
|
|
208
|
+
"id": "ais:1234567890",
|
|
209
|
+
"proofIntegrity": "EAOKyDN0mYQbBh91eMdVeroxQx1H4GfnRbmt6n/2L/Y="
|
|
210
|
+
},
|
|
205
211
|
"proof": {
|
|
206
|
-
"@context": "https://www.w3.org/ns/credentials/v2",
|
|
207
212
|
"type": "DataIntegrityProof",
|
|
208
213
|
"cryptosuite": "eddsa-jcs-2022",
|
|
209
214
|
"created": "2024-08-22T11:56:56.272Z",
|
|
210
215
|
"proofPurpose": "assertionMethod",
|
|
211
|
-
"proofValue": "7DdiPPYtxLjCD3wA1po2rv..."
|
|
216
|
+
"proofValue": "7DdiPPYtxLjCD3wA1po2rv...",
|
|
217
|
+
"verificationMethod": "did:iota:testnet:0xcb07cabaa2f23b7e53d8cdc4228efb351ebb270554d13bc382e4f94ca8d3136b#immutable-proof-assertion",
|
|
218
|
+
"verifiableStorageId": "verifiable-storage:1234567890",
|
|
219
|
+
"immutableReceipt": {
|
|
220
|
+
"id": "immutable-receipt:1234567890",
|
|
221
|
+
"type": "ImmutableReceipt"
|
|
222
|
+
}
|
|
212
223
|
}
|
|
213
224
|
}
|
|
214
225
|
}
|
|
@@ -216,26 +227,37 @@
|
|
|
216
227
|
},
|
|
217
228
|
"application/ld+json": {
|
|
218
229
|
"schema": {
|
|
219
|
-
"$ref": "
|
|
230
|
+
"$ref": "#/components/schemas/DidVerifiableCredential"
|
|
220
231
|
},
|
|
221
232
|
"examples": {
|
|
222
233
|
"immutableProofJsonLdGetResponseExample": {
|
|
223
234
|
"value": {
|
|
224
235
|
"@context": [
|
|
236
|
+
"https://www.w3.org/2018/credentials/v1",
|
|
225
237
|
"https://schema.twindev.org/immutable-proof/",
|
|
226
238
|
"https://schema.twindev.org/common/"
|
|
227
239
|
],
|
|
228
|
-
"type":
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
240
|
+
"type": [
|
|
241
|
+
"VerifiableCredential",
|
|
242
|
+
"ImmutableProof"
|
|
243
|
+
],
|
|
244
|
+
"id": "immutable-proof:1234567890",
|
|
245
|
+
"credentialSubject": {
|
|
246
|
+
"id": "ais:1234567890",
|
|
247
|
+
"proofIntegrity": "EAOKyDN0mYQbBh91eMdVeroxQx1H4GfnRbmt6n/2L/Y="
|
|
248
|
+
},
|
|
232
249
|
"proof": {
|
|
233
|
-
"@context": "https://www.w3.org/ns/credentials/v2",
|
|
234
250
|
"type": "DataIntegrityProof",
|
|
235
251
|
"cryptosuite": "eddsa-jcs-2022",
|
|
236
252
|
"created": "2024-08-22T11:56:56.272Z",
|
|
237
253
|
"proofPurpose": "assertionMethod",
|
|
238
|
-
"proofValue": "7DdiPPYtxLjCD3wA1po2rv..."
|
|
254
|
+
"proofValue": "7DdiPPYtxLjCD3wA1po2rv...",
|
|
255
|
+
"verificationMethod": "did:iota:testnet:0xcb07cabaa2f23b7e53d8cdc4228efb351ebb270554d13bc382e4f94ca8d3136b#immutable-proof-assertion",
|
|
256
|
+
"verifiableStorageId": "verifiable-storage:1234567890",
|
|
257
|
+
"immutableReceipt": {
|
|
258
|
+
"id": "immutable-receipt:1234567890",
|
|
259
|
+
"type": "ImmutableReceipt"
|
|
260
|
+
}
|
|
239
261
|
}
|
|
240
262
|
}
|
|
241
263
|
}
|
|
@@ -349,7 +371,7 @@
|
|
|
349
371
|
"type": "string"
|
|
350
372
|
},
|
|
351
373
|
"style": "simple",
|
|
352
|
-
"example": "
|
|
374
|
+
"example": "immutable-proof:1234567890"
|
|
353
375
|
},
|
|
354
376
|
{
|
|
355
377
|
"name": "accept",
|
|
@@ -387,7 +409,7 @@
|
|
|
387
409
|
"@context": "https://schema.twindev.org/immutable-proof/",
|
|
388
410
|
"type": "ImmutableProofVerification",
|
|
389
411
|
"verified": false,
|
|
390
|
-
"failure": "
|
|
412
|
+
"failure": "verificationFailure"
|
|
391
413
|
}
|
|
392
414
|
}
|
|
393
415
|
}
|
|
@@ -485,7 +507,7 @@
|
|
|
485
507
|
"anyOf": [
|
|
486
508
|
{
|
|
487
509
|
"type": "string",
|
|
488
|
-
"const": "https://
|
|
510
|
+
"const": "https://w3id.org/security/data-integrity/v2"
|
|
489
511
|
},
|
|
490
512
|
{
|
|
491
513
|
"type": "array",
|
|
@@ -493,7 +515,7 @@
|
|
|
493
515
|
"prefixItems": [
|
|
494
516
|
{
|
|
495
517
|
"type": "string",
|
|
496
|
-
"const": "https://
|
|
518
|
+
"const": "https://w3id.org/security/data-integrity/v2"
|
|
497
519
|
}
|
|
498
520
|
],
|
|
499
521
|
"items": {
|
|
@@ -585,9 +607,47 @@
|
|
|
585
607
|
"cryptosuite",
|
|
586
608
|
"proofPurpose"
|
|
587
609
|
],
|
|
588
|
-
"additionalProperties": false,
|
|
589
610
|
"description": "Interface describing a did proof. https://www.w3.org/TR/vc-data-integrity/"
|
|
590
611
|
},
|
|
612
|
+
"DidCredentialSchema": {
|
|
613
|
+
"type": "object",
|
|
614
|
+
"properties": {
|
|
615
|
+
"id": {
|
|
616
|
+
"type": "string",
|
|
617
|
+
"description": "The URI id."
|
|
618
|
+
},
|
|
619
|
+
"type": {
|
|
620
|
+
"type": "string",
|
|
621
|
+
"description": "The credential schema type."
|
|
622
|
+
}
|
|
623
|
+
},
|
|
624
|
+
"required": [
|
|
625
|
+
"id",
|
|
626
|
+
"type"
|
|
627
|
+
],
|
|
628
|
+
"description": "Interface describing a DID credential schema."
|
|
629
|
+
},
|
|
630
|
+
"DidCredentialStatus": {
|
|
631
|
+
"type": "object",
|
|
632
|
+
"properties": {
|
|
633
|
+
"id": {
|
|
634
|
+
"type": "string",
|
|
635
|
+
"description": "The URI id."
|
|
636
|
+
},
|
|
637
|
+
"type": {
|
|
638
|
+
"type": "string",
|
|
639
|
+
"description": "The credential status type."
|
|
640
|
+
}
|
|
641
|
+
},
|
|
642
|
+
"required": [
|
|
643
|
+
"id",
|
|
644
|
+
"type"
|
|
645
|
+
],
|
|
646
|
+
"additionalProperties": {
|
|
647
|
+
"description": "Additional properties."
|
|
648
|
+
},
|
|
649
|
+
"description": "Interface describing a DID credential status."
|
|
650
|
+
},
|
|
591
651
|
"DidCryptoSuites": {
|
|
592
652
|
"anyOf": [
|
|
593
653
|
{
|
|
@@ -603,6 +663,441 @@
|
|
|
603
663
|
],
|
|
604
664
|
"description": "The types for DID Proof crypto suites."
|
|
605
665
|
},
|
|
666
|
+
"DidLabel": {
|
|
667
|
+
"type": "object",
|
|
668
|
+
"properties": {
|
|
669
|
+
"@value": {
|
|
670
|
+
"type": "string",
|
|
671
|
+
"description": "The value for the label."
|
|
672
|
+
},
|
|
673
|
+
"@language": {
|
|
674
|
+
"type": "string",
|
|
675
|
+
"description": "The language for the label."
|
|
676
|
+
},
|
|
677
|
+
"@direction": {
|
|
678
|
+
"type": "string",
|
|
679
|
+
"description": "The direction of the label."
|
|
680
|
+
}
|
|
681
|
+
},
|
|
682
|
+
"required": [
|
|
683
|
+
"@value",
|
|
684
|
+
"@language"
|
|
685
|
+
],
|
|
686
|
+
"description": "Interface describing a DID Label."
|
|
687
|
+
},
|
|
688
|
+
"DidVerifiableCredential": {
|
|
689
|
+
"anyOf": [
|
|
690
|
+
{
|
|
691
|
+
"$ref": "#/components/schemas/DidVerifiableCredentialV1"
|
|
692
|
+
},
|
|
693
|
+
{
|
|
694
|
+
"$ref": "#/components/schemas/DidVerifiableCredentialV2"
|
|
695
|
+
}
|
|
696
|
+
],
|
|
697
|
+
"description": "Interface describing a verifiable credential."
|
|
698
|
+
},
|
|
699
|
+
"DidVerifiableCredentialV1": {
|
|
700
|
+
"type": "object",
|
|
701
|
+
"properties": {
|
|
702
|
+
"id": {
|
|
703
|
+
"type": "string",
|
|
704
|
+
"description": "The identifier for the verifiable credential."
|
|
705
|
+
},
|
|
706
|
+
"type": {
|
|
707
|
+
"anyOf": [
|
|
708
|
+
{
|
|
709
|
+
"type": "string"
|
|
710
|
+
},
|
|
711
|
+
{
|
|
712
|
+
"type": "array",
|
|
713
|
+
"items": {
|
|
714
|
+
"type": "string"
|
|
715
|
+
}
|
|
716
|
+
}
|
|
717
|
+
],
|
|
718
|
+
"description": "The types of the data stored in the verifiable credential."
|
|
719
|
+
},
|
|
720
|
+
"credentialSubject": {
|
|
721
|
+
"anyOf": [
|
|
722
|
+
{
|
|
723
|
+
"$ref": "https://schema.twindev.org/json-ld/JsonLdNodeObject"
|
|
724
|
+
},
|
|
725
|
+
{
|
|
726
|
+
"type": "array",
|
|
727
|
+
"items": {
|
|
728
|
+
"$ref": "https://schema.twindev.org/json-ld/JsonLdNodeObject"
|
|
729
|
+
}
|
|
730
|
+
}
|
|
731
|
+
],
|
|
732
|
+
"description": "The data for the verifiable credential."
|
|
733
|
+
},
|
|
734
|
+
"credentialStatus": {
|
|
735
|
+
"anyOf": [
|
|
736
|
+
{
|
|
737
|
+
"$ref": "#/components/schemas/DidCredentialStatus"
|
|
738
|
+
},
|
|
739
|
+
{
|
|
740
|
+
"type": "array",
|
|
741
|
+
"items": {
|
|
742
|
+
"$ref": "#/components/schemas/DidCredentialStatus"
|
|
743
|
+
}
|
|
744
|
+
}
|
|
745
|
+
],
|
|
746
|
+
"description": "Used to discover information about the current status of the verifiable credential, such as whether it is suspended or revoked."
|
|
747
|
+
},
|
|
748
|
+
"credentialSchema": {
|
|
749
|
+
"anyOf": [
|
|
750
|
+
{
|
|
751
|
+
"$ref": "#/components/schemas/DidCredentialSchema"
|
|
752
|
+
},
|
|
753
|
+
{
|
|
754
|
+
"type": "array",
|
|
755
|
+
"items": {
|
|
756
|
+
"$ref": "#/components/schemas/DidCredentialSchema"
|
|
757
|
+
}
|
|
758
|
+
}
|
|
759
|
+
],
|
|
760
|
+
"description": "Annotate type definitions or lock them to specific versions of the vocabulary."
|
|
761
|
+
},
|
|
762
|
+
"issuer": {
|
|
763
|
+
"anyOf": [
|
|
764
|
+
{
|
|
765
|
+
"type": "string"
|
|
766
|
+
},
|
|
767
|
+
{
|
|
768
|
+
"type": "object",
|
|
769
|
+
"properties": {
|
|
770
|
+
"id": {
|
|
771
|
+
"type": "string"
|
|
772
|
+
},
|
|
773
|
+
"name": {
|
|
774
|
+
"anyOf": [
|
|
775
|
+
{
|
|
776
|
+
"type": "string"
|
|
777
|
+
},
|
|
778
|
+
{
|
|
779
|
+
"type": "array",
|
|
780
|
+
"items": {
|
|
781
|
+
"$ref": "#/components/schemas/DidLabel"
|
|
782
|
+
}
|
|
783
|
+
}
|
|
784
|
+
]
|
|
785
|
+
},
|
|
786
|
+
"description": {
|
|
787
|
+
"anyOf": [
|
|
788
|
+
{
|
|
789
|
+
"type": "string"
|
|
790
|
+
},
|
|
791
|
+
{
|
|
792
|
+
"type": "array",
|
|
793
|
+
"items": {
|
|
794
|
+
"$ref": "#/components/schemas/DidLabel"
|
|
795
|
+
}
|
|
796
|
+
}
|
|
797
|
+
]
|
|
798
|
+
}
|
|
799
|
+
},
|
|
800
|
+
"required": [
|
|
801
|
+
"id"
|
|
802
|
+
]
|
|
803
|
+
}
|
|
804
|
+
],
|
|
805
|
+
"description": "The issuing identity."
|
|
806
|
+
},
|
|
807
|
+
"name": {
|
|
808
|
+
"anyOf": [
|
|
809
|
+
{
|
|
810
|
+
"type": "string"
|
|
811
|
+
},
|
|
812
|
+
{
|
|
813
|
+
"type": "array",
|
|
814
|
+
"items": {
|
|
815
|
+
"$ref": "#/components/schemas/DidLabel"
|
|
816
|
+
}
|
|
817
|
+
}
|
|
818
|
+
],
|
|
819
|
+
"description": "The name of the credential."
|
|
820
|
+
},
|
|
821
|
+
"description": {
|
|
822
|
+
"anyOf": [
|
|
823
|
+
{
|
|
824
|
+
"type": "string"
|
|
825
|
+
},
|
|
826
|
+
{
|
|
827
|
+
"type": "array",
|
|
828
|
+
"items": {
|
|
829
|
+
"$ref": "#/components/schemas/DidLabel"
|
|
830
|
+
}
|
|
831
|
+
}
|
|
832
|
+
],
|
|
833
|
+
"description": "The description of the credential."
|
|
834
|
+
},
|
|
835
|
+
"evidence": {
|
|
836
|
+
"anyOf": [
|
|
837
|
+
{
|
|
838
|
+
"$ref": "https://schema.twindev.org/json-ld/JsonLdNodeObject"
|
|
839
|
+
},
|
|
840
|
+
{
|
|
841
|
+
"type": "array",
|
|
842
|
+
"items": {
|
|
843
|
+
"$ref": "https://schema.twindev.org/json-ld/JsonLdNodeObject"
|
|
844
|
+
}
|
|
845
|
+
}
|
|
846
|
+
],
|
|
847
|
+
"description": "Evidence associated with the Credential."
|
|
848
|
+
},
|
|
849
|
+
"proof": {
|
|
850
|
+
"anyOf": [
|
|
851
|
+
{
|
|
852
|
+
"$ref": "#/components/schemas/Proof"
|
|
853
|
+
},
|
|
854
|
+
{
|
|
855
|
+
"type": "array",
|
|
856
|
+
"items": {
|
|
857
|
+
"$ref": "#/components/schemas/Proof"
|
|
858
|
+
}
|
|
859
|
+
}
|
|
860
|
+
],
|
|
861
|
+
"description": "Proofs that the verifiable credential is valid. Optional if a different proof method is used, such as JWT."
|
|
862
|
+
},
|
|
863
|
+
"@context": {
|
|
864
|
+
"anyOf": [
|
|
865
|
+
{
|
|
866
|
+
"type": "string",
|
|
867
|
+
"const": "https://www.w3.org/2018/credentials/v1"
|
|
868
|
+
},
|
|
869
|
+
{
|
|
870
|
+
"type": "array",
|
|
871
|
+
"minItems": 1,
|
|
872
|
+
"prefixItems": [
|
|
873
|
+
{
|
|
874
|
+
"type": "string",
|
|
875
|
+
"const": "https://www.w3.org/2018/credentials/v1"
|
|
876
|
+
}
|
|
877
|
+
],
|
|
878
|
+
"items": {
|
|
879
|
+
"$ref": "https://schema.twindev.org/json-ld/JsonLdContextDefinitionElement"
|
|
880
|
+
}
|
|
881
|
+
}
|
|
882
|
+
],
|
|
883
|
+
"description": "The context for the verifiable credential."
|
|
884
|
+
},
|
|
885
|
+
"issuanceDate": {
|
|
886
|
+
"type": "string",
|
|
887
|
+
"description": "The date the verifiable credential was issued, depending on version validFrom might be set instead."
|
|
888
|
+
},
|
|
889
|
+
"expirationDate": {
|
|
890
|
+
"type": "string",
|
|
891
|
+
"description": "The date the verifiable credential expires, depending on version validUntil might be set instead."
|
|
892
|
+
}
|
|
893
|
+
},
|
|
894
|
+
"required": [
|
|
895
|
+
"@context",
|
|
896
|
+
"type"
|
|
897
|
+
],
|
|
898
|
+
"description": "Interface describing a verifiable credential. https://www.w3.org/TR/vc-data-model-1.1"
|
|
899
|
+
},
|
|
900
|
+
"DidVerifiableCredentialV2": {
|
|
901
|
+
"type": "object",
|
|
902
|
+
"properties": {
|
|
903
|
+
"id": {
|
|
904
|
+
"type": "string",
|
|
905
|
+
"description": "The identifier for the verifiable credential."
|
|
906
|
+
},
|
|
907
|
+
"type": {
|
|
908
|
+
"anyOf": [
|
|
909
|
+
{
|
|
910
|
+
"type": "string"
|
|
911
|
+
},
|
|
912
|
+
{
|
|
913
|
+
"type": "array",
|
|
914
|
+
"items": {
|
|
915
|
+
"type": "string"
|
|
916
|
+
}
|
|
917
|
+
}
|
|
918
|
+
],
|
|
919
|
+
"description": "The types of the data stored in the verifiable credential."
|
|
920
|
+
},
|
|
921
|
+
"credentialSubject": {
|
|
922
|
+
"anyOf": [
|
|
923
|
+
{
|
|
924
|
+
"$ref": "https://schema.twindev.org/json-ld/JsonLdNodeObject"
|
|
925
|
+
},
|
|
926
|
+
{
|
|
927
|
+
"type": "array",
|
|
928
|
+
"items": {
|
|
929
|
+
"$ref": "https://schema.twindev.org/json-ld/JsonLdNodeObject"
|
|
930
|
+
}
|
|
931
|
+
}
|
|
932
|
+
],
|
|
933
|
+
"description": "The data for the verifiable credential."
|
|
934
|
+
},
|
|
935
|
+
"credentialStatus": {
|
|
936
|
+
"anyOf": [
|
|
937
|
+
{
|
|
938
|
+
"$ref": "#/components/schemas/DidCredentialStatus"
|
|
939
|
+
},
|
|
940
|
+
{
|
|
941
|
+
"type": "array",
|
|
942
|
+
"items": {
|
|
943
|
+
"$ref": "#/components/schemas/DidCredentialStatus"
|
|
944
|
+
}
|
|
945
|
+
}
|
|
946
|
+
],
|
|
947
|
+
"description": "Used to discover information about the current status of the verifiable credential, such as whether it is suspended or revoked."
|
|
948
|
+
},
|
|
949
|
+
"credentialSchema": {
|
|
950
|
+
"anyOf": [
|
|
951
|
+
{
|
|
952
|
+
"$ref": "#/components/schemas/DidCredentialSchema"
|
|
953
|
+
},
|
|
954
|
+
{
|
|
955
|
+
"type": "array",
|
|
956
|
+
"items": {
|
|
957
|
+
"$ref": "#/components/schemas/DidCredentialSchema"
|
|
958
|
+
}
|
|
959
|
+
}
|
|
960
|
+
],
|
|
961
|
+
"description": "Annotate type definitions or lock them to specific versions of the vocabulary."
|
|
962
|
+
},
|
|
963
|
+
"issuer": {
|
|
964
|
+
"anyOf": [
|
|
965
|
+
{
|
|
966
|
+
"type": "string"
|
|
967
|
+
},
|
|
968
|
+
{
|
|
969
|
+
"type": "object",
|
|
970
|
+
"properties": {
|
|
971
|
+
"id": {
|
|
972
|
+
"type": "string"
|
|
973
|
+
},
|
|
974
|
+
"name": {
|
|
975
|
+
"anyOf": [
|
|
976
|
+
{
|
|
977
|
+
"type": "string"
|
|
978
|
+
},
|
|
979
|
+
{
|
|
980
|
+
"type": "array",
|
|
981
|
+
"items": {
|
|
982
|
+
"$ref": "#/components/schemas/DidLabel"
|
|
983
|
+
}
|
|
984
|
+
}
|
|
985
|
+
]
|
|
986
|
+
},
|
|
987
|
+
"description": {
|
|
988
|
+
"anyOf": [
|
|
989
|
+
{
|
|
990
|
+
"type": "string"
|
|
991
|
+
},
|
|
992
|
+
{
|
|
993
|
+
"type": "array",
|
|
994
|
+
"items": {
|
|
995
|
+
"$ref": "#/components/schemas/DidLabel"
|
|
996
|
+
}
|
|
997
|
+
}
|
|
998
|
+
]
|
|
999
|
+
}
|
|
1000
|
+
},
|
|
1001
|
+
"required": [
|
|
1002
|
+
"id"
|
|
1003
|
+
]
|
|
1004
|
+
}
|
|
1005
|
+
],
|
|
1006
|
+
"description": "The issuing identity."
|
|
1007
|
+
},
|
|
1008
|
+
"name": {
|
|
1009
|
+
"anyOf": [
|
|
1010
|
+
{
|
|
1011
|
+
"type": "string"
|
|
1012
|
+
},
|
|
1013
|
+
{
|
|
1014
|
+
"type": "array",
|
|
1015
|
+
"items": {
|
|
1016
|
+
"$ref": "#/components/schemas/DidLabel"
|
|
1017
|
+
}
|
|
1018
|
+
}
|
|
1019
|
+
],
|
|
1020
|
+
"description": "The name of the credential."
|
|
1021
|
+
},
|
|
1022
|
+
"description": {
|
|
1023
|
+
"anyOf": [
|
|
1024
|
+
{
|
|
1025
|
+
"type": "string"
|
|
1026
|
+
},
|
|
1027
|
+
{
|
|
1028
|
+
"type": "array",
|
|
1029
|
+
"items": {
|
|
1030
|
+
"$ref": "#/components/schemas/DidLabel"
|
|
1031
|
+
}
|
|
1032
|
+
}
|
|
1033
|
+
],
|
|
1034
|
+
"description": "The description of the credential."
|
|
1035
|
+
},
|
|
1036
|
+
"evidence": {
|
|
1037
|
+
"anyOf": [
|
|
1038
|
+
{
|
|
1039
|
+
"$ref": "https://schema.twindev.org/json-ld/JsonLdNodeObject"
|
|
1040
|
+
},
|
|
1041
|
+
{
|
|
1042
|
+
"type": "array",
|
|
1043
|
+
"items": {
|
|
1044
|
+
"$ref": "https://schema.twindev.org/json-ld/JsonLdNodeObject"
|
|
1045
|
+
}
|
|
1046
|
+
}
|
|
1047
|
+
],
|
|
1048
|
+
"description": "Evidence associated with the Credential."
|
|
1049
|
+
},
|
|
1050
|
+
"proof": {
|
|
1051
|
+
"anyOf": [
|
|
1052
|
+
{
|
|
1053
|
+
"$ref": "#/components/schemas/Proof"
|
|
1054
|
+
},
|
|
1055
|
+
{
|
|
1056
|
+
"type": "array",
|
|
1057
|
+
"items": {
|
|
1058
|
+
"$ref": "#/components/schemas/Proof"
|
|
1059
|
+
}
|
|
1060
|
+
}
|
|
1061
|
+
],
|
|
1062
|
+
"description": "Proofs that the verifiable credential is valid. Optional if a different proof method is used, such as JWT."
|
|
1063
|
+
},
|
|
1064
|
+
"@context": {
|
|
1065
|
+
"anyOf": [
|
|
1066
|
+
{
|
|
1067
|
+
"type": "string",
|
|
1068
|
+
"const": "https://www.w3.org/ns/credentials/v2"
|
|
1069
|
+
},
|
|
1070
|
+
{
|
|
1071
|
+
"type": "array",
|
|
1072
|
+
"minItems": 1,
|
|
1073
|
+
"prefixItems": [
|
|
1074
|
+
{
|
|
1075
|
+
"type": "string",
|
|
1076
|
+
"const": "https://www.w3.org/ns/credentials/v2"
|
|
1077
|
+
}
|
|
1078
|
+
],
|
|
1079
|
+
"items": {
|
|
1080
|
+
"$ref": "https://schema.twindev.org/json-ld/JsonLdContextDefinitionElement"
|
|
1081
|
+
}
|
|
1082
|
+
}
|
|
1083
|
+
],
|
|
1084
|
+
"description": "The context for the verifiable credential."
|
|
1085
|
+
},
|
|
1086
|
+
"validFrom": {
|
|
1087
|
+
"type": "string",
|
|
1088
|
+
"description": "The date the verifiable credential is valid from."
|
|
1089
|
+
},
|
|
1090
|
+
"validUntil": {
|
|
1091
|
+
"type": "string",
|
|
1092
|
+
"description": "The date the verifiable credential is valid until."
|
|
1093
|
+
}
|
|
1094
|
+
},
|
|
1095
|
+
"required": [
|
|
1096
|
+
"@context",
|
|
1097
|
+
"type"
|
|
1098
|
+
],
|
|
1099
|
+
"description": "Interface describing a verifiable credential. https://www.w3.org/TR/vc-data-model-2.0"
|
|
1100
|
+
},
|
|
606
1101
|
"Error": {
|
|
607
1102
|
"type": "object",
|
|
608
1103
|
"properties": {
|
|
@@ -635,7 +1130,6 @@
|
|
|
635
1130
|
"name",
|
|
636
1131
|
"message"
|
|
637
1132
|
],
|
|
638
|
-
"additionalProperties": false,
|
|
639
1133
|
"description": "Model to describe serialized error."
|
|
640
1134
|
},
|
|
641
1135
|
"ImmutableProofCreateRequest": {
|
|
@@ -648,12 +1142,63 @@
|
|
|
648
1142
|
"required": [
|
|
649
1143
|
"document"
|
|
650
1144
|
],
|
|
651
|
-
"additionalProperties": false,
|
|
652
1145
|
"description": "The parameters from the body."
|
|
653
1146
|
},
|
|
1147
|
+
"JsonWebSignature2020Proof": {
|
|
1148
|
+
"type": "object",
|
|
1149
|
+
"properties": {
|
|
1150
|
+
"@context": {
|
|
1151
|
+
"anyOf": [
|
|
1152
|
+
{
|
|
1153
|
+
"type": "string",
|
|
1154
|
+
"const": "https://w3id.org/security/suites/jws-2020/v1"
|
|
1155
|
+
},
|
|
1156
|
+
{
|
|
1157
|
+
"type": "array",
|
|
1158
|
+
"minItems": 1,
|
|
1159
|
+
"prefixItems": [
|
|
1160
|
+
{
|
|
1161
|
+
"type": "string",
|
|
1162
|
+
"const": "https://w3id.org/security/suites/jws-2020/v1"
|
|
1163
|
+
}
|
|
1164
|
+
],
|
|
1165
|
+
"items": {
|
|
1166
|
+
"$ref": "https://schema.twindev.org/json-ld/JsonLdContextDefinitionElement"
|
|
1167
|
+
}
|
|
1168
|
+
}
|
|
1169
|
+
],
|
|
1170
|
+
"description": "JSON-LD Context."
|
|
1171
|
+
},
|
|
1172
|
+
"type": {
|
|
1173
|
+
"type": "string",
|
|
1174
|
+
"const": "JsonWebSignature2020",
|
|
1175
|
+
"description": "JSON-LD Type."
|
|
1176
|
+
},
|
|
1177
|
+
"proofPurpose": {
|
|
1178
|
+
"type": "string",
|
|
1179
|
+
"description": "The reason the proof was created."
|
|
1180
|
+
},
|
|
1181
|
+
"verificationMethod": {
|
|
1182
|
+
"type": "string",
|
|
1183
|
+
"description": "The verification method of the proof."
|
|
1184
|
+
},
|
|
1185
|
+
"created": {
|
|
1186
|
+
"type": "string",
|
|
1187
|
+
"description": "The iso date of when the proof was created."
|
|
1188
|
+
},
|
|
1189
|
+
"jws": {
|
|
1190
|
+
"type": "string",
|
|
1191
|
+
"description": "The JSON Web Signature."
|
|
1192
|
+
}
|
|
1193
|
+
},
|
|
1194
|
+
"required": [
|
|
1195
|
+
"type",
|
|
1196
|
+
"proofPurpose"
|
|
1197
|
+
],
|
|
1198
|
+
"description": "Interface describing a did proof in JSON Web Signature 2020 Format. https://www.w3.org/TR/vc-jws-2020/"
|
|
1199
|
+
},
|
|
654
1200
|
"NotFoundResponse": {
|
|
655
1201
|
"type": "object",
|
|
656
|
-
"additionalProperties": false,
|
|
657
1202
|
"properties": {
|
|
658
1203
|
"notFoundId": {
|
|
659
1204
|
"type": "string",
|
|
@@ -689,6 +1234,17 @@
|
|
|
689
1234
|
"name"
|
|
690
1235
|
],
|
|
691
1236
|
"description": "The body which contains the error."
|
|
1237
|
+
},
|
|
1238
|
+
"Proof": {
|
|
1239
|
+
"anyOf": [
|
|
1240
|
+
{
|
|
1241
|
+
"$ref": "#/components/schemas/DataIntegrityProof"
|
|
1242
|
+
},
|
|
1243
|
+
{
|
|
1244
|
+
"$ref": "#/components/schemas/JsonWebSignature2020Proof"
|
|
1245
|
+
}
|
|
1246
|
+
],
|
|
1247
|
+
"description": "Interface describing a proof."
|
|
692
1248
|
}
|
|
693
1249
|
},
|
|
694
1250
|
"securitySchemes": {
|