@botpress/adk 1.3.8 → 1.3.10

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.
@@ -2,7 +2,8 @@ export declare class AgentProjectGenerator {
2
2
  private projectPath;
3
3
  private projectName;
4
4
  private packageManager;
5
- constructor(projectPath: string, packageManager?: string);
5
+ private template;
6
+ constructor(projectPath: string, packageManager?: string, template?: string);
6
7
  generate(): Promise<void>;
7
8
  private ensureEmptyDirectory;
8
9
  private createPackageJson;
@@ -1 +1 @@
1
- {"version":3,"file":"agent-project-generator.d.ts","sourceRoot":"","sources":["../../src/agent-init/agent-project-generator.ts"],"names":[],"mappings":"AAQA,qBAAa,qBAAqB;IAChC,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,cAAc,CAAS;gBAEnB,WAAW,EAAE,MAAM,EAAE,cAAc,GAAE,MAAc;IAMzD,QAAQ,IAAI,OAAO,CAAC,IAAI,CAAC;IAY/B,OAAO,CAAC,oBAAoB;IAe5B,OAAO,CAAC,iBAAiB;IA4BzB,OAAO,CAAC,sBAAsB;YAQhB,iBAAiB;IAoB/B,OAAO,CAAC,cAAc;IA2BtB,OAAO,CAAC,eAAe;IAKvB,OAAO,CAAC,eAAe;YAqCT,YAAY;YA8CZ,qBAAqB;IAkCnC,OAAO,CAAC,SAAS;YAKH,kBAAkB;IAQhC,OAAO,CAAC,aAAa;CAGtB"}
1
+ {"version":3,"file":"agent-project-generator.d.ts","sourceRoot":"","sources":["../../src/agent-init/agent-project-generator.ts"],"names":[],"mappings":"AAQA,qBAAa,qBAAqB;IAChC,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,cAAc,CAAS;IAC/B,OAAO,CAAC,QAAQ,CAAS;gBAEb,WAAW,EAAE,MAAM,EAAE,cAAc,GAAE,MAAc,EAAE,QAAQ,GAAE,MAAgB;IAOrF,QAAQ,IAAI,OAAO,CAAC,IAAI,CAAC;IAY/B,OAAO,CAAC,oBAAoB;IAe5B,OAAO,CAAC,iBAAiB;IA4BzB,OAAO,CAAC,sBAAsB;YAQhB,iBAAiB;IA2B/B,OAAO,CAAC,cAAc;IA2BtB,OAAO,CAAC,eAAe;IAKvB,OAAO,CAAC,eAAe;YAqCT,YAAY;YA8CZ,qBAAqB;IAqDnC,OAAO,CAAC,SAAS;YAKH,kBAAkB;IAQhC,OAAO,CAAC,aAAa;CAGtB"}
@@ -1,4 +1,4 @@
1
- import { AssetFile, LocalAssetFile, AssetSyncPlan, AssetSyncResult, AssetSyncOptions, AssetsIndex } from './types.js';
1
+ import { AssetFile, LocalAssetFile, AssetSyncPlan, AssetSyncResult, AssetSyncOptions, AssetsIndex } from "./types.js";
2
2
  export interface AssetManagerOptions {
3
3
  projectPath: string;
4
4
  botId?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"manager.d.ts","sourceRoot":"","sources":["../../src/assets/manager.ts"],"names":[],"mappings":"AAKA,OAAO,EACL,SAAS,EACT,cAAc,EACd,aAAa,EACb,eAAe,EAGf,gBAAgB,EAChB,WAAW,EACZ,MAAM,YAAY,CAAC;AAGpB,MAAM,WAAW,mBAAmB;IAClC,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,qBAAa,aAAa;IACxB,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,UAAU,CAAS;IAC3B,OAAO,CAAC,MAAM,CAAC,CAAS;IACxB,OAAO,CAAC,KAAK,CAAC,CAAS;IACvB,OAAO,CAAC,WAAW,CAAC,CAAS;IAC7B,OAAO,CAAC,YAAY,CAAqB;gBAE7B,OAAO,EAAE,mBAAmB;YAQ1B,SAAS;IAyBvB,OAAO,CAAC,WAAW;IASnB;;OAEG;IACG,kBAAkB,IAAI,OAAO,CAAC,OAAO,CAAC;IAS5C;;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OAEG;IACG,cAAc,IAAI,OAAO,CAAC,cAAc,EAAE,CAAC;IAuCjD;;OAEG;IACG,eAAe,IAAI,OAAO,CAAC,SAAS,EAAE,CAAC;IA8B7C;;OAEG;IACG,cAAc,IAAI,OAAO,CAAC,aAAa,CAAC;IA6E9C;;OAEG;IACG,WAAW,CACf,IAAI,EAAE,aAAa,EACnB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,eAAe,CAAC;IAyE3B;;OAEG;YACW,WAAW;IAsBzB;;OAEG;IACG,aAAa,IAAI,OAAO,CAAC,MAAM,CAAC;IAqCtC;;OAEG;IACG,iBAAiB,IAAI,OAAO,CAAC,WAAW,CAAC;IAW/C;;;OAGG;IACG,sBAAsB,IAAI,OAAO,CAAC,SAAS,EAAE,CAAC;YAgEtC,aAAa;IAoB3B,OAAO,CAAC,aAAa;IAIrB,OAAO,CAAC,WAAW;CA4BpB"}
@@ -1 +1 @@
1
- {"version":3,"file":"service.d.ts","sourceRoot":"","sources":["../../src/auth/service.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,UAAU;IACzB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,qBAAa,WAAW;IACtB,OAAO,CAAC,MAAM,CAAS;gBAEX,MAAM,CAAC,EAAE,MAAM;IAIrB,aAAa,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,CAAC;IAuDjD,cAAc,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;CAQtD"}
1
+ {"version":3,"file":"service.d.ts","sourceRoot":"","sources":["../../src/auth/service.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,UAAU;IACzB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,qBAAa,WAAW;IACtB,OAAO,CAAC,MAAM,CAAS;gBAEX,MAAM,CAAC,EAAE,MAAM;IAIrB,aAAa,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,CAAC;IA0DjD,cAAc,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;CAQtD"}
@@ -1 +1 @@
1
- {"version":3,"file":"dev-id-manager.d.ts","sourceRoot":"","sources":["../../src/bot-generator/dev-id-manager.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAEzD,MAAM,WAAW,YAAY;IAC3B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,qBAAa,YAAY;IACvB,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,cAAc,CAAS;IAC/B,OAAO,CAAC,gBAAgB,CAAS;IACjC,OAAO,CAAC,MAAM,CAAC,CAAS;gBAEZ,WAAW,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM;YAUzC,SAAS;IAwBjB,UAAU,IAAI,OAAO,CAAC,YAAY,CAAC;IAInC,gBAAgB,IAAI,OAAO,CAAC,YAAY,CAAC;IAYzC,gBAAgB,CAAC,KAAK,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC;IAWpD,aAAa,IAAI,OAAO,CAAC,IAAI,CAAC;IAuB9B,YAAY,IAAI,OAAO,CAAC,IAAI,CAAC;IAqB7B,iBAAiB,IAAI,OAAO,CAAC,OAAO,CAAC;CAoB5C"}
1
+ {"version":3,"file":"dev-id-manager.d.ts","sourceRoot":"","sources":["../../src/bot-generator/dev-id-manager.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAEzD,MAAM,WAAW,YAAY;IAC3B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,qBAAa,YAAY;IACvB,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,cAAc,CAAS;IAC/B,OAAO,CAAC,gBAAgB,CAAS;IACjC,OAAO,CAAC,MAAM,CAAC,CAAS;gBAEZ,WAAW,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM;YAUzC,SAAS;IA2BjB,UAAU,IAAI,OAAO,CAAC,YAAY,CAAC;IAInC,gBAAgB,IAAI,OAAO,CAAC,YAAY,CAAC;IAYzC,gBAAgB,CAAC,KAAK,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC;IAWpD,aAAa,IAAI,OAAO,CAAC,IAAI,CAAC;IAuB9B,YAAY,IAAI,OAAO,CAAC,IAAI,CAAC;IAqB7B,iBAAiB,IAAI,OAAO,CAAC,OAAO,CAAC;CAoB5C"}
@@ -1 +1 @@
1
- {"version":3,"file":"generator.d.ts","sourceRoot":"","sources":["../../src/bot-generator/generator.ts"],"names":[],"mappings":"AA8BA,MAAM,WAAW,mBAAmB;IAClC,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,SAAS,GAAG,WAAW,GAAG,YAAY,CAAC;CACrD;AAMD,qBAAa,YAAY;IACvB,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,UAAU,CAAS;gBAEf,OAAO,EAAE,mBAAmB;YAO1B,k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oUrB,gBAAgB;YAoDhB,mBAAmB;YAwBnB,gBAAgB;YA0ChB,mBAAmB;YA4BnB,UAAU;YAWV,aAAa;IAgBrB,kBAAkB,IAAI,OAAO,CAAC,IAAI,CAAC;IAocnC,iBAAiB,IAAI,OAAO,CAAC,IAAI,CAAC;CAczC;AAED,wBAAsB,kBAAkB,CACtC,OAAO,EAAE,mBAAmB,GAC3B,OAAO,CAAC,IAAI,CAAC,CA0Cf"}
@@ -1 +1 @@
1
- {"version":3,"file":"tests.d.ts","sourceRoot":"","sources":["../../src/generators/tests.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,oBAAoB,GAAI,aAAa,MAAM,EAAE,SAAS,MAAM,oDAiBrE,CAAC;AAEL,eAAO,MAAM,kBAAkB,GAAI,KAAK,MAAM,EAAE,SAAS,MAAM;;;;;;;;iBAeyni5B,CAAC;uBAA0H,CAAC;;;;;;;;iBAAuU,CAAC;uBAAyH,CAAC;;;;sBAAsM,CAAC;;;;;;;iBAA6S,CAAC;uBAA0H,CAAC;oBAAkC,CAAC;qBAAoC,CAAC;;;;;;;;;;;sBAA2Y,CAAC;;;;;;;iBAA8O,CAAC;uBAA2H,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAAj73M,CAAC;uBAA0H,CAAC;;;;;;;;iBAAuU,CAAC;uBAAyH,CAAC;;;;sBAAsM,CAAC;;;;;;;iBAA6S,CAAC;uBAA0H,CAAC;oBAAkC,CAAC;qBAAoC,CAAC;;;;;;;;;;;sBAA2Y,CAAC;;;;;;;iBAA8O,CAAC;uBAA2H,CAAC;;;;;;;;;;;;;;;;;;;;;;EAD7tysB,CAAC"}
1
+ {"version":3,"file":"tests.d.ts","sourceRoot":"","sources":["../../src/generators/tests.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,oBAAoB,GAAI,aAAa,MAAM,EAAE,SAAS,MAAM,oDAiBrE,CAAC;AAEL,eAAO,MAAM,kBAAkB,GAAI,KAAK,MAAM,EAAE,SAAS,MAAM;;;;;;;;iBAkBoji5B,CAAC;uBAA0H,CAAC;;;;;;;;iBAAuU,CAAC;uBAAyH,CAAC;;;;sBAAsM,CAAC;;;;;;;iBAA6S,CAAC;uBAA0H,CAAC;oBAAkC,CAAC;qBAAoC,CAAC;;;;;;;;;;;sBAA2Y,CAAC;;;;;;;iBAA8O,CAAC;uBAA2H,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAAj73M,CAAC;uBAA0H,CAAC;;;;;;;;iBAAuU,CAAC;uBAAyH,CAAC;;;;sBAAsM,CAAC;;;;;;;iBAA6S,CAAC;uBAA0H,CAAC;oBAAkC,CAAC;qBAAoC,CAAC;;;;;;;;;;;sBAA2Y,CAAC;;;;;;;iBAA8O,CAAC;uBAA2H,CAAC;;;;;;;;;;;;;;;;;;;;;;EADxpysB,CAAC"}
package/dist/index.js CHANGED
@@ -367,7 +367,10 @@ class AuthService {
367
367
  try {
368
368
  const client = new Client({
369
369
  apiUrl: this.apiUrl,
370
- token
370
+ token,
371
+ headers: {
372
+ "x-multiple-integrations": "true"
373
+ }
371
374
  });
372
375
  const accountResponse = await client.getAccount({});
373
376
  const { account } = accountResponse;
@@ -1344,7 +1347,10 @@ class WorkspaceCache {
1344
1347
  const credentials = await auth.getActiveCredentials();
1345
1348
  const client = new Client2({
1346
1349
  apiUrl: credentials.apiUrl,
1347
- token: credentials.token
1350
+ token: credentials.token,
1351
+ headers: {
1352
+ "x-multiple-integrations": "true"
1353
+ }
1348
1354
  });
1349
1355
  const { workspaces } = await client.listWorkspaces({});
1350
1356
  const workspace = workspaces.find((ws) => ws.id === workspaceId);
@@ -1566,7 +1572,10 @@ class AssetsManager {
1566
1572
  token: credentials.token,
1567
1573
  apiUrl: credentials.apiUrl,
1568
1574
  workspaceId,
1569
- botId: this.botId
1575
+ botId: this.botId,
1576
+ headers: {
1577
+ "x-multiple-integrations": "true"
1578
+ }
1570
1579
  });
1571
1580
  }
1572
1581
  return this.client;
@@ -2434,10 +2443,14 @@ class IntegrationManager {
2434
2443
  if (!this.options.workspaceId && !credentials.workspaceId) {
2435
2444
  throw new Error('No workspace ID found in current profile. Please login again with "adk login"');
2436
2445
  }
2446
+ const workspaceId = this.options.workspaceId || credentials.workspaceId;
2437
2447
  this.client = new Client4({
2438
2448
  token: credentials.token,
2439
2449
  apiUrl: credentials.apiUrl,
2440
- workspaceId: this.options.workspaceId || credentials.workspaceId
2450
+ workspaceId,
2451
+ headers: {
2452
+ "x-multiple-integrations": "true"
2453
+ }
2441
2454
  });
2442
2455
  }
2443
2456
  return this.client;
@@ -2497,7 +2510,7 @@ class IntegrationManager {
2497
2510
  name: ref.fullName,
2498
2511
  version: ref.version
2499
2512
  });
2500
- } catch (_privateError) {
2513
+ } catch (privateError) {
2501
2514
  try {
2502
2515
  integrationResponse = await client.getPublicIntegration({
2503
2516
  name: ref.name,
@@ -2684,7 +2697,10 @@ class HubCache {
2684
2697
  this.client = new Client5({
2685
2698
  token: credentials.token,
2686
2699
  apiUrl: credentials.apiUrl,
2687
- workspaceId: credentials.workspaceId
2700
+ workspaceId: credentials.workspaceId,
2701
+ headers: {
2702
+ "x-multiple-integrations": "true"
2703
+ }
2688
2704
  });
2689
2705
  }
2690
2706
  return this.client;
@@ -2837,7 +2853,10 @@ class IntegrationOperations {
2837
2853
  this.client = new Client6({
2838
2854
  token: credentials.token,
2839
2855
  apiUrl: credentials.apiUrl,
2840
- workspaceId
2856
+ workspaceId,
2857
+ headers: {
2858
+ "x-multiple-integrations": "true"
2859
+ }
2841
2860
  });
2842
2861
  }
2843
2862
  return this.client;
@@ -2923,7 +2942,9 @@ class IntegrationOperations {
2923
2942
  }
2924
2943
  let integrationDefinition;
2925
2944
  try {
2926
- const tempManager = new IntegrationManager;
2945
+ const tempManager = new IntegrationManager({
2946
+ workspaceId: project.agentInfo?.workspaceId
2947
+ });
2927
2948
  const loadResult = await tempManager.loadIntegrations({
2928
2949
  integrations: {
2929
2950
  [alias]: {
@@ -3105,7 +3126,10 @@ class IntegrationChecker {
3105
3126
  this.client = new Client7({
3106
3127
  token: credentials.token,
3107
3128
  apiUrl: credentials.apiUrl,
3108
- workspaceId
3129
+ workspaceId,
3130
+ headers: {
3131
+ "x-multiple-integrations": "true"
3132
+ }
3109
3133
  });
3110
3134
  }
3111
3135
  return this.client;
@@ -3127,7 +3151,9 @@ class IntegrationChecker {
3127
3151
  async checkIntegrations(botId) {
3128
3152
  const client = await this.getClient();
3129
3153
  const project = await AgentProject.load(this.projectPath);
3130
- const integrationManager = new IntegrationManager;
3154
+ const integrationManager = new IntegrationManager({
3155
+ workspaceId: project.agentInfo?.workspaceId
3156
+ });
3131
3157
  const loadResult = await integrationManager.loadIntegrations(project.dependencies || { integrations: {} });
3132
3158
  if (loadResult.errors.length > 0) {
3133
3159
  throw new Error(`Failed to load integrations: ${loadResult.errors.map((e) => e.message).join(", ")}`);
@@ -3433,7 +3459,10 @@ class InterfaceManager {
3433
3459
  this.client = new Client8({
3434
3460
  token: credentials.token,
3435
3461
  apiUrl: credentials.apiUrl,
3436
- workspaceId: this.options.workspaceId || credentials.workspaceId
3462
+ workspaceId: this.options.workspaceId || credentials.workspaceId,
3463
+ headers: {
3464
+ "x-multiple-integrations": "true"
3465
+ }
3437
3466
  });
3438
3467
  }
3439
3468
  return this.client;
@@ -4427,10 +4456,12 @@ class AgentProjectGenerator {
4427
4456
  projectPath;
4428
4457
  projectName;
4429
4458
  packageManager;
4430
- constructor(projectPath, packageManager = "bun") {
4459
+ template;
4460
+ constructor(projectPath, packageManager = "bun", template = "blank") {
4431
4461
  this.projectPath = path14.resolve(projectPath);
4432
4462
  this.projectName = path14.basename(this.projectPath);
4433
4463
  this.packageManager = packageManager;
4464
+ this.template = template;
4434
4465
  }
4435
4466
  async generate() {
4436
4467
  this.ensureEmptyDirectory();
@@ -4465,7 +4496,7 @@ class AgentProjectGenerator {
4465
4496
  deploy: "adk deploy"
4466
4497
  },
4467
4498
  dependencies: {
4468
- "@botpress/runtime": `^${"1.3.8"}`
4499
+ "@botpress/runtime": `^${"1.3.10"}`
4469
4500
  },
4470
4501
  devDependencies: {
4471
4502
  typescript: "^5.0.0"
@@ -4483,12 +4514,18 @@ class AgentProjectGenerator {
4483
4514
  this.writeJsonFile("dependencies.json", dependenciesJson);
4484
4515
  }
4485
4516
  async createAgentConfig() {
4517
+ const defaultModels = this.template === "hello-world" ? `
4518
+ defaultModels: {
4519
+ autonomous: "cerebras:gpt-oss-120b",
4520
+ zai: "cerebras:gpt-oss-120b",
4521
+ },
4522
+ ` : "";
4486
4523
  const agentConfig = `import { z, defineConfig } from '@botpress/runtime';
4487
4524
 
4488
4525
  export default defineConfig({
4489
4526
  name: '${this.projectName}',
4490
4527
  description: 'An AI agent built with Botpress ADK',
4491
-
4528
+ ${defaultModels}
4492
4529
  bot: {
4493
4530
  state: z.object({}),
4494
4531
  },
@@ -4617,7 +4654,21 @@ A Botpress Agent built with the ADK.
4617
4654
  for (const subdir of subdirectories) {
4618
4655
  const subdirPath = path14.join(srcPath, subdir);
4619
4656
  fs11.mkdirSync(subdirPath);
4620
- const placeholderContent = `/**
4657
+ if (subdir === "conversations" && this.template === "hello-world") {
4658
+ const conversationContent = `import { Conversation } from "@botpress/runtime";
4659
+
4660
+ export default new Conversation({
4661
+ channel: "*",
4662
+ handler: async ({ execute }) => {
4663
+ await execute({
4664
+ instructions: \`You are a helpful AI assistant built with Botpress ADK. You can assist users with their questions and tasks.\`,
4665
+ });
4666
+ },
4667
+ });
4668
+ `;
4669
+ await this.writeFormattedFile(path14.join("src", subdir, "index.ts"), conversationContent);
4670
+ } else {
4671
+ const placeholderContent = `/**
4621
4672
  * TODO: Add your ${subdir} here
4622
4673
  *
4623
4674
  * This is a placeholder file to initialize the ${subdir} directory.
@@ -4626,7 +4677,8 @@ A Botpress Agent built with the ADK.
4626
4677
 
4627
4678
  export default {};
4628
4679
  `;
4629
- await this.writeFormattedFile(path14.join("src", subdir, "index.ts"), placeholderContent);
4680
+ await this.writeFormattedFile(path14.join("src", subdir, "index.ts"), placeholderContent);
4681
+ }
4630
4682
  }
4631
4683
  }
4632
4684
  writeFile(relativePath, content) {
@@ -5498,7 +5550,10 @@ class DevIdManager {
5498
5550
  this.client = new Client9({
5499
5551
  token: credentials.token,
5500
5552
  apiUrl: credentials.apiUrl,
5501
- workspaceId
5553
+ workspaceId,
5554
+ headers: {
5555
+ "x-multiple-integrations": "true"
5556
+ }
5502
5557
  });
5503
5558
  }
5504
5559
  return this.client;
@@ -5924,7 +5979,9 @@ class BotGenerator {
5924
5979
  }
5925
5980
  async generateIntegrationsTypes() {
5926
5981
  const project = await AgentProject.load(this.projectPath);
5927
- const manager2 = new IntegrationManager;
5982
+ const manager2 = new IntegrationManager({
5983
+ workspaceId: project.agentInfo?.workspaceId
5984
+ });
5928
5985
  const integrations = await manager2.loadIntegrations(project.dependencies || {});
5929
5986
  const integrationsDir = path29.join(this.projectPath, ".adk", "integrations");
5930
5987
  const existingIntegrationFiles = await this.listFilesRecursive(integrationsDir);
@@ -6005,7 +6062,9 @@ class BotGenerator {
6005
6062
  }
6006
6063
  async generateRuntimeTypes() {
6007
6064
  const project = await AgentProject.load(this.projectPath);
6008
- const manager2 = new IntegrationManager;
6065
+ const manager2 = new IntegrationManager({
6066
+ workspaceId: project.agentInfo?.workspaceId
6067
+ });
6009
6068
  const integrations = await manager2.loadIntegrations(project.dependencies || {});
6010
6069
  const channels = [];
6011
6070
  for (const integration of integrations.integrations) {
@@ -6060,7 +6119,9 @@ declare module "@botpress/runtime/_types/state" {
6060
6119
  }
6061
6120
  async generateInterfacesTypes() {
6062
6121
  const project = await AgentProject.load(this.projectPath);
6063
- const integrationManager = new IntegrationManager;
6122
+ const integrationManager = new IntegrationManager({
6123
+ workspaceId: project.agentInfo?.workspaceId
6124
+ });
6064
6125
  const manager2 = new InterfaceManager;
6065
6126
  const interfacesDir = path29.join(this.projectPath, ".adk", "interfaces");
6066
6127
  const existingInterfaceFiles = await this.listFilesRecursive(interfacesDir);
@@ -6179,7 +6240,7 @@ declare module "@botpress/runtime/_types/state" {
6179
6240
  for (const { alias } of integrations.filter((i) => i.enabled)) {
6180
6241
  const importName = `integration_${getIntegrationAlias(alias)}`;
6181
6242
  imports.push(`import ${importName} from "./bp_modules/${importName}";`);
6182
- addIntegrations.push(`bot.addIntegration(${importName});`);
6243
+ addIntegrations.push(`bot.addIntegration(${importName}, { alias: "${alias}" });`);
6183
6244
  }
6184
6245
  const conversationTags = {};
6185
6246
  const workflowTags = {};
@@ -6909,7 +6970,10 @@ class TableManager {
6909
6970
  this.client = new Client10({
6910
6971
  token: credentials.token,
6911
6972
  apiUrl: credentials.apiUrl,
6912
- botId: this.botId
6973
+ botId: this.botId,
6974
+ headers: {
6975
+ "x-multiple-integrations": "true"
6976
+ }
6913
6977
  });
6914
6978
  }
6915
6979
  return this.client;
@@ -7277,5 +7341,5 @@ export {
7277
7341
  AgentProject
7278
7342
  };
7279
7343
 
7280
- //# debugId=89632232C9C87A3464756E2164756E21
7344
+ //# debugId=0C40DCD421270EAD64756E2164756E21
7281
7345
  //# sourceMappingURL=index.js.map