@zapier/zapier-sdk 0.54.0 → 0.55.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.
Files changed (43) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/README.md +10 -9
  3. package/dist/experimental.cjs +77 -48
  4. package/dist/experimental.d.mts +3 -2
  5. package/dist/experimental.d.ts +1 -0
  6. package/dist/experimental.d.ts.map +1 -1
  7. package/dist/experimental.mjs +77 -48
  8. package/dist/{index-SDDmBk2j.d.mts → index-DjQ4XDAV.d.mts} +7 -0
  9. package/dist/{index-SDDmBk2j.d.ts → index-DjQ4XDAV.d.ts} +7 -0
  10. package/dist/index.cjs +22 -13
  11. package/dist/index.d.mts +1 -1
  12. package/dist/index.mjs +22 -13
  13. package/dist/plugins/triggers/createTriggerInbox/index.d.ts +1 -0
  14. package/dist/plugins/triggers/createTriggerInbox/index.d.ts.map +1 -1
  15. package/dist/plugins/triggers/createTriggerInbox/index.js +18 -3
  16. package/dist/plugins/triggers/createTriggerInbox/schemas.d.ts +1 -0
  17. package/dist/plugins/triggers/createTriggerInbox/schemas.d.ts.map +1 -1
  18. package/dist/plugins/triggers/createTriggerInbox/schemas.js +3 -2
  19. package/dist/plugins/triggers/ensureTriggerInbox/index.d.ts.map +1 -1
  20. package/dist/plugins/triggers/ensureTriggerInbox/index.js +1 -12
  21. package/dist/plugins/triggers/utils.d.ts +6 -0
  22. package/dist/plugins/triggers/utils.d.ts.map +1 -1
  23. package/dist/plugins/triggers/utils.js +17 -0
  24. package/dist/resolvers/actionKey.d.ts.map +1 -1
  25. package/dist/resolvers/actionKey.js +2 -1
  26. package/dist/resolvers/appKey.d.ts.map +1 -1
  27. package/dist/resolvers/appKey.js +2 -3
  28. package/dist/resolvers/clientId.js +1 -1
  29. package/dist/resolvers/connectionId.js +1 -1
  30. package/dist/resolvers/inputFieldKey.d.ts.map +1 -1
  31. package/dist/resolvers/inputFieldKey.js +5 -1
  32. package/dist/resolvers/tableFieldIds.d.ts.map +1 -1
  33. package/dist/resolvers/tableFieldIds.js +2 -1
  34. package/dist/resolvers/tableId.js +1 -1
  35. package/dist/resolvers/tableRecordId.d.ts.map +1 -1
  36. package/dist/resolvers/tableRecordId.js +4 -3
  37. package/dist/resolvers/triggerInbox.d.ts.map +1 -1
  38. package/dist/resolvers/triggerInbox.js +2 -1
  39. package/dist/resolvers/triggerMessages.d.ts.map +1 -1
  40. package/dist/resolvers/triggerMessages.js +2 -1
  41. package/dist/utils/schema-utils.d.ts +7 -0
  42. package/dist/utils/schema-utils.d.ts.map +1 -1
  43. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,21 @@
1
1
  # @zapier/zapier-sdk
2
2
 
3
+ ## 0.55.0
4
+
5
+ ### Minor Changes
6
+
7
+ - ce779d1: Add `hint?: string | string[]` to `PromptConfig.choices`. The CLI renders it after the choice's `name` as dimmed parens; an unset `hint` with a primitive `value` auto-renders the value.
8
+
9
+ All built-in resolvers migrate to the new shape, so existing dropdowns get small visual cleanups (dim parens, no `ID:` prefix, dash converted to parens, em-dash in `tableRecordId` gone).
10
+
11
+ Plugin authors who embed the value in `name` (e.g. `"Foo (${id})"`) should drop the embedded parens; the auto-default appends a second otherwise.
12
+
13
+ ## 0.54.1
14
+
15
+ ### Patch Changes
16
+
17
+ - 22a1727: Add optional `name` parameter to `createTriggerInbox` method
18
+
3
19
  ## 0.54.0
4
20
 
5
21
  ### Minor Changes
package/README.md CHANGED
@@ -1835,18 +1835,19 @@ const result = await zapier.ackTriggerInboxMessages({
1835
1835
 
1836
1836
  #### `createTriggerInbox` 🧪 _experimental_
1837
1837
 
1838
- Create a new trigger inbox subscription with an auto-generated name. Always creates; use ensureTriggerInbox for get-or-create on a stable name.
1838
+ Create a new trigger inbox subscription. Always creates a new inbox; use ensureTriggerInbox for get-or-create on a stable name.
1839
1839
 
1840
1840
  **Parameters:**
1841
1841
 
1842
- | Name | Type | Required | Default | Possible Values | Description |
1843
- | --------------------- | ---------------- | -------- | ------- | --------------- | ------------------------------------------------------------------------------------------------------------ |
1844
- | `options` | `object` | ✅ | — | — | |
1845
- | ​ ↳ `app` | `string` | | — | — | App slug (e.g., 'github'), implementation name (e.g., 'SlackCLIAPI'), or versioned ID (e.g., 'github@1.2.3') |
1846
- | ​ ↳ `action` | `string` | ✅ | — | — | Action key (e.g., 'send_message' or 'find_row') |
1847
- | ​ ↳ `connection` | `string, number` | | — | — | Connection alias or connection ID. Optional for triggers that don't require auth. |
1848
- | ​ ↳ `inputs` | `object` | ❌ | — | — | Input parameters for the trigger subscription |
1849
- | ​ ↳ `notificationUrl` | `string` | ❌ | — | — | Webhook URL to POST to when new messages arrive |
1842
+ | Name | Type | Required | Default | Possible Values | Description |
1843
+ | --------------------- | ---------------- | -------- | ------- | --------------- | -------------------------------------------------------------------------------------------------------------------------------- |
1844
+ | `options` | `object` | ✅ | — | — | |
1845
+ | ​ ↳ `name` | `string` | | — | — | Optional inbox name. Auto-generated when omitted. Throws a conflict error if the name is already in use by another subscription. |
1846
+ | ​ ↳ `app` | `string` | ✅ | — | — | App slug (e.g., 'github'), implementation name (e.g., 'SlackCLIAPI'), or versioned ID (e.g., 'github@1.2.3') |
1847
+ | ​ ↳ `action` | `string` | | — | — | Action key (e.g., 'send_message' or 'find_row') |
1848
+ | ​ ↳ `connection` | `string, number` | ❌ | — | — | Connection alias or connection ID. Optional for triggers that don't require auth. |
1849
+ | ​ ↳ `inputs` | `object` | ❌ | — | — | Input parameters for the trigger subscription |
1850
+ | ​ ↳ `notificationUrl` | `string` | ❌ | — | — | Webhook URL to POST to when new messages arrive |
1850
1851
 
1851
1852
  **Returns:** `Promise<TriggerInboxItem>`
1852
1853
 
@@ -2881,7 +2881,7 @@ async function invalidateCredentialsToken(options) {
2881
2881
  }
2882
2882
 
2883
2883
  // src/sdk-version.ts
2884
- var SDK_VERSION = (typeof process !== "undefined" && process.env ? "0.54.0" : void 0) || "unknown";
2884
+ var SDK_VERSION = (typeof process !== "undefined" && process.env ? "0.55.0" : void 0) || "unknown";
2885
2885
 
2886
2886
  // src/utils/open-url.ts
2887
2887
  var nodePrefix = "node:";
@@ -3978,7 +3978,8 @@ var appKeyResolver = {
3978
3978
  name: "app",
3979
3979
  message: "Select app:",
3980
3980
  choices: apps.map((app) => ({
3981
- name: app.title ? `${app.title} (${getAppKeyList(app).join(", ")})` : app.key,
3981
+ name: app.title || app.key,
3982
+ hint: app.title ? getAppKeyList(app) : void 0,
3982
3983
  value: app.key
3983
3984
  }))
3984
3985
  })
@@ -4026,7 +4027,8 @@ var actionKeyResolver = {
4026
4027
  name: "action",
4027
4028
  message: "Select action:",
4028
4029
  choices: actions.map((action) => ({
4029
- name: `${action.title || action.name || action.key} - ${action.description || "No description"}`,
4030
+ name: action.title || action.name || action.key,
4031
+ hint: action.description || void 0,
4030
4032
  value: action.key
4031
4033
  }))
4032
4034
  })
