@openplanr/protocol 0.8.0 → 0.10.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.
Files changed (70) hide show
  1. package/README.md +9 -0
  2. package/package.json +17 -1
  3. package/registries/commands.json +22 -22
  4. package/registries/skills.json +136 -58
  5. package/registry/v1.17.0/commands.json +88 -0
  6. package/schemas/v1.16.0/artifact-envelope.schema.json +408 -0
  7. package/schemas/v1.16.0/design-review-bundle.schema.json +590 -0
  8. package/schemas/v1.17.0/artifact-paste-v2.schema.json +52 -0
  9. package/schemas/v1.17.0/artifact-room-append-v3.schema.json +159 -0
  10. package/schemas/v1.17.0/artifact-room-create-v3.schema.json +111 -0
  11. package/schemas/v1.17.0/artifact-room-descriptor-v3.schema.json +92 -0
  12. package/schemas/v1.17.0/artifact-room-event-v3.schema.json +130 -0
  13. package/schemas/v1.17.0/artifact-room-management-v3.schema.json +47 -0
  14. package/schemas/v1.17.0/artifact-room-read-page-v3.schema.json +308 -0
  15. package/schemas/v1.17.0/company-resource-manifest.schema.json +128 -0
  16. package/schemas/v1.17.0/company-resource-upload-prepare.schema.json +164 -0
  17. package/schemas/v1.17.0/company-resource-upload-receipt.schema.json +63 -0
  18. package/schemas/v1.17.0/company-resource-upload-status.schema.json +123 -0
  19. package/schemas/v1.17.0/diagram-authoring-bundle.schema.json +1117 -0
  20. package/schemas/v1.17.0/diagram-edit-transaction.schema.json +3295 -0
  21. package/schemas/v1.17.0/diagram-presentation.schema.json +37 -0
  22. package/schemas/v1.17.0/diagram-review-bundle.schema.json +2439 -0
  23. package/schemas/v1.17.0/encrypted-resource-manifest.schema.json +131 -0
  24. package/schemas/v1.17.0/encrypted-upload-commit.schema.json +38 -0
  25. package/schemas/v1.17.0/encrypted-upload-prepare.schema.json +234 -0
  26. package/schemas/v1.17.0/encrypted-upload-receipt.schema.json +54 -0
  27. package/schemas/v1.17.0/encrypted-upload-status.schema.json +129 -0
  28. package/schemas/v1.17.0/encrypted-workspace-event-v2.schema.json +79 -0
  29. package/schemas/v1.17.0/encrypted-workspace-v2.schema.json +91 -0
  30. package/schemas/v1.17.0/enterprise-agent-handoff.schema.json +985 -0
  31. package/schemas/v1.17.0/enterprise-artifact-revision.schema.json +115 -0
  32. package/schemas/v1.17.0/enterprise-change-proposal.schema.json +379 -0
  33. package/schemas/v1.17.0/enterprise-evidence-reference.schema.json +159 -0
  34. package/schemas/v1.17.0/enterprise-review-thread.schema.json +298 -0
  35. package/schemas/v1.17.0/enterprise-sync-state.schema.json +189 -0
  36. package/schemas/v1.17.0/preview-bridge-message.schema.json +197 -0
  37. package/schemas/v1.17.0/resource-catalog.schema.json +145 -0
  38. package/schemas/v1.17.0/sharing-crypto-aad.schema.json +36 -0
  39. package/schemas/v1.17.0/workspace-management-v2.schema.json +45 -0
  40. package/schemas/v1.17.0/workspace-rotation-v2.schema.json +61 -0
  41. package/schemas/v1.18.0/runtime-lock.schema.json +122 -0
  42. package/src/bounded-json-data.d.mts +2 -0
  43. package/src/bounded-json-data.mjs +56 -0
  44. package/src/browser-contracts.d.mts +14 -1
  45. package/src/browser-contracts.mjs +16 -0
  46. package/src/canonical-json.mjs +17 -16
  47. package/src/contracts.d.mts +1 -1
  48. package/src/contracts.mjs +97 -3
  49. package/src/diagram-authoring-contracts.d.mts +12 -0
  50. package/src/diagram-authoring-contracts.mjs +174 -1
  51. package/src/enterprise-contract-validation.d.mts +44 -0
  52. package/src/enterprise-contract-validation.mjs +279 -0
  53. package/src/enterprise-contracts.mjs +25 -231
  54. package/src/enterprise-resource-contracts.d.mts +72 -0
  55. package/src/enterprise-resource-contracts.mjs +202 -0
  56. package/src/generated/artifact-envelope-metadata.mjs +769 -0
  57. package/src/generated/canonical-registries.mjs +158 -80
  58. package/src/index.d.mts +21 -0
  59. package/src/index.mjs +23 -0
  60. package/src/large-object-contracts.d.mts +107 -0
  61. package/src/large-object-contracts.mjs +473 -0
  62. package/src/large-object-limits.d.mts +16 -0
  63. package/src/large-object-limits.mjs +17 -0
  64. package/src/registries.mjs +1 -0
  65. package/src/review-experience-contracts.d.mts +1 -0
  66. package/src/review-experience-contracts.mjs +25 -4
  67. package/src/sharing-security-contracts.d.mts +63 -0
  68. package/src/sharing-security-contracts.mjs +403 -0
  69. package/src/studio-presentation-contracts.d.mts +92 -0
  70. package/src/studio-presentation-contracts.mjs +287 -0
