@bakers-build/addon-remote-drupal 0.6.1-next.5 → 0.6.1-next.6

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.
@@ -1,4 +1,4 @@
1
- import type { ActiveRun, AddonDefinitionV2, AddonRegistration, BbRemote, ClaimedRun, ClaimOptions, ClaimWithheld, ConductorRegistration, ConductorStatus, FinalizableRun, FrozenTicket, InboxSnapshot, RemotePlugin, RunMetrics, RunWriteAttributes, Ticket, TicketMetric, UncleanTicket } from '@bakers-build/conductor/contract';
1
+ import type { ActiveRun, AddonDefinitionV2, AddonRegistration, BbRemote, ClaimedRun, ClaimOptions, ClaimWithheld, ConductorRegistration, ConductorStatus, FinalizableRun, FrozenTicket, InboxSnapshot, RemotePlugin, RunMetrics, RunWriteAttributes, SiteToolClient, Ticket, TicketMetric, UncleanTicket } from '@bakers-build/conductor/contract';
2
2
  import type { MessageResult } from '@bakers-build/message';
3
3
  export { AmbiguousProjectNameError, ConductorTakeoverRequired, } from '@bakers-build/conductor/contract';
4
4
  export { createRunLogHttp, RunLogSizeError } from './run-log-http.js';
@@ -36,6 +36,7 @@ export declare class DrupalBbRemote implements BbRemote {
36
36
  private readonly selection?;
37
37
  private readonly resolvedProjectId?;
38
38
  private readonly fetchRunLog;
39
+ siteTools?: SiteToolClient;
39
40
  constructor(api: JsonApiClient, selection?: BbProjectSelection | undefined, resolvedProjectId?: string | undefined, fetchRunLog?: RunLogFetcher);
40
41
  fetchActiveRuns(id: string): Promise<ActiveRun[]>;
41
42
  activeRunCount(id: string): Promise<number>;
package/dist/src/index.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { createBbConnectionContext, toUnixSeconds } from '@bakers-build/core';
2
+ import { createToolClient } from '@dropsh/plugin-tool';
2
3
  import { AmbiguousProjectNameError, ConductorTakeoverRequired, resolveBbProjectContext, } from '@bakers-build/conductor/contract';
3
4
  export { AmbiguousProjectNameError, ConductorTakeoverRequired, } from '@bakers-build/conductor/contract';
4
5
  export { createRunLogHttp, RunLogSizeError } from './run-log-http.js';
@@ -60,6 +61,7 @@ export class DrupalBbRemote {
60
61
  selection;
61
62
  resolvedProjectId;
62
63
  fetchRunLog;
64
+ siteTools;
63
65
  constructor(api, selection, resolvedProjectId, fetchRunLog = throwingRunLogFetcher) {
64
66
  this.api = api;
65
67
  this.selection = selection;
@@ -828,7 +830,14 @@ export function drupalRemote() {
828
830
  }, {
829
831
  http: createRunLogHttp(config.site.base_url, config.site.jsonapi_prefix),
830
832
  });
831
- return new DrupalBbRemote(context.client, config.bakers, config.resolved_bakers?.projectId, createRunLogFetcher(context.http, context.auth, context.baseUrl));
833
+ const remote = new DrupalBbRemote(context.client, config.bakers, config.resolved_bakers?.projectId, createRunLogFetcher(context.http, context.auth, context.baseUrl));
834
+ // The site's tools for agent runs, on the same auth profile: the run never holds it.
835
+ remote.siteTools = createToolClient({
836
+ auth: context.auth,
837
+ baseUrl: context.baseUrl,
838
+ endpoint: '/mcp',
839
+ });
840
+ return remote;
832
841
  },
833
842
  };
834
843
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bakers-build/addon-remote-drupal",
3
- "version": "0.6.1-next.5",
3
+ "version": "0.6.1-next.6",
4
4
  "description": "bakers.build conductor remote addon: the Drupal/JSON:API control-plane remote.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -20,15 +20,16 @@
20
20
  "directory": "bakers-cli/addons/remote-drupal"
21
21
  },
22
22
  "dependencies": {
23
+ "@dropsh/plugin-tool": "^0.8.2",
23
24
  "dropsh": "^0.8.2"
24
25
  },
25
26
  "peerDependencies": {
26
- "@bakers-build/conductor": "^0.6.1-next.5",
27
- "@bakers-build/core": "^0.6.1-next.5",
28
- "@bakers-build/message": "^0.6.1-next.5"
27
+ "@bakers-build/conductor": "^0.6.1-next.6",
28
+ "@bakers-build/core": "^0.6.1-next.6",
29
+ "@bakers-build/message": "^0.6.1-next.6"
29
30
  },
30
31
  "bakersBuild": {
31
- "commit": "314f28982940df736bea55293a81435d37864b31",
32
+ "commit": "12b97ff4aa2422d69dab286141f3234609f32351",
32
33
  "channel": "next"
33
34
  }
34
35
  }