@@ -4051,7 +4053,7 @@ function promptForConnection(connections, params) {
4051
4053
  name: "connection",
4052
4054
  message: params.app ? `Select connection for ${params.app}:` : "Select connection:",
4053
4055
  choices: connections.map((connection) => ({
4054
- name: `${connection.title || connection.label || "Connection"} (ID: ${connection.id})`,
4056
+ name: connection.title || connection.label || "Connection",
4055
4057
  value: connection.id
4056
4058
  }))
4057
4059
  };
@@ -4166,7 +4168,11 @@ var inputFieldKeyResolver = {
4166
4168
  name: "inputField",
4167
4169
  message: "Select input field:",
4168
4170
  choices: fields.map((field) => ({
4169
- name: `${field.title || field.key} - ${field.value_type || "No type"} ${field.is_required ? "(required)" : "(optional)"}`,
4171
+ name: field.title || field.key,
4172
+ hint: [
4173
+ field.value_type,
4174
+ field.is_required ? "required" : "optional"
4175
+ ].filter(Boolean),
4170
4176
  value: field.key
4171
4177
  }))
4172
4178
  })
@@ -4191,7 +4197,7 @@ var clientIdResolver = {
4191
4197
  name: "clientId",
4192
4198
  message: "Select client credentials to delete:",
4193
4199
  choices: credentials.map((cred) => ({
4194
- name: `${cred.name} (${cred.client_id})`,
4200
+ name: cred.name,
4195
4201
  value: cred.client_id
4196
4202
  }))
4197
4203
  })
@@ -4224,7 +4230,7 @@ var tableIdResolver = {
4224
4230
  name: "table",
4225
4231
  message: "Select a table:",
4226
4232
  choices: tables.map((table) => ({
4227
- name: `${table.name} (${table.id})`,
4233
+ name: table.name,
4228
4234
  value: table.id
4229
4235
  }))
4230
4236
  })
@@ -4241,7 +4247,8 @@ var triggerInboxResolver = {
4241
4247
  // `deleting` inboxes are on their way out — no operation against them
4242
4248
  // is useful (delete is a no-op, pause/resume/update are rejected).
4243
4249
  choices: inboxes.filter((inbox) => inbox.status !== "deleting").map((inbox) => ({
4244
- name: `${inbox.name ?? inbox.id} (${inbox.subscription.app_key} / ${inbox.subscription.action_key}, ${inbox.status})`,
4250
+ name: inbox.name ?? inbox.id,
4251
+ hint: `${inbox.subscription.app_key} / ${inbox.subscription.action_key}, ${inbox.status}`,
4245
4252
  value: inbox.id
4246
4253
  }))
4247
4254
  })
@@ -4264,7 +4271,8 @@ var triggerMessagesResolver = {
4264
4271
  // are gone from the inbox already; available/quarantined ones can't be
4265
4272
  // operated on by these methods.
4266
4273
  choices: messages.filter((message) => message.status === "leased").map((message) => ({
4267
- name: `${message.id} (${message.status}, lease_count: ${message.message_attributes.lease_count})`,
4274
+ name: message.id,
4275
+ hint: `${message.status}, lease_count: ${message.message_attributes.lease_count}`,
4268
4276
  value: message.id
4269
4277
  }))
4270
4278
  })
