@zapier/zapier-sdk-cli 0.82.1 → 0.82.2
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 +10 -0
- package/dist/cli.cjs +38 -3
- package/dist/cli.mjs +41 -6
- package/dist/experimental.cjs +37 -2
- package/dist/experimental.mjs +38 -3
- package/dist/index.cjs +35 -2
- package/dist/index.mjs +38 -5
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# @zapier/zapier-sdk-cli
|
|
2
2
|
|
|
3
|
+
## 0.82.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 545562b: Experimental `create-workflow` now records creation attribution automatically.
|
|
8
|
+
- Updated dependencies [545562b]
|
|
9
|
+
- Updated dependencies [545562b]
|
|
10
|
+
- @zapier/zapier-sdk-mcp@0.24.2
|
|
11
|
+
- @zapier/zapier-sdk@0.110.2
|
|
12
|
+
|
|
3
13
|
## 0.82.1
|
|
4
14
|
|
|
5
15
|
### Patch Changes
|
package/dist/cli.cjs
CHANGED
|
@@ -602,7 +602,7 @@ var SHARED_COMMAND_CLI_OPTIONS = [
|
|
|
602
602
|
|
|
603
603
|
// package.json
|
|
604
604
|
var package_default = {
|
|
605
|
-
version: "0.82.
|
|
605
|
+
version: "0.82.2"};
|
|
606
606
|
var PACKAGE_MANAGERS = ["npm", "pnpm", "yarn", "bun"];
|
|
607
607
|
var LOCKFILES = [
|
|
608
608
|
["pnpm-lock.yaml", "pnpm"],
|
|
@@ -8657,6 +8657,39 @@ var watchTriggerInboxCliPlugin = zapierSdk.defineMethod({
|
|
|
8657
8657
|
return doWatch();
|
|
8658
8658
|
}
|
|
8659
8659
|
});
|
|
8660
|
+
var createWorkflowRef = experimental.declareMethod({ id: "createWorkflow" });
|
|
8661
|
+
function createPublicInputSchema(schema) {
|
|
8662
|
+
return zod.z.object(
|
|
8663
|
+
Object.fromEntries(
|
|
8664
|
+
Object.entries(schema.shape).filter(
|
|
8665
|
+
([name]) => !experimental.INTERNAL_CREATE_WORKFLOW_FIELDS.includes(
|
|
8666
|
+
name
|
|
8667
|
+
)
|
|
8668
|
+
)
|
|
8669
|
+
)
|
|
8670
|
+
).describe(schema.description ?? "Create a workflow");
|
|
8671
|
+
}
|
|
8672
|
+
var CreateWorkflowCliOptionsSchema = createPublicInputSchema(
|
|
8673
|
+
experimental.CreateWorkflowOptionsSchema
|
|
8674
|
+
);
|
|
8675
|
+
var createWorkflowCliPlugin = experimental.defineMethod({
|
|
8676
|
+
namespace: "cli",
|
|
8677
|
+
name: "createWorkflow",
|
|
8678
|
+
imports: [createWorkflowRef],
|
|
8679
|
+
type: "create",
|
|
8680
|
+
itemType: "Workflow",
|
|
8681
|
+
categories: ["code-workflow"],
|
|
8682
|
+
experimental: true,
|
|
8683
|
+
inputSchema: CreateWorkflowCliOptionsSchema,
|
|
8684
|
+
outputSchema: experimental.CreateWorkflowResponseSchema,
|
|
8685
|
+
skipOutputValidation: true,
|
|
8686
|
+
output: "raw",
|
|
8687
|
+
run: ({ imports, input }) => imports.createWorkflow({
|
|
8688
|
+
...input,
|
|
8689
|
+
creationHarness: experimental.getAgent(),
|
|
8690
|
+
creationAccessMethod: "sdk_cli"
|
|
8691
|
+
})
|
|
8692
|
+
});
|
|
8660
8693
|
var BOX_WIDTH = 72;
|
|
8661
8694
|
var BOX_TITLE = "ZAPIER SDK DEPRECATION NOTICE";
|
|
8662
8695
|
var activeNotices = /* @__PURE__ */ new Map();
|
|
@@ -8699,7 +8732,7 @@ function buildBoxLines(message) {
|
|
|
8699
8732
|
// package.json with { type: 'json' }
|
|
8700
8733
|
var package_default2 = {
|
|
8701
8734
|
name: "@zapier/zapier-sdk-cli",
|
|
8702
|
-
version: "0.82.
|
|
8735
|
+
version: "0.82.2"};
|
|
8703
8736
|
|
|
8704
8737
|
// src/sdk.ts
|
|
8705
8738
|
var warnedDeprecatedMethods = /* @__PURE__ */ new Set();
|
|
@@ -8798,10 +8831,12 @@ function createZapierCliSdk2(options = {}) {
|
|
|
8798
8831
|
exports: [
|
|
8799
8832
|
experimental.omitExports(experimental.zapierExperimentalSdkPlugin, [
|
|
8800
8833
|
"drainTriggerInbox",
|
|
8801
|
-
"watchTriggerInbox"
|
|
8834
|
+
"watchTriggerInbox",
|
|
8835
|
+
"createWorkflow"
|
|
8802
8836
|
]),
|
|
8803
8837
|
drainTriggerInboxCliPlugin,
|
|
8804
8838
|
watchTriggerInboxCliPlugin,
|
|
8839
|
+
createWorkflowCliPlugin,
|
|
8805
8840
|
loginPlugin,
|
|
8806
8841
|
signupPlugin,
|
|
8807
8842
|
logoutPlugin,
|
package/dist/cli.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
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$1, CORE_OPTIONS_ID as CORE_OPTIONS_ID$1, SDK_OPTIONS_ID as SDK_OPTIONS_ID$1, addPlugin as addPlugin$1, resolvePlugin, isCredentialsObject, getRegistryPlugin, createController, ZapierAbortDrainSignal, ZapierReleaseTriggerMessageSignal, buildApplicationLifecycleEvent, AuthMechanism, DEPRECATION_NOTICE_EVENT, runWithCallerContext, isCoreCancelledSignal, getNegatable, isPositional, isZapierError, formatErrorMessage, getOsInfo, getPlatformVersions, getAgent, getTtyContext, getCiPlatform, isCi, isZapierConflictError, getReleaseId, getCurrentTimestamp, generateEventId, isZapierApprovalError, ZapierAuthenticationError } from '@zapier/zapier-sdk';
|
|
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$1, CORE_OPTIONS_ID as CORE_OPTIONS_ID$1, SDK_OPTIONS_ID as SDK_OPTIONS_ID$1, addPlugin as addPlugin$1, resolvePlugin, isCredentialsObject, getRegistryPlugin, createController, ZapierAbortDrainSignal, ZapierReleaseTriggerMessageSignal, 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
6
|
import chalk9 from 'chalk';
|
|
@@ -34,7 +34,7 @@ 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, injectCliLogin as injectCliLogin$1, definePlugin as definePlugin$1, omitExports as omitExports$1, zapierExperimentalSdkPlugin, createSdk, CORE_OPTIONS_ID, SDK_OPTIONS_ID, addPlugin } from '@zapier/zapier-sdk/experimental';
|
|
37
|
+
import { triggerInboxResolver, DrainTriggerInboxSchema, WatchTriggerInboxSchema, declareMethod as declareMethod$1, defineMethod as defineMethod$1, CreateWorkflowResponseSchema, getAgent, injectCliLogin as injectCliLogin$1, INTERNAL_CREATE_WORKFLOW_FIELDS, CreateWorkflowOptionsSchema, definePlugin as definePlugin$1, omitExports as omitExports$1, zapierExperimentalSdkPlugin, createSdk, CORE_OPTIONS_ID, SDK_OPTIONS_ID, addPlugin } from '@zapier/zapier-sdk/experimental';
|
|
38
38
|
import * as readline from 'readline';
|
|
39
39
|
|
|
40
40
|
var __defProp = Object.defineProperty;
|
|
@@ -558,7 +558,7 @@ var SHARED_COMMAND_CLI_OPTIONS = [
|
|
|
558
558
|
|
|
559
559
|
// package.json
|
|
560
560
|
var package_default = {
|
|
561
|
-
version: "0.82.
|
|
561
|
+
version: "0.82.2"};
|
|
562
562
|
var PACKAGE_MANAGERS = ["npm", "pnpm", "yarn", "bun"];
|
|
563
563
|
var LOCKFILES = [
|
|
564
564
|
["pnpm-lock.yaml", "pnpm"],
|
|
@@ -684,7 +684,7 @@ function buildCliCommandExecutedEvent({
|
|
|
684
684
|
is_ci_environment: isCi(),
|
|
685
685
|
ci_platform: getCiPlatform(),
|
|
686
686
|
...getTtyContext(),
|
|
687
|
-
agent: getAgent(),
|
|
687
|
+
agent: getAgent$1(),
|
|
688
688
|
package_manager: data.package_manager ?? detectPackageManager(process.cwd()).name,
|
|
689
689
|
made_network_requests: data.made_network_requests ?? null,
|
|
690
690
|
files_modified_count: data.files_modified_count ?? null,
|
|
@@ -8613,6 +8613,39 @@ var watchTriggerInboxCliPlugin = defineMethod({
|
|
|
8613
8613
|
return doWatch();
|
|
8614
8614
|
}
|
|
8615
8615
|
});
|
|
8616
|
+
var createWorkflowRef = declareMethod$1({ id: "createWorkflow" });
|
|
8617
|
+
function createPublicInputSchema(schema) {
|
|
8618
|
+
return z.object(
|
|
8619
|
+
Object.fromEntries(
|
|
8620
|
+
Object.entries(schema.shape).filter(
|
|
8621
|
+
([name]) => !INTERNAL_CREATE_WORKFLOW_FIELDS.includes(
|
|
8622
|
+
name
|
|
8623
|
+
)
|
|
8624
|
+
)
|
|
8625
|
+
)
|
|
8626
|
+
).describe(schema.description ?? "Create a workflow");
|
|
8627
|
+
}
|
|
8628
|
+
var CreateWorkflowCliOptionsSchema = createPublicInputSchema(
|
|
8629
|
+
CreateWorkflowOptionsSchema
|
|
8630
|
+
);
|
|
8631
|
+
var createWorkflowCliPlugin = defineMethod$1({
|
|
8632
|
+
namespace: "cli",
|
|
8633
|
+
name: "createWorkflow",
|
|
8634
|
+
imports: [createWorkflowRef],
|
|
8635
|
+
type: "create",
|
|
8636
|
+
itemType: "Workflow",
|
|
8637
|
+
categories: ["code-workflow"],
|
|
8638
|
+
experimental: true,
|
|
8639
|
+
inputSchema: CreateWorkflowCliOptionsSchema,
|
|
8640
|
+
outputSchema: CreateWorkflowResponseSchema,
|
|
8641
|
+
skipOutputValidation: true,
|
|
8642
|
+
output: "raw",
|
|
8643
|
+
run: ({ imports, input }) => imports.createWorkflow({
|
|
8644
|
+
...input,
|
|
8645
|
+
creationHarness: getAgent(),
|
|
8646
|
+
creationAccessMethod: "sdk_cli"
|
|
8647
|
+
})
|
|
8648
|
+
});
|
|
8616
8649
|
var BOX_WIDTH = 72;
|
|
8617
8650
|
var BOX_TITLE = "ZAPIER SDK DEPRECATION NOTICE";
|
|
8618
8651
|
var activeNotices = /* @__PURE__ */ new Map();
|
|
@@ -8655,7 +8688,7 @@ function buildBoxLines(message) {
|
|
|
8655
8688
|
// package.json with { type: 'json' }
|
|
8656
8689
|
var package_default2 = {
|
|
8657
8690
|
name: "@zapier/zapier-sdk-cli",
|
|
8658
|
-
version: "0.82.
|
|
8691
|
+
version: "0.82.2"};
|
|
8659
8692
|
|
|
8660
8693
|
// src/sdk.ts
|
|
8661
8694
|
var warnedDeprecatedMethods = /* @__PURE__ */ new Set();
|
|
@@ -8754,10 +8787,12 @@ function createZapierCliSdk2(options = {}) {
|
|
|
8754
8787
|
exports: [
|
|
8755
8788
|
omitExports$1(zapierExperimentalSdkPlugin, [
|
|
8756
8789
|
"drainTriggerInbox",
|
|
8757
|
-
"watchTriggerInbox"
|
|
8790
|
+
"watchTriggerInbox",
|
|
8791
|
+
"createWorkflow"
|
|
8758
8792
|
]),
|
|
8759
8793
|
drainTriggerInboxCliPlugin,
|
|
8760
8794
|
watchTriggerInboxCliPlugin,
|
|
8795
|
+
createWorkflowCliPlugin,
|
|
8761
8796
|
loginPlugin,
|
|
8762
8797
|
signupPlugin,
|
|
8763
8798
|
logoutPlugin,
|
package/dist/experimental.cjs
CHANGED
|
@@ -7176,6 +7176,39 @@ var watchTriggerInboxCliPlugin = zapierSdk.defineMethod({
|
|
|
7176
7176
|
return doWatch();
|
|
7177
7177
|
}
|
|
7178
7178
|
});
|
|
7179
|
+
var createWorkflowRef = experimental.declareMethod({ id: "createWorkflow" });
|
|
7180
|
+
function createPublicInputSchema(schema) {
|
|
7181
|
+
return zod.z.object(
|
|
7182
|
+
Object.fromEntries(
|
|
7183
|
+
Object.entries(schema.shape).filter(
|
|
7184
|
+
([name]) => !experimental.INTERNAL_CREATE_WORKFLOW_FIELDS.includes(
|
|
7185
|
+
name
|
|
7186
|
+
)
|
|
7187
|
+
)
|
|
7188
|
+
)
|
|
7189
|
+
).describe(schema.description ?? "Create a workflow");
|
|
7190
|
+
}
|
|
7191
|
+
var CreateWorkflowCliOptionsSchema = createPublicInputSchema(
|
|
7192
|
+
experimental.CreateWorkflowOptionsSchema
|
|
7193
|
+
);
|
|
7194
|
+
var createWorkflowCliPlugin = experimental.defineMethod({
|
|
7195
|
+
namespace: "cli",
|
|
7196
|
+
name: "createWorkflow",
|
|
7197
|
+
imports: [createWorkflowRef],
|
|
7198
|
+
type: "create",
|
|
7199
|
+
itemType: "Workflow",
|
|
7200
|
+
categories: ["code-workflow"],
|
|
7201
|
+
experimental: true,
|
|
7202
|
+
inputSchema: CreateWorkflowCliOptionsSchema,
|
|
7203
|
+
outputSchema: experimental.CreateWorkflowResponseSchema,
|
|
7204
|
+
skipOutputValidation: true,
|
|
7205
|
+
output: "raw",
|
|
7206
|
+
run: ({ imports, input }) => imports.createWorkflow({
|
|
7207
|
+
...input,
|
|
7208
|
+
creationHarness: experimental.getAgent(),
|
|
7209
|
+
creationAccessMethod: "sdk_cli"
|
|
7210
|
+
})
|
|
7211
|
+
});
|
|
7179
7212
|
var activeNotices = /* @__PURE__ */ new Map();
|
|
7180
7213
|
function collectDeprecationNotice(event) {
|
|
7181
7214
|
if (event.type !== zapierSdk.DEPRECATION_NOTICE_EVENT) return;
|
|
@@ -7192,7 +7225,7 @@ function collectDeprecationNoticeAndForward(event, onEvent) {
|
|
|
7192
7225
|
// package.json with { type: 'json' }
|
|
7193
7226
|
var package_default = {
|
|
7194
7227
|
name: "@zapier/zapier-sdk-cli",
|
|
7195
|
-
version: "0.82.
|
|
7228
|
+
version: "0.82.2"};
|
|
7196
7229
|
|
|
7197
7230
|
// src/sdk.ts
|
|
7198
7231
|
var warnedDeprecatedMethods = /* @__PURE__ */ new Set();
|
|
@@ -7261,10 +7294,12 @@ function createZapierCliSdk(options = {}) {
|
|
|
7261
7294
|
exports: [
|
|
7262
7295
|
experimental.omitExports(experimental.zapierExperimentalSdkPlugin, [
|
|
7263
7296
|
"drainTriggerInbox",
|
|
7264
|
-
"watchTriggerInbox"
|
|
7297
|
+
"watchTriggerInbox",
|
|
7298
|
+
"createWorkflow"
|
|
7265
7299
|
]),
|
|
7266
7300
|
drainTriggerInboxCliPlugin,
|
|
7267
7301
|
watchTriggerInboxCliPlugin,
|
|
7302
|
+
createWorkflowCliPlugin,
|
|
7268
7303
|
loginPlugin,
|
|
7269
7304
|
signupPlugin,
|
|
7270
7305
|
logoutPlugin,
|
package/dist/experimental.mjs
CHANGED
|
@@ -9,7 +9,7 @@ import { resolve, join, dirname, basename, relative, extname } from 'path';
|
|
|
9
9
|
import * as lockfile from 'proper-lockfile';
|
|
10
10
|
import { 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, invalidateCachedToken, batch, toSnakeCase, ZapierError, isZapierReleaseTriggerMessageSignal, createSdk, SDK_OPTIONS_ID, resolvePlugin, isCredentialsObject, getRegistryPlugin, createController, ZapierAbortDrainSignal, ZapierReleaseTriggerMessageSignal, buildApplicationLifecycleEvent, AuthMechanism, isCoreCancelledSignal, ZapierAuthenticationError, DEPRECATION_NOTICE_EVENT } from '@zapier/zapier-sdk';
|
|
11
11
|
import { z } from 'zod';
|
|
12
|
-
import { triggerInboxResolver, DrainTriggerInboxSchema, WatchTriggerInboxSchema, injectCliLogin as injectCliLogin$1, definePlugin as definePlugin$1, omitExports as omitExports$1, zapierExperimentalSdkPlugin, createSdk as createSdk$1, CORE_OPTIONS_ID, SDK_OPTIONS_ID as SDK_OPTIONS_ID$1, addPlugin } from '@zapier/zapier-sdk/experimental';
|
|
12
|
+
import { triggerInboxResolver, DrainTriggerInboxSchema, WatchTriggerInboxSchema, declareMethod as declareMethod$1, defineMethod as defineMethod$1, CreateWorkflowResponseSchema, getAgent, injectCliLogin as injectCliLogin$1, INTERNAL_CREATE_WORKFLOW_FIELDS, CreateWorkflowOptionsSchema, definePlugin as definePlugin$1, omitExports as omitExports$1, zapierExperimentalSdkPlugin, createSdk as createSdk$1, CORE_OPTIONS_ID, SDK_OPTIONS_ID as SDK_OPTIONS_ID$1, addPlugin } from '@zapier/zapier-sdk/experimental';
|
|
13
13
|
import { hostname } from 'os';
|
|
14
14
|
import inquirer4 from 'inquirer';
|
|
15
15
|
import chalk5 from 'chalk';
|
|
@@ -7135,6 +7135,39 @@ var watchTriggerInboxCliPlugin = defineMethod({
|
|
|
7135
7135
|
return doWatch();
|
|
7136
7136
|
}
|
|
7137
7137
|
});
|
|
7138
|
+
var createWorkflowRef = declareMethod$1({ id: "createWorkflow" });
|
|
7139
|
+
function createPublicInputSchema(schema) {
|
|
7140
|
+
return z.object(
|
|
7141
|
+
Object.fromEntries(
|
|
7142
|
+
Object.entries(schema.shape).filter(
|
|
7143
|
+
([name]) => !INTERNAL_CREATE_WORKFLOW_FIELDS.includes(
|
|
7144
|
+
name
|
|
7145
|
+
)
|
|
7146
|
+
)
|
|
7147
|
+
)
|
|
7148
|
+
).describe(schema.description ?? "Create a workflow");
|
|
7149
|
+
}
|
|
7150
|
+
var CreateWorkflowCliOptionsSchema = createPublicInputSchema(
|
|
7151
|
+
CreateWorkflowOptionsSchema
|
|
7152
|
+
);
|
|
7153
|
+
var createWorkflowCliPlugin = defineMethod$1({
|
|
7154
|
+
namespace: "cli",
|
|
7155
|
+
name: "createWorkflow",
|
|
7156
|
+
imports: [createWorkflowRef],
|
|
7157
|
+
type: "create",
|
|
7158
|
+
itemType: "Workflow",
|
|
7159
|
+
categories: ["code-workflow"],
|
|
7160
|
+
experimental: true,
|
|
7161
|
+
inputSchema: CreateWorkflowCliOptionsSchema,
|
|
7162
|
+
outputSchema: CreateWorkflowResponseSchema,
|
|
7163
|
+
skipOutputValidation: true,
|
|
7164
|
+
output: "raw",
|
|
7165
|
+
run: ({ imports, input }) => imports.createWorkflow({
|
|
7166
|
+
...input,
|
|
7167
|
+
creationHarness: getAgent(),
|
|
7168
|
+
creationAccessMethod: "sdk_cli"
|
|
7169
|
+
})
|
|
7170
|
+
});
|
|
7138
7171
|
var activeNotices = /* @__PURE__ */ new Map();
|
|
7139
7172
|
function collectDeprecationNotice(event) {
|
|
7140
7173
|
if (event.type !== DEPRECATION_NOTICE_EVENT) return;
|
|
@@ -7151,7 +7184,7 @@ function collectDeprecationNoticeAndForward(event, onEvent) {
|
|
|
7151
7184
|
// package.json with { type: 'json' }
|
|
7152
7185
|
var package_default = {
|
|
7153
7186
|
name: "@zapier/zapier-sdk-cli",
|
|
7154
|
-
version: "0.82.
|
|
7187
|
+
version: "0.82.2"};
|
|
7155
7188
|
|
|
7156
7189
|
// src/sdk.ts
|
|
7157
7190
|
var warnedDeprecatedMethods = /* @__PURE__ */ new Set();
|
|
@@ -7220,10 +7253,12 @@ function createZapierCliSdk(options = {}) {
|
|
|
7220
7253
|
exports: [
|
|
7221
7254
|
omitExports$1(zapierExperimentalSdkPlugin, [
|
|
7222
7255
|
"drainTriggerInbox",
|
|
7223
|
-
"watchTriggerInbox"
|
|
7256
|
+
"watchTriggerInbox",
|
|
7257
|
+
"createWorkflow"
|
|
7224
7258
|
]),
|
|
7225
7259
|
drainTriggerInboxCliPlugin,
|
|
7226
7260
|
watchTriggerInboxCliPlugin,
|
|
7261
|
+
createWorkflowCliPlugin,
|
|
7227
7262
|
loginPlugin,
|
|
7228
7263
|
signupPlugin,
|
|
7229
7264
|
logoutPlugin,
|
package/dist/index.cjs
CHANGED
|
@@ -7177,6 +7177,39 @@ var watchTriggerInboxCliPlugin = zapierSdk.defineMethod({
|
|
|
7177
7177
|
return doWatch();
|
|
7178
7178
|
}
|
|
7179
7179
|
});
|
|
7180
|
+
var createWorkflowRef = experimental.declareMethod({ id: "createWorkflow" });
|
|
7181
|
+
function createPublicInputSchema(schema) {
|
|
7182
|
+
return zod.z.object(
|
|
7183
|
+
Object.fromEntries(
|
|
7184
|
+
Object.entries(schema.shape).filter(
|
|
7185
|
+
([name]) => !experimental.INTERNAL_CREATE_WORKFLOW_FIELDS.includes(
|
|
7186
|
+
name
|
|
7187
|
+
)
|
|
7188
|
+
)
|
|
7189
|
+
)
|
|
7190
|
+
).describe(schema.description ?? "Create a workflow");
|
|
7191
|
+
}
|
|
7192
|
+
var CreateWorkflowCliOptionsSchema = createPublicInputSchema(
|
|
7193
|
+
experimental.CreateWorkflowOptionsSchema
|
|
7194
|
+
);
|
|
7195
|
+
experimental.defineMethod({
|
|
7196
|
+
namespace: "cli",
|
|
7197
|
+
name: "createWorkflow",
|
|
7198
|
+
imports: [createWorkflowRef],
|
|
7199
|
+
type: "create",
|
|
7200
|
+
itemType: "Workflow",
|
|
7201
|
+
categories: ["code-workflow"],
|
|
7202
|
+
experimental: true,
|
|
7203
|
+
inputSchema: CreateWorkflowCliOptionsSchema,
|
|
7204
|
+
outputSchema: experimental.CreateWorkflowResponseSchema,
|
|
7205
|
+
skipOutputValidation: true,
|
|
7206
|
+
output: "raw",
|
|
7207
|
+
run: ({ imports, input }) => imports.createWorkflow({
|
|
7208
|
+
...input,
|
|
7209
|
+
creationHarness: experimental.getAgent(),
|
|
7210
|
+
creationAccessMethod: "sdk_cli"
|
|
7211
|
+
})
|
|
7212
|
+
});
|
|
7180
7213
|
var activeNotices = /* @__PURE__ */ new Map();
|
|
7181
7214
|
function collectDeprecationNotice(event) {
|
|
7182
7215
|
if (event.type !== zapierSdk.DEPRECATION_NOTICE_EVENT) return;
|
|
@@ -7193,7 +7226,7 @@ function collectDeprecationNoticeAndForward(event, onEvent) {
|
|
|
7193
7226
|
// package.json with { type: 'json' }
|
|
7194
7227
|
var package_default = {
|
|
7195
7228
|
name: "@zapier/zapier-sdk-cli",
|
|
7196
|
-
version: "0.82.
|
|
7229
|
+
version: "0.82.2"};
|
|
7197
7230
|
|
|
7198
7231
|
// src/sdk.ts
|
|
7199
7232
|
var warnedDeprecatedMethods = /* @__PURE__ */ new Set();
|
|
@@ -7277,7 +7310,7 @@ function createZapierCliSdk(options = {}) {
|
|
|
7277
7310
|
|
|
7278
7311
|
// package.json
|
|
7279
7312
|
var package_default2 = {
|
|
7280
|
-
version: "0.82.
|
|
7313
|
+
version: "0.82.2"};
|
|
7281
7314
|
|
|
7282
7315
|
// src/telemetry/builders.ts
|
|
7283
7316
|
function createCliBaseEvent(context = {}) {
|
package/dist/index.mjs
CHANGED
|
@@ -7,7 +7,7 @@ import crypto, { createHash } from 'crypto';
|
|
|
7
7
|
import * as path from 'path';
|
|
8
8
|
import { resolve, join, dirname, basename, relative, extname } from 'path';
|
|
9
9
|
import * as lockfile from 'proper-lockfile';
|
|
10
|
-
import { 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, getConnectionPlugin, invalidateCachedToken, batch, toSnakeCase, ZapierError, isZapierReleaseTriggerMessageSignal, createSdk, SDK_OPTIONS_ID, resolvePlugin, isCredentialsObject, getRegistryPlugin, createController, ZapierAbortDrainSignal, ZapierReleaseTriggerMessageSignal, buildApplicationLifecycleEvent, AuthMechanism, isCoreCancelledSignal, ZapierAuthenticationError, CORE_OPTIONS_ID, addPlugin, getOsInfo, getPlatformVersions, getAgent, getTtyContext, getCiPlatform, isCi, getReleaseId, getCurrentTimestamp, generateEventId, DEPRECATION_NOTICE_EVENT } from '@zapier/zapier-sdk';
|
|
10
|
+
import { 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, getConnectionPlugin, invalidateCachedToken, batch, toSnakeCase, ZapierError, isZapierReleaseTriggerMessageSignal, createSdk, SDK_OPTIONS_ID, resolvePlugin, isCredentialsObject, getRegistryPlugin, createController, ZapierAbortDrainSignal, ZapierReleaseTriggerMessageSignal, buildApplicationLifecycleEvent, AuthMechanism, isCoreCancelledSignal, ZapierAuthenticationError, CORE_OPTIONS_ID, addPlugin, getOsInfo, getPlatformVersions, getAgent as getAgent$1, getTtyContext, getCiPlatform, isCi, getReleaseId, getCurrentTimestamp, generateEventId, DEPRECATION_NOTICE_EVENT } from '@zapier/zapier-sdk';
|
|
11
11
|
import { z } from 'zod';
|
|
12
12
|
import chalk5 from 'chalk';
|
|
13
13
|
import { hostname } from 'os';
|
|
@@ -31,7 +31,7 @@ import semver from 'semver';
|
|
|
31
31
|
import crossSpawn from 'cross-spawn';
|
|
32
32
|
import wrapAnsi from 'wrap-ansi';
|
|
33
33
|
import Table from 'cli-table3';
|
|
34
|
-
import { triggerInboxResolver, DrainTriggerInboxSchema, WatchTriggerInboxSchema } from '@zapier/zapier-sdk/experimental';
|
|
34
|
+
import { triggerInboxResolver, DrainTriggerInboxSchema, WatchTriggerInboxSchema, declareMethod as declareMethod$1, defineMethod as defineMethod$1, CreateWorkflowResponseSchema, getAgent, INTERNAL_CREATE_WORKFLOW_FIELDS, CreateWorkflowOptionsSchema } from '@zapier/zapier-sdk/experimental';
|
|
35
35
|
import 'commander';
|
|
36
36
|
|
|
37
37
|
var __defProp = Object.defineProperty;
|
|
@@ -7136,6 +7136,39 @@ var watchTriggerInboxCliPlugin = defineMethod({
|
|
|
7136
7136
|
return doWatch();
|
|
7137
7137
|
}
|
|
7138
7138
|
});
|
|
7139
|
+
var createWorkflowRef = declareMethod$1({ id: "createWorkflow" });
|
|
7140
|
+
function createPublicInputSchema(schema) {
|
|
7141
|
+
return z.object(
|
|
7142
|
+
Object.fromEntries(
|
|
7143
|
+
Object.entries(schema.shape).filter(
|
|
7144
|
+
([name]) => !INTERNAL_CREATE_WORKFLOW_FIELDS.includes(
|
|
7145
|
+
name
|
|
7146
|
+
)
|
|
7147
|
+
)
|
|
7148
|
+
)
|
|
7149
|
+
).describe(schema.description ?? "Create a workflow");
|
|
7150
|
+
}
|
|
7151
|
+
var CreateWorkflowCliOptionsSchema = createPublicInputSchema(
|
|
7152
|
+
CreateWorkflowOptionsSchema
|
|
7153
|
+
);
|
|
7154
|
+
defineMethod$1({
|
|
7155
|
+
namespace: "cli",
|
|
7156
|
+
name: "createWorkflow",
|
|
7157
|
+
imports: [createWorkflowRef],
|
|
7158
|
+
type: "create",
|
|
7159
|
+
itemType: "Workflow",
|
|
7160
|
+
categories: ["code-workflow"],
|
|
7161
|
+
experimental: true,
|
|
7162
|
+
inputSchema: CreateWorkflowCliOptionsSchema,
|
|
7163
|
+
outputSchema: CreateWorkflowResponseSchema,
|
|
7164
|
+
skipOutputValidation: true,
|
|
7165
|
+
output: "raw",
|
|
7166
|
+
run: ({ imports, input }) => imports.createWorkflow({
|
|
7167
|
+
...input,
|
|
7168
|
+
creationHarness: getAgent(),
|
|
7169
|
+
creationAccessMethod: "sdk_cli"
|
|
7170
|
+
})
|
|
7171
|
+
});
|
|
7139
7172
|
var activeNotices = /* @__PURE__ */ new Map();
|
|
7140
7173
|
function collectDeprecationNotice(event) {
|
|
7141
7174
|
if (event.type !== DEPRECATION_NOTICE_EVENT) return;
|
|
@@ -7152,7 +7185,7 @@ function collectDeprecationNoticeAndForward(event, onEvent) {
|
|
|
7152
7185
|
// package.json with { type: 'json' }
|
|
7153
7186
|
var package_default = {
|
|
7154
7187
|
name: "@zapier/zapier-sdk-cli",
|
|
7155
|
-
version: "0.82.
|
|
7188
|
+
version: "0.82.2"};
|
|
7156
7189
|
|
|
7157
7190
|
// src/sdk.ts
|
|
7158
7191
|
var warnedDeprecatedMethods = /* @__PURE__ */ new Set();
|
|
@@ -7236,7 +7269,7 @@ function createZapierCliSdk(options = {}) {
|
|
|
7236
7269
|
|
|
7237
7270
|
// package.json
|
|
7238
7271
|
var package_default2 = {
|
|
7239
|
-
version: "0.82.
|
|
7272
|
+
version: "0.82.2"};
|
|
7240
7273
|
|
|
7241
7274
|
// src/telemetry/builders.ts
|
|
7242
7275
|
function createCliBaseEvent(context = {}) {
|
|
@@ -7283,7 +7316,7 @@ function buildCliCommandExecutedEvent({
|
|
|
7283
7316
|
is_ci_environment: isCi(),
|
|
7284
7317
|
ci_platform: getCiPlatform(),
|
|
7285
7318
|
...getTtyContext(),
|
|
7286
|
-
agent: getAgent(),
|
|
7319
|
+
agent: getAgent$1(),
|
|
7287
7320
|
package_manager: data.package_manager ?? detectPackageManager(process.cwd()).name,
|
|
7288
7321
|
made_network_requests: data.made_network_requests ?? null,
|
|
7289
7322
|
files_modified_count: data.files_modified_count ?? null,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zapier/zapier-sdk-cli",
|
|
3
|
-
"version": "0.82.
|
|
3
|
+
"version": "0.82.2",
|
|
4
4
|
"description": "Command line interface for Zapier SDK",
|
|
5
5
|
"main": "dist/index.cjs",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -96,8 +96,8 @@
|
|
|
96
96
|
"wrap-ansi": "^10.0.0",
|
|
97
97
|
"zod": "4.3.6",
|
|
98
98
|
"@zapier/kitcore": "0.20.0",
|
|
99
|
-
"@zapier/zapier-sdk
|
|
100
|
-
"@zapier/zapier-sdk": "0.
|
|
99
|
+
"@zapier/zapier-sdk": "0.110.2",
|
|
100
|
+
"@zapier/zapier-sdk-mcp": "0.24.2"
|
|
101
101
|
},
|
|
102
102
|
"devDependencies": {
|
|
103
103
|
"@types/cross-spawn": "^6.0.6",
|