@openwop/openwop-conformance 2.35.1 → 2.36.1

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 (121) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/README.md +3 -3
  3. package/coverage.md +13 -1
  4. package/dist/spec-artifacts.lock.json +2 -2
  5. package/fixtures/a2ui-v09/negative-event-name-deleteall.json +139 -0
  6. package/fixtures/a2ui-v09/negative-extra-property.json +140 -0
  7. package/fixtures/a2ui-v09/negative-foreign-catalog.json +139 -0
  8. package/fixtures/a2ui-v09/negative-formatstring-label.json +145 -0
  9. package/fixtures/a2ui-v09/negative-functioncall-openurl.json +129 -0
  10. package/fixtures/a2ui-v09/negative-image-component.json +145 -0
  11. package/fixtures/a2ui-v09/negative-textfield-obscured.json +140 -0
  12. package/fixtures/a2ui-v09/negative-theme-iconurl.json +142 -0
  13. package/fixtures/a2ui-v09/positive-approve-brief.json +139 -0
  14. package/fixtures/conformance-artifact-emit.json +28 -0
  15. package/fixtures/conformance-clarification-nested.json +53 -0
  16. package/fixtures/conformance-clarification-sensitive.json +49 -0
  17. package/fixtures/conformance-credential.json +25 -0
  18. package/fixtures/conformance-mcp-client.json +28 -0
  19. package/fixtures/interrupt-payloads/interrupt-payload-approval.json +1 -0
  20. package/fixtures/interrupt-payloads/interrupt-payload-clarification.json +1 -0
  21. package/fixtures/interrupt-payloads/interrupt-payload-conversation-close.json +1 -0
  22. package/fixtures/interrupt-payloads/interrupt-payload-conversation-exchange.json +1 -0
  23. package/fixtures/interrupt-payloads/interrupt-payload-conversation-start.json +1 -0
  24. package/fixtures/interrupt-payloads/interrupt-payload-custom.json +1 -0
  25. package/fixtures/interrupt-payloads/interrupt-payload-external-event.json +1 -0
  26. package/fixtures/interrupt-payloads/interrupt-payload-low-confidence.json +1 -0
  27. package/fixtures/interrupt-payloads/negative-approval-with-clarification-data.json +1 -0
  28. package/fixtures/interrupt-payloads/negative-conversation-close-with-conversation-start-data.json +1 -0
  29. package/fixtures/interrupt-payloads/negative-conversation-start-with-conversation-exchange-data.json +1 -0
  30. package/fixtures/interrupt-payloads/negative-custom-with-conversation-start-data.json +1 -0
  31. package/fixtures/interrupt-payloads/negative-low-confidence-with-custom-data.json +1 -0
  32. package/fixtures/node-pack-runtime/negative-entry-mismatch.json +31 -0
  33. package/fixtures/node-pack-runtime/negative-headers.json +37 -0
  34. package/fixtures/node-pack-runtime/negative-http.json +31 -0
  35. package/fixtures/node-pack-runtime/negative-icons.json +37 -0
  36. package/fixtures/node-pack-runtime/negative-meta.json +36 -0
  37. package/fixtures/node-pack-runtime/negative-non-remote-language.json +31 -0
  38. package/fixtures/node-pack-runtime/negative-packages.json +41 -0
  39. package/fixtures/node-pack-runtime/negative-sse.json +31 -0
  40. package/fixtures/node-pack-runtime/negative-templated-url.json +31 -0
  41. package/fixtures/node-pack-runtime/negative-two-remotes.json +35 -0
  42. package/fixtures/node-pack-runtime/negative-variables.json +38 -0
  43. package/fixtures/node-pack-runtime/negative-version-range.json +31 -0
  44. package/fixtures/node-pack-runtime/positive-every-optional-member.json +40 -0
  45. package/fixtures/node-pack-runtime/positive-rfc-example.json +31 -0
  46. package/fixtures/node-pack-runtime/upstream/mcp-registry-server-2025-12-11.schema.json +574 -0
  47. package/fixtures/oauth-providers/synthetic.json +36 -4
  48. package/fixtures/upstream/a2a-v1.0.1/README.md +24 -0
  49. package/fixtures/upstream/a2a-v1.0.1/a2a.proto +811 -0
  50. package/fixtures/upstream/a2ui-v0.9/README.md +33 -0
  51. package/fixtures/upstream/a2ui-v0.9/catalog.json +1383 -0
  52. package/fixtures/upstream/a2ui-v0.9/common_types.json +305 -0
  53. package/fixtures/upstream/a2ui-v0.9/server_to_client.json +132 -0
  54. package/fixtures.md +139 -0
  55. package/package.json +2 -2
  56. package/requirements.json +5355 -964
  57. package/scenario-majors.json +93 -6
  58. package/schemas/CORPUS-STAMP.json +103 -89
  59. package/src/lib/localized-content.ts +53 -0
  60. package/src/lib/mcp-fake-server.ts +105 -4
  61. package/src/lib/node-pack-runtime.ts +41 -0
  62. package/src/lib/oauth-as-double.ts +316 -0
  63. package/src/lib/protected-resource.ts +88 -0
  64. package/src/lib/standard-webhooks.ts +120 -0
  65. package/src/lib/toolCatalog.ts +54 -4
  66. package/src/lib/trace-context.ts +98 -0
  67. package/src/lib/v2.ts +6 -0
  68. package/src/lib/webhook-receiver.ts +201 -1
  69. package/src/scenarios/artifact-type-pack-manifest-validation.test.ts +10 -1
  70. package/src/scenarios/auth-challenge-no-oracle.test.ts +122 -0
  71. package/src/scenarios/auth-oauth2-client-credentials.test.ts +46 -5
  72. package/src/scenarios/cross-host-traceparent-propagation.test.ts +92 -58
  73. package/src/scenarios/debugBundle.test.ts +41 -0
  74. package/src/scenarios/fixtures-valid.test.ts +72 -0
  75. package/src/scenarios/inbound-credential-no-passthrough.test.ts +115 -0
  76. package/src/scenarios/interrupt-approver-routing.test.ts +3 -0
  77. package/src/scenarios/localized-content-delivery.test.ts +26 -15
  78. package/src/scenarios/mcp-2026-07-28-discover.test.ts +22 -7
  79. package/src/scenarios/mcp-current-auth-boundary.test.ts +38 -0
  80. package/src/scenarios/mcp-tool-roundtrip.test.ts +29 -0
  81. package/src/scenarios/otel-mcp-semconv-projection.test.ts +85 -0
  82. package/src/scenarios/tool-catalog-compact-projection.test.ts +28 -14
  83. package/src/scenarios/tool-catalog-projection.test.ts +48 -12
  84. package/src/scenarios/tool-descriptor-shape.test.ts +34 -13
  85. package/src/scenarios/v2-a2a-agent-cards.test.ts +305 -0
  86. package/src/scenarios/v2-a2a-operation-map.test.ts +310 -0
  87. package/src/scenarios/v2-a2ui-v09-surface.test.ts +283 -0
  88. package/src/scenarios/v2-advertised-fixtures-exist.test.ts +2 -2
  89. package/src/scenarios/v2-artifact-a2a-shape.test.ts +122 -0
  90. package/src/scenarios/v2-auth-challenge.test.ts +119 -0
  91. package/src/scenarios/v2-bound-id-kinds.test.ts +1 -1
  92. package/src/scenarios/v2-callback-url-guarded.test.ts +2 -2
  93. package/src/scenarios/v2-capability-maturity-bounded.test.ts +108 -0
  94. package/src/scenarios/v2-configurable-closed.test.ts +1 -1
  95. package/src/scenarios/v2-content-locale-keys.test.ts +92 -0
  96. package/src/scenarios/v2-conversation-turn-parts.test.ts +74 -0
  97. package/src/scenarios/v2-credential-interrupt.test.ts +253 -0
  98. package/src/scenarios/v2-effect-identity-business-key.test.ts +2 -2
  99. package/src/scenarios/v2-fork-a-v1-run.test.ts +1 -1
  100. package/src/scenarios/v2-implementation-informational.test.ts +33 -0
  101. package/src/scenarios/v2-interop-trace-context.test.ts +351 -0
  102. package/src/scenarios/v2-lane-exp-only-bound.test.ts +236 -0
  103. package/src/scenarios/v2-lane-issuer-advertised.test.ts +52 -3
  104. package/src/scenarios/v2-mcp-client-results.test.ts +202 -0
  105. package/src/scenarios/v2-mcp-mount-map.test.ts +308 -0
  106. package/src/scenarios/v2-mcp-tasks.test.ts +503 -0
  107. package/src/scenarios/v2-oauth-client-pkce-state-iss.test.ts +203 -0
  108. package/src/scenarios/v2-oauth-mcp-reach-discovery.test.ts +186 -0
  109. package/src/scenarios/v2-oidc-id-token-audience.test.ts +108 -0
  110. package/src/scenarios/v2-protected-resource-metadata.test.ts +145 -0
  111. package/src/scenarios/v2-run-cancel.test.ts +1 -1
  112. package/src/scenarios/v2-run-fork-prefix.test.ts +4 -4
  113. package/src/scenarios/v2-run-pause-resume.test.ts +1 -1
  114. package/src/scenarios/v2-tool-catalog-annotations.test.ts +100 -0
  115. package/src/scenarios/v2-unmapped-type-refused.test.ts +1 -1
  116. package/src/scenarios/v2-v1-events-translated.test.ts +1 -1
  117. package/src/scenarios/v2-webhook-egress-refusal.test.ts +5 -5
  118. package/src/scenarios/v2-webhook-endpoint-verification.test.ts +124 -0
  119. package/src/scenarios/v2-webhook-message-id-stable.test.ts +124 -0
  120. package/src/scenarios/v2-webhook-secret-rotation.test.ts +132 -0
  121. package/src/scenarios/v2-webhook-standard-webhooks-delivery.test.ts +195 -0
