@noodleseed/one 0.174.0 → 0.175.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 (164) hide show
  1. package/dist/commands/solutions-activity.js +1 -1
  2. package/dist/commands/solutions-activity.js.map +1 -1
  3. package/dist/commands/solutions-drafts.d.ts.map +1 -1
  4. package/dist/commands/solutions-drafts.js +36 -9
  5. package/dist/commands/solutions-drafts.js.map +1 -1
  6. package/dist/commands/solutions-native-lifecycle.d.ts +5 -0
  7. package/dist/commands/solutions-native-lifecycle.d.ts.map +1 -0
  8. package/dist/commands/solutions-native-lifecycle.js +77 -0
  9. package/dist/commands/solutions-native-lifecycle.js.map +1 -0
  10. package/dist/commands/solutions-ops.d.ts.map +1 -1
  11. package/dist/commands/solutions-ops.js +3 -0
  12. package/dist/commands/solutions-ops.js.map +1 -1
  13. package/dist/commands/solutions-workspace.d.ts.map +1 -1
  14. package/dist/commands/solutions-workspace.js +36 -11
  15. package/dist/commands/solutions-workspace.js.map +1 -1
  16. package/dist/commands/whatsapp-output.d.ts.map +1 -1
  17. package/dist/commands/whatsapp-output.js +20 -4
  18. package/dist/commands/whatsapp-output.js.map +1 -1
  19. package/node_modules/@noodle-borg/admission-limits/dist/public-record-admission.d.ts +16 -9
  20. package/node_modules/@noodle-borg/admission-limits/dist/public-record-admission.js +5 -2
  21. package/node_modules/@noodle-borg/agent-kit/dist/curated/error-fixes.js +9 -0
  22. package/node_modules/@noodle-borg/agent-kit/dist/generated/example-files.js +5 -5
  23. package/node_modules/@noodle-borg/agent-kit/dist/generated/surface.js +9 -0
  24. package/node_modules/@noodle-borg/agent-kit/dist/skill-authoring-refs.js +1 -1
  25. package/node_modules/@noodle-borg/agent-kit/dist/skill-embedded-assistant-ref.js +13 -1
  26. package/node_modules/@noodle-borg/agent-kit/package.json +1 -1
  27. package/node_modules/@noodle-borg/assistant-gateway/dist/channel-coordinator.d.ts +5 -3
  28. package/node_modules/@noodle-borg/assistant-gateway/dist/channel-coordinator.js +5 -4
  29. package/node_modules/@noodle-borg/assistant-gateway/dist/channel-inbox.js +6 -2
  30. package/node_modules/@noodle-borg/assistant-gateway/dist/channel-store.d.ts +1 -1
  31. package/node_modules/@noodle-borg/assistant-gateway/dist/channel-types.d.ts +12 -0
  32. package/node_modules/@noodle-borg/assistant-gateway/dist/channel-work.d.ts +7 -2
  33. package/node_modules/@noodle-borg/assistant-gateway/dist/channel-work.js +14 -4
  34. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-capture.js +104 -0
  35. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-judgment.js +93 -0
  36. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-ledger.d.ts +105 -0
  37. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-ledger.js +183 -0
  38. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-model-call.js +38 -0
  39. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-parsers.d.ts +22 -0
  40. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-parsers.js +109 -0
  41. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-review.d.ts +21 -0
  42. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-review.js +44 -0
  43. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-spec.d.ts +18 -0
  44. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-spec.js +86 -0
  45. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-store.d.ts +11 -0
  46. package/node_modules/@noodle-borg/assistant-gateway/dist/collection-store.js +18 -0
  47. package/node_modules/@noodle-borg/assistant-gateway/dist/messaging-tool-dispatch.d.ts +20 -1
  48. package/node_modules/@noodle-borg/assistant-gateway/dist/messaging-tool-dispatch.js +38 -2
  49. package/node_modules/@noodle-borg/assistant-gateway/dist/model-runtime.js +3 -0
  50. package/node_modules/@noodle-borg/assistant-gateway/dist/portable.d.ts +5 -0
  51. package/node_modules/@noodle-borg/assistant-gateway/dist/portable.js +5 -0
  52. package/node_modules/@noodle-borg/assistant-gateway/package.json +1 -1
  53. package/node_modules/@noodle-borg/authoring/dist/index.d.ts +1 -0
  54. package/node_modules/@noodle-borg/authoring/dist/interaction.d.ts +49 -0
  55. package/node_modules/@noodle-borg/authoring/dist/interaction.js +25 -0
  56. package/node_modules/@noodle-borg/authoring/dist/server.d.ts +3 -0
  57. package/node_modules/@noodle-borg/authoring/dist/server.js +4 -0
  58. package/node_modules/@noodle-borg/authoring/package.json +6 -1
  59. package/node_modules/@noodle-borg/cli-catalog/dist/catalog-data-channels.js +1 -1
  60. package/node_modules/@noodle-borg/cli-catalog/dist/catalog-data-solution-drafts.js +7 -0
  61. package/node_modules/@noodle-borg/cli-catalog/dist/catalog-data-solution-native-lifecycle.js +43 -0
  62. package/node_modules/@noodle-borg/cli-catalog/dist/catalog-data-solution-records.js +154 -0
  63. package/node_modules/@noodle-borg/cli-catalog/dist/catalog-data-solution-workspace.js +8 -1
  64. package/node_modules/@noodle-borg/cli-catalog/dist/catalog-data-solutions.js +2 -149
  65. package/node_modules/@noodle-borg/compiler/dist/artifact/assemble.js +2 -1
  66. package/node_modules/@noodle-borg/compiler/dist/artifact/types.d.ts +33 -0
  67. package/node_modules/@noodle-borg/compiler/dist/artifact/version.d.ts +2 -1
  68. package/node_modules/@noodle-borg/compiler/dist/artifact/version.js +2 -1
  69. package/node_modules/@noodle-borg/compiler/dist/compile.js +5 -0
  70. package/node_modules/@noodle-borg/compiler/dist/errors.d.ts +1 -1
  71. package/node_modules/@noodle-borg/compiler/dist/index.d.ts +2 -2
  72. package/node_modules/@noodle-borg/compiler/dist/index.js +1 -1
  73. package/node_modules/@noodle-borg/compiler/dist/manifest/interaction-schema.d.ts +41 -0
  74. package/node_modules/@noodle-borg/compiler/dist/manifest/interaction-schema.js +62 -0
  75. package/node_modules/@noodle-borg/compiler/dist/manifest/interaction-validation.js +220 -0
  76. package/node_modules/@noodle-borg/compiler/dist/manifest/schema.d.ts +60 -4
  77. package/node_modules/@noodle-borg/compiler/dist/manifest/schema.js +7 -1
  78. package/node_modules/@noodle-borg/compiler/dist/manifest/website-projection.d.ts +9 -1
  79. package/node_modules/@noodle-borg/compiler/dist/manifest/website-projection.js +58 -10
  80. package/node_modules/@noodle-borg/control-plane/dist/in-memory-atomic-state.d.ts +8 -0
  81. package/node_modules/@noodle-borg/control-plane/dist/in-memory-atomic-state.js +136 -0
  82. package/node_modules/@noodle-borg/control-plane/dist/in-memory-control-plane-store.d.ts +7 -0
  83. package/node_modules/@noodle-borg/control-plane/dist/in-memory-control-plane-store.js +16 -24
  84. package/node_modules/@noodle-borg/control-plane/dist/in-memory-organization-store.d.ts +4 -2
  85. package/node_modules/@noodle-borg/control-plane/dist/in-memory-organization-store.js +8 -6
  86. package/node_modules/@noodle-borg/control-plane/dist/mcp-subdomain-claims.d.ts +2 -1
  87. package/node_modules/@noodle-borg/control-plane/dist/mcp-subdomain-claims.js +13 -8
  88. package/node_modules/@noodle-borg/control-plane/dist/organization-agreements.d.ts +13 -4
  89. package/node_modules/@noodle-borg/control-plane/dist/organization-agreements.js +23 -7
  90. package/node_modules/@noodle-borg/control-plane/dist/portable.d.ts +2 -1
  91. package/node_modules/@noodle-borg/control-plane/dist/portable.js +1 -0
  92. package/node_modules/@noodle-borg/module/dist/platform-human-identity.d.ts +5 -2
  93. package/node_modules/@noodle-borg/runtime/dist/connector/types.d.ts +16 -4
  94. package/node_modules/@noodle-borg/runtime/dist/execute.d.ts +3 -6
  95. package/node_modules/@noodle-borg/runtime/dist/index.d.ts +1 -1
  96. package/node_modules/@noodle-borg/service/dist/application-activity.js +85 -63
  97. package/node_modules/@noodle-borg/service/dist/application-drafts/contracts.js +9 -0
  98. package/node_modules/@noodle-borg/service/dist/application-drafts/paths.js +2 -2
  99. package/node_modules/@noodle-borg/service/dist/application-runtime-target.js +1 -1
  100. package/node_modules/@noodle-borg/service/dist/business-information/contracts.d.ts +18 -4
  101. package/node_modules/@noodle-borg/service/dist/business-information/in-memory-business-pages.js +3 -5
  102. package/node_modules/@noodle-borg/service/dist/business-information/in-memory-installation-lifecycle.js +8 -6
  103. package/node_modules/@noodle-borg/service/dist/business-information/in-memory-native-lifecycle.js +80 -0
  104. package/node_modules/@noodle-borg/service/dist/business-information/in-memory-store.js +27 -31
  105. package/node_modules/@noodle-borg/service/dist/business-information/memory-native-retention.js +29 -0
  106. package/node_modules/@noodle-borg/service/dist/business-information/model.js +9 -2
  107. package/node_modules/@noodle-borg/service/dist/business-information/native-query.js +3 -1
  108. package/node_modules/@noodle-borg/service/dist/business-information/native-record-lifecycle.d.ts +27 -0
  109. package/node_modules/@noodle-borg/service/dist/business-information/native-record-lifecycle.js +63 -0
  110. package/node_modules/@noodle-borg/service/dist/business-information/principal-authority.d.ts +3 -1
  111. package/node_modules/@noodle-borg/service/dist/business-information/principal-authority.js +9 -4
  112. package/node_modules/@noodle-borg/service/dist/business-information/staff-authority.d.ts +16 -0
  113. package/node_modules/@noodle-borg/service/dist/business-information/staff-authority.js +60 -0
  114. package/node_modules/@noodle-borg/service/dist/business-information/workspace-permissions.js +18 -0
  115. package/node_modules/@noodle-borg/service/dist/business-information-runtime.js +1 -0
  116. package/node_modules/@noodle-borg/service/dist/business-onboarding.js +16 -3
  117. package/node_modules/@noodle-borg/service/dist/business-workspaces/contracts.d.ts +110 -0
  118. package/node_modules/@noodle-borg/service/dist/business-workspaces/permissions.d.ts +7 -0
  119. package/node_modules/@noodle-borg/service/dist/business-workspaces/store.d.ts +102 -0
  120. package/node_modules/@noodle-borg/service/dist/channels/360dialog.js +70 -8
  121. package/node_modules/@noodle-borg/service/dist/channels/capability-report.js +73 -0
  122. package/node_modules/@noodle-borg/service/dist/channels/collection-turn.js +232 -0
  123. package/node_modules/@noodle-borg/service/dist/channels/composition.js +1 -0
  124. package/node_modules/@noodle-borg/service/dist/channels/messaging-eligibility.js +45 -0
  125. package/node_modules/@noodle-borg/service/dist/channels/reply-buttons.js +23 -0
  126. package/node_modules/@noodle-borg/service/dist/channels/runtime.js +127 -33
  127. package/node_modules/@noodle-borg/service/dist/native-record-connector.js +19 -4
  128. package/node_modules/@noodle-borg/service/dist/routes/application-drafts.js +44 -2
  129. package/node_modules/@noodle-borg/service/dist/routes/assistant-agent.js +4 -0
  130. package/node_modules/@noodle-borg/service/dist/routes/business-authoring-dispatch.js +1 -1
  131. package/node_modules/@noodle-borg/service/dist/routes/business-information-access.js +39 -0
  132. package/node_modules/@noodle-borg/service/dist/routes/business-information-activity.js +1 -1
  133. package/node_modules/@noodle-borg/service/dist/routes/business-information-channels.js +2 -2
  134. package/node_modules/@noodle-borg/service/dist/routes/business-information-connections.js +10 -4
  135. package/node_modules/@noodle-borg/service/dist/routes/business-information-dispatch.js +11 -0
  136. package/node_modules/@noodle-borg/service/dist/routes/business-information-installation.js +3 -1
  137. package/node_modules/@noodle-borg/service/dist/routes/business-information-notice.js +6 -2
  138. package/node_modules/@noodle-borg/service/dist/routes/business-information-pages.js +1 -1
  139. package/node_modules/@noodle-borg/service/dist/routes/business-information-paths.js +1 -1
  140. package/node_modules/@noodle-borg/service/dist/routes/business-information-record-create.js +7 -2
  141. package/node_modules/@noodle-borg/service/dist/routes/business-information-record-reads.js +2 -2
  142. package/node_modules/@noodle-borg/service/dist/routes/business-information-records.js +332 -0
  143. package/node_modules/@noodle-borg/service/dist/routes/business-information-settings.js +6 -3
  144. package/node_modules/@noodle-borg/service/dist/routes/business-information-staff.js +9 -5
  145. package/node_modules/@noodle-borg/service/dist/routes/business-information.js +12 -356
  146. package/node_modules/@noodle-borg/service/dist/routes/business-native-lifecycle.js +46 -0
  147. package/node_modules/@noodle-borg/service/dist/routes/business-workspaces.js +14 -1
  148. package/node_modules/@noodle-borg/service/dist/service.js +1 -0
  149. package/node_modules/@noodle-borg/service/dist/web-capabilities.js +3 -1
  150. package/node_modules/@noodle-borg/service/package.json +2 -1
  151. package/node_modules/@noodle-borg/wire-contracts/dist/application-draft-validation.d.ts +59 -0
  152. package/node_modules/@noodle-borg/wire-contracts/dist/application-draft-validation.js +38 -0
  153. package/node_modules/@noodle-borg/wire-contracts/dist/business-information.d.ts +144 -50
  154. package/node_modules/@noodle-borg/wire-contracts/dist/business-information.js +44 -4
  155. package/node_modules/@noodle-borg/wire-contracts/dist/business-workspaces.d.ts +70 -0
  156. package/node_modules/@noodle-borg/wire-contracts/dist/business-workspaces.js +31 -1
  157. package/node_modules/@noodle-borg/wire-contracts/dist/index.d.ts +2 -0
  158. package/node_modules/@noodle-borg/wire-contracts/dist/index.js +2 -0
  159. package/node_modules/@noodle-borg/wire-contracts/dist/native-record-lifecycle.d.ts +81 -0
  160. package/node_modules/@noodle-borg/wire-contracts/dist/native-record-lifecycle.js +39 -0
  161. package/node_modules/@noodle-borg/wire-contracts/dist/whatsapp.d.ts +26 -0
  162. package/node_modules/@noodle-borg/wire-contracts/dist/whatsapp.js +24 -1
  163. package/node_modules/@noodleseed/assistant/package.json +1 -1
  164. package/package.json +2 -2
