@openvtc/trust-tasks 0.9.0 → 0.11.0
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/index.d.ts +33 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +33 -0
- package/dist/index.js.map +1 -1
- package/dist/vta/_shared/0.1/context.d.ts +11 -0
- package/dist/vta/_shared/0.1/context.d.ts.map +1 -0
- package/dist/vta/_shared/0.1/context.js +6 -0
- package/dist/vta/_shared/0.1/context.js.map +1 -0
- package/dist/vta/_shared/0.1/service.d.ts +11 -0
- package/dist/vta/_shared/0.1/service.d.ts.map +1 -0
- package/dist/vta/_shared/0.1/service.js +6 -0
- package/dist/vta/_shared/0.1/service.js.map +1 -0
- package/dist/vta/_shared/0.1/webvh-records.d.ts +11 -0
- package/dist/vta/_shared/0.1/webvh-records.d.ts.map +1 -0
- package/dist/vta/_shared/0.1/webvh-records.js +6 -0
- package/dist/vta/_shared/0.1/webvh-records.js.map +1 -0
- package/dist/vta/contexts/create/1.0/payload.d.ts +443 -0
- package/dist/vta/contexts/create/1.0/payload.d.ts.map +1 -0
- package/dist/vta/contexts/create/1.0/payload.js +226 -0
- package/dist/vta/contexts/create/1.0/payload.js.map +1 -0
- package/dist/vta/contexts/delete/1.0/payload.d.ts +256 -0
- package/dist/vta/contexts/delete/1.0/payload.d.ts.map +1 -0
- package/dist/vta/contexts/delete/1.0/payload.js +143 -0
- package/dist/vta/contexts/delete/1.0/payload.js.map +1 -0
- package/dist/vta/contexts/get/1.0/payload.d.ts +405 -0
- package/dist/vta/contexts/get/1.0/payload.d.ts.map +1 -0
- package/dist/vta/contexts/get/1.0/payload.js +212 -0
- package/dist/vta/contexts/get/1.0/payload.js.map +1 -0
- package/dist/vta/contexts/list/1.0/payload.d.ts +460 -0
- package/dist/vta/contexts/list/1.0/payload.d.ts.map +1 -0
- package/dist/vta/contexts/list/1.0/payload.js +237 -0
- package/dist/vta/contexts/list/1.0/payload.js.map +1 -0
- package/dist/vta/contexts/preview-delete/1.0/payload.d.ts +394 -0
- package/dist/vta/contexts/preview-delete/1.0/payload.d.ts.map +1 -0
- package/dist/vta/contexts/preview-delete/1.0/payload.js +209 -0
- package/dist/vta/contexts/preview-delete/1.0/payload.js.map +1 -0
- package/dist/vta/contexts/update/1.0/payload.d.ts +653 -0
- package/dist/vta/contexts/update/1.0/payload.d.ts.map +1 -0
- package/dist/vta/contexts/update/1.0/payload.js +314 -0
- package/dist/vta/contexts/update/1.0/payload.js.map +1 -0
- package/dist/vta/contexts/update-did/1.0/payload.d.ts +419 -0
- package/dist/vta/contexts/update-did/1.0/payload.d.ts.map +1 -0
- package/dist/vta/contexts/update-did/1.0/payload.js +218 -0
- package/dist/vta/contexts/update-did/1.0/payload.js.map +1 -0
- package/dist/vta/services/disable/1.0/payload.d.ts +438 -0
- package/dist/vta/services/disable/1.0/payload.d.ts.map +1 -0
- package/dist/vta/services/disable/1.0/payload.js +235 -0
- package/dist/vta/services/disable/1.0/payload.js.map +1 -0
- package/dist/vta/services/drain/cancel/1.0/payload.d.ts +234 -0
- package/dist/vta/services/drain/cancel/1.0/payload.d.ts.map +1 -0
- package/dist/vta/services/drain/cancel/1.0/payload.js +131 -0
- package/dist/vta/services/drain/cancel/1.0/payload.js.map +1 -0
- package/dist/vta/services/drain/list/1.0/payload.d.ts +352 -0
- package/dist/vta/services/drain/list/1.0/payload.d.ts.map +1 -0
- package/dist/vta/services/drain/list/1.0/payload.js +189 -0
- package/dist/vta/services/drain/list/1.0/payload.js.map +1 -0
- package/dist/vta/services/enable/1.0/payload.d.ts +511 -0
- package/dist/vta/services/enable/1.0/payload.d.ts.map +1 -0
- package/dist/vta/services/enable/1.0/payload.js +262 -0
- package/dist/vta/services/enable/1.0/payload.js.map +1 -0
- package/dist/vta/services/get/1.0/payload.d.ts +399 -0
- package/dist/vta/services/get/1.0/payload.d.ts.map +1 -0
- package/dist/vta/services/get/1.0/payload.js +219 -0
- package/dist/vta/services/get/1.0/payload.js.map +1 -0
- package/dist/vta/services/list/1.0/payload.d.ts +409 -0
- package/dist/vta/services/list/1.0/payload.d.ts.map +1 -0
- package/dist/vta/services/list/1.0/payload.js +221 -0
- package/dist/vta/services/list/1.0/payload.js.map +1 -0
- package/dist/vta/services/rollback/1.0/payload.d.ts +438 -0
- package/dist/vta/services/rollback/1.0/payload.d.ts.map +1 -0
- package/dist/vta/services/rollback/1.0/payload.js +235 -0
- package/dist/vta/services/rollback/1.0/payload.js.map +1 -0
- package/dist/vta/services/update/1.0/payload.d.ts +511 -0
- package/dist/vta/services/update/1.0/payload.d.ts.map +1 -0
- package/dist/vta/services/update/1.0/payload.js +262 -0
- package/dist/vta/services/update/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/agent-name/check/1.0/payload.d.ts +301 -0
- package/dist/vta/webvh/agent-name/check/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/agent-name/check/1.0/payload.js +165 -0
- package/dist/vta/webvh/agent-name/check/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/agent-name/disable/1.0/payload.d.ts +274 -0
- package/dist/vta/webvh/agent-name/disable/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/agent-name/disable/1.0/payload.js +153 -0
- package/dist/vta/webvh/agent-name/disable/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/agent-name/enable/1.0/payload.d.ts +274 -0
- package/dist/vta/webvh/agent-name/enable/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/agent-name/enable/1.0/payload.js +153 -0
- package/dist/vta/webvh/agent-name/enable/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/agent-name/list/1.0/payload.d.ts +377 -0
- package/dist/vta/webvh/agent-name/list/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/agent-name/list/1.0/payload.js +201 -0
- package/dist/vta/webvh/agent-name/list/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/agent-name/remove/1.0/payload.d.ts +274 -0
- package/dist/vta/webvh/agent-name/remove/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/agent-name/remove/1.0/payload.js +153 -0
- package/dist/vta/webvh/agent-name/remove/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/agent-name/set/1.0/payload.d.ts +274 -0
- package/dist/vta/webvh/agent-name/set/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/agent-name/set/1.0/payload.js +153 -0
- package/dist/vta/webvh/agent-name/set/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/dids/create/1.0/payload.d.ts +806 -0
- package/dist/vta/webvh/dids/create/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/dids/create/1.0/payload.js +400 -0
- package/dist/vta/webvh/dids/create/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/dids/delete/1.0/payload.d.ts +257 -0
- package/dist/vta/webvh/dids/delete/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/dids/delete/1.0/payload.js +145 -0
- package/dist/vta/webvh/dids/delete/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/dids/get/1.0/payload.d.ts +539 -0
- package/dist/vta/webvh/dids/get/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/dids/get/1.0/payload.js +282 -0
- package/dist/vta/webvh/dids/get/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/dids/list/1.0/payload.d.ts +537 -0
- package/dist/vta/webvh/dids/list/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/dids/list/1.0/payload.js +278 -0
- package/dist/vta/webvh/dids/list/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/dids/register-with-server/1.0/payload.d.ts +299 -0
- package/dist/vta/webvh/dids/register-with-server/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/dids/register-with-server/1.0/payload.js +163 -0
- package/dist/vta/webvh/dids/register-with-server/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/dids/rotate-keys/1.0/payload.d.ts +357 -0
- package/dist/vta/webvh/dids/rotate-keys/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/dids/rotate-keys/1.0/payload.js +196 -0
- package/dist/vta/webvh/dids/rotate-keys/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/servers/list/1.0/payload.d.ts +366 -0
- package/dist/vta/webvh/servers/list/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/servers/list/1.0/payload.js +200 -0
- package/dist/vta/webvh/servers/list/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/servers/register/1.0/payload.d.ts +335 -0
- package/dist/vta/webvh/servers/register/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/servers/register/1.0/payload.js +183 -0
- package/dist/vta/webvh/servers/register/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/servers/remove/1.0/payload.d.ts +237 -0
- package/dist/vta/webvh/servers/remove/1.0/payload.d.ts.map +1 -0
- package/dist/vta/webvh/servers/remove/1.0/payload.js +137 -0
- package/dist/vta/webvh/servers/remove/1.0/payload.js.map +1 -0
- package/package.json +2 -1
- package/src/index.ts +33 -0
- package/src/vta/_shared/0.1/context.ts +11 -0
- package/src/vta/_shared/0.1/service.ts +11 -0
- package/src/vta/_shared/0.1/webvh-records.ts +11 -0
- package/src/vta/contexts/create/1.0/payload.ts +301 -0
- package/src/vta/contexts/delete/1.0/payload.ts +183 -0
- package/src/vta/contexts/get/1.0/payload.ts +275 -0
- package/src/vta/contexts/list/1.0/payload.ts +309 -0
- package/src/vta/contexts/preview-delete/1.0/payload.ts +267 -0
- package/src/vta/contexts/update/1.0/payload.ts +421 -0
- package/src/vta/contexts/update-did/1.0/payload.ts +285 -0
- package/src/vta/services/disable/1.0/payload.ts +302 -0
- package/src/vta/services/drain/cancel/1.0/payload.ts +169 -0
- package/src/vta/services/drain/list/1.0/payload.ts +241 -0
- package/src/vta/services/enable/1.0/payload.ts +350 -0
- package/src/vta/services/get/1.0/payload.ts +279 -0
- package/src/vta/services/list/1.0/payload.ts +283 -0
- package/src/vta/services/rollback/1.0/payload.ts +302 -0
- package/src/vta/services/update/1.0/payload.ts +350 -0
- package/src/vta/webvh/agent-name/check/1.0/payload.ts +216 -0
- package/src/vta/webvh/agent-name/disable/1.0/payload.ts +197 -0
- package/src/vta/webvh/agent-name/enable/1.0/payload.ts +197 -0
- package/src/vta/webvh/agent-name/list/1.0/payload.ts +258 -0
- package/src/vta/webvh/agent-name/remove/1.0/payload.ts +197 -0
- package/src/vta/webvh/agent-name/set/1.0/payload.ts +197 -0
- package/src/vta/webvh/dids/create/1.0/payload.ts +548 -0
- package/src/vta/webvh/dids/delete/1.0/payload.ts +182 -0
- package/src/vta/webvh/dids/get/1.0/payload.ts +363 -0
- package/src/vta/webvh/dids/list/1.0/payload.ts +361 -0
- package/src/vta/webvh/dids/register-with-server/1.0/payload.ts +212 -0
- package/src/vta/webvh/dids/rotate-keys/1.0/payload.ts +251 -0
- package/src/vta/webvh/servers/list/1.0/payload.ts +248 -0
- package/src/vta/webvh/servers/register/1.0/payload.ts +230 -0
- package/src/vta/webvh/servers/remove/1.0/payload.ts +170 -0
|
@@ -0,0 +1,278 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
|
|
3
|
+
* Source: specs/vta/webvh/dids/list/1.0/payload.schema.json
|
|
4
|
+
*/
|
|
5
|
+
/** Trust Task type URI. */
|
|
6
|
+
export const TYPE_URI = "https://trusttasks.org/spec/vta/webvh/dids/list/1.0";
|
|
7
|
+
/** Trust Task response type URI (request type URI + "#response"). */
|
|
8
|
+
export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/webvh/dids/list/1.0#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/webvh/dids/list/1.0",
|
|
21
|
+
"title": "VTA WebVH DIDs List — payload",
|
|
22
|
+
"type": "object",
|
|
23
|
+
"additionalProperties": false,
|
|
24
|
+
"properties": {
|
|
25
|
+
"contextId": {
|
|
26
|
+
"type": "string",
|
|
27
|
+
"description": "Only DIDs in this context."
|
|
28
|
+
},
|
|
29
|
+
"serverId": {
|
|
30
|
+
"type": "string",
|
|
31
|
+
"description": "Only DIDs published through this hosting server."
|
|
32
|
+
},
|
|
33
|
+
"ext": {
|
|
34
|
+
"$ref": "#/$defs/Ext"
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
"$defs": {
|
|
38
|
+
"Response": {
|
|
39
|
+
"$anchor": "response",
|
|
40
|
+
"title": "VTA WebVH DIDs List — response payload",
|
|
41
|
+
"description": "Success response to vta/webvh/dids/list. Type https://trusttasks.org/spec/vta/webvh/dids/list/1.0#response.",
|
|
42
|
+
"type": "object",
|
|
43
|
+
"additionalProperties": false,
|
|
44
|
+
"required": [
|
|
45
|
+
"dids"
|
|
46
|
+
],
|
|
47
|
+
"properties": {
|
|
48
|
+
"dids": {
|
|
49
|
+
"type": "array",
|
|
50
|
+
"description": "Matching DIDs the caller may see. An empty array is a successful answer and does not imply the VTA holds none.",
|
|
51
|
+
"items": {
|
|
52
|
+
"$ref": "#/$defs/WebvhDidRecord"
|
|
53
|
+
}
|
|
54
|
+
},
|
|
55
|
+
"ext": {
|
|
56
|
+
"$ref": "#/$defs/Ext"
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
"Ext": {
|
|
61
|
+
"title": "Ext",
|
|
62
|
+
"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.",
|
|
63
|
+
"type": "object",
|
|
64
|
+
"minProperties": 1,
|
|
65
|
+
"additionalProperties": true,
|
|
66
|
+
"propertyNames": {
|
|
67
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
68
|
+
}
|
|
69
|
+
},
|
|
70
|
+
"WebvhDidRecord": {
|
|
71
|
+
"title": "WebvhDidRecord",
|
|
72
|
+
"description": "A did:webvh DID as the VTA holds it. The DID document itself is not here — it lives in the log, which `vta/webvh/dids/get` returns on request.",
|
|
73
|
+
"type": "object",
|
|
74
|
+
"additionalProperties": false,
|
|
75
|
+
"required": [
|
|
76
|
+
"did",
|
|
77
|
+
"serverId",
|
|
78
|
+
"mnemonic",
|
|
79
|
+
"scid",
|
|
80
|
+
"contextId",
|
|
81
|
+
"portable",
|
|
82
|
+
"logEntryCount",
|
|
83
|
+
"createdAt",
|
|
84
|
+
"updatedAt"
|
|
85
|
+
],
|
|
86
|
+
"properties": {
|
|
87
|
+
"did": {
|
|
88
|
+
"type": "string",
|
|
89
|
+
"description": "The DID, e.g. `did:webvh:<scid>:example.com:alice`."
|
|
90
|
+
},
|
|
91
|
+
"serverId": {
|
|
92
|
+
"type": "string",
|
|
93
|
+
"description": "Id of the hosting server serving this DID's log. Empty for a serverless DID, whose location comes from the URL it was created with."
|
|
94
|
+
},
|
|
95
|
+
"mnemonic": {
|
|
96
|
+
"type": "string",
|
|
97
|
+
"description": "The hosting server's handle for the record. Unrelated to a BIP-39 phrase; the collision of terms is historical."
|
|
98
|
+
},
|
|
99
|
+
"scid": {
|
|
100
|
+
"type": "string",
|
|
101
|
+
"description": "Self-certifying identifier: the hash committing to the log's first entry. It is what makes the DID's history tamper-evident, and it changes only when the log is re-created — never in place."
|
|
102
|
+
},
|
|
103
|
+
"contextId": {
|
|
104
|
+
"type": "string",
|
|
105
|
+
"description": "Context this DID belongs to. Deleting that context destroys this DID."
|
|
106
|
+
},
|
|
107
|
+
"portable": {
|
|
108
|
+
"type": "boolean",
|
|
109
|
+
"description": "Whether the DID may be moved to another domain without losing its identity. Fixed at creation: a DID created non-portable cannot be made portable later, because portability is a commitment recorded in the log's first entry."
|
|
110
|
+
},
|
|
111
|
+
"logEntryCount": {
|
|
112
|
+
"type": "integer",
|
|
113
|
+
"minimum": 0,
|
|
114
|
+
"description": "Number of entries in the log."
|
|
115
|
+
},
|
|
116
|
+
"preRotationCount": {
|
|
117
|
+
"type": "integer",
|
|
118
|
+
"minimum": 0,
|
|
119
|
+
"default": 0,
|
|
120
|
+
"description": "Pre-rotation keys committed by the most recent entry. `0` means pre-rotation is disabled — a compromise of the current key is then unrecoverable by rotation, because the successor was never committed in advance."
|
|
121
|
+
},
|
|
122
|
+
"nextFragmentId": {
|
|
123
|
+
"type": "integer",
|
|
124
|
+
"minimum": 1,
|
|
125
|
+
"default": 1,
|
|
126
|
+
"description": "Next `#key-{n}` fragment id to mint. Monotonic and never decremented, so a fragment is never reused for a different key."
|
|
127
|
+
},
|
|
128
|
+
"createdAt": {
|
|
129
|
+
"type": "string",
|
|
130
|
+
"format": "date-time"
|
|
131
|
+
},
|
|
132
|
+
"updatedAt": {
|
|
133
|
+
"type": "string",
|
|
134
|
+
"format": "date-time"
|
|
135
|
+
},
|
|
136
|
+
"ext": {
|
|
137
|
+
"$ref": "#/$defs/Ext"
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
};
|
|
143
|
+
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
144
|
+
export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
145
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
146
|
+
"$ref": "#/$defs/Response",
|
|
147
|
+
"$defs": {
|
|
148
|
+
"Response": {
|
|
149
|
+
"$anchor": "response",
|
|
150
|
+
"title": "VTA WebVH DIDs List — response payload",
|
|
151
|
+
"description": "Success response to vta/webvh/dids/list. Type https://trusttasks.org/spec/vta/webvh/dids/list/1.0#response.",
|
|
152
|
+
"type": "object",
|
|
153
|
+
"additionalProperties": false,
|
|
154
|
+
"required": [
|
|
155
|
+
"dids"
|
|
156
|
+
],
|
|
157
|
+
"properties": {
|
|
158
|
+
"dids": {
|
|
159
|
+
"type": "array",
|
|
160
|
+
"description": "Matching DIDs the caller may see. An empty array is a successful answer and does not imply the VTA holds none.",
|
|
161
|
+
"items": {
|
|
162
|
+
"$ref": "#/$defs/WebvhDidRecord"
|
|
163
|
+
}
|
|
164
|
+
},
|
|
165
|
+
"ext": {
|
|
166
|
+
"$ref": "#/$defs/Ext"
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
},
|
|
170
|
+
"Ext": {
|
|
171
|
+
"title": "Ext",
|
|
172
|
+
"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.",
|
|
173
|
+
"type": "object",
|
|
174
|
+
"minProperties": 1,
|
|
175
|
+
"additionalProperties": true,
|
|
176
|
+
"propertyNames": {
|
|
177
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
178
|
+
}
|
|
179
|
+
},
|
|
180
|
+
"WebvhDidRecord": {
|
|
181
|
+
"title": "WebvhDidRecord",
|
|
182
|
+
"description": "A did:webvh DID as the VTA holds it. The DID document itself is not here — it lives in the log, which `vta/webvh/dids/get` returns on request.",
|
|
183
|
+
"type": "object",
|
|
184
|
+
"additionalProperties": false,
|
|
185
|
+
"required": [
|
|
186
|
+
"did",
|
|
187
|
+
"serverId",
|
|
188
|
+
"mnemonic",
|
|
189
|
+
"scid",
|
|
190
|
+
"contextId",
|
|
191
|
+
"portable",
|
|
192
|
+
"logEntryCount",
|
|
193
|
+
"createdAt",
|
|
194
|
+
"updatedAt"
|
|
195
|
+
],
|
|
196
|
+
"properties": {
|
|
197
|
+
"did": {
|
|
198
|
+
"type": "string",
|
|
199
|
+
"description": "The DID, e.g. `did:webvh:<scid>:example.com:alice`."
|
|
200
|
+
},
|
|
201
|
+
"serverId": {
|
|
202
|
+
"type": "string",
|
|
203
|
+
"description": "Id of the hosting server serving this DID's log. Empty for a serverless DID, whose location comes from the URL it was created with."
|
|
204
|
+
},
|
|
205
|
+
"mnemonic": {
|
|
206
|
+
"type": "string",
|
|
207
|
+
"description": "The hosting server's handle for the record. Unrelated to a BIP-39 phrase; the collision of terms is historical."
|
|
208
|
+
},
|
|
209
|
+
"scid": {
|
|
210
|
+
"type": "string",
|
|
211
|
+
"description": "Self-certifying identifier: the hash committing to the log's first entry. It is what makes the DID's history tamper-evident, and it changes only when the log is re-created — never in place."
|
|
212
|
+
},
|
|
213
|
+
"contextId": {
|
|
214
|
+
"type": "string",
|
|
215
|
+
"description": "Context this DID belongs to. Deleting that context destroys this DID."
|
|
216
|
+
},
|
|
217
|
+
"portable": {
|
|
218
|
+
"type": "boolean",
|
|
219
|
+
"description": "Whether the DID may be moved to another domain without losing its identity. Fixed at creation: a DID created non-portable cannot be made portable later, because portability is a commitment recorded in the log's first entry."
|
|
220
|
+
},
|
|
221
|
+
"logEntryCount": {
|
|
222
|
+
"type": "integer",
|
|
223
|
+
"minimum": 0,
|
|
224
|
+
"description": "Number of entries in the log."
|
|
225
|
+
},
|
|
226
|
+
"preRotationCount": {
|
|
227
|
+
"type": "integer",
|
|
228
|
+
"minimum": 0,
|
|
229
|
+
"default": 0,
|
|
230
|
+
"description": "Pre-rotation keys committed by the most recent entry. `0` means pre-rotation is disabled — a compromise of the current key is then unrecoverable by rotation, because the successor was never committed in advance."
|
|
231
|
+
},
|
|
232
|
+
"nextFragmentId": {
|
|
233
|
+
"type": "integer",
|
|
234
|
+
"minimum": 1,
|
|
235
|
+
"default": 1,
|
|
236
|
+
"description": "Next `#key-{n}` fragment id to mint. Monotonic and never decremented, so a fragment is never reused for a different key."
|
|
237
|
+
},
|
|
238
|
+
"createdAt": {
|
|
239
|
+
"type": "string",
|
|
240
|
+
"format": "date-time"
|
|
241
|
+
},
|
|
242
|
+
"updatedAt": {
|
|
243
|
+
"type": "string",
|
|
244
|
+
"format": "date-time"
|
|
245
|
+
},
|
|
246
|
+
"ext": {
|
|
247
|
+
"$ref": "#/$defs/Ext"
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
};
|
|
253
|
+
/**
|
|
254
|
+
* SPEC.md §7.2 policy for the request variant, from this specification's
|
|
255
|
+
* front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
|
|
256
|
+
* per-specification and cannot be derived from the document alone, and
|
|
257
|
+
* item 2 needs the schema this carries.
|
|
258
|
+
*/
|
|
259
|
+
export const SPEC = {
|
|
260
|
+
typeUri: TYPE_URI,
|
|
261
|
+
isBearer: false,
|
|
262
|
+
isProofRequired: false,
|
|
263
|
+
isRecipientRequired: true,
|
|
264
|
+
payloadSchema: PAYLOAD_SCHEMA,
|
|
265
|
+
};
|
|
266
|
+
/**
|
|
267
|
+
* SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
|
|
268
|
+
* tracks the *issuer* party's requirement because a response swaps the
|
|
269
|
+
* parties (§7.3 item 5).
|
|
270
|
+
*/
|
|
271
|
+
export const RESPONSE_SPEC = {
|
|
272
|
+
typeUri: RESPONSE_TYPE_URI,
|
|
273
|
+
isBearer: false,
|
|
274
|
+
isProofRequired: false,
|
|
275
|
+
isRecipientRequired: true,
|
|
276
|
+
payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
|
|
277
|
+
};
|
|
278
|
+
//# sourceMappingURL=payload.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"payload.js","sourceRoot":"","sources":["../../../../../../src/vta/webvh/dids/list/1.0/payload.ts"],"names":[],"mappings":"AAAA;;;GAGG;AA0EH,2BAA2B;AAC3B,MAAM,CAAC,MAAM,QAAQ,GAAG,qDAA8D,CAAC;AAKvF,qEAAqE;AACrE,MAAM,CAAC,MAAM,i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
|
+
* Source: specs/vta/webvh/dids/register-with-server/1.0/payload.schema.json
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Hand an existing DID's log to a hosting server so it is served there.
|
|
7
|
+
*/
|
|
8
|
+
export interface VTAWebVHDIDsRegisterWithServerPayload {
|
|
9
|
+
did: string;
|
|
10
|
+
/**
|
|
11
|
+
* Hosting server to register with.
|
|
12
|
+
*/
|
|
13
|
+
serverId: string;
|
|
14
|
+
/**
|
|
15
|
+
* Overwrite a registration the server already holds at this location. Default false: the location may be somebody else's identity.
|
|
16
|
+
*/
|
|
17
|
+
force?: boolean;
|
|
18
|
+
/**
|
|
19
|
+
* Domain to publish under, when the server serves more than one.
|
|
20
|
+
*/
|
|
21
|
+
domain?: string;
|
|
22
|
+
ext?: Ext;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* 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.
|
|
26
|
+
*/
|
|
27
|
+
export interface Ext {
|
|
28
|
+
[k: string]: unknown | undefined;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Success response to vta/webvh/dids/register-with-server. Type https://trusttasks.org/spec/vta/webvh/dids/register-with-server/1.0#response.
|
|
32
|
+
*/
|
|
33
|
+
export interface VTAWebVHDIDsRegisterWithServerResponsePayload {
|
|
34
|
+
did: string;
|
|
35
|
+
serverId: string;
|
|
36
|
+
/**
|
|
37
|
+
* Entries the server accepted. Compare it with the DID's own log length: a shorter count means the server holds a truncated history and will resolve to an older document.
|
|
38
|
+
*/
|
|
39
|
+
logEntryCount: number;
|
|
40
|
+
ext?: Ext;
|
|
41
|
+
}
|
|
42
|
+
/** Trust Task type URI. */
|
|
43
|
+
export declare const TYPE_URI: "https://trusttasks.org/spec/vta/webvh/dids/register-with-server/1.0";
|
|
44
|
+
/** Stable alias for this specification's request payload shape. */
|
|
45
|
+
export type Payload = VTAWebVHDIDsRegisterWithServerPayload;
|
|
46
|
+
/** Trust Task response type URI (request type URI + "#response"). */
|
|
47
|
+
export declare const RESPONSE_TYPE_URI: "https://trusttasks.org/spec/vta/webvh/dids/register-with-server/1.0#response";
|
|
48
|
+
/** Stable alias for this specification's success-response payload shape. */
|
|
49
|
+
export type Response = VTAWebVHDIDsRegisterWithServerResponsePayload;
|
|
50
|
+
/**
|
|
51
|
+
* This specification's payload schema, as a value.
|
|
52
|
+
*
|
|
53
|
+
* SPEC.md §7.2 item 2 is performed against this. It is shipped as data
|
|
54
|
+
* rather than only as a `.json` file because TypeScript types are erased
|
|
55
|
+
* at runtime: without a schema a consumer has nothing to validate, and
|
|
56
|
+
* every REQUIRED payload member is optional in practice. Cross-file
|
|
57
|
+
* `$ref`s are already inlined, so it needs no resolver.
|
|
58
|
+
*/
|
|
59
|
+
export declare const PAYLOAD_SCHEMA: {
|
|
60
|
+
readonly $schema: "https://json-schema.org/draft/2020-12/schema";
|
|
61
|
+
readonly $id: "https://trusttasks.org/spec/vta/webvh/dids/register-with-server/1.0";
|
|
62
|
+
readonly title: "VTA WebVH DIDs Register-With-Server — payload";
|
|
63
|
+
readonly description: "Hand an existing DID's log to a hosting server so it is served there.";
|
|
64
|
+
readonly type: "object";
|
|
65
|
+
readonly additionalProperties: false;
|
|
66
|
+
readonly required: readonly ["did", "serverId"];
|
|
67
|
+
readonly properties: {
|
|
68
|
+
readonly did: {
|
|
69
|
+
readonly type: "string";
|
|
70
|
+
readonly minLength: 1;
|
|
71
|
+
};
|
|
72
|
+
readonly serverId: {
|
|
73
|
+
readonly type: "string";
|
|
74
|
+
readonly minLength: 1;
|
|
75
|
+
readonly description: "Hosting server to register with.";
|
|
76
|
+
};
|
|
77
|
+
readonly force: {
|
|
78
|
+
readonly type: "boolean";
|
|
79
|
+
readonly default: false;
|
|
80
|
+
readonly description: "Overwrite a registration the server already holds at this location. Default false: the location may be somebody else's identity.";
|
|
81
|
+
};
|
|
82
|
+
readonly domain: {
|
|
83
|
+
readonly type: "string";
|
|
84
|
+
readonly description: "Domain to publish under, when the server serves more than one.";
|
|
85
|
+
};
|
|
86
|
+
readonly ext: {
|
|
87
|
+
readonly $ref: "#/$defs/Ext";
|
|
88
|
+
};
|
|
89
|
+
};
|
|
90
|
+
readonly $defs: {
|
|
91
|
+
readonly Response: {
|
|
92
|
+
readonly $anchor: "response";
|
|
93
|
+
readonly title: "VTA WebVH DIDs Register-With-Server — response payload";
|
|
94
|
+
readonly description: "Success response to vta/webvh/dids/register-with-server. Type https://trusttasks.org/spec/vta/webvh/dids/register-with-server/1.0#response.";
|
|
95
|
+
readonly type: "object";
|
|
96
|
+
readonly additionalProperties: false;
|
|
97
|
+
readonly required: readonly ["did", "serverId", "logEntryCount"];
|
|
98
|
+
readonly properties: {
|
|
99
|
+
readonly did: {
|
|
100
|
+
readonly type: "string";
|
|
101
|
+
};
|
|
102
|
+
readonly serverId: {
|
|
103
|
+
readonly type: "string";
|
|
104
|
+
};
|
|
105
|
+
readonly logEntryCount: {
|
|
106
|
+
readonly type: "integer";
|
|
107
|
+
readonly minimum: 0;
|
|
108
|
+
readonly description: "Entries the server accepted. Compare it with the DID's own log length: a shorter count means the server holds a truncated history and will resolve to an older document.";
|
|
109
|
+
};
|
|
110
|
+
readonly ext: {
|
|
111
|
+
readonly $ref: "#/$defs/Ext";
|
|
112
|
+
};
|
|
113
|
+
};
|
|
114
|
+
};
|
|
115
|
+
readonly Ext: {
|
|
116
|
+
readonly title: "Ext";
|
|
117
|
+
readonly 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.";
|
|
118
|
+
readonly type: "object";
|
|
119
|
+
readonly minProperties: 1;
|
|
120
|
+
readonly additionalProperties: true;
|
|
121
|
+
readonly propertyNames: {
|
|
122
|
+
readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
|
|
123
|
+
};
|
|
124
|
+
};
|
|
125
|
+
};
|
|
126
|
+
};
|
|
127
|
+
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
128
|
+
export declare const RESPONSE_PAYLOAD_SCHEMA: {
|
|
129
|
+
readonly $schema: "https://json-schema.org/draft/2020-12/schema";
|
|
130
|
+
readonly $ref: "#/$defs/Response";
|
|
131
|
+
readonly $defs: {
|
|
132
|
+
readonly Response: {
|
|
133
|
+
readonly $anchor: "response";
|
|
134
|
+
readonly title: "VTA WebVH DIDs Register-With-Server — response payload";
|
|
135
|
+
readonly description: "Success response to vta/webvh/dids/register-with-server. Type https://trusttasks.org/spec/vta/webvh/dids/register-with-server/1.0#response.";
|
|
136
|
+
readonly type: "object";
|
|
137
|
+
readonly additionalProperties: false;
|
|
138
|
+
readonly required: readonly ["did", "serverId", "logEntryCount"];
|
|
139
|
+
readonly properties: {
|
|
140
|
+
readonly did: {
|
|
141
|
+
readonly type: "string";
|
|
142
|
+
};
|
|
143
|
+
readonly serverId: {
|
|
144
|
+
readonly type: "string";
|
|
145
|
+
};
|
|
146
|
+
readonly logEntryCount: {
|
|
147
|
+
readonly type: "integer";
|
|
148
|
+
readonly minimum: 0;
|
|
149
|
+
readonly description: "Entries the server accepted. Compare it with the DID's own log length: a shorter count means the server holds a truncated history and will resolve to an older document.";
|
|
150
|
+
};
|
|
151
|
+
readonly ext: {
|
|
152
|
+
readonly $ref: "#/$defs/Ext";
|
|
153
|
+
};
|
|
154
|
+
};
|
|
155
|
+
};
|
|
156
|
+
readonly Ext: {
|
|
157
|
+
readonly title: "Ext";
|
|
158
|
+
readonly 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.";
|
|
159
|
+
readonly type: "object";
|
|
160
|
+
readonly minProperties: 1;
|
|
161
|
+
readonly additionalProperties: true;
|
|
162
|
+
readonly propertyNames: {
|
|
163
|
+
readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
|
|
164
|
+
};
|
|
165
|
+
};
|
|
166
|
+
};
|
|
167
|
+
};
|
|
168
|
+
/**
|
|
169
|
+
* SPEC.md §7.2 policy for the request variant, from this specification's
|
|
170
|
+
* front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
|
|
171
|
+
* per-specification and cannot be derived from the document alone, and
|
|
172
|
+
* item 2 needs the schema this carries.
|
|
173
|
+
*/
|
|
174
|
+
export declare const SPEC: {
|
|
175
|
+
readonly typeUri: "https://trusttasks.org/spec/vta/webvh/dids/register-with-server/1.0";
|
|
176
|
+
readonly isBearer: false;
|
|
177
|
+
readonly isProofRequired: true;
|
|
178
|
+
readonly isRecipientRequired: true;
|
|
179
|
+
readonly payloadSchema: {
|
|
180
|
+
readonly $schema: "https://json-schema.org/draft/2020-12/schema";
|
|
181
|
+
readonly $id: "https://trusttasks.org/spec/vta/webvh/dids/register-with-server/1.0";
|
|
182
|
+
readonly title: "VTA WebVH DIDs Register-With-Server — payload";
|
|
183
|
+
readonly description: "Hand an existing DID's log to a hosting server so it is served there.";
|
|
184
|
+
readonly type: "object";
|
|
185
|
+
readonly additionalProperties: false;
|
|
186
|
+
readonly required: readonly ["did", "serverId"];
|
|
187
|
+
readonly properties: {
|
|
188
|
+
readonly did: {
|
|
189
|
+
readonly type: "string";
|
|
190
|
+
readonly minLength: 1;
|
|
191
|
+
};
|
|
192
|
+
readonly serverId: {
|
|
193
|
+
readonly type: "string";
|
|
194
|
+
readonly minLength: 1;
|
|
195
|
+
readonly description: "Hosting server to register with.";
|
|
196
|
+
};
|
|
197
|
+
readonly force: {
|
|
198
|
+
readonly type: "boolean";
|
|
199
|
+
readonly default: false;
|
|
200
|
+
readonly description: "Overwrite a registration the server already holds at this location. Default false: the location may be somebody else's identity.";
|
|
201
|
+
};
|
|
202
|
+
readonly domain: {
|
|
203
|
+
readonly type: "string";
|
|
204
|
+
readonly description: "Domain to publish under, when the server serves more than one.";
|
|
205
|
+
};
|
|
206
|
+
readonly ext: {
|
|
207
|
+
readonly $ref: "#/$defs/Ext";
|
|
208
|
+
};
|
|
209
|
+
};
|
|
210
|
+
readonly $defs: {
|
|
211
|
+
readonly Response: {
|
|
212
|
+
readonly $anchor: "response";
|
|
213
|
+
readonly title: "VTA WebVH DIDs Register-With-Server — response payload";
|
|
214
|
+
readonly description: "Success response to vta/webvh/dids/register-with-server. Type https://trusttasks.org/spec/vta/webvh/dids/register-with-server/1.0#response.";
|
|
215
|
+
readonly type: "object";
|
|
216
|
+
readonly additionalProperties: false;
|
|
217
|
+
readonly required: readonly ["did", "serverId", "logEntryCount"];
|
|
218
|
+
readonly properties: {
|
|
219
|
+
readonly did: {
|
|
220
|
+
readonly type: "string";
|
|
221
|
+
};
|
|
222
|
+
readonly serverId: {
|
|
223
|
+
readonly type: "string";
|
|
224
|
+
};
|
|
225
|
+
readonly logEntryCount: {
|
|
226
|
+
readonly type: "integer";
|
|
227
|
+
readonly minimum: 0;
|
|
228
|
+
readonly description: "Entries the server accepted. Compare it with the DID's own log length: a shorter count means the server holds a truncated history and will resolve to an older document.";
|
|
229
|
+
};
|
|
230
|
+
readonly ext: {
|
|
231
|
+
readonly $ref: "#/$defs/Ext";
|
|
232
|
+
};
|
|
233
|
+
};
|
|
234
|
+
};
|
|
235
|
+
readonly Ext: {
|
|
236
|
+
readonly title: "Ext";
|
|
237
|
+
readonly 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.";
|
|
238
|
+
readonly type: "object";
|
|
239
|
+
readonly minProperties: 1;
|
|
240
|
+
readonly additionalProperties: true;
|
|
241
|
+
readonly propertyNames: {
|
|
242
|
+
readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
|
|
243
|
+
};
|
|
244
|
+
};
|
|
245
|
+
};
|
|
246
|
+
};
|
|
247
|
+
};
|
|
248
|
+
/**
|
|
249
|
+
* SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
|
|
250
|
+
* tracks the *issuer* party's requirement because a response swaps the
|
|
251
|
+
* parties (§7.3 item 5).
|
|
252
|
+
*/
|
|
253
|
+
export declare const RESPONSE_SPEC: {
|
|
254
|
+
readonly typeUri: "https://trusttasks.org/spec/vta/webvh/dids/register-with-server/1.0#response";
|
|
255
|
+
readonly isBearer: false;
|
|
256
|
+
readonly isProofRequired: true;
|
|
257
|
+
readonly isRecipientRequired: true;
|
|
258
|
+
readonly payloadSchema: {
|
|
259
|
+
readonly $schema: "https://json-schema.org/draft/2020-12/schema";
|
|
260
|
+
readonly $ref: "#/$defs/Response";
|
|
261
|
+
readonly $defs: {
|
|
262
|
+
readonly Response: {
|
|
263
|
+
readonly $anchor: "response";
|
|
264
|
+
readonly title: "VTA WebVH DIDs Register-With-Server — response payload";
|
|
265
|
+
readonly description: "Success response to vta/webvh/dids/register-with-server. Type https://trusttasks.org/spec/vta/webvh/dids/register-with-server/1.0#response.";
|
|
266
|
+
readonly type: "object";
|
|
267
|
+
readonly additionalProperties: false;
|
|
268
|
+
readonly required: readonly ["did", "serverId", "logEntryCount"];
|
|
269
|
+
readonly properties: {
|
|
270
|
+
readonly did: {
|
|
271
|
+
readonly type: "string";
|
|
272
|
+
};
|
|
273
|
+
readonly serverId: {
|
|
274
|
+
readonly type: "string";
|
|
275
|
+
};
|
|
276
|
+
readonly logEntryCount: {
|
|
277
|
+
readonly type: "integer";
|
|
278
|
+
readonly minimum: 0;
|
|
279
|
+
readonly description: "Entries the server accepted. Compare it with the DID's own log length: a shorter count means the server holds a truncated history and will resolve to an older document.";
|
|
280
|
+
};
|
|
281
|
+
readonly ext: {
|
|
282
|
+
readonly $ref: "#/$defs/Ext";
|
|
283
|
+
};
|
|
284
|
+
};
|
|
285
|
+
};
|
|
286
|
+
readonly Ext: {
|
|
287
|
+
readonly title: "Ext";
|
|
288
|
+
readonly 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.";
|
|
289
|
+
readonly type: "object";
|
|
290
|
+
readonly minProperties: 1;
|
|
291
|
+
readonly additionalProperties: true;
|
|
292
|
+
readonly propertyNames: {
|
|
293
|
+
readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
|
|
294
|
+
};
|
|
295
|
+
};
|
|
296
|
+
};
|
|
297
|
+
};
|
|
298
|
+
};
|
|
299
|
+
//# sourceMappingURL=payload.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"payload.d.ts","sourceRoot":"","sources":["../../../../../../src/vta/webvh/dids/register-with-server/1.0/payload.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AACH,MAAM,WAAW,qCAAqC;IACpD,GAAG,EAAE,MAAM,CAAC;IACZ;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,GAAG,CAAC,EAAE,GAAG,CAAC;CACX;AACD;;GAEG;AACH,MAAM,WAAW,GAAG;IAClB,CAAC,CAAC,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,CAAC;CAClC;AACD;;GAEG;AACH,MAAM,WAAW,6CAA6C;IAC5D,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,aAAa,EAAE,MAAM,CAAC;IACtB,GAAG,CAAC,EAAE,GAAG,CAAC;CACX;AAED,2BAA2B;AAC3B,eAAO,MAAM,QAAQ,EAAG,qEAA8E,CAAC;AAEvG,mEAAmE;AACnE,MAAM,MAAM,OAAO,GAAG,qCAAqC,CAAC;AAE5D,qEAAqE;AACrE,eAAO,MAAM,iBAAiB,EAAG,8EAAuF,CAAC;AAEzH,4EAA4E;AAC5E,MAAM,MAAM,QAAQ,GAAG,6CAA6C,CAAC;AAErE;;;;;;;;GAQG;AACH,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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