@ggui-ai/protocol 0.15.0 → 0.16.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 (75) hide show
  1. package/dist/errors/domain-error.d.ts +70 -0
  2. package/dist/errors/domain-error.d.ts.map +1 -0
  3. package/dist/errors/domain-error.js +118 -0
  4. package/dist/gadgets/stdlib-gadgets.d.ts +1 -1
  5. package/dist/gadgets/stdlib-gadgets.js +1 -1
  6. package/dist/index.d.ts +3 -1
  7. package/dist/index.d.ts.map +1 -1
  8. package/dist/index.js +4 -2
  9. package/dist/integrations/mcp-apps.d.ts +33 -7
  10. package/dist/integrations/mcp-apps.d.ts.map +1 -1
  11. package/dist/integrations/mcp-apps.js +13 -13
  12. package/dist/integrations/overlay-hash.d.ts +19 -0
  13. package/dist/integrations/overlay-hash.d.ts.map +1 -0
  14. package/dist/integrations/overlay-hash.js +29 -0
  15. package/dist/integrations/theme-binding.d.ts +14 -12
  16. package/dist/integrations/theme-binding.d.ts.map +1 -1
  17. package/dist/integrations/theme-binding.js +10 -6
  18. package/dist/registry/blueprint-key.d.ts.map +1 -1
  19. package/dist/registry/blueprint-key.js +4 -3
  20. package/dist/schemas/app-theme.d.ts +46 -10
  21. package/dist/schemas/app-theme.d.ts.map +1 -1
  22. package/dist/schemas/app-theme.js +108 -40
  23. package/dist/schemas/blueprint.d.ts +2 -1
  24. package/dist/schemas/blueprint.d.ts.map +1 -1
  25. package/dist/schemas/blueprint.js +15 -3
  26. package/dist/schemas/data-contract.d.ts +1 -1
  27. package/dist/schemas/data-contract.js +1 -1
  28. package/dist/schemas/handshake-suggestion.d.ts.map +1 -1
  29. package/dist/schemas/handshake-suggestion.js +8 -1
  30. package/dist/schemas/mcp.d.ts +48 -22
  31. package/dist/schemas/mcp.d.ts.map +1 -1
  32. package/dist/schemas/mcp.js +44 -15
  33. package/dist/schemas/ops-blueprint.d.ts +4 -4
  34. package/dist/schemas/ops-blueprint.d.ts.map +1 -1
  35. package/dist/schemas/ops-blueprint.js +13 -8
  36. package/dist/schemas/render-input-envelope.js +1 -1
  37. package/dist/types/blueprint-source.d.ts +27 -7
  38. package/dist/types/blueprint-source.d.ts.map +1 -1
  39. package/dist/types/blueprint-source.js +19 -3
  40. package/dist/types/blueprint.d.ts +2 -2
  41. package/dist/types/blueprint.d.ts.map +1 -1
  42. package/dist/types/data-contract.d.ts +3 -3
  43. package/dist/types/domain-error-codes.d.ts +167 -0
  44. package/dist/types/domain-error-codes.d.ts.map +1 -0
  45. package/dist/types/domain-error-codes.js +170 -0
  46. package/dist/types/handshake-suggestion.d.ts +2 -2
  47. package/dist/types/live-channel.d.ts +1 -1
  48. package/dist/types/llm-route.d.ts +59 -2
  49. package/dist/types/llm-route.d.ts.map +1 -1
  50. package/dist/types/llm-route.js +62 -16
  51. package/dist/types/llm.d.ts +22 -2
  52. package/dist/types/llm.d.ts.map +1 -1
  53. package/dist/types/llm.js +29 -2
  54. package/dist/types/mcp.d.ts +31 -39
  55. package/dist/types/mcp.d.ts.map +1 -1
  56. package/dist/types/mcp.js +22 -10
  57. package/dist/types/refusal-codes.d.ts +31 -93
  58. package/dist/types/refusal-codes.d.ts.map +1 -1
  59. package/dist/types/refusal-codes.js +41 -96
  60. package/dist/types/render.d.ts +3 -3
  61. package/dist/types/render.d.ts.map +1 -1
  62. package/dist/validation/contract-validator.d.ts +8 -2
  63. package/dist/validation/contract-validator.d.ts.map +1 -1
  64. package/dist/validation/contract-validator.js +12 -4
  65. package/dist/validation/lint-contract.d.ts +2 -2
  66. package/dist/validation/lint-contract.d.ts.map +1 -1
  67. package/dist/validation/lint-contract.js +6 -4
  68. package/dist/validation/schema-subset.d.ts +3 -3
  69. package/dist/version.d.ts +357 -6
  70. package/dist/version.d.ts.map +1 -1
  71. package/dist/version.js +356 -5
  72. package/package.json +1 -1
  73. package/dist/envelope-adapters.d.ts +0 -12
  74. package/dist/envelope-adapters.d.ts.map +0 -1
  75. package/dist/envelope-adapters.js +0 -30
@@ -10,9 +10,10 @@
10
10
  * 16-character sha256 prefix — matches the existing `blueprintHash`
11
11
  * shape in `cache-trace-sink` and `generation-cache.ts`. Collision