@@ -1,6 +1,9 @@
1
1
  /** Provider-neutral embedded-assistant model transport. */
2
2
  export * from './assistant-model-context.js';
3
3
  export * from './assistant-suggestions.js';
4
+ export * from './collection-capture.js';
5
+ export * from './collection-judgment.js';
6
+ export * from './collection-model-call.js';
4
7
  export * from './model-error.js';
5
8
  export * from './model-probe.js';
6
9
  export * from './model-request.js';
@@ -24,6 +24,11 @@ export * from './channel-provider-blocks.js';
24
24
  export * from './channel-store.js';
25
25
  export * from './channel-types.js';
26
26
  export * from './channel-work.js';
27
+ export * from './collection-ledger.js';
28
+ export * from './collection-parsers.js';
29
+ export * from './collection-review.js';
30
+ export * from './collection-spec.js';
31
+ export * from './collection-store.js';
27
32
  export * from './continuity-bounds.js';
28
33
  export * from './continuity-store.js';
29
34
  export * from './elevation.js';
@@ -24,6 +24,11 @@ export * from './channel-provider-blocks.js';
24
24
  export * from './channel-store.js';
25
25
  export * from './channel-types.js';
26
26
  export * from './channel-work.js';
27
+ export * from './collection-ledger.js';
28
+ export * from './collection-parsers.js';
29
+ export * from './collection-review.js';
30
+ export * from './collection-spec.js';
31
+ export * from './collection-store.js';
27
32
  export * from './continuity-bounds.js';
