@zapier/zapier-sdk 0.18.2 → 0.18.3

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 CHANGED
@@ -1,5 +1,11 @@
1
1
  # @zapier/zapier-sdk
2
2
 
3
+ ## 0.18.3
4
+
5
+ ### Patch Changes
6
+
7
+ - 7c59b01: - `listAuthentications` now routes through the proxy. It also imports and overrides a shared schema from `zapier-sdk-core`
8
+
3
9
  ## 0.18.2
4
10
 
5
11
  ### Patch Changes
package/README.md CHANGED
@@ -673,18 +673,18 @@ List available authentications with optional filtering
673
673
 
674
674
  **Parameters:**
675
675
 
676
- | Name | Type | Required | Default | Possible Values | Description |
677
- | --------------------- | ----------------- | -------- | ------- | --------------- | ------------------------------------------------------------------------------ |
678
- | `options` | `object` | ✅ | — | — | |
679
- | ↳ `appKey` | `string` | ❌ | — | — | App key of authentications to list (e.g., 'SlackCLIAPI' or slug like 'github') |
680
- | ↳ `authenticationIds` | `array` | ❌ | — | — | List of authentication IDs to filter by |
681
- | ↳ `search` | `string` | ❌ | — | — | Search term to filter authentications by title |
682
- | ↳ `title` | `string` | ❌ | — | — | Filter authentications by exact title match |
683
- | ↳ `accountId` | `string` | ❌ | — | — | Filter by account ID |
684
- | ↳ `owner` | `string, literal` | ❌ | — | — | Filter by owner, 'me' for your own authentications or a specific user ID |
685
- | ↳ `pageSize` | `number` | ❌ | — | — | Number of authentications per page |
686
- | ↳ `maxItems` | `number` | ❌ | — | — | Maximum total items to return across all pages |
687
- | ↳ `cursor` | `string` | ❌ | — | — | Cursor to start from |
676
+ | Name | Type | Required | Default | Possible Values | Description |
677
+ | --------------------- | -------- | -------- | ------- | --------------- | ---------------------------------------------------------------------------------- |
678
+ | `options` | `object` | ✅ | — | — | |
679
+ | ↳ `appKey` | `string` | ❌ | — | — | App key of authentications to list (e.g., 'SlackCLIAPI' or slug like 'github') |
680
+ | ↳ `authenticationIds` | `array` | ❌ | — | — | List of authentication IDs to filter by |
681
+ | ↳ `search` | `string` | ❌ | — | — | Search term to filter authentications by title |
682
+ | ↳ `title` | `string` | ❌ | — | — | Filter authentications by exact title match (searches first, then filters locally) |
683
+ | ↳ `accountId` | `string` | ❌ | — | — | Filter authentications by account ID |
684
+ | ↳ `owner` | `string` | ❌ | — | — | Filter by owner - 'me' for your own authentications or a specific user ID |
685
+ | ↳ `pageSize` | `number` | ❌ | — | — | Number of authentications per page |
686
+ | ↳ `maxItems` | `number` | ❌ | — | — | Maximum total items to return across all pages |
687
+ | ↳ `cursor` | `string` | ❌ | — | — | Cursor to start from |
688
688
 
689
689
  **Returns:** `Promise<PaginatedResult<AuthenticationItem>>`
690
690
 
@@ -130,55 +130,6 @@ export declare const ActionFieldSchema: z.ZodObject<{
130
130
  format: z.ZodOptional<z.ZodString>;
131
131
  inputFormat: z.ZodOptional<z.ZodArray<z.ZodString>>;
132
132
  }, z.core.$strip>;
