@openvtc/trust-tasks 0.26.11 → 0.26.13
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/CHANGELOG.md +303 -0
- package/dist/_shared/components.d.ts +18 -0
- package/dist/_shared/components.d.ts.map +1 -1
- package/dist/index.d.ts +12 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +12 -0
- package/dist/index.js.map +1 -1
- package/dist/rooms/keys/act/0.3/payload.d.ts +546 -0
- package/dist/rooms/keys/act/0.3/payload.d.ts.map +1 -0
- package/dist/rooms/keys/act/0.3/payload.js +305 -0
- package/dist/rooms/keys/act/0.3/payload.js.map +1 -0
- package/dist/rooms/owner/group/add/0.2/payload.d.ts +417 -0
- package/dist/rooms/owner/group/add/0.2/payload.d.ts.map +1 -0
- package/dist/rooms/owner/group/add/0.2/payload.js +218 -0
- package/dist/rooms/owner/group/add/0.2/payload.js.map +1 -0
- package/dist/vta/_shared/0.6/witness-party.d.ts +16 -0
- package/dist/vta/_shared/0.6/witness-party.d.ts.map +1 -0
- package/dist/vta/_shared/0.6/witness-party.js +6 -0
- package/dist/vta/_shared/0.6/witness-party.js.map +1 -0
- package/dist/vta/witness/accept/0.2/payload.d.ts +499 -0
- package/dist/vta/witness/accept/0.2/payload.d.ts.map +1 -0
- package/dist/vta/witness/accept/0.2/payload.js +278 -0
- package/dist/vta/witness/accept/0.2/payload.js.map +1 -0
- package/dist/vta/witness/list/0.1/payload.d.ts +673 -0
- package/dist/vta/witness/list/0.1/payload.d.ts.map +1 -0
- package/dist/vta/witness/list/0.1/payload.js +351 -0
- package/dist/vta/witness/list/0.1/payload.js.map +1 -0
- package/dist/vta/witness/open/0.2/payload.d.ts +500 -0
- package/dist/vta/witness/open/0.2/payload.d.ts.map +1 -0
- package/dist/vta/witness/open/0.2/payload.js +259 -0
- package/dist/vta/witness/open/0.2/payload.js.map +1 -0
- package/dist/vta/witness/present/0.2/payload.d.ts +303 -0
- package/dist/vta/witness/present/0.2/payload.d.ts.map +1 -0
- package/dist/vta/witness/present/0.2/payload.js +170 -0
- package/dist/vta/witness/present/0.2/payload.js.map +1 -0
- package/dist/vtc/members/personhood/assert/0.2/payload.d.ts +536 -0
- package/dist/vtc/members/personhood/assert/0.2/payload.d.ts.map +1 -0
- package/dist/vtc/members/personhood/assert/0.2/payload.js +228 -0
- package/dist/vtc/members/personhood/assert/0.2/payload.js.map +1 -0
- package/dist/vtc/members/registry-consent/0.1/payload.d.ts +311 -0
- package/dist/vtc/members/registry-consent/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/members/registry-consent/0.1/payload.js +183 -0
- package/dist/vtc/members/registry-consent/0.1/payload.js.map +1 -0
- package/dist/vtc/members/update/0.1/payload.d.ts +3 -3
- package/dist/vtc/members/update/0.1/payload.js +1 -1
- package/dist/vtc/members/update/0.1/payload.js.map +1 -1
- package/dist/witness/_shared/0.1/outcome-evidence.d.ts +16 -0
- package/dist/witness/_shared/0.1/outcome-evidence.d.ts.map +1 -0
- package/dist/witness/_shared/0.1/outcome-evidence.js +6 -0
- package/dist/witness/_shared/0.1/outcome-evidence.js.map +1 -0
- package/dist/witness/session/0.2/payload.d.ts +274 -0
- package/dist/witness/session/0.2/payload.d.ts.map +1 -0
- package/dist/witness/session/0.2/payload.js +152 -0
- package/dist/witness/session/0.2/payload.js.map +1 -0
- package/dist/witness/session/submit/0.2/payload.d.ts +295 -0
- package/dist/witness/session/submit/0.2/payload.d.ts.map +1 -0
- package/dist/witness/session/submit/0.2/payload.js +166 -0
- package/dist/witness/session/submit/0.2/payload.js.map +1 -0
- package/package.json +1 -1
- package/src/_shared/components.ts +17 -0
- package/src/index.ts +12 -0
- package/src/rooms/keys/act/0.3/payload.ts +380 -0
- package/src/rooms/owner/group/add/0.2/payload.ts +288 -0
- package/src/vta/_shared/0.6/witness-party.ts +17 -0
- package/src/vta/witness/accept/0.2/payload.ts +330 -0
- package/src/vta/witness/list/0.1/payload.ts +441 -0
- package/src/vta/witness/open/0.2/payload.ts +336 -0
- package/src/vta/witness/present/0.2/payload.ts +210 -0
- package/src/vtc/members/personhood/assert/0.2/payload.ts +421 -0
- package/src/vtc/members/registry-consent/0.1/payload.ts +231 -0
- package/src/vtc/members/update/0.1/payload.ts +2 -2
- package/src/witness/_shared/0.1/outcome-evidence.ts +17 -0
- package/src/witness/session/0.2/payload.ts +197 -0
- package/src/witness/session/submit/0.2/payload.ts +212 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"payload.d.ts","sourceRoot":"","sources":["../../../../../src/vta/witness/list/0.1/payload.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,eAAe,EAAE,gBAAgB,EAAE,GAAG,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AAGjH;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC;;OAEG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,GAAG,CAAC,EAAE,GAAG,CAAC;CACX;AACD;;GAEG;AACH,MAAM,WAAW,6BAA6B;IAC5C;;;;OAIG;IACH,WAAW,EAAE,gBAAgB,EAAE,CAAC;IAChC;;OAEG;IACH,SAAS,EAAE,OAAO,CAAC;IACnB;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,GAAG,CAAC,EAAE,GAAG,CAAC;CACX;AACD;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;OAEG;IACH,YAAY,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,OAAO,EAAE,MAAM,CAAC;IAChB;;OAEG;IACH,eAAe,EAAE,MAAM,CAAC;IACxB;;OAEG;IACH,kBAAkB,EAAE,eAAe,CAAC;IACpC;;OAEG;IACH,UAAU,EAAE,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAOhB,CAAC"}
|
|
@@ -0,0 +1,351 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
|
|
3
|
+
* Source: specs/vta/witness/list/0.1/payload.schema.json
|
|
4
|
+
*/
|
|
5
|
+
/** Trust Task type URI. */
|
|
6
|
+
export const TYPE_URI = "https://trusttasks.org/spec/vta/witness/list/0.1";
|
|
7
|
+
/** Trust Task response type URI (request type URI + "#response"). */
|
|
8
|
+
export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/witness/list/0.1#response";
|
|
9
|
+
/**
|
|
10
|
+
* This specification's payload schema, as a value.
|
|
11
|
+
*
|
|
12
|
+
* SPEC.md §7.2 item 2 is performed against this. It is shipped as data
|
|
13
|
+
* rather than only as a `.json` file because TypeScript types are erased
|
|
14
|
+
* at runtime: without a schema a consumer has nothing to validate, and
|
|
15
|
+
* every REQUIRED payload member is optional in practice. Cross-file
|
|
16
|
+
* `$ref`s are already inlined, so it needs no resolver.
|
|
17
|
+
*/
|
|
18
|
+
export const PAYLOAD_SCHEMA = {
|
|
19
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
20
|
+
"$id": "https://trusttasks.org/spec/vta/witness/list/0.1",
|
|
21
|
+
"title": "VTA Witness — List — payload",
|
|
22
|
+
"description": "A client reads back from its VTA the Verifiable Witness Credentials vta/witness/accept stored for its principal, each with the outcome evidence stored beside it. Every filter is optional and those present are AND-combined.",
|
|
23
|
+
"type": "object",
|
|
24
|
+
"additionalProperties": false,
|
|
25
|
+
"properties": {
|
|
26
|
+
"relationshipDid": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"pattern": "^did:",
|
|
29
|
+
"maxLength": 2048,
|
|
30
|
+
"description": "Only VWCs whose credentialSubject.id is this relationship DID."
|
|
31
|
+
},
|
|
32
|
+
"witness": {
|
|
33
|
+
"type": "string",
|
|
34
|
+
"pattern": "^did:",
|
|
35
|
+
"maxLength": 2048,
|
|
36
|
+
"description": "Only VWCs issued by this witness."
|
|
37
|
+
},
|
|
38
|
+
"pageSize": {
|
|
39
|
+
"type": "integer",
|
|
40
|
+
"minimum": 1,
|
|
41
|
+
"maximum": 100,
|
|
42
|
+
"description": "Maximum entries to return. The VTA MAY return fewer and caps this value."
|
|
43
|
+
},
|
|
44
|
+
"cursor": {
|
|
45
|
+
"type": "string",
|
|
46
|
+
"minLength": 1,
|
|
47
|
+
"maxLength": 4096,
|
|
48
|
+
"description": "Continue a previous page. Opaque: a consumer MUST NOT construct or parse one."
|
|
49
|
+
},
|
|
50
|
+
"ext": {
|
|
51
|
+
"$ref": "#/$defs/Ext"
|
|
52
|
+
}
|
|
53
|
+
},
|
|
54
|
+
"$defs": {
|
|
55
|
+
"Response": {
|
|
56
|
+
"$anchor": "response",
|
|
57
|
+
"title": "VTA Witness — List — response payload",
|
|
58
|
+
"description": "One entry per stored VWC that matched and that the caller may read. Empty when nothing matched, which is a successful answer, not an error.",
|
|
59
|
+
"type": "object",
|
|
60
|
+
"additionalProperties": false,
|
|
61
|
+
"required": [
|
|
62
|
+
"witnessings",
|
|
63
|
+
"truncated"
|
|
64
|
+
],
|
|
65
|
+
"properties": {
|
|
66
|
+
"witnessings": {
|
|
67
|
+
"type": "array",
|
|
68
|
+
"maxItems": 100,
|
|
69
|
+
"items": {
|
|
70
|
+
"$ref": "#/$defs/StoredWitnessing"
|
|
71
|
+
},
|
|
72
|
+
"description": "The matching stored VWCs, each with its evidence."
|
|
73
|
+
},
|
|
74
|
+
"truncated": {
|
|
75
|
+
"type": "boolean",
|
|
76
|
+
"description": "The VTA stopped early. A consumer MUST NOT read a truncated page as a complete account of what is stored."
|
|
77
|
+
},
|
|
78
|
+
"cursor": {
|
|
79
|
+
"type": "string",
|
|
80
|
+
"minLength": 1,
|
|
81
|
+
"maxLength": 4096,
|
|
82
|
+
"description": "Pass to the next request to continue. Absent when the page is the last."
|
|
83
|
+
},
|
|
84
|
+
"ext": {
|
|
85
|
+
"$ref": "#/$defs/Ext"
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
},
|
|
89
|
+
"StoredWitnessing": {
|
|
90
|
+
"title": "StoredWitnessing",
|
|
91
|
+
"description": "One VWC vta/witness/accept stored, as accept answered it, with the time it was stored. The VWC itself travels once, inside evidence.outcome, under the witness's proof.",
|
|
92
|
+
"type": "object",
|
|
93
|
+
"additionalProperties": false,
|
|
94
|
+
"required": [
|
|
95
|
+
"credentialId",
|
|
96
|
+
"witness",
|
|
97
|
+
"relationshipDid",
|
|
98
|
+
"vwcDigestMultibase",
|
|
99
|
+
"acceptedAt",
|
|
100
|
+
"evidence"
|
|
101
|
+
],
|
|
102
|
+
"properties": {
|
|
103
|
+
"credentialId": {
|
|
104
|
+
"type": "string",
|
|
105
|
+
"minLength": 1,
|
|
106
|
+
"maxLength": 256,
|
|
107
|
+
"description": "The credential-vault handle the VWC is stored under: the credentialId vta/witness/accept returned."
|
|
108
|
+
},
|
|
109
|
+
"witness": {
|
|
110
|
+
"type": "string",
|
|
111
|
+
"pattern": "^did:",
|
|
112
|
+
"maxLength": 2048,
|
|
113
|
+
"description": "The witness that issued the VWC: its issuer, which is the recipient of evidence.session."
|
|
114
|
+
},
|
|
115
|
+
"relationshipDid": {
|
|
116
|
+
"type": "string",
|
|
117
|
+
"pattern": "^did:",
|
|
118
|
+
"maxLength": 2048,
|
|
119
|
+
"description": "The relationship DID the VWC names as its credentialSubject.id."
|
|
120
|
+
},
|
|
121
|
+
"vwcDigestMultibase": {
|
|
122
|
+
"$ref": "#/$defs/DigestMultibase",
|
|
123
|
+
"description": "The VWC's digest, as the witness returned it and the VTA checked it at accept: over the RFC 8785 canonicalization of the VWC, proof included."
|
|
124
|
+
},
|
|
125
|
+
"acceptedAt": {
|
|
126
|
+
"type": "string",
|
|
127
|
+
"format": "date-time",
|
|
128
|
+
"description": "When vta/witness/accept stored the VWC."
|
|
129
|
+
},
|
|
130
|
+
"evidence": {
|
|
131
|
+
"$ref": "#/$defs/OutcomeEvidence",
|
|
132
|
+
"description": "The outcome evidence stored with the VWC, each document exactly as stored, never re-serialised: `session`, the witness/session document as the VTA built it, and `outcome`, the witness/session/submit #response as received, which carries the VWC. Of whichever version the session was conducted under."
|
|
133
|
+
},
|
|
134
|
+
"ext": {
|
|
135
|
+
"$ref": "#/$defs/Ext"
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
},
|
|
139
|
+
"Ext": {
|
|
140
|
+
"title": "Ext",
|
|
141
|
+
"description": "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.",
|
|
142
|
+
"type": "object",
|
|
143
|
+
"minProperties": 1,
|
|
144
|
+
"additionalProperties": true,
|
|
145
|
+
"propertyNames": {
|
|
146
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
147
|
+
}
|
|
148
|
+
},
|
|
149
|
+
"OutcomeEvidence": {
|
|
150
|
+
"title": "OutcomeEvidence",
|
|
151
|
+
"description": "One witnessing session's outcome evidence. `session` is the initiating witness/session document; `outcome` is the terminal witness/session/submit #response that the initiating document's own specification declares as its outcome evidence, under the witness's proof, delivering the VWC and its vwcDigestMultibase. A consumer pairs them with a presented VWC by SPEC §4.9.4's four checks and the witnessing checks of witness/session/submit (This response is the outcome evidence).",
|
|
152
|
+
"type": "object",
|
|
153
|
+
"additionalProperties": false,
|
|
154
|
+
"required": [
|
|
155
|
+
"session",
|
|
156
|
+
"outcome"
|
|
157
|
+
],
|
|
158
|
+
"properties": {
|
|
159
|
+
"session": {
|
|
160
|
+
"$ref": "#/$defs/EvidenceDocument",
|
|
161
|
+
"description": "The witness/session document that opened the session. The VWC's taskContext is its id and its taskDigestMultibase is computed over it (SPEC §4.9.3)."
|
|
162
|
+
},
|
|
163
|
+
"outcome": {
|
|
164
|
+
"$ref": "#/$defs/EvidenceDocument",
|
|
165
|
+
"description": "The witness/session/submit #response that closed the session, under the witness's proof. It carries the VWC and its vwcDigestMultibase."
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
},
|
|
169
|
+
"EvidenceDocument": {
|
|
170
|
+
"title": "EvidenceDocument",
|
|
171
|
+
"description": "A whole Trust Task document — `id`, `type`, `payload` and every other member, `proof` included — carried exactly as it was sent or received, never re-serialised: a task digest and a proof are taken over its members, and a re-serialised copy reproduces neither reliably. Typed as an open object so every member survives; the checks that give it meaning belong to the task that reads it.",
|
|
172
|
+
"type": "object",
|
|
173
|
+
"minProperties": 1
|
|
174
|
+
},
|
|
175
|
+
"DigestMultibase": {
|
|
176
|
+
"title": "DigestMultibase",
|
|
177
|
+
"description": "A cryptographic digest as a multibase-encoded multihash — the encoding the W3C Verifiable Credentials Data Model 2.0 defines for `digestMultibase`, and the one `did:webvh` uses for its SCID and entry hashes.\n\nMultihash carries the hash algorithm in-band, so the value is self-describing and the wire format survives an algorithm change without a schema revision; multibase does the same for the base encoding, so a verifier never infers base58 from base64url by context. A bare hex string or a `sha-256:`-style prefix hard-codes one algorithm into the wire contract and is non-conforming here.\n\nThis definition constrains the *encoding only*. What the digest is computed over is stated by each referencing field, because it differs legitimately: a digest over a JSON document is taken over its RFC 8785 (JCS) canonicalization, while a digest over an opaque artifact is taken over its bytes. A field whose input is a JSON document and which does not name a canonicalization is not reproducible.\n\nRestricted to the two multibase headers W3C Controlled Identifiers 1.0 §2.4 normatively requires — `z` (base58btc) and `u` (base64url-no-pad). CID permits others but states that \"interoperability is not guaranteed between implementations using such values\", and a registry whose purpose is interoperability should not mint digests a conforming verifier may be unable to read. The alphabets are enforced rather than assumed: base58btc excludes 0, O, I and l, and an earlier permissive pattern let three published examples carry digests that were not valid base58 at all. base58btc is RECOMMENDED, for consistency with `did:key` and `did:webvh`.",
|
|
178
|
+
"type": "string",
|
|
179
|
+
"minLength": 16,
|
|
180
|
+
"pattern": "^(z[1-9A-HJ-NP-Za-km-z]+|u[A-Za-z0-9_-]+)$",
|
|
181
|
+
"examples": [
|
|
182
|
+
"zQmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR"
|
|
183
|
+
]
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
};
|
|
187
|
+
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
188
|
+
export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
189
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
190
|
+
"$ref": "#/$defs/Response",
|
|
191
|
+
"$defs": {
|
|
192
|
+
"Response": {
|
|
193
|
+
"$anchor": "response",
|
|
194
|
+
"title": "VTA Witness — List — response payload",
|
|
195
|
+
"description": "One entry per stored VWC that matched and that the caller may read. Empty when nothing matched, which is a successful answer, not an error.",
|
|
196
|
+
"type": "object",
|
|
197
|
+
"additionalProperties": false,
|
|
198
|
+
"required": [
|
|
199
|
+
"witnessings",
|
|
200
|
+
"truncated"
|
|
201
|
+
],
|
|
202
|
+
"properties": {
|
|
203
|
+
"witnessings": {
|
|
204
|
+
"type": "array",
|
|
205
|
+
"maxItems": 100,
|
|
206
|
+
"items": {
|
|
207
|
+
"$ref": "#/$defs/StoredWitnessing"
|
|
208
|
+
},
|
|
209
|
+
"description": "The matching stored VWCs, each with its evidence."
|
|
210
|
+
},
|
|
211
|
+
"truncated": {
|
|
212
|
+
"type": "boolean",
|
|
213
|
+
"description": "The VTA stopped early. A consumer MUST NOT read a truncated page as a complete account of what is stored."
|
|
214
|
+
},
|
|
215
|
+
"cursor": {
|
|
216
|
+
"type": "string",
|
|
217
|
+
"minLength": 1,
|
|
218
|
+
"maxLength": 4096,
|
|
219
|
+
"description": "Pass to the next request to continue. Absent when the page is the last."
|
|
220
|
+
},
|
|
221
|
+
"ext": {
|
|
222
|
+
"$ref": "#/$defs/Ext"
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
},
|
|
226
|
+
"StoredWitnessing": {
|
|
227
|
+
"title": "StoredWitnessing",
|
|
228
|
+
"description": "One VWC vta/witness/accept stored, as accept answered it, with the time it was stored. The VWC itself travels once, inside evidence.outcome, under the witness's proof.",
|
|
229
|
+
"type": "object",
|
|
230
|
+
"additionalProperties": false,
|
|
231
|
+
"required": [
|
|
232
|
+
"credentialId",
|
|
233
|
+
"witness",
|
|
234
|
+
"relationshipDid",
|
|
235
|
+
"vwcDigestMultibase",
|
|
236
|
+
"acceptedAt",
|
|
237
|
+
"evidence"
|
|
238
|
+
],
|
|
239
|
+
"properties": {
|
|
240
|
+
"credentialId": {
|
|
241
|
+
"type": "string",
|
|
242
|
+
"minLength": 1,
|
|
243
|
+
"maxLength": 256,
|
|
244
|
+
"description": "The credential-vault handle the VWC is stored under: the credentialId vta/witness/accept returned."
|
|
245
|
+
},
|
|
246
|
+
"witness": {
|
|
247
|
+
"type": "string",
|
|
248
|
+
"pattern": "^did:",
|
|
249
|
+
"maxLength": 2048,
|
|
250
|
+
"description": "The witness that issued the VWC: its issuer, which is the recipient of evidence.session."
|
|
251
|
+
},
|
|
252
|
+
"relationshipDid": {
|
|
253
|
+
"type": "string",
|
|
254
|
+
"pattern": "^did:",
|
|
255
|
+
"maxLength": 2048,
|
|
256
|
+
"description": "The relationship DID the VWC names as its credentialSubject.id."
|
|
257
|
+
},
|
|
258
|
+
"vwcDigestMultibase": {
|
|
259
|
+
"$ref": "#/$defs/DigestMultibase",
|
|
260
|
+
"description": "The VWC's digest, as the witness returned it and the VTA checked it at accept: over the RFC 8785 canonicalization of the VWC, proof included."
|
|
261
|
+
},
|
|
262
|
+
"acceptedAt": {
|
|
263
|
+
"type": "string",
|
|
264
|
+
"format": "date-time",
|
|
265
|
+
"description": "When vta/witness/accept stored the VWC."
|
|
266
|
+
},
|
|
267
|
+
"evidence": {
|
|
268
|
+
"$ref": "#/$defs/OutcomeEvidence",
|
|
269
|
+
"description": "The outcome evidence stored with the VWC, each document exactly as stored, never re-serialised: `session`, the witness/session document as the VTA built it, and `outcome`, the witness/session/submit #response as received, which carries the VWC. Of whichever version the session was conducted under."
|
|
270
|
+
},
|
|
271
|
+
"ext": {
|
|
272
|
+
"$ref": "#/$defs/Ext"
|
|
273
|
+
}
|
|
274
|
+
}
|
|
275
|
+
},
|
|
276
|
+
"Ext": {
|
|
277
|
+
"title": "Ext",
|
|
278
|
+
"description": "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.",
|
|
279
|
+
"type": "object",
|
|
280
|
+
"minProperties": 1,
|
|
281
|
+
"additionalProperties": true,
|
|
282
|
+
"propertyNames": {
|
|
283
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
284
|
+
}
|
|
285
|
+
},
|
|
286
|
+
"OutcomeEvidence": {
|
|
287
|
+
"title": "OutcomeEvidence",
|
|
288
|
+
"description": "One witnessing session's outcome evidence. `session` is the initiating witness/session document; `outcome` is the terminal witness/session/submit #response that the initiating document's own specification declares as its outcome evidence, under the witness's proof, delivering the VWC and its vwcDigestMultibase. A consumer pairs them with a presented VWC by SPEC §4.9.4's four checks and the witnessing checks of witness/session/submit (This response is the outcome evidence).",
|
|
289
|
+
"type": "object",
|
|
290
|
+
"additionalProperties": false,
|
|
291
|
+
"required": [
|
|
292
|
+
"session",
|
|
293
|
+
"outcome"
|
|
294
|
+
],
|
|
295
|
+
"properties": {
|
|
296
|
+
"session": {
|
|
297
|
+
"$ref": "#/$defs/EvidenceDocument",
|
|
298
|
+
"description": "The witness/session document that opened the session. The VWC's taskContext is its id and its taskDigestMultibase is computed over it (SPEC §4.9.3)."
|
|
299
|
+
},
|
|
300
|
+
"outcome": {
|
|
301
|
+
"$ref": "#/$defs/EvidenceDocument",
|
|
302
|
+
"description": "The witness/session/submit #response that closed the session, under the witness's proof. It carries the VWC and its vwcDigestMultibase."
|
|
303
|
+
}
|
|
304
|
+
}
|
|
305
|
+
},
|
|
306
|
+
"EvidenceDocument": {
|
|
307
|
+
"title": "EvidenceDocument",
|
|
308
|
+
"description": "A whole Trust Task document — `id`, `type`, `payload` and every other member, `proof` included — carried exactly as it was sent or received, never re-serialised: a task digest and a proof are taken over its members, and a re-serialised copy reproduces neither reliably. Typed as an open object so every member survives; the checks that give it meaning belong to the task that reads it.",
|
|
309
|
+
"type": "object",
|
|
310
|
+
"minProperties": 1
|
|
311
|
+
},
|
|
312
|
+
"DigestMultibase": {
|
|
313
|
+
"title": "DigestMultibase",
|
|
314
|
+
"description": "A cryptographic digest as a multibase-encoded multihash — the encoding the W3C Verifiable Credentials Data Model 2.0 defines for `digestMultibase`, and the one `did:webvh` uses for its SCID and entry hashes.\n\nMultihash carries the hash algorithm in-band, so the value is self-describing and the wire format survives an algorithm change without a schema revision; multibase does the same for the base encoding, so a verifier never infers base58 from base64url by context. A bare hex string or a `sha-256:`-style prefix hard-codes one algorithm into the wire contract and is non-conforming here.\n\nThis definition constrains the *encoding only*. What the digest is computed over is stated by each referencing field, because it differs legitimately: a digest over a JSON document is taken over its RFC 8785 (JCS) canonicalization, while a digest over an opaque artifact is taken over its bytes. A field whose input is a JSON document and which does not name a canonicalization is not reproducible.\n\nRestricted to the two multibase headers W3C Controlled Identifiers 1.0 §2.4 normatively requires — `z` (base58btc) and `u` (base64url-no-pad). CID permits others but states that \"interoperability is not guaranteed between implementations using such values\", and a registry whose purpose is interoperability should not mint digests a conforming verifier may be unable to read. The alphabets are enforced rather than assumed: base58btc excludes 0, O, I and l, and an earlier permissive pattern let three published examples carry digests that were not valid base58 at all. base58btc is RECOMMENDED, for consistency with `did:key` and `did:webvh`.",
|
|
315
|
+
"type": "string",
|
|
316
|
+
"minLength": 16,
|
|
317
|
+
"pattern": "^(z[1-9A-HJ-NP-Za-km-z]+|u[A-Za-z0-9_-]+)$",
|
|
318
|
+
"examples": [
|
|
319
|
+
"zQmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR"
|
|
320
|
+
]
|
|
321
|
+
}
|
|
322
|
+
}
|
|
323
|
+
};
|
|
324
|
+
/**
|
|
325
|
+
* SPEC.md §7.2 policy for the request variant, from this specification's
|
|
326
|
+
* front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
|
|
327
|
+
* per-specification and cannot be derived from the document alone, and
|
|
328
|
+
* item 2 needs the schema this carries.
|
|
329
|
+
*/
|
|
330
|
+
export const SPEC = {
|
|
331
|
+
typeUri: TYPE_URI,
|
|
332
|
+
isBearer: false,
|
|
333
|
+
isProofRequired: true,
|
|
334
|
+
isRecipientRequired: true,
|
|
335
|
+
isIssuedAtRequired: true,
|
|
336
|
+
payloadSchema: PAYLOAD_SCHEMA,
|
|
337
|
+
};
|
|
338
|
+
/**
|
|
339
|
+
* SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
|
|
340
|
+
* tracks the *issuer* party's requirement because a response swaps the
|
|
341
|
+
* parties (§7.3 item 5).
|
|
342
|
+
*/
|
|
343
|
+
export const RESPONSE_SPEC = {
|
|
344
|
+
typeUri: RESPONSE_TYPE_URI,
|
|
345
|
+
isBearer: false,
|
|
346
|
+
isProofRequired: true,
|
|
347
|
+
isRecipientRequired: true,
|
|
348
|
+
isIssuedAtRequired: true,
|
|
349
|
+
payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
|
|
350
|
+
};
|
|
351
|
+
//# sourceMappingURL=payload.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"payload.js","sourceRoot":"","sources":["../../../../../src/vta/witness/list/0.1/payload.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAiFH,2BAA2B;AAC3B,MAAM,CAAC,MAAM,QAAQ,GAAG,kDAA2D,CAAC;AAKpF,qEAAqE;AACrE,MAAM,CAAC,MAAM,iBAAiB,GAAG,2DAAoE,CAAC;AAKtG;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,cAAc,GAAG;IAC5B,SAAS,EAAE,8CAA8C;IACzD,KAAK,EAAE,kDAAkD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