28
33
  export * from './continuity-store.js';
29
34
  export * from './elevation.js';
@@ -42,7 +42,7 @@
42
42
  "@noodle-borg/module-audit": "0.0.0",
43
43
  "@noodle-borg/protocol": "0.0.0",
44
44
  "@noodle-borg/runtime": "0.0.0",
45
- "@noodleseed/assistant": "1.36.0",
45
+ "@noodleseed/assistant": "1.36.1",
46
46
  "zod": "^4.4.3"
47
47
  },
48
48
  "devDependencies": {
@@ -12,6 +12,7 @@ export { type CustomerEndpointPolicy, type CustomerEndpointRef, customerEndpoint
12
12
  export type { DistributionImageSource, DistributionMetadataSource, DistributionMetadataV1, DistributionNegativeReviewScenarioSource, DistributionPositiveReviewScenarioSource, DistributionReviewScenarioSource, DistributionScreenshotSource, } from './distribution.js';
13
13
  export { gmailConnector } from './gmail.js';
14
14
  export { type HandoffPurpose, type HandoffSession, type HandoffStateHandleLink, handoffSession, } from './handoff.js';
15
+ export type { CollectControl, CollectFieldOptions, ToolInteractionOptions, } from './interaction.js';
15
16
  export { algolia, file, firecrawl, type KnowledgeCrawlerDeclaration, type KnowledgeIndexDeclaration, type KnowledgeInput, knowledge, meilisearch, site, tavily, } from './knowledge.js';
16
17
  export { type ManagedCollectionDeclaration, type ManagedCollectionInput, type ManagedCollectionSource, managedCollection, } from './managed-collection.js';
17
18
  export { noodlePlatform, noodlePlatformCatalog } from './platform.js';
@@ -0,0 +1,49 @@
1
+ import type { Manifest } from '@noodle-borg/compiler';
2
+ import type { ServerComponent } from './server.js';
3
+ /** Standard field controls every platform renderer supports (ADR 0240, tier 0). */
4
+ export type CollectControl = 'text' | 'textarea' | 'email' | 'phone' | 'url' | 'select' | 'consent';
5
+ export interface CollectFieldOptions {
6
+ /** An input property of the action tool. */
7
+ readonly key: string;
8
+ readonly control: CollectControl;
9
+ /**
10
+ * Never enters the conversation model, transcript, logs or diagnostics. Nothing is private by
11
+ * default; mark each field deliberately.
12
+ */
13
+ readonly private?: true;
14
+ /** The person may leave it blank; the renderer submits the schema's empty value. */
15
+ readonly optional?: true;
16
+ }
17
+ /**
18
+ * Bounded `collect` interaction metadata (ADR 0240): one definition that a platform renderer presents
19
+ * with the controls each channel has, a browser form or the tool's React `view` on the website and
20
+ * natural collection in chat on messaging channels. It describes meaning, never layout: which fields
21
+ * to collect for one confirmed action, which are private, what to review, and what to say on success.
22
+ */
23
+ export interface ToolInteractionOptions {
24
+ readonly kind: 'collect';
25
+ /** The confirmed action tool (`{ confirm: true }`, not read-only) this collection prepares. */
26
+ readonly action: ServerComponent;
27
+ /** Action input property -> this tool's output property that seeds it before collection starts. */
28
+ readonly initialValues?: Readonly<Record<string, {
29
+ readonly fromOutput: string;
30
+ }>>;
31
+ readonly fields: readonly CollectFieldOptions[];
32
+ /** Every collected value is reviewed verbatim before confirmation. */
33
+ readonly review: 'all';
34
+ /** Shown only after a known successful business outcome. */
35
+ readonly outcome: {
36
+ readonly success: string;
37
+ };
38
+ /** Shorten the channel profile's confirmation expiry (whole seconds); it can never be lengthened. */
39
+ readonly confirmationExpiry?: {
40
+ readonly seconds: number;
41
+ };
42
+ }
43
+ type ManifestToolInteraction = NonNullable<Extract<Manifest, {
44
+ manifestVersion: '2';
45
+ }>['tools'][number]['interaction']>;
46
+ /** Serialize the authored block to manifest data: the action by name, fields verbatim. */
47
+ export declare function manifestToolInteraction(toolName: string, interaction: ToolInteractionOptions): ManifestToolInteraction;
48
+ export {};
49
+ //# sourceMappingURL=interaction.d.ts.map
@@ -0,0 +1,25 @@
1
+ /** Serialize the authored block to manifest data: the action by name, fields verbatim. */
2
+ export function manifestToolInteraction(toolName, interaction) {
3
+ if (interaction.action.kind !== 'tool') {
4
+ throw new Error(`tool "${toolName}" interaction.action must be a tool component`);
5
+ }
6
+ return {
7
+ kind: 'collect',
8
+ action: interaction.action.name,
9
+ ...(interaction.initialValues === undefined
10
+ ? {}
11
+ : { initialValues: { ...interaction.initialValues } }),
12
+ fields: interaction.fields.map((field) => ({
13
+ key: field.key,
14
+ control: field.control,
15
+ ...(field.private === true ? { private: true } : {}),
16
+ ...(field.optional === true ? { optional: true } : {}),
17
+ })),
18
+ review: 'all',
19
+ outcome: { success: interaction.outcome.success },
20
+ ...(interaction.confirmationExpiry === undefined
21
+ ? {}
22
+ : { confirmationExpiry: { seconds: interaction.confirmationExpiry.seconds } }),
23
+ };
24
+ }
25
+ //# sourceMappingURL=interaction.js.map
@@ -8,6 +8,7 @@ import { type ConfigRef, type DeclaredVariableRef } from './config.js';
8
8
  import { type ConnectorCatalogDoc, type ConnectorRef } from './connectors.js';
9
9
  import { type ServerContextOptions } from './context.js';
10
10
  import { type CustomerAuth } from './customer-auth.js';
11
+ import { type ToolInteractionOptions } from './interaction.js';
11
12
  import { type JsonSchema } from './json-schema.js';
12
13
  import { type KnowledgeDeclaration } from './knowledge.js';
13
14
  import * as collections from './managed-collection.js';
@@ -158,6 +159,8 @@ export interface ToolOptions {
158
159
  readonly visibility?: ('model' | 'app')[];
159
160
  /** Optional MCP Apps presentation linked to this tool. A view is metadata, not another tool kind. */
160
161
  readonly view?: ToolViewOptions;
162
+ /** Bounded `collect` interaction this opener declares for one confirmed action (ADR 0240). */
163
+ readonly interaction?: ToolInteractionOptions;
161
164
  /** Stable view identity. Defaults to `<tool>_widget`. */
162
165
  readonly viewName?: string;
163
166
  readonly viewTitle?: string;
@@ -9,6 +9,7 @@ import { toManifestConnectorRef } from './connections.js';
9
9
  import { validateCatalog } from './connectors.js';
10
10
  import { manifestContext } from './context.js';
11
11
  import { manifestCustomerAuth } from './customer-auth.js';
12
+ import { manifestToolInteraction } from './interaction.js';
12
13
  import { toJsonSchema } from './json-schema.js';
13
14
  import { manifestKnowledge } from './knowledge.js';
14
15
  import * as collections from './managed-collection.js';
@@ -149,6 +150,9 @@ class ServerBuilder {
149
150
  ...(tool.options.output ? { outputSchema: toJsonSchema(tool.options.output) } : {}),
150
151
  ...manifestToolAnnotations(tool.options),
151
152
  ...(tool.options.visibility?.length ? { visibility: [...tool.options.visibility] } : {}),
153
+ ...(tool.options.interaction
154
+ ? { interaction: manifestToolInteraction(tool.name, tool.options.interaction) }
155
+ : {}),
152
156
  fulfilment: {
153
157
  steps: recorded.steps,
154
158
  output: recorded.output,
@@ -20,16 +20,21 @@
20
20
  "./load-authored": {
21
21
  "types": "./dist/load-authored.d.ts",
22
22
  "import": "./dist/load-authored.js"
23
+ },
24
+ "./sandbox-authoring": {
25
+ "types": "./dist/sandbox-authoring.d.ts",
26
+ "import": "./dist/sandbox-authoring.js"
23
27
  }
24
28
  },
25
29
  "files": [
26
30
  "dist"
27
31
  ],
28
32
  "scripts": {
29
- "build": "tsc -p tsconfig.json",
33
+ "build": "tsc -p tsconfig.json && node ../../scripts/build-authoring-sandbox.mjs",
30
34
  "typecheck": "tsc -p tsconfig.json --noEmit && tsc -p tsconfig.type-tests.json --noEmit"
31
35
  },
32
36
  "dependencies": {
37
+ "@noodle-borg/compute": "0.0.0",
33
38
  "@noodle-borg/managed-capabilities": "0.0.0",
34
39
  "typescript": "^6.0.3",
35
40
  "@noodle-borg/compiler": "0.0.0",
@@ -60,7 +60,7 @@ export const CHANNELS_COMMAND = {
60
60
  flag('support-email', 'Contact shown when an answer cannot be completed.'),
61
61
  ...limits,
62
62
  ]),
63
- leaf('doctor', 'Check deployment, storage, worker, model cost bound, and provider setup.', mutation),
63
+ leaf('doctor', 'Check deployment, storage, worker, model cost bound, provider setup, and capability compatibility.', mutation),
64
64
  leaf('enable', 'Enable after a successful current readiness check.', [
65
65
  revision,
66
66
  ...mutation,
@@ -37,6 +37,13 @@ export const SOLUTION_DRAFTS = {
37
37
  arguments: [],
38
38
  flags: [],
39
39
  subcommands: [
40
+ {
41
+ name: 'validate',
42
+ summary: 'Check an exact saved TypeScript revision without executing actions or publishing.',
43
+ arguments: [draftId],
44
+ flags: [...common, revision],
45
+ jsonOutput: { mode: 'single' },
46
+ },
40
47
  {
41
48
  name: 'history',
42
49
  summary: 'List source-free revisions, newest first.',
@@ -0,0 +1,43 @@
1
+ /** Native-record lifecycle review; no automatic data migration. */
2
+ import { INSTALLATION_ARGUMENT, OPTIONAL_FLAG, SOLUTION_COMMON_FLAGS, } from './catalog-data-solution-flags.js';
3
+ const common = SOLUTION_COMMON_FLAGS.map((flag) => flag.name === 'org' ? { ...flag, required: true } : flag);
4
+ export const SOLUTION_NATIVE_LIFECYCLE = {
5
+ name: 'lifecycle',
6
+ summary: 'Review and explicitly preserve available native records until erasure.',
7
+ arguments: [],
8
+ flags: [],
9
+ subcommands: [
10
+ {
11
+ name: 'preview',
12
+ summary: 'Inspect current policy and preservation counts without changing records.',
13
+ arguments: [INSTALLATION_ARGUMENT],
14
+ flags: common,
15
+ jsonOutput: { mode: 'single' },
16
+ },
17
+ {
18
+ name: 'migrate',
19
+ summary: 'Apply a reviewed one-way migration; never restore expired or erased records.',
20
+ arguments: [INSTALLATION_ARGUMENT],
21
+ flags: [
22
+ ...common,
23
+ {
24
+ ...OPTIONAL_FLAG,
25
+ name: 'preview',
26
+ type: 'string',
27
+ value: '<json>',
28
+ required: true,
29
+ summary: 'Exact preview data JSON, valid for five minutes and only while the reviewed inventory is unchanged.',
30
+ },
31
+ {
32
+ ...OPTIONAL_FLAG,
33
+ name: 'confirm',
34
+ type: 'boolean',
35
+ required: true,
36
+ summary: 'Confirm preserving available and future records until explicit erasure. Activity history is unchanged.',
37
+ },
38
+ ],
39
+ jsonOutput: { mode: 'single' },
40
+ },
41
+ ],
42
+ };
43
+ //# sourceMappingURL=catalog-data-solution-native-lifecycle.js.map
@@ -0,0 +1,154 @@
1
+ /** Canonical record operations and reviewed lifecycle metadata. Pure data only. */
2
+ import { INSTALLATION_ARGUMENT, OPTIONAL_FLAG, PAGING_FLAGS, REQUIRED_ARGUMENT, SOLUTION_COMMON_FLAGS, } from './catalog-data-solution-flags.js';
3
+ import { SOLUTION_NATIVE_LIFECYCLE } from './catalog-data-solution-native-lifecycle.js';
4
+ export const COLLECTION_ARGUMENT = {
5
+ ...REQUIRED_ARGUMENT,
6
+ name: 'collection',
7
+ summary: 'Managed collection key.',
8
+ };
9
+ const RECORD_ARGUMENT = {
10
+ ...REQUIRED_ARGUMENT,
11
+ name: 'record',
12
+ summary: 'Managed record identifier.',
13
+ };
14
+ const RECORD_QUERY_FLAGS = [
15
+ {
16
+ ...OPTIONAL_FLAG,
17
+ name: 'filters',
18
+ type: 'string',
19
+ value: '<json>',
20
+ summary: 'JSON array of up to eight field/value equality filters, combined with AND. Only declared fields.',
21
+ },
22
+ {
23
+ ...OPTIONAL_FLAG,
24
+ name: 'sort-field',
25
+ type: 'string',
26
+ value: '<field>',
27
+ summary: 'Declared native collection sort field.',
28
+ },
29
+ {
30
+ ...OPTIONAL_FLAG,
31
+ name: 'sort-direction',
32
+ type: 'string',
33
+ value: '<asc|desc>',
34
+ summary: 'Sort direction; requires --sort-field.',
35
+ },
36
+ {
37
+ ...OPTIONAL_FLAG,
38
+ name: 'created-at-from',
39
+ type: 'string',
40
+ value: '<timestamp>',
41
+ summary: 'Inclusive creation-time lower bound; narrows the 10,000-record payload-query scan.',
42
+ },
43
+ {
44
+ ...OPTIONAL_FLAG,
45
+ name: 'created-at-to',
46
+ type: 'string',
47
+ value: '<timestamp>',
48
+ summary: 'Inclusive creation-time upper bound.',
49
+ },
50
+ ];
51
+ const RECORD_FLAGS = [
52
+ ...SOLUTION_COMMON_FLAGS,
53
+ {
54
+ ...OPTIONAL_FLAG,
55
+ name: 'data',
56
+ type: 'string',
57
+ value: '<json>',
58
+ summary: 'Structured JSON record data.',
59
+ },
60
+ {
61
+ ...OPTIONAL_FLAG,
62
+ name: 'idempotency-key',
63
+ type: 'string',
64
+ value: '<key>',
65
+ summary: 'Retry-safe create key.',
66
+ },
67
+ {
68
+ ...OPTIONAL_FLAG,
69
+ name: 'expected-revision',
70
+ type: 'integer',
71
+ value: '<revision>',
72
+ summary: 'Expected current record revision.',
73
+ },
74
+ {
75
+ ...OPTIONAL_FLAG,
76
+ name: 'status',
77
+ type: 'string',
78
+ value: '<status>',
79
+ summary: 'Record status or list filter.',
80
+ },
81
+ {
82
+ ...OPTIONAL_FLAG,
83
+ name: 'assignee',
84
+ type: 'string',
85
+ value: '<subject>',
86
+ summary: 'Assignee subject or list filter.',
87
+ },
88
+ {
89
+ ...OPTIONAL_FLAG,
90
+ name: 'note',
91
+ type: 'string',
92
+ value: '<text>',
93
+ summary: 'Operator note text.',
94
+ },
95
+ ...PAGING_FLAGS,
96
+ {
97
+ ...OPTIONAL_FLAG,
98
+ name: 'include-deleted',
99
+ type: 'boolean',
100
+ summary: 'Include payload-free tombstones.',
101
+ },
102
+ ];
103
+ export const SOLUTION_RECORDS = {
104
+ name: 'records',
105
+ summary: 'Operate one installed managed collection.',
106
+ arguments: [],
107
+ flags: [],
108
+ usage: 'solutions records <list|create|get|update|assign|status|note|activity|delete|migrate-schema|export|lifecycle> [options]',
109
+ subcommands: [
110
+ SOLUTION_NATIVE_LIFECYCLE,
111
+ ...[
112
+ 'list',
113
+ 'create',
114
+ 'get',
115
+ 'update',
116
+ 'assign',
117
+ 'status',
118
+ 'note',
119
+ 'activity',
120
+ 'delete',
121
+ 'migrate-schema',
122
+ 'export',
123
+ ].map((name) => ({
124
+ name,
125
+ summary: name === 'activity'
126
+ ? 'Read native record history newest first; default 50, maximum 100, with --cursor for older pages.'
127
+ : name === 'migrate-schema'
128
+ ? 'Administrator-only conversion of an eligible legacy request record with revision protection.'
129
+ : `${name[0]?.toUpperCase()}${name.slice(1)} managed records.`,
130
+ arguments: [
131
+ INSTALLATION_ARGUMENT,
132
+ COLLECTION_ARGUMENT,
133
+ ...(name === 'list' || name === 'create' || name === 'export' ? [] : [RECORD_ARGUMENT]),
134
+ ],
135
+ flags: [
136
+ ...RECORD_FLAGS,
137
+ ...(name === 'list' ? RECORD_QUERY_FLAGS : []),
138
+ ...(name === 'update'
139
+ ? [
140
+ {
141
+ ...OPTIONAL_FLAG,
142
+ name: 'unset',
143
+ type: 'string',
144
+ value: '<fields>',
145
+ summary: 'Comma-separated optional field keys to remove; cannot overlap --data. May be used without --data.',
146
+ },
147
+ ]
148
+ : []),
149
+ ],
150
+ jsonOutput: { mode: 'single' },
151
+ })),
152
+ ],
153
+ };
154
+ //# sourceMappingURL=catalog-data-solution-records.js.map
@@ -1,5 +1,5 @@
1
1
  /** Fixed-role workspace administration. No execution or business permission authority lives here. */
2
- import { EXPECTED_REVISION, OPTIONAL_FLAG, SOLUTION_COMMON_FLAGS, } from './catalog-data-solution-flags.js';
2
+ import { EXPECTED_REVISION, OPTIONAL_FLAG, PAGING_FLAGS, SOLUTION_COMMON_FLAGS, } from './catalog-data-solution-flags.js';
3
3
  const common = SOLUTION_COMMON_FLAGS.map((flag) => flag.name === 'org' ? { ...flag, required: true } : flag);
4
4
  const confirm = {
5
5
  ...OPTIONAL_FLAG,
@@ -27,6 +27,13 @@ export const SOLUTION_WORKSPACE = {
27
27
  arguments: [],
28
28
  flags: [],
29
29
  subcommands: [
30
+ {
31
+ name: 'list',
32
+ summary: 'Discover your current business workspaces without developer organization access.',
33
+ arguments: [],
34
+ flags: [...SOLUTION_COMMON_FLAGS.filter((flag) => flag.name !== 'org'), ...PAGING_FLAGS],
35
+ jsonOutput: { mode: 'single' },
36
+ },
30
37
  {
31
38
  name: 'show',
32
39
  summary: 'Inspect current workspace members, permissions and pending invitations.',
@@ -2,6 +2,7 @@
2
2
  import { SOLUTION_DRAFTS } from './catalog-data-solution-drafts.js';
3
3
  import { AUTH_TOKEN, EXPECTED_REVISION, IDEMPOTENCY_KEY, INSTALLATION_ARGUMENT, JSON_FLAG, OPTIONAL_FLAG, PAGING_FLAGS, REQUIRED_ARGUMENT, SERVICE, SOLUTION_COMMON_FLAGS, } from './catalog-data-solution-flags.js';
4
4
  import { SOLUTION_PAGE } from './catalog-data-solution-page.js';
5
+ import { COLLECTION_ARGUMENT, SOLUTION_RECORDS } from './catalog-data-solution-records.js';
5
6
  import { SOLUTION_WORKSPACE } from './catalog-data-solution-workspace.js';
6
7
  const APP = {
7
8
  ...OPTIONAL_FLAG,
@@ -25,105 +26,6 @@ const RETENTION = {
25
26
  summary: 'Managed-record retention in days.',
26
27
  constraints: { choices: [7, 30, 90], default: 30 },
27
28
  };
28
- const COLLECTION_ARGUMENT = {
29
- ...REQUIRED_ARGUMENT,
30
- name: 'collection',
31
- summary: 'Managed collection key.',
32
- };
33
- const RECORD_ARGUMENT = {
34
- ...REQUIRED_ARGUMENT,
35
- name: 'record',
36
- summary: 'Managed record identifier.',
37
- };
38
- const RECORD_QUERY_FLAGS = [
39
- {
40
- ...OPTIONAL_FLAG,
41
- name: 'filters',
42
- type: 'string',
43
- value: '<json>',
44
- summary: 'JSON array of up to eight field/value equality filters, combined with AND. Only declared fields.',
45
- },
46
- {
47
- ...OPTIONAL_FLAG,
48
- name: 'sort-field',
49
- type: 'string',
50
- value: '<field>',
51
- summary: 'Declared native collection sort field.',
52
- },
53
- {
54
- ...OPTIONAL_FLAG,
55
- name: 'sort-direction',
56
- type: 'string',
57
- value: '<asc|desc>',
58
- summary: 'Sort direction; requires --sort-field.',
59
- },
60
- {
61
- ...OPTIONAL_FLAG,
62
- name: 'created-at-from',
63
- type: 'string',
64
- value: '<timestamp>',
65
- summary: 'Inclusive creation-time lower bound; narrows the 10,000-record payload-query scan.',
66
- },
67
- {
68
- ...OPTIONAL_FLAG,
69
- name: 'created-at-to',
70
- type: 'string',
71
- value: '<timestamp>',
72
- summary: 'Inclusive creation-time upper bound.',
73
- },
74
- ];
75
- const RECORD_FLAGS = [
76
- ...SOLUTION_COMMON_FLAGS,
77
- {
78
- ...OPTIONAL_FLAG,
79
- name: 'data',
80
- type: 'string',
81
- value: '<json>',
82
- summary: 'Structured JSON record data.',
83
- },
84
- {
85
- ...OPTIONAL_FLAG,
86
- name: 'idempotency-key',
87
- type: 'string',
88
- value: '<key>',
89
- summary: 'Retry-safe create key.',
90
- },
91
- {
92
- ...OPTIONAL_FLAG,
93
- name: 'expected-revision',
94
- type: 'integer',
95
- value: '<revision>',
96
- summary: 'Expected current record revision.',
97
- },
98
- {
99
- ...OPTIONAL_FLAG,
100
- name: 'status',
101
- type: 'string',
102
- value: '<status>',
103
- summary: 'Record status or list filter.',
104
- },
105
- {
106
- ...OPTIONAL_FLAG,
107
- name: 'assignee',
108
- type: 'string',
109
- value: '<subject>',
110
- summary: 'Assignee subject or list filter.',
111
- },
112
- {
113
- ...OPTIONAL_FLAG,
114
- name: 'note',
115
- type: 'string',
116
- value: '<text>',
117
- summary: 'Operator note text.',
118
- },
119
- ...PAGING_FLAGS,
120
- {
121
- ...OPTIONAL_FLAG,
122
- name: 'include-deleted',
123
- type: 'boolean',
124
- summary: 'Include payload-free tombstones.',
125
- },
126
- ];
127
29
  export const CATALOG_SOLUTIONS = {
128
30
  name: 'solutions',
129
31
  section: 'resources',
@@ -630,56 +532,7 @@ export const CATALOG_SOLUTIONS = {
630
532
  },
631
533
  ],
632
534
  },
633
- {
634
- name: 'records',
635
- summary: 'Operate one installed managed collection.',
636
- arguments: [],
637
- flags: [],
638
- usage: 'solutions records <list|create|get|update|assign|status|note|activity|delete|migrate-schema|export> <installation> <collection> [record] [options]',
639
- subcommands: [
640
- ...[
641
- 'list',
642
- 'create',
643
- 'get',
644
- 'update',
645
- 'assign',
646
- 'status',
647
- 'note',
648
- 'activity',
649
- 'delete',
650
- 'migrate-schema',
651
- 'export',
652
- ].map((name) => ({
653
- name,
654
- summary: name === 'activity'
655
- ? 'Read native record history newest first; default 50, maximum 100, with --cursor for older pages.'
656
- : name === 'migrate-schema'
657
- ? 'Administrator-only conversion of an eligible legacy request record with revision protection.'
658
- : `${name[0]?.toUpperCase()}${name.slice(1)} managed records.`,
659
- arguments: [
660
- INSTALLATION_ARGUMENT,
661
- COLLECTION_ARGUMENT,
662
- ...(name === 'list' || name === 'create' || name === 'export' ? [] : [RECORD_ARGUMENT]),
663
- ],
664
- flags: [
665
- ...RECORD_FLAGS,
666
- ...(name === 'list' ? RECORD_QUERY_FLAGS : []),
667
- ...(name === 'update'
668
- ? [
669
- {
670
- ...OPTIONAL_FLAG,
671
- name: 'unset',
672
- type: 'string',
673
- value: '<fields>',
674
- summary: 'Comma-separated optional field keys to remove; cannot overlap --data. May be used without --data.',
675
- },
676
- ]
677
- : []),
678
- ],
679
- jsonOutput: { mode: 'single' },
680
- })),
681
- ],
682
- },
535
+ SOLUTION_RECORDS,
683
536
  {
684
537
  name: 'sources',
685
538
  summary: 'Inspect and control one external collection source.',
@@ -1,6 +1,6 @@
1
1
  import { artifactConfig } from './config.js';
2
2
  import { ARTIFACT_SCHEMA_VERSION, } from './types.js';
3
- export function assembleRuntimeArtifact({ manifest, options, runtimeBranding, runtimeShell, artifactAmbientContext, state, artifactTools, allResources, artifactPrompts, packagedAssets, requirements, declared, customerEndpoints, knowledge, managedCollections, variables, }) {
3
+ export function assembleRuntimeArtifact({ manifest, options, runtimeBranding, runtimeShell, artifactAmbientContext, state, artifactTools, allResources, artifactPrompts, packagedAssets, requirements, declared, customerEndpoints, knowledge, managedCollections, variables, toolInteractions, }) {
4
4
  // 4. Assemble the artifact. `resources`/`prompts` and their capability lists are emitted only when
5
5
  // present, keeping a tools-only artifact byte-identical to before this slice.
6
6
  const capabilities = {
@@ -54,6 +54,7 @@ export function assembleRuntimeArtifact({ manifest, options, runtimeBranding, ru
54
54
  ...(state !== undefined ? { state } : {}),
55
55
  },
56
56
  tools: artifactTools,
57
+ ...(toolInteractions === undefined ? {} : { toolInteractions }),
57
58
  ...(allResources.length > 0 ? { resources: allResources } : {}),
58
59
  ...(artifactPrompts.length > 0 ? { prompts: artifactPrompts } : {}),
59
60
  ...(packagedAssets.length > 0 ? { assets: packagedAssets.map(toArtifactAsset) } : {}),