@walkeros/mcp 4.1.0 → 4.1.1-next-1779822275564

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/dist/stdio.js CHANGED
@@ -432,15 +432,17 @@ async function flowSimulateHandlerBody(input) {
432
432
  `Unknown step type "${stepType}". Use "source", "transformer", or "destination".`
433
433
  );
434
434
  }
435
- if (result.captured && result.captured.length > 0) {
436
- const eventCount = result.captured.length;
437
- const summary2 = `Source captured ${eventCount} event${eventCount !== 1 ? "s" : ""}`;
435
+ const success = !result.error;
436
+ const errorMessage = result.error?.message;
437
+ if (result.step === "source") {
438
+ const eventCount = result.events.length;
439
+ const summary = `Source captured ${eventCount} event${eventCount !== 1 ? "s" : ""}`;
438
440
  return mcpResult3(
439
441
  {
440
- success: result.success,
441
- error: result.error,
442
- summary: summary2,
443
- capturedEvents: result.captured,
442
+ success,
443
+ error: errorMessage,
444
+ summary,
445
+ capturedEvents: result.events,
444
446
  duration: result.duration
445
447
  },
446
448
  {
@@ -452,41 +454,45 @@ async function flowSimulateHandlerBody(input) {
452
454
  }
453
455
  );
454
456
  }
455
- const destinations = {};
456
- if (result.elbResult && typeof result.elbResult === "object" && "done" in result.elbResult && result.elbResult.done) {
457
- const done = result.elbResult.done;
458
- for (const name of Object.keys(done)) {
459
- destinations[name] = { received: true, calls: 0 };
460
- }
461
- }
462
- if (result.usage) {
463
- for (const [name, calls] of Object.entries(result.usage)) {
464
- const summary2 = {
465
- received: calls.length > 0,
466
- calls: calls.length
467
- };
468
- if (verbose && calls.length > 0) {
469
- summary2.payload = calls;
457
+ if (result.step === "transformer") {
458
+ return mcpResult3(
459
+ {
460
+ success,
461
+ error: errorMessage,
462
+ summary: `Transformer processed event`,
463
+ capturedEvents: result.events,
464
+ duration: result.duration
465
+ },
466
+ {
467
+ next: ["Use flow_bundle to build for production"]
470
468
  }
471
- destinations[name] = summary2;
472
- }
469
+ );
470
+ }
471
+ const destinations = {};
472
+ const callCount = result.calls.length;
473
+ const destSummary = {
474
+ received: callCount > 0,
475
+ calls: callCount
476
+ };
477
+ if (verbose && callCount > 0) {
478
+ destSummary.payload = result.calls;
473
479
  }
480
+ destinations[result.name] = destSummary;
474
481
  const destCount = Object.keys(destinations).length;
475
482
  const receivedCount = Object.values(destinations).filter(
476
483
  (d) => d.received
477
484
  ).length;
478
485
  const warnings = [];
479
- if (stepType === "destination" && destCount === 0) {
486
+ if (receivedCount === 0) {
480
487
  warnings.push(
481
488
  'Destination did not receive the event. Common causes: (1) destination config has consent: { marketing: true } but event lacks matching consent, (2) mapping rules do not match the event name, (3) policy redacted required fields. Add consent to the event: { name: "...", data: {...}, consent: { marketing: true } }.'
482
489
  );
483
490
  }
484
- const summary = stepType === "transformer" ? `Transformer processed event` : `${receivedCount}/${destCount} destinations received the event`;
485
491
  const resultObj = {
486
- success: result.success,
487
- error: result.error,
488
- summary,
489
- destinations: destCount > 0 ? destinations : void 0,
492
+ success,
493
+ error: errorMessage,
494
+ summary: `${receivedCount}/${destCount} destinations received the event`,
495
+ destinations,
490
496
  duration: result.duration
491
497
  };
492
498
  return mcpResult3(resultObj, {
@@ -722,7 +728,7 @@ var NPM_SEARCH_URL = "https://registry.npmjs.org/-/v1/search";
722
728
  var JSDELIVR_BASE = "https://cdn.jsdelivr.net/npm";
723
729
  var WALKEROS_JSON_PATH = "dist/walkerOS.json";
724
730
  var CACHE_TTL = 5 * 60 * 1e3;
725
- var CLIENT_HEADER = "walkeros-mcp/4.1.0";
731
+ var CLIENT_HEADER = "walkeros-mcp/4.1.1-next-1779822275564";
726
732
  var cache;
727
733
  function normalizePlatform(platform) {
728
734
  if (platform == null) return [];
@@ -1164,7 +1170,7 @@ async function feedbackHandlerBody(client, input) {
1164
1170
  const isAnonymous = explicitAnonymous ?? anonymous ?? true;
1165
1171
  await client.submitFeedback(text, {
1166
1172
  anonymous: isAnonymous,
1167
- version: "4.1.0"
1173
+ version: "4.1.1-next-1779822275564"
1168
1174
  });
1169
1175
  return mcpResult8({ ok: true });
1170
1176
  } catch (error) {
@@ -1344,7 +1350,11 @@ var inputSchema9 = {
1344
1350
  ),
1345
1351
  name: z9.string().optional().describe(
1346
1352
  "Project name. Required for create. Optional for update (to rename)."
1347
- )
1353
+ ),
1354
+ cursor: z9.string().optional().describe(
1355
+ "Pagination cursor from a previous list response. Only used with the list action."
1356
+ ),
1357
+ limit: z9.number().int().min(1).max(100).optional().describe("Max items per page (1-100). Only used with the list action.")
1348
1358
  };
1349
1359
  var annotations9 = {
1350
1360
  readOnlyHint: false,
@@ -1363,11 +1373,11 @@ function createProjectManageToolSpec(client) {
1363
1373
  };
1364
1374
  }
1365
1375
  async function projectManageHandlerBody(client, input) {
1366
- const { action, projectId, name } = input ?? {};
1376
+ const { action, projectId, name, cursor, limit } = input ?? {};
1367
1377
  try {
1368
1378
  switch (action) {
1369
1379
  case "list": {
1370
- const projects = await client.listProjects();
1380
+ const projects = await client.listProjects({ cursor, limit });
1371
1381
  const items = Array.isArray(projects) ? projects : projects?.projects || [];
1372
1382
  if (items.length === 0) {
1373
1383
  return mcpResult10(
@@ -1567,6 +1577,10 @@ var inputSchema10 = {
1567
1577
  sort: z10.enum(["name", "updated_at", "created_at"]).optional().describe("Sort field for list."),
1568
1578
  order: z10.enum(["asc", "desc"]).optional().describe("Sort order for list."),
1569
1579
  includeDeleted: z10.boolean().optional().describe("Include soft-deleted flows in list results."),
1580
+ cursor: z10.string().optional().describe(
1581
+ "Pagination cursor from a previous list response. Only used with the list action."
1582
+ ),
1583
+ limit: z10.number().int().min(1).max(100).optional().describe("Max items per page (1-100). Only used with the list action."),
1570
1584
  previewId: z10.string().optional().describe(
1571
1585
  "Preview ID (prv_...). Required for preview_get and preview_delete."
1572
1586
  ),
@@ -1608,6 +1622,8 @@ async function flowManageHandlerBody(client, input) {
1608
1622
  sort,
1609
1623
  order,
1610
1624
  includeDeleted,
1625
+ cursor,
1626
+ limit,
1611
1627
  previewId,
1612
1628
  flowName,
1613
1629
  flowSettingsId,
@@ -1621,7 +1637,9 @@ async function flowManageHandlerBody(client, input) {
1621
1637
  projectId,
1622
1638
  sort,
1623
1639
  order,
1624
- includeDeleted
1640
+ includeDeleted,
1641
+ cursor,
1642
+ limit
1625
1643
  });
1626
1644
  const dataObj = data2;
1627
1645
  const flows = dataObj.flows;
@@ -1631,7 +1649,9 @@ async function flowManageHandlerBody(client, input) {
1631
1649
  const data = await client.listAllFlows({
1632
1650
  sort,
1633
1651
  order,
1634
- includeDeleted
1652
+ includeDeleted,
1653
+ cursor,
1654
+ limit
1635
1655
  });
1636
1656
  const safe = Array.isArray(data) ? data.map(safeSummary) : data;
1637
1657
  return mcpResult11(
@@ -1943,7 +1963,11 @@ var inputSchema11 = {
1943
1963
  ),
1944
1964
  flowName: z11.string().optional().describe(
1945
1965
  "Flow name for multi-settings flows. Only used with deploy action."
1946
- )
1966
+ ),
1967
+ cursor: z11.string().optional().describe(
1968
+ "Pagination cursor from a previous list response. Only used with the list action."
1969
+ ),
1970
+ limit: z11.number().int().min(1).max(100).optional().describe("Max items per page (1-100). Only used with the list action.")
1947
1971
  };
1948
1972
  var annotations11 = {
1949
1973
  readOnlyHint: false,
@@ -1971,7 +1995,18 @@ function createDeployManageToolSpec(client) {
1971
1995
  };
1972
1996
  }
1973
1997
  async function deployManageHandlerBody(client, input) {
1974
- const { action, projectId, flowId, slug, type, status, wait, flowName } = input ?? {};
1998
+ const {
1999
+ action,
2000
+ projectId,
2001
+ flowId,
2002
+ slug,
2003
+ type,
2004
+ status,
2005
+ wait,
2006
+ flowName,
2007
+ cursor,
2008
+ limit
2009
+ } = input ?? {};
1975
2010
  try {
1976
2011
  switch (action) {
1977
2012
  case "deploy": {
@@ -1998,7 +2033,9 @@ async function deployManageHandlerBody(client, input) {
1998
2033
  projectId,
1999
2034
  flowId,
2000
2035
  type,
2001
- status
2036
+ status,
2037
+ cursor,
2038
+ limit
2002
2039
  });
2003
2040
  return mcpResult12(data);
2004
2041
  }
@@ -2714,8 +2751,8 @@ import {
2714
2751
  setFeedbackPreference
2715
2752
  } from "@walkeros/cli";
2716
2753
  var HttpToolClient = class {
2717
- async listProjects() {
2718
- return listProjects();
2754
+ async listProjects(options) {
2755
+ return listProjects(options);
2719
2756
  }
2720
2757
  async getProject(options) {
2721
2758
  return getProject(options);
@@ -2807,7 +2844,7 @@ var HttpToolClient = class {
2807
2844
  };
2808
2845
 
2809
2846
  // src/stdio.ts
2810
- setClientContext({ type: "mcp", version: "4.1.0" });
2847
+ setClientContext({ type: "mcp", version: "4.1.1-next-1779822275564" });
2811
2848
  process.on("uncaughtException", (err) => {
2812
2849
  const emitter = getMcpEmitterSingleton();
2813
2850
  if (emitter) {
@@ -2827,7 +2864,7 @@ process.on("unhandledRejection", (reason) => {
2827
2864
  async function main() {
2828
2865
  const server = createWalkerOSMcpServer({
2829
2866
  client: new HttpToolClient(),
2830
- version: "4.1.0"
2867
+ version: "4.1.1-next-1779822275564"
2831
2868
  });
2832
2869
  const transport = new StdioServerTransport();
2833
2870
  await server.connect(transport);
@@ -2837,7 +2874,7 @@ main().catch(async (error) => {
2837
2874
  try {
2838
2875
  const emitter = await createMcpEmitter({
2839
2876
  clientInfo: void 0,
2840
- packageVersion: "4.1.0"
2877
+ packageVersion: "4.1.1-next-1779822275564"
2841
2878
  });
2842
2879
  await emitter.emitError("startup");
2843
2880
  } catch {