@@ -0,0 +1,590 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://openplanr.dev/schemas/v1.16.0/design-review-bundle.schema.json",
4
+ "x-openplanr-contract": {
5
+ "id": "design-review-bundle",
6
+ "version": "1.16.0"
7
+ },
8
+ "type": "object",
9
+ "additionalProperties": false,
10
+ "properties": {
11
+ "kind": {
12
+ "const": "openplanr-design-review-bundle"
13
+ },
14
+ "schemaVersion": {
15
+ "const": "1.2.0"
16
+ },
17
+ "design": {
18
+ "type": "object",
19
+ "additionalProperties": false,
20
+ "properties": {
21
+ "id": {
22
+ "$ref": "#/$defs/id"
23
+ },
24
+ "title": {
25
+ "$ref": "#/$defs/text"
26
+ },
27
+ "frames": {
28
+ "type": "array",
29
+ "minItems": 1,
30
+ "items": {
31
+ "type": "object",
32
+ "additionalProperties": false,
33
+ "required": [
34
+ "id",
35
+ "label",
36
+ "width",
37
+ "height"
38
+ ],
39
+ "properties": {
40
+ "id": {
41
+ "$ref": "#/$defs/id"
42
+ },
43
+ "label": {
44
+ "$ref": "#/$defs/text"
45
+ },
46
+ "width": {
47
+ "type": "integer",
48
+ "minimum": 1,
49
+ "maximum": 16384
50
+ },
51
+ "height": {
52
+ "type": "integer",
53
+ "minimum": 1,
54
+ "maximum": 16384
55
+ }
56
+ }
57
+ }
58
+ },
59
+ "screens": {
60
+ "type": "array",
61
+ "minItems": 1,
62
+ "items": {
63
+ "type": "object",
64
+ "additionalProperties": false,
65
+ "required": [
66
+ "id",
67
+ "title"
68
+ ],
69
+ "properties": {
70
+ "id": {
71
+ "$ref": "#/$defs/id"
72
+ },
73
+ "title": {
74
+ "$ref": "#/$defs/text"
75
+ },
76
+ "description": {
77
+ "$ref": "#/$defs/text"
78
+ },
79
+ "anchors": {
80
+ "$ref": "#/$defs/ids"
81
+ }
82
+ }
83
+ }
84
+ },
85
+ "screenOrder": {
86
+ "type": "array",
87
+ "minItems": 1,
88
+ "items": {
89
+ "$ref": "#/$defs/id"
90
+ },
91
+ "uniqueItems": true
92
+ },
93
+ "flows": {
94
+ "type": "array",
95
+ "items": {
96
+ "type": "object",
97
+ "additionalProperties": false,
98
+ "required": [
99
+ "id",
100
+ "title",
101
+ "screens"
102
+ ],
103
+ "properties": {
104
+ "id": {
105
+ "$ref": "#/$defs/id"
106
+ },
107
+ "title": {
108
+ "$ref": "#/$defs/text"
109
+ },
110
+ "screens": {
111
+ "type": "array",
112
+ "minItems": 1,
113
+ "items": {
114
+ "$ref": "#/$defs/id"
115
+ }
116
+ }
117
+ }
118
+ }
119
+ },
120
+ "variants": {
121
+ "type": "array",
122
+ "minItems": 1,
123
+ "items": {
124
+ "type": "object",
125
+ "additionalProperties": false,
126
+ "required": [
127
+ "id",
128
+ "label",
129
+ "status"
130
+ ],
131
+ "properties": {
132
+ "id": {
133
+ "$ref": "#/$defs/id"
134
+ },
135
+ "label": {
136
+ "$ref": "#/$defs/text"
137
+ },
138
+ "description": {
139
+ "$ref": "#/$defs/text"
140
+ },
141
+ "status": {
142
+ "enum": [
143
+ "ready",
144
+ "failed"
145
+ ]
146
+ },
147
+ "issue": {
148
+ "$ref": "#/$defs/text"
149
+ }
150
+ },
151
+ "if": {
152
+ "properties": {
153
+ "status": {
154
+ "const": "failed"
155
+ }
156
+ }
157
+ },
158
+ "then": {
159
+ "required": [
160
+ "issue"
161
+ ]
162
+ }
163
+ }
164
+ },
165
+ "selectedVariant": {
166
+ "$ref": "#/$defs/id"
167
+ },
168
+ "defaultView": {
169
+ "enum": [
170
+ "canvas",
171
+ "prototype",
172
+ "walkthrough"
173
+ ]
174
+ }
175
+ },
176
+ "required": [
177
+ "id",
178
+ "title",
179
+ "frames",
180
+ "screens",
181
+ "screenOrder",
182
+ "variants",
183
+ "selectedVariant",
184
+ "defaultView"
185
+ ]
186
+ },
187
+ "envelope": {
188
+ "type": "object",
189
+ "required": [
190
+ "schemaVersion",
191
+ "sources",
192
+ "artifacts",
193
+ "viewer"
194
+ ],
195
+ "properties": {
196
+ "schemaVersion": {
197
+ "const": "1.1.0"
198
+ }
199
+ }
200
+ },
201
+ "entries": {
202
+ "type": "array",
203
+ "minItems": 1,
204
+ "maxItems": 4096,
205
+ "items": {
206
+ "type": "object",
207
+ "additionalProperties": false,
208
+ "required": [
209
+ "artifactId",
210
+ "screenId",
211
+ "variantId",
212
+ "frameId"
213
+ ],
214
+ "properties": {
215
+ "artifactId": {
216
+ "type": "string",
217
+ "minLength": 1,
218
+ "maxLength": 128
219
+ },
220
+ "screenId": {
221
+ "type": "string",
222
+ "minLength": 1,
223
+ "maxLength": 128
224
+ },
225
+ "variantId": {
226
+ "type": "string",
227
+ "minLength": 1,
228
+ "maxLength": 128
229
+ },
230
+ "frameId": {
231
+ "type": "string",
232
+ "minLength": 1,
233
+ "maxLength": 128
234
+ }
235
+ }
236
+ }
237
+ },
238
+ "state": {
239
+ "type": [
240
+ "object",
241
+ "null"
242
+ ],
243
+ "additionalProperties": false,
244
+ "properties": {
245
+ "positions": {
246
+ "type": "object",
247
+ "additionalProperties": {
248
+ "type": "object",
249
+ "additionalProperties": false,
250
+ "required": [
251
+ "x",
252
+ "y"
253
+ ],
254
+ "properties": {
255
+ "x": {
256
+ "type": "number",
257
+ "minimum": -10000000,
258
+ "maximum": 10000000
259
+ },
260
+ "y": {
261
+ "type": "number",
262
+ "minimum": -10000000,
263
+ "maximum": 10000000
264
+ }
265
+ }
266
+ }
267
+ }
268
+ }
269
+ },
270
+ "revision": {
271
+ "type": "string",
272
+ "minLength": 1,
273
+ "maxLength": 128
274
+ },
275
+ "verification": {
276
+ "type": [
277
+ "object",
278
+ "null"
279
+ ],
280
+ "additionalProperties": false,
281
+ "properties": {
282
+ "status": {
283
+ "enum": [
284
+ "verified",
285
+ "unverified",
286
+ "failed",
287
+ "pending"
288
+ ]
289
+ }
290
+ }
291
+ },
292
+ "reviewContext": {
293
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
294
+ "$id": "https://openplanr.dev/schemas/v1.10.0/design-review-context.schema.json",
295
+ "x-openplanr-contract": {
296
+ "id": "design-review-context",
297
+ "version": "1.10.0"
298
+ },
299
+ "type": "object",
300
+ "additionalProperties": false,
301
+ "properties": {
302
+ "kind": {
303
+ "const": "openplanr-design-review-context"
304
+ },
305
+ "schemaVersion": {
306
+ "const": "1.0.0"
307
+ },
308
+ "designId": {
309
+ "type": "string",
310
+ "minLength": 1,
311
+ "maxLength": 128
312
+ },
313
+ "brief": {
314
+ "type": "object",
315
+ "additionalProperties": false,
316
+ "properties": {
317
+ "purpose": {
318
+ "type": "string",
319
+ "maxLength": 16384
320
+ },
321
+ "requests": {
322
+ "type": "array",
323
+ "maxItems": 3,
324
+ "items": {
325
+ "type": "string",
326
+ "maxLength": 16384
327
+ }
328
+ },
329
+ "audience": {
330
+ "type": "string",
331
+ "maxLength": 16384
332
+ }
333
+ },
334
+ "required": [
335
+ "purpose",
336
+ "requests"
337
+ ]
338
+ },
339
+ "revisionSummary": {
340
+ "type": "string",
341
+ "maxLength": 16384
342
+ },
343
+ "implementation": {
344
+ "type": "object",
345
+ "additionalProperties": false,
346
+ "properties": {
347
+ "tokens": {
348
+ "type": "array",
349
+ "maxItems": 512,
350
+ "items": {
351
+ "type": "object",
352
+ "additionalProperties": false,
353
+ "properties": {
354
+ "name": {
355
+ "type": "string",
356
+ "minLength": 1,
357
+ "maxLength": 128
358
+ },
359
+ "value": {
360
+ "type": "string",
361
+ "maxLength": 16384
362
+ },
363
+ "description": {
364
+ "type": "string",
365
+ "maxLength": 16384
366
+ }
367
+ },
368
+ "required": [
369
+ "name",
370
+ "value"
371
+ ]
372
+ }
373
+ },
374
+ "components": {
375
+ "type": "array",
376
+ "maxItems": 256,
377
+ "items": {
378
+ "type": "object",
379
+ "additionalProperties": false,
380
+ "properties": {
381
+ "id": {
382
+ "type": "string",
383
+ "minLength": 1,
384
+ "maxLength": 128
385
+ },
386
+ "name": {
387
+ "type": "string",
388
+ "maxLength": 16384
389
+ },
390
+ "screenIds": {
391
+ "type": "array",
392
+ "maxItems": 256,
393
+ "items": {
394
+ "type": "string",
395
+ "minLength": 1,
396
+ "maxLength": 128
397
+ }
398
+ },
399
+ "anchorIds": {
400
+ "type": "array",
401
+ "maxItems": 256,
402
+ "items": {
403
+ "type": "string",
404
+ "minLength": 1,
405
+ "maxLength": 128
406
+ }
407
+ },
408
+ "states": {
409
+ "type": "array",
410
+ "maxItems": 256,
411
+ "items": {
412
+ "type": "object",
413
+ "additionalProperties": false,
414
+ "properties": {
415
+ "name": {
416
+ "type": "string",
417
+ "minLength": 1,
418
+ "maxLength": 128
419
+ },
420
+ "description": {
421
+ "type": "string",
422
+ "maxLength": 16384
423
+ }
424
+ },
425
+ "required": [
426
+ "name",
427
+ "description"
428
+ ]
429
+ }
430
+ },
431
+ "notes": {
432
+ "type": "string",
433
+ "maxLength": 16384
434
+ },
435
+ "responsive": {
436
+ "type": "string",
437
+ "maxLength": 16384
438
+ },
439
+ "accessibility": {
440
+ "type": "string",
441
+ "maxLength": 16384
442
+ }
443
+ },
444
+ "required": [
445
+ "id",
446
+ "name"
447
+ ]
448
+ }
449
+ },
450
+ "responsive": {
451
+ "type": "array",
452
+ "maxItems": 256,
453
+ "items": {
454
+ "type": "string",
455
+ "maxLength": 16384
456
+ }
457
+ },
458
+ "accessibility": {
459
+ "type": "array",
460
+ "maxItems": 256,
461
+ "items": {
462
+ "type": "string",
463
+ "maxLength": 16384
464
+ }
465
+ }
466
+ },
467
+ "required": [
468
+ "tokens",
469
+ "components",
470
+ "responsive",
471
+ "accessibility"
472
+ ]
473
+ }
474
+ },
475
+ "required": [
476
+ "kind",
477
+ "schemaVersion",
478
+ "designId",
479
+ "brief",
480
+ "implementation"
481
+ ]
482
+ },
483
+ "contextDigest": {
484
+ "type": "string",
485
+ "pattern": "^[a-f0-9]{64}$"
486
+ },
487
+ "fingerprints": {
488
+ "type": "array",
489
+ "maxItems": 4096,
490
+ "items": {
491
+ "type": "object",
492
+ "additionalProperties": false,
493
+ "properties": {
494
+ "screenId": {
495
+ "type": "string",
496
+ "minLength": 1,
497
+ "maxLength": 128
498
+ },
499
+ "variantId": {
500
+ "type": "string",
501
+ "minLength": 1,
502
+ "maxLength": 128
503
+ },
504
+ "frameId": {
505
+ "type": "string",
506
+ "minLength": 1,
507
+ "maxLength": 128
508
+ },
509
+ "contentDigest": {
510
+ "type": "string",
511
+ "pattern": "^[a-f0-9]{64}$"
512
+ },
513
+ "guidanceDigest": {
514
+ "type": "string",
515
+ "pattern": "^[a-f0-9]{64}$"
516
+ }
517
+ },
518
+ "required": [
519
+ "screenId",
520
+ "variantId",
521
+ "frameId",
522
+ "contentDigest",
523
+ "guidanceDigest"
524
+ ]
525
+ }
526
+ }
527
+ },
528
+ "required": [
529
+ "kind",
530
+ "schemaVersion",
531
+ "design",
532
+ "envelope",
533
+ "entries",
534
+ "revision",
535
+ "reviewContext",
536
+ "contextDigest",
537
+ "fingerprints"
538
+ ],
539
+ "$defs": {
540
+ "id": {
541
+ "type": "string",
542
+ "minLength": 1,
543
+ "maxLength": 128,
544
+ "pattern": "^[A-Za-z][A-Za-z0-9_-]*$"
545
+ },
546
+ "text": {
547
+ "type": "string",
548
+ "minLength": 1,
549
+ "pattern": "\\S"
550
+ },
551
+ "ids": {
552
+ "type": "array",
553
+ "items": {
554
+ "$ref": "#/$defs/id"
555
+ },
556
+ "uniqueItems": true
557
+ },
558
+ "localPath": {
559
+ "type": "string",
560
+ "minLength": 1,
561
+ "description": "Path relative to the authored document directory. No URL, traversal, encoded path, query or fragment.",
562
+ "pattern": "^(?!/)(?!.*(?:^|/)\\.{1,2}(?:/|$))(?!.*//)(?!.*[/ ]$)[^\\\\:\\u0000-\\u001F%?#]+$"
563
+ },
564
+ "paths": {
565
+ "type": "array",
566
+ "items": {
567
+ "$ref": "#/$defs/localPath"
568
+ },
569
+ "uniqueItems": true
570
+ },
571
+ "source": {
572
+ "type": "object",
573
+ "additionalProperties": false,
574
+ "required": [
575
+ "html"
576
+ ],
577
+ "properties": {
578
+ "html": {
579
+ "$ref": "#/$defs/localPath"
580
+ },
581
+ "styles": {
582
+ "$ref": "#/$defs/paths"
583
+ },
584
+ "scripts": {
585
+ "$ref": "#/$defs/paths"
586
+ }
587
+ }
588
+ }
589
+ }
590
+ }
@@ -0,0 +1,52 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://openplanr.dev/schemas/v1.17.0/artifact-paste-v2.schema.json",
4
+ "x-openplanr-contract": {
5
+ "id": "artifact-paste-v2",
6
+ "version": "1.17.0"
7
+ },
8
+ "type": "object",
9
+ "additionalProperties": false,
10
+ "properties": {
11
+ "schemaVersion": {
12
+ "const": "2.0.0"
13
+ },
14
+ "operation": {
15
+ "const": "create"
16
+ },
17
+ "id": {
18
+ "type": "string",
19
+ "pattern": "^[A-Za-z0-9_-]{16,128}$"
20
+ },
21
+ "creationId": {
22
+ "type": "string",
23
+ "pattern": "^[A-Za-z0-9_-]{43}$"
24
+ },
25
+ "ttl": {
26
+ "enum": [
27
+ "1d",
28
+ "7d",
29
+ "30d"
30
+ ]
31
+ },
32
+ "iv": {
33
+ "type": "string",
34
+ "pattern": "^[A-Za-z0-9_-]{16}$"
35
+ },
36
+ "ciphertext": {
37
+ "type": "string",
38
+ "pattern": "^[A-Za-z0-9_-]+$",
39
+ "minLength": 22,
40
+ "maxLength": 6990507
41
+ }
42
+ },
43
+ "required": [
44
+ "schemaVersion",
45
+ "operation",
46
+ "id",
47
+ "creationId",
48
+ "ttl",
49
+ "iv",
50
+ "ciphertext"
51
+ ]
52
+ }