@zapier/zapier-sdk 0.61.0 → 0.63.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 +12 -0
- package/README.md +140 -0
- package/dist/experimental.cjs +317 -2
- package/dist/experimental.d.mts +139 -2
- package/dist/experimental.d.ts +137 -0
- package/dist/experimental.d.ts.map +1 -1
- package/dist/experimental.js +8 -0
- package/dist/experimental.mjs +317 -3
- package/dist/{index-iKbnOz6r.d.mts → index-3fBEDEsp.d.mts} +25 -1
- package/dist/{index-iKbnOz6r.d.ts → index-3fBEDEsp.d.ts} +25 -1
- package/dist/index.cjs +17 -1
- package/dist/index.d.mts +1 -1
- package/dist/index.mjs +17 -2
- package/dist/plugins/codeSubstrate/cancelDurableRun/index.d.ts +40 -0
- package/dist/plugins/codeSubstrate/cancelDurableRun/index.d.ts.map +1 -0
- package/dist/plugins/codeSubstrate/cancelDurableRun/index.js +27 -0
- package/dist/plugins/codeSubstrate/cancelDurableRun/schemas.d.ts +11 -0
- package/dist/plugins/codeSubstrate/cancelDurableRun/schemas.d.ts.map +1 -0
- package/dist/plugins/codeSubstrate/cancelDurableRun/schemas.js +12 -0
- package/dist/plugins/codeSubstrate/getDurableRun/index.d.ts +89 -0
- package/dist/plugins/codeSubstrate/getDurableRun/index.d.ts.map +1 -0
- package/dist/plugins/codeSubstrate/getDurableRun/index.js +20 -0
- package/dist/plugins/codeSubstrate/getDurableRun/schemas.d.ts +178 -0
- package/dist/plugins/codeSubstrate/getDurableRun/schemas.d.ts.map +1 -0
- package/dist/plugins/codeSubstrate/getDurableRun/schemas.js +130 -0
- package/dist/plugins/codeSubstrate/listDurableRuns/index.d.ts +55 -0
- package/dist/plugins/codeSubstrate/listDurableRuns/index.d.ts.map +1 -0
- package/dist/plugins/codeSubstrate/listDurableRuns/index.js +27 -0
- package/dist/plugins/codeSubstrate/listDurableRuns/schemas.d.ts +73 -0
- package/dist/plugins/codeSubstrate/listDurableRuns/schemas.d.ts.map +1 -0
- package/dist/plugins/codeSubstrate/listDurableRuns/schemas.js +59 -0
- package/dist/plugins/codeSubstrate/runDurable/index.d.ts +53 -0
- package/dist/plugins/codeSubstrate/runDurable/index.d.ts.map +1 -0
- package/dist/plugins/codeSubstrate/runDurable/index.js +36 -0
- package/dist/plugins/codeSubstrate/runDurable/schemas.d.ts +24 -0
- package/dist/plugins/codeSubstrate/runDurable/schemas.d.ts.map +1 -0
- package/dist/plugins/codeSubstrate/runDurable/schemas.js +61 -0
- package/dist/resolvers/durableRunId.d.ts +4 -0
- package/dist/resolvers/durableRunId.d.ts.map +1 -0
- package/dist/resolvers/durableRunId.js +14 -0
- package/dist/resolvers/index.d.ts +1 -0
- package/dist/resolvers/index.d.ts.map +1 -1
- package/dist/resolvers/index.js +1 -0
- package/package.json +1 -1
package/dist/experimental.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { B as BaseSdkOptions, W as WithAddPlugin, P as PluginMeta, Z as ZapierSdkOptions$1, E as EventEmissionContext, A as ApiClient, M as Manifest, R as ResolvedAppLocator, U as UpdateManifestEntryOptions, a as UpdateManifestEntryResult, b as AddActionEntryOptions, c as AddActionEntryResult, d as ActionEntry, f as findManifestEntry, r as readManifestFromFile, C as CapabilitiesContext, e as PaginatedSdkResult, F as FieldsetItem, g as PositionalMetadata, h as ZapierFetchInitOptions, D as DrainTriggerInboxOptions, i as DynamicResolver, j as WatchTriggerInboxOptions, k as ActionProxy, l as ZapierSdkApps } from './index-
|
|
2
|
-
export { u as Action, bZ as ActionExecutionOptions, y as ActionExecutionResult, z as ActionField, H as ActionFieldChoice, aB as ActionItem, bc as ActionKeyProperty, aM as ActionKeyPropertySchema, bd as ActionProperty, aN as ActionPropertySchema, as as ActionResolverItem, bo as ActionTimeoutMsProperty, aY as ActionTimeoutMsPropertySchema, at as ActionTypeItem, bb as ActionTypeProperty, aL as ActionTypePropertySchema, bB as ApiError,
|
|
1
|
+
import { B as BaseSdkOptions, W as WithAddPlugin, P as PluginMeta, Z as ZapierSdkOptions$1, E as EventEmissionContext, A as ApiClient, M as Manifest, R as ResolvedAppLocator, U as UpdateManifestEntryOptions, a as UpdateManifestEntryResult, b as AddActionEntryOptions, c as AddActionEntryResult, d as ActionEntry, f as findManifestEntry, r as readManifestFromFile, C as CapabilitiesContext, e as PaginatedSdkResult, F as FieldsetItem, g as PositionalMetadata, h as ZapierFetchInitOptions, D as DrainTriggerInboxOptions, i as DynamicResolver, j as WatchTriggerInboxOptions, k as ActionProxy, l as ZapierSdkApps } from './index-3fBEDEsp.mjs';
|
|
2
|
+
export { u as Action, bZ as ActionExecutionOptions, y as ActionExecutionResult, z as ActionField, H as ActionFieldChoice, aB as ActionItem, bc as ActionKeyProperty, aM as ActionKeyPropertySchema, bd as ActionProperty, aN as ActionPropertySchema, as as ActionResolverItem, bo as ActionTimeoutMsProperty, aY as ActionTimeoutMsPropertySchema, at as ActionTypeItem, bb as ActionTypeProperty, aL as ActionTypePropertySchema, bB as ApiError, dk as ApiEvent, cH as ApiPluginOptions, cJ as ApiPluginProvides, v as App, b_ as AppFactoryInput, az as AppItem, b9 as AppKeyProperty, aJ as AppKeyPropertySchema, ba as AppProperty, aK as AppPropertySchema, eu as ApplicationLifecycleEventData, bS as ApprovalStatus, bY as AppsPluginProvides, bt as AppsProperty, b1 as AppsPropertySchema, a0 as ArrayResolver, dj as AuthEvent, bh as AuthenticationIdProperty, aQ as AuthenticationIdPropertySchema, eC as BaseEvent, al as BaseSdkOptionsSchema, aa as BatchOptions, cu as CONTEXT_CACHE_MAX_SIZE, ct as CONTEXT_CACHE_TTL_MS, x as Choice, dr as ClientCredentialsObject, dC as ClientCredentialsObjectSchema, K as Connection, dK as ConnectionEntry, dJ as ConnectionEntrySchema, bf as ConnectionIdProperty, aP as ConnectionIdPropertySchema, aA as ConnectionItem, bg as ConnectionProperty, aR as ConnectionPropertySchema, dM as ConnectionsMap, dL as ConnectionsMapSchema, dO as ConnectionsPluginProvides, bv as ConnectionsProperty, b3 as ConnectionsPropertySchema, O as ConnectionsResponse, cg as CreateClientCredentialsPluginProvides, ec as CreateTableFieldsPluginProvides, e6 as CreateTablePluginProvides, ek as CreateTableRecordsPluginProvides, dn as Credentials, dH as CredentialsFunction, dG as CredentialsFunctionSchema, dq as CredentialsObject, dE as CredentialsObjectSchema, dI as CredentialsSchema, dT as DEFAULT_ACTION_TIMEOUT_MS, d$ as DEFAULT_APPROVAL_TIMEOUT_MS, cD as DEFAULT_CONFIG_PATH, e0 as DEFAULT_MAX_APPROVAL_RETRIES, dS as DEFAULT_PAGE_SIZE, bm as DebugProperty, aW as DebugPropertySchema, ci as DeleteClientCredentialsPluginProvides, ee as DeleteTableFieldsPluginProvides, e8 as DeleteTablePluginProvides, em as DeleteTableRecordsPluginProvides, o as DrainTriggerInboxCallback, p as DrainTriggerInboxErrorObserver, a3 as DynamicListResolver, a4 as DynamicSearchResolver, ev as EnhancedErrorEventData, bC as ErrorOptions, dm as EventCallback, et as EventContext, eq as EventEmissionConfig, es as EventEmissionProvides, c0 as FetchPluginProvides, w as Field, bs as FieldsProperty, b0 as FieldsPropertySchema, a5 as FieldsResolver, s as FindFirstAuthenticationPluginProvides, cq as FindFirstConnectionPluginProvides, t as FindUniqueAuthenticationPluginProvides, cs as FindUniqueConnectionPluginProvides, Y as FormatMetadata, X as FormattedItem, ak as FunctionDeprecation, aG as FunctionOptions, aj as FunctionRegistryEntry, ca as GetActionInputFieldsSchemaPluginProvides, cm as GetActionPluginProvides, ck as GetAppPluginProvides, G as GetAuthenticationPluginProvides, co as GetConnectionPluginProvides, cG as GetProfilePluginProvides, e4 as GetTablePluginProvides, eg as GetTableRecordPluginProvides, aD as InfoFieldItem, aC as InputFieldItem, be as InputFieldProperty, aO as InputFieldPropertySchema, bi as InputsProperty, aS as InputsPropertySchema, bA as LeaseLimitProperty, b8 as LeaseLimitPropertySchema, by as LeaseProperty, b6 as LeasePropertySchema, bz as LeaseSecondsProperty, b7 as LeaseSecondsPropertySchema, L as LeasedTriggerMessageItem, bj as LimitProperty, aT as LimitPropertySchema, c8 as ListActionInputFieldChoicesPluginProvides, c6 as ListActionInputFieldsPluginProvides, c4 as ListActionsPluginProvides, c2 as ListAppsPluginProvides, q as ListAuthenticationsPluginProvides, ce as ListClientCredentialsPluginProvides, cc as ListConnectionsPluginProvides, ea as ListTableFieldsPluginProvides, ei as ListTableRecordsPluginProvides, e2 as ListTablesPluginProvides, dl as LoadingEvent, dW as MAX_CONCURRENCY_LIMIT, dR as MAX_PAGE_LIMIT, cE as ManifestEntry, cz as ManifestPluginOptions, cC as ManifestPluginProvides, eD as MethodCalledEvent, ew as MethodCalledEventData, N as Need, I as NeedsRequest, J as NeedsResponse, bk as OffsetProperty, aU as OffsetPropertySchema, _ as OutputFormatter, bl as OutputProperty, aV as OutputPropertySchema, aI as PaginatedSdkFunction, bn as ParamsProperty, aX as ParamsPropertySchema, ds as PkceCredentialsObject, dD as PkceCredentialsObjectSchema, am as Plugin, an as PluginProvides, aw as PollOptions, bQ as RateLimitInfo, bq as RecordProperty, a_ as RecordPropertySchema, br as RecordsProperty, a$ as RecordsPropertySchema, af as RelayFetchSchema, ae as RelayRequestSchema, av as RequestOptions, cy as RequestPluginProvides, d6 as ResolveAuthTokenOptions, dx as ResolveCredentialsOptions, dp as ResolvedCredentials, dF as ResolvedCredentialsSchema, $ as Resolver, a1 as ResolverMetadata, aE as RootFieldItem, cw as RunActionPluginProvides, di as SdkEvent, aH as SdkPage, a2 as StaticResolver, bp as TableProperty, aZ as TablePropertySchema, bu as TablesProperty, b2 as TablesPropertySchema, bx as TriggerInboxNameProperty, b5 as TriggerInboxNamePropertySchema, bw as TriggerInboxProperty, b4 as TriggerInboxPropertySchema, T as TriggerMessageStatus, eo as UpdateTableRecordsPluginProvides, Q as UserProfile, aF as UserProfileItem, dP as ZAPIER_BASE_URL, dY as ZAPIER_MAX_CONCURRENT_REQUESTS, dU as ZAPIER_MAX_NETWORK_RETRIES, dV as ZAPIER_MAX_NETWORK_RETRY_DELAY_MS, m as ZapierAbortDrainSignal, bO as ZapierActionError, bE as ZapierApiError, bF as ZapierAppNotFoundError, bT as ZapierApprovalError, bI as ZapierAuthenticationError, bM as ZapierBundleError, de as ZapierCache, df as ZapierCacheEntry, dg as ZapierCacheSetOptions, bL as ZapierConfigurationError, bP as ZapierConflictError, bD as ZapierError, bJ as ZapierNotFoundError, bR as ZapierRateLimitError, bU as ZapierRelayError, n as ZapierReleaseTriggerMessageSignal, bK as ZapierResourceNotFoundError, bW as ZapierSignal, bN as ZapierTimeoutError, bH as ZapierUnknownError, bG as ZapierValidationError, cM as actionKeyResolver, cL as actionTypeResolver, cI as apiPlugin, cK as appKeyResolver, bX as appsPlugin, cO as authenticationIdGenericResolver, cN as authenticationIdResolver, a9 as batch, ex as buildApplicationLifecycleEvent, ab as buildCapabilityMessage, ez as buildErrorEvent, ey as buildErrorEventWithContext, eB as buildMethodCalledEvent, ep as cleanupEventListeners, d7 as clearTokenCache, cS as clientCredentialsNameResolver, cT as clientIdResolver, ar as composePlugins, cO as connectionIdGenericResolver, cN as connectionIdResolver, dN as connectionsPlugin, eA as createBaseEvent, cf as createClientCredentialsPlugin, V as createFunction, dh as createMemoryCache, ai as createOptionsPlugin, aq as createPaginatedPluginMethod, ap as createPluginMethod, ah as createSdk, eb as createTableFieldsPlugin, e5 as createTablePlugin, ej as createTableRecordsPlugin, ax as createZapierApi, ag as createZapierSdkWithoutRegistry, ao as definePlugin, ch as deleteClientCredentialsPlugin, ed as deleteTableFieldsPlugin, e7 as deleteTablePlugin, el as deleteTableRecordsPlugin, cX as durableRunIdResolver, er as eventEmissionPlugin, b$ as fetchPlugin, cp as findFirstConnectionPlugin, cr as findUniqueConnectionPlugin, bV as formatErrorMessage, eE as generateEventId, c9 as getActionInputFieldsSchemaPlugin, cl as getActionPlugin, cj as getAppPlugin, dA as getBaseUrlFromCredentials, eK as getCiPlatform, dB as getClientIdFromCredentials, cn as getConnectionPlugin, eM as getCpuTime, eF as getCurrentTimestamp, eL as getMemoryUsage, ay as getOrCreateApiClient, eH as getOsInfo, eI as getPlatformVersions, cA as getPreferredManifestEntryKey, cF as getProfilePlugin, eG as getReleaseId, e3 as getTablePlugin, ef as getTableRecordPlugin, db as getTokenFromCliLogin, dZ as getZapierApprovalMode, d_ as getZapierDefaultApprovalMode, dQ as getZapierSdkService, d9 as injectCliLogin, cR as inputFieldKeyResolver, cQ as inputsAllOptionalResolver, cP as inputsResolver, d8 as invalidateCachedToken, dd as invalidateCredentialsToken, eJ as isCi, da as isCliLoginAvailable, dt as isClientCredentials, dw as isCredentialsFunction, dv as isCredentialsObject, du as isPkceCredentials, S as isPositional, c7 as listActionInputFieldChoicesPlugin, c5 as listActionInputFieldsPlugin, c3 as listActionsPlugin, c1 as listAppsPlugin, cd as listClientCredentialsPlugin, cb as listConnectionsPlugin, e9 as listTableFieldsPlugin, eh as listTableRecordsPlugin, e1 as listTablesPlugin, ac as logDeprecation, cB as manifestPlugin, dX as parseConcurrencyEnvVar, au as registryPlugin, cx as requestPlugin, ad as resetDeprecationWarnings, dc as resolveAuthToken, dz as resolveCredentials, dy as resolveCredentialsFromEnv, cv as runActionPlugin, a6 as runWithTelemetryContext, c$ as tableFieldIdsResolver, d1 as tableFieldsResolver, d4 as tableFiltersResolver, cU as tableIdResolver, d0 as tableNameResolver, cZ as tableRecordIdResolver, c_ as tableRecordIdsResolver, d2 as tableRecordsResolver, d5 as tableSortResolver, d3 as tableUpdateRecordsResolver, a7 as toSnakeCase, a8 as toTitleCase, cV as triggerInboxResolver, cY as triggerMessagesResolver, en as updateTableRecordsPlugin, cW as workflowIdResolver } from './index-3fBEDEsp.mjs';
|
|
3
3
|
import * as zod_v4_core from 'zod/v4/core';
|
|
4
4
|
import * as zod from 'zod';
|
|
5
5
|
import '@zapier/zapier-sdk-core/v0/schemas/connections';
|
|
@@ -2417,6 +2417,143 @@ declare function createZapierSdk(options?: ZapierSdkOptions): WithAddPlugin<{
|
|
|
2417
2417
|
deleteWorkflow: PluginMeta;
|
|
2418
2418
|
};
|
|
2419
2419
|
};
|
|
2420
|
+
} & {
|
|
2421
|
+
listDurableRuns: (options?: ({
|
|
2422
|
+
pageSize?: number | undefined;
|
|
2423
|
+
cursor?: string | undefined;
|
|
2424
|
+
maxItems?: number | undefined;
|
|
2425
|
+
} & {
|
|
2426
|
+
cursor?: string;
|
|
2427
|
+
pageSize?: number;
|
|
2428
|
+
maxItems?: number;
|
|
2429
|
+
}) | undefined) => PaginatedSdkResult<{
|
|
2430
|
+
id: string;
|
|
2431
|
+
status: "initialized" | "started" | "finished" | "failed" | "cancelled";
|
|
2432
|
+
input: unknown;
|
|
2433
|
+
output: unknown;
|
|
2434
|
+
error: {
|
|
2435
|
+
[x: string]: unknown;
|
|
2436
|
+
code: string;
|
|
2437
|
+
message: string;
|
|
2438
|
+
} | null;
|
|
2439
|
+
execution_id: string | null;
|
|
2440
|
+
is_private: boolean;
|
|
2441
|
+
created_at: string;
|
|
2442
|
+
updated_at: string;
|
|
2443
|
+
}>;
|
|
2444
|
+
} & {
|
|
2445
|
+
context: {
|
|
2446
|
+
meta: {
|
|
2447
|
+
listDurableRuns: PluginMeta;
|
|
2448
|
+
};
|
|
2449
|
+
};
|
|
2450
|
+
} & {
|
|
2451
|
+
getDurableRun: (options?: {
|
|
2452
|
+
run: string;
|
|
2453
|
+
} | undefined) => Promise<{
|
|
2454
|
+
data: {
|
|
2455
|
+
id: string;
|
|
2456
|
+
status: "initialized" | "started" | "finished" | "failed" | "cancelled";
|
|
2457
|
+
input: unknown;
|
|
2458
|
+
output: unknown;
|
|
2459
|
+
error: {
|
|
2460
|
+
[x: string]: unknown;
|
|
2461
|
+
code: string;
|
|
2462
|
+
message: string;
|
|
2463
|
+
} | null;
|
|
2464
|
+
execution: {
|
|
2465
|
+
id: string;
|
|
2466
|
+
name: string;
|
|
2467
|
+
status: "failed" | "running" | "waiting" | "completed";
|
|
2468
|
+
input: unknown;
|
|
2469
|
+
created_at: string;
|
|
2470
|
+
output?: unknown;
|
|
2471
|
+
error?: unknown;
|
|
2472
|
+
metadata?: Record<string, unknown> | undefined;
|
|
2473
|
+
summary?: {
|
|
2474
|
+
[x: string]: unknown;
|
|
2475
|
+
total_attempts: number;
|
|
2476
|
+
last_error?: {
|
|
2477
|
+
[x: string]: unknown;
|
|
2478
|
+
code: string;
|
|
2479
|
+
title: string;
|
|
2480
|
+
detail?: string | null | undefined;
|
|
2481
|
+
} | undefined;
|
|
2482
|
+
} | null | undefined;
|
|
2483
|
+
operations?: {
|
|
2484
|
+
id: string;
|
|
2485
|
+
execution_id: string;
|
|
2486
|
+
name: string;
|
|
2487
|
+
type: "step" | "wait" | "callback";
|
|
2488
|
+
status: "failed" | "completed" | "pending" | "exhausted";
|
|
2489
|
+
retry_count: number;
|
|
2490
|
+
created_at: string;
|
|
2491
|
+
result?: unknown;
|
|
2492
|
+
error?: unknown;
|
|
2493
|
+
max_attempts?: number | undefined;
|
|
2494
|
+
next_retry_at?: string | undefined;
|
|
2495
|
+
resume_at?: string | undefined;
|
|
2496
|
+
callback_token?: string | null | undefined;
|
|
2497
|
+
payload_schema?: unknown;
|
|
2498
|
+
payload?: unknown;
|
|
2499
|
+
expires_at?: string | undefined;
|
|
2500
|
+
completed_at?: string | undefined;
|
|
2501
|
+
}[] | undefined;
|
|
2502
|
+
} | null;
|
|
2503
|
+
is_private: boolean;
|
|
2504
|
+
created_at: string;
|
|
2505
|
+
updated_at: string;
|
|
2506
|
+
};
|
|
2507
|
+
}>;
|
|
2508
|
+
} & {
|
|
2509
|
+
context: {
|
|
2510
|
+
meta: {
|
|
2511
|
+
getDurableRun: PluginMeta;
|
|
2512
|
+
};
|
|
2513
|
+
};
|
|
2514
|
+
} & {
|
|
2515
|
+
runDurable: (options?: {
|
|
2516
|
+
source_files: Record<string, string>;
|
|
2517
|
+
input?: unknown;
|
|
2518
|
+
dependencies?: Record<string, string> | undefined;
|
|
2519
|
+
zapier_durable_version?: string | undefined;
|
|
2520
|
+
connections?: Record<string, {
|
|
2521
|
+
connection_id: string | number;
|
|
2522
|
+
}> | undefined;
|
|
2523
|
+
app_versions?: Record<string, {
|
|
2524
|
+
implementation_name: string;
|
|
2525
|
+
version?: string | undefined;
|
|
2526
|
+
}> | undefined;
|
|
2527
|
+
private?: boolean | undefined;
|
|
2528
|
+
} | undefined) => Promise<{
|
|
2529
|
+
data: {
|
|
2530
|
+
id: string;
|
|
2531
|
+
status: "initialized";
|
|
2532
|
+
is_private: boolean;
|
|
2533
|
+
created_at: string;
|
|
2534
|
+
};
|
|
2535
|
+
}>;
|
|
2536
|
+
} & {
|
|
2537
|
+
context: {
|
|
2538
|
+
meta: {
|
|
2539
|
+
runDurable: PluginMeta;
|
|
2540
|
+
};
|
|
2541
|
+
};
|
|
2542
|
+
} & {
|
|
2543
|
+
cancelDurableRun: (options?: {
|
|
2544
|
+
run: string;
|
|
2545
|
+
} | undefined) => Promise<{
|
|
2546
|
+
data: {
|
|
2547
|
+
id: string;
|
|
2548
|
+
status: "cancelled";
|
|
2549
|
+
};
|
|
2550
|
+
}>;
|
|
2551
|
+
} & {
|
|
2552
|
+
context: {
|
|
2553
|
+
meta: {
|
|
2554
|
+
cancelDurableRun: PluginMeta;
|
|
2555
|
+
};
|
|
2556
|
+
};
|
|
2420
2557
|
} & {
|
|
2421
2558
|
apps: ActionProxy & ZapierSdkApps;
|
|
2422
2559
|
context: {
|
package/dist/experimental.d.ts
CHANGED
|
@@ -2432,6 +2432,143 @@ export declare function createZapierSdk(options?: ZapierSdkOptions): import("./i
|
|
|
2432
2432
|
deleteWorkflow: PluginMeta;
|
|
2433
2433
|
};
|
|
2434
2434
|
};
|
|
2435
|
+
} & {
|
|
2436
|
+
listDurableRuns: (options?: ({
|
|
2437
|
+
pageSize?: number | undefined;
|
|
2438
|
+
cursor?: string | undefined;
|
|
2439
|
+
maxItems?: number | undefined;
|
|
2440
|
+
} & {
|
|
2441
|
+
cursor?: string;
|
|
2442
|
+
pageSize?: number;
|
|
2443
|
+
maxItems?: number;
|
|
2444
|
+
}) | undefined) => import("./index").PaginatedSdkResult<{
|
|
2445
|
+
id: string;
|
|
2446
|
+
status: "initialized" | "started" | "finished" | "failed" | "cancelled";
|
|
2447
|
+
input: unknown;
|
|
2448
|
+
output: unknown;
|
|
2449
|
+
error: {
|
|
2450
|
+
[x: string]: unknown;
|
|
2451
|
+
code: string;
|
|
2452
|
+
message: string;
|
|
2453
|
+
} | null;
|
|
2454
|
+
execution_id: string | null;
|
|
2455
|
+
is_private: boolean;
|
|
2456
|
+
created_at: string;
|
|
2457
|
+
updated_at: string;
|
|
2458
|
+
}>;
|
|
2459
|
+
} & {
|
|
2460
|
+
context: {
|
|
2461
|
+
meta: {
|
|
2462
|
+
listDurableRuns: PluginMeta;
|
|
2463
|
+
};
|
|
2464
|
+
};
|
|
2465
|
+
} & {
|
|
2466
|
+
getDurableRun: (options?: {
|
|
2467
|
+
run: string;
|
|
2468
|
+
} | undefined) => Promise<{
|
|
2469
|
+
data: {
|
|
2470
|
+
id: string;
|
|
2471
|
+
status: "initialized" | "started" | "finished" | "failed" | "cancelled";
|
|
2472
|
+
input: unknown;
|
|
2473
|
+
output: unknown;
|
|
2474
|
+
error: {
|
|
2475
|
+
[x: string]: unknown;
|
|
2476
|
+
code: string;
|
|
2477
|
+
message: string;
|
|
2478
|
+
} | null;
|
|
2479
|
+
execution: {
|
|
2480
|
+
id: string;
|
|
2481
|
+
name: string;
|
|
2482
|
+
status: "failed" | "waiting" | "completed" | "running";
|
|
2483
|
+
input: unknown;
|
|
2484
|
+
created_at: string;
|
|
2485
|
+
output?: unknown;
|
|
2486
|
+
error?: unknown;
|
|
2487
|
+
metadata?: Record<string, unknown> | undefined;
|
|
2488
|
+
summary?: {
|
|
2489
|
+
[x: string]: unknown;
|
|
2490
|
+
total_attempts: number;
|
|
2491
|
+
last_error?: {
|
|
2492
|
+
[x: string]: unknown;
|
|
2493
|
+
code: string;
|
|
2494
|
+
title: string;
|
|
2495
|
+
detail?: string | null | undefined;
|
|
2496
|
+
} | undefined;
|
|
2497
|
+
} | null | undefined;
|
|
2498
|
+
operations?: {
|
|
2499
|
+
id: string;
|
|
2500
|
+
execution_id: string;
|
|
2501
|
+
name: string;
|
|
2502
|
+
type: "step" | "wait" | "callback";
|
|
2503
|
+
status: "pending" | "failed" | "exhausted" | "completed";
|
|
2504
|
+
retry_count: number;
|
|
2505
|
+
created_at: string;
|
|
2506
|
+
result?: unknown;
|
|
2507
|
+
error?: unknown;
|
|
2508
|
+
max_attempts?: number | undefined;
|
|
2509
|
+
next_retry_at?: string | undefined;
|
|
2510
|
+
resume_at?: string | undefined;
|
|
2511
|
+
callback_token?: string | null | undefined;
|
|
2512
|
+
payload_schema?: unknown;
|
|
2513
|
+
payload?: unknown;
|
|
2514
|
+
expires_at?: string | undefined;
|
|
2515
|
+
completed_at?: string | undefined;
|
|
2516
|
+
}[] | undefined;
|
|
2517
|
+
} | null;
|
|
2518
|
+
is_private: boolean;
|
|
2519
|
+
created_at: string;
|
|
2520
|
+
updated_at: string;
|
|
2521
|
+
};
|
|
2522
|
+
}>;
|
|
2523
|
+
} & {
|
|
2524
|
+
context: {
|
|
2525
|
+
meta: {
|
|
2526
|
+
getDurableRun: PluginMeta;
|
|
2527
|
+
};
|
|
2528
|
+
};
|
|
2529
|
+
} & {
|
|
2530
|
+
runDurable: (options?: {
|
|
2531
|
+
source_files: Record<string, string>;
|
|
2532
|
+
input?: unknown;
|
|
2533
|
+
dependencies?: Record<string, string> | undefined;
|
|
2534
|
+
zapier_durable_version?: string | undefined;
|
|
2535
|
+
connections?: Record<string, {
|
|
2536
|
+
connection_id: string | number;
|
|
2537
|
+
}> | undefined;
|
|
2538
|
+
app_versions?: Record<string, {
|
|
2539
|
+
implementation_name: string;
|
|
2540
|
+
version?: string | undefined;
|
|
2541
|
+
}> | undefined;
|
|
2542
|
+
private?: boolean | undefined;
|
|
2543
|
+
} | undefined) => Promise<{
|
|
2544
|
+
data: {
|
|
2545
|
+
id: string;
|
|
2546
|
+
status: "initialized";
|
|
2547
|
+
is_private: boolean;
|
|
2548
|
+
created_at: string;
|
|
2549
|
+
};
|
|
2550
|
+
}>;
|
|
2551
|
+
} & {
|
|
2552
|
+
context: {
|
|
2553
|
+
meta: {
|
|
2554
|
+
runDurable: PluginMeta;
|
|
2555
|
+
};
|
|
2556
|
+
};
|
|
2557
|
+
} & {
|
|
2558
|
+
cancelDurableRun: (options?: {
|
|
2559
|
+
run: string;
|
|
2560
|
+
} | undefined) => Promise<{
|
|
2561
|
+
data: {
|
|
2562
|
+
id: string;
|
|
2563
|
+
status: "cancelled";
|
|
2564
|
+
};
|
|
2565
|
+
}>;
|
|
2566
|
+
} & {
|
|
2567
|
+
context: {
|
|
2568
|
+
meta: {
|
|
2569
|
+
cancelDurableRun: PluginMeta;
|
|
2570
|
+
};
|
|
2571
|
+
};
|
|
2435
2572
|
} & {
|
|
2436
2573
|
apps: import("./plugins/apps/schemas").ActionProxy & import("./index").ZapierSdkApps;
|
|
2437
2574
|
context: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"experimental.d.ts","sourceRoot":"","sources":["../src/experimental.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAClD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"experimental.d.ts","sourceRoot":"","sources":["../src/experimental.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAClD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAmFjD,cAAc,SAAS,CAAC;AAExB,MAAM,WAAW,gBAAiB,SAAQ,cAAc;CAAG;AAE3D,wBAAgB,eAAe,CAAC,OAAO,GAAE,gBAAqB;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GATpnJ;AAED,MAAM,MAAM,SAAS,GAAG,UAAU,CAAC,OAAO,eAAe,CAAC,CAAC;AAM3D,YAAY,EAAE,UAAU,EAAE,CAAC"}
|
package/dist/experimental.js
CHANGED
|
@@ -83,6 +83,10 @@ import { updateWorkflowPlugin } from "./plugins/codeSubstrate/updateWorkflow";
|
|
|
83
83
|
import { enableWorkflowPlugin } from "./plugins/codeSubstrate/enableWorkflow";
|
|
84
84
|
import { disableWorkflowPlugin } from "./plugins/codeSubstrate/disableWorkflow";
|
|
85
85
|
import { deleteWorkflowPlugin } from "./plugins/codeSubstrate/deleteWorkflow";
|
|
86
|
+
import { listDurableRunsPlugin } from "./plugins/codeSubstrate/listDurableRuns";
|
|
87
|
+
import { getDurableRunPlugin } from "./plugins/codeSubstrate/getDurableRun";
|
|
88
|
+
import { runDurablePlugin } from "./plugins/codeSubstrate/runDurable";
|
|
89
|
+
import { cancelDurableRunPlugin } from "./plugins/codeSubstrate/cancelDurableRun";
|
|
86
90
|
// Re-export everything from the stable index so callers importing from
|
|
87
91
|
// the experimental subpath get the full API surface (types, helpers,
|
|
88
92
|
// errors) without having to import from two paths.
|
|
@@ -165,6 +169,10 @@ export function createZapierSdk(options = {}) {
|
|
|
165
169
|
.addPlugin(enableWorkflowPlugin)
|
|
166
170
|
.addPlugin(disableWorkflowPlugin)
|
|
167
171
|
.addPlugin(deleteWorkflowPlugin)
|
|
172
|
+
.addPlugin(listDurableRunsPlugin)
|
|
173
|
+
.addPlugin(getDurableRunPlugin)
|
|
174
|
+
.addPlugin(runDurablePlugin)
|
|
175
|
+
.addPlugin(cancelDurableRunPlugin)
|
|
168
176
|
// Magic apps plugin
|
|
169
177
|
.addPlugin(appsPlugin)
|
|
170
178
|
// Profile
|