@keystrokehq/zendesk 0.0.9 → 0.0.15

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 (55) hide show
  1. package/dist/_official/index.d.mts +1 -1
  2. package/dist/_official/index.mjs +1 -1
  3. package/dist/_runtime/index.d.mts +117 -321
  4. package/dist/_runtime/index.mjs +1 -1
  5. package/dist/client.d.mts +1 -1
  6. package/dist/client.mjs +1 -1
  7. package/dist/custom/connection.d.mts +1 -1
  8. package/dist/custom/connection.mjs +1 -1
  9. package/dist/custom/jobs.d.mts +1 -1
  10. package/dist/custom/jobs.mjs +1 -1
  11. package/dist/custom/organizations.d.mts +1 -1
  12. package/dist/custom/organizations.mjs +1 -1
  13. package/dist/custom/search.d.mts +1 -1
  14. package/dist/custom/search.mjs +1 -1
  15. package/dist/custom/tickets.d.mts +1 -1
  16. package/dist/custom/tickets.mjs +1 -1
  17. package/dist/custom/triggers.d.mts +1 -1
  18. package/dist/custom/triggers.mjs +1 -1
  19. package/dist/custom/users.d.mts +1 -1
  20. package/dist/custom/users.mjs +1 -1
  21. package/dist/custom.d.mts +1 -1
  22. package/dist/custom.mjs +1 -1
  23. package/dist/{factory-ou1q975N.mjs → factory-CCCKLvYC.mjs} +2 -1
  24. package/dist/integration-C7oBvhtb.mjs +76 -0
  25. package/dist/{integration-CdHa-pMh.d.mts → integration-CQfg4GuM.d.mts} +14 -34
  26. package/dist/{jobs-C_g4owe2.mjs → jobs-DQIapMfm.mjs} +1 -1
  27. package/dist/{jobs-Dl9hHlgC.d.mts → jobs-UlSX6gEP.d.mts} +5 -13
  28. package/dist/{organizations-DdUvE-1B.d.mts → organizations-CKAQNEHJ.d.mts} +33 -90
  29. package/dist/{organizations-sN29x0eG.mjs → organizations-DY_2cjq3.mjs} +1 -1
  30. package/dist/platform/connection.d.mts +1 -1
  31. package/dist/platform/connection.mjs +1 -1
  32. package/dist/platform/jobs.d.mts +1 -1
  33. package/dist/platform/jobs.mjs +1 -1
  34. package/dist/platform/organizations.d.mts +1 -1
  35. package/dist/platform/organizations.mjs +1 -1
  36. package/dist/platform/search.d.mts +1 -1
  37. package/dist/platform/search.mjs +1 -1
  38. package/dist/platform/tickets.d.mts +1 -1
  39. package/dist/platform/tickets.mjs +1 -1
  40. package/dist/platform/triggers.d.mts +1 -1
  41. package/dist/platform/triggers.mjs +1 -1
  42. package/dist/platform/users.d.mts +1 -1
  43. package/dist/platform/users.mjs +1 -1
  44. package/dist/platform.d.mts +1 -1
  45. package/dist/platform.mjs +1 -1
  46. package/dist/{search-68vtAp_t.d.mts → search-Bo7Y9fWp.d.mts} +9 -24
  47. package/dist/{search-D41iedQX.mjs → search-ijatwi9u.mjs} +1 -1
  48. package/dist/{tickets-a8IOtaZF.d.mts → tickets-BTRJSv_J.d.mts} +37 -101
  49. package/dist/{tickets-DJQf0-Dk.mjs → tickets-CGvxqnN4.mjs} +1 -1
  50. package/dist/{triggers-YRytUtLd.d.mts → triggers-CwBF6DYN.d.mts} +4 -3
  51. package/dist/{triggers-oJe3l-Nj.mjs → triggers-DYQL-F5D.mjs} +2 -52
  52. package/dist/{users-BbnHg3UX.d.mts → users-BGysoDAw.d.mts} +37 -101
  53. package/dist/{users-7GgP08U7.mjs → users-BSWjHzET.mjs} +1 -1
  54. package/package.json +4 -4
  55. package/dist/integration-DwdrlwuX.mjs +0 -174
@@ -1,6 +1,5 @@
1
- import * as _keystrokehq_core0 from "@keystrokehq/core";
2
1
  import { z } from "zod";