12
12
  * probability for 100s-of-thousands of distinct contract is ~10^-6
13
- * (birthday-bound on 2^64), well below the budget for the OSS
14
- * single-tenant scope. Hosted multi-tenant deployments scope keys
15
- * by appId so the bound is per-tenant, never global.
13
+ * (birthday-bound on 2^64), well below the budget for a single
14
+ * deployment's key space. A deployment that serves many apps scopes
15
+ * keys by `appId`, so the bound holds per app, never across the whole
16
+ * store.
16
17
  */
17
18
  import { createHash } from 'node:crypto';
18
19
  import { canonicalizeContracts } from './canonicalize-contract.js';
@@ -26,23 +26,59 @@ export declare const GGUI_CSS_VAR_KEY_RE: RegExp;
26
26
  * bare regex on its own.
27
27
  */
28
28
  export declare const CSS_VALUE_SAFE_RE: RegExp;
29
+ /**
30
+ * The grammar a per-mode `keyframes` string MUST satisfy (ggui#987 §3.4,
31
+ * follower D). The renderer injects the text verbatim into the card's
32
+ * `<style>` after the variables, so the text is bounded to what that slot
33
+ * is FOR: zero or more `@keyframes <ident> { <frame-selectors> { <declarations> } … }`
34
+ * blocks and nothing else — no other at-rule (`@import`, `@font-face`,
35
+ * `@media`, …), no `<` / `>`, braces balanced and nested exactly one level
36
+ * inside a block. Comments (`/* … *\/`) are stripped before the walk and are
37
+ * therefore allowed, as `cssVariableMap` values allow `url(`; the deny-list
38
+ * on values (`;{}<>@`) cannot apply verbatim here because `;`, `{`, `}` and
39
+ * the one `@` ARE the grammar. Same principal, same slot, one rule.
40
+ */
41
+ export declare const KEYFRAMES_NAME_RE: RegExp;
42
+ export declare function isKeyframesText(text: string): boolean;
29
43
  export declare const appThemeSchema: z.ZodObject<{
30
- mode: z.ZodEnum<{
44
+ mode: z.ZodOptional<z.ZodEnum<{
31
45
  light: "light";
32
46
  dark: "dark";
33
- }>;
34
- cssVariables: z.ZodRecord<z.ZodString, z.ZodString>;
47
+ }>>;
35
48
  name: z.ZodOptional<z.ZodString>;
36
- base: z.ZodOptional<z.ZodObject<{
37
- documentHash: z.ZodString;
49
+ overlayHash: z.ZodString;
50
+ overlays: z.ZodObject<{
38
51
  light: z.ZodRecord<z.ZodString, z.ZodString>;
39
52
  dark: z.ZodRecord<z.ZodString, z.ZodString>;
40
- keyframes: z.ZodOptional<z.ZodObject<{
41
- light: z.ZodOptional<z.ZodString>;
42
- dark: z.ZodOptional<z.ZodString>;
43
- }, z.core.$strict>>;
44
- frameless: z.ZodOptional<z.ZodBoolean>;
53
+ }, z.core.$strict>;
54
+ cssVariables: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
55
+ keyframes: z.ZodOptional<z.ZodObject<{
56
+ light: z.ZodOptional<z.ZodString>;
57
+ dark: z.ZodOptional<z.ZodString>;
45
58
  }, z.core.$strict>>;
59
+ frameless: z.ZodOptional<z.ZodBoolean>;
46
60
  }, z.core.$strict>;
47
61
  export type AppTheme = z.infer<typeof appThemeSchema>;
62
+ /**
63
+ * The ONE refusal body every write door returns for an overlay it will not
64
+ * store (ggui#987 §3.4): REST 422 `invalid_app_config`, the AppSync
65
+ * `errorInfo`, the MCP ops door's `{ ok: false }` structured content. A
66
+ * discriminated union by key — exactly one of the four.
67
+ */
68
+ export declare const appThemeRefusalBodySchema: z.ZodUnion<readonly [z.ZodObject<{
69
+ uncovered: z.ZodObject<{
70
+ light: z.ZodArray<z.ZodString>;
71
+ dark: z.ZodArray<z.ZodString>;
72
+ }, z.core.$strict>;
73
+ }, z.core.$strict>, z.ZodObject<{
74
+ unknown: z.ZodObject<{
75
+ light: z.ZodArray<z.ZodString>;
76
+ dark: z.ZodArray<z.ZodString>;
77
+ }, z.core.$strict>;
78
+ }, z.core.$strict>, z.ZodObject<{
79
+ overlayHash: z.ZodLiteral<"mismatch">;
80
+ }, z.core.$strict>, z.ZodObject<{
81
+ refused: z.ZodLiteral<"v1 shape">;
82
+ }, z.core.$strict>]>;
83
+ export type AppThemeRefusalBody = z.infer<typeof appThemeRefusalBodySchema>;
48
84
  //# sourceMappingURL=app-theme.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"app-theme.d.ts","sourceRoot":"","sources":["../../src/schemas/app-theme.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;;;GAUG;AACH,eAAO,MAAM,mBAAmB,QAA2B,CAAC;AAE5D;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,iBAAiB,QAAiB,CAAC;AAahD,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;kBAkDhB,CAAC;AAEZ,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC"}
1
+ {"version":3,"file":"app-theme.d.ts","sourceRoot":"","sources":["../../src/schemas/app-theme.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;;;GAUG;AACH,eAAO,MAAM,mBAAmB,QAA2B,CAAC;AAE5D;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,iBAAiB,QAAiB,CAAC;AAahD;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,iBAAiB,QAA+B,CAAC;AAE9D,wBAAgB,eAAe,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAoCrD;AAQD,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;kBAuChB,CAAC;AAEZ,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAEtD;;;;;GAKG;AACH,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;oBAKpC,CAAC;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAC"}
@@ -35,54 +35,122 @@ const cssValue = z
35
35
  const cssVariableMap = z
36
36
  .record(z.string().regex(GGUI_CSS_VAR_KEY_RE, 'css var key must be --ggui-*'), cssValue)
37
37
  .refine((m) => Object.keys(m).length <= 200, 'too many css variables (max 200)');
38
+ /**
39
+ * The grammar a per-mode `keyframes` string MUST satisfy (ggui#987 §3.4,
40
+ * follower D). The renderer injects the text verbatim into the card's
41
+ * `<style>` after the variables, so the text is bounded to what that slot
42
+ * is FOR: zero or more `@keyframes <ident> { <frame-selectors> { <declarations> } … }`
43
+ * blocks and nothing else — no other at-rule (`@import`, `@font-face`,
44
+ * `@media`, …), no `<` / `>`, braces balanced and nested exactly one level
45
+ * inside a block. Comments (`/* … *\/`) are stripped before the walk and are
46
+ * therefore allowed, as `cssVariableMap` values allow `url(`; the deny-list
47
+ * on values (`;{}<>@`) cannot apply verbatim here because `;`, `{`, `}` and
48
+ * the one `@` ARE the grammar. Same principal, same slot, one rule.
49
+ */
50
+ export const KEYFRAMES_NAME_RE = /^[A-Za-z_-][A-Za-z0-9_-]*$/;
51
+ export function isKeyframesText(text) {
52
+ const s = text.replace(/\/\*[\s\S]*?\*\//g, ' ');
53
+ if (/[<>]/.test(s))
54
+ return false;
55
+ let i = 0;
56
+ const n = s.length;
57
+ const skipWs = () => {
58
+ while (i < n && /\s/.test(s[i]))
59
+ i += 1;
60
+ };
61
+ for (;;) {
62
+ skipWs();
63
+ if (i >= n)
64
+ return true;
65
+ if (!s.startsWith('@keyframes', i))
66
+ return false;
67
+ i += '@keyframes'.length;
68
+ if (i >= n || !/\s/.test(s[i]))
69
+ return false;
70
+ skipWs();
71
+ const nameStart = i;
72
+ while (i < n && /[A-Za-z0-9_-]/.test(s[i]))
73
+ i += 1;
74
+ if (!KEYFRAMES_NAME_RE.test(s.slice(nameStart, i)))
75
+ return false;
76
+ skipWs();
77
+ if (s[i] !== '{')
78
+ return false;
79
+ i += 1;
80
+ // Inside the block: frame rules only — `selectors { declarations }` at depth 1, no `@`.
81
+ let depth = 1;
82
+ while (i < n && depth > 0) {
83
+ const ch = s[i];
84
+ if (ch === '@')
85
+ return false;
86
+ if (ch === '{') {
87
+ depth += 1;
88
+ if (depth > 2)
89
+ return false;
90
+ }
91
+ else if (ch === '}') {
92
+ depth -= 1;
93
+ }
94
+ i += 1;
95
+ }
96
+ if (depth !== 0)
97
+ return false;
98
+ }
99
+ }
100
+ /** A per-mode keyframes string: `@keyframes` blocks only (see {@link isKeyframesText}), 8 KiB cap unchanged. */
101
+ const keyframesText = z
102
+ .string()
103
+ .max(8192)
104
+ .refine(isKeyframesText, 'keyframes must be `@keyframes <name> { … }` blocks and nothing else');
38
105
  export const appThemeSchema = z
39
106
  .object({
40
- mode: z.enum(['light', 'dark']),
41
- cssVariables: cssVariableMap,
107
+ /**
108
+ * Default appearance: the mode painted when NO embedding host announces
109
+ * one. Never a pin — the host owns runtime mode (ggui#987 D4; see
110
+ * `integrations/theme-binding.ts`). Absent ⇒ mode-neutral.
111
+ */
112
+ mode: z.enum(['light', 'dark']).optional(),
113
+ /** A label the author's tooling reads back. Never resolved by a renderer. */
42
114
  name: z.string().min(1).max(64).optional(),
43
115
  /**
44
- * The REGISTERED base ladder, delivered (runtime theme
45
- * registration): both modes' resolved variable sets ride the
46
- * envelope so a mid-session mode switch is a local operation and
47
- * delivery never depends on the iframe being able to fetch. The
48
- * renderer injects the mode-selected set BELOW `cssVariables` (the
49
- * per-app overlay) in the documented precedence. `documentHash` is
50
- * the registration's identity: it joins painted ladders to
51
- * registration records, and a receiver holding the hash may be
52
- * served a future envelope without the variable sets.
116
+ * Delivery attestation: `canonicalOverlayHash({ overlays, cssVariables,
117
+ * keyframes })` (`integrations/overlay-hash.ts`). Every write door
118
+ * recomputes it and refuses a mismatch; read doors pass it through.
53
119
  */
54
- base: z
120
+ overlayHash: z.string().regex(/^[0-9a-f]{64}$/, 'overlayHash must be sha256 lowercase hex'),
121
+ /**
122
+ * The projection, both modes — the derived `--ggui-*` sets a card
123
+ * injects for the effective mode (ggui#987 §2.4: produced by ONE
124
+ * function on every path). REQUIRED, both: an overlay that could not
125
+ * follow the host's mode is not accepted.
126
+ */
127
+ overlays: z.object({ light: cssVariableMap, dark: cssVariableMap }).strict(),
128
+ /** Mode-agnostic per-app overrides, injected above both projections. */
129
+ cssVariables: cssVariableMap.optional(),
130
+ /** Per-mode `@keyframes` blocks, injected verbatim after the variables — bounded to that grammar by {@link isKeyframesText}. */
131
+ keyframes: z
55
132
  .object({
56
- documentHash: z
57
- .string()
58
- .regex(/^[0-9a-f]{64}$/, 'documentHash must be sha256 lowercase hex'),
59
- light: cssVariableMap,
60
- dark: cssVariableMap,
61
- /**
62
- * Per-mode `@keyframes` blocks from the registration document
63
- * (ggui#613 residual 2). A mode key is absent when its
64
- * document declares no motion keyframes; the whole field is
65
- * absent on pre-#613 registrations (additive optional — old
66
- * bases stay valid). Injected verbatim after the variable
67
- * ladder, same position the compiled path gives
68
- * `theme.cssKeyframes`.
69
- */
70
- keyframes: z
71
- .object({
72
- light: z.string().max(8192).optional(),
73
- dark: z.string().max(8192).optional(),
74
- })
75
- .strict()
76
- .optional(),
77
- /**
78
- * `$metadata.frameless` delivered (OR of both modes): the
79
- * embedding host owns the card silhouette, so the renderer
80
- * appends the root-children border-suppression rule — the
81
- * SAME rule the compiled path emits.
82
- */
83
- frameless: z.boolean().optional(),
133
+ light: keyframesText.optional(),
134
+ dark: keyframesText.optional(),
84
135
  })
85
136
  .strict()
86
137
  .optional(),
138
+ /**
139
+ * The embedding host owns the card silhouette: the renderer appends the
140
+ * root-children border-suppression rule.
141
+ */
142
+ frameless: z.boolean().optional(),
87
143
  })
88
144
  .strict();
145
+ /**
146
+ * The ONE refusal body every write door returns for an overlay it will not
147
+ * store (ggui#987 §3.4): REST 422 `invalid_app_config`, the AppSync
148
+ * `errorInfo`, the MCP ops door's `{ ok: false }` structured content. A
149
+ * discriminated union by key — exactly one of the four.
150
+ */
151
+ export const appThemeRefusalBodySchema = z.union([
152
+ z.object({ uncovered: z.object({ light: z.array(z.string()), dark: z.array(z.string()) }).strict() }).strict(),
153
+ z.object({ unknown: z.object({ light: z.array(z.string()), dark: z.array(z.string()) }).strict() }).strict(),
154
+ z.object({ overlayHash: z.literal('mismatch') }).strict(),
155
+ z.object({ refused: z.literal('v1 shape') }).strict(),
156
+ ]);
@@ -11,7 +11,8 @@ import type { BlueprintSource, CuratedBlueprintSource, LlmBlueprintSource, UserB
11
11
  * Zod mirror of {@link LlmBlueprintSource} — the engine-generated arm.
12
12
  * Both provenance fields are REQUIRED: every generation mint site has
13
13
  * them in scope, and an engine-generated artifact that cannot name its
14
- * engine + model is not a real state.
14
+ * engine + model is not a real state. Since ggui#924 the identity is
15
+ * de-modeled (`ui-gen-<tier>`) and the model is the run's `ModelRef`.
15
16
  */
16
17
  export declare const llmBlueprintSourceSchema: z.ZodType<LlmBlueprintSource>;
17
18
  /** Zod mirror of {@link UserBlueprintSource} — no engine claim exists. */
@@ -1 +1 @@
1
- {"version":3,"file":"blueprint.d.ts","sourceRoot":"","sources":["../../src/schemas/blueprint.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,KAAK,EACV,wBAAwB,EACxB,SAAS,EACT,iBAAiB,EAClB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EACV,eAAe,EACf,sBAAsB,EACtB,kBAAkB,EAClB,mBAAmB,EACpB,MAAM,2BAA2B,CAAC;AAGnC;;;;;GAKG;AACH,eAAO,MAAM,wBAAwB,EAAE,CAAC,CAAC,OAAO,CAAC,kBAAkB,CAMvB,CAAC;AAE7C,0EAA0E;AAC1E,eAAO,MAAM,yBAAyB,EAAE,CAAC,CAAC,OAAO,CAAC,mBAAmB,CAExB,CAAC;AAE9C,oDAAoD;AACpD,eAAO,MAAM,4BAA4B,EAAE,CAAC,CAAC,OAAO,CAAC,sBAAsB,CAE3B,CAAC;AAEjD;;;;;GAKG;AACH,eAAO,MAAM,qBAAqB,EAAE,CAAC,CAAC,OAAO,CAAC,eAAe,CAI7B,CAAC;AAEjC;;;;;;;;;GASG;AACH,sF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CAAC,SAAS,CAwBd,CAAC;AAmBpC;;;GAGG;AACH,eAAO,MAAM,8BAA8B,EAAE,CAAC,CAAC,OAAO,CAAC,wBAAwB,CAM7B,CAAC"}
@@ -5,18 +5,30 @@
5
5
  * here is `z.ZodType<Blueprint>` so any drift fails compile.
6
6
  */
7
7
  import { z } from 'zod';
8
+ import { isGeneratorId } from '../types/blueprint-source.js';
9
+ import { MODEL_REF_PREFIXES, isModelRef } from '../types/llm-route.js';
8
10
  import { dataContractSchema, jsonValueSchema } from './data-contract.js';
9
11
  /**
10
12
  * Zod mirror of {@link LlmBlueprintSource} — the engine-generated arm.
11
13
  * Both provenance fields are REQUIRED: every generation mint site has
12
14
  * them in scope, and an engine-generated artifact that cannot name its
13
- * engine + model is not a real state.
15
+ * engine + model is not a real state. Since ggui#924 the identity is
16
+ * de-modeled (`ui-gen-<tier>`) and the model is the run's `ModelRef`.
14
17
  */
15
18
  export const llmBlueprintSourceSchema = z
16
19
  .object({
17
20
  kind: z.literal('llm'),
18
- generator: z.string().min(1),
19
- model: z.string().min(1),
21
+ // ggui#924: the de-modeled identity and the run's `ModelRef` — a
22
+ // modeled id, a bare model name or a second spelling is refused here,
23
+ // naming the field. Template literals (not `z.custom`) so the fields
24
+ // keep their literal types AND render to JSON Schema as `pattern` —
25
+ // this schema is embedded in tool inputs that `tools/list` renders.
26
+ generator: z.templateLiteral(['ui-gen-', z.string()]).refine(isGeneratorId, {
27
+ error: 'generator is the de-modeled identity `ui-gen-<tier>` — one tier token, no model segment (e.g. `ui-gen-default`)',
28
+ }),
29
+ model: z.templateLiteral([z.enum(MODEL_REF_PREFIXES), '/', z.string()]).refine(isModelRef, {
30
+ error: 'model is the run route in the registry spelling `<prefix>/<model>` (e.g. `anthropic/claude-haiku-4-5`)',
31
+ }),
20
32
  })
21
33
  .strict();
22
34
  /** Zod mirror of {@link UserBlueprintSource} — no engine claim exists. */
@@ -7,7 +7,7 @@
7
7
  * Output-side seams that type-narrow contract on the wire —
8
8
  * `renderOutputSchema.contract` and the various `decision` echoes — use
9
9
  * `z.custom<DataContract>()` because they trust the shape (it
10
- * originates from internal pod state).
10
+ * originates from internal server state).
11
11
  *
12
12
  * The input seam is different: agents author contract on
13
13
  * `story.contract` and the handler MUST plumb them to the generator.
@@ -7,7 +7,7 @@
7
7
  * Output-side seams that type-narrow contract on the wire —
8
8
  * `renderOutputSchema.contract` and the various `decision` echoes — use
9
9
  * `z.custom<DataContract>()` because they trust the shape (it
10
- * originates from internal pod state).
10
+ * originates from internal server state).
11
11
  *
12
12
  * The input seam is different: agents author contract on
13
13
  * `story.contract` and the handler MUST plumb them to the generator.
@@ -1 +1 @@
1
- {"version":3,"file":"handshake-suggestion.d.ts","sourceRoot":"","sources":["../../src/schemas/handshake-suggestion.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,KAAK,EACV,cAAc,EACd,aAAa,EACb,mBAAmB,EACnB,SAAS,EACT,WAAW,EACX,oBAAoB,EACpB,iBAAiB,EACjB,gBAAgB,EACjB,MAAM,kCAAkC,CAAC;AAI1C,qEAAqE;AACrE,eAAO,MAAM,sBAAsB,EAAE,CAAC,CAAC,OAAO,CAAC,gBAAgB,CAI7D,CAAC;AAEH,mEAAmE;AACnE,eAAO,MAAM,iBAAiB,EAAE,CAAC,CAAC,OAAO,CAAC,WAAW,CAezB,CAAC;AAE7B,8DAA8D;AAC9D,eAAO,MAAM,eAAe,EAAE,CAAC,CAAC,OAAO,CAAC,SAAS,CAAsD,CAAC;AAExG;;;;;GAKG;AACH,oFAAoF;AACpF,eAAO,MAAM,oBAAoB,gDAAiD,CAAC;AAEnF,eAAO,MAAM,0BAA0B;;;;kBAkB5B,CAAC;AAEZ,uDAAuD;AACvD,eAAO,MAAM,oBAAoB,EAAE,CAAC,CAAC,OAAO,CAAC,cAAc,CAA2D,CAAC;AAEvH,+DAA+D;AAC/D,eAAO,MAAM,mBAAmB,EA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AAM,uBAAuB,EAAE,CAAC,CAAC,OAAO,CAAC,iBAAiB,CAOtB,CAAC;AAE5C,qDAAqD;AACrD,eAAO,MAAM,0BAA0B,EAAE,CAAC,CAAC,OAAO,CAAC,oBAAoB,CAKzB,CAAC;AAE/C,2EAA2E;AAC3E,eAAO,MAAM,yBAAyB,EAAE,CAAC,CAAC,OAAO,CAAC,mBAAmB,CASxB,CAAC"}
@@ -8,6 +8,7 @@
8
8
  * `z.ZodType<T>` so any drift fails compile.
9
9
  */
10
10
  import { z } from 'zod';
11
+ import { GENERATOR_ID_PATTERN } from '../types/blueprint-source.js';
11
12
  import { dataContractSchema, jsonValueSchema } from './data-contract.js';
12
13
  import { blueprintSourceSchema, blueprintVarianceSchema } from './blueprint.js';
13
14
  /** Three-mode routing enum on {@link HandshakeSuggestion.origin}. */
@@ -51,7 +52,13 @@ export const blueprintDraftObjectSchema = z
51
52
  // rejection message) that `blueprintMeta.variance` projects on the
52
53
  // way back out (ggui#523 item 1 — the mirror-of-a-mirror is gone).
53
54
  variance: blueprintVarianceSchema.optional(),
54
- generator: z.string().optional(),
55
+ generator: z
56
+ .string()
57
+ .regex(GENERATOR_ID_PATTERN, {
58
+ error: 'generator is an identity `ui-gen-<tier>` — one tier token, no model segment (ggui#924)',
59
+ })
60
+ .optional()
61
+ .describe('Generator identity hint — `ui-gen-default` or `ui-gen-advanced` (one tier token, no model segment). The deployment picks the model and reports it on `source.model`.'),
55
62
  }, {
56
63
  error: (issue) => issue.code === 'unrecognized_keys'
57
64
  ? `blueprintDraft: unknown key(s) ${issue.keys.map((k) => JSON.stringify(k)).join(', ')} — a draft is EXACTLY {${BLUEPRINT_DRAFT_KEYS.join(', ')}}; \`intent\` is a top-level ggui_handshake field, not a draft field, and the four specs live INSIDE \`contract\``
@@ -7,7 +7,7 @@
7
7
  * Two consumption patterns, both anchored here:
8
8
  *
9
9
  * - **Wired raw shapes** (`*InputShape`): handlers in
10
- * `@ggui-ai/mcp-server-handlers` (and the hosted pod's discover
10
+ * `@ggui-ai/mcp-server-handlers` (and a hosted deployment's discover
11
11
  * tool) import the SHAPE directly as their `inputSchema` and
12
12
  * validate with `z.object(shape)` — unknown keys are STRIPPED.
13
13
  * The shape is the one authored copy of the validation rules AND
@@ -396,13 +396,10 @@ export declare const renderRefusalSchema: z.ZodObject<{
396
396
  unsupported_provider: "unsupported_provider";
397
397
  insufficient_credit: "insufficient_credit";
398
398
  hard_cap_exceeded: "hard_cap_exceeded";
399
- model_not_in_tier: "model_not_in_tier";
399
+ model_not_allowed: "model_not_allowed";
400
400
  managed_default_cap_exceeded: "managed_default_cap_exceeded";
401
401
  app_policy_missing: "app_policy_missing";
402
402
  billing_mode_anomaly: "billing_mode_anomaly";
403
- app_canceled: "app_canceled";
404
- trial_exhausted: "trial_exhausted";
405
- trial_expired: "trial_expired";
406
403
  issuer_rate_limited: "issuer_rate_limited";
407
404
  app_rate_limited: "app_rate_limited";
408
405
  app_deprovisioned: "app_deprovisioned";
@@ -419,9 +416,16 @@ export type PreGenerationRefusal = z.infer<typeof renderRefusalSchema>;
419
416
  * from {@link MCP_ENDPOINT_REFUSAL_CODES} — today exactly
420
417
  * `app_deprovisioned`, the one refusal with a tenant-side fix and
421
418
  * therefore the one that MUST be legible where a deleted app and a bad
422
- * credential would otherwise look alike.
419
+ * credential would otherwise look alike. `appId` (ggui#870) is the app
420
+ * the refused endpoint serves, as DATA — equal to the path's `{appId}`
421
+ * — so a tenant's repair loop keys on it and never parses prose; it is
422
+ * the ggui id the bound caller already holds, never the tenant's own
423
+ * `ownerRef`. The typed refusal answers a correctly bound federated
424
+ * identity only (identity first): an anonymous request is refused by the
425
+ * auth adapter before this arm, and learns nothing about the app.
423
426
  */
424
427
  export declare const transportRefusalSchema: z.ZodObject<{
428
+ appId: z.ZodString;
425
429
  message: z.ZodString;
426
430
  fix: z.ZodString;
427
431
  retry: z.ZodEnum<{
@@ -444,7 +448,7 @@ export type TransportRefusal = z.infer<typeof transportRefusalSchema>;
444
448
  * proxy 403) and `message` `App not found`, plus `data.refusal`, which
445
449
  * makes it legible. `data` is strict: it carries the refusal and nothing
446
450
  * else. An authorization failure that is not a registry state answers
447
- * HTTP 403 with `-32001` (`UNAUTHORIZED`) and NO `data` — the three
451
+ * HTTP 403 with `-32007` (`UNAUTHORIZED`) and NO `data` — the three
448
452
  * untyped arms stay indistinguishable among themselves by contract:
449
453
  * naming any of them would say which is true. A first-party server
450
454
  * never chooses `-32000`: it is the SDK client's `ConnectionClosed`, so
@@ -455,6 +459,7 @@ export declare const transportRefusalErrorSchema: z.ZodObject<{
455
459
  message: z.ZodLiteral<"App not found">;
456
460
  data: z.ZodObject<{
457
461
  refusal: z.ZodObject<{
462
+ appId: z.ZodString;
458
463
  message: z.ZodString;
459
464
  fix: z.ZodString;
460
465
  retry: z.ZodEnum<{
@@ -507,13 +512,10 @@ export declare const refusedOutputSchema: z.ZodObject<{
507
512
  unsupported_provider: "unsupported_provider";
508
513
  insufficient_credit: "insufficient_credit";
509
514
  hard_cap_exceeded: "hard_cap_exceeded";
510
- model_not_in_tier: "model_not_in_tier";
515
+ model_not_allowed: "model_not_allowed";
511
516
  managed_default_cap_exceeded: "managed_default_cap_exceeded";
512
517
  app_policy_missing: "app_policy_missing";
513
518
  billing_mode_anomaly: "billing_mode_anomaly";
514
- app_canceled: "app_canceled";
515
- trial_exhausted: "trial_exhausted";
516
- trial_expired: "trial_expired";
517
519
  issuer_rate_limited: "issuer_rate_limited";
518
520
  app_rate_limited: "app_rate_limited";
519
521
  app_deprovisioned: "app_deprovisioned";
@@ -673,13 +675,10 @@ export declare const renderOutputSchema: z.ZodObject<{
673
675
  unsupported_provider: "unsupported_provider";
674
676
  insufficient_credit: "insufficient_credit";
675
677
  hard_cap_exceeded: "hard_cap_exceeded";
676
- model_not_in_tier: "model_not_in_tier";
678
+ model_not_allowed: "model_not_allowed";
677
679
  managed_default_cap_exceeded: "managed_default_cap_exceeded";
678
680
  app_policy_missing: "app_policy_missing";
679
681
  billing_mode_anomaly: "billing_mode_anomaly";
680
- app_canceled: "app_canceled";
681
- trial_exhausted: "trial_exhausted";
682
- trial_expired: "trial_expired";
683
682
  issuer_rate_limited: "issuer_rate_limited";
684
683
  app_rate_limited: "app_rate_limited";
685
684
  app_deprovisioned: "app_deprovisioned";
@@ -711,7 +710,7 @@ export declare const renderOutputSchema: z.ZodObject<{
711
710
  * wise). Use when most props stay the same and the agent only
712
711
  * needs to send a small delta — common after a single domain-tool
713
712
  * mutation. RFC 7396 chosen because it has a published spec and
714
- * wide library support (GitHub API, Kubernetes strategic-merge).
713
+ * wide library support (GitHub API's merge semantics, strategic-merge-patch).
715
714
  *
716
715
  * Anti-patterns (the discriminated union rejects these structurally,
717
716
  * but they're a common author mistake when copy-pasting):
@@ -724,7 +723,7 @@ export declare const renderOutputSchema: z.ZodObject<{
724
723
  * partial patches that would break required fields, type-mismatch
725
724
  * values, etc. all reject pre-persist.
726
725
  *
727
- * `sessionId` is globally unique; the server tenancy-checks via
726
+ * `sessionId` is globally unique; the server checks the app scope via
728
727
  * `ctx.appId`.
729
728
  */
730
729
  export declare const updateInputSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -890,9 +889,9 @@ export declare const gguiSessionEventSchema: z.ZodObject<{
890
889
  * OPTIONAL here (the bridge rung owns its cursor and seeds from 0; the
891
890
  * route requires it because a bare browser GET has no cursor owner),
892
891
  * and `limit` is clamped to {@link RUNTIME_PULL_MAX_LIMIT} instead of
893
- * rejecting above it. Tenancy violations and unknown sessionIds
892
+ * rejecting above it. Cross-app access and unknown sessionIds
894
893
  * surface uniformly as the `session_not_found` error — existence of
895
- * other tenants' renders is never leaked.
894
+ * other apps' renders is never leaked.
896
895
  */
897
896
  export declare const runtimePullInputShape: {
898
897
  readonly sessionId: z.ZodString;
@@ -1119,9 +1118,9 @@ export declare const gguiSessionStatusSchema: z.ZodEnum<{
1119
1118
  /**
1120
1119
  * One drained row of `ggui_consume` — a user action that reached the
1121
1120
  * pipe (ggui#817 part C2). Closed on the wire: an unknown key is
1122
- * stripped at the transport, a missing key refuses the row at the seam
1123
- * (`parsePendingEnvelope`), so a malformed pipe entry never ships to an
1124
- * agent typed as a good one.
1121
+ * stripped at the transport, a missing key refuses the row at the store
1122
+ * boundary (`pendingEventSchema`, ggui#839), so a malformed pipe entry
1123
+ * never ships to an agent typed as a good one.
1125
1124
  */
1126
1125
  export declare const consumeEventEntrySchema: z.ZodObject<{
1127
1126
  type: z.ZodLiteral<"action">;
@@ -1132,6 +1131,33 @@ export declare const consumeEventEntrySchema: z.ZodObject<{
1132
1131
  actionId: z.ZodString;
1133
1132
  firedAt: z.ZodString;
1134
1133
  }, z.core.$strip>;
1134
+ /**
1135
+ * One stored row of the consume pipe — what a producer appends and
1136
+ * `consumeAndClear` drains, the same shape on every store (ggui#839; a
1137
+ * store-boundary contract, never wire — `ggui_consume` returns the
1138
+ * entries, never the wrapper). `id` is the drain_ack key and the
1139
+ * idempotency key per `(sessionId, id)`; `envelope` is the
1140
+ * {@link consumeEventEntrySchema} entry, always the object (every writer
1141
+ * passes one; a store that serializes the row serializes the whole row);
1142
+ * `createdAt` is when the row was appended — a string, never `.datetime()`:
1143
+ * the relay copies the client's `firedAt`, which the ingress accepts as a
1144
+ * diagnostic. `PendingEventConsumer` adapters validate every row through
1145
+ * this schema on append and, when rows come back from a serialization, on
1146
+ * drain — a malformed row never reaches an agent typed as a good entry.
1147
+ */
1148
+ export declare const pendingEventSchema: z.ZodObject<{
1149
+ id: z.ZodString;
1150
+ envelope: z.ZodObject<{
1151
+ type: z.ZodLiteral<"action">;
1152
+ sessionId: z.ZodString;
1153
+ intent: z.ZodString;
1154
+ actionData: z.ZodNullable<z.ZodType<import("../index.js").JsonValue, unknown, z.core.$ZodTypeInternals<import("../index.js").JsonValue, unknown>>>;
1155
+ uiContext: z.ZodType<import("../index.js").JsonObject, unknown, z.core.$ZodTypeInternals<import("../index.js").JsonObject, unknown>>;
1156
+ actionId: z.ZodString;
1157
+ firedAt: z.ZodString;
1158
+ }, z.core.$strip>;
1159
+ createdAt: z.ZodString;
1160
+ }, z.core.$strip>;
1135
1161
  /**
1136
1162
  * `ggui_consume`'s output — the drained rows, the session's state, and the
1137
1163
  * client's observations when the host sent any (ggui#817 part C2). The
@@ -1 +1 @@
1
- {"version":3,"file":"mcp.d.ts","sourceRoot":"","sources":["../../src/schemas/mcp.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAyBxB;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB;;;CAgBpB,CAAC;AAEX,eAAO,MAAM,kBAAkB;;;iBAA8B,CAAC;AAE9D;;;GAGG;AACH,eAAO,MAAM,cAAc;;;;;CAKjB,CAAC;AAEX,eAAO,MAAM,eAAe;;;;;iBAA2B,CAAC;AAExD,eAAO,MAAM,oBAAoB;;CAKvB,CAAC;AAEX,eAAO,MAAM,qBAAqB;;iBAAiC,CAAC;AAEpE;;;;;;GAMG;AACH,eAAO,MAAM,yBAAyB;;CAK5B,CAAC;AAEX,eAAO,MAAM,0BAA0B;;iBAAsC,CAAC;AAE9E;;;;;GAKG;AACH,eAAO,MAAM,gCAAgC,IAAc,CAAC;AAE5D,eAAO,MAAM,iCAAiC,gCAE7C,CAAC;AAEF,eAAO,MAAM,0BAA0B;;;;;CAwB7B,CAAC;AAEX,eAAO,MAAM,2BAA2B;;;;;iBAAuC,CAAC;AAEhF,eAAO,MAAM,yBAAyB;;CAO5B,CAAC;AAEX,eAAO,MAAM,0BAA0B;;iBAAsC,CAAC;AAE9E,eAAO,MAAM,kBAAkB,IAAc,CAAC;AAE9C,eAAO,MAAM,mBAAmB,gCAA+B,CAAC;AAahE;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,eAAO,MAAM,oBAAoB;;;;kBA0BtB,CAAC;AAEZ;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,eAAO,MAAM,qBAAqB;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