@kadoa/mcp 0.5.24 → 0.5.26

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.
Files changed (3) hide show
  1. package/README.md +10 -0
  2. package/dist/index.js +50 -21
  3. package/package.json +2 -2
package/README.md CHANGED
@@ -88,6 +88,16 @@ Point your client to `https://mcp.kadoa.com/mcp` with OAuth authentication.
88
88
  | `team_list` | List all teams you belong to and see which is active |
89
89
  | `team_switch` | Switch the active team by name or ID |
90
90
 
91
+ ## Workflow controls and behavior
92
+
93
+ For detailed customer guidance, see the [Kadoa documentation](https://docs.kadoa.com/docs/introduction), including [workflows](https://docs.kadoa.com/docs/workflows/overview), [Workflow Assistant](https://docs.kadoa.com/docs/sdk/workflows/assistant), [Personal Inbox](https://docs.kadoa.com/docs/sdk/inbox), [notifications](https://docs.kadoa.com/docs/notifications), and [templates](https://docs.kadoa.com/docs/templates).
94
+
95
+ - **Assistant work vs. schedule:** `interrupt_workflow_assistant`, `resume_workflow_assistant`, and `stop_workflow_assistant` control the Assistant session only; they do not pause scheduled workflow runs. Use `pause_workflow` to stop an active workflow's schedule and `approve_workflow` to activate it again.
96
+ - **Inbox acknowledgement:** `mark_inbox_item_read` only acknowledges an item. For an Assistant question, inspect it with `get_workflow_assistant`, then use `answer_workflow_assistant_question` to answer and resume; use `resume_workflow_assistant` only for an idle or interrupted Assistant.
97
+ - **Run history:** `list_workflow_runs` filters by `status` (`success`, `failed`, or `in_progress`) and supports 1-based `page` and `limit` pagination.
98
+ - **Notifications:** `create_realtime_monitor` requires at least one email, webhook, Slack, or WebSocket notification channel. Notifications are optional when creating a standard one-time or scheduled workflow with `create_workflow`.
99
+ - **Template changes:** `update_template` changes template name and description only. To change template-controlled configuration, create an immutable version with `create_template_version`, then roll it out to linked workflows with `apply_template_version`.
100
+
91
101
  ## Usage Examples
92
102
 
93
103
  Once the MCP server is configured, you can manage the full workflow lifecycle through natural conversation. Here are a few common operations shown as Claude Code sessions.
package/dist/index.js CHANGED
@@ -52654,6 +52654,15 @@ This is the main page content.`
52654
52654
  });
52655
52655
 
52656
52656
  // src/client.ts
52657
+ function isScrapeRequest(url3) {
52658
+ if (!url3)
52659
+ return false;
52660
+ try {
52661
+ return new URL(url3, "https://api.kadoa.com").pathname === "/v4/scrape";
52662
+ } catch {
52663
+ return false;
52664
+ }
52665
+ }
52657
52666
  function createKadoaClient(auth) {
52658
52667
  const { principal } = auth;
52659
52668
  const client = new KadoaClient({
@@ -52662,11 +52671,14 @@ function createKadoaClient(auth) {
52662
52671
  client.axiosInstance.interceptors.request.use((config2) => {
52663
52672
  config2.headers["x-kadoa-source"] = "mcp";
52664
52673
  config2.headers["x-team-id"] = principal.teamId;
52674
+ if (isScrapeRequest(config2.url)) {
52675
+ config2.timeout = MCP_SCRAPE_REQUEST_TIMEOUT_MS;
52676
+ }
52665
52677
  return config2;
52666
52678
  });
52667
52679
  return client;
52668
52680
  }
52669
- var refreshRawMutex, ctxRefreshMutex;
52681
+ var MCP_SCRAPE_REQUEST_TIMEOUT_MS = 310000, refreshRawMutex, ctxRefreshMutex;
52670
52682
  var init_client = __esm(() => {
52671
52683
  init_dist2();
52672
52684
  refreshRawMutex = new Map;
@@ -52698,9 +52710,19 @@ __export(exports_client, {
52698
52710
  decodeJwtClaims: () => decodeJwtClaims,
52699
52711
  createKadoaClient: () => createKadoaClient2,
52700
52712
  SessionExpiredError: () => SessionExpiredError,
52713
+ MCP_SCRAPE_REQUEST_TIMEOUT_MS: () => MCP_SCRAPE_REQUEST_TIMEOUT_MS2,
52701
52714
  KadoaSdkException: () => KadoaSdkException,
52702
52715
  KadoaClient: () => KadoaClient
52703
52716
  });
52717
+ function isScrapeRequest2(url3) {
52718
+ if (!url3)
52719
+ return false;
52720
+ try {
52721
+ return new URL(url3, "https://api.kadoa.com").pathname === "/v4/scrape";
52722
+ } catch {
52723
+ return false;
52724
+ }
52725
+ }
52704
52726
  function createKadoaClient2(auth) {
52705
52727
  const { principal } = auth;
52706
52728
  const client = new KadoaClient({
@@ -52709,6 +52731,9 @@ function createKadoaClient2(auth) {
52709
52731
  client.axiosInstance.interceptors.request.use((config2) => {
52710
52732
  config2.headers["x-kadoa-source"] = "mcp";
52711
52733
  config2.headers["x-team-id"] = principal.teamId;
52734
+ if (isScrapeRequest2(config2.url)) {
52735
+ config2.timeout = MCP_SCRAPE_REQUEST_TIMEOUT_MS2;
52736
+ }
52712
52737
  return config2;
52713
52738
  });
52714
52739
  return client;
@@ -52819,7 +52844,7 @@ async function getValidJwt(ctx) {
52819
52844
  ctxRefreshMutex2.set(ctx, promise3);
52820
52845
  return promise3;
52821
52846
  }
52822
- var SessionExpiredError, refreshRawMutex2, ctxRefreshMutex2;
52847
+ var MCP_SCRAPE_REQUEST_TIMEOUT_MS2 = 310000, SessionExpiredError, refreshRawMutex2, ctxRefreshMutex2;
52823
52848
  var init_client2 = __esm(() => {
52824
52849
  init_dist2();
52825
52850
  SessionExpiredError = class SessionExpiredError extends Error {
@@ -53284,23 +53309,27 @@ function registerTools(server, ctx, capabilities) {
53284
53309
  password: exports_external.string().optional().describe("Password (required for 'basic' type)"),
53285
53310
  headers: exports_external.object({}).passthrough().optional().describe("Custom headers as key-value pairs (required for 'header' type)")
53286
53311
  }).optional().describe("Authentication configuration for the webhook endpoint");
53312
+ const notificationChannelsSchema = exports_external.object({
53313
+ email: exports_external.object({
53314
+ recipients: exports_external.array(exports_external.string().email()).optional().describe("Email addresses to notify. Omit to use account default email.")
53315
+ }).optional().describe("Send email notifications. Pass {} for account default email, or {recipients: [...]} for custom addresses."),
53316
+ webhook: exports_external.object({
53317
+ url: exports_external.string().url().describe("Webhook endpoint URL"),
53318
+ httpMethod: exports_external.enum(["POST", "GET", "PUT", "PATCH"]).optional().describe("HTTP method (defaults to POST)"),
53319
+ auth: webhookAuthShape
53320
+ }).optional().describe("Send notifications via HTTP webhook"),
53321
+ slack: exports_external.object({
53322
+ webhookUrl: exports_external.string().url().optional().describe("Slack incoming webhook URL (legacy)"),
53323
+ slackChannelId: exports_external.string().optional().describe("Slack channel ID from OAuth integration (e.g. C01ABCDEF)"),
53324
+ slackChannelName: exports_external.string().optional().describe("Slack channel name (e.g. #alerts)")
53325
+ }).optional().describe("Send notifications to a Slack channel. Use slackChannelId/slackChannelName for OAuth integration, or webhookUrl for legacy incoming webhooks."),
53326
+ websocket: exports_external.boolean().optional().describe("Enable WebSocket notifications for programmatic real-time consumption")
53327
+ });
53287
53328
  const notificationsInputShape = {
53288
- notifications: exports_external.preprocess(coerceJson(), exports_external.object({
53289
- email: exports_external.object({
53290
- recipients: exports_external.array(exports_external.string().email()).optional().describe("Email addresses to notify. Omit to use account default email.")
53291
- }).optional().describe("Send email notifications. Pass {} for account default email, or {recipients: [...]} for custom addresses."),
53292
- webhook: exports_external.object({
53293
- url: exports_external.string().url().describe("Webhook endpoint URL"),
53294
- httpMethod: exports_external.enum(["POST", "GET", "PUT", "PATCH"]).optional().describe("HTTP method (defaults to POST)"),
53295
- auth: webhookAuthShape
53296
- }).optional().describe("Send notifications via HTTP webhook"),
53297
- slack: exports_external.object({
53298
- webhookUrl: exports_external.string().url().optional().describe("Slack incoming webhook URL (legacy)"),
53299
- slackChannelId: exports_external.string().optional().describe("Slack channel ID from OAuth integration (e.g. C01ABCDEF)"),
53300
- slackChannelName: exports_external.string().optional().describe("Slack channel name (e.g. #alerts)")
53301
- }).optional().describe("Send notifications to a Slack channel. Use slackChannelId/slackChannelName for OAuth integration, or webhookUrl for legacy incoming webhooks."),
53302
- websocket: exports_external.boolean().optional().describe("Enable WebSocket notifications for programmatic real-time consumption")
53303
- }).optional().describe("Notification channels to alert when data changes."))
53329
+ notifications: exports_external.preprocess(coerceJson(), notificationChannelsSchema.optional()).optional().describe("Optional notification channels to alert when data changes.")
53330
+ };
53331
+ const requiredNotificationsInputShape = {
53332
+ notifications: exports_external.preprocess(coerceJson(), notificationChannelsSchema).describe("Notification channels to alert when data changes.")
53304
53333
  };
53305
53334
  function resolveUrls(args) {
53306
53335
  const urls = args.urls ?? (args.url ? [args.url] : []);
@@ -53529,7 +53558,7 @@ function registerTools(server, ctx, capabilities) {
53529
53558
  ...urlInputShape,
53530
53559
  description: exports_external.string().max(500).optional().describe("Description of what this monitor watches (max 500 characters)"),
53531
53560
  tags: exports_external.preprocess(coerceArray(true), exports_external.array(exports_external.string())).optional().describe("Tags for organizing monitors"),
53532
- ...notificationsInputShape
53561
+ ...requiredNotificationsInputShape
53533
53562
  }),
53534
53563
  annotations: { readOnlyHint: false, destructiveHint: false, idempotentHint: false }
53535
53564
  }, withErrorHandling("create_realtime_monitor", async (args) => {
@@ -55142,7 +55171,7 @@ var package_default;
55142
55171
  var init_package = __esm(() => {
55143
55172
  package_default = {
55144
55173
  name: "@kadoa/mcp",
55145
- version: "0.5.24",
55174
+ version: "0.5.26",
55146
55175
  description: "Kadoa MCP Server — manage workflows from Claude Desktop, Cursor, and other MCP clients",
55147
55176
  type: "module",
55148
55177
  main: "dist/index.js",
@@ -55160,7 +55189,7 @@ var init_package = __esm(() => {
55160
55189
  build: "bun build src/index.ts --outdir=dist --target=node --external express --external ioredis",
55161
55190
  "check-types": "tsc --noEmit",
55162
55191
  test: "BUN_TEST=1 bun test",
55163
- "test:unit": "BUN_TEST=1 bun test tests/unit/server.test.ts --timeout=120000 && BUN_TEST=1 bun test $(find tests/unit -maxdepth 1 -name '*.test.ts' ! -name 'server.test.ts') --timeout=120000",
55192
+ "test:unit": "BUN_TEST=1 bun test tests/unit/server.test.ts --timeout=120000 && BUN_TEST=1 bun test tests/unit/client.test.ts --timeout=120000 && BUN_TEST=1 bun test tests/unit/proactive-refresh.test.ts --timeout=120000 && BUN_TEST=1 bun test $(find tests/unit -maxdepth 1 -name '*.test.ts' ! -name 'server.test.ts' ! -name 'client.test.ts' ! -name 'proactive-refresh.test.ts') --timeout=120000",
55164
55193
  "test:e2e": "BUN_TEST=1 bun test tests/e2e --timeout=600000",
55165
55194
  "test:eval": "BUN_TEST=1 bun test tests/evals --timeout=300000",
55166
55195
  prepublishOnly: "bun run check-types && bun run test:unit && bun run build"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kadoa/mcp",
3
- "version": "0.5.24",
3
+ "version": "0.5.26",
4
4
  "description": "Kadoa MCP Server — manage workflows from Claude Desktop, Cursor, and other MCP clients",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -18,7 +18,7 @@
18
18
  "build": "bun build src/index.ts --outdir=dist --target=node --external express --external ioredis",
19
19
  "check-types": "tsc --noEmit",
20
20
  "test": "BUN_TEST=1 bun test",
21
- "test:unit": "BUN_TEST=1 bun test tests/unit/server.test.ts --timeout=120000 && BUN_TEST=1 bun test $(find tests/unit -maxdepth 1 -name '*.test.ts' ! -name 'server.test.ts') --timeout=120000",
21
+ "test:unit": "BUN_TEST=1 bun test tests/unit/server.test.ts --timeout=120000 && BUN_TEST=1 bun test tests/unit/client.test.ts --timeout=120000 && BUN_TEST=1 bun test tests/unit/proactive-refresh.test.ts --timeout=120000 && BUN_TEST=1 bun test $(find tests/unit -maxdepth 1 -name '*.test.ts' ! -name 'server.test.ts' ! -name 'client.test.ts' ! -name 'proactive-refresh.test.ts') --timeout=120000",
22
22
  "test:e2e": "BUN_TEST=1 bun test tests/e2e --timeout=600000",
23
23
  "test:eval": "BUN_TEST=1 bun test tests/evals --timeout=300000",
24
24
  "prepublishOnly": "bun run check-types && bun run test:unit && bun run build"