3
- import * as _keystrokehq_core_credential_set0 from "@keystrokehq/core/credential-set";
2
+ import * as _keystrokehq_core0 from "@keystrokehq/core";
4
3
 
5
4
  //#region src/users.d.ts
6
5
  declare const platformListUsers: _keystrokehq_core0.Operation<z.ZodObject<{
@@ -21,13 +20,10 @@ declare const platformListUsers: _keystrokehq_core0.Operation<z.ZodObject<{
21
20
  created_at: z.ZodOptional<z.ZodString>;
22
21
  updated_at: z.ZodOptional<z.ZodString>;
23
22
  }, z.core.$strip>>;
24
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
25
- ZENDESK_ACCESS_TOKEN: z.ZodString;
26
- ZENDESK_SUBDOMAIN: z.ZodString;
27
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
23
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-platform", z.ZodObject<{
28
24
  ZENDESK_ACCESS_TOKEN: z.ZodString;
29
25
  ZENDESK_SUBDOMAIN: z.ZodString;
30
- }, z.core.$strip>>[] | undefined>], undefined>;
26
+ }, z.core.$strip>>], undefined>;
31
27
  declare const customListUsers: _keystrokehq_core0.Operation<z.ZodObject<{
32
28
  page: z.ZodOptional<z.ZodNumber>;
33
29
  perPage: z.ZodOptional<z.ZodNumber>;
@@ -46,15 +42,11 @@ declare const customListUsers: _keystrokehq_core0.Operation<z.ZodObject<{
46
42
  created_at: z.ZodOptional<z.ZodString>;
47
43
  updated_at: z.ZodOptional<z.ZodString>;
48
44
  }, z.core.$strip>>;
49
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
50
- ZENDESK_SUBDOMAIN: z.ZodString;
51
- ZENDESK_EMAIL: z.ZodEmail;
52
- ZENDESK_API_TOKEN: z.ZodString;
53
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
45
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-custom", z.ZodObject<{
54
46
  ZENDESK_SUBDOMAIN: z.ZodString;
55
47
  ZENDESK_EMAIL: z.ZodEmail;
56
48
  ZENDESK_API_TOKEN: z.ZodString;
57
- }, z.core.$strip>>[] | undefined>], undefined>;
49
+ }, z.core.$strip>>], undefined>;
58
50
  declare const platformGetUser: _keystrokehq_core0.Operation<z.ZodObject<{
59
51
  id: z.ZodNumber;
60
52
  }, z.core.$strip>, z.ZodObject<{
@@ -66,13 +58,10 @@ declare const platformGetUser: _keystrokehq_core0.Operation<z.ZodObject<{
66
58
  organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
67
59
  created_at: z.ZodOptional<z.ZodString>;
68
60
  updated_at: z.ZodOptional<z.ZodString>;
69
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
70
- ZENDESK_ACCESS_TOKEN: z.ZodString;
71
- ZENDESK_SUBDOMAIN: z.ZodString;
72
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
61
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-platform", z.ZodObject<{
73
62
  ZENDESK_ACCESS_TOKEN: z.ZodString;
74
63
  ZENDESK_SUBDOMAIN: z.ZodString;
75
- }, z.core.$strip>>[] | undefined>], undefined>;
64
+ }, z.core.$strip>>], undefined>;
76
65
  declare const customGetUser: _keystrokehq_core0.Operation<z.ZodObject<{
77
66
  id: z.ZodNumber;
78
67
  }, z.core.$strip>, z.ZodObject<{
@@ -84,15 +73,11 @@ declare const customGetUser: _keystrokehq_core0.Operation<z.ZodObject<{
84
73
  organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
85
74
  created_at: z.ZodOptional<z.ZodString>;
86
75
  updated_at: z.ZodOptional<z.ZodString>;
87
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
88
- ZENDESK_SUBDOMAIN: z.ZodString;
89
- ZENDESK_EMAIL: z.ZodEmail;
90
- ZENDESK_API_TOKEN: z.ZodString;
91
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
76
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-custom", z.ZodObject<{
92
77
  ZENDESK_SUBDOMAIN: z.ZodString;
93
78
  ZENDESK_EMAIL: z.ZodEmail;
94
79
  ZENDESK_API_TOKEN: z.ZodString;
95
- }, z.core.$strip>>[] | undefined>], undefined>;
80
+ }, z.core.$strip>>], undefined>;
96
81
  declare const platformGetCurrentUser: _keystrokehq_core0.Operation<z.ZodObject<{}, z.core.$strip>, z.ZodObject<{
97
82
  id: z.ZodCoercedNumber<unknown>;
98
83
  name: z.ZodOptional<z.ZodString>;
@@ -102,13 +87,10 @@ declare const platformGetCurrentUser: _keystrokehq_core0.Operation<z.ZodObject<{
102
87
  organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
103
88
  created_at: z.ZodOptional<z.ZodString>;
104
89
  updated_at: z.ZodOptional<z.ZodString>;
105
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
90
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-platform", z.ZodObject<{
106
91
  ZENDESK_ACCESS_TOKEN: z.ZodString;
107
92
  ZENDESK_SUBDOMAIN: z.ZodString;
108
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
109
- ZENDESK_ACCESS_TOKEN: z.ZodString;
110
- ZENDESK_SUBDOMAIN: z.ZodString;
111
- }, z.core.$strip>>[] | undefined>], undefined>;
93
+ }, z.core.$strip>>], undefined>;
112
94
  declare const customGetCurrentUser: _keystrokehq_core0.Operation<z.ZodObject<{}, z.core.$strip>, z.ZodObject<{
113
95
  id: z.ZodCoercedNumber<unknown>;
114
96
  name: z.ZodOptional<z.ZodString>;
@@ -118,15 +100,11 @@ declare const customGetCurrentUser: _keystrokehq_core0.Operation<z.ZodObject<{},
118
100
  organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
119
101
  created_at: z.ZodOptional<z.ZodString>;
120
102
  updated_at: z.ZodOptional<z.ZodString>;
121
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
122
- ZENDESK_SUBDOMAIN: z.ZodString;
123
- ZENDESK_EMAIL: z.ZodEmail;
124
- ZENDESK_API_TOKEN: z.ZodString;
125
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
103
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-custom", z.ZodObject<{
126
104
  ZENDESK_SUBDOMAIN: z.ZodString;
127
105
  ZENDESK_EMAIL: z.ZodEmail;
128
106
  ZENDESK_API_TOKEN: z.ZodString;
129
- }, z.core.$strip>>[] | undefined>], undefined>;
107
+ }, z.core.$strip>>], undefined>;
130
108
  declare const platformSearchUsers: _keystrokehq_core0.Operation<z.ZodObject<{
131
109
  query: z.ZodString;
132
110
  }, z.core.$strip>, z.ZodObject<{
@@ -143,13 +121,10 @@ declare const platformSearchUsers: _keystrokehq_core0.Operation<z.ZodObject<{
143
121
  created_at: z.ZodOptional<z.ZodString>;
144
122
  updated_at: z.ZodOptional<z.ZodString>;
145
123
  }, z.core.$strip>>;
146
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
147
- ZENDESK_ACCESS_TOKEN: z.ZodString;
148
- ZENDESK_SUBDOMAIN: z.ZodString;
149
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
124
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-platform", z.ZodObject<{
150
125
  ZENDESK_ACCESS_TOKEN: z.ZodString;
151
126
  ZENDESK_SUBDOMAIN: z.ZodString;
152
- }, z.core.$strip>>[] | undefined>], undefined>;
127
+ }, z.core.$strip>>], undefined>;
153
128
  declare const customSearchUsers: _keystrokehq_core0.Operation<z.ZodObject<{
154
129
  query: z.ZodString;
155
130
  }, z.core.$strip>, z.ZodObject<{
@@ -166,15 +141,11 @@ declare const customSearchUsers: _keystrokehq_core0.Operation<z.ZodObject<{
166
141
  created_at: z.ZodOptional<z.ZodString>;
167
142
  updated_at: z.ZodOptional<z.ZodString>;
168
143
  }, z.core.$strip>>;
169
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
170
- ZENDESK_SUBDOMAIN: z.ZodString;
171
- ZENDESK_EMAIL: z.ZodEmail;
172
- ZENDESK_API_TOKEN: z.ZodString;
173
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
144
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-custom", z.ZodObject<{
174
145
  ZENDESK_SUBDOMAIN: z.ZodString;
175
146
  ZENDESK_EMAIL: z.ZodEmail;
176
147
  ZENDESK_API_TOKEN: z.ZodString;
177
- }, z.core.$strip>>[] | undefined>], undefined>;
148
+ }, z.core.$strip>>], undefined>;
178
149
  declare const platformCreateUser: _keystrokehq_core0.Operation<z.ZodObject<{
179
150
  name: z.ZodString;
180
151
  email: z.ZodEmail;
@@ -192,13 +163,10 @@ declare const platformCreateUser: _keystrokehq_core0.Operation<z.ZodObject<{
192
163
  organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
193
164
  created_at: z.ZodOptional<z.ZodString>;
194
165
  updated_at: z.ZodOptional<z.ZodString>;
195
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
196
- ZENDESK_ACCESS_TOKEN: z.ZodString;
197
- ZENDESK_SUBDOMAIN: z.ZodString;
198
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
166
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-platform", z.ZodObject<{
199
167
  ZENDESK_ACCESS_TOKEN: z.ZodString;
200
168
  ZENDESK_SUBDOMAIN: z.ZodString;
201
- }, z.core.$strip>>[] | undefined>], undefined>;
169
+ }, z.core.$strip>>], undefined>;
202
170
  declare const customCreateUser: _keystrokehq_core0.Operation<z.ZodObject<{
203
171
  name: z.ZodString;
204
172
  email: z.ZodEmail;
@@ -216,15 +184,11 @@ declare const customCreateUser: _keystrokehq_core0.Operation<z.ZodObject<{
216
184
  organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
217
185
  created_at: z.ZodOptional<z.ZodString>;
218
186
  updated_at: z.ZodOptional<z.ZodString>;
219
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
187
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-custom", z.ZodObject<{
220
188
  ZENDESK_SUBDOMAIN: z.ZodString;
221
189
  ZENDESK_EMAIL: z.ZodEmail;
222
190
  ZENDESK_API_TOKEN: z.ZodString;
223
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
224
- ZENDESK_SUBDOMAIN: z.ZodString;
225
- ZENDESK_EMAIL: z.ZodEmail;
226
- ZENDESK_API_TOKEN: z.ZodString;
227
- }, z.core.$strip>>[] | undefined>], undefined>;
191
+ }, z.core.$strip>>], undefined>;
228
192
  declare const platformUpdateUser: _keystrokehq_core0.Operation<z.ZodObject<{
229
193
  id: z.ZodNumber;
230
194
  name: z.ZodOptional<z.ZodString>;
@@ -244,13 +208,10 @@ declare const platformUpdateUser: _keystrokehq_core0.Operation<z.ZodObject<{
244
208
  organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
245
209
  created_at: z.ZodOptional<z.ZodString>;
246
210
  updated_at: z.ZodOptional<z.ZodString>;
247
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
211
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-platform", z.ZodObject<{
248
212
  ZENDESK_ACCESS_TOKEN: z.ZodString;
249
213
  ZENDESK_SUBDOMAIN: z.ZodString;
250
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
251
- ZENDESK_ACCESS_TOKEN: z.ZodString;
252
- ZENDESK_SUBDOMAIN: z.ZodString;
253
- }, z.core.$strip>>[] | undefined>], undefined>;
214
+ }, z.core.$strip>>], undefined>;
254
215
  declare const customUpdateUser: _keystrokehq_core0.Operation<z.ZodObject<{
255
216
  id: z.ZodNumber;
256
217
  name: z.ZodOptional<z.ZodString>;
@@ -270,39 +231,28 @@ declare const customUpdateUser: _keystrokehq_core0.Operation<z.ZodObject<{
270
231
  organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
271
232
  created_at: z.ZodOptional<z.ZodString>;
272
233
  updated_at: z.ZodOptional<z.ZodString>;
273
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
274
- ZENDESK_SUBDOMAIN: z.ZodString;
275
- ZENDESK_EMAIL: z.ZodEmail;
276
- ZENDESK_API_TOKEN: z.ZodString;
277
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
234
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-custom", z.ZodObject<{
278
235
  ZENDESK_SUBDOMAIN: z.ZodString;
279
236
  ZENDESK_EMAIL: z.ZodEmail;
280
237
  ZENDESK_API_TOKEN: z.ZodString;
281
- }, z.core.$strip>>[] | undefined>], undefined>;
238
+ }, z.core.$strip>>], undefined>;
282
239
  declare const platformDeleteUser: _keystrokehq_core0.Operation<z.ZodObject<{
283
240
  id: z.ZodNumber;
284
241
  }, z.core.$strip>, z.ZodObject<{
285
242
  success: z.ZodBoolean;
286
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
287
- ZENDESK_ACCESS_TOKEN: z.ZodString;
288
- ZENDESK_SUBDOMAIN: z.ZodString;
289
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
243
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-platform", z.ZodObject<{
290
244
  ZENDESK_ACCESS_TOKEN: z.ZodString;
291
245
  ZENDESK_SUBDOMAIN: z.ZodString;
292
- }, z.core.$strip>>[] | undefined>], undefined>;
246
+ }, z.core.$strip>>], undefined>;
293
247
  declare const customDeleteUser: _keystrokehq_core0.Operation<z.ZodObject<{
294
248
  id: z.ZodNumber;
295
249
  }, z.core.$strip>, z.ZodObject<{
296
250
  success: z.ZodBoolean;
297
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
251
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-custom", z.ZodObject<{
298
252
  ZENDESK_SUBDOMAIN: z.ZodString;
299
253
  ZENDESK_EMAIL: z.ZodEmail;
300
254
  ZENDESK_API_TOKEN: z.ZodString;
301
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
302
- ZENDESK_SUBDOMAIN: z.ZodString;
303
- ZENDESK_EMAIL: z.ZodEmail;
304
- ZENDESK_API_TOKEN: z.ZodString;
305
- }, z.core.$strip>>[] | undefined>], undefined>;
255
+ }, z.core.$strip>>], undefined>;
306
256
  declare const platformCreateManyUsers: _keystrokehq_core0.Operation<z.ZodObject<{
307
257
  users: z.ZodArray<z.ZodObject<{
308
258
  name: z.ZodString;
@@ -323,13 +273,10 @@ declare const platformCreateManyUsers: _keystrokehq_core0.Operation<z.ZodObject<
323
273
  url: z.ZodOptional<z.ZodString>;
324
274
  results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
325
275
  }, z.core.$strip>;
326
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
327
- ZENDESK_ACCESS_TOKEN: z.ZodString;
328
- ZENDESK_SUBDOMAIN: z.ZodString;
329
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
276
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-platform", z.ZodObject<{
330
277
  ZENDESK_ACCESS_TOKEN: z.ZodString;
331
278
  ZENDESK_SUBDOMAIN: z.ZodString;
332
- }, z.core.$strip>>[] | undefined>], undefined>;
279
+ }, z.core.$strip>>], undefined>;
333
280
  declare const customCreateManyUsers: _keystrokehq_core0.Operation<z.ZodObject<{
334
281
  users: z.ZodArray<z.ZodObject<{
335
282
  name: z.ZodString;
@@ -350,15 +297,11 @@ declare const customCreateManyUsers: _keystrokehq_core0.Operation<z.ZodObject<{
350
297
  url: z.ZodOptional<z.ZodString>;
351
298
  results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
352
299
  }, z.core.$strip>;
353
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
354
- ZENDESK_SUBDOMAIN: z.ZodString;
355
- ZENDESK_EMAIL: z.ZodEmail;
356
- ZENDESK_API_TOKEN: z.ZodString;
357
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
300
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-custom", z.ZodObject<{
358
301
  ZENDESK_SUBDOMAIN: z.ZodString;
359
302
  ZENDESK_EMAIL: z.ZodEmail;
360
303
  ZENDESK_API_TOKEN: z.ZodString;
361
- }, z.core.$strip>>[] | undefined>], undefined>;
304
+ }, z.core.$strip>>], undefined>;
362
305
  declare const platformUpdateManyUsers: _keystrokehq_core0.Operation<z.ZodObject<{
363
306
  users: z.ZodArray<z.ZodObject<{
364
307
  id: z.ZodNumber;
@@ -381,13 +324,10 @@ declare const platformUpdateManyUsers: _keystrokehq_core0.Operation<z.ZodObject<
381
324
  url: z.ZodOptional<z.ZodString>;
382
325
  results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
383
326
  }, z.core.$strip>;
384
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
327
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-platform", z.ZodObject<{
385
328
  ZENDESK_ACCESS_TOKEN: z.ZodString;
386
329
  ZENDESK_SUBDOMAIN: z.ZodString;
387
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
388
- ZENDESK_ACCESS_TOKEN: z.ZodString;
389
- ZENDESK_SUBDOMAIN: z.ZodString;
390
- }, z.core.$strip>>[] | undefined>], undefined>;
330
+ }, z.core.$strip>>], undefined>;
391
331
  declare const customUpdateManyUsers: _keystrokehq_core0.Operation<z.ZodObject<{
392
332
  users: z.ZodArray<z.ZodObject<{
393
333
  id: z.ZodNumber;
@@ -410,14 +350,10 @@ declare const customUpdateManyUsers: _keystrokehq_core0.Operation<z.ZodObject<{
410
350
  url: z.ZodOptional<z.ZodString>;
411
351
  results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
412
352
  }, z.core.$strip>;
413
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
414
- ZENDESK_SUBDOMAIN: z.ZodString;
415
- ZENDESK_EMAIL: z.ZodEmail;
416
- ZENDESK_API_TOKEN: z.ZodString;
417
- }, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
353
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:zendesk-custom", z.ZodObject<{
418
354
  ZENDESK_SUBDOMAIN: z.ZodString;
419
355
  ZENDESK_EMAIL: z.ZodEmail;
420
356
  ZENDESK_API_TOKEN: z.ZodString;
421
- }, z.core.$strip>>[] | undefined>], undefined>;
357
+ }, z.core.$strip>>], undefined>;
422
358
  //#endregion
