@agent-native/dispatch 0.40.23-nightly-20261014124140 → 0.40.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,28 +1,19 @@
1
1
  # @agent-native/dispatch
2
2
 
3
- ## 0.40.23-nightly-20261014124140
3
+ ## 0.40.23
4
4
 
5
5
  ### Patch Changes
6
6
 
7
+ - Release all public npm packages with a patch version bump.
8
+ - 3ab5193: Drop the caller-supplied `size` from Builder upload attachments and measure it on the server, reject invalid attachments up front with an `invalid_attachment` error, and teach the turn-into-app browser-host guide to attach Project instructions and knowledge files verbatim, so a bad or missing attachment no longer reads as a temporary Builder outage or a silent drop.
7
9
  - 3b9d3cd: Show how long each tool call took in Thread Debug.
8
- - Updated dependencies [d52c0b3]
9
10
  - Updated dependencies [fadfb1b]
10
- - Updated dependencies [1856007]
11
11
  - Updated dependencies [7407dca]
12
12
  - Updated dependencies [980bd9f]
13
- - Updated dependencies [d31e11d]
14
13
  - Updated dependencies [7407dca]
15
- - Updated dependencies [11c3988]
16
- - Updated dependencies [62cc000]
17
- - Updated dependencies [3be2c82]
18
- - Updated dependencies [8961aeb]
19
- - Updated dependencies [3be2c82]
20
- - Updated dependencies [3be2c82]
21
- - Updated dependencies [6c0529a]
22
- - Updated dependencies [3b9d3cd]
23
- - Updated dependencies [9bb5cda]
24
- - @agent-native/core@0.209.0-nightly-20261014124140
25
- - @agent-native/toolkit@0.209.0-nightly-20261014124140
14
+ - Updated dependencies
15
+ - Updated dependencies [d6a3ea3]
16
+ - @agent-native/toolkit@0.209.0
26
17
 
27
18
  ## 0.40.22
28
19
 
@@ -1269,11 +1260,4 @@
1269
1260
  - Updated dependencies [95ea873]
1270
1261
  - @agent-native/toolkit@0.16.4
1271
1262
 
1272
- ## 0.27.16
1273
-
1274
- ### Patch Changes
1275
-
1276
- - 3850b75: Retry workspace embed-session minting with the shared A2A secret when a target rejects org-secret authentication, with redacted mint diagnostics. Keep SSO fanout limited to canonical and explicitly registered own-origin apps; path-mounted workspace apps remain same-origin with Dispatch and keep their existing ambient session behavior, so this narrows fanout targets but is not origin isolation.
1277
- - 3850b75: Resolve workspace embed pages from an app's canonical home URL instead of a deep A2A link, and allow extensions rendered in the hosted workspace to load in their parent frame.
1278
-
1279
1263
  For the full list of releases, see the [changelog archive](./changelog/archive/CHANGELOG.md).
