@agiflowai/agent-cli 0.2.17 → 0.2.18

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,5 +1,11 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.2.18
4
+ - Fix config context.
5
+
6
+ ## 0.2.17
7
+ - Fix build issue.
8
+
3
9
  ## 0.2.16
4
10
  - Fix terminal size data schema.
5
11
 
package/dist/cli.js CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { bx as z, bn as H, by as P, bo as M } from "./index-BN8T7DlD.mjs";
2
+ import { bx as z, bn as H, by as P, bo as M } from "./index-BvnfhTPZ.mjs";
3
3
  import Q from "node:events";
4
4
  import X from "node:child_process";
5
5
  import Z from "node:path";
package/dist/daemon.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { jsx as e, jsxs as i, Fragment as F } from "react/jsx-runtime";
2
- import { bj as f, bk as V, bl as Y, bm as $, bn as S, bo as D, bp as X, bq as H, br as J, bs as Z, bt as ee, bu as re, bv as ne, bw as oe } from "./index-BN8T7DlD.mjs";
2
+ import { bj as f, bk as V, bl as Y, bm as $, bn as S, bo as D, bp as X, bq as H, br as J, bs as Z, bt as ee, bu as re, bv as ne, bw as oe } from "./index-BvnfhTPZ.mjs";
3
3
  import { useQueryClient as ie, useQuery as te, useMutation as M, QueryClientProvider as ce, QueryClient as le } from "@tanstack/react-query";
4
4
  import { useDispatch as de, useSelector as u, shallowEqual as ae, Provider as se } from "react-redux";
5
5
  import P, { useRef as L, useEffect as _, useState as C, useCallback as ue, useMemo as he } from "react";
@@ -1,4 +1,4 @@
1
- import { am as s, al as t, ad as o, ai as c, ah as S, a4 as m, a8 as r, ak as n, ac as h, aa as g, ap as l, ab as p, ag as M, an as P, aj as T, a9 as u, a5 as i, ae as C, af as v, a7 as I, a6 as d, ao as x, aq as A, ar as R, at as f, as as q, au as V } from "./index-BN8T7DlD.mjs";
1
+ import { am as s, al as t, ad as o, ai as c, ah as S, a4 as m, a8 as r, ak as n, ac as h, aa as g, ap as l, ab as p, ag as M, an as P, aj as T, a9 as u, a5 as i, ae as C, af as v, a7 as I, a6 as d, ao as x, aq as A, ar as R, at as f, as as q, au as V } from "./index-BvnfhTPZ.mjs";
2
2
  export {
3
3
  s as AgentMessageCreateSchema,
4
4
  t as AgentMessageTypeSchema,
@@ -28,4 +28,4 @@ export {
28
28
  q as createTextPart,
29
29
  V as createToolInvocationInput
30
30
  };
31
- //# sourceMappingURL=index-3ecCYMRh.mjs.map
31
+ //# sourceMappingURL=index-Ba8ZwafA.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-Ba8ZwafA.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -20628,7 +20628,7 @@ let Nc = class {
20628
20628
  const t = this.agentConfigService.getStoredAgentSessionId();
20629
20629
  if (t)
20630
20630
  try {
20631
- const { createGetAgentStatus: e } = await Promise.resolve().then(() => GA), { createSendAgentStatus: r } = await Promise.resolve().then(() => zT), { AGENT_STATUS: i } = await import("./index-D1ws4p69.mjs"), n = e(t, t), a = (await this.multiplexClient.request(n))?.payload?.result || i.IDLE;
20631
+ const { createGetAgentStatus: e } = await Promise.resolve().then(() => GA), { createSendAgentStatus: r } = await Promise.resolve().then(() => zT), { AGENT_STATUS: i } = await import("./index-CkE7X3P2.mjs"), n = e(t, t), a = (await this.multiplexClient.request(n))?.payload?.result || i.IDLE;
20632
20632
  await this.multiplexClient.publish(
20633
20633
  r(t, {
20634
20634
  agentType: this.agentConfigService.getAgentType() ?? void 0,
@@ -20834,10 +20834,10 @@ let Bc = class {
20834
20834
  return this.wsOptions;
20835
20835
  }
20836
20836
  /**
20837
- * Get API URL from HTTP options
20837
+ * Get API URL from HTTP options or agent config
20838
20838
  */
20839
20839
  getApiUrl() {
20840
- return this.httpOptions?.apiUrl;
20840
+ return this.httpOptions?.apiUrl || this.agentConfig?.apiUrl;
20841
20841
  }
20842
20842
  /**
20843
20843
  * Get agent session ID
@@ -20876,10 +20876,10 @@ let Bc = class {
20876
20876
  return this.httpOptions?.agentTypeId;
20877
20877
  }
20878
20878
  /**
20879
- * Get server URL from WebSocket options
20879
+ * Get server URL from WebSocket options or agent config
20880
20880
  */
20881
20881
  getServerUrl() {
20882
- return this.wsOptions?.serverUrl;
20882
+ return this.wsOptions?.serverUrl || this.agentConfig?.serverUrl;
20883
20883
  }
20884
20884
  /**
20885
20885
  * Get reconnect interval from WebSocket options
@@ -22661,7 +22661,7 @@ let ws = class {
22661
22661
  * Middleware layers wrap around this with setup (BEFORE) and cleanup (AFTER)
22662
22662
  */
22663
22663
  async launchPty(t) {
22664
- const { AGENT_STATUS: e } = await import("./index-D1ws4p69.mjs"), r = t.metadata.agentCommand, i = t.metadata.agentArgs;
22664
+ const { AGENT_STATUS: e } = await import("./index-CkE7X3P2.mjs"), r = t.metadata.agentCommand, i = t.metadata.agentArgs;
22665
22665
  if (!r)
22666
22666
  throw new Error("launchPty requires metadata.agentCommand to be set by middleware");
22667
22667
  const n = await this.getAgentEnvironmentVariablesForContext(t);
@@ -23890,7 +23890,7 @@ class n$ extends Ob {
23890
23890
  if (!e.length) return;
23891
23891
  const i = (/* @__PURE__ */ new Date()).toISOString();
23892
23892
  try {
23893
- const { createSelectComponent: n, createToolInvocationInput: o } = await import("./index-3ecCYMRh.mjs"), { createRequestApproval: s } = await Promise.resolve().then(() => Yi), a = e.map((m) => ({ label: m.text, value: m.number, selected: !!m.selected })), u = n(a), c = o(!1, u), l = s(r.agentSessionId, {
23893
+ const { createSelectComponent: n, createToolInvocationInput: o } = await import("./index-Ba8ZwafA.mjs"), { createRequestApproval: s } = await Promise.resolve().then(() => Yi), a = e.map((m) => ({ label: m.text, value: m.number, selected: !!m.selected })), u = n(a), c = o(!1, u), l = s(r.agentSessionId, {
23894
23894
  toolName: "selectOption",
23895
23895
  toolArgs: { timestamp: i, options: a },
23896
23896
  input: c
@@ -43912,4 +43912,4 @@ export {
43912
43912
  YC as y,
43913
43913
  LC as z
43914
43914
  };
43915
- //# sourceMappingURL=index-BN8T7DlD.mjs.map
43915
+ //# sourceMappingURL=index-BvnfhTPZ.mjs.map