423
359
  export { platformUpdateManyUsers as _, customGetUser as a, customUpdateManyUsers as c, platformCreateUser as d, platformDeleteUser as f, platformSearchUsers as g, platformListUsers as h, customGetCurrentUser as i, customUpdateUser as l, platformGetUser as m, customCreateUser as n, customListUsers as o, platformGetCurrentUser as p, customDeleteUser as r, customSearchUsers as s, customCreateManyUsers as t, platformCreateManyUsers as u, platformUpdateUser as v };
@@ -1,5 +1,5 @@
1
1
  import { zendeskBulkJobResponseSchema, zendeskUserEnvelopeSchema, zendeskUserListResponseSchema, zendeskUserSchema } from "./schemas.mjs";
2
- import { n as zendeskPlatformOperation, t as zendeskCustomOperation } from "./factory-ou1q975N.mjs";
2
+ import { n as zendeskPlatformOperation, t as zendeskCustomOperation } from "./factory-CCCKLvYC.mjs";
3
3
  import { n as createPlatformZendeskClient, t as createCustomZendeskClient } from "./shared-BmxcJmfq.mjs";
4
4
  import { z } from "zod";
5
5
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@keystrokehq/zendesk",
3
- "version": "0.0.9",
3
+ "version": "0.0.15",
4
4
  "private": false,