@@ -6,6 +6,19 @@ declare const _default: import("@agent-native/core/action").ActionDefinition<{
6
6
  content: string;
7
7
  scope: "all" | "selected";
8
8
  }, {
9
+ id: string;
10
+ ownerEmail: string;
11
+ orgId: string | null;
12
+ kind: string;
13
+ name: string;
14
+ description: string | null;
15
+ path: string;
16
+ content: string;
17
+ scope: string;
18
+ createdBy: string;
19
+ createdAt: number;
20
+ updatedAt: number;
21
+ } | {
9
22
  id: string;
10
23
  ownerEmail: string;
11
24
  orgId: string | null;
@@ -22,19 +35,6 @@ declare const _default: import("@agent-native/core/action").ActionDefinition<{
22
35
  reviewedAt: number | null;
23
36
  createdAt: number;
24
37
  updatedAt: number;
25
- } | {
26
- id: string;
27
- ownerEmail: string;
28
- orgId: string | null;
29
- kind: string;
30
- name: string;
31
- description: string | null;
32
- path: string;
33
- content: string;
34
- scope: string;
35
- createdBy: string;
36
- createdAt: number;
37
- updatedAt: number;
38
38
  }>;
39
39
  export default _default;
40
40
  //# sourceMappingURL=create-workspace-resource.d.ts.map
@@ -1,19 +1,6 @@
1
1
  declare const _default: import("@agent-native/core/action").ActionDefinition<{
2
2
  id: string;
3
3
  }, {
4
- id: string;
5
- ownerEmail: string;
6
- orgId: string | null;
7
- kind: string;
8
- name: string;
9
- description: string | null;
10
- path: string;
11
- content: string;
12
- scope: string;
13
- createdBy: string;
14
- createdAt: number;
15
- updatedAt: number;
16
- } | {
17
4
  id: string;
18
5
  ownerEmail: string;
19
6
  orgId: string | null;
@@ -30,6 +17,19 @@ declare const _default: import("@agent-native/core/action").ActionDefinition<{
30
17
  reviewedAt: number | null;
31
18
  createdAt: number;
32
19
  updatedAt: number;
20
+ } | {
21
+ id: string;
22
+ ownerEmail: string;
23
+ orgId: string | null;
24
+ kind: string;
25
+ name: string;
26
+ description: string | null;
27
+ path: string;
28
+ content: string;
29
+ scope: string;
30
+ createdBy: string;
31
+ createdAt: number;
32
+ updatedAt: number;
33
33
  }>;
34
34
  export default _default;
35
35
  //# sourceMappingURL=delete-workspace-resource.d.ts.map
@@ -23,19 +23,6 @@ declare const _default: import("@agent-native/core/action").ActionDefinition<{
23
23
  } | {
24
24
  status: "created";
25
25
  resource: {
26
- id: string;
27
- ownerEmail: string;
28
- orgId: string | null;
29
- kind: string;
30
- name: string;
31
- description: string | null;
32
- path: string;
33
- content: string;
34
- scope: string;
35
- createdBy: string;
36
- createdAt: number;
37
- updatedAt: number;
38
- } | {
39
26
  id: string;
40
27
  ownerEmail: string;
41
28
  orgId: string | null;
@@ -52,6 +39,19 @@ declare const _default: import("@agent-native/core/action").ActionDefinition<{
52
39
  reviewedAt: number | null;
53
40
  createdAt: number;
54
41
  updatedAt: number;
42
+ } | {
43
+ id: string;
44
+ ownerEmail: string;
45
+ orgId: string | null;
46
+ kind: string;
47
+ name: string;
48
+ description: string | null;
49
+ path: string;
50
+ content: string;
51
+ scope: string;
52
+ createdBy: string;
53
+ createdAt: number;
54
+ updatedAt: number;
55
55
  };
56
56
  source: "claude" | "json" | "markdown";
57
57
  warnings: string[];
@@ -47,10 +47,10 @@ declare const _default: import("node_modules/@agent-native/core/dist").ActionDef
47
47
  notes?: string | undefined;
48
48
  scope?: "org" | "user" | undefined;
49
49
  }, {
50
+ id?: undefined;
50
51
  provider?: undefined;
51
52
  deleted?: undefined;
52
- id?: undefined;
53
- found?: undefined;
53
+ message?: undefined;
54
54
  providers: {
55
55
  id: string;
56
56
  label: string;
@@ -61,45 +61,45 @@ declare const _default: import("node_modules/@agent-native/core/dist").ActionDef
61
61
  updatedAt: number;
62
62
  }[];
63
63
  count: number;
64
+ found?: undefined;
64
65
  registered?: undefined;
65
66
  label?: undefined;
66
- message?: undefined;
67
67
  } | {
68
- deleted?: undefined;
69
68
  id?: undefined;
70
69
  count?: undefined;
70
+ deleted?: undefined;
71
+ message?: undefined;
71
72
  providers?: undefined;
72
73
  found: boolean;
73
74
  provider: import("node_modules/@agent-native/core/dist/provider-api").CustomProviderConfig;
74
75
  registered?: undefined;
75
76
  label?: undefined;
76
- message?: undefined;
77
77
  } | {
78
78
  provider?: undefined;
79
- deleted?: undefined;
80
79
  count?: undefined;
80
+ deleted?: undefined;
81
+ message?: undefined;
81
82
  providers?: undefined;
82
83
  found: boolean;
83
84
  id: string;
84
85
  registered?: undefined;
85
86
  label?: undefined;
86
- message?: undefined;
87
87
  } | {
88
88
  provider?: undefined;
89
89
  count?: undefined;
90
- found?: undefined;
90
+ message?: undefined;
91
91
  providers?: undefined;
92
+ found?: undefined;
92
93
  deleted: boolean;
93
94
  id: string;
94
95
  registered?: undefined;
95
96
  label?: undefined;
96
- message?: undefined;
97
97
  } | {
98
98
  provider?: undefined;
99
- deleted?: undefined;
100
99
  count?: undefined;
101
- found?: undefined;
100
+ deleted?: undefined;
102
101
  providers?: undefined;
102
+ found?: undefined;
103
103
  registered: boolean;
104
104
  id: string;
105
105
  label: string;
@@ -13,7 +13,6 @@ declare const attachmentSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
13
13
  name: z.ZodString;
14
14
  dataUrl: z.ZodString;
15
15
  text: z.ZodOptional<z.ZodString>;
16
- size: z.ZodNumber;
17
16
  id: z.ZodString;
18
17
  }, z.core.$strip>, z.ZodObject<{
19
18
  type: z.ZodLiteral<"url">;
@@ -33,7 +32,6 @@ declare const _default: import("@agent-native/core/action").ActionDefinition<{
33
32
  name: string;
34
33
  dataUrl: string;
35
34
  text?: string | undefined;
36
- size: number;
37
35
  id: string;
38
36
  } | {
39
37
  type: "url";
@@ -1 +1 @@
1
- {"version":3,"file":"start-workspace-app-creation.d.ts","sourceRoot":"","sources":["../../src/actions/start-workspace-app-creation.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,QAAA,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;2BAsBpB,CAAC;AAEH,MAAM,MAAM,mCAAmC,GAAG,CAAC,CAAC,KAAK,CACvD,OAAO,gBAAgB,CACxB,CAAC"}
1
+ {"version":3,"file":"start-workspace-app-creation.d.ts","sourceRoot":"","sources":["../../src/actions/start-workspace-app-creation.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,QAAA,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;2BAqBpB,CAAC;AAEH,MAAM,MAAM,mCAAmC,GAAG,CAAC,CAAC,KAAK,CACvD,OAAO,gBAAgB,CACxB,CAAC"}
@@ -17,7 +17,6 @@ const attachmentSchema = z.discriminatedUnion("type", [
17
17
  name: z.string().min(1),
18
18
  dataUrl: z.string(),
19
19
  text: z.string().optional(),
20
- size: z.number().int().nonnegative(),
21
20
  id: z.string().min(1),
22
21
  }),
23
22
  z.object({
@@ -1 +1 @@
1
- {"version":3,"file":"start-workspace-app-creation.js","sourceRoot":"","sources":["../../src/actions/start-workspace-app-creation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EACL,gCAAgC,EAChC,uBAAuB,GACxB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,yBAAyB,EAAE,MAAM,qCAAqC,CAAC;AAEhF,MAAM,gBAAgB,GAAG,CAAC,CAAC,kBAAkB,CAAC,MAAM,EAAE;IACpD,CAAC,CAAC,MAAM,CAAC;QACP,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,QAAQ,CAAC;QACzB,WAAW,EAAE,CAAC,CAAC,IAAI,CAAC;YAClB,YAAY;YACZ,WAAW;YACX,YAAY;YACZ,WA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,CAAC;aACR,QAAQ,EAAE;aACV,QAAQ,EAAE;aACV,QAAQ,CACP,6HAA6H,CAC9H;QACH,SAAS,EAAE,CAAC;aACT,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;aACjB,GAAG,CAAC,GAAG,CAAC;aACR,QAAQ,EAAE;aACV,QAAQ,CAAC,+CAA+C,CAAC;QAC5D,WAAW,EAAE,CAAC;aACX,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;aACjB,GAAG,CAAC,GAAG,CAAC;aACR,QAAQ,EAAE;aACV,QAAQ,CACP,wEAAwE,CACzE;QACH,WAAW,EAAE,CAAC;aACX,KAAK,CAAC,gBAAgB,CAAC;aACvB,QAAQ,EAAE;aACV,QAAQ,CACP,oJAAoJ,CACrJ;KACJ,CAAC;IACF,GAAG,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE,CAAC,yBAAyB,CAAC,IAAI,CAAC;CACrD,CAAC,CAAC","sourcesContent":["import { defineAction } from \"@agent-native/core/action\";\nimport {\n getWorkspaceAppIdValidationError,\n normalizeWorkspaceAppId,\n} from \"@agent-native/core/shared\";\nimport { z } from \"zod\";\n\nimport { startWorkspaceAppCreation } from \"../server/lib/app-creation-store.js\";\n\nconst attachmentSchema = z.discriminatedUnion(\"type\", [\n z.object({\n type: z.literal(\"upload\"),\n contentType: z.enum([\n \"image/webp\",\n \"image/png\",\n \"image/jpeg\",\n \"image/gif\",\n \"application/pdf\",\n \"application/json\",\n \"text/plain\",\n ]),\n name: z.string().min(1),\n dataUrl: z.string(),\n text: z.string().optional(),\n size: z.number().int().nonnegative(),\n id: z.string().min(1),\n }),\n z.object({\n type: z.literal(\"url\"),\n value: z.string().url(),\n }),\n]);\n\nexport type StartWorkspaceAppCreationAttachment = z.infer<\n typeof attachmentSchema\n>;\n\nexport default defineAction({\n description:\n 'Start creating a new workspace app from Dispatch when the request truly needs its own app. For Claude Web, ChatGPT Web, or either host\\'s web Project, this action is the Builder handoff: call it after forming a bounded source brief and do not scaffold or edit files in the host sandbox. This handoff is autonomous once the brief exists: do not ask the user for non-blocking product or UX choices; choose recommended defaults and let Builder record assumptions while it implements. Callers should include a concise generated description by default; Dispatch generates one from the prompt when omitted. In local dev this returns a code-agent prompt; in production it reuses the connected Agent-Native workspace project or, for an organization owner/admin, provisions it through the Builder Projects API before starting the Builder Cloud Agent branch. If no project is configured, organization members must ask an owner/admin to configure it first. The result must be a separate workspace app under apps/<app-id>, not a new route or file in apps/chat. If chat is used as the source template, the finished app must be branded as the requested app and must not leave visible \"Chat\", \"Starter\", \"Blank app\", or \"New app\" UI behind. If the request needs Mail, Calendar, Analytics, Brain, Assets, or another first-party app, use the existing hosted/connected app via links or A2A; do not wrap or nest those apps inside the new app unless the user explicitly asks for a customized app from that template.',\n schema: z.object({\n prompt: z.string().min(1).describe(\"The user's app creation request\"),\n appId: z\n .string()\n .max(64)\n .transform(normalizeWorkspaceAppId)\n .refine((appId) => !getWorkspaceAppIdValidationError(appId), {\n message:\n \"Use a non-reserved app id with lowercase letters, numbers, and hyphens.\",\n })\n .optional()\n .nullable()\n .describe(\n \"Desired workspace app id/path or human-friendly name. Names are converted to lowercase, hyphenated ids.\",\n ),\n template: z\n .string()\n .optional()\n .nullable()\n .describe(\"Template to start from\"),\n description: z\n .string()\n .max(500)\n .optional()\n .nullable()\n .describe(\n \"Concise AI-generated description of the app based on the user's prompt. Dispatch saves this while the app is being created.\",\n ),\n secretIds: z\n .array(z.string())\n .max(100)\n .optional()\n .describe(\"Dispatch vault secret IDs to grant to the app\"),\n resourceIds: z\n .array(z.string())\n .max(100)\n .optional()\n .describe(\n \"Dispatch workspace resource IDs or knowledge packs to grant to the app\",\n ),\n attachments: z\n .array(attachmentSchema)\n .optional()\n .describe(\n \"Optional Builder message attachments. Uploads use supported image, PDF, text, or JSON content; attachments are model context, not workspace files.\",\n ),\n }),\n run: async (args) => startWorkspaceAppCreation(args),\n});\n"]}
1
+ {"version":3,"file":"start-workspace-app-creation.js","sourceRoot":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GAAG,CAAC,EAAE,CAAC;aACP,SAAS,CAAC,uBAAuB,CAAC;aAClC,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,gCAAgC,CAAC,KAAK,CAAC,EAAE;YAC3D,OAAO,EACL,yEAAyE;SAC5E,CAAC;aACD,QAAQ,EAAE;aACV,QAAQ,EAAE;aACV,QAAQ,CACP,yGAAyG,CAC1G;QACH,QAAQ,EAAE,CAAC;aACR,MAAM,EAAE;aACR,QAAQ,EAAE;aACV,QAAQ,EAAE;aACV,QAAQ,CAAC,wBAAwB,CAAC;QACrC,WAAW,EAAE,CAAC;aACX,MAAM,EAAE;aACR,GAAG,CAAC,GAAG,CAAC;aACR,QAAQ,EAAE;aACV,QAAQ,EAAE;aACV,QAAQ,CACP,6HAA6H,CAC9H;QACH,SAAS,EAAE,CAAC;aACT,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;aACjB,GAAG,CAAC,GAAG,CAAC;aACR,QAAQ,EAAE;aACV,QAAQ,CAAC,+CAA+C,CAAC;QAC5D,WAAW,EAAE,CAAC;aACX,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;aACjB,GAAG,CAAC,GAAG,CAAC;aACR,QAAQ,EAAE;aACV,QAAQ,CACP,wEAAwE,CACzE;QACH,WAAW,EAAE,CAAC;aACX,KAAK,CAAC,gBAAgB,CAAC;aACvB,QAAQ,EAAE;aACV,QAAQ,CACP,oJAAoJ,CACrJ;KACJ,CAAC;IACF,GAAG,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE,CAAC,yBAAyB,CAAC,IAAI,CAAC;CACrD,CAAC,CAAC","sourcesContent":["import { defineAction } from \"@agent-native/core/action\";\nimport {\n getWorkspaceAppIdValidationError,\n normalizeWorkspaceAppId,\n} from \"@agent-native/core/shared\";\nimport { z } from \"zod\";\n\nimport { startWorkspaceAppCreation } from \"../server/lib/app-creation-store.js\";\n\nconst attachmentSchema = z.discriminatedUnion(\"type\", [\n z.object({\n type: z.literal(\"upload\"),\n contentType: z.enum([\n \"image/webp\",\n \"image/png\",\n \"image/jpeg\",\n \"image/gif\",\n \"application/pdf\",\n \"application/json\",\n \"text/plain\",\n ]),\n name: z.string().min(1),\n dataUrl: z.string(),\n text: z.string().optional(),\n id: z.string().min(1),\n }),\n z.object({\n type: z.literal(\"url\"),\n value: z.string().url(),\n }),\n]);\n\nexport type StartWorkspaceAppCreationAttachment = z.infer<\n typeof attachmentSchema\n>;\n\nexport default defineAction({\n description:\n 'Start creating a new workspace app from Dispatch when the request truly needs its own app. For Claude Web, ChatGPT Web, or either host\\'s web Project, this action is the Builder handoff: call it after forming a bounded source brief and do not scaffold or edit files in the host sandbox. This handoff is autonomous once the brief exists: do not ask the user for non-blocking product or UX choices; choose recommended defaults and let Builder record assumptions while it implements. Callers should include a concise generated description by default; Dispatch generates one from the prompt when omitted. In local dev this returns a code-agent prompt; in production it reuses the connected Agent-Native workspace project or, for an organization owner/admin, provisions it through the Builder Projects API before starting the Builder Cloud Agent branch. If no project is configured, organization members must ask an owner/admin to configure it first. The result must be a separate workspace app under apps/<app-id>, not a new route or file in apps/chat. If chat is used as the source template, the finished app must be branded as the requested app and must not leave visible \"Chat\", \"Starter\", \"Blank app\", or \"New app\" UI behind. If the request needs Mail, Calendar, Analytics, Brain, Assets, or another first-party app, use the existing hosted/connected app via links or A2A; do not wrap or nest those apps inside the new app unless the user explicitly asks for a customized app from that template.',\n schema: z.object({\n prompt: z.string().min(1).describe(\"The user's app creation request\"),\n appId: z\n .string()\n .max(64)\n .transform(normalizeWorkspaceAppId)\n .refine((appId) => !getWorkspaceAppIdValidationError(appId), {\n message:\n \"Use a non-reserved app id with lowercase letters, numbers, and hyphens.\",\n })\n .optional()\n .nullable()\n .describe(\n \"Desired workspace app id/path or human-friendly name. Names are converted to lowercase, hyphenated ids.\",\n ),\n template: z\n .string()\n .optional()\n .nullable()\n .describe(\"Template to start from\"),\n description: z\n .string()\n .max(500)\n .optional()\n .nullable()\n .describe(\n \"Concise AI-generated description of the app based on the user's prompt. Dispatch saves this while the app is being created.\",\n ),\n secretIds: z\n .array(z.string())\n .max(100)\n .optional()\n .describe(\"Dispatch vault secret IDs to grant to the app\"),\n resourceIds: z\n .array(z.string())\n .max(100)\n .optional()\n .describe(\n \"Dispatch workspace resource IDs or knowledge packs to grant to the app\",\n ),\n attachments: z\n .array(attachmentSchema)\n .optional()\n .describe(\n \"Optional Builder message attachments. Uploads use supported image, PDF, text, or JSON content; attachments are model context, not workspace files.\",\n ),\n }),\n run: async (args) => startWorkspaceAppCreation(args),\n});\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"app-creation-store.d.ts","sourceRoot":"","sources":["../../../src/server/lib/app-creation-store.ts"],"names":[],"mappings":"AAYA,OAAO,EAYL,KAAK,sBAAsB,EAC5B,MAAM,2BAA2B,CAAC;AAOnC,OAAO,EAML,KAAK,mBAAmB,EACzB,MAAM,2BAA2B,CAAC;AAGnC,OAAO,mBAAmB,CAAC;AA0G3B,KAAK,oBAAoB,GAAG,UAAU,GAAG,QAAQ,CAAC;AAClD,KAAK,sBAAsB,GAAG,SAAS,GAAG,KAAK,CAAC;AAEhD,MAAM,WAAW,mBAAmB;IAClC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;IACnB,UAAU,EAAE,OAAO,CAAC;IACpB,QAAQ,EAAE,oBAAoB,CAAC;IAC/B,WAAW,EAAE,MAAM,EAAE,CAAC;IACtB,cAAc,EAAE,MAAM,EAAE,CAAC;IACzB,MAAM,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAC7B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,UAAU,CAAC,EAAE,M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AAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,EAAE,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;IACvB,WAAW,CAAC,EAAE,sBAAsB,EAAE,CAAC;CACxC,GAAG,OAAO,CAAC,+BAA+B,CAAC,CAgM3C"}
@@ -4,9 +4,10 @@ import path from "node:path";
4
4
  import { fileURLToPath } from "node:url";
5
5
  import { canonicalA2AAudience, signA2AToken } from "@agent-native/core/a2a";
6
6
  import { isActionContractError } from "@agent-native/core/action";
7
+ import { describeErrorWithCauses } from "@agent-native/core/agent/engine/error-detail";
7
8
  import { getDbExec } from "@agent-native/core/db";
8
9
  import { getOrgDomain, isWorkspaceAppAccessAllowed, } from "@agent-native/core/org";
9
- import { CredentialStoreUnavailableError, FeatureNotConfiguredError, createBuilderProject, getBuilderBranchProjectId, getRequestContext, inferWorkspaceAppRootHomePath, isIntegrationCallerRequest, readConfiguredWorkspaceAppHomePath, resolveAppRuntimeUrl, resolveVercelDeploymentProtectionHeaders, runBuilderAgent, } from "@agent-native/core/server";
10
+ import { CredentialStoreUnavailableError, FeatureNotConfiguredError, createBuilderProject, getBuilderBranchProjectId, getRequestContext, inferWorkspaceAppRootHomePath, isIntegrationCallerRequest, readConfiguredWorkspaceAppHomePath, resolveAppRuntimeUrl, resolveVercelDeploymentProtectionHeaders, normalizeBuilderAgentAttachments, runBuilderAgent, } from "@agent-native/core/server";
10
11
  import { getOrgSetting } from "@agent-native/core/settings";
11
12
  import { getSetting, mutateSetting, putSetting, } from "@agent-native/core/settings";
12
13
  import { BUILDER_CONNECT_PROVIDER, BUILDER_CONNECT_PROVIDER_LABEL, assertValidWorkspaceAppId, connectRequiredResult, normalizeWorkspaceAppHomePath, } from "@agent-native/core/shared";
@@ -2156,6 +2157,12 @@ function builderUnavailable(input) {
2156
2157
  const detail = input.err instanceof Error && input.err.message
2157
2158
  ? input.err.message
2158
2159
  : input.fallbackDetail;
2160
+ console.warn("[dispatch] workspace app creation unavailable", {
2161
+ appId: input.appId,
2162
+ projectId: input.projectId,
2163
+ reason,
2164
+ error: describeErrorWithCauses(input.err),
2165
+ });
2159
2166
  const base = {
2160
2167
  mode: "builder-unavailable",
2161
2168
  appId: input.appId,
@@ -2193,10 +2200,15 @@ export async function startWorkspaceAppCreation(input) {
2193
2200
  });
2194
2201
  assertValidWorkspaceAppId(initial.appId);
2195
2202
  requireWorkspaceAppOrgId();
2203
+ normalizeBuilderAgentAttachments(input.attachments);
2196
2204
  const isLocal = isLocalAppCreationRuntime();
2197
2205
  if (!isLocal) {
2198
2206
  const authorization = await remoteAppCreationAuthorization();
2199
2207
  if (authorization.ok === false) {
2208
+ console.warn("[dispatch] workspace app creation not authorized", {
2209
+ appId: initial.appId,
2210
+ reason: authorization.reason,
2211
+ });
2200
2212
  return {
2201
2213
  mode: "builder-unavailable",
2202
2214
  appId: initial.appId,
@@ -2264,6 +2276,7 @@ export async function startWorkspaceAppCreation(input) {
2264
2276
  }
2265
2277
  catch (err) {
2266
2278
  if (err instanceof AppCreationSettingsAuthorizationError) {
2279
+ console.warn("[dispatch] workspace app creation needs an owner or admin to configure the Builder project", { appId: built.appId });
2267
2280
  return {
2268
2281
  mode: "builder-unavailable",
2269
2282
  appId: built.appId,