@zapier/zapier-sdk-cli 0.84.6 → 0.85.0
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 +27 -0
- package/README.md +17 -3
- package/bin/zapier-sdk-experimental.mjs +8 -0
- package/dist/cli.cjs +297 -150
- package/dist/cli.mjs +305 -158
- package/dist/experimental.cjs +37 -18
- package/dist/experimental.d.mts +9 -7
- package/dist/experimental.d.ts +9 -7
- package/dist/experimental.mjs +38 -19
- package/dist/index.cjs +106 -83
- package/dist/index.d.mts +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.mjs +106 -83
- package/package.json +4 -4
package/dist/cli.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { Command, CommanderError, Option, InvalidArgumentError } from 'commander';
|
|
3
|
-
import { getConnectionPlugin, definePlugin, apiPlugin, defineMethod, apiPluginRef, resolveCredentialsPluginRef, eventEmissionPluginRef, sdkOptionsPluginRef, declareOptionalProperty, OutputPropertySchema, ZapierBundleError, isZapierBundleError, DEFAULT_CONFIG_PATH, declareMethod, ZapierValidationError, isZapierValidationError, ZapierUnknownError, manifestPluginRef, defineResolver, isPermanentHttpError, isZapierAuthenticationError, ZapierApiError, defineOverride, fetchPlugin, zapierCoreOptions, injectCliLogin, omitExports, zapierSdkPlugin, BaseSdkOptionsSchema, disposeSdk, invalidateCachedToken, batch, toSnakeCase, ZapierError, isZapierReleaseTriggerMessageSignal, createSdk as createSdk$
|
|
3
|
+
import { STABILITY_LEVELS, getConnectionPlugin, definePlugin, apiPlugin, defineMethod, apiPluginRef, resolveCredentialsPluginRef, eventEmissionPluginRef, sdkOptionsPluginRef, declareOptionalProperty, OutputPropertySchema, ZapierBundleError, isZapierBundleError, DEFAULT_CONFIG_PATH, declareMethod, ZapierValidationError, isZapierValidationError, ZapierUnknownError, manifestPluginRef, defineResolver, isPermanentHttpError, isZapierAuthenticationError, ZapierApiError, defineOverride, fetchPlugin, zapierCoreOptions, injectCliLogin, omitExports, zapierSdkPlugin, BaseSdkOptionsSchema, disposeSdk, invalidateCachedToken, batch, toSnakeCase, ZapierError, isZapierReleaseTriggerMessageSignal, createSdk as createSdk$2, CORE_OPTIONS_ID as CORE_OPTIONS_ID$2, SDK_OPTIONS_ID as SDK_OPTIONS_ID$2, addPlugin as addPlugin$2, formatExtensionPluginFailure as formatExtensionPluginFailure$2, resolvePlugin, isCredentialsObject, getRegistryPlugin, createController, ZapierAbortDrainSignal, ZapierReleaseTriggerMessageSignal, STABILITY_DEFINITIONS, getRegistry, getCoreErrorCode, CoreErrorCode, applyStabilityLabel, buildApplicationLifecycleEvent, AuthMechanism, DEPRECATION_NOTICE_EVENT, runWithCallerContext, isCoreCancelledSignal, getNegatable, isPositional, isZapierError, formatErrorMessage, getOsInfo, getPlatformVersions, getAgent as getAgent$1, getTtyContext, getCiPlatform, isCi, isZapierConflictError, getReleaseId, getCurrentTimestamp, generateEventId, isZapierApprovalError, ZapierAuthenticationError } from '@zapier/zapier-sdk';
|
|
4
4
|
import { z } from 'zod';
|
|
5
5
|
import inquirer from 'inquirer';
|
|
6
|
-
import
|
|
6
|
+
import chalk10 from 'chalk';
|
|
7
7
|
import { makeTheme, createPrompt, useState, usePrefix, useMemo, useEffect, useKeypress, isEnterKey, isTabKey, isUpKey, isDownKey, usePagination, Separator } from '@inquirer/core';
|
|
8
8
|
import ora from 'ora';
|
|
9
9
|
import * as fs from 'fs';
|
|
@@ -34,7 +34,8 @@ import packageJsonLib, { VersionNotFoundError } from 'package-json';
|
|
|
34
34
|
import semver from 'semver';
|
|
35
35
|
import crossSpawn from 'cross-spawn';
|
|
36
36
|
import Table from 'cli-table3';
|
|
37
|
-
import { triggerInboxResolver, DrainTriggerInboxSchema, WatchTriggerInboxSchema, declareMethod as declareMethod$1, defineMethod as defineMethod$1, CreateWorkflowResponseSchema, getAgent, injectCliLogin as injectCliLogin$
|
|
37
|
+
import { triggerInboxResolver, DrainTriggerInboxSchema, WatchTriggerInboxSchema, declareMethod as declareMethod$1, defineMethod as defineMethod$1, CreateWorkflowResponseSchema, getAgent, injectCliLogin as injectCliLogin$2, INTERNAL_CREATE_WORKFLOW_FIELDS, CreateWorkflowOptionsSchema, definePlugin as definePlugin$1, omitExports as omitExports$1, zapierExperimentalSdkPlugin, createSdk, CORE_OPTIONS_ID, SDK_OPTIONS_ID, addPlugin, formatExtensionPluginFailure } from '@zapier/zapier-sdk/experimental';
|
|
38
|
+
import { injectCliLogin as injectCliLogin$1, definePlugin as definePlugin$2, omitExports as omitExports$2, zapierBetaSdkPlugin, createSdk as createSdk$1, CORE_OPTIONS_ID as CORE_OPTIONS_ID$1, SDK_OPTIONS_ID as SDK_OPTIONS_ID$1, addPlugin as addPlugin$1, formatExtensionPluginFailure as formatExtensionPluginFailure$1 } from '@zapier/zapier-sdk/beta';
|
|
38
39
|
import * as readline from 'readline';
|
|
39
40
|
|
|
40
41
|
var __defProp = Object.defineProperty;
|
|
@@ -60,9 +61,9 @@ function normalizeChoices(choices) {
|
|
|
60
61
|
var theme = makeTheme({
|
|
61
62
|
icon: { cursor: "\u276F" },
|
|
62
63
|
style: {
|
|
63
|
-
disabled: (text) =>
|
|
64
|
-
searchTerm: (text) =>
|
|
65
|
-
keysHelpTip: (keys) => keys.map(([key, action]) => `${
|
|
64
|
+
disabled: (text) => chalk10.dim(`- ${text}`),
|
|
65
|
+
searchTerm: (text) => chalk10.cyan(text),
|
|
66
|
+
keysHelpTip: (keys) => keys.map(([key, action]) => `${chalk10.bold(key)} ${chalk10.dim(action)}`).join(chalk10.dim(" \u2022 "))
|
|
66
67
|
}
|
|
67
68
|
});
|
|
68
69
|
var searchSelect = createPrompt(
|
|
@@ -205,10 +206,10 @@ async function promptText({
|
|
|
205
206
|
]);
|
|
206
207
|
return value;
|
|
207
208
|
}
|
|
208
|
-
var display = (c) => c.hint ? `${c.label} ${
|
|
209
|
+
var display = (c) => c.hint ? `${c.label} ${chalk10.dim(`(${c.hint})`)}` : c.label;
|
|
209
210
|
var HIGH_CONTRAST_PROMPT_THEME = {
|
|
210
211
|
style: {
|
|
211
|
-
answer: (text) =>
|
|
212
|
+
answer: (text) => chalk10.inverse.bold(` ${text} `)
|
|
212
213
|
}
|
|
213
214
|
};
|
|
214
215
|
function buildSelectRows(question, term) {
|
|
@@ -224,8 +225,8 @@ function buildSelectRows(question, term) {
|
|
|
224
225
|
name: display(c),
|
|
225
226
|
value: c.value
|
|
226
227
|
}));
|
|
227
|
-
const skipRow = offers(question, "skip") ? [row(
|
|
228
|
-
const customRow = offers(question, "custom") ? [row(
|
|
228
|
+
const skipRow = offers(question, "skip") ? [row(chalk10.dim("Skip (optional)"), "skip")] : [];
|
|
229
|
+
const customRow = offers(question, "custom") ? [row(chalk10.dim("Enter a value manually\u2026"), "custom")] : [];
|
|
229
230
|
const committed = !!t || question.search !== void 0;
|
|
230
231
|
let rows;
|
|
231
232
|
if (!committed) {
|
|
@@ -236,13 +237,13 @@ function buildSelectRows(question, term) {
|
|
|
236
237
|
rows = [...customRow, ...skipRow];
|
|
237
238
|
}
|
|
238
239
|
if (offers(question, "search"))
|
|
239
|
-
rows.push(row(
|
|
240
|
+
rows.push(row(chalk10.cyan("Search again\u2026"), "search"));
|
|
240
241
|
if (offers(question, "next_page"))
|
|
241
|
-
rows.push(row(
|
|
242
|
-
if (offers(question, "retry")) rows.push(row(
|
|
243
|
-
if (offers(question, "cancel")) rows.push(row(
|
|
242
|
+
rows.push(row(chalk10.dim("Load more\u2026"), "next_page"));
|
|
243
|
+
if (offers(question, "retry")) rows.push(row(chalk10.yellow("Retry"), "retry"));
|
|
244
|
+
if (offers(question, "cancel")) rows.push(row(chalk10.dim("Cancel"), "cancel"));
|
|
244
245
|
for (const note of question.notes ?? [])
|
|
245
|
-
rows.push({ name:
|
|
246
|
+
rows.push({ name: chalk10.dim(note), value: note, disabled: true });
|
|
246
247
|
return rows;
|
|
247
248
|
}
|
|
248
249
|
function foldPage(acc, question, field) {
|
|
@@ -322,12 +323,12 @@ async function answerSelect(question, field, box, failed, mode) {
|
|
|
322
323
|
})),
|
|
323
324
|
...offers(question, "next_page") ? [
|
|
324
325
|
{
|
|
325
|
-
name:
|
|
326
|
+
name: chalk10.dim("Load more\u2026"),
|
|
326
327
|
value: { action: "next_page" }
|
|
327
328
|
}
|
|
328
329
|
] : [],
|
|
329
330
|
...(question.notes ?? []).map((note) => ({
|
|
330
|
-
name:
|
|
331
|
+
name: chalk10.dim(note),
|
|
331
332
|
value: note,
|
|
332
333
|
disabled: true
|
|
333
334
|
}))
|
|
@@ -404,14 +405,14 @@ async function answerSelect(question, field, box, failed, mode) {
|
|
|
404
405
|
case "retry":
|
|
405
406
|
return { type: "retry" };
|
|
406
407
|
case "skip":
|
|
407
|
-
printAnswered(view.message,
|
|
408
|
+
printAnswered(view.message, chalk10.dim("(skipped)"));
|
|
408
409
|
return { type: "skip" };
|
|
409
410
|
case "cancel":
|
|
410
411
|
return { type: "cancel" };
|
|
411
412
|
}
|
|
412
413
|
}
|
|
413
414
|
function printAnswered(message, label) {
|
|
414
|
-
console.log(`${
|
|
415
|
+
console.log(`${chalk10.green("\u2714")} ${message} ${chalk10.cyan(label)}`);
|
|
415
416
|
}
|
|
416
417
|
async function answerInput(question) {
|
|
417
418
|
const message = question.placeholder ? question.message.replace(/:?\s*$/, ` (${question.placeholder}):`) : question.message;
|
|
@@ -458,7 +459,7 @@ function createCliAnswer({
|
|
|
458
459
|
try {
|
|
459
460
|
if (result.error !== void 0) {
|
|
460
461
|
const message = typeof result.error === "string" ? result.error : result.error.message;
|
|
461
|
-
console.log(
|
|
462
|
+
console.log(chalk10.yellow(`! ${message}`));
|
|
462
463
|
}
|
|
463
464
|
const question = result.question;
|
|
464
465
|
const field = question.path.length ? question.path.join(".") : "value";
|
|
@@ -527,8 +528,6 @@ var ZapierCliMissingParametersError = class extends ZapierCliError {
|
|
|
527
528
|
this.params = params;
|
|
528
529
|
}
|
|
529
530
|
};
|
|
530
|
-
|
|
531
|
-
// src/utils/cli-options.ts
|
|
532
531
|
var RESERVED_CLI_OPTIONS = [
|
|
533
532
|
{
|
|
534
533
|
name: "version" /* Version */,
|
|
@@ -541,6 +540,11 @@ var RESERVED_CLI_OPTIONS = [
|
|
|
541
540
|
flag: "--help",
|
|
542
541
|
short: "-h",
|
|
543
542
|
description: "Display help for command"
|
|
543
|
+
},
|
|
544
|
+
{
|
|
545
|
+
name: "stability" /* Stability */,
|
|
546
|
+
flag: "--stability <level>",
|
|
547
|
+
description: `Which stability tier of the SDK / CLI surface to use: ${STABILITY_LEVELS.join(", ")}. Can also be set with the ZAPIER_STABILITY environment variable (default: stable).`
|
|
544
548
|
}
|
|
545
549
|
];
|
|
546
550
|
function getReservedCliOption(name) {
|
|
@@ -558,7 +562,7 @@ var SHARED_COMMAND_CLI_OPTIONS = [
|
|
|
558
562
|
|
|
559
563
|
// package.json
|
|
560
564
|
var package_default = {
|
|
561
|
-
version: "0.
|
|
565
|
+
version: "0.85.0"};
|
|
562
566
|
var PACKAGE_MANAGERS = ["npm", "pnpm", "yarn", "bun"];
|
|
563
567
|
var LOCKFILES = [
|
|
564
568
|
["pnpm-lock.yaml", "pnpm"],
|
|
@@ -723,7 +727,7 @@ async function formatItemsFromSchema(_functionInfo, items, startingNumber = 0, o
|
|
|
723
727
|
formatItemsGeneric(items, startingNumber);
|
|
724
728
|
}
|
|
725
729
|
function formatSingleItem(formatted, itemNumber) {
|
|
726
|
-
let titleLine = `${
|
|
730
|
+
let titleLine = `${chalk10.gray(`${itemNumber + 1}.`)} ${chalk10.cyan(formatted.title)}`;
|
|
727
731
|
const subtitleParts = [];
|
|
728
732
|
if (formatted.hint !== void 0) {
|
|
729
733
|
subtitleParts.push(
|
|
@@ -741,11 +745,11 @@ function formatSingleItem(formatted, itemNumber) {
|
|
|
741
745
|
}
|
|
742
746
|
const uniqueParts = [...new Set(subtitleParts)];
|
|
743
747
|
if (uniqueParts.length > 0) {
|
|
744
|
-
titleLine += ` ${
|
|
748
|
+
titleLine += ` ${chalk10.gray(`(${uniqueParts.join(", ")})`)}`;
|
|
745
749
|
}
|
|
746
750
|
console.log(titleLine);
|
|
747
751
|
if (formatted.description) {
|
|
748
|
-
console.log(` ${
|
|
752
|
+
console.log(` ${chalk10.dim(formatted.description)}`);
|
|
749
753
|
}
|
|
750
754
|
if (formatted.raw !== void 0) {
|
|
751
755
|
formatJsonOutput(formatted.raw);
|
|
@@ -756,7 +760,7 @@ function formatSingleItem(formatted, itemNumber) {
|
|
|
756
760
|
if (detail.label) {
|
|
757
761
|
const isMultiline = detail.text.includes("\n");
|
|
758
762
|
if (isMultiline) {
|
|
759
|
-
console.log(` ${
|
|
763
|
+
console.log(` ${chalk10.gray(detail.label + ":")}`);
|
|
760
764
|
const displayText = formatDetailText(
|
|
761
765
|
detail.text,
|
|
762
766
|
DETAIL_INDENT + " "
|
|
@@ -765,7 +769,7 @@ function formatSingleItem(formatted, itemNumber) {
|
|
|
765
769
|
console.log(`${DETAIL_INDENT} ${styledText}`);
|
|
766
770
|
} else {
|
|
767
771
|
const styledValue = applyStyle(detail.text, detail.style);
|
|
768
|
-
console.log(` ${
|
|
772
|
+
console.log(` ${chalk10.gray(detail.label + ":")} ${styledValue}`);
|
|
769
773
|
}
|
|
770
774
|
} else {
|
|
771
775
|
const displayText = formatDetailText(detail.text, DETAIL_INDENT);
|
|
@@ -789,16 +793,16 @@ function formatDetailText(text, indent = DETAIL_INDENT) {
|
|
|
789
793
|
function applyStyle(value, style) {
|
|
790
794
|
switch (style) {
|
|
791
795
|
case "dim":
|
|
792
|
-
return
|
|
796
|
+
return chalk10.dim(value);
|
|
793
797
|
case "accent":
|
|
794
|
-
return
|
|
798
|
+
return chalk10.magenta(value);
|
|
795
799
|
case "warning":
|
|
796
|
-
return
|
|
800
|
+
return chalk10.red(value);
|
|
797
801
|
case "success":
|
|
798
|
-
return
|
|
802
|
+
return chalk10.green(value);
|
|
799
803
|
case "normal":
|
|
800
804
|
default:
|
|
801
|
-
return
|
|
805
|
+
return chalk10.blue(value);
|
|
802
806
|
}
|
|
803
807
|
}
|
|
804
808
|
function convertGenericItemToFormattedItem(item) {
|
|
@@ -947,10 +951,10 @@ function createInteractiveRenderer(context = {}) {
|
|
|
947
951
|
const obj = item;
|
|
948
952
|
const name = obj?.name || obj?.key || obj?.id || "Item";
|
|
949
953
|
console.log(
|
|
950
|
-
`${
|
|
954
|
+
`${chalk10.gray(`${startingNumber + index + 1}.`)} ${chalk10.cyan(String(name))}`
|
|
951
955
|
);
|
|
952
956
|
if (obj?.description)
|
|
953
|
-
console.log(` ${
|
|
957
|
+
console.log(` ${chalk10.dim(String(obj.description))}`);
|
|
954
958
|
console.log();
|
|
955
959
|
});
|
|
956
960
|
}
|
|
@@ -961,35 +965,35 @@ function createInteractiveRenderer(context = {}) {
|
|
|
961
965
|
if (!(Symbol.asyncIterator in Object(source))) {
|
|
962
966
|
const items = source?.data;
|
|
963
967
|
if (!Array.isArray(items) || items.length === 0) {
|
|
964
|
-
console.log(
|
|
968
|
+
console.log(chalk10.yellow(`No ${itemName} found.`));
|
|
965
969
|
return;
|
|
966
970
|
}
|
|
967
971
|
await renderItemsForDisplay(items, functionInfo, 0);
|
|
968
|
-
console.log(
|
|
972
|
+
console.log(chalk10.green(`
|
|
969
973
|
\u2705 Showing ${items.length} ${itemName}`));
|
|
970
974
|
return;
|
|
971
975
|
}
|
|
972
976
|
let totalShown = 0;
|
|
973
977
|
let pageCount = 0;
|
|
974
|
-
console.log(
|
|
978
|
+
console.log(chalk10.blue(`\u{1F4CB} ${getListTitle(functionInfo)}
|
|
975
979
|
`));
|
|
976
980
|
for await (const page of source) {
|
|
977
981
|
const items = page.data ?? [];
|
|
978
982
|
pageCount++;
|
|
979
983
|
if (items.length === 0 && pageCount === 1) {
|
|
980
|
-
console.log(
|
|
984
|
+
console.log(chalk10.yellow(`No ${itemName} found.`));
|
|
981
985
|
return;
|
|
982
986
|
}
|
|
983
987
|
if (items.length === 0) break;
|
|
984
988
|
if (pageCount > 1) {
|
|
985
989
|
console.clear();
|
|
986
|
-
console.log(
|
|
990
|
+
console.log(chalk10.blue(`\u{1F4CB} ${getListTitle(functionInfo)}
|
|
987
991
|
`));
|
|
988
992
|
}
|
|
989
993
|
await renderItemsForDisplay(items, functionInfo, totalShown);
|
|
990
994
|
totalShown += items.length;
|
|
991
995
|
console.log(
|
|
992
|
-
|
|
996
|
+
chalk10.green(
|
|
993
997
|
`
|
|
994
998
|
\u2705 Showing ${totalShown} ${itemName} (page ${pageCount})`
|
|
995
999
|
)
|
|
@@ -1008,7 +1012,7 @@ function createInteractiveRenderer(context = {}) {
|
|
|
1008
1012
|
break;
|
|
1009
1013
|
}
|
|
1010
1014
|
}
|
|
1011
|
-
console.log(
|
|
1015
|
+
console.log(chalk10.gray(`
|
|
1012
1016
|
\u{1F4C4} Finished browsing ${itemName}`));
|
|
1013
1017
|
},
|
|
1014
1018
|
async renderCollectedList(items, { maxItems, userSpecifiedMaxItems, functionInfo } = {}) {
|
|
@@ -1018,30 +1022,30 @@ function createInteractiveRenderer(context = {}) {
|
|
|
1018
1022
|
}
|
|
1019
1023
|
const itemName = getItemName(functionInfo);
|
|
1020
1024
|
if (items.length === 0) {
|
|
1021
|
-
console.log(
|
|
1025
|
+
console.log(chalk10.yellow(`No ${itemName} found.`));
|
|
1022
1026
|
return;
|
|
1023
1027
|
}
|
|
1024
|
-
console.log(
|
|
1028
|
+
console.log(chalk10.green(`
|
|
1025
1029
|
\u2705 Found ${items.length} ${itemName}:
|
|
1026
1030
|
`));
|
|
1027
1031
|
await renderItemsForDisplay(items, functionInfo);
|
|
1028
1032
|
if (userSpecifiedMaxItems && maxItems) {
|
|
1029
1033
|
console.log(
|
|
1030
|
-
|
|
1034
|
+
chalk10.gray(
|
|
1031
1035
|
`
|
|
1032
1036
|
\u{1F4C4} Showing up to ${maxItems} ${itemName} (--max-items ${maxItems})`
|
|
1033
1037
|
)
|
|
1034
1038
|
);
|
|
1035
1039
|
} else {
|
|
1036
|
-
console.log(
|
|
1040
|
+
console.log(chalk10.gray(`
|
|
1037
1041
|
\u{1F4C4} All available ${itemName} shown`));
|
|
1038
1042
|
}
|
|
1039
1043
|
},
|
|
1040
1044
|
renderItem(value, options) {
|
|
1041
1045
|
if (options?.outputFile) {
|
|
1042
1046
|
const label = options.commandName ? `\u2705 ${options.commandName} completed successfully!` : "\u2705 Done!";
|
|
1043
|
-
console.log(
|
|
1044
|
-
console.log(
|
|
1047
|
+
console.log(chalk10.green(label));
|
|
1048
|
+
console.log(chalk10.gray(`Output written to: ${options.outputFile}`));
|
|
1045
1049
|
} else {
|
|
1046
1050
|
formatJsonOutput(value);
|
|
1047
1051
|
}
|
|
@@ -1051,17 +1055,17 @@ function createInteractiveRenderer(context = {}) {
|
|
|
1051
1055
|
},
|
|
1052
1056
|
renderError(error) {
|
|
1053
1057
|
if (error instanceof ZapierCliMissingParametersError) {
|
|
1054
|
-
console.error(
|
|
1055
|
-
console.error("\n" +
|
|
1058
|
+
console.error(chalk10.red("\u274C " + formatMissingParamsError(error)));
|
|
1059
|
+
console.error("\n" + chalk10.dim("Use --help to see available options"));
|
|
1056
1060
|
throw new ZapierCliExitError(error.message, 1);
|
|
1057
1061
|
}
|
|
1058
1062
|
if (isZapierError(error)) {
|
|
1059
1063
|
const formattedMessage = formatErrorMessage(error);
|
|
1060
|
-
console.error(
|
|
1064
|
+
console.error(chalk10.red("\u274C Error:"), formattedMessage);
|
|
1061
1065
|
throw new ZapierCliExitError(formattedMessage, 1);
|
|
1062
1066
|
}
|
|
1063
1067
|
const msg = error instanceof Error ? error.message : "Unknown error";
|
|
1064
|
-
console.error(
|
|
1068
|
+
console.error(chalk10.red("\u274C Error:"), msg);
|
|
1065
1069
|
throw new ZapierCliExitError(msg, 1);
|
|
1066
1070
|
}
|
|
1067
1071
|
};
|
|
@@ -1104,6 +1108,17 @@ function sanitizeCliArguments(args) {
|
|
|
1104
1108
|
function resolveNonInteractive(options) {
|
|
1105
1109
|
return options.nonInteractive === true || options.skipPrompts === true || !process.stdin.isTTY || !process.stdout.isTTY;
|
|
1106
1110
|
}
|
|
1111
|
+
function warningBlock({
|
|
1112
|
+
banner,
|
|
1113
|
+
message,
|
|
1114
|
+
detail
|
|
1115
|
+
}) {
|
|
1116
|
+
console.warn();
|
|
1117
|
+
console.warn(chalk10.yellow.bold(banner) + chalk10.yellow(message));
|
|
1118
|
+
if (detail) console.warn(chalk10.yellow(` ${detail}`));
|
|
1119
|
+
console.warn();
|
|
1120
|
+
}
|
|
1121
|
+
var DEPRECATION_BANNER = "\u26A0\uFE0F DEPRECATION WARNING";
|
|
1107
1122
|
var CLI_COMMAND_EXECUTED_EVENT_SUBJECT = "platform.sdk.CliCommandExecutedEvent";
|
|
1108
1123
|
var PAGINATION_PARAM_NAMES = /* @__PURE__ */ new Set(["maxItems", "pageSize", "cursor"]);
|
|
1109
1124
|
function getNormalizedResult(result, { isListCommand }) {
|
|
@@ -1177,7 +1192,7 @@ async function promptConfirm(confirmType, itemType) {
|
|
|
1177
1192
|
}
|
|
1178
1193
|
const configOrFn = CONFIRM_MESSAGES[confirmType];
|
|
1179
1194
|
const { messageBefore, messageAfter } = typeof configOrFn === "function" ? configOrFn(itemType) : configOrFn;
|
|
1180
|
-
console.log(
|
|
1195
|
+
console.log(chalk10.yellow(`
|
|
1181
1196
|
${messageBefore}
|
|
1182
1197
|
`));
|
|
1183
1198
|
const { confirmed } = await inquirer.prompt([
|
|
@@ -1199,16 +1214,11 @@ function emitParamDeprecationWarnings({
|
|
|
1199
1214
|
const value = options[param.name];
|
|
1200
1215
|
if (value === void 0) continue;
|
|
1201
1216
|
if (Array.isArray(value) && value.length === 0) continue;
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
);
|
|
1208
|
-
if (param.deprecationMessage) {
|
|
1209
|
-
console.warn(chalk9.yellow(` ${param.deprecationMessage}`));
|
|
1210
|
-
}
|
|
1211
|
-
console.warn();
|
|
1217
|
+
warningBlock({
|
|
1218
|
+
banner: DEPRECATION_BANNER,
|
|
1219
|
+
message: ` - \`${toKebabCase(param.name)}\` is deprecated and may be removed in a future release.`,
|
|
1220
|
+
detail: param.deprecationMessage
|
|
1221
|
+
});
|
|
1212
1222
|
}
|
|
1213
1223
|
}
|
|
1214
1224
|
function resolveOutputMode({
|
|
@@ -1423,6 +1433,12 @@ function readCliRegistry(sdk) {
|
|
|
1423
1433
|
function generateCliCommands(program2, sdk) {
|
|
1424
1434
|
const registry = readCliRegistry(sdk);
|
|
1425
1435
|
if (!registry) return;
|
|
1436
|
+
const stabilityByCommandName = new Map(
|
|
1437
|
+
registry.functions.map((fn) => [
|
|
1438
|
+
methodNameToCliCommand(fn.name),
|
|
1439
|
+
fn.stability
|
|
1440
|
+
])
|
|
1441
|
+
);
|
|
1426
1442
|
registry.functions.forEach((fnInfo) => {
|
|
1427
1443
|
if (!fnInfo.inputSchema) {
|
|
1428
1444
|
console.warn(`Schema not found for ${fnInfo.name}`);
|
|
@@ -1457,6 +1473,15 @@ function generateCliCommands(program2, sdk) {
|
|
|
1457
1473
|
const commands = helper.visibleCommands(cmd);
|
|
1458
1474
|
if (commands.length > 0) {
|
|
1459
1475
|
output += "\nCommands:\n";
|
|
1476
|
+
const labeledSubcommandTerm = (command) => {
|
|
1477
|
+
const term = helper.subcommandTerm(command);
|
|
1478
|
+
const name = command.name();
|
|
1479
|
+
const labeledName = applyStabilityLabel({
|
|
1480
|
+
description: name,
|
|
1481
|
+
stability: stabilityByCommandName.get(name)
|
|
1482
|
+
});
|
|
1483
|
+
return labeledName !== name && term.startsWith(name) ? labeledName + term.slice(name.length) : term;
|
|
1484
|
+
};
|
|
1460
1485
|
const categorizedCommands = /* @__PURE__ */ new Set();
|
|
1461
1486
|
registry.categories.forEach((category) => {
|
|
1462
1487
|
const categoryCommands = commands.filter(
|
|
@@ -1470,7 +1495,7 @@ function generateCliCommands(program2, sdk) {
|
|
|
1470
1495
|
${category.titlePlural}:
|
|
1471
1496
|
`;
|
|
1472
1497
|
categoryCommands.forEach((command) => {
|
|
1473
|
-
output += ` ${
|
|
1498
|
+
output += ` ${labeledSubcommandTerm(command)}
|
|
1474
1499
|
`;
|
|
1475
1500
|
categorizedCommands.add(command.name());
|
|
1476
1501
|
});
|
|
@@ -1484,7 +1509,7 @@ function generateCliCommands(program2, sdk) {
|
|
|
1484
1509
|
Other:
|
|
1485
1510
|
`;
|
|
1486
1511
|
otherCommands.forEach((command) => {
|
|
1487
|
-
output += ` ${
|
|
1512
|
+
output += ` ${labeledSubcommandTerm(command)}
|
|
1488
1513
|
`;
|
|
1489
1514
|
});
|
|
1490
1515
|
}
|
|
@@ -1509,7 +1534,10 @@ function createCommandConfig(cliCommandName, functionInfo, sdk) {
|
|
|
1509
1534
|
}
|
|
1510
1535
|
}
|
|
1511
1536
|
const baseDescription = functionInfo.description || schema?.description || `${cliCommandName} command`;
|
|
1512
|
-
const description =
|
|
1537
|
+
const description = applyStabilityLabel({
|
|
1538
|
+
description: baseDescription,
|
|
1539
|
+
stability: functionInfo.stability
|
|
1540
|
+
});
|
|
1513
1541
|
const handler = async (...args) => {
|
|
1514
1542
|
const startTime = Date.now();
|
|
1515
1543
|
let success = true;
|
|
@@ -1605,7 +1633,7 @@ function createCommandConfig(cliCommandName, functionInfo, sdk) {
|
|
|
1605
1633
|
functionInfo.itemType
|
|
1606
1634
|
);
|
|
1607
1635
|
if (!confirmResult.confirmed) {
|
|
1608
|
-
console.log(
|
|
1636
|
+
console.log(chalk10.yellow("Operation cancelled."));
|
|
1609
1637
|
return;
|
|
1610
1638
|
}
|
|
1611
1639
|
confirmMessageAfter = confirmResult.messageAfter;
|
|
@@ -1666,7 +1694,7 @@ function createCommandConfig(cliCommandName, functionInfo, sdk) {
|
|
|
1666
1694
|
renderer.renderItem(normalizedResult.value);
|
|
1667
1695
|
}
|
|
1668
1696
|
if (confirmMessageAfter) {
|
|
1669
|
-
console.log(
|
|
1697
|
+
console.log(chalk10.yellow(`
|
|
1670
1698
|
${confirmMessageAfter}`));
|
|
1671
1699
|
}
|
|
1672
1700
|
break;
|
|
@@ -3085,14 +3113,14 @@ function formatCredentialsChoice({
|
|
|
3085
3113
|
credentials: credentials2,
|
|
3086
3114
|
current
|
|
3087
3115
|
}) {
|
|
3088
|
-
const currentLabel = current ?
|
|
3116
|
+
const currentLabel = current ? chalk10.cyan(" (current)") : "";
|
|
3089
3117
|
const details = [
|
|
3090
3118
|
credentials2.clientId,
|
|
3091
3119
|
credentials2.scopes.join(", "),
|
|
3092
3120
|
`created ${createdAtIso(credentials2).slice(0, 10)}`
|
|
3093
3121
|
].join(" \xB7 ");
|
|
3094
3122
|
return {
|
|
3095
|
-
name: `${credentials2.name}${currentLabel} ${
|
|
3123
|
+
name: `${credentials2.name}${currentLabel} ${chalk10.dim(`\xB7 ${details}`)}`,
|
|
3096
3124
|
short: credentials2.name,
|
|
3097
3125
|
value: { action: "switch", credentials: credentials2 }
|
|
3098
3126
|
};
|
|
@@ -3268,20 +3296,20 @@ var getCallablePromise = () => {
|
|
|
3268
3296
|
var getCallablePromise_default = getCallablePromise;
|
|
3269
3297
|
var log = {
|
|
3270
3298
|
info: (message, ...args) => {
|
|
3271
|
-
console.error(
|
|
3299
|
+
console.error(chalk10.blue("\u2139"), message, ...args);
|
|
3272
3300
|
},
|
|
3273
3301
|
error: (message, ...args) => {
|
|
3274
|
-
console.error(
|
|
3302
|
+
console.error(chalk10.red("\u2716"), message, ...args);
|
|
3275
3303
|
},
|
|
3276
3304
|
success: (message, ...args) => {
|
|
3277
|
-
console.error(
|
|
3305
|
+
console.error(chalk10.green("\u2713"), message, ...args);
|
|
3278
3306
|
},
|
|
3279
3307
|
warn: (message, ...args) => {
|
|
3280
|
-
console.error(
|
|
3308
|
+
console.error(chalk10.yellow("\u26A0"), message, ...args);
|
|
3281
3309
|
},
|
|
3282
3310
|
debug: (message, ...args) => {
|
|
3283
3311
|
if (process.env.DEBUG === "true" || process.argv.includes("--debug")) {
|
|
3284
|
-
console.error(
|
|
3312
|
+
console.error(chalk10.gray("\u{1F41B}"), message, ...args);
|
|
3285
3313
|
}
|
|
3286
3314
|
}
|
|
3287
3315
|
};
|
|
@@ -4439,9 +4467,9 @@ async function provisionAccountCredentials({
|
|
|
4439
4467
|
isNonInteractive,
|
|
4440
4468
|
isHeadless
|
|
4441
4469
|
}) {
|
|
4442
|
-
const scopedSdk = createSdk$
|
|
4470
|
+
const scopedSdk = createSdk$2(accountCredentialsApiPlugin, {
|
|
4443
4471
|
configuration: {
|
|
4444
|
-
[SDK_OPTIONS_ID$
|
|
4472
|
+
[SDK_OPTIONS_ID$2]: {
|
|
4445
4473
|
credentials: accessToken,
|
|
4446
4474
|
baseUrl: credentialsBaseUrl2,
|
|
4447
4475
|
callerPackage: imports.sdkOptions?.callerPackage,
|
|
@@ -4793,9 +4821,10 @@ var CLI_EXTENSIONS_ID = "cli/extensions";
|
|
|
4793
4821
|
var cliExtensionsPluginRef = declareOptionalProperty({
|
|
4794
4822
|
id: CLI_EXTENSIONS_ID
|
|
4795
4823
|
});
|
|
4796
|
-
var
|
|
4797
|
-
var
|
|
4798
|
-
|
|
4824
|
+
var EXPERIMENTAL_BIN_ENV = "ZAPIER_SDK_EXPERIMENTAL_BIN";
|
|
4825
|
+
var CLI_STABILITY_ID = "cli/stability";
|
|
4826
|
+
var cliStabilityPluginRef = declareOptionalProperty({
|
|
4827
|
+
id: CLI_STABILITY_ID
|
|
4799
4828
|
});
|
|
4800
4829
|
var McpSchema = z.object({
|
|
4801
4830
|
port: z.string().optional().describe("Port to listen on (for future HTTP transport)")
|
|
@@ -4804,11 +4833,7 @@ var McpSchema = z.object({
|
|
|
4804
4833
|
// src/plugins/mcp/index.ts
|
|
4805
4834
|
var mcpPlugin = defineMethod({
|
|
4806
4835
|
name: "mcp",
|
|
4807
|
-
imports: [
|
|
4808
|
-
sdkOptionsPluginRef,
|
|
4809
|
-
cliExtensionsPluginRef,
|
|
4810
|
-
cliExperimentalPluginRef
|
|
4811
|
-
],
|
|
4836
|
+
imports: [sdkOptionsPluginRef, cliExtensionsPluginRef, cliStabilityPluginRef],
|
|
4812
4837
|
output: "raw",
|
|
4813
4838
|
inputSchema: McpSchema,
|
|
4814
4839
|
categories: ["utility"],
|
|
@@ -4818,7 +4843,7 @@ var mcpPlugin = defineMethod({
|
|
|
4818
4843
|
debug: imports.sdkOptions?.debug,
|
|
4819
4844
|
maxConcurrentRequests: imports.sdkOptions?.maxConcurrentRequests,
|
|
4820
4845
|
extensions: imports.extensions,
|
|
4821
|
-
|
|
4846
|
+
stability: imports.stability
|
|
4822
4847
|
});
|
|
4823
4848
|
}
|
|
4824
4849
|
});
|
|
@@ -6449,7 +6474,7 @@ function buildTemplateVariables({
|
|
|
6449
6474
|
};
|
|
6450
6475
|
}
|
|
6451
6476
|
function cleanupProject({ projectDir }) {
|
|
6452
|
-
console.log("\n" +
|
|
6477
|
+
console.log("\n" + chalk10.yellow("!") + " Cleaning up...");
|
|
6453
6478
|
rmSync(projectDir, { recursive: true, force: true });
|
|
6454
6479
|
}
|
|
6455
6480
|
async function withInterruptCleanup(cleanup, fn) {
|
|
@@ -6659,8 +6684,8 @@ function buildNextSteps({
|
|
|
6659
6684
|
}
|
|
6660
6685
|
function createConsoleDisplayHooks() {
|
|
6661
6686
|
return {
|
|
6662
|
-
onItemComplete: (message) => console.log(" " +
|
|
6663
|
-
onWarn: (message) => console.warn(
|
|
6687
|
+
onItemComplete: (message) => console.log(" " + chalk10.green("\u2713") + " " + chalk10.dim(message)),
|
|
6688
|
+
onWarn: (message) => console.warn(chalk10.yellow("!") + " " + message),
|
|
6664
6689
|
onStepStart: ({
|
|
6665
6690
|
description,
|
|
6666
6691
|
stepNumber,
|
|
@@ -6669,31 +6694,31 @@ function createConsoleDisplayHooks() {
|
|
|
6669
6694
|
nonInteractive
|
|
6670
6695
|
}) => {
|
|
6671
6696
|
const progressMessage = `${description}...`;
|
|
6672
|
-
const stepCounter =
|
|
6697
|
+
const stepCounter = chalk10.dim(`${stepNumber}/${totalSteps}`);
|
|
6673
6698
|
if (nonInteractive) {
|
|
6674
6699
|
console.log(
|
|
6675
|
-
"\n" +
|
|
6700
|
+
"\n" + chalk10.bold(`\u276F ${progressMessage}`) + " " + stepCounter + "\n"
|
|
6676
6701
|
);
|
|
6677
6702
|
} else {
|
|
6678
6703
|
console.log(
|
|
6679
|
-
|
|
6704
|
+
chalk10.dim("\u2192") + " " + progressMessage + " " + stepCounter
|
|
6680
6705
|
);
|
|
6681
6706
|
}
|
|
6682
6707
|
if (command) {
|
|
6683
|
-
console.log(" " +
|
|
6708
|
+
console.log(" " + chalk10.cyan(`$ ${command}`));
|
|
6684
6709
|
}
|
|
6685
6710
|
},
|
|
6686
6711
|
onStepSuccess: ({ stepNumber, totalSteps }) => console.log(
|
|
6687
|
-
"\n" +
|
|
6712
|
+
"\n" + chalk10.green("\u2713") + " " + chalk10.dim(`Step ${stepNumber}/${totalSteps} complete`) + "\n"
|
|
6688
6713
|
),
|
|
6689
6714
|
onStepError: ({ description, command, err }) => {
|
|
6690
6715
|
const detail = err instanceof Error && err.message ? `
|
|
6691
|
-
${
|
|
6716
|
+
${chalk10.dim(err.message)}` : "";
|
|
6692
6717
|
const hint = command ? `
|
|
6693
|
-
${
|
|
6718
|
+
${chalk10.dim("run manually:")} ${chalk10.cyan(`$ ${command}`)}` : "";
|
|
6694
6719
|
console.error(
|
|
6695
6720
|
`
|
|
6696
|
-
${
|
|
6721
|
+
${chalk10.red("\u2716")} ${chalk10.bold(description)}${chalk10.dim(" failed")}${detail}${hint}`
|
|
6697
6722
|
);
|
|
6698
6723
|
}
|
|
6699
6724
|
};
|
|
@@ -6705,22 +6730,22 @@ function displaySummaryAndNextSteps({
|
|
|
6705
6730
|
packageManager
|
|
6706
6731
|
}) {
|
|
6707
6732
|
const formatStatus = (complete) => ({
|
|
6708
|
-
icon: complete ?
|
|
6709
|
-
text: complete ?
|
|
6733
|
+
icon: complete ? chalk10.green("\u2713") : chalk10.yellow("!"),
|
|
6734
|
+
text: complete ? chalk10.green("Setup complete") : chalk10.yellow("Setup interrupted")
|
|
6710
6735
|
});
|
|
6711
|
-
const formatNextStep = (step, i) => " " +
|
|
6712
|
-
const formatCommand = (cmd) => " " +
|
|
6713
|
-
const formatCompletedStep = (step) => " " +
|
|
6736
|
+
const formatNextStep = (step, i) => " " + chalk10.dim(`${i + 1}.`) + " " + chalk10.bold(step.description);
|
|
6737
|
+
const formatCommand = (cmd) => " " + chalk10.cyan(`$ ${cmd}`);
|
|
6738
|
+
const formatCompletedStep = (step) => " " + chalk10.green("\u2713") + " " + step.description;
|
|
6714
6739
|
const { execCmd } = getPackageManagerCommands({ packageManager });
|
|
6715
6740
|
const leftoverSteps = steps.filter(
|
|
6716
6741
|
(s) => !completedSetupStepIds.includes(s.id)
|
|
6717
6742
|
);
|
|
6718
6743
|
const isComplete = leftoverSteps.length === 0;
|
|
6719
6744
|
const status = formatStatus(isComplete);
|
|
6720
|
-
console.log("\n" +
|
|
6721
|
-
console.log(" " +
|
|
6745
|
+
console.log("\n" + chalk10.bold("\u276F Summary") + "\n");
|
|
6746
|
+
console.log(" " + chalk10.dim("Project") + " " + chalk10.bold(projectName));
|
|
6722
6747
|
console.log(
|
|
6723
|
-
" " +
|
|
6748
|
+
" " + chalk10.dim("Status") + " " + status.icon + " " + status.text
|
|
6724
6749
|
);
|
|
6725
6750
|
const completedSteps = steps.filter(
|
|
6726
6751
|
(s) => completedSetupStepIds.includes(s.id)
|
|
@@ -6730,7 +6755,7 @@ function displaySummaryAndNextSteps({
|
|
|
6730
6755
|
for (const step of completedSteps) console.log(formatCompletedStep(step));
|
|
6731
6756
|
}
|
|
6732
6757
|
const nextSteps = buildNextSteps({ projectName, leftoverSteps, execCmd });
|
|
6733
|
-
console.log("\n" +
|
|
6758
|
+
console.log("\n" + chalk10.bold("\u276F Next Steps") + "\n");
|
|
6734
6759
|
nextSteps.forEach((step, i) => {
|
|
6735
6760
|
console.log(formatNextStep(step, i));
|
|
6736
6761
|
if (step.command) console.log(formatCommand(step.command));
|
|
@@ -6915,26 +6940,26 @@ function displayUpdateNotification(versionInfo, packageName) {
|
|
|
6915
6940
|
if (versionInfo.isDeprecated) {
|
|
6916
6941
|
console.error();
|
|
6917
6942
|
console.error(
|
|
6918
|
-
|
|
6943
|
+
chalk10.red.bold("\u26A0\uFE0F DEPRECATION WARNING") + chalk10.red(
|
|
6919
6944
|
` - ${packageName} v${versionInfo.currentVersion} is deprecated.`
|
|
6920
6945
|
)
|
|
6921
6946
|
);
|
|
6922
6947
|
if (versionInfo.deprecationMessage) {
|
|
6923
|
-
console.error(
|
|
6948
|
+
console.error(chalk10.red(` ${versionInfo.deprecationMessage}`));
|
|
6924
6949
|
}
|
|
6925
|
-
console.error(
|
|
6950
|
+
console.error(chalk10.red(` Please update to the latest version.`));
|
|
6926
6951
|
console.error();
|
|
6927
6952
|
}
|
|
6928
6953
|
if (versionInfo.hasUpdate) {
|
|
6929
6954
|
console.error();
|
|
6930
6955
|
console.error(
|
|
6931
|
-
|
|
6956
|
+
chalk10.yellow.bold("\u{1F4E6} Update available!") + chalk10.yellow(
|
|
6932
6957
|
` ${packageName} v${versionInfo.currentVersion} \u2192 v${versionInfo.latestVersion}`
|
|
6933
6958
|
)
|
|
6934
6959
|
);
|
|
6935
6960
|
console.error(
|
|
6936
|
-
|
|
6937
|
-
` Run ${
|
|
6961
|
+
chalk10.yellow(
|
|
6962
|
+
` Run ${chalk10.bold(getUpdateCommand(packageName))} to update.`
|
|
6938
6963
|
)
|
|
6939
6964
|
);
|
|
6940
6965
|
console.error();
|
|
@@ -6975,7 +7000,7 @@ var boltFillRanks = new Map(
|
|
|
6975
7000
|
);
|
|
6976
7001
|
var STATUS_ROW_INDEX = Math.floor(boltRows.length / 2);
|
|
6977
7002
|
function formatPhase({ label, detail }) {
|
|
6978
|
-
return detail ? `${
|
|
7003
|
+
return detail ? `${chalk10.bold(label)} ${chalk10.dim(detail)}` : chalk10.bold(label);
|
|
6979
7004
|
}
|
|
6980
7005
|
function formatLoaderFrame({
|
|
6981
7006
|
phase,
|
|
@@ -6987,7 +7012,7 @@ function formatLoaderFrame({
|
|
|
6987
7012
|
const cellIndex = rowIndex * row.length + columnIndex;
|
|
6988
7013
|
const fillRank = boltFillRanks.get(cellIndex);
|
|
6989
7014
|
const isFilled = fillRank !== void 0 && fillRank < fillStage;
|
|
6990
|
-
return isFilled ?
|
|
7015
|
+
return isFilled ? chalk10.bold.yellow(cell) : chalk10.dim.yellow(cell);
|
|
6991
7016
|
}).join("");
|
|
6992
7017
|
const status = rowIndex === STATUS_ROW_INDEX ? ` ${formatPhase(phase)}` : "";
|
|
6993
7018
|
return `${bolt}${status}`;
|
|
@@ -7019,12 +7044,12 @@ async function runWithSetupLoader({
|
|
|
7019
7044
|
const result = await promise;
|
|
7020
7045
|
clearInterval(animationTimer);
|
|
7021
7046
|
const elapsedSeconds = ((Date.now() - startedAt) / 1e3).toFixed(1);
|
|
7022
|
-
loader.succeed(`${formatPhase(phase)} ${
|
|
7047
|
+
loader.succeed(`${formatPhase(phase)} ${chalk10.dim(`${elapsedSeconds}s`)}`);
|
|
7023
7048
|
return result;
|
|
7024
7049
|
} catch (error) {
|
|
7025
7050
|
clearInterval(animationTimer);
|
|
7026
7051
|
const elapsedSeconds = ((Date.now() - startedAt) / 1e3).toFixed(1);
|
|
7027
|
-
loader.fail(`${formatPhase(phase)} ${
|
|
7052
|
+
loader.fail(`${formatPhase(phase)} ${chalk10.dim(`${elapsedSeconds}s`)}`);
|
|
7028
7053
|
throw error;
|
|
7029
7054
|
}
|
|
7030
7055
|
}
|
|
@@ -7090,7 +7115,7 @@ var resolveSetupInputPlugin = defineMethod({
|
|
|
7090
7115
|
run: ({ input }) => input
|
|
7091
7116
|
});
|
|
7092
7117
|
function createSetupController() {
|
|
7093
|
-
const setupResolutionSdk = createSdk$
|
|
7118
|
+
const setupResolutionSdk = createSdk$2(
|
|
7094
7119
|
definePlugin({
|
|
7095
7120
|
name: "setup-resolution",
|
|
7096
7121
|
exports: [
|
|
@@ -7515,7 +7540,7 @@ async function runCommand({
|
|
|
7515
7540
|
detail: commandLabel
|
|
7516
7541
|
});
|
|
7517
7542
|
}
|
|
7518
|
-
console.log(
|
|
7543
|
+
console.log(chalk10.dim(commandLabel));
|
|
7519
7544
|
return await execute;
|
|
7520
7545
|
} catch (error) {
|
|
7521
7546
|
const message = error instanceof Error ? error.message : String(error);
|
|
@@ -7782,7 +7807,7 @@ function printAgentPrompt({
|
|
|
7782
7807
|
message
|
|
7783
7808
|
}) {
|
|
7784
7809
|
console.log();
|
|
7785
|
-
console.log(
|
|
7810
|
+
console.log(chalk10.bgYellow.black.bold(message));
|
|
7786
7811
|
console.log();
|
|
7787
7812
|
console.log(buildAgentPrompt({ context }));
|
|
7788
7813
|
}
|
|
@@ -8067,7 +8092,7 @@ var MINIMUM_MESSAGE_WIDTH = 20;
|
|
|
8067
8092
|
var MAXIMUM_MESSAGE_WIDTH = 88;
|
|
8068
8093
|
function showPhase({ number, title }) {
|
|
8069
8094
|
console.log();
|
|
8070
|
-
console.log(
|
|
8095
|
+
console.log(chalk10.bgCyan.black.bold(` ${number}/${PHASE_COUNT} ${title} `));
|
|
8071
8096
|
}
|
|
8072
8097
|
function printWrapped(text) {
|
|
8073
8098
|
const width = Math.max(
|
|
@@ -8081,7 +8106,7 @@ function printWrapped(text) {
|
|
|
8081
8106
|
}
|
|
8082
8107
|
function showReadyMessage() {
|
|
8083
8108
|
console.log();
|
|
8084
|
-
console.log(
|
|
8109
|
+
console.log(chalk10.bgGreen.black.bold(" \u2713 Zapier SDK setup complete "));
|
|
8085
8110
|
console.log();
|
|
8086
8111
|
printWrapped(
|
|
8087
8112
|
"Use active Zapier connections to access 9,000+ app connectors without managing each app's OAuth, token refresh, or retries."
|
|
@@ -8093,7 +8118,7 @@ function showReadyMessage() {
|
|
|
8093
8118
|
console.log();
|
|
8094
8119
|
}
|
|
8095
8120
|
async function runWizard(context) {
|
|
8096
|
-
console.log(
|
|
8121
|
+
console.log(chalk10.bold("Zapier SDK setup"));
|
|
8097
8122
|
showPhase({ number: 1, title: "Project directory" });
|
|
8098
8123
|
await chooseDirectory(context);
|
|
8099
8124
|
showPhase({ number: 2, title: "Node.js" });
|
|
@@ -8108,7 +8133,7 @@ async function runWizard(context) {
|
|
|
8108
8133
|
showPhase({ number: 6, title: "Slack demo" });
|
|
8109
8134
|
await offerSlackTest(context);
|
|
8110
8135
|
showReadyMessage();
|
|
8111
|
-
console.log(
|
|
8136
|
+
console.log(chalk10.bgCyan.black.bold(" Next steps "));
|
|
8112
8137
|
await openAgentHandoff(context);
|
|
8113
8138
|
}
|
|
8114
8139
|
|
|
@@ -8157,13 +8182,13 @@ function createInteractiveCallback() {
|
|
|
8157
8182
|
const attrs = message.message_attributes;
|
|
8158
8183
|
console.log(
|
|
8159
8184
|
`
|
|
8160
|
-
${
|
|
8185
|
+
${chalk10.bold(`Message #${messageNumber}`)} ${chalk10.dim(message.id)} ${chalk10.dim(`(lease #${attrs.lease_count})`)}`
|
|
8161
8186
|
);
|
|
8162
8187
|
if (attrs.error_message) {
|
|
8163
|
-
console.log(
|
|
8188
|
+
console.log(chalk10.yellow(` upstream error: ${attrs.error_message}`));
|
|
8164
8189
|
}
|
|
8165
8190
|
if (attrs.possible_duplicate_data) {
|
|
8166
|
-
console.log(
|
|
8191
|
+
console.log(chalk10.yellow(" possible duplicate data"));
|
|
8167
8192
|
}
|
|
8168
8193
|
while (true) {
|
|
8169
8194
|
let action;
|
|
@@ -8193,7 +8218,7 @@ ${chalk9.bold(`Message #${messageNumber}`)} ${chalk9.dim(message.id)} ${chalk9.d
|
|
|
8193
8218
|
throw error;
|
|
8194
8219
|
}
|
|
8195
8220
|
if (action === "view") {
|
|
8196
|
-
console.log(
|
|
8221
|
+
console.log(chalk10.dim(JSON.stringify(message.payload, null, 2)));
|
|
8197
8222
|
continue;
|
|
8198
8223
|
}
|
|
8199
8224
|
if (action === "ack") {
|
|
@@ -8296,7 +8321,7 @@ function describeReason(reason) {
|
|
|
8296
8321
|
}
|
|
8297
8322
|
function printDrainError(reason, message) {
|
|
8298
8323
|
console.error(
|
|
8299
|
-
|
|
8324
|
+
chalk10.red(`Error processing ${message.id}: ${describeReason(reason)}`)
|
|
8300
8325
|
);
|
|
8301
8326
|
}
|
|
8302
8327
|
function printDrainSummary(counts) {
|
|
@@ -8306,7 +8331,7 @@ function printDrainSummary(counts) {
|
|
|
8306
8331
|
if (skipped > 0) parts.push(`${skipped} skipped`);
|
|
8307
8332
|
parts.push(`${counts.rejected} rejected`);
|
|
8308
8333
|
console.log(
|
|
8309
|
-
|
|
8334
|
+
chalk10.dim(
|
|
8310
8335
|
`
|
|
8311
8336
|
Processed ${total} message${total === 1 ? "" : "s"} (${parts.join(", ")}).`
|
|
8312
8337
|
)
|
|
@@ -8314,7 +8339,7 @@ Processed ${total} message${total === 1 ? "" : "s"} (${parts.join(", ")}).`
|
|
|
8314
8339
|
}
|
|
8315
8340
|
function warnInteractiveContinueOnErrorOverride() {
|
|
8316
8341
|
console.warn(
|
|
8317
|
-
|
|
8342
|
+
chalk10.yellow(
|
|
8318
8343
|
'Note: continueOnError=false is overridden to true in interactive mode (the "Skip (let lease expire)" choice would otherwise terminate the drain).'
|
|
8319
8344
|
)
|
|
8320
8345
|
);
|
|
@@ -8640,7 +8665,7 @@ var createWorkflowCliPlugin = defineMethod$1({
|
|
|
8640
8665
|
type: "create",
|
|
8641
8666
|
itemType: "Workflow",
|
|
8642
8667
|
categories: ["code-workflow"],
|
|
8643
|
-
|
|
8668
|
+
stability: "experimental",
|
|
8644
8669
|
inputSchema: CreateWorkflowCliOptionsSchema,
|
|
8645
8670
|
outputSchema: CreateWorkflowResponseSchema,
|
|
8646
8671
|
skipOutputValidation: true,
|
|
@@ -8672,7 +8697,7 @@ function renderDeprecationNotices() {
|
|
|
8672
8697
|
console.error();
|
|
8673
8698
|
for (const message of messages) {
|
|
8674
8699
|
for (const line of buildBoxLines(message)) {
|
|
8675
|
-
console.error(
|
|
8700
|
+
console.error(chalk10.red.bold(line));
|
|
8676
8701
|
}
|
|
8677
8702
|
console.error();
|
|
8678
8703
|
}
|
|
@@ -8693,21 +8718,33 @@ function buildBoxLines(message) {
|
|
|
8693
8718
|
// package.json with { type: 'json' }
|
|
8694
8719
|
var package_default2 = {
|
|
8695
8720
|
name: "@zapier/zapier-sdk-cli",
|
|
8696
|
-
version: "0.
|
|
8721
|
+
version: "0.85.0"};
|
|
8697
8722
|
|
|
8698
8723
|
// src/sdk.ts
|
|
8699
8724
|
var warnedDeprecatedMethods = /* @__PURE__ */ new Set();
|
|
8725
|
+
var warnedStabilityMethods = /* @__PURE__ */ new Set();
|
|
8700
8726
|
var cliCoreOptions = {
|
|
8701
8727
|
...zapierCoreOptions,
|
|
8702
8728
|
logDeprecation: ({ methodName, deprecation }) => {
|
|
8703
8729
|
if (warnedDeprecatedMethods.has(methodName)) return;
|
|
8704
8730
|
warnedDeprecatedMethods.add(methodName);
|
|
8705
|
-
|
|
8706
|
-
|
|
8707
|
-
|
|
8708
|
-
|
|
8709
|
-
|
|
8710
|
-
|
|
8731
|
+
warningBlock({
|
|
8732
|
+
banner: DEPRECATION_BANNER,
|
|
8733
|
+
message: ` - \`${toKebabCase(methodName)}\` is deprecated.`,
|
|
8734
|
+
detail: deprecation.message
|
|
8735
|
+
});
|
|
8736
|
+
},
|
|
8737
|
+
logStabilityNotice: ({ methodName, stability }) => {
|
|
8738
|
+
if (stability === "stable") return;
|
|
8739
|
+
if (warnedStabilityMethods.has(methodName)) return;
|
|
8740
|
+
warnedStabilityMethods.add(methodName);
|
|
8741
|
+
warningBlock({
|
|
8742
|
+
banner: `\u26A0\uFE0F ${stability.toUpperCase()} COMMAND`,
|
|
8743
|
+
message: ` - \`${toKebabCase(methodName)}\` is marked ${stability}.`,
|
|
8744
|
+
// The detail line is the tier's consumer contract, so the CLI says the
|
|
8745
|
+
// same thing as the SDK's runtime notice and the generated docs.
|
|
8746
|
+
detail: STABILITY_DEFINITIONS[stability]
|
|
8747
|
+
});
|
|
8711
8748
|
}
|
|
8712
8749
|
};
|
|
8713
8750
|
injectCliLogin(login_exports);
|
|
@@ -8753,15 +8790,72 @@ function createZapierCliSdk(options = {}) {
|
|
|
8753
8790
|
// cannot be hidden by any rendering path.
|
|
8754
8791
|
onEvent: (event) => collectDeprecationNoticeAndForward(event, sdkOptions.onEvent)
|
|
8755
8792
|
};
|
|
8756
|
-
const sdk = createSdk$
|
|
8793
|
+
const sdk = createSdk$2(cliSdkPlugin, {
|
|
8757
8794
|
configuration: {
|
|
8758
|
-
[SDK_OPTIONS_ID$
|
|
8759
|
-
[CORE_OPTIONS_ID$
|
|
8795
|
+
[SDK_OPTIONS_ID$2]: stackOptions,
|
|
8796
|
+
[CORE_OPTIONS_ID$2]: cliCoreOptions,
|
|
8760
8797
|
// Resolved extensions, forwarded to `mcp` (imported by ref there) so
|
|
8761
8798
|
// the MCP server's SDK matches the CLI surface.
|
|
8762
8799
|
[CLI_EXTENSIONS_ID]: extensions
|
|
8763
8800
|
}
|
|
8764
8801
|
});
|
|
8802
|
+
addPlugin$2(sdk, cliFetchOverride);
|
|
8803
|
+
for (const ext of extensions) {
|
|
8804
|
+
try {
|
|
8805
|
+
addPlugin$2(sdk, ext);
|
|
8806
|
+
} catch (err) {
|
|
8807
|
+
console.warn(formatExtensionPluginFailure$2(err));
|
|
8808
|
+
}
|
|
8809
|
+
}
|
|
8810
|
+
return sdk;
|
|
8811
|
+
}
|
|
8812
|
+
injectCliLogin$1(login_exports);
|
|
8813
|
+
function createZapierCliSdk2(options = {}) {
|
|
8814
|
+
const { extensions = [], ...sdkOptions } = options;
|
|
8815
|
+
const stackOptions = {
|
|
8816
|
+
...sdkOptions,
|
|
8817
|
+
eventEmission: { ...sdkOptions.eventEmission, callContext: "cli" },
|
|
8818
|
+
callerPackage: { name: package_default2.name, version: package_default2.version },
|
|
8819
|
+
// Collected for the boxed stderr warning rendered in the exit path. The
|
|
8820
|
+
// box is additive: the SDK's own inline warn still fires, so the notice
|
|
8821
|
+
// cannot be hidden by any rendering path.
|
|
8822
|
+
onEvent: (event) => collectDeprecationNoticeAndForward(event, sdkOptions.onEvent)
|
|
8823
|
+
};
|
|
8824
|
+
const cliBetaSdkPlugin = definePlugin$2({
|
|
8825
|
+
namespace: "zapier",
|
|
8826
|
+
name: "cli-beta-sdk",
|
|
8827
|
+
exports: [
|
|
8828
|
+
omitExports$2(zapierBetaSdkPlugin, [
|
|
8829
|
+
"drainTriggerInbox",
|
|
8830
|
+
"watchTriggerInbox"
|
|
8831
|
+
]),
|
|
8832
|
+
drainTriggerInboxCliPlugin,
|
|
8833
|
+
watchTriggerInboxCliPlugin,
|
|
8834
|
+
loginPlugin,
|
|
8835
|
+
signupPlugin,
|
|
8836
|
+
logoutPlugin,
|
|
8837
|
+
mcpPlugin,
|
|
8838
|
+
getLoginConfigPathPlugin,
|
|
8839
|
+
initPlugin,
|
|
8840
|
+
setupPlugin,
|
|
8841
|
+
bundleCodePlugin,
|
|
8842
|
+
feedbackPlugin,
|
|
8843
|
+
curlPlugin,
|
|
8844
|
+
addAppsPlugin,
|
|
8845
|
+
buildManifestPlugin,
|
|
8846
|
+
generateAppTypesPlugin
|
|
8847
|
+
]
|
|
8848
|
+
});
|
|
8849
|
+
const sdk = createSdk$1(cliBetaSdkPlugin, {
|
|
8850
|
+
configuration: {
|
|
8851
|
+
[SDK_OPTIONS_ID$1]: stackOptions,
|
|
8852
|
+
[CORE_OPTIONS_ID$1]: cliCoreOptions,
|
|
8853
|
+
[CLI_EXTENSIONS_ID]: extensions,
|
|
8854
|
+
// Built by the beta factory: `mcp` reads this to launch the beta MCP
|
|
8855
|
+
// server so the surfaces stay aligned.
|
|
8856
|
+
[CLI_STABILITY_ID]: "beta"
|
|
8857
|
+
}
|
|
8858
|
+
});
|
|
8765
8859
|
addPlugin$1(sdk, cliFetchOverride);
|
|
8766
8860
|
for (const ext of extensions) {
|
|
8767
8861
|
try {
|
|
@@ -8772,8 +8866,8 @@ function createZapierCliSdk(options = {}) {
|
|
|
8772
8866
|
}
|
|
8773
8867
|
return sdk;
|
|
8774
8868
|
}
|
|
8775
|
-
injectCliLogin$
|
|
8776
|
-
function
|
|
8869
|
+
injectCliLogin$2(login_exports);
|
|
8870
|
+
function createZapierCliSdk3(options = {}) {
|
|
8777
8871
|
const { extensions = [], ...sdkOptions } = options;
|
|
8778
8872
|
const stackOptions = {
|
|
8779
8873
|
...sdkOptions,
|
|
@@ -8818,7 +8912,7 @@ function createZapierCliSdk2(options = {}) {
|
|
|
8818
8912
|
[CLI_EXTENSIONS_ID]: extensions,
|
|
8819
8913
|
// Built by the experimental factory: `mcp` reads this to launch the
|
|
8820
8914
|
// experimental MCP server so the surfaces stay aligned.
|
|
8821
|
-
[
|
|
8915
|
+
[CLI_STABILITY_ID]: "experimental"
|
|
8822
8916
|
}
|
|
8823
8917
|
});
|
|
8824
8918
|
addPlugin(sdk, cliFetchOverride);
|
|
@@ -8959,11 +9053,11 @@ function buildFrameLines(state, frameIndex) {
|
|
|
8959
9053
|
const bodyWidth = width - 2;
|
|
8960
9054
|
const bodyTextWidth = innerWidth - 2;
|
|
8961
9055
|
const content = [];
|
|
8962
|
-
content.push(
|
|
9056
|
+
content.push(chalk10.bold.cyan("Approval review"));
|
|
8963
9057
|
content.push("");
|
|
8964
9058
|
if (!state.verdict) {
|
|
8965
9059
|
content.push(
|
|
8966
|
-
|
|
9060
|
+
chalk10.yellow(`${SPINNER_FRAMES[frameIndex]} Checking approval...`)
|
|
8967
9061
|
);
|
|
8968
9062
|
}
|
|
8969
9063
|
const recentMessages = state.messages.slice(-5);
|
|
@@ -8974,13 +9068,13 @@ function buildFrameLines(state, frameIndex) {
|
|
|
8974
9068
|
"\n"
|
|
8975
9069
|
);
|
|
8976
9070
|
segments.forEach((segment, segmentIndex) => {
|
|
8977
|
-
const prefix = segmentIndex === 0 ?
|
|
8978
|
-
content.push(`${prefix}${dimmed ?
|
|
9071
|
+
const prefix = segmentIndex === 0 ? chalk10.cyan("> ") : " ";
|
|
9072
|
+
content.push(`${prefix}${dimmed ? chalk10.dim(segment) : segment}`);
|
|
8979
9073
|
});
|
|
8980
9074
|
});
|
|
8981
9075
|
if (state.streamError) {
|
|
8982
9076
|
if (hasMessages || !state.verdict) content.push("");
|
|
8983
|
-
content.push(
|
|
9077
|
+
content.push(chalk10.bold.red("Approval stream error"));
|
|
8984
9078
|
for (const segment of wrapAnsi4(state.streamError, bodyTextWidth, {
|
|
8985
9079
|
hard: true
|
|
8986
9080
|
}).split("\n")) {
|
|
@@ -8990,7 +9084,7 @@ function buildFrameLines(state, frameIndex) {
|
|
|
8990
9084
|
if (state.verdict) {
|
|
8991
9085
|
if (hasMessages || state.streamError) content.push("");
|
|
8992
9086
|
content.push(
|
|
8993
|
-
|
|
9087
|
+
chalk10.bold.green(`${state.verdict.icon} ${state.verdict.label}`)
|
|
8994
9088
|
);
|
|
8995
9089
|
if (state.verdict.reason) {
|
|
8996
9090
|
for (const segment of wrapAnsi4(state.verdict.reason, bodyTextWidth, {
|
|
@@ -9002,12 +9096,12 @@ function buildFrameLines(state, frameIndex) {
|
|
|
9002
9096
|
}
|
|
9003
9097
|
const pad = (line) => {
|
|
9004
9098
|
const padding = " ".repeat(Math.max(0, innerWidth - displayWidth(line)));
|
|
9005
|
-
return `${
|
|
9099
|
+
return `${chalk10.cyan("\u2502")} ${line}${padding} ${chalk10.cyan("\u2502")}`;
|
|
9006
9100
|
};
|
|
9007
9101
|
return [
|
|
9008
|
-
|
|
9102
|
+
chalk10.cyan(`\u256D${"\u2500".repeat(bodyWidth)}\u256E`),
|
|
9009
9103
|
...content.map(pad),
|
|
9010
|
-
|
|
9104
|
+
chalk10.cyan(`\u2570${"\u2500".repeat(bodyWidth)}\u256F`)
|
|
9011
9105
|
];
|
|
9012
9106
|
}
|
|
9013
9107
|
function createApprovalProgressRenderer({
|
|
@@ -9207,6 +9301,7 @@ var EXIT_GRACE_PERIOD_MILLISECONDS = 500;
|
|
|
9207
9301
|
var program = new Command();
|
|
9208
9302
|
var versionOption = getReservedCliOption("version" /* Version */);
|
|
9209
9303
|
var helpOption = getReservedCliOption("help" /* Help */);
|
|
9304
|
+
var stabilityOption = getReservedCliOption("stability" /* Stability */);
|
|
9210
9305
|
program.name("zapier-sdk").description("CLI for Zapier SDK").version(
|
|
9211
9306
|
package_default2.version,
|
|
9212
9307
|
`${versionOption.short}, ${versionOption.flag}`,
|
|
@@ -9235,7 +9330,10 @@ program.name("zapier-sdk").description("CLI for Zapier SDK").version(
|
|
|
9235
9330
|
).option(
|
|
9236
9331
|
"--causation-id <id>",
|
|
9237
9332
|
"Causation ID emitted as the zapier-causation-id header on every outbound request. Falls back to ZAPIER_CAUSATION_ID."
|
|
9238
|
-
).option(
|
|
9333
|
+
).option(stabilityOption.flag, stabilityOption.description).option(
|
|
9334
|
+
"--experimental",
|
|
9335
|
+
"Deprecated. Use --stability experimental instead."
|
|
9336
|
+
);
|
|
9239
9337
|
var booleanFlags = [];
|
|
9240
9338
|
for (const [key, fieldSchema] of Object.entries(
|
|
9241
9339
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
@@ -9321,8 +9419,57 @@ for (const { camelName, kebabFlag } of booleanFlags) {
|
|
|
9321
9419
|
flagOverrides[camelName] = true;
|
|
9322
9420
|
}
|
|
9323
9421
|
}
|
|
9324
|
-
|
|
9325
|
-
|
|
9422
|
+
function parseStabilityLevel(value, source) {
|
|
9423
|
+
if (value === void 0) return void 0;
|
|
9424
|
+
if (STABILITY_LEVELS.includes(value)) {
|
|
9425
|
+
return value;
|
|
9426
|
+
}
|
|
9427
|
+
console.error(
|
|
9428
|
+
`Invalid ${source} value "${value}". Valid stability levels: ${STABILITY_LEVELS.join(", ")}.`
|
|
9429
|
+
);
|
|
9430
|
+
process.exit(1);
|
|
9431
|
+
}
|
|
9432
|
+
function warnDeprecatedOptIn(used, replacement) {
|
|
9433
|
+
warningBlock({
|
|
9434
|
+
banner: DEPRECATION_BANNER,
|
|
9435
|
+
message: ` - \`${used}\` is deprecated.`,
|
|
9436
|
+
detail: `Use \`${replacement}\` instead.`
|
|
9437
|
+
});
|
|
9438
|
+
}
|
|
9439
|
+
function resolveCliStability() {
|
|
9440
|
+
const flagLevel = parseStabilityLevel(
|
|
9441
|
+
getFlagValue("--stability"),
|
|
9442
|
+
"--stability"
|
|
9443
|
+
);
|
|
9444
|
+
if (flagLevel) return flagLevel;
|
|
9445
|
+
if (process.argv.includes("--experimental")) {
|
|
9446
|
+
if (process.env[EXPERIMENTAL_BIN_ENV] === "1") {
|
|
9447
|
+
warnDeprecatedOptIn(
|
|
9448
|
+
"zapier-sdk-experimental",
|
|
9449
|
+
"zapier-sdk --stability experimental"
|
|
9450
|
+
);
|
|
9451
|
+
} else {
|
|
9452
|
+
warnDeprecatedOptIn("--experimental", "--stability experimental");
|
|
9453
|
+
}
|
|
9454
|
+
return "experimental";
|
|
9455
|
+
}
|
|
9456
|
+
const envLevel = parseStabilityLevel(
|
|
9457
|
+
process.env.ZAPIER_STABILITY || void 0,
|
|
9458
|
+
"ZAPIER_STABILITY"
|
|
9459
|
+
);
|
|
9460
|
+
if (envLevel) return envLevel;
|
|
9461
|
+
if (process.env.ZAPIER_EXPERIMENTAL === "1" || process.env.ZAPIER_EXPERIMENTAL === "true") {
|
|
9462
|
+
warnDeprecatedOptIn("ZAPIER_EXPERIMENTAL", "ZAPIER_STABILITY=experimental");
|
|
9463
|
+
return "experimental";
|
|
9464
|
+
}
|
|
9465
|
+
return "stable";
|
|
9466
|
+
}
|
|
9467
|
+
var cliStability = resolveCliStability();
|
|
9468
|
+
var createZapierCliSdk4 = {
|
|
9469
|
+
stable: createZapierCliSdk,
|
|
9470
|
+
beta: createZapierCliSdk2,
|
|
9471
|
+
experimental: createZapierCliSdk3
|
|
9472
|
+
}[cliStability];
|
|
9326
9473
|
var approvalProgress = createApprovalProgressRenderer({
|
|
9327
9474
|
enabled: process.stderr.isTTY === true
|
|
9328
9475
|
});
|
|
@@ -9330,7 +9477,7 @@ program.exitOverride();
|
|
|
9330
9477
|
(async () => {
|
|
9331
9478
|
let exitCode = 0;
|
|
9332
9479
|
const extensions = await resolveExtensions();
|
|
9333
|
-
const sdk =
|
|
9480
|
+
const sdk = createZapierCliSdk4({
|
|
9334
9481
|
debug: isDebugMode,
|
|
9335
9482
|
credentials,
|
|
9336
9483
|
baseUrl,
|