5
5
  "sideEffects": false,
6
6
  "type": "module",
@@ -132,18 +132,18 @@
132
132
  "LICENSE"
133
133
  ],
134
134
  "dependencies": {
135
+ "@keystrokehq/integration-authoring": "^0.0.9",
135
136
  "zod": "^4.3.6"
136
137
  },
137
138
  "peerDependencies": {
138
- "@keystrokehq/core": ">=0.0.8 <0.1.0"
139
+ "@keystrokehq/core": ">=0.0.13 <0.1.0"
139
140
  },
140
141
  "devDependencies": {
141
142
  "@types/node": "^22.19.11",
142
143
  "tsdown": "^0.20.3",
143
144
  "typescript": "^5.9.3",
144
145
  "vitest": "^4.0.18",
145
- "@keystrokehq/core": "^0.0.12",
146
- "@keystrokehq/integration-authoring": "0.0.9",
146
+ "@keystrokehq/core": "^0.0.13",
147
147
  "@keystrokehq/test-utils": "0.0.0",
148
148
  "@keystrokehq/typescript-config": "0.0.0"
149
149
  },
@@ -1,174 +0,0 @@
1
- import { CredentialSet, Operation } from "@keystrokehq/core";
2
- import { z } from "zod";
3
-
4
- //#region ../../packages/integration-authoring/dist/official/runtime.mjs
5
- const REGISTRY_KEY = "__ks_official_integration_metadata_registry";
6
- function getRegistry() {
7
- const globalStore = globalThis;
8
- if (!globalStore[REGISTRY_KEY]) globalStore[REGISTRY_KEY] = /* @__PURE__ */ new WeakMap();
9
- return globalStore[REGISTRY_KEY];
10
- }
11
- function registerOfficialOperation(operation, metadata) {
12
- getRegistry().set(operation, Object.freeze({ ...metadata }));
13
- }
14
-
15
- //#endregion
16
- //#region ../../packages/integration-authoring/dist/official/index.mjs
17
- const OFFICIAL_CREDENTIAL_SET_ID_PREFIX = "keystroke:";
18
- function officialCredentialSetId(id) {
19
- return `${OFFICIAL_CREDENTIAL_SET_ID_PREFIX}${id}`;
20
- }
21
- function stripOfficialCredentialSetIdPrefix(id) {
22
- return id.startsWith(OFFICIAL_CREDENTIAL_SET_ID_PREFIX) ? id.slice(10) : id;
23
- }
24
- /**
25
- * Creates a factory for Keystroke-official integration operations.
26
- *
27
- * It keeps the same flat `run(input, credentials)` ergonomics as the generic
28
- * operation factory, while registering official metadata for builder/runtime
29
- * operation metadata.
30
- */
31
- function createOfficialOperationFactory(credentialSet) {
32
- const integrationId = stripOfficialCredentialSetIdPrefix(credentialSet.id);
33
- return (config) => {
34
- const wrappedRun = async (input, ctx) => {
35
- const creds = ctx.credentials[credentialSet.id];
36
- return config.run(input, creds);
37
- };
38
- const operation = new Operation({
39
- id: config.id,
40
- name: config.name,
41
- description: config.description,
42
- input: config.input,
43
- output: config.output,
44
- credentialSets: [credentialSet],
45
- ...config.tags !== void 0 ? { tags: config.tags } : {},
46
- ...config.needsApproval !== void 0 ? { needsApproval: config.needsApproval } : {},
47
- ...config.requiredOAuthScopes !== void 0 ? { requiredOAuthScopes: config.requiredOAuthScopes } : {},
48
- ...config.retries !== void 0 ? { retries: config.retries } : {},
49
- ...config.timeout !== void 0 ? { timeout: config.timeout } : {},
50
- ...config.maxDurationMs !== void 0 ? { maxDurationMs: config.maxDurationMs } : {},
51
- run: wrappedRun
52
- });
53
- registerOfficialOperation(operation, { integrationId });
54
- return operation;
55
- };
56
- }
57
- /**
58
- * Creates an official integration bundle from a single config object.
59
- *
60
- * - Creates the public `CredentialSet` internally.
61
- * - Accepts optional `internal` fields for Keystroke-owned platform credentials.
62
- */
63
- function defineOfficialIntegration(config) {
64
- const internalCredentialSets = config.internal ?? {};
65
- const allInternalCredentialSets = [
66
- ...internalCredentialSets.providerApp ? [internalCredentialSets.providerApp] : [],
67
- ...internalCredentialSets.providerAppVariants ?? [],
68
- ...internalCredentialSets.webhookVerification ? [internalCredentialSets.webhookVerification] : [],
69
- ...internalCredentialSets.other ?? []
70
- ];
71
- const credentialSet = new CredentialSet({
72
- id: config.id,
73
- name: config.name,
74
- description: config.description,
75
- auth: config.auth,
76
- ...config.connections ? { connections: config.connections } : {},
77
- ...config.proxy ? { proxy: config.proxy } : {},
78
- ...config.needsRawSecret === true ? { needsRawSecret: true } : {}
79
- });
80
- return Object.freeze({
81
- integration: {
82
- id: config.id,
83
- name: config.name,
84
- ...config.description !== void 0 ? { description: config.description } : {},
85
- auth: config.auth,
86
- ...config.proxy ? { proxy: config.proxy } : {},
87
- ...config.needsRawSecret === true ? { needsRawSecret: true } : {},
88
- ...config.connections ? { connections: config.connections } : {}
89
- },
90
- credentialSet,
91
- internalCredentialSets,
92
- allInternalCredentialSets
93
- });
94
- }
95
-
96
- //#endregion
97
- //#region src/_official/provider-app.ts
98
- const zendeskPlatformAppCredentialSet = new CredentialSet({
99
- id: officialCredentialSetId("zendesk-platform-app"),
100
- exposure: "platform-only",
101
- name: "Zendesk Platform App",
102
- auth: z.object({
103
- clientId: z.string().min(1),
104
- clientSecret: z.string().min(1),
105
- webhookSigningSecret: z.string().min(1)
106
- })
107
- });
108
- const zendeskOfficialProviderSeed = {
109
- provider: "zendesk",
110
- appRef: "zendesk-platform",
111
- displayName: "Zendesk Platform",
112
- credentialSetName: "Keystroke Zendesk Platform App",
113
- envShape: {
114
- KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_ID: z.string().optional(),
115
- KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_SECRET: z.string().optional(),
116
- KEYSTROKE_OFFICIAL_ZENDESK_WEBHOOK_SIGNING_SECRET: z.string().optional()
117
- },
118
- requiredEnvKeys: [
119
- "KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_ID",
120
- "KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_SECRET",
121
- "KEYSTROKE_OFFICIAL_ZENDESK_WEBHOOK_SIGNING_SECRET"
122
- ],
123
- externalAppIdEnvKey: "KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_ID",
124
- buildCredentials: (env) => ({
125
- clientId: env.KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_ID,
126
- clientSecret: env.KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_SECRET,
127
- webhookSigningSecret: env.KEYSTROKE_OFFICIAL_ZENDESK_WEBHOOK_SIGNING_SECRET
128
- })
129
- };
130
-
131
- //#endregion
132
- //#region src/integration.ts
133
- const zendeskSubdomainSchema = z.string().trim().min(1).regex(/^[a-zA-Z0-9-]+$/, { error: "Zendesk subdomain must contain only letters, numbers, and hyphens" });
134
- const zendeskPlatformAuthSchema = z.object({
135
- ZENDESK_ACCESS_TOKEN: z.string().min(1),
136
- ZENDESK_SUBDOMAIN: zendeskSubdomainSchema
137
- });
138
- const zendeskCustomAuthSchema = z.object({
139
- ZENDESK_SUBDOMAIN: zendeskSubdomainSchema,
140
- ZENDESK_EMAIL: z.email(),
141
- ZENDESK_API_TOKEN: z.string().min(1)
142
- });
143
- const zendeskPlatformOfficialIntegration = {
144
- id: "zendesk.platform-oauth",
145
- name: "Zendesk (Platform OAuth)",
146
- description: "Zendesk Support via Keystroke-managed OAuth",
147
- auth: zendeskPlatformAuthSchema,
148
- connections: [{
149
- id: "oauth",
150
- kind: "oauth",
151
- tokenType: "refreshable",
152
- authUrl: "https://{subdomain}.zendesk.com/oauth/authorizations/new",
153
- tokenUrl: "https://{subdomain}.zendesk.com/oauth/tokens",
154
- revokeUrl: "https://{subdomain}.zendesk.com/api/v2/oauth/tokens/current",
155
- scopes: ["read", "write"],
156
- vault: { accessToken: "ZENDESK_ACCESS_TOKEN" }
157
- }]
158
- };
159
- const zendeskCustomOfficialIntegration = {
160
- id: "zendesk.custom-token",
161
- name: "Zendesk (Custom Token)",
162
- description: "Zendesk Support via bring-your-own API token",
163
- auth: zendeskCustomAuthSchema
164
- };
165
- const zendeskPlatformBundle = defineOfficialIntegration({
166
- ...zendeskPlatformOfficialIntegration,
167
- internal: { providerApp: zendeskPlatformAppCredentialSet }
168
- });
169
- const zendeskCustomBundle = defineOfficialIntegration(zendeskCustomOfficialIntegration);
170
- const zendeskPlatform = zendeskPlatformBundle.credentialSet;
171
- const zendeskCustom = zendeskCustomBundle.credentialSet;
172
-
173
- //#endregion
174
- export { zendeskPlatformBundle as a, zendeskPlatformAppCredentialSet as c, zendeskPlatform as i, createOfficialOperationFactory as l, zendeskCustomBundle as n, zendeskPlatformOfficialIntegration as o, zendeskCustomOfficialIntegration as r, zendeskOfficialProviderSeed as s, zendeskCustom as t };