@keystrokehq/zendesk 0.0.8 → 0.0.9
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/dist/_official/index.d.mts +1 -1
- package/dist/_official/index.mjs +1 -1
- package/dist/_runtime/index.d.mts +59 -59
- package/dist/_runtime/index.mjs +1 -1
- package/dist/client.d.mts +1 -1
- package/dist/client.mjs +1 -1
- package/dist/custom/connection.d.mts +1 -1
- package/dist/custom/connection.mjs +1 -1
- package/dist/custom/jobs.d.mts +1 -1
- package/dist/custom/jobs.mjs +1 -1
- package/dist/custom/organizations.d.mts +1 -1
- package/dist/custom/organizations.mjs +1 -1
- package/dist/custom/search.d.mts +1 -1
- package/dist/custom/search.mjs +1 -1
- package/dist/custom/tickets.d.mts +1 -1
- package/dist/custom/tickets.mjs +1 -1
- package/dist/custom/triggers.d.mts +1 -1
- package/dist/custom/triggers.mjs +1 -1
- package/dist/custom/users.d.mts +1 -1
- package/dist/custom/users.mjs +1 -1
- package/dist/custom.d.mts +1 -1
- package/dist/custom.mjs +1 -1
- package/dist/{factory-BkTVtxO3.mjs → factory-ou1q975N.mjs} +1 -2
- package/dist/{integration-CtcJn--7.d.mts → integration-CdHa-pMh.d.mts} +7 -9
- package/dist/integration-DwdrlwuX.mjs +174 -0
- package/dist/{jobs-CK59oLh4.mjs → jobs-C_g4owe2.mjs} +1 -1
- package/dist/{jobs-b1iHVfk8.d.mts → jobs-Dl9hHlgC.d.mts} +3 -3
- package/dist/{organizations-BhzeGbyt.d.mts → organizations-DdUvE-1B.d.mts} +17 -17
- package/dist/{organizations-B6d9UFNE.mjs → organizations-sN29x0eG.mjs} +1 -1
- package/dist/platform/connection.d.mts +1 -1
- package/dist/platform/connection.mjs +1 -1
- package/dist/platform/jobs.d.mts +1 -1
- package/dist/platform/jobs.mjs +1 -1
- package/dist/platform/organizations.d.mts +1 -1
- package/dist/platform/organizations.mjs +1 -1
- package/dist/platform/search.d.mts +1 -1
- package/dist/platform/search.mjs +1 -1
- package/dist/platform/tickets.d.mts +1 -1
- package/dist/platform/tickets.mjs +1 -1
- package/dist/platform/triggers.d.mts +1 -1
- package/dist/platform/triggers.mjs +1 -1
- package/dist/platform/users.d.mts +1 -1
- package/dist/platform/users.mjs +1 -1
- package/dist/platform.d.mts +1 -1
- package/dist/platform.mjs +1 -1
- package/dist/{search-BhDCvZbH.d.mts → search-68vtAp_t.d.mts} +5 -5
- package/dist/{search-CtezRdYT.mjs → search-D41iedQX.mjs} +1 -1
- package/dist/{tickets-Cfm1FvkY.mjs → tickets-DJQf0-Dk.mjs} +1 -1
- package/dist/{tickets-PVnTF9mU.d.mts → tickets-a8IOtaZF.d.mts} +19 -19
- package/dist/{triggers-cLdYl78y.d.mts → triggers-YRytUtLd.d.mts} +3 -4
- package/dist/{triggers-B-QDHWMY.mjs → triggers-oJe3l-Nj.mjs} +52 -2
- package/dist/{users-BzkPok3V.mjs → users-7GgP08U7.mjs} +1 -1
- package/dist/{users-wFde5fME.d.mts → users-BbnHg3UX.d.mts} +19 -19
- package/package.json +3 -3
- package/dist/integration-Dl2aSMKz.mjs +0 -83
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { z } from "zod";
|
|
2
1
|
import * as _keystrokehq_core0 from "@keystrokehq/core";
|
|
2
|
+
import { z } from "zod";
|
|
3
3
|
import * as _keystrokehq_core_credential_set0 from "@keystrokehq/core/credential-set";
|
|
4
4
|
|
|
5
5
|
//#region src/search.d.ts
|
|
@@ -21,7 +21,7 @@ declare const platformSearch: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
21
21
|
result_type: z.ZodOptional<z.ZodString>;
|
|
22
22
|
url: z.ZodOptional<z.ZodString>;
|
|
23
23
|
}, z.core.$strip>>;
|
|
24
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
24
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
25
25
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
26
26
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
27
27
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -46,7 +46,7 @@ declare const customSearch: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
46
46
|
result_type: z.ZodOptional<z.ZodString>;
|
|
47
47
|
url: z.ZodOptional<z.ZodString>;
|
|
48
48
|
}, z.core.$strip>>;
|
|
49
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
49
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
50
50
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
51
51
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
52
52
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -59,7 +59,7 @@ declare const platformCountSearchResults: _keystrokehq_core0.Operation<z.ZodObje
|
|
|
59
59
|
query: z.ZodString;
|
|
60
60
|
}, z.core.$strip>, z.ZodObject<{
|
|
61
61
|
count: z.ZodCoercedNumber<unknown>;
|
|
62
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
62
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
63
63
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
64
64
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
65
65
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -70,7 +70,7 @@ declare const customCountSearchResults: _keystrokehq_core0.Operation<z.ZodObject
|
|
|
70
70
|
query: z.ZodString;
|
|
71
71
|
}, z.core.$strip>, z.ZodObject<{
|
|
72
72
|
count: z.ZodCoercedNumber<unknown>;
|
|
73
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
73
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
74
74
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
75
75
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
76
76
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { zendeskSearchCountResponseSchema, zendeskSearchResponseSchema } from "./schemas.mjs";
|
|
2
|
-
import { n as zendeskPlatformOperation, t as zendeskCustomOperation } from "./factory-
|
|
2
|
+
import { n as zendeskPlatformOperation, t as zendeskCustomOperation } from "./factory-ou1q975N.mjs";
|
|
3
3
|
import { n as createPlatformZendeskClient, t as createCustomZendeskClient } from "./shared-BmxcJmfq.mjs";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { zendeskBulkJobResponseSchema, zendeskTicketEnvelopeSchema, zendeskTicketListResponseSchema, zendeskTicketSchema } from "./schemas.mjs";
|
|
2
|
-
import { n as zendeskPlatformOperation, t as zendeskCustomOperation } from "./factory-
|
|
2
|
+
import { n as zendeskPlatformOperation, t as zendeskCustomOperation } from "./factory-ou1q975N.mjs";
|
|
3
3
|
import { n as createPlatformZendeskClient, t as createCustomZendeskClient } from "./shared-BmxcJmfq.mjs";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { z } from "zod";
|
|
2
1
|
import * as _keystrokehq_core0 from "@keystrokehq/core";
|
|
2
|
+
import { z } from "zod";
|
|
3
3
|
import * as _keystrokehq_core_credential_set0 from "@keystrokehq/core/credential-set";
|
|
4
4
|
|
|
5
5
|
//#region src/tickets.d.ts
|
|
@@ -29,7 +29,7 @@ declare const platformGetTicket: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
29
29
|
author_id: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
30
30
|
created_at: z.ZodOptional<z.ZodString>;
|
|
31
31
|
}, z.core.$strip>>;
|
|
32
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
32
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
33
33
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
34
34
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
35
35
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -62,7 +62,7 @@ declare const customGetTicket: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
62
62
|
author_id: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
63
63
|
created_at: z.ZodOptional<z.ZodString>;
|
|
64
64
|
}, z.core.$strip>>;
|
|
65
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
65
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
66
66
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
67
67
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
68
68
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -109,7 +109,7 @@ declare const platformListTickets: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
109
109
|
created_at: z.ZodOptional<z.ZodString>;
|
|
110
110
|
}, z.core.$strip>>;
|
|
111
111
|
}, z.core.$strip>>;
|
|
112
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
112
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
113
113
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
114
114
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
115
115
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -154,7 +154,7 @@ declare const customListTickets: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
154
154
|
created_at: z.ZodOptional<z.ZodString>;
|
|
155
155
|
}, z.core.$strip>>;
|
|
156
156
|
}, z.core.$strip>>;
|
|
157
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
157
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
158
158
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
159
159
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
160
160
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -200,7 +200,7 @@ declare const platformCreateTicket: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
200
200
|
author_id: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
201
201
|
created_at: z.ZodOptional<z.ZodString>;
|
|
202
202
|
}, z.core.$strip>>;
|
|
203
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
203
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
204
204
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
205
205
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
206
206
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -244,7 +244,7 @@ declare const customCreateTicket: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
244
244
|
author_id: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
245
245
|
created_at: z.ZodOptional<z.ZodString>;
|
|
246
246
|
}, z.core.$strip>>;
|
|
247
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
247
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
248
248
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
249
249
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
250
250
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -291,7 +291,7 @@ declare const platformUpdateTicket: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
291
291
|
author_id: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
292
292
|
created_at: z.ZodOptional<z.ZodString>;
|
|
293
293
|
}, z.core.$strip>>;
|
|
294
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
294
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
295
295
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
296
296
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
297
297
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -336,7 +336,7 @@ declare const customUpdateTicket: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
336
336
|
author_id: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
337
337
|
created_at: z.ZodOptional<z.ZodString>;
|
|
338
338
|
}, z.core.$strip>>;
|
|
339
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
339
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
340
340
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
341
341
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
342
342
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -349,7 +349,7 @@ declare const platformDeleteTicket: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
349
349
|
id: z.ZodNumber;
|
|
350
350
|
}, z.core.$strip>, z.ZodObject<{
|
|
351
351
|
success: z.ZodBoolean;
|
|
352
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
352
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
353
353
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
354
354
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
355
355
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -360,7 +360,7 @@ declare const customDeleteTicket: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
360
360
|
id: z.ZodNumber;
|
|
361
361
|
}, z.core.$strip>, z.ZodObject<{
|
|
362
362
|
success: z.ZodBoolean;
|
|
363
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
363
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
364
364
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
365
365
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
366
366
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -397,7 +397,7 @@ declare const platformReplyToTicket: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
397
397
|
author_id: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
398
398
|
created_at: z.ZodOptional<z.ZodString>;
|
|
399
399
|
}, z.core.$strip>>;
|
|
400
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
400
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
401
401
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
402
402
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
403
403
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -432,7 +432,7 @@ declare const customReplyToTicket: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
432
432
|
author_id: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
433
433
|
created_at: z.ZodOptional<z.ZodString>;
|
|
434
434
|
}, z.core.$strip>>;
|
|
435
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
435
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
436
436
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
437
437
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
438
438
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -466,7 +466,7 @@ declare const platformCreateManyTickets: _keystrokehq_core0.Operation<z.ZodObjec
|
|
|
466
466
|
url: z.ZodOptional<z.ZodString>;
|
|
467
467
|
results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
|
|
468
468
|
}, z.core.$strip>;
|
|
469
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
469
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
470
470
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
471
471
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
472
472
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -498,7 +498,7 @@ declare const customCreateManyTickets: _keystrokehq_core0.Operation<z.ZodObject<
|
|
|
498
498
|
url: z.ZodOptional<z.ZodString>;
|
|
499
499
|
results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
|
|
500
500
|
}, z.core.$strip>;
|
|
501
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
501
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
502
502
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
503
503
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
504
504
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -535,7 +535,7 @@ declare const platformUpdateManyTickets: _keystrokehq_core0.Operation<z.ZodObjec
|
|
|
535
535
|
url: z.ZodOptional<z.ZodString>;
|
|
536
536
|
results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
|
|
537
537
|
}, z.core.$strip>;
|
|
538
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
538
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
539
539
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
540
540
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
541
541
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -570,7 +570,7 @@ declare const customUpdateManyTickets: _keystrokehq_core0.Operation<z.ZodObject<
|
|
|
570
570
|
url: z.ZodOptional<z.ZodString>;
|
|
571
571
|
results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
|
|
572
572
|
}, z.core.$strip>;
|
|
573
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
573
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
574
574
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
575
575
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
576
576
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -596,7 +596,7 @@ declare const platformMergeTickets: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
596
596
|
url: z.ZodOptional<z.ZodString>;
|
|
597
597
|
results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
|
|
598
598
|
}, z.core.$strip>;
|
|
599
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
599
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
600
600
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
601
601
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
602
602
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -620,7 +620,7 @@ declare const customMergeTickets: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
620
620
|
url: z.ZodOptional<z.ZodString>;
|
|
621
621
|
results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
|
|
622
622
|
}, z.core.$strip>;
|
|
623
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
623
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
624
624
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
625
625
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
626
626
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import { o as zendeskPlatform, r as zendeskCustom } from "./integration-
|
|
1
|
+
import { o as zendeskPlatform, r as zendeskCustom } from "./integration-CdHa-pMh.mjs";
|
|
2
2
|
import { zendeskTicketListResponseSchema } from "./schemas.mjs";
|
|
3
3
|
import { ZendeskRecentTicketsEvent } from "./events.mjs";
|
|
4
|
+
import { BoundTrigger, Operation } from "@keystrokehq/core";
|
|
4
5
|
import { z } from "zod";
|
|
5
|
-
import { BoundTrigger } from "@keystrokehq/core";
|
|
6
|
-
import { IntegrationTriggerBindingOptions } from "@keystrokehq/integration-authoring";
|
|
7
|
-
import { AnyCredentialSet } from "@keystrokehq/core/credential-set";
|
|
8
6
|
import { PollingTriggerManifest } from "@keystrokehq/core/trigger";
|
|
7
|
+
import { AnyCredentialSet } from "@keystrokehq/core/credential-set";
|
|
9
8
|
|
|
10
9
|
//#region src/triggers.d.ts
|
|
11
10
|
type ZendeskPollingSchedule = number | `${number}s` | `${number}m` | `${number}h` | `${number}d` | `${number}w` | `${number}y`;
|
|
@@ -1,9 +1,59 @@
|
|
|
1
|
-
import { i as zendeskPlatform, t as zendeskCustom } from "./integration-
|
|
1
|
+
import { i as zendeskPlatform, t as zendeskCustom } from "./integration-DwdrlwuX.mjs";
|
|
2
2
|
import { zendeskTicketListResponseSchema } from "./schemas.mjs";
|
|
3
3
|
import { mapZendeskRecentTicketsEvent } from "./events.mjs";
|
|
4
4
|
import { n as createPlatformZendeskClient, t as createCustomZendeskClient } from "./shared-BmxcJmfq.mjs";
|
|
5
|
-
import {
|
|
5
|
+
import { Operation } from "@keystrokehq/core";
|
|
6
|
+
import { z } from "zod";
|
|
7
|
+
import { pollingTrigger } from "@keystrokehq/core/trigger";
|
|
6
8
|
|
|
9
|
+
//#region ../../packages/integration-authoring/dist/index.mjs
|
|
10
|
+
const IntegrationConfigSchema = z.object({
|
|
11
|
+
id: z.string().min(1),
|
|
12
|
+
name: z.string().min(1),
|
|
13
|
+
description: z.string().optional()
|
|
14
|
+
});
|
|
15
|
+
function resolveMetadata(metadata, defaults) {
|
|
16
|
+
return {
|
|
17
|
+
id: metadata?.id ?? defaults.defaultId,
|
|
18
|
+
description: metadata?.description ?? defaults.defaultDescription
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
function resolveAuthorPayload(payload, mapPayload) {
|
|
22
|
+
if (!mapPayload) return payload;
|
|
23
|
+
return mapPayload(payload);
|
|
24
|
+
}
|
|
25
|
+
function createIntegrationTriggerBindingFactory(config) {
|
|
26
|
+
const bind = (options) => {
|
|
27
|
+
const resolvedMetadata = resolveMetadata(options, config);
|
|
28
|
+
const baseTrigger = config.createBaseTrigger(resolvedMetadata);
|
|
29
|
+
const userTransform = options?.transform;
|
|
30
|
+
return baseTrigger({ transform: userTransform || config.mapPayload ? (runtimePayload, request) => {
|
|
31
|
+
const authorPayload = resolveAuthorPayload(runtimePayload, config.mapPayload);
|
|
32
|
+
if (authorPayload === null) throw new Error(`Trigger "${resolvedMetadata.id}" mapPayload returned null after the trigger filter passed; tighten the trigger filter schema.`);
|
|
33
|
+
if (!userTransform) return authorPayload;
|
|
34
|
+
return userTransform(authorPayload, request);
|
|
35
|
+
} : void 0 });
|
|
36
|
+
};
|
|
37
|
+
return Object.freeze(bind);
|
|
38
|
+
}
|
|
39
|
+
function createPollingTriggerBindingFactory(config) {
|
|
40
|
+
return createIntegrationTriggerBindingFactory({
|
|
41
|
+
defaultId: config.defaultId,
|
|
42
|
+
defaultDescription: config.defaultDescription,
|
|
43
|
+
mapPayload: config.mapPayload,
|
|
44
|
+
createBaseTrigger: (metadata) => pollingTrigger({
|
|
45
|
+
id: metadata.id,
|
|
46
|
+
description: metadata.description,
|
|
47
|
+
schedule: config.schedule,
|
|
48
|
+
response: config.response,
|
|
49
|
+
poll: config.poll,
|
|
50
|
+
...config.credentialSets ? { credentialSets: config.credentialSets } : {},
|
|
51
|
+
...config.filter ? { filter: config.filter } : {}
|
|
52
|
+
})
|
|
53
|
+
});
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
//#endregion
|
|
7
57
|
//#region src/triggers.ts
|
|
8
58
|
function buildPlatformRecentTicketsBind(options) {
|
|
9
59
|
return createPollingTriggerBindingFactory({
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { zendeskBulkJobResponseSchema, zendeskUserEnvelopeSchema, zendeskUserListResponseSchema, zendeskUserSchema } from "./schemas.mjs";
|
|
2
|
-
import { n as zendeskPlatformOperation, t as zendeskCustomOperation } from "./factory-
|
|
2
|
+
import { n as zendeskPlatformOperation, t as zendeskCustomOperation } from "./factory-ou1q975N.mjs";
|
|
3
3
|
import { n as createPlatformZendeskClient, t as createCustomZendeskClient } from "./shared-BmxcJmfq.mjs";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { z } from "zod";
|
|
2
1
|
import * as _keystrokehq_core0 from "@keystrokehq/core";
|
|
2
|
+
import { z } from "zod";
|
|
3
3
|
import * as _keystrokehq_core_credential_set0 from "@keystrokehq/core/credential-set";
|
|
4
4
|
|
|
5
5
|
//#region src/users.d.ts
|
|
@@ -21,7 +21,7 @@ declare const platformListUsers: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
21
21
|
created_at: z.ZodOptional<z.ZodString>;
|
|
22
22
|
updated_at: z.ZodOptional<z.ZodString>;
|
|
23
23
|
}, z.core.$strip>>;
|
|
24
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
24
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
25
25
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
26
26
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
27
27
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -46,7 +46,7 @@ declare const customListUsers: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
46
46
|
created_at: z.ZodOptional<z.ZodString>;
|
|
47
47
|
updated_at: z.ZodOptional<z.ZodString>;
|
|
48
48
|
}, z.core.$strip>>;
|
|
49
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
49
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
50
50
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
51
51
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
52
52
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -66,7 +66,7 @@ declare const platformGetUser: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
66
66
|
organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
|
|
67
67
|
created_at: z.ZodOptional<z.ZodString>;
|
|
68
68
|
updated_at: z.ZodOptional<z.ZodString>;
|
|
69
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
69
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
70
70
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
71
71
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
72
72
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -84,7 +84,7 @@ declare const customGetUser: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
84
84
|
organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
|
|
85
85
|
created_at: z.ZodOptional<z.ZodString>;
|
|
86
86
|
updated_at: z.ZodOptional<z.ZodString>;
|
|
87
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
87
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
88
88
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
89
89
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
90
90
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -102,7 +102,7 @@ declare const platformGetCurrentUser: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
102
102
|
organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
|
|
103
103
|
created_at: z.ZodOptional<z.ZodString>;
|
|
104
104
|
updated_at: z.ZodOptional<z.ZodString>;
|
|
105
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
105
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
106
106
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
107
107
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
108
108
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -118,7 +118,7 @@ declare const customGetCurrentUser: _keystrokehq_core0.Operation<z.ZodObject<{},
|
|
|
118
118
|
organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
|
|
119
119
|
created_at: z.ZodOptional<z.ZodString>;
|
|
120
120
|
updated_at: z.ZodOptional<z.ZodString>;
|
|
121
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
121
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
122
122
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
123
123
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
124
124
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -143,7 +143,7 @@ declare const platformSearchUsers: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
143
143
|
created_at: z.ZodOptional<z.ZodString>;
|
|
144
144
|
updated_at: z.ZodOptional<z.ZodString>;
|
|
145
145
|
}, z.core.$strip>>;
|
|
146
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
146
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
147
147
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
148
148
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
149
149
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -166,7 +166,7 @@ declare const customSearchUsers: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
166
166
|
created_at: z.ZodOptional<z.ZodString>;
|
|
167
167
|
updated_at: z.ZodOptional<z.ZodString>;
|
|
168
168
|
}, z.core.$strip>>;
|
|
169
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
169
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
170
170
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
171
171
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
172
172
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -192,7 +192,7 @@ declare const platformCreateUser: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
192
192
|
organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
|
|
193
193
|
created_at: z.ZodOptional<z.ZodString>;
|
|
194
194
|
updated_at: z.ZodOptional<z.ZodString>;
|
|
195
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
195
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
196
196
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
197
197
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
198
198
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -216,7 +216,7 @@ declare const customCreateUser: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
216
216
|
organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
|
|
217
217
|
created_at: z.ZodOptional<z.ZodString>;
|
|
218
218
|
updated_at: z.ZodOptional<z.ZodString>;
|
|
219
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
219
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
220
220
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
221
221
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
222
222
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -244,7 +244,7 @@ declare const platformUpdateUser: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
244
244
|
organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
|
|
245
245
|
created_at: z.ZodOptional<z.ZodString>;
|
|
246
246
|
updated_at: z.ZodOptional<z.ZodString>;
|
|
247
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
247
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
248
248
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
249
249
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
250
250
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -270,7 +270,7 @@ declare const customUpdateUser: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
270
270
|
organization_id: z.ZodOptional<z.ZodNullable<z.ZodCoercedNumber<unknown>>>;
|
|
271
271
|
created_at: z.ZodOptional<z.ZodString>;
|
|
272
272
|
updated_at: z.ZodOptional<z.ZodString>;
|
|
273
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
273
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
274
274
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
275
275
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
276
276
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -283,7 +283,7 @@ declare const platformDeleteUser: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
283
283
|
id: z.ZodNumber;
|
|
284
284
|
}, z.core.$strip>, z.ZodObject<{
|
|
285
285
|
success: z.ZodBoolean;
|
|
286
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
286
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
287
287
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
288
288
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
289
289
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -294,7 +294,7 @@ declare const customDeleteUser: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
294
294
|
id: z.ZodNumber;
|
|
295
295
|
}, z.core.$strip>, z.ZodObject<{
|
|
296
296
|
success: z.ZodBoolean;
|
|
297
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
297
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
298
298
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
299
299
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
300
300
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -323,7 +323,7 @@ declare const platformCreateManyUsers: _keystrokehq_core0.Operation<z.ZodObject<
|
|
|
323
323
|
url: z.ZodOptional<z.ZodString>;
|
|
324
324
|
results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
|
|
325
325
|
}, z.core.$strip>;
|
|
326
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
326
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
327
327
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
328
328
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
329
329
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -350,7 +350,7 @@ declare const customCreateManyUsers: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
350
350
|
url: z.ZodOptional<z.ZodString>;
|
|
351
351
|
results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
|
|
352
352
|
}, z.core.$strip>;
|
|
353
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
353
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
354
354
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
355
355
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
356
356
|
ZENDESK_API_TOKEN: z.ZodString;
|
|
@@ -381,7 +381,7 @@ declare const platformUpdateManyUsers: _keystrokehq_core0.Operation<z.ZodObject<
|
|
|
381
381
|
url: z.ZodOptional<z.ZodString>;
|
|
382
382
|
results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
|
|
383
383
|
}, z.core.$strip>;
|
|
384
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
384
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.platform-oauth", z.ZodObject<{
|
|
385
385
|
ZENDESK_ACCESS_TOKEN: z.ZodString;
|
|
386
386
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
387
387
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
@@ -410,7 +410,7 @@ declare const customUpdateManyUsers: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
410
410
|
url: z.ZodOptional<z.ZodString>;
|
|
411
411
|
results: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>>;
|
|
412
412
|
}, z.core.$strip>;
|
|
413
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
413
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"zendesk.custom-token", z.ZodObject<{
|
|
414
414
|
ZENDESK_SUBDOMAIN: z.ZodString;
|
|
415
415
|
ZENDESK_EMAIL: z.ZodEmail;
|
|
416
416
|
ZENDESK_API_TOKEN: z.ZodString;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@keystrokehq/zendesk",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.9",
|
|
4
4
|
"private": false,
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"type": "module",
|
|
@@ -132,7 +132,6 @@
|
|
|
132
132
|
"LICENSE"
|
|
133
133
|
],
|
|
134
134
|
"dependencies": {
|
|
135
|
-
"@keystrokehq/integration-authoring": "^0.0.8",
|
|
136
135
|
"zod": "^4.3.6"
|
|
137
136
|
},
|
|
138
137
|
"peerDependencies": {
|
|
@@ -143,7 +142,8 @@
|
|
|
143
142
|
"tsdown": "^0.20.3",
|
|
144
143
|
"typescript": "^5.9.3",
|
|
145
144
|
"vitest": "^4.0.18",
|
|
146
|
-
"@keystrokehq/core": "^0.0.
|
|
145
|
+
"@keystrokehq/core": "^0.0.12",
|
|
146
|
+
"@keystrokehq/integration-authoring": "0.0.9",
|
|
147
147
|
"@keystrokehq/test-utils": "0.0.0",
|
|
148
148
|
"@keystrokehq/typescript-config": "0.0.0"
|
|
149
149
|
},
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
import { defineOfficialIntegration, officialCredentialSetId } from "@keystrokehq/integration-authoring/official";
|
|
2
|
-
import { z } from "zod";
|
|
3
|
-
import { CredentialSet } from "@keystrokehq/core";
|
|
4
|
-
|
|
5
|
-
//#region src/_official/provider-app.ts
|
|
6
|
-
const zendeskPlatformAppCredentialSet = new CredentialSet({
|
|
7
|
-
id: officialCredentialSetId("zendesk-platform-app"),
|
|
8
|
-
exposure: "platform-only",
|
|
9
|
-
name: "Zendesk Platform App",
|
|
10
|
-
auth: z.object({
|
|
11
|
-
clientId: z.string().min(1),
|
|
12
|
-
clientSecret: z.string().min(1),
|
|
13
|
-
webhookSigningSecret: z.string().min(1)
|
|
14
|
-
})
|
|
15
|
-
});
|
|
16
|
-
const zendeskOfficialProviderSeed = {
|
|
17
|
-
provider: "zendesk",
|
|
18
|
-
appRef: "zendesk-platform",
|
|
19
|
-
displayName: "Zendesk Platform",
|
|
20
|
-
credentialSetName: "Keystroke Zendesk Platform App",
|
|
21
|
-
envShape: {
|
|
22
|
-
KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_ID: z.string().optional(),
|
|
23
|
-
KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_SECRET: z.string().optional(),
|
|
24
|
-
KEYSTROKE_OFFICIAL_ZENDESK_WEBHOOK_SIGNING_SECRET: z.string().optional()
|
|
25
|
-
},
|
|
26
|
-
requiredEnvKeys: [
|
|
27
|
-
"KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_ID",
|
|
28
|
-
"KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_SECRET",
|
|
29
|
-
"KEYSTROKE_OFFICIAL_ZENDESK_WEBHOOK_SIGNING_SECRET"
|
|
30
|
-
],
|
|
31
|
-
externalAppIdEnvKey: "KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_ID",
|
|
32
|
-
buildCredentials: (env) => ({
|
|
33
|
-
clientId: env.KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_ID,
|
|
34
|
-
clientSecret: env.KEYSTROKE_OFFICIAL_ZENDESK_CLIENT_SECRET,
|
|
35
|
-
webhookSigningSecret: env.KEYSTROKE_OFFICIAL_ZENDESK_WEBHOOK_SIGNING_SECRET
|
|
36
|
-
})
|
|
37
|
-
};
|
|
38
|
-
|
|
39
|
-
//#endregion
|
|
40
|
-
//#region src/integration.ts
|
|
41
|
-
const zendeskSubdomainSchema = z.string().trim().min(1).regex(/^[a-zA-Z0-9-]+$/, { error: "Zendesk subdomain must contain only letters, numbers, and hyphens" });
|
|
42
|
-
const zendeskPlatformAuthSchema = z.object({
|
|
43
|
-
ZENDESK_ACCESS_TOKEN: z.string().min(1),
|
|
44
|
-
ZENDESK_SUBDOMAIN: zendeskSubdomainSchema
|
|
45
|
-
});
|
|
46
|
-
const zendeskCustomAuthSchema = z.object({
|
|
47
|
-
ZENDESK_SUBDOMAIN: zendeskSubdomainSchema,
|
|
48
|
-
ZENDESK_EMAIL: z.email(),
|
|
49
|
-
ZENDESK_API_TOKEN: z.string().min(1)
|
|
50
|
-
});
|
|
51
|
-
const zendeskPlatformOfficialIntegration = {
|
|
52
|
-
id: "zendesk-platform",
|
|
53
|
-
publicId: "zendesk",
|
|
54
|
-
name: "Zendesk Platform",
|
|
55
|
-
description: "Zendesk Support integration via Keystroke-managed OAuth for tickets, users, organizations, search, and triggers",
|
|
56
|
-
auth: zendeskPlatformAuthSchema,
|
|
57
|
-
connections: [{
|
|
58
|
-
id: "oauth",
|
|
59
|
-
kind: "oauth",
|
|
60
|
-
tokenType: "refreshable",
|
|
61
|
-
authUrl: "https://{subdomain}.zendesk.com/oauth/authorizations/new",
|
|
62
|
-
tokenUrl: "https://{subdomain}.zendesk.com/oauth/tokens",
|
|
63
|
-
revokeUrl: "https://{subdomain}.zendesk.com/api/v2/oauth/tokens/current",
|
|
64
|
-
scopes: ["read", "write"],
|
|
65
|
-
vault: { accessToken: "ZENDESK_ACCESS_TOKEN" }
|
|
66
|
-
}]
|
|
67
|
-
};
|
|
68
|
-
const zendeskCustomOfficialIntegration = {
|
|
69
|
-
id: "zendesk-custom",
|
|
70
|
-
name: "Zendesk Custom",
|
|
71
|
-
description: "Zendesk Support integration via bring-your-own API token for tickets, users, organizations, and search",
|
|
72
|
-
auth: zendeskCustomAuthSchema
|
|
73
|
-
};
|
|
74
|
-
const zendeskPlatformBundle = defineOfficialIntegration({
|
|
75
|
-
...zendeskPlatformOfficialIntegration,
|
|
76
|
-
internal: { providerApp: zendeskPlatformAppCredentialSet }
|
|
77
|
-
});
|
|
78
|
-
const zendeskCustomBundle = defineOfficialIntegration(zendeskCustomOfficialIntegration);
|
|
79
|
-
const zendeskPlatform = zendeskPlatformBundle.credentialSet;
|
|
80
|
-
const zendeskCustom = zendeskCustomBundle.credentialSet;
|
|
81
|
-
|
|
82
|
-
//#endregion
|
|
83
|
-
export { zendeskPlatformBundle as a, zendeskPlatformAppCredentialSet as c, zendeskPlatform as i, zendeskCustomBundle as n, zendeskPlatformOfficialIntegration as o, zendeskCustomOfficialIntegration as r, zendeskOfficialProviderSeed as s, zendeskCustom as t };
|