@kumion/cli 0.6.6 → 0.6.7
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/README.md +7 -1
- package/dist/client.js +20 -0
- package/dist/main.js +136 -1
- package/dist/mcp.js +73 -1
- package/package.json +1 -1
- package/skills/kumion/SKILL.md +2 -1
package/README.md
CHANGED
|
@@ -109,6 +109,11 @@ would use.
|
|
|
109
109
|
| `kumion agents publish <agentId> [--revision <rev>] [--accept-intermittent]` | `agents:publish` |
|
|
110
110
|
| `kumion agents opening-name <agentId> --revision <rev> (--on \| --off)` | `agents:write` (a draft write: live after the next publish) |
|
|
111
111
|
| `kumion agents availability <agentId> --revision <rev> [--operating-hours-file <path>] [--off-hours-file <path>]` | `agents:live` (live: no publish) |
|
|
112
|
+
| `kumion webcall get <agentId>` | `agents:read` |
|
|
113
|
+
| `kumion webcall update <agentId> [--ip <a,b,...>] [--embed <a,b,...>] [--title <t>] [--greeting <t>] [--accent <#RRGGBB>] [--quick-reply <t>]… [--launcher-label <t>] [--position right\|left] [--entry both\|voice\|text] [--logo <file> \| --remove-logo]` | `agents:live` (live: no publish) |
|
|
114
|
+
| `kumion widget-keys list` | `agents:read` (key ids and dates, never secrets) |
|
|
115
|
+
| `kumion widget-keys create` | `agents:live` (prints the secret once) |
|
|
116
|
+
| `kumion widget-keys revoke <keyId>` | `agents:live` (cannot be undone) |
|
|
112
117
|
| `kumion agents create-from-template --template <id> --business-name <name> [--name <name>] [--url <url> \| --document <documentId>] [--idempotency-key <key>]` | `agents:write` (a `url` makes it read an external site and call the model; the key makes a resend return the first agent) |
|
|
113
118
|
| `kumion agents capture get <agentId>` | `agents:read` |
|
|
114
119
|
| `kumion agents capture set <agentId> --revision <rev> (--spec <specId> ... \| --clear)` | `agents:live` (live: no publish) |
|
|
@@ -394,6 +399,7 @@ A key a node does not store follows the agent's setting (会話の運用) or the
|
|
|
394
399
|
| `first_word_wait_seconds` | start | `tune` | `number` | Seconds `wait_for_first_word` waits (1 to 10, default 3). Absent means the default. Read only when `wait_for_first_word` is true. |
|
|
395
400
|
| `respond_on_enter` | agent | `tune` | `boolean` | Absent means the node answers on arrival. Only an explicit false (wait for the caller) is stored. |
|
|
396
401
|
| `confirm_before_end` | agent | `tune` | `boolean` | Absent means off (agents published before this setting keep their behaviour); a node created on the canvas stores true, and a node compiled from a SOP or document stores true when its connection to an end node requires items (the `end_without_readback` rule). On: the platform reads the recorded items back once before the call ends, and the end opens on a later caller turn with caller_confirmed. |
|
|
402
|
+
| `notify_site` | agent | `tune` | `boolean` | Absent means off. On: a web call (website widget) tells the embedding page `node.entered { nodeKey, label }` each time the call enters this node. |
|
|
397
403
|
| `confirm_before_end_keys` | agent | `internal` | `string[]` | Set by the compiler on a 伝言 step. With `confirm_before_end` on, the end readback reads only these item keys (the call-back number); absent means every item the ending requires. |
|
|
398
404
|
| `entry_lookup` | agent | `tune` | `string` | Absent means no lookup on entry. A tool key from this step's tools (`booking_list`): the platform calls it when the call arrives at this step, and the call and its result are in the step's context before the AI speaks. |
|
|
399
405
|
| `quiet_wait` | start, agent | `tune` | `{ seconds, listen?, resume_speech? }` | Node-level wait. { seconds: 0 } turns the agent default off here. |
|
|
@@ -665,7 +671,7 @@ Two things are closed here on purpose:
|
|
|
665
671
|
`kumion mcp` serves the same operations as MCP tools over stdio, for Claude Code,
|
|
666
672
|
Codex or any other MCP host, one tool per command above: `list_agents`, `get_agent`,
|
|
667
673
|
`patch_agent`, `publish_agent`, `get_call_flow`, `update_call_flow`,
|
|
668
|
-
`edit_call_flow_steps`, `set_agent_opening_name`, `set_agent_availability`,
|
|
674
|
+
`edit_call_flow_steps`, `set_agent_opening_name`, `set_agent_availability`, `get_webcall_access`, `set_webcall_access`,
|
|
669
675
|
`create_agent_from_template`, `list_agent_templates`, `list_facts`, `edit_fact`,
|
|
670
676
|
`confirm_facts`, `list_staff`, `create_staff`, `update_staff`, `get_store_hours`,
|
|
671
677
|
`update_store_hours`, `set_store_hours_exception`, `get_booking_settings`,
|
package/dist/client.js
CHANGED
|
@@ -222,6 +222,26 @@ export class KumionClient {
|
|
|
222
222
|
});
|
|
223
223
|
return body;
|
|
224
224
|
}
|
|
225
|
+
async getWebcallAccess(agentId) {
|
|
226
|
+
const { body } = await this.request("GET", this.agentPath(agentId, "/webcall"), "agents:read");
|
|
227
|
+
return body;
|
|
228
|
+
}
|
|
229
|
+
async setWebcallAccess(agentId, patch) {
|
|
230
|
+
const { body } = await this.request("PATCH", this.agentPath(agentId, "/webcall"), "agents:live", { body: patch });
|
|
231
|
+
return body;
|
|
232
|
+
}
|
|
233
|
+
async listWidgetSigningKeys() {
|
|
234
|
+
const { body } = await this.request("GET", this.tenantPath("/widget-signing-keys"), "agents:read");
|
|
235
|
+
return body.keys;
|
|
236
|
+
}
|
|
237
|
+
async createWidgetSigningKey() {
|
|
238
|
+
const { body } = await this.request("POST", this.tenantPath("/widget-signing-keys"), "agents:live", { body: {} });
|
|
239
|
+
return body.key;
|
|
240
|
+
}
|
|
241
|
+
async revokeWidgetSigningKey(keyId) {
|
|
242
|
+
const { body } = await this.request("DELETE", this.tenantPath(`/widget-signing-keys/${encodeURIComponent(keyId)}`), "agents:live");
|
|
243
|
+
return body;
|
|
244
|
+
}
|
|
225
245
|
async listFacts(agentId) {
|
|
226
246
|
const { body } = await this.request("GET", this.agentPath(agentId, "/facts"), "agents:read");
|
|
227
247
|
return body.facts;
|
package/dist/main.js
CHANGED
|
@@ -6,7 +6,7 @@ import { ApiError, KumionClient, isTextFile, specText, } from "./client.js";
|
|
|
6
6
|
import { DEFAULT_BASE_URL, keyPrefix, looksLikeApiKey, normalizeBaseUrl, resolveCredentials, } from "./credentials.js";
|
|
7
7
|
import { DEFAULT_DEVICE_SCOPES, deviceLogin } from "./device-login.js";
|
|
8
8
|
import { describeError, ReportedFailure, UsageError } from "./errors.js";
|
|
9
|
-
export const VERSION = "0.6.
|
|
9
|
+
export const VERSION = "0.6.7";
|
|
10
10
|
const HELP = `kumion — manage your Kumion voice agents over the Partner API
|
|
11
11
|
|
|
12
12
|
Usage: kumion <command> [options]
|
|
@@ -45,6 +45,18 @@ Agents
|
|
|
45
45
|
call outside it. Each file holds the JSON of that setting, or
|
|
46
46
|
null to clear it. LIVE: callers get it at once, no publish
|
|
47
47
|
(needs a key with agents:live)
|
|
48
|
+
webcall get <agentId> Show the Webコール access limits (allowed IPs / embedding sites; empty = no limit)
|
|
49
|
+
webcall update <agentId> [--ip <a,b,...>] [--embed <a,b,...>] [--accent <#RRGGBB>] [--title <t>] [--greeting <t>]
|
|
50
|
+
[--quick-reply <t> (repeat, max 4)] [--launcher-label <t>] [--position right|left]
|
|
51
|
+
[--entry both|voice|text] [--logo <png|jpg|webp file> | --remove-logo]
|
|
52
|
+
(an empty value clears an appearance item back to the default)
|
|
53
|
+
Set them (comma-separated; "" clears). LIVE, no publish.
|
|
54
|
+
The IP list is what stops people opening the widget URL directly
|
|
55
|
+
(needs a key with agents:live)
|
|
56
|
+
widget-keys list List the keys your server signs website-widget visitor tokens with (no secrets)
|
|
57
|
+
widget-keys create Make a key. The secret is printed once and cannot be read again.
|
|
58
|
+
LIVE; at most 2 unrevoked keys per workspace (needs a key with agents:live)
|
|
59
|
+
widget-keys revoke <keyId> Stop accepting tokens signed with that key. Cannot be undone (agents:live)
|
|
48
60
|
agents create-from-template --template <id> --business-name <name> [--name <name>]
|
|
49
61
|
[--url <url> | --document <documentId>] [--idempotency-key <key>]
|
|
50
62
|
[--fallback-staff <contactKey>]
|
|
@@ -388,6 +400,11 @@ export const COMMANDS = {
|
|
|
388
400
|
"agents publish": agentsPublish,
|
|
389
401
|
"agents opening-name": agentsOpeningName,
|
|
390
402
|
"agents availability": agentsAvailability,
|
|
403
|
+
"webcall get": webcallGet,
|
|
404
|
+
"webcall update": webcallUpdate,
|
|
405
|
+
"widget-keys list": widgetKeysList,
|
|
406
|
+
"widget-keys create": widgetKeysCreate,
|
|
407
|
+
"widget-keys revoke": widgetKeysRevoke,
|
|
391
408
|
"agents create-from-template": agentsCreateFromTemplate,
|
|
392
409
|
"flow get": flowGet,
|
|
393
410
|
"flow update": flowUpdate,
|
|
@@ -768,6 +785,123 @@ async function agentsAvailability(args, deps) {
|
|
|
768
785
|
deps.io.out(`Saved and live now — no publish needed. New revision: ${view.revision}`);
|
|
769
786
|
return 0;
|
|
770
787
|
}
|
|
788
|
+
function splitList(v) {
|
|
789
|
+
return v.split(",").map((x) => x.trim()).filter(Boolean);
|
|
790
|
+
}
|
|
791
|
+
function webcallLines(w, deps) {
|
|
792
|
+
deps.io.out(`IP allowlist: ${w.accessIpAllowlist.length ? w.accessIpAllowlist.join(", ") : "(none — no limit)"}`);
|
|
793
|
+
deps.io.out(`Embed sites: ${w.embedOriginAllowlist.length ? w.embedOriginAllowlist.join(", ") : "(none — deployment default)"}`);
|
|
794
|
+
const shown = Object.entries(w.appearance ?? {}).filter(([, v]) => v !== undefined);
|
|
795
|
+
deps.io.out(`Appearance: ${shown.length ? shown.map(([k, v]) => `${k}=${Array.isArray(v) ? v.join(" | ") : String(v)}`).join("; ") : "(defaults)"}`);
|
|
796
|
+
deps.io.out(`Logo: ${w.hasLogo ? "set" : "(none)"}`);
|
|
797
|
+
}
|
|
798
|
+
async function webcallGet(args, deps) {
|
|
799
|
+
const { values, positionals } = parse(args, {});
|
|
800
|
+
const agentId = need(positionals, 0, "agentId");
|
|
801
|
+
const w = await (await clientFor(values, deps)).getWebcallAccess(agentId);
|
|
802
|
+
if (values.json)
|
|
803
|
+
printJson(deps, w);
|
|
804
|
+
else
|
|
805
|
+
webcallLines(w, deps);
|
|
806
|
+
return 0;
|
|
807
|
+
}
|
|
808
|
+
const LOGO_TYPES = { ".png": "image/png", ".jpg": "image/jpeg", ".jpeg": "image/jpeg", ".webp": "image/webp" };
|
|
809
|
+
async function widgetKeysList(args, deps) {
|
|
810
|
+
const { values } = parse(args, {});
|
|
811
|
+
const keys = await (await clientFor(values, deps)).listWidgetSigningKeys();
|
|
812
|
+
if (values.json)
|
|
813
|
+
printJson(deps, { keys });
|
|
814
|
+
else if (keys.length === 0)
|
|
815
|
+
deps.io.out("No signing keys.");
|
|
816
|
+
else
|
|
817
|
+
for (const k of keys) {
|
|
818
|
+
deps.io.out(`${k.id} ${k.revokedAt ? `revoked ${k.revokedAt}` : "active"} created ${k.createdAt} last used ${k.lastUsedAt ?? "never"}`);
|
|
819
|
+
}
|
|
820
|
+
return 0;
|
|
821
|
+
}
|
|
822
|
+
async function widgetKeysCreate(args, deps) {
|
|
823
|
+
const { values } = parse(args, {});
|
|
824
|
+
const key = await (await clientFor(values, deps)).createWidgetSigningKey();
|
|
825
|
+
if (values.json)
|
|
826
|
+
printJson(deps, { key });
|
|
827
|
+
else {
|
|
828
|
+
deps.io.out(`kid: ${key.id}`);
|
|
829
|
+
deps.io.out(`secret: ${key.secret}`);
|
|
830
|
+
deps.io.out("Store the secret now: it cannot be shown again. Sign tokens with HS256 and put the kid in the JWT header.");
|
|
831
|
+
}
|
|
832
|
+
return 0;
|
|
833
|
+
}
|
|
834
|
+
async function widgetKeysRevoke(args, deps) {
|
|
835
|
+
const { values, positionals } = parse(args, {});
|
|
836
|
+
const keyId = need(positionals, 0, "keyId");
|
|
837
|
+
const result = await (await clientFor(values, deps)).revokeWidgetSigningKey(keyId);
|
|
838
|
+
if (values.json)
|
|
839
|
+
printJson(deps, result);
|
|
840
|
+
else
|
|
841
|
+
deps.io.out(`Revoked ${keyId}.`);
|
|
842
|
+
return 0;
|
|
843
|
+
}
|
|
844
|
+
async function webcallUpdate(args, deps) {
|
|
845
|
+
const { values, positionals } = parse(args, {
|
|
846
|
+
ip: { type: "string" },
|
|
847
|
+
embed: { type: "string" },
|
|
848
|
+
accent: { type: "string" },
|
|
849
|
+
title: { type: "string" },
|
|
850
|
+
greeting: { type: "string" },
|
|
851
|
+
"quick-reply": { type: "string", multiple: true },
|
|
852
|
+
"launcher-label": { type: "string" },
|
|
853
|
+
position: { type: "string" },
|
|
854
|
+
entry: { type: "string" },
|
|
855
|
+
logo: { type: "string" },
|
|
856
|
+
"remove-logo": { type: "boolean" },
|
|
857
|
+
});
|
|
858
|
+
const agentId = need(positionals, 0, "agentId");
|
|
859
|
+
const patch = {};
|
|
860
|
+
if (values.ip !== undefined)
|
|
861
|
+
patch.accessIpAllowlist = splitList(values.ip);
|
|
862
|
+
if (values.embed !== undefined)
|
|
863
|
+
patch.embedOriginAllowlist = splitList(values.embed);
|
|
864
|
+
const appearance = {};
|
|
865
|
+
const orNull = (v) => (v === "" ? null : v);
|
|
866
|
+
if (values.accent !== undefined)
|
|
867
|
+
appearance.accent = orNull(values.accent);
|
|
868
|
+
if (values.title !== undefined)
|
|
869
|
+
appearance.title = orNull(values.title);
|
|
870
|
+
if (values.greeting !== undefined)
|
|
871
|
+
appearance.greeting = orNull(values.greeting);
|
|
872
|
+
if (values["launcher-label"] !== undefined)
|
|
873
|
+
appearance.launcherLabel = orNull(values["launcher-label"]);
|
|
874
|
+
if (values.position !== undefined)
|
|
875
|
+
appearance.launcherPosition = orNull(values.position);
|
|
876
|
+
if (values.entry !== undefined)
|
|
877
|
+
appearance.entry = orNull(values.entry);
|
|
878
|
+
if (values["quick-reply"] !== undefined)
|
|
879
|
+
appearance.quickReplies = values["quick-reply"].filter((q) => q !== "");
|
|
880
|
+
if (Object.keys(appearance).length > 0)
|
|
881
|
+
patch.appearance = appearance;
|
|
882
|
+
if (values.logo !== undefined && values["remove-logo"])
|
|
883
|
+
throw new UsageError("Pass --logo or --remove-logo, not both.");
|
|
884
|
+
if (values["remove-logo"])
|
|
885
|
+
patch.logo = null;
|
|
886
|
+
if (values.logo !== undefined) {
|
|
887
|
+
const ext = values.logo.slice(values.logo.lastIndexOf(".")).toLowerCase();
|
|
888
|
+
const contentType = LOGO_TYPES[ext];
|
|
889
|
+
if (!contentType)
|
|
890
|
+
throw new UsageError("The logo must be a .png, .jpg or .webp file.");
|
|
891
|
+
patch.logo = { contentType, dataBase64: Buffer.from(await readFile(values.logo)).toString("base64") };
|
|
892
|
+
}
|
|
893
|
+
if (Object.keys(patch).length === 0) {
|
|
894
|
+
throw new UsageError("Nothing to change. Pass --ip, --embed or an appearance flag (see `kumion help`).");
|
|
895
|
+
}
|
|
896
|
+
const w = await (await clientFor(values, deps)).setWebcallAccess(agentId, patch);
|
|
897
|
+
if (values.json)
|
|
898
|
+
printJson(deps, w);
|
|
899
|
+
else {
|
|
900
|
+
deps.io.out("Saved and live now — no publish needed.");
|
|
901
|
+
webcallLines(w, deps);
|
|
902
|
+
}
|
|
903
|
+
return 0;
|
|
904
|
+
}
|
|
771
905
|
function factLine(fact) {
|
|
772
906
|
const state = fact.reviewState === "pending" ? `pending${fact.candidates.length > 0 ? ` (candidates: ${fact.candidates.join(" / ")})` : ""}` : (fact.value ?? "");
|
|
773
907
|
return `${fact.id} ${fact.label}: ${state} [revision ${fact.revision}]`;
|
|
@@ -2214,6 +2348,7 @@ async function callsGet(args, deps) {
|
|
|
2214
2348
|
`Duration: ${call.durationSec === null ? "-" : `${call.durationSec}s`}${call.transferred ? " — transferred to a person" : ""}`,
|
|
2215
2349
|
`Recorded: ${call.capturedItems.length > 0 ? call.capturedItems.join(", ") : "-"}`,
|
|
2216
2350
|
...(call.ticketNo ? [`Ticket: ${call.ticketNo}`] : []),
|
|
2351
|
+
...Object.entries(call.variables ?? {}).map(([name, value]) => `Variable: ${name} = ${value}${call.variableSources?.[name] ? ` [${call.variableSources[name]}]` : ""}`),
|
|
2217
2352
|
`Transcript: ${call.hasTranscript ? `yes — \`kumion calls transcript ${call.id}\`` : "none yet"}`,
|
|
2218
2353
|
].join("\n"));
|
|
2219
2354
|
return 0;
|
package/dist/mcp.js
CHANGED
|
@@ -282,6 +282,73 @@ export function createKumionMcpServer(client, options) {
|
|
|
282
282
|
}
|
|
283
283
|
return attempt(() => client.setAvailability(args.agentId, patch, args.revision));
|
|
284
284
|
});
|
|
285
|
+
server.registerTool("list_widget_signing_keys", {
|
|
286
|
+
description: "List the keys the customer's server signs website-widget visitor tokens with: id (the token's `kid`), createdAt, " +
|
|
287
|
+
"lastUsedAt, revokedAt. Never returns a secret. Needs agents:read.",
|
|
288
|
+
inputSchema: {},
|
|
289
|
+
annotations: { readOnlyHint: true },
|
|
290
|
+
}, () => attempt(async () => ({ keys: await client.listWidgetSigningKeys() })));
|
|
291
|
+
server.registerTool("create_widget_signing_key", {
|
|
292
|
+
description: "Create a visitor-token signing key (HS256). The `secret` in the answer is shown once and cannot be read again; " +
|
|
293
|
+
"do not log it. At most 2 unrevoked keys per workspace. LIVE: confirm with the person first. Needs agents:live.",
|
|
294
|
+
inputSchema: {},
|
|
295
|
+
}, () => attempt(() => client.createWidgetSigningKey()));
|
|
296
|
+
server.registerTool("revoke_widget_signing_key", {
|
|
297
|
+
description: "Revoke a signing key: tokens signed with it are refused from the next call. Cannot be undone, so confirm with the " +
|
|
298
|
+
"person first. Needs agents:live.",
|
|
299
|
+
inputSchema: { keyId: z.string().min(1).describe("The key id from list_widget_signing_keys.") },
|
|
300
|
+
annotations: { destructiveHint: true, idempotentHint: true },
|
|
301
|
+
}, (args) => attempt(() => client.revokeWidgetSigningKey(args.keyId)));
|
|
302
|
+
server.registerTool("get_webcall_access", {
|
|
303
|
+
description: "Read the Webコール access limits of an agent: accessIpAllowlist (IPs/CIDRs allowed to open the widget; the layer " +
|
|
304
|
+
"that stops direct URL access) and embedOriginAllowlist (sites allowed to embed it). Empty = no limit.",
|
|
305
|
+
inputSchema: { agentId },
|
|
306
|
+
annotations: { readOnlyHint: true },
|
|
307
|
+
}, (args) => attempt(() => client.getWebcallAccess(args.agentId)));
|
|
308
|
+
server.registerTool("set_webcall_access", {
|
|
309
|
+
description: "Set the Webコール access limits. accessIpAllowlist: IPs or CIDRs (empty list = no limit); embedOriginAllowlist: " +
|
|
310
|
+
"origins like https://example.com or https://*.example.com. appearance: the widget look (accent #RRGGBB, title <=40, " +
|
|
311
|
+
"greeting <=200, quickReplies <=4 x <=30, launcherLabel <=20, launcherPosition, entry); null clears an item. logo: " +
|
|
312
|
+
"{contentType, dataBase64} PNG/JPEG/WebP <=512KB, or null to remove. LIVE: applies at once, no publish, so confirm with the " +
|
|
313
|
+
"person first (a wrong IP list locks them out). Needs agents:live.",
|
|
314
|
+
inputSchema: {
|
|
315
|
+
agentId,
|
|
316
|
+
accessIpAllowlist: z.array(z.string()).optional().describe("Allowed IPs/CIDRs; [] clears."),
|
|
317
|
+
embedOriginAllowlist: z.array(z.string()).optional().describe("Allowed embedding origins; [] clears."),
|
|
318
|
+
appearance: z
|
|
319
|
+
.object({
|
|
320
|
+
accent: z.string().nullable().optional(),
|
|
321
|
+
title: z.string().nullable().optional(),
|
|
322
|
+
greeting: z.string().nullable().optional(),
|
|
323
|
+
quickReplies: z.array(z.string()).nullable().optional(),
|
|
324
|
+
launcherLabel: z.string().nullable().optional(),
|
|
325
|
+
launcherPosition: z.enum(["right", "left"]).nullable().optional(),
|
|
326
|
+
entry: z.enum(["both", "voice", "text"]).nullable().optional(),
|
|
327
|
+
})
|
|
328
|
+
.optional()
|
|
329
|
+
.describe("Widget look; a field set to null returns to the default."),
|
|
330
|
+
logo: z
|
|
331
|
+
.object({ contentType: z.enum(["image/png", "image/jpeg", "image/webp"]), dataBase64: z.string() })
|
|
332
|
+
.nullable()
|
|
333
|
+
.optional()
|
|
334
|
+
.describe("Logo image (base64, <=512KB); null removes it."),
|
|
335
|
+
},
|
|
336
|
+
annotations: { destructiveHint: true, idempotentHint: true },
|
|
337
|
+
}, (args) => {
|
|
338
|
+
const patch = {};
|
|
339
|
+
if (args.accessIpAllowlist)
|
|
340
|
+
patch.accessIpAllowlist = args.accessIpAllowlist;
|
|
341
|
+
if (args.embedOriginAllowlist)
|
|
342
|
+
patch.embedOriginAllowlist = args.embedOriginAllowlist;
|
|
343
|
+
if (args.appearance)
|
|
344
|
+
patch.appearance = args.appearance;
|
|
345
|
+
if (args.logo !== undefined)
|
|
346
|
+
patch.logo = args.logo;
|
|
347
|
+
if (Object.keys(patch).length === 0) {
|
|
348
|
+
return failure(new UsageError("Nothing to change: pass `accessIpAllowlist`, `embedOriginAllowlist`, `appearance` or `logo`."));
|
|
349
|
+
}
|
|
350
|
+
return attempt(() => client.setWebcallAccess(args.agentId, patch));
|
|
351
|
+
});
|
|
285
352
|
server.registerTool("list_facts", {
|
|
286
353
|
description: "List the facts taken from the agent's 資料 (prices, menu, opening notes) with their state (pending, " +
|
|
287
354
|
"confirmed, edited) and the `revision` edit_fact needs. Needs agents:read.",
|
|
@@ -831,6 +898,7 @@ export function createKumionMcpServer(client, options) {
|
|
|
831
898
|
instruction: z.string().optional().describe("What to tell the model. Omit to have it generated."),
|
|
832
899
|
confirmationMessage: z.string().optional().describe("What the agent says after recording. Omit for the generic line."),
|
|
833
900
|
enabled: z.boolean().optional().describe("Whether the spec records at all. Default true."),
|
|
901
|
+
needsAttention: z.boolean().optional().describe("Whether its open records count on ホーム「対応が必要なもの」. Default true."),
|
|
834
902
|
},
|
|
835
903
|
annotations: { destructiveHint: false, idempotentHint: false },
|
|
836
904
|
}, (args) => attempt(() => client.createCaptureSpec({
|
|
@@ -841,6 +909,7 @@ export function createKumionMcpServer(client, options) {
|
|
|
841
909
|
...(args.instruction === undefined ? {} : { instruction: args.instruction }),
|
|
842
910
|
...(args.confirmationMessage === undefined ? {} : { confirmationMessage: args.confirmationMessage }),
|
|
843
911
|
...(args.enabled === undefined ? {} : { enabled: args.enabled }),
|
|
912
|
+
...(args.needsAttention === undefined ? {} : { needsAttention: args.needsAttention }),
|
|
844
913
|
})));
|
|
845
914
|
server.registerTool("update_capture_spec", {
|
|
846
915
|
description: "Change one 記録項目. An omitted field is left alone; `key` cannot be changed. A hand-written `instruction` " +
|
|
@@ -860,6 +929,7 @@ export function createKumionMcpServer(client, options) {
|
|
|
860
929
|
.describe("New closing line. An empty string goes back to the generic one."),
|
|
861
930
|
fields: z.array(captureSpecField).optional().describe("The whole field list, replacing the current one."),
|
|
862
931
|
enabled: z.boolean().optional().describe("false stops recording (past records stay)."),
|
|
932
|
+
needsAttention: z.boolean().optional().describe("false takes its open records off ホーム「対応が必要なもの」 (サマリー still lists them); true brings them back."),
|
|
863
933
|
},
|
|
864
934
|
annotations: { destructiveHint: true, idempotentHint: true },
|
|
865
935
|
}, (args) => {
|
|
@@ -877,8 +947,10 @@ export function createKumionMcpServer(client, options) {
|
|
|
877
947
|
patch.fields = args.fields;
|
|
878
948
|
if (args.enabled !== undefined)
|
|
879
949
|
patch.enabled = args.enabled;
|
|
950
|
+
if (args.needsAttention !== undefined)
|
|
951
|
+
patch.needsAttention = args.needsAttention;
|
|
880
952
|
if (Object.keys(patch).length === 0) {
|
|
881
|
-
return failure(new UsageError("Nothing to change: pass label, scenario, instruction, confirmationMessage, fields or
|
|
953
|
+
return failure(new UsageError("Nothing to change: pass label, scenario, instruction, confirmationMessage, fields, enabled or needsAttention."));
|
|
882
954
|
}
|
|
883
955
|
return attempt(() => client.updateCaptureSpec(args.specId, patch, args.revision));
|
|
884
956
|
});
|
package/package.json
CHANGED
package/skills/kumion/SKILL.md
CHANGED
|
@@ -14,7 +14,7 @@ Two ways in, same operations and same permissions:
|
|
|
14
14
|
- **MCP tools** when the host has the `kumion` MCP server registered. Each CLI
|
|
15
15
|
command has one: `list_agents`, `get_agent`, `get_agent_spec`, `patch_agent`,
|
|
16
16
|
`publish_agent`, `get_call_flow`, `update_call_flow`, `edit_call_flow_steps`,
|
|
17
|
-
`set_agent_opening_name`, `set_agent_availability`, `create_agent_from_template`,
|
|
17
|
+
`set_agent_opening_name`, `set_agent_availability`, `get_webcall_access`, `set_webcall_access`, `list_widget_signing_keys`, `create_widget_signing_key`, `revoke_widget_signing_key`, `create_agent_from_template`,
|
|
18
18
|
`list_agent_templates`, `list_facts`, `edit_fact`, `confirm_facts`,
|
|
19
19
|
`list_staff`, `create_staff`, `update_staff`, `get_store_hours`,
|
|
20
20
|
`update_store_hours`, `set_store_hours_exception`, `get_booking_settings`,
|
|
@@ -278,6 +278,7 @@ A key a node does not store follows the agent's setting (会話の運用) or the
|
|
|
278
278
|
| `first_word_wait_seconds` | start | `tune` | `number` | Seconds `wait_for_first_word` waits (1 to 10, default 3). Absent means the default. Read only when `wait_for_first_word` is true. |
|
|
279
279
|
| `respond_on_enter` | agent | `tune` | `boolean` | Absent means the node answers on arrival. Only an explicit false (wait for the caller) is stored. |
|
|
280
280
|
| `confirm_before_end` | agent | `tune` | `boolean` | Absent means off (agents published before this setting keep their behaviour); a node created on the canvas stores true, and a node compiled from a SOP or document stores true when its connection to an end node requires items (the `end_without_readback` rule). On: the platform reads the recorded items back once before the call ends, and the end opens on a later caller turn with caller_confirmed. |
|
|
281
|
+
| `notify_site` | agent | `tune` | `boolean` | Absent means off. On: a web call (website widget) tells the embedding page `node.entered { nodeKey, label }` each time the call enters this node. |
|
|
281
282
|
| `confirm_before_end_keys` | agent | `internal` | `string[]` | Set by the compiler on a 伝言 step. With `confirm_before_end` on, the end readback reads only these item keys (the call-back number); absent means every item the ending requires. |
|
|
282
283
|
| `entry_lookup` | agent | `tune` | `string` | Absent means no lookup on entry. A tool key from this step's tools (`booking_list`): the platform calls it when the call arrives at this step, and the call and its result are in the step's context before the AI speaks. |
|
|
283
284
|
| `quiet_wait` | start, agent | `tune` | `{ seconds, listen?, resume_speech? }` | Node-level wait. { seconds: 0 } turns the agent default off here. |
|