@openvtc/trust-tasks 0.16.8 → 0.16.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/CHANGELOG.md +285 -0
- package/dist/_shared/components.d.ts +206 -7
- package/dist/_shared/components.d.ts.map +1 -1
- package/dist/device/list/0.1/payload.d.ts +4 -4
- package/dist/device/list/0.1/payload.d.ts.map +1 -1
- package/dist/device/list/0.1/payload.js +6 -2
- package/dist/device/list/0.1/payload.js.map +1 -1
- package/dist/device/list/0.2/payload.d.ts +4 -4
- package/dist/device/list/0.2/payload.d.ts.map +1 -1
- package/dist/device/list/0.2/payload.js +6 -2
- package/dist/device/list/0.2/payload.js.map +1 -1
- package/dist/device/register/0.1/payload.d.ts +4 -4
- package/dist/device/register/0.1/payload.d.ts.map +1 -1
- package/dist/device/register/0.1/payload.js +6 -2
- package/dist/device/register/0.1/payload.js.map +1 -1
- package/dist/device/register/0.2/payload.d.ts +4 -4
- package/dist/device/register/0.2/payload.d.ts.map +1 -1
- package/dist/device/register/0.2/payload.js +6 -2
- package/dist/device/register/0.2/payload.js.map +1 -1
- package/dist/index.d.ts +31 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +31 -0
- package/dist/index.js.map +1 -1
- package/dist/persona/_shared/0.1/persona-record.d.ts +22 -0
- package/dist/persona/_shared/0.1/persona-record.d.ts.map +1 -0
- package/dist/persona/_shared/0.1/persona-record.js +6 -0
- package/dist/persona/_shared/0.1/persona-record.js.map +1 -0
- package/dist/persona/attribute/delete/1.0/payload.d.ts +351 -0
- package/dist/persona/attribute/delete/1.0/payload.d.ts.map +1 -0
- package/dist/persona/attribute/delete/1.0/payload.js +188 -0
- package/dist/persona/attribute/delete/1.0/payload.js.map +1 -0
- package/dist/persona/attribute/list/1.0/payload.d.ts +895 -0
- package/dist/persona/attribute/list/1.0/payload.d.ts.map +1 -0
- package/dist/persona/attribute/list/1.0/payload.js +532 -0
- package/dist/persona/attribute/list/1.0/payload.js.map +1 -0
- package/dist/persona/attribute/put/1.0/payload.d.ts +829 -0
- package/dist/persona/attribute/put/1.0/payload.d.ts.map +1 -0
- package/dist/persona/attribute/put/1.0/payload.js +487 -0
- package/dist/persona/attribute/put/1.0/payload.js.map +1 -0
- package/dist/persona/binding/get/1.0/payload.d.ts +382 -0
- package/dist/persona/binding/get/1.0/payload.d.ts.map +1 -0
- package/dist/persona/binding/get/1.0/payload.js +206 -0
- package/dist/persona/binding/get/1.0/payload.js.map +1 -0
- package/dist/persona/binding/list/1.0/payload.d.ts +387 -0
- package/dist/persona/binding/list/1.0/payload.d.ts.map +1 -0
- package/dist/persona/binding/list/1.0/payload.js +210 -0
- package/dist/persona/binding/list/1.0/payload.js.map +1 -0
- package/dist/persona/binding/set/1.0/payload.d.ts +545 -0
- package/dist/persona/binding/set/1.0/payload.d.ts.map +1 -0
- package/dist/persona/binding/set/1.0/payload.js +302 -0
- package/dist/persona/binding/set/1.0/payload.js.map +1 -0
- package/dist/persona/contact/delete/1.0/payload.d.ts +313 -0
- package/dist/persona/contact/delete/1.0/payload.d.ts.map +1 -0
- package/dist/persona/contact/delete/1.0/payload.js +174 -0
- package/dist/persona/contact/delete/1.0/payload.js.map +1 -0
- package/dist/persona/contact/get/1.0/payload.d.ts +1027 -0
- package/dist/persona/contact/get/1.0/payload.d.ts.map +1 -0
- package/dist/persona/contact/get/1.0/payload.js +606 -0
- package/dist/persona/contact/get/1.0/payload.js.map +1 -0
- package/dist/persona/contact/list/1.0/payload.d.ts +490 -0
- package/dist/persona/contact/list/1.0/payload.d.ts.map +1 -0
- package/dist/persona/contact/list/1.0/payload.js +262 -0
- package/dist/persona/contact/list/1.0/payload.js.map +1 -0
- package/dist/persona/contact/put/1.0/payload.d.ts +885 -0
- package/dist/persona/contact/put/1.0/payload.d.ts.map +1 -0
- package/dist/persona/contact/put/1.0/payload.js +518 -0
- package/dist/persona/contact/put/1.0/payload.js.map +1 -0
- package/dist/persona/correlation/analyze/1.0/payload.d.ts +648 -0
- package/dist/persona/correlation/analyze/1.0/payload.d.ts.map +1 -0
- package/dist/persona/correlation/analyze/1.0/payload.js +338 -0
- package/dist/persona/correlation/analyze/1.0/payload.js.map +1 -0
- package/dist/persona/disclosure/history/1.0/payload.d.ts +639 -0
- package/dist/persona/disclosure/history/1.0/payload.d.ts.map +1 -0
- package/dist/persona/disclosure/history/1.0/payload.js +339 -0
- package/dist/persona/disclosure/history/1.0/payload.js.map +1 -0
- package/dist/persona/disclosure/present/1.0/payload.d.ts +400 -0
- package/dist/persona/disclosure/present/1.0/payload.d.ts.map +1 -0
- package/dist/persona/disclosure/present/1.0/payload.js +211 -0
- package/dist/persona/disclosure/present/1.0/payload.js.map +1 -0
- package/dist/persona/disclosure/preview/1.0/payload.d.ts +858 -0
- package/dist/persona/disclosure/preview/1.0/payload.d.ts.map +1 -0
- package/dist/persona/disclosure/preview/1.0/payload.js +480 -0
- package/dist/persona/disclosure/preview/1.0/payload.js.map +1 -0
- package/dist/persona/local/binding/set/1.0/payload.d.ts +394 -0
- package/dist/persona/local/binding/set/1.0/payload.d.ts.map +1 -0
- package/dist/persona/local/binding/set/1.0/payload.js +226 -0
- package/dist/persona/local/binding/set/1.0/payload.js.map +1 -0
- package/dist/persona/local/profile/delete/1.0/payload.d.ts +311 -0
- package/dist/persona/local/profile/delete/1.0/payload.d.ts.map +1 -0
- package/dist/persona/local/profile/delete/1.0/payload.js +173 -0
- package/dist/persona/local/profile/delete/1.0/payload.js.map +1 -0
- package/dist/persona/local/profile/get/1.0/payload.d.ts +368 -0
- package/dist/persona/local/profile/get/1.0/payload.d.ts.map +1 -0
- package/dist/persona/local/profile/get/1.0/payload.js +210 -0
- package/dist/persona/local/profile/get/1.0/payload.js.map +1 -0
- package/dist/persona/local/profile/list/1.0/payload.d.ts +387 -0
- package/dist/persona/local/profile/list/1.0/payload.d.ts.map +1 -0
- package/dist/persona/local/profile/list/1.0/payload.js +214 -0
- package/dist/persona/local/profile/list/1.0/payload.js.map +1 -0
- package/dist/persona/local/profile/put/1.0/payload.d.ts +545 -0
- package/dist/persona/local/profile/put/1.0/payload.d.ts.map +1 -0
- package/dist/persona/local/profile/put/1.0/payload.js +315 -0
- package/dist/persona/local/profile/put/1.0/payload.js.map +1 -0
- package/dist/persona/profile/delete/1.0/payload.d.ts +350 -0
- package/dist/persona/profile/delete/1.0/payload.d.ts.map +1 -0
- package/dist/persona/profile/delete/1.0/payload.js +189 -0
- package/dist/persona/profile/delete/1.0/payload.js.map +1 -0
- package/dist/persona/profile/get/1.0/payload.d.ts +1307 -0
- package/dist/persona/profile/get/1.0/payload.d.ts.map +1 -0
- package/dist/persona/profile/get/1.0/payload.js +804 -0
- package/dist/persona/profile/get/1.0/payload.js.map +1 -0
- package/dist/persona/profile/list/1.0/payload.d.ts +1120 -0
- package/dist/persona/profile/list/1.0/payload.d.ts.map +1 -0
- package/dist/persona/profile/list/1.0/payload.js +680 -0
- package/dist/persona/profile/list/1.0/payload.js.map +1 -0
- package/dist/persona/profile/put/1.0/payload.d.ts +1115 -0
- package/dist/persona/profile/put/1.0/payload.d.ts.map +1 -0
- package/dist/persona/profile/put/1.0/payload.js +675 -0
- package/dist/persona/profile/put/1.0/payload.js.map +1 -0
- package/dist/persona/renderers/list/1.0/payload.d.ts +362 -0
- package/dist/persona/renderers/list/1.0/payload.d.ts.map +1 -0
- package/dist/persona/renderers/list/1.0/payload.js +197 -0
- package/dist/persona/renderers/list/1.0/payload.js.map +1 -0
- package/dist/rooms/keys/commit/0.1/payload.d.ts +266 -0
- package/dist/rooms/keys/commit/0.1/payload.d.ts.map +1 -0
- package/dist/rooms/keys/commit/0.1/payload.js +146 -0
- package/dist/rooms/keys/commit/0.1/payload.js.map +1 -0
- package/dist/rooms/keys/key-package/0.1/payload.d.ts +272 -0
- package/dist/rooms/keys/key-package/0.1/payload.d.ts.map +1 -0
- package/dist/rooms/keys/key-package/0.1/payload.js +147 -0
- package/dist/rooms/keys/key-package/0.1/payload.js.map +1 -0
- package/dist/rooms/keys/welcome/0.1/payload.d.ts +276 -0
- package/dist/rooms/keys/welcome/0.1/payload.d.ts.map +1 -0
- package/dist/rooms/keys/welcome/0.1/payload.js +148 -0
- package/dist/rooms/keys/welcome/0.1/payload.js.map +1 -0
- package/dist/rooms/owner/claim/0.1/payload.d.ts +391 -0
- package/dist/rooms/owner/claim/0.1/payload.d.ts.map +1 -0
- package/dist/rooms/owner/claim/0.1/payload.js +214 -0
- package/dist/rooms/owner/claim/0.1/payload.js.map +1 -0
- package/dist/rooms/owner/transfer/0.1/payload.d.ts +391 -0
- package/dist/rooms/owner/transfer/0.1/payload.d.ts.map +1 -0
- package/dist/rooms/owner/transfer/0.1/payload.js +214 -0
- package/dist/rooms/owner/transfer/0.1/payload.js.map +1 -0
- package/dist/rooms/records/curate/0.1/payload.d.ts +500 -0
- package/dist/rooms/records/curate/0.1/payload.d.ts.map +1 -0
- package/dist/rooms/records/curate/0.1/payload.js +277 -0
- package/dist/rooms/records/curate/0.1/payload.js.map +1 -0
- package/dist/vta/_shared/0.1/app-state-record.d.ts +1 -1
- package/dist/vta/_shared/0.1/app-state-record.d.ts.map +1 -1
- package/dist/vta/app-state/delete/1.0/payload.d.ts +1 -1
- package/dist/vta/app-state/delete/1.0/payload.d.ts.map +1 -1
- package/dist/vta/app-state/get/1.0/payload.d.ts +1 -1
- package/dist/vta/app-state/get/1.0/payload.d.ts.map +1 -1
- package/dist/vta/app-state/get-many/1.0/payload.d.ts +1 -1
- package/dist/vta/app-state/get-many/1.0/payload.d.ts.map +1 -1
- package/dist/vta/app-state/list/1.0/payload.d.ts +1 -1
- package/dist/vta/app-state/list/1.0/payload.d.ts.map +1 -1
- package/dist/vta/app-state/put/1.0/payload.d.ts +1 -1
- package/dist/vta/app-state/put/1.0/payload.d.ts.map +1 -1
- package/dist/vta/app-state/put-many/1.0/payload.d.ts +1 -1
- package/dist/vta/app-state/put-many/1.0/payload.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/_shared/components.ts +217 -7
- package/src/device/list/0.1/payload.ts +6 -2
- package/src/device/list/0.2/payload.ts +6 -2
- package/src/device/register/0.1/payload.ts +6 -2
- package/src/device/register/0.2/payload.ts +6 -2
- package/src/index.ts +31 -0
- package/src/persona/_shared/0.1/persona-record.ts +23 -0
- package/src/persona/attribute/delete/1.0/payload.ts +238 -0
- package/src/persona/attribute/list/1.0/payload.ts +590 -0
- package/src/persona/attribute/put/1.0/payload.ts +559 -0
- package/src/persona/binding/get/1.0/payload.ts +257 -0
- package/src/persona/binding/list/1.0/payload.ts +260 -0
- package/src/persona/binding/set/1.0/payload.ts +370 -0
- package/src/persona/contact/delete/1.0/payload.ts +216 -0
- package/src/persona/contact/get/1.0/payload.ts +662 -0
- package/src/persona/contact/list/1.0/payload.ts +323 -0
- package/src/persona/contact/put/1.0/payload.ts +580 -0
- package/src/persona/correlation/analyze/1.0/payload.ts +466 -0
- package/src/persona/disclosure/history/1.0/payload.ts +415 -0
- package/src/persona/disclosure/present/1.0/payload.ts +274 -0
- package/src/persona/disclosure/preview/1.0/payload.ts +597 -0
- package/src/persona/local/binding/set/1.0/payload.ts +267 -0
- package/src/persona/local/profile/delete/1.0/payload.ts +215 -0
- package/src/persona/local/profile/get/1.0/payload.ts +251 -0
- package/src/persona/local/profile/list/1.0/payload.ts +260 -0
- package/src/persona/local/profile/put/1.0/payload.ts +373 -0
- package/src/persona/profile/delete/1.0/payload.ts +236 -0
- package/src/persona/profile/get/1.0/payload.ts +846 -0
- package/src/persona/profile/list/1.0/payload.ts +723 -0
- package/src/persona/profile/put/1.0/payload.ts +741 -0
- package/src/persona/renderers/list/1.0/payload.ts +248 -0
- package/src/rooms/keys/commit/0.1/payload.ts +195 -0
- package/src/rooms/keys/key-package/0.1/payload.ts +196 -0
- package/src/rooms/keys/welcome/0.1/payload.ts +201 -0
- package/src/rooms/owner/claim/0.1/payload.ts +268 -0
- package/src/rooms/owner/transfer/0.1/payload.ts +268 -0
- package/src/rooms/records/curate/0.1/payload.ts +357 -0
- package/src/vta/_shared/0.1/app-state-record.ts +1 -1
- package/src/vta/app-state/delete/1.0/payload.ts +1 -1
- package/src/vta/app-state/get/1.0/payload.ts +1 -1
- package/src/vta/app-state/get-many/1.0/payload.ts +1 -1
- package/src/vta/app-state/list/1.0/payload.ts +1 -1
- package/src/vta/app-state/put/1.0/payload.ts +1 -1
- package/src/vta/app-state/put-many/1.0/payload.ts +1 -1
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
|
|
3
|
+
* Source: specs/rooms/keys/welcome/0.1/payload.schema.json
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
import type { Ext } from "../../../../_shared/components.js";
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* A room's owner delivers an MLS Welcome to the agent that will hold a new member's room keys, so it can join the group. The Welcome carries the group's secrets sealed to the recipient's KeyPackage; a recipient that accepts one it was not invited to has been handed key material it should have refused.
|
|
11
|
+
*/
|
|
12
|
+
export interface RoomsKeysWelcomePayload {
|
|
13
|
+
/**
|
|
14
|
+
* The room being joined.
|
|
15
|
+
*/
|
|
16
|
+
roomId: string;
|
|
17
|
+
/**
|
|
18
|
+
* The MLS Welcome message, base64url.
|
|
19
|
+
*/
|
|
20
|
+
welcome: string;
|
|
21
|
+
/**
|
|
22
|
+
* The group's ratchet tree, base64url, where the Welcome does not carry it as an extension. A joiner needs the tree to derive the group's secrets; omit it only where the group uses the ratchet-tree extension.
|
|
23
|
+
*/
|
|
24
|
+
ratchetTree?: string;
|
|
25
|
+
/**
|
|
26
|
+
* The invitation credential (VIC) the room issued to the joining party, serialized per the governing profile. This is what makes the Welcome acceptable: joining is a two-party act, and a recipient with no matching invitation MUST refuse.
|
|
27
|
+
*/
|
|
28
|
+
invitation?: string;
|
|
29
|
+
/**
|
|
30
|
+
* Ecosystem-defined extension members per SPEC.md §4.5.1.
|
|
31
|
+
*/
|
|
32
|
+
ext?: Ext;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Success response to rooms/keys/welcome. Type https://trusttasks.org/spec/rooms/keys/welcome/0.1#response.
|
|
36
|
+
*/
|
|
37
|
+
export interface RoomsKeysWelcomeResponsePayload {
|
|
38
|
+
/**
|
|
39
|
+
* The MLS epoch the recipient joined at. The sender needs this to know which commits the recipient still lacks.
|
|
40
|
+
*/
|
|
41
|
+
epoch: number;
|
|
42
|
+
ext?: Ext;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
/** Shared definitions this specification references, re-exported under the names it used to declare them with. */
|
|
46
|
+
export type { Ext };
|
|
47
|
+
|
|
48
|
+
/** Trust Task type URI. */
|
|
49
|
+
export const TYPE_URI = "https://trusttasks.org/spec/rooms/keys/welcome/0.1" as const;
|
|
50
|
+
|
|
51
|
+
/** Stable alias for this specification's request payload shape. */
|
|
52
|
+
export type Payload = RoomsKeysWelcomePayload;
|
|
53
|
+
|
|
54
|
+
/** Trust Task response type URI (request type URI + "#response"). */
|
|
55
|
+
export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/rooms/keys/welcome/0.1#response" as const;
|
|
56
|
+
|
|
57
|
+
/** Stable alias for this specification's success-response payload shape. */
|
|
58
|
+
export type Response = RoomsKeysWelcomeResponsePayload;
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* This specification's payload schema, as a value.
|
|
62
|
+
*
|
|
63
|
+
* SPEC.md §7.2 item 2 is performed against this. It is shipped as data
|
|
64
|
+
* rather than only as a `.json` file because TypeScript types are erased
|
|
65
|
+
* at runtime: without a schema a consumer has nothing to validate, and
|
|
66
|
+
* every REQUIRED payload member is optional in practice. Cross-file
|
|
67
|
+
* `$ref`s are already inlined, so it needs no resolver.
|
|
68
|
+
*/
|
|
69
|
+
export const PAYLOAD_SCHEMA = {
|
|
70
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
71
|
+
"$id": "https://trusttasks.org/spec/rooms/keys/welcome/0.1",
|
|
72
|
+
"title": "Rooms Keys Welcome — payload",
|
|
73
|
+
"description": "A room's owner delivers an MLS Welcome to the agent that will hold a new member's room keys, so it can join the group. The Welcome carries the group's secrets sealed to the recipient's KeyPackage; a recipient that accepts one it was not invited to has been handed key material it should have refused.",
|
|
74
|
+
"type": "object",
|
|
75
|
+
"additionalProperties": false,
|
|
76
|
+
"required": [
|
|
77
|
+
"roomId",
|
|
78
|
+
"welcome"
|
|
79
|
+
],
|
|
80
|
+
"properties": {
|
|
81
|
+
"roomId": {
|
|
82
|
+
"type": "string",
|
|
83
|
+
"description": "The room being joined."
|
|
84
|
+
},
|
|
85
|
+
"welcome": {
|
|
86
|
+
"type": "string",
|
|
87
|
+
"description": "The MLS Welcome message, base64url."
|
|
88
|
+
},
|
|
89
|
+
"ratchetTree": {
|
|
90
|
+
"type": "string",
|
|
91
|
+
"description": "The group's ratchet tree, base64url, where the Welcome does not carry it as an extension. A joiner needs the tree to derive the group's secrets; omit it only where the group uses the ratchet-tree extension."
|
|
92
|
+
},
|
|
93
|
+
"invitation": {
|
|
94
|
+
"type": "string",
|
|
95
|
+
"description": "The invitation credential (VIC) the room issued to the joining party, serialized per the governing profile. This is what makes the Welcome acceptable: joining is a two-party act, and a recipient with no matching invitation MUST refuse."
|
|
96
|
+
},
|
|
97
|
+
"ext": {
|
|
98
|
+
"$ref": "#/$defs/Ext",
|
|
99
|
+
"description": "Ecosystem-defined extension members per SPEC.md §4.5.1."
|
|
100
|
+
}
|
|
101
|
+
},
|
|
102
|
+
"$defs": {
|
|
103
|
+
"Response": {
|
|
104
|
+
"$anchor": "response",
|
|
105
|
+
"title": "Rooms Keys Welcome — response payload",
|
|
106
|
+
"description": "Success response to rooms/keys/welcome. Type https://trusttasks.org/spec/rooms/keys/welcome/0.1#response.",
|
|
107
|
+
"type": "object",
|
|
108
|
+
"additionalProperties": false,
|
|
109
|
+
"required": [
|
|
110
|
+
"epoch"
|
|
111
|
+
],
|
|
112
|
+
"properties": {
|
|
113
|
+
"epoch": {
|
|
114
|
+
"type": "integer",
|
|
115
|
+
"minimum": 0,
|
|
116
|
+
"description": "The MLS epoch the recipient joined at. The sender needs this to know which commits the recipient still lacks."
|
|
117
|
+
},
|
|
118
|
+
"ext": {
|
|
119
|
+
"$ref": "#/$defs/Ext"
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
"Ext": {
|
|
124
|
+
"title": "Ext",
|
|
125
|
+
"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.",
|
|
126
|
+
"type": "object",
|
|
127
|
+
"minProperties": 1,
|
|
128
|
+
"additionalProperties": true,
|
|
129
|
+
"propertyNames": {
|
|
130
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
} as const;
|
|
135
|
+
|
|
136
|
+
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
137
|
+
export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
138
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
139
|
+
"$ref": "#/$defs/Response",
|
|
140
|
+
"$defs": {
|
|
141
|
+
"Response": {
|
|
142
|
+
"$anchor": "response",
|
|
143
|
+
"title": "Rooms Keys Welcome — response payload",
|
|
144
|
+
"description": "Success response to rooms/keys/welcome. Type https://trusttasks.org/spec/rooms/keys/welcome/0.1#response.",
|
|
145
|
+
"type": "object",
|
|
146
|
+
"additionalProperties": false,
|
|
147
|
+
"required": [
|
|
148
|
+
"epoch"
|
|
149
|
+
],
|
|
150
|
+
"properties": {
|
|
151
|
+
"epoch": {
|
|
152
|
+
"type": "integer",
|
|
153
|
+
"minimum": 0,
|
|
154
|
+
"description": "The MLS epoch the recipient joined at. The sender needs this to know which commits the recipient still lacks."
|
|
155
|
+
},
|
|
156
|
+
"ext": {
|
|
157
|
+
"$ref": "#/$defs/Ext"
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
},
|
|
161
|
+
"Ext": {
|
|
162
|
+
"title": "Ext",
|
|
163
|
+
"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.",
|
|
164
|
+
"type": "object",
|
|
165
|
+
"minProperties": 1,
|
|
166
|
+
"additionalProperties": true,
|
|
167
|
+
"propertyNames": {
|
|
168
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
} as const;
|
|
173
|
+
|
|
174
|
+
/**
|
|
175
|
+
* SPEC.md §7.2 policy for the request variant, from this specification's
|
|
176
|
+
* front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
|
|
177
|
+
* per-specification and cannot be derived from the document alone, and
|
|
178
|
+
* item 2 needs the schema this carries.
|
|
179
|
+
*/
|
|
180
|
+
export const SPEC = {
|
|
181
|
+
typeUri: TYPE_URI,
|
|
182
|
+
isBearer: false,
|
|
183
|
+
isProofRequired: true,
|
|
184
|
+
isRecipientRequired: true,
|
|
185
|
+
isIssuedAtRequired: true,
|
|
186
|
+
payloadSchema: PAYLOAD_SCHEMA,
|
|
187
|
+
} as const;
|
|
188
|
+
|
|
189
|
+
/**
|
|
190
|
+
* SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
|
|
191
|
+
* tracks the *issuer* party's requirement because a response swaps the
|
|
192
|
+
* parties (§7.3 item 5).
|
|
193
|
+
*/
|
|
194
|
+
export const RESPONSE_SPEC = {
|
|
195
|
+
typeUri: RESPONSE_TYPE_URI,
|
|
196
|
+
isBearer: false,
|
|
197
|
+
isProofRequired: true,
|
|
198
|
+
isRecipientRequired: true,
|
|
199
|
+
isIssuedAtRequired: true,
|
|
200
|
+
payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
|
|
201
|
+
} as const;
|
|
@@ -0,0 +1,268 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
|
|
3
|
+
* Source: specs/rooms/owner/claim/0.1/payload.schema.json
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
import type { AuthorityPresentation, Ext } from "../../../../_shared/components.js";
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* A nominated successor claims ownership of a room whose owner has stopped renewing it. A claim is an act, never an automatic promotion: an ownership change should be something somebody caused, not something that happened.
|
|
11
|
+
*/
|
|
12
|
+
export interface RoomsOwnerClaimPayload {
|
|
13
|
+
/**
|
|
14
|
+
* The room being claimed.
|
|
15
|
+
*/
|
|
16
|
+
roomId: string;
|
|
17
|
+
/**
|
|
18
|
+
* The succession credential the room issued to this claimant, serialized per the governing profile. Issued in advance by the owner themselves — a host verifies a decision the previous owner already made, and never makes one of its own about who should own a room.
|
|
19
|
+
*/
|
|
20
|
+
nomination: string;
|
|
21
|
+
/**
|
|
22
|
+
* The claimant's own membership and authority in the room. A host cannot see the MLS group, so this credential — the room's own statement that this party is a member — is the only membership it can check, and it is the same one every other room task presents.
|
|
23
|
+
*/
|
|
24
|
+
presentation: AuthorityPresentation;
|
|
25
|
+
/**
|
|
26
|
+
* Why, for the room's audit trail. A claim is a takeover; it should say what prompted it.
|
|
27
|
+
*/
|
|
28
|
+
reason?: string;
|
|
29
|
+
/**
|
|
30
|
+
* Ecosystem-defined extension members per SPEC.md §4.5.1.
|
|
31
|
+
*/
|
|
32
|
+
ext?: Ext;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Success response to rooms/owner/claim. Type https://trusttasks.org/spec/rooms/owner/claim/0.1#response.
|
|
36
|
+
*/
|
|
37
|
+
export interface RoomsOwnerClaimResponsePayload {
|
|
38
|
+
roomId: string;
|
|
39
|
+
/**
|
|
40
|
+
* The owner after the claim — the claimant.
|
|
41
|
+
*/
|
|
42
|
+
ownerDid: string;
|
|
43
|
+
ext?: Ext;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
/** Shared definitions this specification references, re-exported under the names it used to declare them with. */
|
|
47
|
+
export type { AuthorityPresentation, Ext };
|
|
48
|
+
|
|
49
|
+
/** Trust Task type URI. */
|
|
50
|
+
export const TYPE_URI = "https://trusttasks.org/spec/rooms/owner/claim/0.1" as const;
|
|
51
|
+
|
|
52
|
+
/** Stable alias for this specification's request payload shape. */
|
|
53
|
+
export type Payload = RoomsOwnerClaimPayload;
|
|
54
|
+
|
|
55
|
+
/** Trust Task response type URI (request type URI + "#response"). */
|
|
56
|
+
export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/rooms/owner/claim/0.1#response" as const;
|
|
57
|
+
|
|
58
|
+
/** Stable alias for this specification's success-response payload shape. */
|
|
59
|
+
export type Response = RoomsOwnerClaimResponsePayload;
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* This specification's payload schema, as a value.
|
|
63
|
+
*
|
|
64
|
+
* SPEC.md §7.2 item 2 is performed against this. It is shipped as data
|
|
65
|
+
* rather than only as a `.json` file because TypeScript types are erased
|
|
66
|
+
* at runtime: without a schema a consumer has nothing to validate, and
|
|
67
|
+
* every REQUIRED payload member is optional in practice. Cross-file
|
|
68
|
+
* `$ref`s are already inlined, so it needs no resolver.
|
|
69
|
+
*/
|
|
70
|
+
export const PAYLOAD_SCHEMA = {
|
|
71
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
72
|
+
"$id": "https://trusttasks.org/spec/rooms/owner/claim/0.1",
|
|
73
|
+
"title": "Rooms Owner Claim — payload",
|
|
74
|
+
"description": "A nominated successor claims ownership of a room whose owner has stopped renewing it. A claim is an act, never an automatic promotion: an ownership change should be something somebody caused, not something that happened.",
|
|
75
|
+
"type": "object",
|
|
76
|
+
"additionalProperties": false,
|
|
77
|
+
"required": [
|
|
78
|
+
"roomId",
|
|
79
|
+
"nomination",
|
|
80
|
+
"presentation"
|
|
81
|
+
],
|
|
82
|
+
"properties": {
|
|
83
|
+
"roomId": {
|
|
84
|
+
"type": "string",
|
|
85
|
+
"description": "The room being claimed."
|
|
86
|
+
},
|
|
87
|
+
"nomination": {
|
|
88
|
+
"type": "string",
|
|
89
|
+
"description": "The succession credential the room issued to this claimant, serialized per the governing profile. Issued in advance by the owner themselves — a host verifies a decision the previous owner already made, and never makes one of its own about who should own a room."
|
|
90
|
+
},
|
|
91
|
+
"presentation": {
|
|
92
|
+
"$ref": "#/$defs/AuthorityPresentation",
|
|
93
|
+
"description": "The claimant's own membership and authority in the room. A host cannot see the MLS group, so this credential — the room's own statement that this party is a member — is the only membership it can check, and it is the same one every other room task presents."
|
|
94
|
+
},
|
|
95
|
+
"reason": {
|
|
96
|
+
"type": "string",
|
|
97
|
+
"maxLength": 512,
|
|
98
|
+
"description": "Why, for the room's audit trail. A claim is a takeover; it should say what prompted it."
|
|
99
|
+
},
|
|
100
|
+
"ext": {
|
|
101
|
+
"$ref": "#/$defs/Ext",
|
|
102
|
+
"description": "Ecosystem-defined extension members per SPEC.md §4.5.1."
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
"$defs": {
|
|
106
|
+
"Response": {
|
|
107
|
+
"$anchor": "response",
|
|
108
|
+
"title": "Rooms Owner Claim — response payload",
|
|
109
|
+
"description": "Success response to rooms/owner/claim. Type https://trusttasks.org/spec/rooms/owner/claim/0.1#response.",
|
|
110
|
+
"type": "object",
|
|
111
|
+
"additionalProperties": false,
|
|
112
|
+
"required": [
|
|
113
|
+
"roomId",
|
|
114
|
+
"ownerDid"
|
|
115
|
+
],
|
|
116
|
+
"properties": {
|
|
117
|
+
"roomId": {
|
|
118
|
+
"type": "string"
|
|
119
|
+
},
|
|
120
|
+
"ownerDid": {
|
|
121
|
+
"type": "string",
|
|
122
|
+
"description": "The owner after the claim — the claimant."
|
|
123
|
+
},
|
|
124
|
+
"ext": {
|
|
125
|
+
"$ref": "#/$defs/Ext"
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
},
|
|
129
|
+
"Ext": {
|
|
130
|
+
"title": "Ext",
|
|
131
|
+
"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.",
|
|
132
|
+
"type": "object",
|
|
133
|
+
"minProperties": 1,
|
|
134
|
+
"additionalProperties": true,
|
|
135
|
+
"propertyNames": {
|
|
136
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
137
|
+
}
|
|
138
|
+
},
|
|
139
|
+
"AuthorityPresentation": {
|
|
140
|
+
"title": "AuthorityPresentation",
|
|
141
|
+
"type": "object",
|
|
142
|
+
"additionalProperties": false,
|
|
143
|
+
"required": [
|
|
144
|
+
"membership",
|
|
145
|
+
"authority"
|
|
146
|
+
],
|
|
147
|
+
"description": "What a party presents to act on a room. Carries the whole authority chain: a host MUST NOT dereference an authority credential's `parent` to fetch a link it was not given. Resolving over the network would make verification depend on availability, turn every identifier into a request the host can be induced to make against an address the holder chooses, and signal credential use to whoever hosts the identifier.",
|
|
148
|
+
"properties": {
|
|
149
|
+
"membership": {
|
|
150
|
+
"type": "string",
|
|
151
|
+
"description": "The presenter's membership credential for this room, or — on a `private` room — a zero-knowledge presentation of it. Serialized per the governing profile."
|
|
152
|
+
},
|
|
153
|
+
"authority": {
|
|
154
|
+
"type": "array",
|
|
155
|
+
"minItems": 1,
|
|
156
|
+
"maxItems": 8,
|
|
157
|
+
"items": {
|
|
158
|
+
"type": "string"
|
|
159
|
+
},
|
|
160
|
+
"description": "The authority chain, LEAF FIRST: the first element is the credential being relied on and the last MUST be one issued by the room itself. Every link the presenter relies on is present, because the host will not fetch one. Capped at 8: verification is linear in chain length and runs on every operation, so an unbounded chain is a denial-of-service surface against the host. The known uses need 2 to 3 — a person attenuating to an agent, and that agent to a sub-agent."
|
|
161
|
+
},
|
|
162
|
+
"subjectBinding": {
|
|
163
|
+
"type": "string",
|
|
164
|
+
"description": "REQUIRED on a `private` room, where the subject identifier is withheld: a proof that the membership credential and the authority chain's leaf describe the SAME subject. Without it two parties pool credentials — one contributes membership, the other authority — and the combination verifies as a single party holding both. A host MUST refuse a private-room presentation that omits this."
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
} as const;
|
|
170
|
+
|
|
171
|
+
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
172
|
+
export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
173
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
174
|
+
"$ref": "#/$defs/Response",
|
|
175
|
+
"$defs": {
|
|
176
|
+
"Response": {
|
|
177
|
+
"$anchor": "response",
|
|
178
|
+
"title": "Rooms Owner Claim — response payload",
|
|
179
|
+
"description": "Success response to rooms/owner/claim. Type https://trusttasks.org/spec/rooms/owner/claim/0.1#response.",
|
|
180
|
+
"type": "object",
|
|
181
|
+
"additionalProperties": false,
|
|
182
|
+
"required": [
|
|
183
|
+
"roomId",
|
|
184
|
+
"ownerDid"
|
|
185
|
+
],
|
|
186
|
+
"properties": {
|
|
187
|
+
"roomId": {
|
|
188
|
+
"type": "string"
|
|
189
|
+
},
|
|
190
|
+
"ownerDid": {
|
|
191
|
+
"type": "string",
|
|
192
|
+
"description": "The owner after the claim — the claimant."
|
|
193
|
+
},
|
|
194
|
+
"ext": {
|
|
195
|
+
"$ref": "#/$defs/Ext"
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
},
|
|
199
|
+
"Ext": {
|
|
200
|
+
"title": "Ext",
|
|
201
|
+
"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.",
|
|
202
|
+
"type": "object",
|
|
203
|
+
"minProperties": 1,
|
|
204
|
+
"additionalProperties": true,
|
|
205
|
+
"propertyNames": {
|
|
206
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
207
|
+
}
|
|
208
|
+
},
|
|
209
|
+
"AuthorityPresentation": {
|
|
210
|
+
"title": "AuthorityPresentation",
|
|
211
|
+
"type": "object",
|
|
212
|
+
"additionalProperties": false,
|
|
213
|
+
"required": [
|
|
214
|
+
"membership",
|
|
215
|
+
"authority"
|
|
216
|
+
],
|
|
217
|
+
"description": "What a party presents to act on a room. Carries the whole authority chain: a host MUST NOT dereference an authority credential's `parent` to fetch a link it was not given. Resolving over the network would make verification depend on availability, turn every identifier into a request the host can be induced to make against an address the holder chooses, and signal credential use to whoever hosts the identifier.",
|
|
218
|
+
"properties": {
|
|
219
|
+
"membership": {
|
|
220
|
+
"type": "string",
|
|
221
|
+
"description": "The presenter's membership credential for this room, or — on a `private` room — a zero-knowledge presentation of it. Serialized per the governing profile."
|
|
222
|
+
},
|
|
223
|
+
"authority": {
|
|
224
|
+
"type": "array",
|
|
225
|
+
"minItems": 1,
|
|
226
|
+
"maxItems": 8,
|
|
227
|
+
"items": {
|
|
228
|
+
"type": "string"
|
|
229
|
+
},
|
|
230
|
+
"description": "The authority chain, LEAF FIRST: the first element is the credential being relied on and the last MUST be one issued by the room itself. Every link the presenter relies on is present, because the host will not fetch one. Capped at 8: verification is linear in chain length and runs on every operation, so an unbounded chain is a denial-of-service surface against the host. The known uses need 2 to 3 — a person attenuating to an agent, and that agent to a sub-agent."
|
|
231
|
+
},
|
|
232
|
+
"subjectBinding": {
|
|
233
|
+
"type": "string",
|
|
234
|
+
"description": "REQUIRED on a `private` room, where the subject identifier is withheld: a proof that the membership credential and the authority chain's leaf describe the SAME subject. Without it two parties pool credentials — one contributes membership, the other authority — and the combination verifies as a single party holding both. A host MUST refuse a private-room presentation that omits this."
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
} as const;
|
|
240
|
+
|
|
241
|
+
/**
|
|
242
|
+
* SPEC.md §7.2 policy for the request variant, from this specification's
|
|
243
|
+
* front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
|
|
244
|
+
* per-specification and cannot be derived from the document alone, and
|
|
245
|
+
* item 2 needs the schema this carries.
|
|
246
|
+
*/
|
|
247
|
+
export const SPEC = {
|
|
248
|
+
typeUri: TYPE_URI,
|
|
249
|
+
isBearer: false,
|
|
250
|
+
isProofRequired: true,
|
|
251
|
+
isRecipientRequired: true,
|
|
252
|
+
isIssuedAtRequired: true,
|
|
253
|
+
payloadSchema: PAYLOAD_SCHEMA,
|
|
254
|
+
} as const;
|
|
255
|
+
|
|
256
|
+
/**
|
|
257
|
+
* SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
|
|
258
|
+
* tracks the *issuer* party's requirement because a response swaps the
|
|
259
|
+
* parties (§7.3 item 5).
|
|
260
|
+
*/
|
|
261
|
+
export const RESPONSE_SPEC = {
|
|
262
|
+
typeUri: RESPONSE_TYPE_URI,
|
|
263
|
+
isBearer: false,
|
|
264
|
+
isProofRequired: true,
|
|
265
|
+
isRecipientRequired: true,
|
|
266
|
+
isIssuedAtRequired: true,
|
|
267
|
+
payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
|
|
268
|
+
} as const;
|