@@ -4510,8 +4518,8 @@ async function createFieldKeyTranslator({
4510
4518
  function summarizeRecord(record) {
4511
4519
  const values = Object.values(record.data);
4512
4520
  const preview = values.slice(0, 3).map((v) => formatFieldValue(v).replace(/\s+/g, " ").trim()).filter((s) => s.length > 0).join(", ");
4513
- const truncated = preview.length > 60 ? preview.slice(0, 57) + "..." : preview;
4514
- return truncated ? `${record.id} \u2014 ${truncated}` : record.id;
4521
+ if (!preview) return void 0;
4522
+ return preview.length > 60 ? preview.slice(0, 57) + "..." : preview;
4515
4523
  }
4516
4524
  function fetchRecords(sdk, params) {
4517
4525
  return sdk.listTableRecords({
@@ -4521,7 +4529,7 @@ function fetchRecords(sdk, params) {
4521
4529
  }
4522
4530
  function recordChoices(records) {
4523
4531
  return records.map((record) => ({
4524
- name: summarizeRecord(record),
4532
+ name: summarizeRecord(record) || record.id,
4525
4533
  value: record.id
4526
4534
  }));
4527
4535
  }
@@ -4561,7 +4569,8 @@ var tableFieldIdsResolver = {
4561
4569
  name: "fields",
4562
4570
  message: "Select fields:",
4563
4571
  choices: fields.map((field) => ({
4564
- name: `${field.name} (${field.id}, ${field.type})`,
4572
+ name: field.name,
4573
+ hint: [field.id, field.type],
4565
4574
  value: field.id
4566
4575
  })),
4567
4576
  validate: (value) => Array.isArray(value) && value.length > 0 ? true : "Select at least one field"
@@ -8999,8 +9008,11 @@ var TriggerInboxItemSchema = withFormatter(
8999
9008
  );
9000
9009
 
9001
9010
  // src/plugins/triggers/createTriggerInbox/schemas.ts
9002
- var CreateTriggerInboxDescription = "Create a new trigger inbox subscription with an auto-generated name. Always creates; use ensureTriggerInbox for get-or-create on a stable name.";
9011
+ var CreateTriggerInboxDescription = "Create a new trigger inbox subscription. Always creates a new inbox; use ensureTriggerInbox for get-or-create on a stable name.";
9003
9012
  var CreateTriggerInboxSchema = zod.z.object({
9013
+ name: TriggerInboxNamePropertySchema.optional().describe(
9014
+ "Optional inbox name. Auto-generated when omitted. Throws a conflict error if the name is already in use by another subscription."
9015
+ ),
9004
9016
  app: AppPropertySchema,
9005
9017
  action: ActionPropertySchema,
9006
9018
  connection: ConnectionPropertySchema.nullable().optional().describe(
@@ -9018,6 +9030,39 @@ var triggersDefaults = {
9018
9030
  experimental: true
9019
9031
  };
9020
9032
 
9033
+ // src/plugins/triggers/utils.ts
9034
+ var UUID_REGEX = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
9035
+ async function resolveTriggerInboxId({
9036
+ api,
9037
+ inbox
9038
+ }) {
9039
+ if (UUID_REGEX.test(inbox)) {
9040
+ return inbox;
9041
+ }
9042
+ const rawResponse = await api.get("/trigger-inbox/api/v1/inboxes", {
9043
+ searchParams: { name: inbox, limit: "1" },
9044
+ authRequired: true
9045
+ });
9046
+ const response = rawResponse;
9047
+ const id = response.results?.[0]?.id;
9048
+ if (!id) {
9049
+ throw new ZapierResourceNotFoundError(
9050
+ `No trigger inbox named "${inbox}" found.`,
9051
+ { resourceType: "trigger_inbox", resourceId: inbox }
9052
+ );
9053
+ }
9054
+ return id;
9055
+ }
9056
+ function extractErrorDetail(data) {
9057
+ if (typeof data !== "object" || data === null) return void 0;
9058
+ const errors = data.errors;
9059
+ if (!Array.isArray(errors) || errors.length === 0) return void 0;
9060
+ const first = errors[0];
9061
+ if (typeof first !== "object" || first === null) return void 0;
9062
+ const detail = first.detail;
9063
+ return typeof detail === "string" ? detail : void 0;
9064
+ }
9065
+
9021
9066
  // src/plugins/triggers/createTriggerInbox/index.ts
9022
9067
  var createTriggerInboxPlugin = definePlugin(
9023
9068
  (sdk) => createPluginMethod(sdk, {
@@ -9032,6 +9077,7 @@ var createTriggerInboxPlugin = definePlugin(
9032
9077
  // seeded into resolvedParams without polluting the user-facing schema
9033
9078
  // (where it would leak into the SDK method signature and CLI flags).
9034
9079
  resolvers: {
9080
+ name: { type: "static", inputType: "text" },
9035
9081
  app: appKeyResolver,
9036
9082
  action: actionKeyResolver,
9037
9083
  connection: connectionIdResolver,
@@ -9041,6 +9087,7 @@ var createTriggerInboxPlugin = definePlugin(
9041
9087
  handler: async ({ sdk: sdk2, options }) => {
9042
9088
  const { api } = sdk2.context;
9043
9089
  const {
9090
+ name,
9044
9091
  app: appKey,
9045
9092
  action: actionKey,
9046
9093
  connection,
@@ -9066,13 +9113,28 @@ var createTriggerInboxPlugin = definePlugin(
9066
9113
  connection_id: resolvedConnectionId ?? null
9067
9114
  }
9068
9115
  };
9116
+ if (name !== void 0) {
9117
+ requestBody.name = name;
9118
+ }
9069
9119
  if (notificationUrl !== void 0) {
9070
9120
  requestBody.notification_url = notificationUrl;
9071
9121
  }
9072
9122
  const rawResponse = await api.post(
9073
9123
  "/trigger-inbox/api/v1/inboxes",
9074
9124
  requestBody,
9075
- { authRequired: true }
9125
+ {
9126
+ authRequired: true,
9127
+ customErrorHandler: ({ status, data }) => {
9128
+ if (status === 409) {
9129
+ const detail = extractErrorDetail(data);
9130
+ return new ZapierConflictError(
9131
+ detail ?? `An inbox named "${name}" already exists with a different subscription.`,
9132
+ { statusCode: status, resourceType: "trigger_inbox" }
9133
+ );
9134
+ }
9135
+ return void 0;
9136
+ }
9137
+ }
9076
9138
  );
9077
9139
  return { data: TriggerInboxItemSchema.parse(rawResponse) };
9078
9140
  }
@@ -9095,15 +9157,6 @@ var EnsureTriggerInboxSchema = zod.z.object({
9095
9157
  }).describe(EnsureTriggerInboxDescription);
9096
9158
 
9097
9159
  // src/plugins/triggers/ensureTriggerInbox/index.ts
9098
- function extractErrorDetail(data) {
9099
- if (typeof data !== "object" || data === null) return void 0;
9100
- const errors = data.errors;
9101
- if (!Array.isArray(errors) || errors.length === 0) return void 0;
9102
- const first = errors[0];
9103
- if (typeof first !== "object" || first === null) return void 0;
9104
- const detail = first.detail;
9105
- return typeof detail === "string" ? detail : void 0;
9106
- }
9107
9160
  var ensureTriggerInboxPlugin = definePlugin(
9108
9161
  (sdk) => createPluginMethod(sdk, {
9109
9162
  ...triggersDefaults,
@@ -9247,30 +9300,6 @@ var GetTriggerInboxSchema = zod.z.object({
9247
9300
  inbox: TriggerInboxPropertySchema
9248
9301
  }).describe("Get details of a trigger inbox by ID");
9249
9302
 
9250
- // src/plugins/triggers/utils.ts
9251
- var UUID_REGEX = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
9252
- async function resolveTriggerInboxId({
9253
- api,
9254
- inbox
9255
- }) {
9256
- if (UUID_REGEX.test(inbox)) {
9257
- return inbox;
9258
- }
9259
- const rawResponse = await api.get("/trigger-inbox/api/v1/inboxes", {
9260
- searchParams: { name: inbox, limit: "1" },
9261
- authRequired: true
9262
- });
9263
- const response = rawResponse;
9264
- const id = response.results?.[0]?.id;
9265
- if (!id) {
9266
- throw new ZapierResourceNotFoundError(
9267
- `No trigger inbox named "${inbox}" found.`,
9268
- { resourceType: "trigger_inbox", resourceId: inbox }
9269
- );
9270
- }
9271
- return id;
9272
- }
9273
-
9274
9303
  // src/plugins/triggers/getTriggerInbox/index.ts
9275
9304
  var getTriggerInboxPlugin = definePlugin(
9276
9305
  (sdk) => createPluginMethod(sdk, {
@@ -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-SDDmBk2j.mjs';
2
- export { u as Action, ci as ActionExecutionOptions, y as ActionExecutionResult, z as ActionField, H as ActionFieldChoice, aW as ActionItem, bx as ActionKeyProperty, b5 as ActionKeyPropertySchema, by as ActionProperty, b6 as ActionPropertySchema, as as ActionResolverItem, bJ as ActionTimeoutMsProperty, bh as ActionTimeoutMsPropertySchema, at as ActionTypeItem, bw as ActionTypeProperty, b4 as ActionTypePropertySchema, bW as ApiError, dE as ApiEvent, d0 as ApiPluginOptions, d2 as ApiPluginProvides, v as App, cj as AppFactoryInput, aU as AppItem, bu as AppKeyProperty, b2 as AppKeyPropertySchema, bv as AppProperty, b3 as AppPropertySchema, aD as ApplicationLifecycleEventData, cb as ApprovalStatus, ch as AppsPluginProvides, bO as AppsProperty, bm as AppsPropertySchema, a0 as ArrayResolver, dD as AuthEvent, bC as AuthenticationIdProperty, b9 as AuthenticationIdPropertySchema, az as BaseEvent, al as BaseSdkOptionsSchema, aa as BatchOptions, cP as CONTEXT_CACHE_MAX_SIZE, cO as CONTEXT_CACHE_TTL_MS, x as Choice, dK as ClientCredentialsObject, dV as ClientCredentialsObjectSchema, K as Connection, e1 as ConnectionEntry, e0 as ConnectionEntrySchema, bA as ConnectionIdProperty, b8 as ConnectionIdPropertySchema, aV as ConnectionItem, bB as ConnectionProperty, ba as ConnectionPropertySchema, e3 as ConnectionsMap, e2 as ConnectionsMapSchema, e5 as ConnectionsPluginProvides, bQ as ConnectionsProperty, bo as ConnectionsPropertySchema, O as ConnectionsResponse, cB as CreateClientCredentialsPluginProvides, eu as CreateTableFieldsPluginProvides, eo as CreateTablePluginProvides, eC as CreateTableRecordsPluginProvides, dH as Credentials, d_ as CredentialsFunction, dZ as CredentialsFunctionSchema, dJ as CredentialsObject, dX as CredentialsObjectSchema, d$ as CredentialsSchema, ea as DEFAULT_ACTION_TIMEOUT_MS, eh as DEFAULT_APPROVAL_TIMEOUT_MS, cY as DEFAULT_CONFIG_PATH, ei as DEFAULT_MAX_APPROVAL_RETRIES, e9 as DEFAULT_PAGE_SIZE, bH as DebugProperty, bf as DebugPropertySchema, cD as DeleteClientCredentialsPluginProvides, ew as DeleteTableFieldsPluginProvides, eq as DeleteTablePluginProvides, eE as DeleteTableRecordsPluginProvides, o as DrainTriggerInboxCallback, p as DrainTriggerInboxErrorObserver, a3 as DynamicListResolver, a4 as DynamicSearchResolver, aE as EnhancedErrorEventData, bX as ErrorOptions, dG as EventCallback, aC as EventContext, aB as EventEmissionProvides, cl as FetchPluginProvides, w as Field, bN as FieldsProperty, bl as FieldsPropertySchema, a5 as FieldsResolver, s as FindFirstAuthenticationPluginProvides, cL as FindFirstConnectionPluginProvides, t as FindUniqueAuthenticationPluginProvides, cN as FindUniqueConnectionPluginProvides, Y as FormatMetadata, X as FormattedItem, ak as FunctionDeprecation, a$ as FunctionOptions, aj as FunctionRegistryEntry, cv as GetActionInputFieldsSchemaPluginProvides, cH as GetActionPluginProvides, cF as GetAppPluginProvides, G as GetAuthenticationPluginProvides, cJ as GetConnectionPluginProvides, c$ as GetProfilePluginProvides, em as GetTablePluginProvides, ey as GetTableRecordPluginProvides, aY as InfoFieldItem, aX as InputFieldItem, bz as InputFieldProperty, b7 as InputFieldPropertySchema, bD as InputsProperty, bb as InputsPropertySchema, bV as LeaseLimitProperty, bt as LeaseLimitPropertySchema, bT as LeaseProperty, br as LeasePropertySchema, bU as LeaseSecondsProperty, bs as LeaseSecondsPropertySchema, L as LeasedTriggerMessageItem, bE as LimitProperty, bc as LimitPropertySchema, ct as ListActionInputFieldChoicesPluginProvides, cr as ListActionInputFieldsPluginProvides, cp as ListActionsPluginProvides, cn as ListAppsPluginProvides, q as ListAuthenticationsPluginProvides, cz as ListClientCredentialsPluginProvides, cx as ListConnectionsPluginProvides, es as ListTableFieldsPluginProvides, eA as ListTableRecordsPluginProvides, ek as ListTablesPluginProvides, dF as LoadingEvent, ed as MAX_CONCURRENCY_LIMIT, e8 as MAX_PAGE_LIMIT, cZ as ManifestEntry, cU as ManifestPluginOptions, cX as ManifestPluginProvides, aA as MethodCalledEvent, aF as MethodCalledEventData, N as Need, I as NeedsRequest, J as NeedsResponse, bF as OffsetProperty, bd as OffsetPropertySchema, _ as OutputFormatter, bG as OutputProperty, be as OutputPropertySchema, b1 as PaginatedSdkFunction, bI as ParamsProperty, bg as ParamsPropertySchema, dL as PkceCredentialsObject, dW as PkceCredentialsObjectSchema, am as Plugin, an as PluginProvides, aw as PollOptions, c9 as RateLimitInfo, bL as RecordProperty, bj as RecordPropertySchema, bM as RecordsProperty, bk as RecordsPropertySchema, af as RelayFetchSchema, ae as RelayRequestSchema, av as RequestOptions, cT as RequestPluginProvides, dq as ResolveAuthTokenOptions, dQ as ResolveCredentialsOptions, dI as ResolvedCredentials, dY as ResolvedCredentialsSchema, $ as Resolver, a1 as ResolverMetadata, aZ as RootFieldItem, cR as RunActionPluginProvides, dC as SdkEvent, b0 as SdkPage, a2 as StaticResolver, bK as TableProperty, bi as TablePropertySchema, bP as TablesProperty, bn as TablesPropertySchema, bS as TriggerInboxNameProperty, bq as TriggerInboxNamePropertySchema, bR as TriggerInboxProperty, bp as TriggerInboxPropertySchema, T as TriggerMessageStatus, eG as UpdateTableRecordsPluginProvides, Q as UserProfile, a_ as UserProfileItem, e6 as ZAPIER_BASE_URL, ef as ZAPIER_MAX_CONCURRENT_REQUESTS, eb as ZAPIER_MAX_NETWORK_RETRIES, ec as ZAPIER_MAX_NETWORK_RETRY_DELAY_MS, m as ZapierAbortDrainSignal, c7 as ZapierActionError, bZ as ZapierApiError, b_ as ZapierAppNotFoundError, cc as ZapierApprovalError, c1 as ZapierAuthenticationError, c5 as ZapierBundleError, dy as ZapierCache, dz as ZapierCacheEntry, dA as ZapierCacheSetOptions, c4 as ZapierConfigurationError, c8 as ZapierConflictError, bY as ZapierError, c2 as ZapierNotFoundError, ca as ZapierRateLimitError, cd as ZapierRelayError, n as ZapierReleaseTriggerMessageSignal, c3 as ZapierResourceNotFoundError, cf as ZapierSignal, c6 as ZapierTimeoutError, c0 as ZapierUnknownError, b$ as ZapierValidationError, d5 as actionKeyResolver, d4 as actionTypeResolver, d1 as apiPlugin, d3 as appKeyResolver, cg as appsPlugin, d7 as authenticationIdGenericResolver, d6 as authenticationIdResolver, a9 as batch, aP as buildApplicationLifecycleEvent, ab as buildCapabilityMessage, aR as buildErrorEvent, aQ as buildErrorEventWithContext, aT as buildMethodCalledEvent, dr as clearTokenCache, db as clientCredentialsNameResolver, dc as clientIdResolver, ar as composePlugins, d7 as connectionIdGenericResolver, d6 as connectionIdResolver, e4 as connectionsPlugin, aS as createBaseEvent, cA as createClientCredentialsPlugin, V as createFunction, dB as createMemoryCache, ai as createOptionsPlugin, aq as createPaginatedPluginMethod, ap as createPluginMethod, ah as createSdk, et as createTableFieldsPlugin, en as createTablePlugin, eB as createTableRecordsPlugin, ax as createZapierApi, ag as createZapierSdkWithoutRegistry, ao as definePlugin, cC as deleteClientCredentialsPlugin, ev as deleteTableFieldsPlugin, ep as deleteTablePlugin, eD as deleteTableRecordsPlugin, ck as fetchPlugin, cK as findFirstConnectionPlugin, cM as findUniqueConnectionPlugin, ce as formatErrorMessage, aG as generateEventId, cu as getActionInputFieldsSchemaPlugin, cG as getActionPlugin, cE as getAppPlugin, dT as getBaseUrlFromCredentials, aM as getCiPlatform, dU as getClientIdFromCredentials, cI as getConnectionPlugin, aO as getCpuTime, aH as getCurrentTimestamp, aN as getMemoryUsage, ay as getOrCreateApiClient, aJ as getOsInfo, aK as getPlatformVersions, cV as getPreferredManifestEntryKey, c_ as getProfilePlugin, aI as getReleaseId, el as getTablePlugin, ex as getTableRecordPlugin, dv as getTokenFromCliLogin, eg as getZapierApprovalMode, e7 as getZapierSdkService, dt as injectCliLogin, da as inputFieldKeyResolver, d9 as inputsAllOptionalResolver, d8 as inputsResolver, ds as invalidateCachedToken, dx as invalidateCredentialsToken, aL as isCi, du as isCliLoginAvailable, dM as isClientCredentials, dP as isCredentialsFunction, dO as isCredentialsObject, dN as isPkceCredentials, S as isPositional, cs as listActionInputFieldChoicesPlugin, cq as listActionInputFieldsPlugin, co as listActionsPlugin, cm as listAppsPlugin, cy as listClientCredentialsPlugin, cw as listConnectionsPlugin, er as listTableFieldsPlugin, ez as listTableRecordsPlugin, ej as listTablesPlugin, ac as logDeprecation, cW as manifestPlugin, ee as parseConcurrencyEnvVar, au as registryPlugin, cS as requestPlugin, ad as resetDeprecationWarnings, dw as resolveAuthToken, dS as resolveCredentials, dR as resolveCredentialsFromEnv, cQ as runActionPlugin, a6 as runWithTelemetryContext, di as tableFieldIdsResolver, dk as tableFieldsResolver, dn as tableFiltersResolver, dd as tableIdResolver, dj as tableNameResolver, dg as tableRecordIdResolver, dh as tableRecordIdsResolver, dl as tableRecordsResolver, dp as tableSortResolver, dm as tableUpdateRecordsResolver, a7 as toSnakeCase, a8 as toTitleCase, de as triggerInboxResolver, df as triggerMessagesResolver, eF as updateTableRecordsPlugin } from './index-SDDmBk2j.mjs';
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-DjQ4XDAV.mjs';
2
+ export { u as Action, ci as ActionExecutionOptions, y as ActionExecutionResult, z as ActionField, H as ActionFieldChoice, aW as ActionItem, bx as ActionKeyProperty, b5 as ActionKeyPropertySchema, by as ActionProperty, b6 as ActionPropertySchema, as as ActionResolverItem, bJ as ActionTimeoutMsProperty, bh as ActionTimeoutMsPropertySchema, at as ActionTypeItem, bw as ActionTypeProperty, b4 as ActionTypePropertySchema, bW as ApiError, dE as ApiEvent, d0 as ApiPluginOptions, d2 as ApiPluginProvides, v as App, cj as AppFactoryInput, aU as AppItem, bu as AppKeyProperty, b2 as AppKeyPropertySchema, bv as AppProperty, b3 as AppPropertySchema, aD as ApplicationLifecycleEventData, cb as ApprovalStatus, ch as AppsPluginProvides, bO as AppsProperty, bm as AppsPropertySchema, a0 as ArrayResolver, dD as AuthEvent, bC as AuthenticationIdProperty, b9 as AuthenticationIdPropertySchema, az as BaseEvent, al as BaseSdkOptionsSchema, aa as BatchOptions, cP as CONTEXT_CACHE_MAX_SIZE, cO as CONTEXT_CACHE_TTL_MS, x as Choice, dK as ClientCredentialsObject, dV as ClientCredentialsObjectSchema, K as Connection, e1 as ConnectionEntry, e0 as ConnectionEntrySchema, bA as ConnectionIdProperty, b8 as ConnectionIdPropertySchema, aV as ConnectionItem, bB as ConnectionProperty, ba as ConnectionPropertySchema, e3 as ConnectionsMap, e2 as ConnectionsMapSchema, e5 as ConnectionsPluginProvides, bQ as ConnectionsProperty, bo as ConnectionsPropertySchema, O as ConnectionsResponse, cB as CreateClientCredentialsPluginProvides, eu as CreateTableFieldsPluginProvides, eo as CreateTablePluginProvides, eC as CreateTableRecordsPluginProvides, dH as Credentials, d_ as CredentialsFunction, dZ as CredentialsFunctionSchema, dJ as CredentialsObject, dX as CredentialsObjectSchema, d$ as CredentialsSchema, ea as DEFAULT_ACTION_TIMEOUT_MS, eh as DEFAULT_APPROVAL_TIMEOUT_MS, cY as DEFAULT_CONFIG_PATH, ei as DEFAULT_MAX_APPROVAL_RETRIES, e9 as DEFAULT_PAGE_SIZE, bH as DebugProperty, bf as DebugPropertySchema, cD as DeleteClientCredentialsPluginProvides, ew as DeleteTableFieldsPluginProvides, eq as DeleteTablePluginProvides, eE as DeleteTableRecordsPluginProvides, o as DrainTriggerInboxCallback, p as DrainTriggerInboxErrorObserver, a3 as DynamicListResolver, a4 as DynamicSearchResolver, aE as EnhancedErrorEventData, bX as ErrorOptions, dG as EventCallback, aC as EventContext, aB as EventEmissionProvides, cl as FetchPluginProvides, w as Field, bN as FieldsProperty, bl as FieldsPropertySchema, a5 as FieldsResolver, s as FindFirstAuthenticationPluginProvides, cL as FindFirstConnectionPluginProvides, t as FindUniqueAuthenticationPluginProvides, cN as FindUniqueConnectionPluginProvides, Y as FormatMetadata, X as FormattedItem, ak as FunctionDeprecation, a$ as FunctionOptions, aj as FunctionRegistryEntry, cv as GetActionInputFieldsSchemaPluginProvides, cH as GetActionPluginProvides, cF as GetAppPluginProvides, G as GetAuthenticationPluginProvides, cJ as GetConnectionPluginProvides, c$ as GetProfilePluginProvides, em as GetTablePluginProvides, ey as GetTableRecordPluginProvides, aY as InfoFieldItem, aX as InputFieldItem, bz as InputFieldProperty, b7 as InputFieldPropertySchema, bD as InputsProperty, bb as InputsPropertySchema, bV as LeaseLimitProperty, bt as LeaseLimitPropertySchema, bT as LeaseProperty, br as LeasePropertySchema, bU as LeaseSecondsProperty, bs as LeaseSecondsPropertySchema, L as LeasedTriggerMessageItem, bE as LimitProperty, bc as LimitPropertySchema, ct as ListActionInputFieldChoicesPluginProvides, cr as ListActionInputFieldsPluginProvides, cp as ListActionsPluginProvides, cn as ListAppsPluginProvides, q as ListAuthenticationsPluginProvides, cz as ListClientCredentialsPluginProvides, cx as ListConnectionsPluginProvides, es as ListTableFieldsPluginProvides, eA as ListTableRecordsPluginProvides, ek as ListTablesPluginProvides, dF as LoadingEvent, ed as MAX_CONCURRENCY_LIMIT, e8 as MAX_PAGE_LIMIT, cZ as ManifestEntry, cU as ManifestPluginOptions, cX as ManifestPluginProvides, aA as MethodCalledEvent, aF as MethodCalledEventData, N as Need, I as NeedsRequest, J as NeedsResponse, bF as OffsetProperty, bd as OffsetPropertySchema, _ as OutputFormatter, bG as OutputProperty, be as OutputPropertySchema, b1 as PaginatedSdkFunction, bI as ParamsProperty, bg as ParamsPropertySchema, dL as PkceCredentialsObject, dW as PkceCredentialsObjectSchema, am as Plugin, an as PluginProvides, aw as PollOptions, c9 as RateLimitInfo, bL as RecordProperty, bj as RecordPropertySchema, bM as RecordsProperty, bk as RecordsPropertySchema, af as RelayFetchSchema, ae as RelayRequestSchema, av as RequestOptions, cT as RequestPluginProvides, dq as ResolveAuthTokenOptions, dQ as ResolveCredentialsOptions, dI as ResolvedCredentials, dY as ResolvedCredentialsSchema, $ as Resolver, a1 as ResolverMetadata, aZ as RootFieldItem, cR as RunActionPluginProvides, dC as SdkEvent, b0 as SdkPage, a2 as StaticResolver, bK as TableProperty, bi as TablePropertySchema, bP as TablesProperty, bn as TablesPropertySchema, bS as TriggerInboxNameProperty, bq as TriggerInboxNamePropertySchema, bR as TriggerInboxProperty, bp as TriggerInboxPropertySchema, T as TriggerMessageStatus, eG as UpdateTableRecordsPluginProvides, Q as UserProfile, a_ as UserProfileItem, e6 as ZAPIER_BASE_URL, ef as ZAPIER_MAX_CONCURRENT_REQUESTS, eb as ZAPIER_MAX_NETWORK_RETRIES, ec as ZAPIER_MAX_NETWORK_RETRY_DELAY_MS, m as ZapierAbortDrainSignal, c7 as ZapierActionError, bZ as ZapierApiError, b_ as ZapierAppNotFoundError, cc as ZapierApprovalError, c1 as ZapierAuthenticationError, c5 as ZapierBundleError, dy as ZapierCache, dz as ZapierCacheEntry, dA as ZapierCacheSetOptions, c4 as ZapierConfigurationError, c8 as ZapierConflictError, bY as ZapierError, c2 as ZapierNotFoundError, ca as ZapierRateLimitError, cd as ZapierRelayError, n as ZapierReleaseTriggerMessageSignal, c3 as ZapierResourceNotFoundError, cf as ZapierSignal, c6 as ZapierTimeoutError, c0 as ZapierUnknownError, b$ as ZapierValidationError, d5 as actionKeyResolver, d4 as actionTypeResolver, d1 as apiPlugin, d3 as appKeyResolver, cg as appsPlugin, d7 as authenticationIdGenericResolver, d6 as authenticationIdResolver, a9 as batch, aP as buildApplicationLifecycleEvent, ab as buildCapabilityMessage, aR as buildErrorEvent, aQ as buildErrorEventWithContext, aT as buildMethodCalledEvent, dr as clearTokenCache, db as clientCredentialsNameResolver, dc as clientIdResolver, ar as composePlugins, d7 as connectionIdGenericResolver, d6 as connectionIdResolver, e4 as connectionsPlugin, aS as createBaseEvent, cA as createClientCredentialsPlugin, V as createFunction, dB as createMemoryCache, ai as createOptionsPlugin, aq as createPaginatedPluginMethod, ap as createPluginMethod, ah as createSdk, et as createTableFieldsPlugin, en as createTablePlugin, eB as createTableRecordsPlugin, ax as createZapierApi, ag as createZapierSdkWithoutRegistry, ao as definePlugin, cC as deleteClientCredentialsPlugin, ev as deleteTableFieldsPlugin, ep as deleteTablePlugin, eD as deleteTableRecordsPlugin, ck as fetchPlugin, cK as findFirstConnectionPlugin, cM as findUniqueConnectionPlugin, ce as formatErrorMessage, aG as generateEventId, cu as getActionInputFieldsSchemaPlugin, cG as getActionPlugin, cE as getAppPlugin, dT as getBaseUrlFromCredentials, aM as getCiPlatform, dU as getClientIdFromCredentials, cI as getConnectionPlugin, aO as getCpuTime, aH as getCurrentTimestamp, aN as getMemoryUsage, ay as getOrCreateApiClient, aJ as getOsInfo, aK as getPlatformVersions, cV as getPreferredManifestEntryKey, c_ as getProfilePlugin, aI as getReleaseId, el as getTablePlugin, ex as getTableRecordPlugin, dv as getTokenFromCliLogin, eg as getZapierApprovalMode, e7 as getZapierSdkService, dt as injectCliLogin, da as inputFieldKeyResolver, d9 as inputsAllOptionalResolver, d8 as inputsResolver, ds as invalidateCachedToken, dx as invalidateCredentialsToken, aL as isCi, du as isCliLoginAvailable, dM as isClientCredentials, dP as isCredentialsFunction, dO as isCredentialsObject, dN as isPkceCredentials, S as isPositional, cs as listActionInputFieldChoicesPlugin, cq as listActionInputFieldsPlugin, co as listActionsPlugin, cm as listAppsPlugin, cy as listClientCredentialsPlugin, cw as listConnectionsPlugin, er as listTableFieldsPlugin, ez as listTableRecordsPlugin, ej as listTablesPlugin, ac as logDeprecation, cW as manifestPlugin, ee as parseConcurrencyEnvVar, au as registryPlugin, cS as requestPlugin, ad as resetDeprecationWarnings, dw as resolveAuthToken, dS as resolveCredentials, dR as resolveCredentialsFromEnv, cQ as runActionPlugin, a6 as runWithTelemetryContext, di as tableFieldIdsResolver, dk as tableFieldsResolver, dn as tableFiltersResolver, dd as tableIdResolver, dj as tableNameResolver, dg as tableRecordIdResolver, dh as tableRecordIdsResolver, dl as tableRecordsResolver, dp as tableSortResolver, dm as tableUpdateRecordsResolver, a7 as toSnakeCase, a8 as toTitleCase, de as triggerInboxResolver, df as triggerMessagesResolver, eF as updateTableRecordsPlugin } from './index-DjQ4XDAV.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';
@@ -1432,6 +1432,7 @@ declare function createZapierSdk(options?: ZapierSdkOptions): WithAddPlugin<{
1432
1432
  createTriggerInbox: (options?: {
1433
1433
  app: string;
1434
1434
  action: string;
1435
+ name?: string | undefined;
1435
1436
  connection?: string | number | null | undefined;
1436
1437
  inputs?: Record<string, unknown> | undefined;
1437
1438
  notificationUrl?: string | undefined;
@@ -1447,6 +1447,7 @@ export declare function createZapierSdk(options?: ZapierSdkOptions): import("./i
1447
1447
  createTriggerInbox: (options?: {
1448
1448
  app: string;
1449
1449
  action: string;
1450
+ name?: string | undefined;
1450
1451
  connection?: string | number | null | undefined;
1451
1452
  inputs?: Record<string, unknown> | undefined;
1452
1453
  notificationUrl?: string | undefined;
@@ -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;AAwEjD,cAAc,SAAS,CAAC;AAExB,MAAM,WAAW,gBAAiB,SAAQ,cAAc;CAAG;AAE3D,wBAAgB,eAAe,CAAC,OAAO,GAAE,gBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;sBA+Fq9K,CAAC;;;;sBAAiX,CAAC;qBAAyB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAT/5L;AAED,MAAM,MAAM,SAAS,GAAG,UAAU,CAAC,OAAO,eAAe,CAAC,CAAC;AAM3D,YAAY,EAAE,UAAU,EAAE,CAAC"}
@@ -2879,7 +2879,7 @@ async function invalidateCredentialsToken(options) {
2879
2879
  }
2880
2880
 
2881
2881
  // src/sdk-version.ts
2882
- var SDK_VERSION = (typeof process !== "undefined" && process.env ? "0.54.0" : void 0) || "unknown";
2882
+ var SDK_VERSION = (typeof process !== "undefined" && process.env ? "0.55.0" : void 0) || "unknown";
2883
2883
 
2884
2884
  // src/utils/open-url.ts
2885
2885
  var nodePrefix = "node:";
@@ -3976,7 +3976,8 @@ var appKeyResolver = {
3976
3976
  name: "app",
3977
3977
  message: "Select app:",
3978
3978
  choices: apps.map((app) => ({
3979
- name: app.title ? `${app.title} (${getAppKeyList(app).join(", ")})` : app.key,
3979
+ name: app.title || app.key,
3980
+ hint: app.title ? getAppKeyList(app) : void 0,
3980
3981
  value: app.key
3981
3982
  }))
3982
3983
  })
@@ -4024,7 +4025,8 @@ var actionKeyResolver = {
4024
4025
  name: "action",
4025
4026
  message: "Select action:",
4026
4027
  choices: actions.map((action) => ({
4027
- name: `${action.title || action.name || action.key} - ${action.description || "No description"}`,
4028
+ name: action.title || action.name || action.key,
4029
+ hint: action.description || void 0,
4028
4030
  value: action.key
4029
4031
  }))
4030
4032
  })
@@ -4049,7 +4051,7 @@ function promptForConnection(connections, params) {
4049
4051
  name: "connection",
4050
4052
  message: params.app ? `Select connection for ${params.app}:` : "Select connection:",
4051
4053
  choices: connections.map((connection) => ({
4052
- name: `${connection.title || connection.label || "Connection"} (ID: ${connection.id})`,
4054
+ name: connection.title || connection.label || "Connection",
4053
4055
  value: connection.id
4054
4056
  }))
4055
4057
  };
@@ -4164,7 +4166,11 @@ var inputFieldKeyResolver = {
4164
4166
  name: "inputField",
4165
4167
  message: "Select input field:",
4166
4168
  choices: fields.map((field) => ({
4167
- name: `${field.title || field.key} - ${field.value_type || "No type"} ${field.is_required ? "(required)" : "(optional)"}`,
4169
+ name: field.title || field.key,
4170
+ hint: [
4171
+ field.value_type,
4172
+ field.is_required ? "required" : "optional"
4173
+ ].filter(Boolean),
4168
4174
  value: field.key
4169
4175
  }))
4170
4176
  })
@@ -4189,7 +4195,7 @@ var clientIdResolver = {
4189
4195
  name: "clientId",
4190
4196
  message: "Select client credentials to delete:",
4191
4197
  choices: credentials.map((cred) => ({
4192
- name: `${cred.name} (${cred.client_id})`,
4198
+ name: cred.name,
4193
4199
  value: cred.client_id
4194
4200
  }))
4195
4201
  })
@@ -4222,7 +4228,7 @@ var tableIdResolver = {
4222
4228
  name: "table",
4223
4229
  message: "Select a table:",
4224
4230
  choices: tables.map((table) => ({
4225
- name: `${table.name} (${table.id})`,
4231
+ name: table.name,
4226
4232
  value: table.id
4227
4233
  }))
4228
4234
  })
@@ -4239,7 +4245,8 @@ var triggerInboxResolver = {
4239
4245
  // `deleting` inboxes are on their way out — no operation against them
4240
4246
  // is useful (delete is a no-op, pause/resume/update are rejected).
4241
4247
  choices: inboxes.filter((inbox) => inbox.status !== "deleting").map((inbox) => ({
4242
- name: `${inbox.name ?? inbox.id} (${inbox.subscription.app_key} / ${inbox.subscription.action_key}, ${inbox.status})`,
4248
+ name: inbox.name ?? inbox.id,
4249
+ hint: `${inbox.subscription.app_key} / ${inbox.subscription.action_key}, ${inbox.status}`,
4243
4250
  value: inbox.id
4244
4251
  }))
4245
4252
  })
@@ -4262,7 +4269,8 @@ var triggerMessagesResolver = {
4262
4269
  // are gone from the inbox already; available/quarantined ones can't be
4263
4270
  // operated on by these methods.
4264
4271
  choices: messages.filter((message) => message.status === "leased").map((message) => ({
4265
- name: `${message.id} (${message.status}, lease_count: ${message.message_attributes.lease_count})`,
4272
+ name: message.id,
4273
+ hint: `${message.status}, lease_count: ${message.message_attributes.lease_count}`,
4266
4274
  value: message.id
4267
4275
  }))
4268
4276
  })
@@ -4508,8 +4516,8 @@ async function createFieldKeyTranslator({
4508
4516
  function summarizeRecord(record) {
4509
4517
  const values = Object.values(record.data);
4510
4518
  const preview = values.slice(0, 3).map((v) => formatFieldValue(v).replace(/\s+/g, " ").trim()).filter((s) => s.length > 0).join(", ");
4511
- const truncated = preview.length > 60 ? preview.slice(0, 57) + "..." : preview;
4512
- return truncated ? `${record.id} \u2014 ${truncated}` : record.id;
4519
+ if (!preview) return void 0;
4520
+ return preview.length > 60 ? preview.slice(0, 57) + "..." : preview;
4513
4521
  }
4514
4522
  function fetchRecords(sdk, params) {
4515
4523
  return sdk.listTableRecords({
@@ -4519,7 +4527,7 @@ function fetchRecords(sdk, params) {
4519
4527
  }
4520
4528
  function recordChoices(records) {
4521
4529
  return records.map((record) => ({
4522
- name: summarizeRecord(record),
4530
+ name: summarizeRecord(record) || record.id,
4523
4531
  value: record.id
4524
4532
  }));
4525
4533
  }
@@ -4559,7 +4567,8 @@ var tableFieldIdsResolver = {
4559
4567
  name: "fields",
4560
4568
  message: "Select fields:",
4561
4569
  choices: fields.map((field) => ({
4562
- name: `${field.name} (${field.id}, ${field.type})`,
4570
+ name: field.name,
4571
+ hint: [field.id, field.type],
4563
4572
  value: field.id
4564
4573
  })),
4565
4574
  validate: (value) => Array.isArray(value) && value.length > 0 ? true : "Select at least one field"
@@ -8997,8 +9006,11 @@ var TriggerInboxItemSchema = withFormatter(
8997
9006
  );
8998
9007
 
8999
9008
  // src/plugins/triggers/createTriggerInbox/schemas.ts
9000
- var CreateTriggerInboxDescription = "Create a new trigger inbox subscription with an auto-generated name. Always creates; use ensureTriggerInbox for get-or-create on a stable name.";
9009
+ var CreateTriggerInboxDescription = "Create a new trigger inbox subscription. Always creates a new inbox; use ensureTriggerInbox for get-or-create on a stable name.";
9001
9010
  var CreateTriggerInboxSchema = z.object({
9011
+ name: TriggerInboxNamePropertySchema.optional().describe(
9012
+ "Optional inbox name. Auto-generated when omitted. Throws a conflict error if the name is already in use by another subscription."
9013
+ ),
9002
9014
  app: AppPropertySchema,
9003
9015
  action: ActionPropertySchema,
9004
9016
  connection: ConnectionPropertySchema.nullable().optional().describe(
@@ -9016,6 +9028,39 @@ var triggersDefaults = {
9016
9028
  experimental: true
9017
9029
  };
9018
9030
 
9031
+ // src/plugins/triggers/utils.ts
9032
+ var UUID_REGEX = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
9033
+ async function resolveTriggerInboxId({
9034
+ api,
9035
+ inbox
9036
+ }) {
9037
+ if (UUID_REGEX.test(inbox)) {
9038
+ return inbox;
9039
+ }
9040
+ const rawResponse = await api.get("/trigger-inbox/api/v1/inboxes", {
9041
+ searchParams: { name: inbox, limit: "1" },
9042
+ authRequired: true
9043
+ });
9044
+ const response = rawResponse;
9045
+ const id = response.results?.[0]?.id;
9046
+ if (!id) {
9047
+ throw new ZapierResourceNotFoundError(
9048
+ `No trigger inbox named "${inbox}" found.`,
9049
+ { resourceType: "trigger_inbox", resourceId: inbox }
9050
+ );
9051
+ }
9052
+ return id;
9053
+ }
9054
+ function extractErrorDetail(data) {
9055
+ if (typeof data !== "object" || data === null) return void 0;
9056
+ const errors = data.errors;
9057
+ if (!Array.isArray(errors) || errors.length === 0) return void 0;
9058
+ const first = errors[0];
9059
+ if (typeof first !== "object" || first === null) return void 0;
9060
+ const detail = first.detail;
9061
+ return typeof detail === "string" ? detail : void 0;
9062
+ }
9063
+
9019
9064
  // src/plugins/triggers/createTriggerInbox/index.ts
9020
9065
  var createTriggerInboxPlugin = definePlugin(
9021
9066
  (sdk) => createPluginMethod(sdk, {
@@ -9030,6 +9075,7 @@ var createTriggerInboxPlugin = definePlugin(
9030
9075
  // seeded into resolvedParams without polluting the user-facing schema
9031
9076
  // (where it would leak into the SDK method signature and CLI flags).
9032
9077
  resolvers: {
9078
+ name: { type: "static", inputType: "text" },
9033
9079
  app: appKeyResolver,
9034
9080
  action: actionKeyResolver,
9035
9081
  connection: connectionIdResolver,
@@ -9039,6 +9085,7 @@ var createTriggerInboxPlugin = definePlugin(
9039
9085
  handler: async ({ sdk: sdk2, options }) => {
9040
9086
  const { api } = sdk2.context;
9041
9087
  const {
9088
+ name,
9042
9089
  app: appKey,
9043
9090
  action: actionKey,
9044
9091
  connection,
@@ -9064,13 +9111,28 @@ var createTriggerInboxPlugin = definePlugin(
9064
9111
  connection_id: resolvedConnectionId ?? null
9065
9112
  }
9066
9113
  };
9114
+ if (name !== void 0) {
9115
+ requestBody.name = name;
9116
+ }
9067
9117
  if (notificationUrl !== void 0) {
9068
9118
  requestBody.notification_url = notificationUrl;
9069
9119
  }
9070
9120
  const rawResponse = await api.post(
9071
9121
  "/trigger-inbox/api/v1/inboxes",
9072
9122
  requestBody,
9073
- { authRequired: true }
9123
+ {
9124
+ authRequired: true,
9125
+ customErrorHandler: ({ status, data }) => {
9126
+ if (status === 409) {
9127
+ const detail = extractErrorDetail(data);
9128
+ return new ZapierConflictError(
9129
+ detail ?? `An inbox named "${name}" already exists with a different subscription.`,
9130
+ { statusCode: status, resourceType: "trigger_inbox" }
9131
+ );
9132
+ }
9133
+ return void 0;
9134
+ }
9135
+ }
9074
9136
  );
9075
9137
  return { data: TriggerInboxItemSchema.parse(rawResponse) };
9076
9138
  }
@@ -9093,15 +9155,6 @@ var EnsureTriggerInboxSchema = z.object({
9093
9155
  }).describe(EnsureTriggerInboxDescription);
9094
9156
 
9095
9157
  // src/plugins/triggers/ensureTriggerInbox/index.ts
9096
- function extractErrorDetail(data) {
9097
- if (typeof data !== "object" || data === null) return void 0;
9098
- const errors = data.errors;
9099
- if (!Array.isArray(errors) || errors.length === 0) return void 0;
9100
- const first = errors[0];
9101
- if (typeof first !== "object" || first === null) return void 0;
9102
- const detail = first.detail;
9103
- return typeof detail === "string" ? detail : void 0;
9104
- }
9105
9158
  var ensureTriggerInboxPlugin = definePlugin(
9106
9159
  (sdk) => createPluginMethod(sdk, {
9107
9160
  ...triggersDefaults,
@@ -9245,30 +9298,6 @@ var GetTriggerInboxSchema = z.object({
9245
9298
  inbox: TriggerInboxPropertySchema
9246
9299
  }).describe("Get details of a trigger inbox by ID");
9247
9300
 
9248
- // src/plugins/triggers/utils.ts
9249
- var UUID_REGEX = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
9250
- async function resolveTriggerInboxId({
9251
- api,
9252
- inbox
9253
- }) {
9254
- if (UUID_REGEX.test(inbox)) {
9255
- return inbox;
9256
- }
9257
- const rawResponse = await api.get("/trigger-inbox/api/v1/inboxes", {
9258
- searchParams: { name: inbox, limit: "1" },
9259
- authRequired: true
9260
- });
9261
- const response = rawResponse;
9262
- const id = response.results?.[0]?.id;
9263
- if (!id) {
9264
- throw new ZapierResourceNotFoundError(
9265
- `No trigger inbox named "${inbox}" found.`,
9266
- { resourceType: "trigger_inbox", resourceId: inbox }
9267
- );
9268
- }
9269
- return id;
9270
- }
9271
-
9272
9301
  // src/plugins/triggers/getTriggerInbox/index.ts
9273
9302
  var getTriggerInboxPlugin = definePlugin(
9274
9303
  (sdk) => createPluginMethod(sdk, {