@openplanr/protocol 0.6.1 → 0.7.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/README.md +10 -0
- package/lib/dashboard/closed-json-contract.mjs +99 -109
- package/lib/dashboard/operate-experience-audit-display-contract.d.mts +128 -153
- package/lib/dashboard/operate-experience-audit-display-contract.mjs +530 -585
- package/lib/dashboard/operate-experience-display-contract.d.mts +415 -437
- package/lib/dashboard/operate-experience-display-contract.mjs +777 -831
- package/lib/dashboard/operate-experience-surface-contract.d.mts +143 -148
- package/lib/dashboard/operate-experience-surface-contract.mjs +72 -73
- package/lib/dashboard/operate-review-contract.d.mts +7 -14
- package/lib/dashboard/operate-review-contract.mjs +46 -42
- package/lib/dashboard/operate-review-display-workspace-contract.d.mts +2 -5
- package/lib/dashboard/operate-review-display-workspace-contract.mjs +158 -104
- package/lib/dashboard/operate-review-payload-safety.mjs +4 -2
- package/lib/dashboard/operate-review-workspace-projection-v2.d.mts +47 -33
- package/lib/protocol/index.d.ts +2647 -543
- package/package.json +1 -1
- package/registries/artifact-theme.json +64 -0
- package/registries/commands.json +40 -40
- package/registries/skills.json +5 -5
- package/schemas/v1.14.0/artifact-theme.schema.json +316 -0
- package/src/browser-contracts.d.mts +4 -1
- package/src/browser-contracts.mjs +16 -5
- package/src/canonical-json.d.mts +6 -1
- package/src/canonical-json.mjs +100 -22
- package/src/compat/live-evidence-v2.mjs +1611 -485
- package/src/compat/operate-experience-live-patch.mjs +67 -15
- package/src/compat/operating-planning-contracts.mjs +183 -51
- package/src/contracts.d.mts +54 -13
- package/src/contracts.mjs +635 -343
- package/src/design-contracts.mjs +58 -21
- package/src/design-handoff-contracts.d.mts +67 -11
- package/src/design-handoff-contracts.mjs +236 -119
- package/src/design-publication-contracts.mjs +98 -33
- package/src/diagram-authoring-contracts.d.mts +422 -78
- package/src/diagram-authoring-contracts.mjs +1715 -335
- package/src/diagram-contracts.d.mts +4 -1
- package/src/diagram-contracts.mjs +16 -4
- package/src/enterprise-contracts.d.mts +211 -46
- package/src/enterprise-contracts.mjs +738 -184
- package/src/errors.mjs +4 -0
- package/src/generated/canonical-registries.mjs +45 -45
- package/src/index.d.mts +8 -8
- package/src/index.mjs +36 -20
- package/src/json-schema.d.mts +21 -6
- package/src/json-schema.mjs +66 -18
- package/src/planning-contracts.d.mts +8 -2
- package/src/planning-contracts.mjs +33 -7
- package/src/registries.d.mts +11 -3
- package/src/registries.mjs +369 -87
- package/src/review-experience-contracts.d.mts +7 -2
- package/src/review-experience-contracts.mjs +198 -49
- package/src/semver.mjs +5 -1
- package/src/skill-source-contracts.d.mts +36 -16
- package/src/skill-source-contracts.mjs +25 -6
- package/src/task-contracts.d.mts +13 -3
- package/src/task-contracts.mjs +181 -40
- package/src/workspace-contracts.d.mts +38 -10
- package/src/workspace-contracts.mjs +147 -33
package/README.md
CHANGED
|
@@ -47,6 +47,16 @@ new contracts. Validation does not apply edits or grant hosted access.
|
|
|
47
47
|
See the [authoring contract guide](../../docs/diagrams/authoring-contracts.md) for
|
|
48
48
|
content boundaries, digest coverage and legacy compatibility.
|
|
49
49
|
|
|
50
|
+
## Artifact theme
|
|
51
|
+
|
|
52
|
+
Protocol 1.14 adds `registries/artifact-theme.json` and its schema,
|
|
53
|
+
`schemas/v1.14.0/artifact-theme.schema.json`. It succeeds the byte-preserved
|
|
54
|
+
`registry/artifact-theme.json`: it names itself with `kind`, `schemaVersion: "1.1.0"`
|
|
55
|
+
and `protocolVersion`, uses the brand teal on light (`#237a72`, strong `#1b5f59`),
|
|
56
|
+
and adds an `onPrimary` text colour to both palettes. The artifact package
|
|
57
|
+
generates its review theme CSS and JSON from it. The preserved registry keeps its
|
|
58
|
+
original values.
|
|
59
|
+
|
|
50
60
|
## Design document contract
|
|
51
61
|
|
|
52
62
|
The additive `schemas/v1.9.0/design-document.schema.json` defines stable design,
|
|
@@ -1,141 +1,131 @@
|
|
|
1
|
-
import { sha256Hex } from
|
|
1
|
+
import { sha256Hex } from '../../src/canonical-json.mjs';
|
|
2
2
|
|
|
3
3
|
export const hasOwn = (value, key) => Object.hasOwn(value, key);
|
|
4
4
|
|
|
5
5
|
export function deepFreeze(value, seen = new Set()) {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
return Object.freeze(value);
|
|
6
|
+
if (value === null || typeof value !== 'object' || seen.has(value)) return value;
|
|
7
|
+
seen.add(value);
|
|
8
|
+
for (const child of Object.values(value)) deepFreeze(child, seen);
|
|
9
|
+
return Object.freeze(value);
|
|
11
10
|
}
|
|
12
11
|
|
|
13
12
|
export function safeDataClone(value) {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
13
|
+
// Validate the original object graph before cloning. structuredClone drops
|
|
14
|
+
// symbol and non-enumerable properties, so cloning first would allow hidden
|
|
15
|
+
// fields to be laundered out of an otherwise closed contract.
|
|
16
|
+
serializeJcs(value);
|
|
17
|
+
return structuredClone(value);
|
|
19
18
|
}
|
|
20
19
|
|
|
21
20
|
function assertUnicodeScalarString(value) {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
21
|
+
for (let index = 0; index < value.length; index += 1) {
|
|
22
|
+
const code = value.charCodeAt(index);
|
|
23
|
+
if (code >= 0xd800 && code <= 0xdbff) {
|
|
24
|
+
const next = value.charCodeAt(index + 1);
|
|
25
|
+
if (!(next >= 0xdc00 && next <= 0xdfff)) {
|
|
26
|
+
throw new TypeError('JCS requires Unicode scalar strings.');
|
|
27
|
+
}
|
|
28
|
+
index += 1;
|
|
29
|
+
} else if (code >= 0xdc00 && code <= 0xdfff) {
|
|
30
|
+
throw new TypeError('JCS requires Unicode scalar strings.');
|
|
31
|
+
}
|
|
32
|
+
}
|
|
34
33
|
}
|
|
35
34
|
|
|
36
35
|
function serialize(value, seen) {
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
.sort()
|
|
107
|
-
.map((key) => {
|
|
108
|
-
assertUnicodeScalarString(key);
|
|
109
|
-
return `${JSON.stringify(key)}:${serialize(descriptors[key].value, seen)}`;
|
|
110
|
-
});
|
|
111
|
-
return `{${entries.join(",")}}`;
|
|
112
|
-
} finally {
|
|
113
|
-
seen.delete(value);
|
|
114
|
-
}
|
|
36
|
+
if (value === null) return 'null';
|
|
37
|
+
if (typeof value === 'boolean') return value ? 'true' : 'false';
|
|
38
|
+
if (typeof value === 'string') {
|
|
39
|
+
assertUnicodeScalarString(value);
|
|
40
|
+
return JSON.stringify(value);
|
|
41
|
+
}
|
|
42
|
+
if (typeof value === 'number') {
|
|
43
|
+
if (!Number.isFinite(value)) throw new TypeError('JCS requires finite numbers.');
|
|
44
|
+
return JSON.stringify(value);
|
|
45
|
+
}
|
|
46
|
+
if (typeof value !== 'object') throw new TypeError('JCS requires JSON data.');
|
|
47
|
+
if (seen.has(value)) throw new TypeError('JCS cannot canonicalize a cycle.');
|
|
48
|
+
seen.add(value);
|
|
49
|
+
try {
|
|
50
|
+
if (Array.isArray(value)) {
|
|
51
|
+
const ownKeys = Reflect.ownKeys(value);
|
|
52
|
+
if (
|
|
53
|
+
ownKeys.some((key) => {
|
|
54
|
+
if (key === 'length') return false;
|
|
55
|
+
if (typeof key !== 'string') return true;
|
|
56
|
+
const index = Number(key);
|
|
57
|
+
return (
|
|
58
|
+
!Number.isSafeInteger(index) ||
|
|
59
|
+
index < 0 ||
|
|
60
|
+
index >= value.length ||
|
|
61
|
+
String(index) !== key
|
|
62
|
+
);
|
|
63
|
+
})
|
|
64
|
+
) {
|
|
65
|
+
throw new TypeError('JCS requires plain JSON arrays.');
|
|
66
|
+
}
|
|
67
|
+
const entries = [];
|
|
68
|
+
for (let index = 0; index < value.length; index += 1) {
|
|
69
|
+
const descriptor = Object.getOwnPropertyDescriptor(value, String(index));
|
|
70
|
+
if (!descriptor || !descriptor.enumerable || descriptor.get || descriptor.set) {
|
|
71
|
+
throw new TypeError('JCS cannot canonicalize a sparse array.');
|
|
72
|
+
}
|
|
73
|
+
entries.push(serialize(descriptor.value, seen));
|
|
74
|
+
}
|
|
75
|
+
return `[${entries.join(',')}]`;
|
|
76
|
+
}
|
|
77
|
+
const prototype = Object.getPrototypeOf(value);
|
|
78
|
+
if (prototype !== Object.prototype && prototype !== null) {
|
|
79
|
+
throw new TypeError('JCS requires plain JSON objects.');
|
|
80
|
+
}
|
|
81
|
+
const descriptors = Object.getOwnPropertyDescriptors(value);
|
|
82
|
+
if (
|
|
83
|
+
Reflect.ownKeys(value).some((key) => {
|
|
84
|
+
if (typeof key !== 'string') return true;
|
|
85
|
+
const descriptor = descriptors[key];
|
|
86
|
+
return (
|
|
87
|
+
!descriptor?.enumerable ||
|
|
88
|
+
typeof descriptor.get === 'function' ||
|
|
89
|
+
typeof descriptor.set === 'function'
|
|
90
|
+
);
|
|
91
|
+
})
|
|
92
|
+
) {
|
|
93
|
+
throw new TypeError('JCS requires enumerable data properties only.');
|
|
94
|
+
}
|
|
95
|
+
const entries = Object.keys(descriptors)
|
|
96
|
+
.sort()
|
|
97
|
+
.map((key) => {
|
|
98
|
+
assertUnicodeScalarString(key);
|
|
99
|
+
return `${JSON.stringify(key)}:${serialize(descriptors[key].value, seen)}`;
|
|
100
|
+
});
|
|
101
|
+
return `{${entries.join(',')}}`;
|
|
102
|
+
} finally {
|
|
103
|
+
seen.delete(value);
|
|
104
|
+
}
|
|
115
105
|
}
|
|
116
106
|
|
|
117
107
|
export function serializeJcs(value) {
|
|
118
|
-
|
|
108
|
+
return serialize(value, new Set());
|
|
119
109
|
}
|
|
120
110
|
|
|
121
111
|
export function contentHash(value, domain) {
|
|
122
|
-
|
|
112
|
+
return `sha256:${sha256Hex(`${domain}\u0000${serializeJcs(value)}`)}`;
|
|
123
113
|
}
|
|
124
114
|
|
|
125
115
|
export function jcsHash(value) {
|
|
126
|
-
|
|
116
|
+
return `sha256:${sha256Hex(serializeJcs(value))}`;
|
|
127
117
|
}
|
|
128
118
|
|
|
129
119
|
export function withoutContentHash(value) {
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
120
|
+
const clone = safeDataClone(value);
|
|
121
|
+
delete clone.integrity.contentHash;
|
|
122
|
+
return clone;
|
|
133
123
|
}
|
|
134
124
|
|
|
135
125
|
export function exactJson(left, right) {
|
|
136
|
-
|
|
126
|
+
return serializeJcs(left) === serializeJcs(right);
|
|
137
127
|
}
|
|
138
128
|
|
|
139
129
|
export function exactEventHead(left, right) {
|
|
140
|
-
|
|
130
|
+
return left?.sequence === right?.sequence && left?.hash === right?.hash;
|
|
141
131
|
}
|
|
@@ -1,196 +1,171 @@
|
|
|
1
1
|
import type {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
} from
|
|
12
|
-
import type { OperateExperienceSurfaceBaseV1 } from
|
|
2
|
+
OperateExperienceClaimV1,
|
|
3
|
+
OperateExperienceDomainMetricV1,
|
|
4
|
+
OperateExperienceEvidenceV1,
|
|
5
|
+
OperateExperienceHistoryV1,
|
|
6
|
+
OperateExperienceLearningV1,
|
|
7
|
+
OperateExperienceOutcomeV1,
|
|
8
|
+
OperateExperienceRationaleV1,
|
|
9
|
+
OperateExperienceReplayV1,
|
|
10
|
+
ProtocolValidationError,
|
|
11
|
+
} from '../protocol/index.js';
|
|
12
|
+
import type { OperateExperienceSurfaceBaseV1 } from './operate-experience-surface-contract.mjs';
|
|
13
13
|
|
|
14
14
|
export type OperateAuditEventHeadV1 =
|
|
15
|
-
|
|
16
|
-
|
|
15
|
+
| Readonly<{ sequence: 0; hash: null }>
|
|
16
|
+
| Readonly<{ sequence: number; hash: string }>;
|
|
17
17
|
|
|
18
18
|
type NullableDeepLink<T extends object> = Readonly<
|
|
19
|
-
|
|
19
|
+
Omit<T, 'deepLink'> & { deepLink: string | null }
|
|
20
20
|
>;
|
|
21
21
|
|
|
22
22
|
export type OperateAuditDisplayBindingV1 = Readonly<{
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
| "export";
|
|
36
|
-
query: string | null;
|
|
37
|
-
format: "json" | "html" | null;
|
|
38
|
-
generatedAt: string;
|
|
39
|
-
eventHead: OperateAuditEventHeadV1;
|
|
40
|
-
viewHash: string;
|
|
23
|
+
actorId: string;
|
|
24
|
+
scopeId: string;
|
|
25
|
+
domainId: string;
|
|
26
|
+
domainVersion: string;
|
|
27
|
+
cycleId: string;
|
|
28
|
+
subjectId: string | null;
|
|
29
|
+
surface: 'evidence' | 'outcomes' | 'outcome' | 'history' | 'search' | 'export';
|
|
30
|
+
query: string | null;
|
|
31
|
+
format: 'json' | 'html' | null;
|
|
32
|
+
generatedAt: string;
|
|
33
|
+
eventHead: OperateAuditEventHeadV1;
|
|
34
|
+
viewHash: string;
|
|
41
35
|
}>;
|
|
42
36
|
|
|
43
37
|
export type OperateAuditDisplayIntegrityV1 = Readonly<{
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
38
|
+
algorithm: 'sha-256-jcs';
|
|
39
|
+
domain: 'openplanr:operate-experience-audit-display-surface:1.0.0';
|
|
40
|
+
sourceViewHash: string;
|
|
41
|
+
contentHash: string;
|
|
48
42
|
}>;
|
|
49
43
|
|
|
50
44
|
export type OperateAuditEvidenceV1 = Readonly<
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
>[];
|
|
56
|
-
}
|
|
45
|
+
Omit<OperateExperienceEvidenceV1, 'deepLink' | 'causalLinks'> & {
|
|
46
|
+
deepLink: string | null;
|
|
47
|
+
causalLinks: readonly NullableDeepLink<OperateExperienceEvidenceV1['causalLinks'][number]>[];
|
|
48
|
+
}
|
|
57
49
|
>;
|
|
58
50
|
|
|
59
51
|
export type OperateAuditClaimV1 = Readonly<
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
>[];
|
|
65
|
-
}
|
|
52
|
+
Omit<OperateExperienceClaimV1, 'deepLink' | 'causalLinks'> & {
|
|
53
|
+
deepLink: string | null;
|
|
54
|
+
causalLinks: readonly NullableDeepLink<OperateExperienceClaimV1['causalLinks'][number]>[];
|
|
55
|
+
}
|
|
66
56
|
>;
|
|
67
57
|
|
|
68
58
|
export type OperateAuditDomainMetricV1 = Readonly<
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
59
|
+
Omit<OperateExperienceDomainMetricV1, 'dueVerification'> & {
|
|
60
|
+
dueVerification: readonly NullableDeepLink<
|
|
61
|
+
OperateExperienceDomainMetricV1['dueVerification'][number]
|
|
62
|
+
>[];
|
|
63
|
+
}
|
|
74
64
|
>;
|
|
75
65
|
|
|
76
66
|
export type OperateAuditOutcomeV1 = Readonly<
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
NonNullable<OperateExperienceOutcomeV1["decision"]>
|
|
84
|
-
>;
|
|
85
|
-
execution: readonly NullableDeepLink<
|
|
86
|
-
OperateExperienceOutcomeV1["execution"][number]
|
|
87
|
-
>[];
|
|
88
|
-
rollback: readonly NullableDeepLink<
|
|
89
|
-
OperateExperienceOutcomeV1["rollback"][number]
|
|
90
|
-
>[];
|
|
91
|
-
}
|
|
67
|
+
Omit<OperateExperienceOutcomeV1, 'deepLink' | 'decision' | 'execution' | 'rollback'> & {
|
|
68
|
+
deepLink: string | null;
|
|
69
|
+
decision: null | NullableDeepLink<NonNullable<OperateExperienceOutcomeV1['decision']>>;
|
|
70
|
+
execution: readonly NullableDeepLink<OperateExperienceOutcomeV1['execution'][number]>[];
|
|
71
|
+
rollback: readonly NullableDeepLink<OperateExperienceOutcomeV1['rollback'][number]>[];
|
|
72
|
+
}
|
|
92
73
|
>;
|
|
93
74
|
|
|
94
75
|
type AuditPayloadBase = Readonly<
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
mutationEnabled: false;
|
|
100
|
-
eventHead: OperateAuditEventHeadV1;
|
|
101
|
-
}
|
|
76
|
+
Omit<OperateExperienceSurfaceBaseV1, 'surface' | 'mutationEnabled' | 'eventHead'> & {
|
|
77
|
+
mutationEnabled: false;
|
|
78
|
+
eventHead: OperateAuditEventHeadV1;
|
|
79
|
+
}
|
|
102
80
|
>;
|
|
103
81
|
|
|
104
82
|
type OperateAuditReplayV1 = Readonly<
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
}
|
|
83
|
+
Omit<OperateExperienceReplayV1, 'checkpoint' | 'finalHead'> & {
|
|
84
|
+
checkpoint: null | Readonly<
|
|
85
|
+
Omit<NonNullable<OperateExperienceReplayV1['checkpoint']>, 'eventHead'> & {
|
|
86
|
+
eventHead: OperateAuditEventHeadV1;
|
|
87
|
+
}
|
|
88
|
+
>;
|
|
89
|
+
finalHead: OperateAuditEventHeadV1;
|
|
90
|
+
}
|
|
114
91
|
>;
|
|
115
92
|
|
|
116
93
|
export type OperateExperienceAuditDisplaySurfacePayloadV1 = AuditPayloadBase &
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
94
|
+
(
|
|
95
|
+
| Readonly<{
|
|
96
|
+
surface: 'evidence';
|
|
97
|
+
data: Readonly<{
|
|
98
|
+
evidence: readonly OperateAuditEvidenceV1[];
|
|
99
|
+
claims: readonly OperateAuditClaimV1[];
|
|
100
|
+
rationale: readonly OperateExperienceRationaleV1[];
|
|
101
|
+
}>;
|
|
102
|
+
}>
|
|
103
|
+
| Readonly<{
|
|
104
|
+
surface: 'outcomes';
|
|
105
|
+
data: Readonly<{
|
|
106
|
+
domainMetrics: readonly OperateAuditDomainMetricV1[];
|
|
107
|
+
outcomes: readonly OperateAuditOutcomeV1[];
|
|
108
|
+
learnings: readonly OperateExperienceLearningV1[];
|
|
109
|
+
}>;
|
|
110
|
+
}>
|
|
111
|
+
| Readonly<{
|
|
112
|
+
surface: 'outcome';
|
|
113
|
+
data: Readonly<{
|
|
114
|
+
outcome: OperateAuditOutcomeV1;
|
|
115
|
+
learnings: readonly OperateExperienceLearningV1[];
|
|
116
|
+
}>;
|
|
117
|
+
}>
|
|
118
|
+
| Readonly<{
|
|
119
|
+
surface: 'history';
|
|
120
|
+
data: Readonly<{
|
|
121
|
+
history: readonly OperateExperienceHistoryV1[];
|
|
122
|
+
replay: OperateAuditReplayV1;
|
|
123
|
+
}>;
|
|
124
|
+
}>
|
|
125
|
+
| Readonly<{
|
|
126
|
+
surface: 'search';
|
|
127
|
+
data: Readonly<{
|
|
128
|
+
query: string;
|
|
129
|
+
results: readonly Readonly<{
|
|
130
|
+
kind: string;
|
|
131
|
+
subjectId: string;
|
|
132
|
+
title: string;
|
|
133
|
+
summary: string;
|
|
134
|
+
state: string;
|
|
135
|
+
deepLink?: string;
|
|
136
|
+
}>[];
|
|
137
|
+
}>;
|
|
138
|
+
}>
|
|
139
|
+
| Readonly<{
|
|
140
|
+
surface: 'export';
|
|
141
|
+
data: Readonly<{
|
|
142
|
+
format: 'json' | 'html';
|
|
143
|
+
mediaType: 'application/json' | 'text/html; charset=utf-8';
|
|
144
|
+
content: string;
|
|
145
|
+
}>;
|
|
146
|
+
}>
|
|
147
|
+
);
|
|
171
148
|
|
|
172
149
|
export type OperateExperienceAuditDisplaySurfaceV1 = Readonly<{
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
150
|
+
kind: 'operate-experience-audit-display-surface';
|
|
151
|
+
schemaVersion: '1.0.0';
|
|
152
|
+
protocolVersion: '2.0.0';
|
|
153
|
+
requestBinding: OperateAuditDisplayBindingV1;
|
|
154
|
+
payload: OperateExperienceAuditDisplaySurfacePayloadV1;
|
|
155
|
+
integrity: OperateAuditDisplayIntegrityV1;
|
|
179
156
|
}>;
|
|
180
157
|
|
|
181
158
|
export function validateOperateExperienceAuditDisplaySurfaceV1(
|
|
182
|
-
|
|
183
|
-
|
|
159
|
+
value: unknown,
|
|
160
|
+
expected?: OperateAuditDisplayBindingV1,
|
|
184
161
|
): ProtocolValidationError[];
|
|
185
162
|
export function assertOperateExperienceAuditDisplaySurfaceV1(
|
|
186
|
-
|
|
187
|
-
|
|
163
|
+
value: unknown,
|
|
164
|
+
expected?: OperateAuditDisplayBindingV1,
|
|
188
165
|
): OperateExperienceAuditDisplaySurfaceV1;
|
|
189
166
|
export function issueOperateExperienceAuditDisplaySurfaceV1(
|
|
190
|
-
|
|
191
|
-
|
|
167
|
+
payload: OperateExperienceAuditDisplaySurfacePayloadV1,
|
|
168
|
+
binding: OperateAuditDisplayBindingV1,
|
|
192
169
|
): OperateExperienceAuditDisplaySurfaceV1;
|
|
193
170
|
|
|
194
|
-
export const OPERATE_EXPERIENCE_AUDIT_DISPLAY_SURFACE_SCHEMA_V1: Readonly<
|
|
195
|
-
Record<string, unknown>
|
|
196
|
-
>;
|
|
171
|
+
export const OPERATE_EXPERIENCE_AUDIT_DISPLAY_SURFACE_SCHEMA_V1: Readonly<Record<string, unknown>>;
|