133
- export declare const AuthenticationSchema: z.ZodObject<{
134
- id: z.ZodNumber;
135
- date: z.ZodString;
136
- lastchanged: z.ZodOptional<z.ZodString>;
137
- account_id: z.ZodNumber;
138
- customuser_id: z.ZodOptional<z.ZodNumber>;
139
- selected_api: z.ZodString;
140
- destination_selected_api: z.ZodOptional<z.ZodNullable<z.ZodString>>;
141
- is_invite_only: z.ZodBoolean;
142
- is_private: z.ZodBoolean;
143
- shared_with_all: z.ZodBoolean;
144
- is_stale: z.ZodOptional<z.ZodString>;
145
- is_shared: z.ZodOptional<z.ZodString>;
146
- marked_stale_at: z.ZodOptional<z.ZodNullable<z.ZodString>>;
147
- label: z.ZodOptional<z.ZodNullable<z.ZodString>>;
148
- identifier: z.ZodOptional<z.ZodNullable<z.ZodString>>;
149
- title: z.ZodOptional<z.ZodNullable<z.ZodString>>;
150
- url: z.ZodOptional<z.ZodString>;
151
- groups: z.ZodOptional<z.ZodString>;
152
- members: z.ZodOptional<z.ZodString>;
153
- permissions: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
154
- }, z.core.$strip>;
155
- export declare const AuthenticationsResponseSchema: z.ZodObject<{
156
- count: z.ZodNumber;
157
- next: z.ZodOptional<z.ZodNullable<z.ZodString>>;
158
- previous: z.ZodOptional<z.ZodNullable<z.ZodString>>;
159
- results: z.ZodArray<z.ZodObject<{
160
- id: z.ZodNumber;
161
- date: z.ZodString;
162
- lastchanged: z.ZodOptional<z.ZodString>;
163
- account_id: z.ZodNumber;
164
- customuser_id: z.ZodOptional<z.ZodNumber>;
165
- selected_api: z.ZodString;
166
- destination_selected_api: z.ZodOptional<z.ZodNullable<z.ZodString>>;
167
- is_invite_only: z.ZodBoolean;
168
- is_private: z.ZodBoolean;
169
- shared_with_all: z.ZodBoolean;
170
- is_stale: z.ZodOptional<z.ZodString>;
171
- is_shared: z.ZodOptional<z.ZodString>;
172
- marked_stale_at: z.ZodOptional<z.ZodNullable<z.ZodString>>;
173
- label: z.ZodOptional<z.ZodNullable<z.ZodString>>;
174
- identifier: z.ZodOptional<z.ZodNullable<z.ZodString>>;
175
- title: z.ZodOptional<z.ZodNullable<z.ZodString>>;
176
- url: z.ZodOptional<z.ZodString>;
177
- groups: z.ZodOptional<z.ZodString>;
178
- members: z.ZodOptional<z.ZodString>;
179
- permissions: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
180
- }, z.core.$strip>>;
181
- }, z.core.$strip>;
182
133
  export declare const UserProfileSchema: z.ZodObject<{
183
134
  id: z.ZodNumber;
184
135
  code: z.ZodString;
@@ -1 +1 @@
1
- {"version":3,"file":"schemas.d.ts","sourceRoot":"","sources":["../../src/api/schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;GAIG;AAMH,eAAO,MAAM,iBAAiB;;;;;iBAK5B,CAAC;AAEH,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA0CrB,CAAC;AAEH,eAAO,MAA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;;;;;iBAIjC,CAAC;AAMH,eAAO,MAAM,kBAAkB;;;;;;iBAM7B,CAAC;AAEH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAM9B,CAAC;AAMH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAmB/B,CAAC;AAEH,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAKxC,CAAC;AAMH,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA2DnC,CAAC;AAEH,eAAO,MAAM,iCAAiC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAK5C,CAAC;AAMH,eAAO,MAAM,6BAA6B;;iBAExC,CAAC;AAEH,eAAO,MAAM,8BAA8B;;;iBAGzC,CAAC;AAEH,eAAO,MAAM,wBAAwB;;;;;;;;iBAsCnC,CAAC;AAEH,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;iBAOpC,CAAC"}
@@ -127,34 +127,6 @@ export const ActionFieldSchema = z.object({
127
127
  // ============================================================================
128
128
  // Main API Entity Schemas
129
129
  // ============================================================================
130
- export const AuthenticationSchema = z.object({
131
- id: z.number(),
132
- date: z.string(),
133
- lastchanged: z.string().optional(),
134
- account_id: z.number(),
135
- customuser_id: z.number().optional(),
136
- selected_api: z.string(),
137
- destination_selected_api: z.string().nullable().optional(),
138
- is_invite_only: z.boolean(),
139
- is_private: z.boolean(),
140
- shared_with_all: z.boolean(),
141
- is_stale: z.string().optional(),
142
- is_shared: z.string().optional(),
143
- marked_stale_at: z.string().nullable().optional(),
144
- label: z.string().nullable().optional(),
145
- identifier: z.string().nullable().optional(),
146
- title: z.string().nullable().optional(),
147
- url: z.string().optional(),
148
- groups: z.string().optional(),
149
- members: z.string().optional(),
150
- permissions: z.record(z.string(), z.boolean()).optional(),
151
- });
152
- export const AuthenticationsResponseSchema = z.object({
153
- count: z.number(),
154
- next: z.string().nullable().optional(),
155
- previous: z.string().nullable().optional(),
156
- results: z.array(AuthenticationSchema),
157
- });
158
130
  export const UserProfileSchema = z.object({
159
131
  id: z.number(),
160
132
  code: z.string(),
package/dist/index.cjs CHANGED
@@ -716,10 +716,16 @@ function createPageFunction(coreFn) {
716
716
  try {
717
717
  const result = await coreFn(options);
718
718
  if (result && typeof result === "object" && "data" in result) {
719
- const data = result.data;
719
+ const paginatedResult = result;
720
+ let nextCursor;
721
+ if (paginatedResult.nextCursor) {
722
+ nextCursor = paginatedResult.nextCursor;
723
+ } else if (paginatedResult.links?.next) {
724
+ nextCursor = extractCursor({ next: paginatedResult.links.next });
725
+ }
720
726
  return {
721
- data: Array.isArray(data) ? data : [data],
722
- nextCursor: result.nextCursor
727
+ data: Array.isArray(paginatedResult.data) ? paginatedResult.data : [paginatedResult.data],
728
+ nextCursor
723
729
  };
724
730
  }
725
731
  if (Array.isArray(result)) {
@@ -1025,34 +1031,6 @@ zod.z.object({
1025
1031
  format: zod.z.string().optional(),
1026
1032
  inputFormat: zod.z.array(zod.z.string()).optional()
1027
1033
  });
1028
- var AuthenticationSchema = zod.z.object({
1029
- id: zod.z.number(),
1030
- date: zod.z.string(),
1031
- lastchanged: zod.z.string().optional(),
1032
- account_id: zod.z.number(),
1033
- customuser_id: zod.z.number().optional(),
1034
- selected_api: zod.z.string(),
1035
- destination_selected_api: zod.z.string().nullable().optional(),
1036
- is_invite_only: zod.z.boolean(),
1037
- is_private: zod.z.boolean(),
1038
- shared_with_all: zod.z.boolean(),
1039
- is_stale: zod.z.string().optional(),
1040
- is_shared: zod.z.string().optional(),
1041
- marked_stale_at: zod.z.string().nullable().optional(),
1042
- label: zod.z.string().nullable().optional(),
1043
- identifier: zod.z.string().nullable().optional(),
1044
- title: zod.z.string().nullable().optional(),
1045
- url: zod.z.string().optional(),
1046
- groups: zod.z.string().optional(),
1047
- members: zod.z.string().optional(),
1048
- permissions: zod.z.record(zod.z.string(), zod.z.boolean()).optional()
1049
- });
1050
- zod.z.object({
1051
- count: zod.z.number(),
1052
- next: zod.z.string().nullable().optional(),
1053
- previous: zod.z.string().nullable().optional(),
1054
- results: zod.z.array(AuthenticationSchema)
1055
- });
1056
1034
  zod.z.object({
1057
1035
  id: zod.z.number(),
1058
1036
  code: zod.z.string(),
@@ -1443,50 +1421,6 @@ function normalizeImplementationMetaToAppItem(implementationMeta) {
1443
1421
  version: appVersion
1444
1422
  };
1445
1423
  }
1446
- function normalizeAuthenticationItem(auth, options = {}) {
1447
- let appKey = options.app_key;
1448
- let appVersion = options.app_version;
1449
- if (auth.selected_api) {
1450
- const [extractedAppKey, extractedVersion] = splitVersionedKey(
1451
- auth.selected_api
1452
- );
1453
- if (!appKey) {
1454
- appKey = extractedAppKey;
1455
- }
1456
- if (!appVersion) {
1457
- appVersion = extractedVersion;
1458
- }
1459
- }
1460
- const {
1461
- selected_api: selectedApi,
1462
- customuser_id: profileId,
1463
- id,
1464
- account_id: accountId,
1465
- ...restOfAuth
1466
- } = auth;
1467
- return {
1468
- ...restOfAuth,
1469
- // Pass through all other API response fields except selected_api
1470
- id: String(id),
1471
- // Convert to string
1472
- account_id: String(accountId),
1473
- // Convert to string
1474
- implementation_id: selectedApi,
1475
- // Rename selected_api to implementation_id
1476
- title: auth.title || auth.label || void 0,
1477
- // Coerce title from label if missing
1478
- is_expired: auth.is_stale,
1479
- // Map is_stale to is_expired
1480
- expired_at: auth.marked_stale_at,
1481
- // Map marked_stale_at to expired_at
1482
- app_key: appKey,
1483
- // App key from implementations endpoint or parsed from selected_api
1484
- app_version: appVersion,
1485
- // Version from selected_api or provided
1486
- profile_id: profileId != null ? String(profileId) : void 0
1487
- // Map customuser_id to profile_id, convert to string
1488
- };
1489
- }
1490
1424
  function normalizeActionItem(action) {
1491
1425
  const { name, type, selected_api: selectedApi } = action;
1492
1426
  const [appKey, appVersion] = selectedApi ? splitVersionedKey(selectedApi) : ["", void 0];
@@ -2248,19 +2182,22 @@ var listInputFieldsPlugin = ({ sdk, context }) => {
2248
2182
  }
2249
2183
  };
2250
2184
  };
2251
- var ListAuthenticationsSchema = zod.z.object({
2185
+ var ListAuthenticationsQuerySchema = authentications.ListAuthenticationsQuerySchema.omit(
2186
+ {
2187
+ offset: true
2188
+ }
2189
+ ).extend({
2190
+ // Override appKey with our custom schema (array type, different description)
2252
2191
  appKey: AppKeyPropertySchema.optional().describe(
2253
2192
  "App key of authentications to list (e.g., 'SlackCLIAPI' or slug like 'github')"
2254
2193
  ),
2194
+ // Override authenticationIds to be an array instead of comma-separated string
2255
2195
  authenticationIds: zod.z.array(zod.z.string()).optional().describe("List of authentication IDs to filter by"),
2256
- search: zod.z.string().optional().describe("Search term to filter authentications by title"),
2257
- title: zod.z.string().optional().describe("Filter authentications by exact title match"),
2258
- accountId: zod.z.string().optional().describe("Filter by account ID"),
2259
- owner: zod.z.union([zod.z.string(), zod.z.literal("me")]).optional().describe(
2260
- "Filter by owner, 'me' for your own authentications or a specific user ID"
2261
- ),
2196
+ // Override pageSize to make optional (needs to be fixed in `zapier-sdk-core`)
2262
2197
  pageSize: zod.z.number().min(1).optional().describe("Number of authentications per page"),
2198
+ // SDK specific property for pagination/iterator helpers
2263
2199
  maxItems: zod.z.number().min(1).optional().describe("Maximum total items to return across all pages"),
2200
+ // SDK specific property for pagination/iterator helpers
2264
2201
  cursor: zod.z.string().optional().describe("Cursor to start from")
2265
2202
  }).merge(TelemetryMarkerSchema).describe("List available authentications with optional filtering");
2266
2203
  var AuthenticationItemSchema = withFormatter(
@@ -2297,36 +2234,38 @@ var AuthenticationItemSchema = withFormatter(
2297
2234
  var listAuthenticationsPlugin = ({ context }) => {
2298
2235
  async function listAuthenticationsPage(options) {
2299
2236
  const { api, getVersionedImplementationId } = context;
2300
- const searchParams = {};
2237
+ const searchParams = {
2238
+ pageSize: options.pageSize.toString()
2239
+ };
2301
2240
  if (options.appKey) {
2302
2241
  const implementationId = await getVersionedImplementationId(
2303
2242
  options.appKey
2304
2243
  );
2305
2244
  if (implementationId) {
2306
2245
  const [versionlessSelectedApi] = splitVersionedKey(implementationId);
2307
- searchParams.versionless_selected_api = versionlessSelectedApi;
2246
+ searchParams.appKey = versionlessSelectedApi;
2308
2247
  }
2309
2248
  }
2310
2249
  if (options.authenticationIds && options.authenticationIds.length > 0) {
2311
- searchParams.ids = options.authenticationIds.join(",");
2250
+ searchParams.authenticationIds = options.authenticationIds.join(",");
2312
2251
  }
2313
2252
  if (options.search) {
2314
2253
  searchParams.search = options.search;
2315
- } else if (options.title) {
2316
- searchParams.search = options.title;
2254
+ }
2255
+ if (options.title) {
2256
+ searchParams.title = options.title;
2317
2257
  }
2318
2258
  if (options.accountId) {
2319
- searchParams.account_id = options.accountId;
2259
+ searchParams.accountId = options.accountId;
2320
2260
  }
2321
2261
  if (options.owner) {
2322
2262
  searchParams.owner = options.owner;
2323
2263
  }
2324
- searchParams.limit = options.pageSize.toString();
2325
2264
  if (options.cursor) {
2326
2265
  searchParams.offset = options.cursor;
2327
2266
  }
2328
- const data = await api.get(
2329
- "/zapier/api/v4/authentications/",
2267
+ const response = await api.get(
2268
+ "/api/v0/authentications",
2330
2269
  {
2331
2270
  searchParams,
2332
2271
  customErrorHandler: ({ status }) => {
@@ -2347,23 +2286,12 @@ var listAuthenticationsPlugin = ({ context }) => {
2347
2286
  authRequired: true
2348
2287
  }
2349
2288
  );
2350
- let auths = (data.results || []).map(
2351
- (auth) => normalizeAuthenticationItem(auth)
2352
- );
2353
- if (options.title) {
2354
- auths = auths.filter(
2355
- (auth) => auth.title === options.title
2356
- );
2357
- }
2358
- return {
2359
- data: auths,
2360
- nextCursor: extractCursor(data)
2361
- };
2289
+ return response;
2362
2290
  }
2363
2291
  const methodName = stripPageSuffix(listAuthenticationsPage.name);
2364
2292
  const listAuthenticationsDefinition = createPaginatedFunction(
2365
2293
  listAuthenticationsPage,
2366
- ListAuthenticationsSchema,
2294
+ ListAuthenticationsQuerySchema,
2367
2295
  createTelemetryCallback(context.eventEmission.emitMethodCalled, methodName),
2368
2296
  methodName
2369
2297
  );
@@ -2375,7 +2303,7 @@ var listAuthenticationsPlugin = ({ context }) => {
2375
2303
  categories: ["authentication"],
2376
2304
  type: "list",
2377
2305
  itemType: "Authentication",
2378
- inputSchema: ListAuthenticationsSchema,
2306
+ inputSchema: ListAuthenticationsQuerySchema,
2379
2307
  outputSchema: AuthenticationItemSchema,
2380
2308
  resolvers: {
2381
2309
  appKey: appKeyResolver
@@ -4881,7 +4809,7 @@ function getCpuTime() {
4881
4809
 
4882
4810
  // package.json
4883
4811
  var package_default = {
4884
- version: "0.18.2"};
4812
+ version: "0.18.3"};
4885
4813
 
4886
4814
  // src/plugins/eventEmission/builders.ts
4887
4815
  function createBaseEvent(context = {}) {
package/dist/index.d.mts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as zod from 'zod';
2
2
  import { z } from 'zod';
3
- import { AuthenticationSchema, AuthenticationsResponseSchema, GetAuthenticationParam, GetAuthenticationResponse, GetAuthenticationParamSchema } from '@zapier/zapier-sdk-core/v0/schemas/authentications';
3
+ import { AuthenticationSchema, AuthenticationsResponseSchema, AuthenticationItem as AuthenticationItem$1, GetAuthenticationParam, GetAuthenticationResponse, GetAuthenticationParamSchema } from '@zapier/zapier-sdk-core/v0/schemas/authentications';
4
4
  import * as zod_v4_core from 'zod/v4/core';
5
5
 
6
6
  /**
@@ -1516,15 +1516,15 @@ AppsPluginProvides>;
1516
1516
  interface ZapierSdkApps {
1517
1517
  }
1518
1518
 
1519
- declare const ListAuthenticationsSchema: z.ZodObject<{
1519
+ declare const ListAuthenticationsQuerySchema: z.ZodObject<{
1520
+ search: z.ZodOptional<z.ZodString>;
1521
+ title: z.ZodOptional<z.ZodString>;
1522
+ accountId: z.ZodOptional<z.ZodString>;
1523
+ owner: z.ZodOptional<z.ZodString>;
1520
1524
  appKey: z.ZodOptional<z.ZodString & {
1521
1525
  _def: z.core.$ZodStringDef & PositionalMetadata;
1522
1526
  }>;
1523
1527
  authenticationIds: z.ZodOptional<z.ZodArray<z.ZodString>>;
1524
- search: z.ZodOptional<z.ZodString>;
1525
- title: z.ZodOptional<z.ZodString>;
1526
- accountId: z.ZodOptional<z.ZodString>;
1527
- owner: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodLiteral<"me">]>>;
1528
1528
  pageSize: z.ZodOptional<z.ZodNumber>;
1529
1529
  maxItems: z.ZodOptional<z.ZodNumber>;
1530
1530
  cursor: z.ZodOptional<z.ZodString>;
@@ -1532,22 +1532,20 @@ declare const ListAuthenticationsSchema: z.ZodObject<{
1532
1532
  isNested: z.ZodOptional<z.ZodBoolean>;
1533
1533
  }, z.core.$strip>>;
1534
1534
  }, z.core.$strip>;
1535
- type ListAuthenticationsOptions = z.infer<typeof ListAuthenticationsSchema>;
1535
+ type ListAuthenticationsOptions = z.infer<typeof ListAuthenticationsQuerySchema>;
1536
+ interface ListAuthenticationsPage {
1537
+ data: AuthenticationItem$1[];
1538
+ nextCursor?: string;
1539
+ }
1536
1540
 
1537
1541
  interface ListAuthenticationsPluginProvides {
1538
- listAuthentications: (options?: ListAuthenticationsOptions) => Promise<{
1539
- data: AuthenticationItem[];
1540
- nextCursor?: string;
1541
- }> & AsyncIterable<{
1542
- data: AuthenticationItem[];
1543
- nextCursor?: string;
1544
- }> & {
1545
- items(): AsyncIterable<AuthenticationItem>;
1542
+ listAuthentications: (options?: ListAuthenticationsOptions) => Promise<ListAuthenticationsPage> & AsyncIterable<ListAuthenticationsPage> & {
1543
+ items(): AsyncIterable<AuthenticationItem$1>;
1546
1544
  };
1547
1545
  context: {
1548
1546
  meta: {
1549
1547
  listAuthentications: {
1550
- inputSchema: typeof ListAuthenticationsSchema;
1548
+ inputSchema: typeof ListAuthenticationsQuerySchema;
1551
1549
  };
1552
1550
  };
1553
1551
  };
@@ -2356,7 +2354,7 @@ declare function createZapierSdkWithoutRegistry(options?: ZapierSdkOptions): Sdk
2356
2354
  } & {
2357
2355
  meta: {
2358
2356
  listAuthentications: {
2359
- inputSchema: typeof ListAuthenticationsSchema;
2357
+ inputSchema: typeof ListAuthenticationsQuerySchema;
2360
2358
  };
2361
2359
  };
2362
2360
  } & {