@openvtc/trust-tasks 0.16.9 → 0.16.11
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 +220 -0
- package/dist/_shared/components.d.ts +206 -5
- package/dist/_shared/components.d.ts.map +1 -1
- package/dist/index.d.ts +27 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +27 -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 +530 -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 +802 -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/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/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 +213 -5
- package/src/index.ts +27 -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 +588 -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 +844 -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/owner/claim/0.1/payload.ts +268 -0
- package/src/rooms/owner/transfer/0.1/payload.ts +268 -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,251 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
|
|
3
|
+
* Source: specs/persona/local/profile/get/1.0/payload.schema.json
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
import type { Ext, Ulid, Version_PersonaV0_1 as Version } from "../../../../../_shared/components.js";
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Read one context-local profile.
|
|
11
|
+
*/
|
|
12
|
+
export interface PersonaLocalProfileGetPayload {
|
|
13
|
+
contextId: string;
|
|
14
|
+
profileId: Ulid;
|
|
15
|
+
ext?: Ext;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Success response to persona/local/profile/get. Type https://trusttasks.org/spec/persona/local/profile/get/1.0#response.
|
|
19
|
+
*/
|
|
20
|
+
export interface PersonaLocalProfileGetResponsePayload {
|
|
21
|
+
profile: {
|
|
22
|
+
profileId: Ulid;
|
|
23
|
+
name: string;
|
|
24
|
+
/**
|
|
25
|
+
* @maxItems 64
|
|
26
|
+
*/
|
|
27
|
+
entries: {}[];
|
|
28
|
+
version: Version;
|
|
29
|
+
};
|
|
30
|
+
ext?: Ext;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
/** Shared definitions this specification references, re-exported under the names it used to declare them with. */
|
|
34
|
+
export type { Ext, Ulid, Version };
|
|
35
|
+
|
|
36
|
+
/** Trust Task type URI. */
|
|
37
|
+
export const TYPE_URI = "https://trusttasks.org/spec/persona/local/profile/get/1.0" as const;
|
|
38
|
+
|
|
39
|
+
/** Stable alias for this specification's request payload shape. */
|
|
40
|
+
export type Payload = PersonaLocalProfileGetPayload;
|
|
41
|
+
|
|
42
|
+
/** Trust Task response type URI (request type URI + "#response"). */
|
|
43
|
+
export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/persona/local/profile/get/1.0#response" as const;
|
|
44
|
+
|
|
45
|
+
/** Stable alias for this specification's success-response payload shape. */
|
|
46
|
+
export type Response = PersonaLocalProfileGetResponsePayload;
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* This specification's payload schema, as a value.
|
|
50
|
+
*
|
|
51
|
+
* SPEC.md §7.2 item 2 is performed against this. It is shipped as data
|
|
52
|
+
* rather than only as a `.json` file because TypeScript types are erased
|
|
53
|
+
* at runtime: without a schema a consumer has nothing to validate, and
|
|
54
|
+
* every REQUIRED payload member is optional in practice. Cross-file
|
|
55
|
+
* `$ref`s are already inlined, so it needs no resolver.
|
|
56
|
+
*/
|
|
57
|
+
export const PAYLOAD_SCHEMA = {
|
|
58
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
59
|
+
"$id": "https://trusttasks.org/spec/persona/local/profile/get/1.0",
|
|
60
|
+
"title": "Persona Local Profile Get — payload",
|
|
61
|
+
"type": "object",
|
|
62
|
+
"additionalProperties": false,
|
|
63
|
+
"properties": {
|
|
64
|
+
"contextId": {
|
|
65
|
+
"type": "string",
|
|
66
|
+
"minLength": 1
|
|
67
|
+
},
|
|
68
|
+
"profileId": {
|
|
69
|
+
"$ref": "#/$defs/Ulid"
|
|
70
|
+
},
|
|
71
|
+
"ext": {
|
|
72
|
+
"$ref": "#/$defs/Ext"
|
|
73
|
+
}
|
|
74
|
+
},
|
|
75
|
+
"$defs": {
|
|
76
|
+
"Response": {
|
|
77
|
+
"required": [
|
|
78
|
+
"profile"
|
|
79
|
+
],
|
|
80
|
+
"properties": {
|
|
81
|
+
"profile": {
|
|
82
|
+
"type": "object",
|
|
83
|
+
"additionalProperties": false,
|
|
84
|
+
"required": [
|
|
85
|
+
"profileId",
|
|
86
|
+
"name",
|
|
87
|
+
"entries",
|
|
88
|
+
"version"
|
|
89
|
+
],
|
|
90
|
+
"properties": {
|
|
91
|
+
"profileId": {
|
|
92
|
+
"$ref": "#/$defs/Ulid"
|
|
93
|
+
},
|
|
94
|
+
"name": {
|
|
95
|
+
"type": "string",
|
|
96
|
+
"maxLength": 128
|
|
97
|
+
},
|
|
98
|
+
"entries": {
|
|
99
|
+
"type": "array",
|
|
100
|
+
"maxItems": 64,
|
|
101
|
+
"items": {
|
|
102
|
+
"type": "object"
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
"version": {
|
|
106
|
+
"$ref": "#/$defs/Version"
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
},
|
|
110
|
+
"ext": {
|
|
111
|
+
"$ref": "#/$defs/Ext"
|
|
112
|
+
}
|
|
113
|
+
},
|
|
114
|
+
"$anchor": "response",
|
|
115
|
+
"title": "Persona Local Profile Get — response payload",
|
|
116
|
+
"description": "Success response to persona/local/profile/get. Type https://trusttasks.org/spec/persona/local/profile/get/1.0#response.",
|
|
117
|
+
"type": "object",
|
|
118
|
+
"additionalProperties": false
|
|
119
|
+
},
|
|
120
|
+
"Ext": {
|
|
121
|
+
"title": "Ext",
|
|
122
|
+
"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.",
|
|
123
|
+
"type": "object",
|
|
124
|
+
"minProperties": 1,
|
|
125
|
+
"additionalProperties": true,
|
|
126
|
+
"propertyNames": {
|
|
127
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
128
|
+
}
|
|
129
|
+
},
|
|
130
|
+
"Version": {
|
|
131
|
+
"title": "Version",
|
|
132
|
+
"description": "A value of the store's monotonic write counter. Server-assigned; a producer never chooses one.",
|
|
133
|
+
"type": "integer",
|
|
134
|
+
"minimum": 1
|
|
135
|
+
},
|
|
136
|
+
"Ulid": {
|
|
137
|
+
"title": "Ulid",
|
|
138
|
+
"description": "A ULID in Crockford base32, uppercase. Used for `attributeId` and `profileId`. Chosen over a UUID because the leading 48 bits are a timestamp, so a key-ordered scan of the store is also creation-ordered and a `list` needs no secondary sort. Server-assigned on create; a producer MAY supply one to make a create idempotent, and a maintainer MUST reject a supplied value that already exists rather than silently overwriting.",
|
|
139
|
+
"type": "string",
|
|
140
|
+
"pattern": "^[0-9A-HJKMNP-TV-Z]{26}$"
|
|
141
|
+
}
|
|
142
|
+
},
|
|
143
|
+
"description": "Read one context-local profile.",
|
|
144
|
+
"required": [
|
|
145
|
+
"contextId",
|
|
146
|
+
"profileId"
|
|
147
|
+
]
|
|
148
|
+
} as const;
|
|
149
|
+
|
|
150
|
+
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
151
|
+
export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
152
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
153
|
+
"$ref": "#/$defs/Response",
|
|
154
|
+
"$defs": {
|
|
155
|
+
"Response": {
|
|
156
|
+
"required": [
|
|
157
|
+
"profile"
|
|
158
|
+
],
|
|
159
|
+
"properties": {
|
|
160
|
+
"profile": {
|
|
161
|
+
"type": "object",
|
|
162
|
+
"additionalProperties": false,
|
|
163
|
+
"required": [
|
|
164
|
+
"profileId",
|
|
165
|
+
"name",
|
|
166
|
+
"entries",
|
|
167
|
+
"version"
|
|
168
|
+
],
|
|
169
|
+
"properties": {
|
|
170
|
+
"profileId": {
|
|
171
|
+
"$ref": "#/$defs/Ulid"
|
|
172
|
+
},
|
|
173
|
+
"name": {
|
|
174
|
+
"type": "string",
|
|
175
|
+
"maxLength": 128
|
|
176
|
+
},
|
|
177
|
+
"entries": {
|
|
178
|
+
"type": "array",
|
|
179
|
+
"maxItems": 64,
|
|
180
|
+
"items": {
|
|
181
|
+
"type": "object"
|
|
182
|
+
}
|
|
183
|
+
},
|
|
184
|
+
"version": {
|
|
185
|
+
"$ref": "#/$defs/Version"
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
},
|
|
189
|
+
"ext": {
|
|
190
|
+
"$ref": "#/$defs/Ext"
|
|
191
|
+
}
|
|
192
|
+
},
|
|
193
|
+
"$anchor": "response",
|
|
194
|
+
"title": "Persona Local Profile Get — response payload",
|
|
195
|
+
"description": "Success response to persona/local/profile/get. Type https://trusttasks.org/spec/persona/local/profile/get/1.0#response.",
|
|
196
|
+
"type": "object",
|
|
197
|
+
"additionalProperties": false
|
|
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
|
+
"Version": {
|
|
210
|
+
"title": "Version",
|
|
211
|
+
"description": "A value of the store's monotonic write counter. Server-assigned; a producer never chooses one.",
|
|
212
|
+
"type": "integer",
|
|
213
|
+
"minimum": 1
|
|
214
|
+
},
|
|
215
|
+
"Ulid": {
|
|
216
|
+
"title": "Ulid",
|
|
217
|
+
"description": "A ULID in Crockford base32, uppercase. Used for `attributeId` and `profileId`. Chosen over a UUID because the leading 48 bits are a timestamp, so a key-ordered scan of the store is also creation-ordered and a `list` needs no secondary sort. Server-assigned on create; a producer MAY supply one to make a create idempotent, and a maintainer MUST reject a supplied value that already exists rather than silently overwriting.",
|
|
218
|
+
"type": "string",
|
|
219
|
+
"pattern": "^[0-9A-HJKMNP-TV-Z]{26}$"
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
} as const;
|
|
223
|
+
|
|
224
|
+
/**
|
|
225
|
+
* SPEC.md §7.2 policy for the request variant, from this specification's
|
|
226
|
+
* front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
|
|
227
|
+
* per-specification and cannot be derived from the document alone, and
|
|
228
|
+
* item 2 needs the schema this carries.
|
|
229
|
+
*/
|
|
230
|
+
export const SPEC = {
|
|
231
|
+
typeUri: TYPE_URI,
|
|
232
|
+
isBearer: false,
|
|
233
|
+
isProofRequired: true,
|
|
234
|
+
isRecipientRequired: true,
|
|
235
|
+
isIssuedAtRequired: false,
|
|
236
|
+
payloadSchema: PAYLOAD_SCHEMA,
|
|
237
|
+
} as const;
|
|
238
|
+
|
|
239
|
+
/**
|
|
240
|
+
* SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
|
|
241
|
+
* tracks the *issuer* party's requirement because a response swaps the
|
|
242
|
+
* parties (§7.3 item 5).
|
|
243
|
+
*/
|
|
244
|
+
export const RESPONSE_SPEC = {
|
|
245
|
+
typeUri: RESPONSE_TYPE_URI,
|
|
246
|
+
isBearer: false,
|
|
247
|
+
isProofRequired: true,
|
|
248
|
+
isRecipientRequired: true,
|
|
249
|
+
isIssuedAtRequired: false,
|
|
250
|
+
payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
|
|
251
|
+
} as const;
|
|
@@ -0,0 +1,260 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
|
|
3
|
+
* Source: specs/persona/local/profile/list/1.0/payload.schema.json
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
import type { Ext, Ulid } from "../../../../../_shared/components.js";
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Enumerate this context's local profiles. A separate keyspace from the holder's pool, so the scan structurally cannot return a pool profile — the isolation is in the address, not in a filter that could be got wrong.
|
|
11
|
+
*/
|
|
12
|
+
export interface PersonaLocalProfileListPayload {
|
|
13
|
+
contextId: string;
|
|
14
|
+
cursor?: string;
|
|
15
|
+
limit?: number;
|
|
16
|
+
ext?: Ext;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Success response to persona/local/profile/list. Type https://trusttasks.org/spec/persona/local/profile/list/1.0#response.
|
|
20
|
+
*/
|
|
21
|
+
export interface PersonaLocalProfileListResponsePayload {
|
|
22
|
+
/**
|
|
23
|
+
* @maxItems 500
|
|
24
|
+
*/
|
|
25
|
+
profiles: {
|
|
26
|
+
profileId: Ulid;
|
|
27
|
+
name: string;
|
|
28
|
+
entryCount: number;
|
|
29
|
+
/**
|
|
30
|
+
* Whether a persona in this context is bound to it.
|
|
31
|
+
*/
|
|
32
|
+
bound?: boolean;
|
|
33
|
+
}[];
|
|
34
|
+
nextCursor?: string;
|
|
35
|
+
ext?: Ext;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/** Shared definitions this specification references, re-exported under the names it used to declare them with. */
|
|
39
|
+
export type { Ext, Ulid };
|
|
40
|
+
|
|
41
|
+
/** Trust Task type URI. */
|
|
42
|
+
export const TYPE_URI = "https://trusttasks.org/spec/persona/local/profile/list/1.0" as const;
|
|
43
|
+
|
|
44
|
+
/** Stable alias for this specification's request payload shape. */
|
|
45
|
+
export type Payload = PersonaLocalProfileListPayload;
|
|
46
|
+
|
|
47
|
+
/** Trust Task response type URI (request type URI + "#response"). */
|
|
48
|
+
export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/persona/local/profile/list/1.0#response" as const;
|
|
49
|
+
|
|
50
|
+
/** Stable alias for this specification's success-response payload shape. */
|
|
51
|
+
export type Response = PersonaLocalProfileListResponsePayload;
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* This specification's payload schema, as a value.
|
|
55
|
+
*
|
|
56
|
+
* SPEC.md §7.2 item 2 is performed against this. It is shipped as data
|
|
57
|
+
* rather than only as a `.json` file because TypeScript types are erased
|
|
58
|
+
* at runtime: without a schema a consumer has nothing to validate, and
|
|
59
|
+
* every REQUIRED payload member is optional in practice. Cross-file
|
|
60
|
+
* `$ref`s are already inlined, so it needs no resolver.
|
|
61
|
+
*/
|
|
62
|
+
export const PAYLOAD_SCHEMA = {
|
|
63
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
64
|
+
"$id": "https://trusttasks.org/spec/persona/local/profile/list/1.0",
|
|
65
|
+
"title": "Persona Local Profile List — payload",
|
|
66
|
+
"type": "object",
|
|
67
|
+
"additionalProperties": false,
|
|
68
|
+
"properties": {
|
|
69
|
+
"contextId": {
|
|
70
|
+
"type": "string",
|
|
71
|
+
"minLength": 1
|
|
72
|
+
},
|
|
73
|
+
"cursor": {
|
|
74
|
+
"type": "string",
|
|
75
|
+
"maxLength": 4096
|
|
76
|
+
},
|
|
77
|
+
"limit": {
|
|
78
|
+
"type": "integer",
|
|
79
|
+
"minimum": 1,
|
|
80
|
+
"maximum": 500,
|
|
81
|
+
"default": 100
|
|
82
|
+
},
|
|
83
|
+
"ext": {
|
|
84
|
+
"$ref": "#/$defs/Ext"
|
|
85
|
+
}
|
|
86
|
+
},
|
|
87
|
+
"$defs": {
|
|
88
|
+
"Response": {
|
|
89
|
+
"required": [
|
|
90
|
+
"profiles"
|
|
91
|
+
],
|
|
92
|
+
"properties": {
|
|
93
|
+
"profiles": {
|
|
94
|
+
"type": "array",
|
|
95
|
+
"maxItems": 500,
|
|
96
|
+
"items": {
|
|
97
|
+
"type": "object",
|
|
98
|
+
"additionalProperties": false,
|
|
99
|
+
"required": [
|
|
100
|
+
"profileId",
|
|
101
|
+
"name",
|
|
102
|
+
"entryCount"
|
|
103
|
+
],
|
|
104
|
+
"properties": {
|
|
105
|
+
"profileId": {
|
|
106
|
+
"$ref": "#/$defs/Ulid"
|
|
107
|
+
},
|
|
108
|
+
"name": {
|
|
109
|
+
"type": "string",
|
|
110
|
+
"maxLength": 128
|
|
111
|
+
},
|
|
112
|
+
"entryCount": {
|
|
113
|
+
"type": "integer",
|
|
114
|
+
"minimum": 0
|
|
115
|
+
},
|
|
116
|
+
"bound": {
|
|
117
|
+
"type": "boolean",
|
|
118
|
+
"description": "Whether a persona in this context is bound to it."
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
"nextCursor": {
|
|
124
|
+
"type": "string",
|
|
125
|
+
"maxLength": 4096
|
|
126
|
+
},
|
|
127
|
+
"ext": {
|
|
128
|
+
"$ref": "#/$defs/Ext"
|
|
129
|
+
}
|
|
130
|
+
},
|
|
131
|
+
"$anchor": "response",
|
|
132
|
+
"title": "Persona Local Profile List — response payload",
|
|
133
|
+
"description": "Success response to persona/local/profile/list. Type https://trusttasks.org/spec/persona/local/profile/list/1.0#response.",
|
|
134
|
+
"type": "object",
|
|
135
|
+
"additionalProperties": false
|
|
136
|
+
},
|
|
137
|
+
"Ext": {
|
|
138
|
+
"title": "Ext",
|
|
139
|
+
"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.",
|
|
140
|
+
"type": "object",
|
|
141
|
+
"minProperties": 1,
|
|
142
|
+
"additionalProperties": true,
|
|
143
|
+
"propertyNames": {
|
|
144
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
145
|
+
}
|
|
146
|
+
},
|
|
147
|
+
"Ulid": {
|
|
148
|
+
"title": "Ulid",
|
|
149
|
+
"description": "A ULID in Crockford base32, uppercase. Used for `attributeId` and `profileId`. Chosen over a UUID because the leading 48 bits are a timestamp, so a key-ordered scan of the store is also creation-ordered and a `list` needs no secondary sort. Server-assigned on create; a producer MAY supply one to make a create idempotent, and a maintainer MUST reject a supplied value that already exists rather than silently overwriting.",
|
|
150
|
+
"type": "string",
|
|
151
|
+
"pattern": "^[0-9A-HJKMNP-TV-Z]{26}$"
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
"description": "Enumerate this context's local profiles. A separate keyspace from the holder's pool, so the scan structurally cannot return a pool profile — the isolation is in the address, not in a filter that could be got wrong.",
|
|
155
|
+
"required": [
|
|
156
|
+
"contextId"
|
|
157
|
+
]
|
|
158
|
+
} as const;
|
|
159
|
+
|
|
160
|
+
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
161
|
+
export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
162
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
163
|
+
"$ref": "#/$defs/Response",
|
|
164
|
+
"$defs": {
|
|
165
|
+
"Response": {
|
|
166
|
+
"required": [
|
|
167
|
+
"profiles"
|
|
168
|
+
],
|
|
169
|
+
"properties": {
|
|
170
|
+
"profiles": {
|
|
171
|
+
"type": "array",
|
|
172
|
+
"maxItems": 500,
|
|
173
|
+
"items": {
|
|
174
|
+
"type": "object",
|
|
175
|
+
"additionalProperties": false,
|
|
176
|
+
"required": [
|
|
177
|
+
"profileId",
|
|
178
|
+
"name",
|
|
179
|
+
"entryCount"
|
|
180
|
+
],
|
|
181
|
+
"properties": {
|
|
182
|
+
"profileId": {
|
|
183
|
+
"$ref": "#/$defs/Ulid"
|
|
184
|
+
},
|
|
185
|
+
"name": {
|
|
186
|
+
"type": "string",
|
|
187
|
+
"maxLength": 128
|
|
188
|
+
},
|
|
189
|
+
"entryCount": {
|
|
190
|
+
"type": "integer",
|
|
191
|
+
"minimum": 0
|
|
192
|
+
},
|
|
193
|
+
"bound": {
|
|
194
|
+
"type": "boolean",
|
|
195
|
+
"description": "Whether a persona in this context is bound to it."
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
},
|
|
200
|
+
"nextCursor": {
|
|
201
|
+
"type": "string",
|
|
202
|
+
"maxLength": 4096
|
|
203
|
+
},
|
|
204
|
+
"ext": {
|
|
205
|
+
"$ref": "#/$defs/Ext"
|
|
206
|
+
}
|
|
207
|
+
},
|
|
208
|
+
"$anchor": "response",
|
|
209
|
+
"title": "Persona Local Profile List — response payload",
|
|
210
|
+
"description": "Success response to persona/local/profile/list. Type https://trusttasks.org/spec/persona/local/profile/list/1.0#response.",
|
|
211
|
+
"type": "object",
|
|
212
|
+
"additionalProperties": false
|
|
213
|
+
},
|
|
214
|
+
"Ext": {
|
|
215
|
+
"title": "Ext",
|
|
216
|
+
"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.",
|
|
217
|
+
"type": "object",
|
|
218
|
+
"minProperties": 1,
|
|
219
|
+
"additionalProperties": true,
|
|
220
|
+
"propertyNames": {
|
|
221
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
222
|
+
}
|
|
223
|
+
},
|
|
224
|
+
"Ulid": {
|
|
225
|
+
"title": "Ulid",
|
|
226
|
+
"description": "A ULID in Crockford base32, uppercase. Used for `attributeId` and `profileId`. Chosen over a UUID because the leading 48 bits are a timestamp, so a key-ordered scan of the store is also creation-ordered and a `list` needs no secondary sort. Server-assigned on create; a producer MAY supply one to make a create idempotent, and a maintainer MUST reject a supplied value that already exists rather than silently overwriting.",
|
|
227
|
+
"type": "string",
|
|
228
|
+
"pattern": "^[0-9A-HJKMNP-TV-Z]{26}$"
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
} as const;
|
|
232
|
+
|
|
233
|
+
/**
|
|
234
|
+
* SPEC.md §7.2 policy for the request variant, from this specification's
|
|
235
|
+
* front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
|
|
236
|
+
* per-specification and cannot be derived from the document alone, and
|
|
237
|
+
* item 2 needs the schema this carries.
|
|
238
|
+
*/
|
|
239
|
+
export const SPEC = {
|
|
240
|
+
typeUri: TYPE_URI,
|
|
241
|
+
isBearer: false,
|
|
242
|
+
isProofRequired: true,
|
|
243
|
+
isRecipientRequired: true,
|
|
244
|
+
isIssuedAtRequired: false,
|
|
245
|
+
payloadSchema: PAYLOAD_SCHEMA,
|
|
246
|
+
} as const;
|
|
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 const RESPONSE_SPEC = {
|
|
254
|
+
typeUri: RESPONSE_TYPE_URI,
|
|
255
|
+
isBearer: false,
|
|
256
|
+
isProofRequired: true,
|
|
257
|
+
isRecipientRequired: true,
|
|
258
|
+
isIssuedAtRequired: false,
|
|
259
|
+
payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
|
|
260
|
+
} as const;
|