@@ -0,0 +1,305 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://a2ui.org/specification/v0_9/common_types.json",
4
+ "title": "A2UI Common Types",
5
+ "description": "Common type definitions used across A2UI schemas.",
6
+ "$defs": {
7
+ "ComponentId": {
8
+ "type": "string",
9
+ "description": "The unique identifier for a component, used for both definitions and references within the same surface."
10
+ },
11
+ "AccessibilityAttributes": {
12
+ "type": "object",
13
+ "description": "Attributes to enhance accessibility when using assistive technologies like screen readers.",
14
+ "properties": {
15
+ "label": {
16
+ "$ref": "#/$defs/DynamicString",
17
+ "description": "A short string, typically 1 to 3 words, used by assistive technologies to convey the purpose or intent of an element. For example, an input field might have an accessible label of 'User ID' or a button might be labeled 'Submit'."
18
+ },
19
+ "description": {
20
+ "$ref": "#/$defs/DynamicString",
21
+ "description": "Additional information provided by assistive technologies about an element such as instructions, format requirements, or result of an action. For example, a mute button might have a label of 'Mute' and a description of 'Silences notifications about this conversation'."
22
+ }
23
+ }
24
+ },
25
+ "ComponentCommon": {
26
+ "type": "object",
27
+ "properties": {
28
+ "id": {
29
+ "$ref": "#/$defs/ComponentId"
30
+ },
31
+ "accessibility": {
32
+ "$ref": "#/$defs/AccessibilityAttributes"
33
+ }
34
+ },
35
+ "required": ["id"]
36
+ },
37
+ "ChildList": {
38
+ "oneOf": [
39
+ {
40
+ "type": "array",
41
+ "items": {
42
+ "$ref": "#/$defs/ComponentId"
43
+ },
44
+ "description": "A static list of child component IDs."
45
+ },
46
+ {
47
+ "type": "object",
48
+ "description": "A template for generating a dynamic list of children from a data model list. The `componentId` is the component to use as a template.",
49
+ "properties": {
50
+ "componentId": {
51
+ "$ref": "#/$defs/ComponentId"
52
+ },
53
+ "path": {
54
+ "type": "string",
55
+ "description": "The path to the list of component property objects in the data model."
56
+ }
57
+ },
58
+ "required": ["componentId", "path"],
59
+ "additionalProperties": false
60
+ }
61
+ ]
62
+ },
63
+ "DataBinding": {
64
+ "type": "object",
65
+ "properties": {
66
+ "path": {
67
+ "type": "string",
68
+ "description": "A JSON Pointer path to a value in the data model."
69
+ }
70
+ },
71
+ "required": ["path"],
72
+ "additionalProperties": false
73
+ },
74
+ "DynamicValue": {
75
+ "description": "A value that can be a literal, a path, or a function call returning any type.",
76
+ "oneOf": [
77
+ {
78
+ "type": "string"
79
+ },
80
+ {
81
+ "type": "number"
82
+ },
83
+ {
84
+ "type": "boolean"
85
+ },
86
+ {
87
+ "type": "array"
88
+ },
89
+ {
90
+ "$ref": "#/$defs/DataBinding"
91
+ },
92
+ {
93
+ "$ref": "#/$defs/FunctionCall"
94
+ }
95
+ ]
96
+ },
97
+ "DynamicString": {
98
+ "description": "Represents a string",
99
+ "oneOf": [
100
+ {
101
+ "type": "string"
102
+ },
103
+ {
104
+ "$ref": "#/$defs/DataBinding"
105
+ },
106
+ {
107
+ "allOf": [
108
+ {
109
+ "$ref": "#/$defs/FunctionCall"
110
+ },
111
+ {
112
+ "properties": {
113
+ "returnType": {
114
+ "const": "string"
115
+ }
116
+ }
117
+ }
118
+ ]
119
+ }
120
+ ]
121
+ },
122
+ "DynamicNumber": {
123
+ "description": "Represents a value that can be either a literal number, a path to a number in the data model, or a function call returning a number.",
124
+ "oneOf": [
125
+ {
126
+ "type": "number"
127
+ },
128
+ {
129
+ "$ref": "#/$defs/DataBinding"
130
+ },
131
+ {
132
+ "allOf": [
133
+ {
134
+ "$ref": "#/$defs/FunctionCall"
135
+ },
136
+ {
137
+ "properties": {
138
+ "returnType": {
139
+ "const": "number"
140
+ }
141
+ }
142
+ }
143
+ ]
144
+ }
145
+ ]
146
+ },
147
+ "DynamicBoolean": {
148
+ "description": "A boolean value that can be a literal, a path, or a function call returning a boolean.",
149
+ "oneOf": [
150
+ {
151
+ "type": "boolean"
152
+ },
153
+ {
154
+ "$ref": "#/$defs/DataBinding"
155
+ },
156
+ {
157
+ "allOf": [
158
+ {
159
+ "$ref": "#/$defs/FunctionCall"
160
+ },
161
+ {
162
+ "properties": {
163
+ "returnType": {
164
+ "const": "boolean"
165
+ }
166
+ }
167
+ }
168
+ ]
169
+ }
170
+ ]
171
+ },
172
+ "DynamicStringList": {
173
+ "description": "Represents a value that can be either a literal array of strings, a path to a string array in the data model, or a function call returning a string array.",
174
+ "oneOf": [
175
+ {
176
+ "type": "array",
177
+ "items": {
178
+ "type": "string"
179
+ }
180
+ },
181
+ {
182
+ "$ref": "#/$defs/DataBinding"
183
+ },
184
+ {
185
+ "allOf": [
186
+ {
187
+ "$ref": "#/$defs/FunctionCall"
188
+ },
189
+ {
190
+ "properties": {
191
+ "returnType": {
192
+ "const": "array"
193
+ }
194
+ }
195
+ }
196
+ ]
197
+ }
198
+ ]
199
+ },
200
+ "FunctionCall": {
201
+ "type": "object",
202
+ "description": "Invokes a named function on the client.",
203
+ "properties": {
204
+ "call": {
205
+ "type": "string",
206
+ "description": "The name of the function to call."
207
+ },
208
+ "args": {
209
+ "type": "object",
210
+ "description": "Arguments passed to the function.",
211
+ "additionalProperties": {
212
+ "anyOf": [
213
+ {
214
+ "$ref": "#/$defs/DynamicValue"
215
+ },
216
+ {
217
+ "type": "object",
218
+ "description": "A literal object argument (e.g. configuration)."
219
+ }
220
+ ]
221
+ }
222
+ },
223
+ "returnType": {
224
+ "type": "string",
225
+ "description": "The expected return type of the function call.",
226
+ "enum": ["string", "number", "boolean", "array", "object", "any", "void"],
227
+ "default": "boolean"
228
+ }
229
+ },
230
+ "required": ["call"],
231
+ "oneOf": [{"$ref": "catalog.json#/$defs/anyFunction"}]
232
+ },
233
+ "CheckRule": {
234
+ "type": "object",
235
+ "description": "A single validation rule applied to an input component.",
236
+ "properties": {
237
+ "condition": {
238
+ "$ref": "#/$defs/DynamicBoolean"
239
+ },
240
+ "message": {
241
+ "type": "string",
242
+ "description": "The error message to display if the check fails."
243
+ }
244
+ },
245
+ "required": ["condition", "message"],
246
+ "additionalProperties": false
247
+ },
248
+ "Checkable": {
249
+ "description": "Properties for components that support client-side checks.",
250
+ "type": "object",
251
+ "properties": {
252
+ "checks": {
253
+ "type": "array",
254
+ "description": "A list of checks to perform. These are function calls that must return a boolean indicating validity.",
255
+ "items": {
256
+ "$ref": "#/$defs/CheckRule"
257
+ }
258
+ }
259
+ }
260
+ },
261
+ "Action": {
262
+ "description": "Defines an interaction handler that can either trigger a server-side event or execute a local client-side function.",
263
+ "oneOf": [
264
+ {
265
+ "type": "object",
266
+ "description": "Triggers a server-side event.",
267
+ "properties": {
268
+ "event": {
269
+ "type": "object",
270
+ "description": "The event to dispatch to the server.",
271
+ "properties": {
272
+ "name": {
273
+ "type": "string",
274
+ "description": "The name of the action to be dispatched to the server."
275
+ },
276
+ "context": {
277
+ "type": "object",
278
+ "description": "A JSON object containing the key-value pairs for the action context. Values can be literals or paths. Use literal values unless the value must be dynamically bound to the data model. Do NOT use paths for static IDs.",
279
+ "additionalProperties": {
280
+ "$ref": "#/$defs/DynamicValue"
281
+ }
282
+ }
283
+ },
284
+ "required": ["name"],
285
+ "additionalProperties": false
286
+ }
287
+ },
288
+ "required": ["event"],
289
+ "additionalProperties": false
290
+ },
291
+ {
292
+ "type": "object",
293
+ "description": "Executes a local client-side function.",
294
+ "properties": {
295
+ "functionCall": {
296
+ "$ref": "#/$defs/FunctionCall"
297
+ }
298
+ },
299
+ "required": ["functionCall"],
300
+ "additionalProperties": false
301
+ }
302
+ ]
303
+ }
304
+ }
305
+ }
@@ -0,0 +1,132 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://a2ui.org/specification/v0_9/server_to_client.json",
4
+ "title": "A2UI Message Schema",
5
+ "description": "Describes a JSON payload for an A2UI (Agent to UI) message, which is used to dynamically construct and update user interfaces.",
6
+ "type": "object",
7
+ "oneOf": [
8
+ {"$ref": "#/$defs/CreateSurfaceMessage"},
9
+ {"$ref": "#/$defs/UpdateComponentsMessage"},
10
+ {"$ref": "#/$defs/UpdateDataModelMessage"},
11
+ {"$ref": "#/$defs/DeleteSurfaceMessage"}
12
+ ],
13
+ "$defs": {
14
+ "CreateSurfaceMessage": {
15
+ "type": "object",
16
+ "properties": {
17
+ "version": {
18
+ "const": "v0.9"
19
+ },
20
+ "createSurface": {
21
+ "type": "object",
22
+ "description": "Signals the client to create a new surface and begin rendering it. It is an error to send 'createSurface' for a surfaceId that already exists without first deleting it. When this message is sent, the client will expect 'updateComponents' and/or 'updateDataModel' messages for the same surfaceId that define the component tree.",
23
+ "properties": {
24
+ "surfaceId": {
25
+ "type": "string",
26
+ "description": "The unique identifier for the UI surface to be rendered."
27
+ },
28
+ "catalogId": {
29
+ "description": "A string that uniquely identifies this catalog. It is recommended to prefix this with an internet domain that you own, to avoid conflicts e.g. mycompany.com:somecatalog'.",
30
+ "type": "string"
31
+ },
32
+ "theme": {
33
+ "$ref": "catalog.json#/$defs/theme",
34
+ "description": "Theme parameters for the surface (e.g., {'primaryColor': '#FF0000'}). These must validate against the 'theme' schema defined in the catalog."
35
+ },
36
+ "sendDataModel": {
37
+ "type": "boolean",
38
+ "description": "If true, the client will send the full data model of this surface in the metadata of every A2A message sent to the server that created the surface. Defaults to false."
39
+ }
40
+ },
41
+ "required": ["surfaceId", "catalogId"],
42
+ "additionalProperties": false
43
+ }
44
+ },
45
+ "required": ["createSurface", "version"],
46
+ "additionalProperties": false
47
+ },
48
+ "UpdateComponentsMessage": {
49
+ "type": "object",
50
+ "properties": {
51
+ "version": {
52
+ "const": "v0.9"
53
+ },
54
+ "updateComponents": {
55
+ "type": "object",
56
+ "description": "Updates a surface with a new set of components. This message can be sent multiple times to update the component tree of an existing surface. One of the components in one of the components lists MUST have an 'id' of 'root' to serve as the root of the component tree. A createSurface message MUST have been previously sent for the 'surfaceId' in this message; the surface's catalog is the one specified by that createSurface.",
57
+ "properties": {
58
+ "surfaceId": {
59
+ "type": "string",
60
+ "description": "The unique identifier for the UI surface to be updated."
61
+ },
62
+
63
+ "components": {
64
+ "type": "array",
65
+ "description": "A list containing all UI components for the surface.",
66
+ "minItems": 1,
67
+ "items": {
68
+ "$ref": "catalog.json#/$defs/anyComponent"
69
+ }
70
+ }
71
+ },
72
+ "required": ["surfaceId", "components"],
73
+ "additionalProperties": false
74
+ }
75
+ },
76
+ "required": ["updateComponents", "version"],
77
+ "additionalProperties": false
78
+ },
79
+ "UpdateDataModelMessage": {
80
+ "type": "object",
81
+ "properties": {
82
+ "version": {
83
+ "const": "v0.9"
84
+ },
85
+ "updateDataModel": {
86
+ "type": "object",
87
+ "description": "Updates the data model for an existing surface. This message can be sent multiple times to update the data model. A createSurface message MUST have been previously sent for the 'surfaceId' in this message; the surface's catalog is the one specified by that createSurface.",
88
+ "properties": {
89
+ "surfaceId": {
90
+ "type": "string",
91
+ "description": "The unique identifier for the UI surface this data model update applies to."
92
+ },
93
+ "path": {
94
+ "type": "string",
95
+ "description": "An optional path to a location within the data model (e.g., '/user/name'). If omitted, or set to '/', refers to the entire data model."
96
+ },
97
+ "value": {
98
+ "description": "The data to be updated in the data model. If present, the value at 'path' is replaced (or created). If omitted, the key at 'path' is removed.",
99
+ "additionalProperties": true
100
+ }
101
+ },
102
+ "required": ["surfaceId"],
103
+ "additionalProperties": false
104
+ }
105
+ },
106
+ "required": ["updateDataModel", "version"],
107
+ "additionalProperties": false
108
+ },
109
+ "DeleteSurfaceMessage": {
110
+ "type": "object",
111
+ "properties": {
112
+ "version": {
113
+ "const": "v0.9"
114
+ },
115
+ "deleteSurface": {
116
+ "type": "object",
117
+ "description": "Signals the client to delete the surface identified by 'surfaceId'. A createSurface message MUST have been previously sent for the 'surfaceId' in this message; the surface's catalog is the one specified by that createSurface.",
118
+ "properties": {
119
+ "surfaceId": {
120
+ "type": "string",
121
+ "description": "The unique identifier for the UI surface to be deleted."
122
+ }
123
+ },
124
+ "required": ["surfaceId"],
125
+ "additionalProperties": false
126
+ }
127
+ },
128
+ "required": ["deleteSurface", "version"],
129
+ "additionalProperties": false
130
+ }
131
+ }
132
+ }