@keystrokehq/sendgrid 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.
Files changed (49) hide show
  1. package/dist/_official/index.d.mts +1 -1
  2. package/dist/_official/index.mjs +1 -1
  3. package/dist/alerts.d.mts +6 -6
  4. package/dist/alerts.mjs +2 -2
  5. package/dist/api-keys.d.mts +7 -7
  6. package/dist/api-keys.mjs +2 -2
  7. package/dist/client.d.mts +1 -1
  8. package/dist/client.mjs +2 -3
  9. package/dist/connection.d.mts +1 -1
  10. package/dist/connection.mjs +1 -1
  11. package/dist/domains.d.mts +4 -4
  12. package/dist/domains.mjs +2 -2
  13. package/dist/email-validation.d.mts +6 -6
  14. package/dist/email-validation.mjs +2 -2
  15. package/dist/{factory-BSL0D2L0.mjs → factory-CToXR1jp.mjs} +1 -2
  16. package/dist/integration-C9EALG65.mjs +113 -0
  17. package/dist/{integration-DpbPKcSF.d.mts → integration-zx-jmybs.d.mts} +3 -4
  18. package/dist/mail-send.d.mts +9 -9
  19. package/dist/mail-send.mjs +2 -2
  20. package/dist/marketing-contacts.d.mts +17 -17
  21. package/dist/marketing-contacts.mjs +2 -2
  22. package/dist/marketing-customfields.d.mts +4 -4
  23. package/dist/marketing-customfields.mjs +1 -1
  24. package/dist/marketing-lists.d.mts +8 -8
  25. package/dist/marketing-lists.mjs +2 -2
  26. package/dist/marketing-segments.d.mts +11 -11
  27. package/dist/marketing-segments.mjs +2 -2
  28. package/dist/marketing-singlesends.d.mts +17 -17
  29. package/dist/marketing-singlesends.mjs +2 -2
  30. package/dist/sender-identities.d.mts +7 -7
  31. package/dist/sender-identities.mjs +1 -1
  32. package/dist/senders.d.mts +6 -6
  33. package/dist/senders.mjs +1 -1
  34. package/dist/shared-BayZ0Lt6.mjs +46 -0
  35. package/dist/stats.d.mts +6 -6
  36. package/dist/stats.mjs +2 -2
  37. package/dist/suppressions.d.mts +32 -32
  38. package/dist/suppressions.mjs +2 -2
  39. package/dist/templates.d.mts +12 -12
  40. package/dist/templates.mjs +2 -2
  41. package/dist/user-account.d.mts +5 -5
  42. package/dist/user-account.mjs +1 -1
  43. package/dist/webhooks/event.d.mts +9 -9
  44. package/dist/webhooks/event.mjs +2 -2
  45. package/dist/webhooks/parse.d.mts +7 -7
  46. package/dist/webhooks/parse.mjs +2 -2
  47. package/package.json +4 -4
  48. package/dist/integration-37BovSeK.mjs +0 -23
  49. package/dist/shared-CQ8JFNXi.mjs +0 -13
@@ -1,2 +1,2 @@
1
- import { i as sendgridOfficialIntegration, r as sendgridBundle } from "../integration-DpbPKcSF.mjs";
1
+ import { i as sendgridOfficialIntegration, r as sendgridBundle } from "../integration-zx-jmybs.mjs";
2
2
  export { sendgridBundle, sendgridOfficialIntegration };
@@ -1,3 +1,3 @@
1
- import { n as sendgridBundle, r as sendgridOfficialIntegration } from "../integration-37BovSeK.mjs";
1
+ import { n as sendgridBundle, r as sendgridOfficialIntegration } from "../integration-C9EALG65.mjs";
2
2
 
3
3
  export { sendgridBundle, sendgridOfficialIntegration };
package/dist/alerts.d.mts CHANGED
@@ -1,6 +1,6 @@
1
+ import * as _keystrokehq_core0 from "@keystrokehq/core";
1
2
  import { z } from "zod";
2
3
  import * as _keystrokehq_core_credential_set0 from "@keystrokehq/core/credential-set";
3
- import * as _keystrokehq_core0 from "@keystrokehq/core";
4
4
 
5
5
  //#region src/alerts.d.ts
6
6
  declare const createAlert: _keystrokehq_core0.Operation<z.ZodObject<{
@@ -30,7 +30,7 @@ declare const createAlert: _keystrokehq_core0.Operation<z.ZodObject<{
30
30
  percentage: z.ZodOptional<z.ZodNumber>;
31
31
  created_at: z.ZodOptional<z.ZodNumber>;
32
32
  updated_at: z.ZodOptional<z.ZodNumber>;
33
- }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
33
+ }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
34
34
  SENDGRID_API_KEY: z.ZodString;
35
35
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
36
36
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -77,7 +77,7 @@ declare const updateAlert: _keystrokehq_core0.Operation<z.ZodObject<{
77
77
  percentage: z.ZodOptional<z.ZodNumber>;
78
78
  created_at: z.ZodOptional<z.ZodNumber>;
79
79
  updated_at: z.ZodOptional<z.ZodNumber>;
80
- }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
80
+ }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
81
81
  SENDGRID_API_KEY: z.ZodString;
82
82
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
83
83
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -100,7 +100,7 @@ declare const deleteAlert: _keystrokehq_core0.Operation<z.ZodObject<{
100
100
  alertId: z.ZodNumber;
101
101
  }, z.core.$strip>, z.ZodObject<{
102
102
  success: z.ZodBoolean;
103
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
103
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
104
104
  SENDGRID_API_KEY: z.ZodString;
105
105
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
106
106
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -136,7 +136,7 @@ declare const getAlert: _keystrokehq_core0.Operation<z.ZodObject<{
136
136
  percentage: z.ZodOptional<z.ZodNumber>;
137
137
  created_at: z.ZodOptional<z.ZodNumber>;
138
138
  updated_at: z.ZodOptional<z.ZodNumber>;
139
- }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
139
+ }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
140
140
  SENDGRID_API_KEY: z.ZodString;
141
141
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
142
142
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -170,7 +170,7 @@ declare const listAlerts: _keystrokehq_core0.Operation<z.ZodOptional<z.ZodObject
170
170
  percentage: z.ZodOptional<z.ZodNumber>;
171
171
  created_at: z.ZodOptional<z.ZodNumber>;
172
172
  updated_at: z.ZodOptional<z.ZodNumber>;
173
- }, z.core.$catchall<z.ZodUnknown>>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
173
+ }, z.core.$catchall<z.ZodUnknown>>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
174
174
  SENDGRID_API_KEY: z.ZodString;
175
175
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
176
176
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
package/dist/alerts.mjs CHANGED
@@ -1,5 +1,5 @@
1
- import { n as __exportAll, t as sendgridOperation } from "./factory-BSL0D2L0.mjs";
2
- import { n as omitUndefined } from "./shared-CQ8JFNXi.mjs";
1
+ import { n as __exportAll, t as sendgridOperation } from "./factory-CToXR1jp.mjs";
2
+ import { n as omitUndefined } from "./shared-BayZ0Lt6.mjs";
3
3
  import { createSendGridClient } from "./client.mjs";
4
4
  import { $t as sendgridAlertFrequencySchema, en as sendgridAlertListSchema, in as sendgridEmailSchema, nn as sendgridAlertTypeSchema, tn as sendgridAlertSchema } from "./webhooks-CKdsIikb.mjs";
5
5
  import { z } from "zod";
@@ -1,6 +1,6 @@
1
+ import * as _keystrokehq_core0 from "@keystrokehq/core";
1
2
  import { z } from "zod";
2
3
  import * as _keystrokehq_core_credential_set0 from "@keystrokehq/core/credential-set";
3
- import * as _keystrokehq_core0 from "@keystrokehq/core";
4
4
 
5
5
  //#region src/api-keys.d.ts
6
6
  declare const createApiKey: _keystrokehq_core0.Operation<z.ZodObject<{
@@ -11,7 +11,7 @@ declare const createApiKey: _keystrokehq_core0.Operation<z.ZodObject<{
11
11
  name: z.ZodString;
12
12
  scopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
13
13
  api_key: z.ZodOptional<z.ZodString>;
14
- }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
14
+ }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
15
15
  SENDGRID_API_KEY: z.ZodString;
16
16
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
17
17
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -36,7 +36,7 @@ declare const listApiKeys: _keystrokehq_core0.Operation<z.ZodOptional<z.ZodObjec
36
36
  name: z.ZodString;
37
37
  scopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
38
38
  }, z.core.$catchall<z.ZodUnknown>>>;
39
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
39
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
40
40
  SENDGRID_API_KEY: z.ZodString;
41
41
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
42
42
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -61,7 +61,7 @@ declare const getApiKey: _keystrokehq_core0.Operation<z.ZodObject<{
61
61
  api_key_id: z.ZodString;
62
62
  name: z.ZodString;
63
63
  scopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
64
- }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
64
+ }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
65
65
  SENDGRID_API_KEY: z.ZodString;
66
66
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
67
67
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -87,7 +87,7 @@ declare const updateApiKeyName: _keystrokehq_core0.Operation<z.ZodObject<{
87
87
  api_key_id: z.ZodString;
88
88
  name: z.ZodString;
89
89
  scopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
90
- }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
90
+ }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
91
91
  SENDGRID_API_KEY: z.ZodString;
92
92
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
93
93
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -114,7 +114,7 @@ declare const updateApiKeyNameAndScopes: _keystrokehq_core0.Operation<z.ZodObjec
114
114
  api_key_id: z.ZodString;
115
115
  name: z.ZodString;
116
116
  scopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
117
- }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
117
+ }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
118
118
  SENDGRID_API_KEY: z.ZodString;
119
119
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
120
120
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -137,7 +137,7 @@ declare const deleteApiKey: _keystrokehq_core0.Operation<z.ZodObject<{
137
137
  apiKeyId: z.ZodString;
138
138
  }, z.core.$strip>, z.ZodObject<{
139
139
  success: z.ZodBoolean;
140
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
140
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
141
141
  SENDGRID_API_KEY: z.ZodString;
142
142
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
143
143
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
package/dist/api-keys.mjs CHANGED
@@ -1,5 +1,5 @@
1
- import { n as __exportAll, t as sendgridOperation } from "./factory-BSL0D2L0.mjs";
2
- import { n as omitUndefined } from "./shared-CQ8JFNXi.mjs";
1
+ import { n as __exportAll, t as sendgridOperation } from "./factory-CToXR1jp.mjs";
2
+ import { n as omitUndefined } from "./shared-BayZ0Lt6.mjs";
3
3
  import { createSendGridClient } from "./client.mjs";
4
4
  import { Qt as sendgridApiKeyWithKeySchema, Xt as sendgridApiKeySchema, Yt as sendgridApiKeyListSchema, on as sendgridIdSchema } from "./webhooks-CKdsIikb.mjs";
5
5
  import { z } from "zod";
package/dist/client.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import { t as SendGridCredentials } from "./integration-DpbPKcSF.mjs";
1
+ import { t as SendGridCredentials } from "./integration-zx-jmybs.mjs";
2
2
 
3
3
  //#region src/client.d.ts
4
4
  type Primitive = string | number | boolean;
package/dist/client.mjs CHANGED
@@ -1,7 +1,6 @@
1
- import { t as sendgrid } from "./integration-37BovSeK.mjs";
2
- import { r as stringIfPresent, t as asRecord } from "./shared-CQ8JFNXi.mjs";
1
+ import { t as sendgrid } from "./integration-C9EALG65.mjs";
2
+ import { i as createErrorNormalizingProxy, r as stringIfPresent, t as asRecord } from "./shared-BayZ0Lt6.mjs";
3
3
  import { CredentialRevokedError } from "@keystrokehq/core/errors";
4
- import { createErrorNormalizingProxy } from "@keystrokehq/integration-authoring";
5
4
 
6
5
  //#region src/client.ts
7
6
  const SENDGRID_GLOBAL_BASE = "https://api.sendgrid.com/v3";
@@ -1,2 +1,2 @@
1
- import { i as sendgridOfficialIntegration, n as sendgrid, t as SendGridCredentials } from "./integration-DpbPKcSF.mjs";
1
+ import { i as sendgridOfficialIntegration, n as sendgrid, t as SendGridCredentials } from "./integration-zx-jmybs.mjs";
2
2
  export { type SendGridCredentials, sendgrid, sendgridOfficialIntegration };
@@ -1,3 +1,3 @@
1
- import { r as sendgridOfficialIntegration, t as sendgrid } from "./integration-37BovSeK.mjs";
1
+ import { r as sendgridOfficialIntegration, t as sendgrid } from "./integration-C9EALG65.mjs";
2
2
 
3
3
  export { sendgrid, sendgridOfficialIntegration };
@@ -1,6 +1,6 @@
1
+ import * as _keystrokehq_core0 from "@keystrokehq/core";
1
2
  import { z } from "zod";
2
3
  import * as _keystrokehq_core_credential_set0 from "@keystrokehq/core/credential-set";
3
- import * as _keystrokehq_core0 from "@keystrokehq/core";
4
4
 
5
5
  //#region src/domains.d.ts
6
6
  declare const listAuthenticatedDomains: _keystrokehq_core0.Operation<z.ZodOptional<z.ZodObject<{
@@ -27,7 +27,7 @@ declare const listAuthenticatedDomains: _keystrokehq_core0.Operation<z.ZodOption
27
27
  host: z.ZodOptional<z.ZodString>;
28
28
  data: z.ZodOptional<z.ZodString>;
29
29
  }, z.core.$catchall<z.ZodUnknown>>>>;
30
- }, z.core.$catchall<z.ZodUnknown>>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
30
+ }, z.core.$catchall<z.ZodUnknown>>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
31
31
  SENDGRID_API_KEY: z.ZodString;
32
32
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
33
33
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -66,7 +66,7 @@ declare const getAuthenticatedDomain: _keystrokehq_core0.Operation<z.ZodObject<{
66
66
  host: z.ZodOptional<z.ZodString>;
67
67
  data: z.ZodOptional<z.ZodString>;
68
68
  }, z.core.$catchall<z.ZodUnknown>>>>;
69
- }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
69
+ }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
70
70
  SENDGRID_API_KEY: z.ZodString;
71
71
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
72
72
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -91,7 +91,7 @@ declare const validateAuthenticatedDomain: _keystrokehq_core0.Operation<z.ZodObj
91
91
  id: z.ZodNumber;
92
92
  valid: z.ZodBoolean;
93
93
  validation_results: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
94
- }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
94
+ }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
95
95
  SENDGRID_API_KEY: z.ZodString;
96
96
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
97
97
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
package/dist/domains.mjs CHANGED
@@ -1,5 +1,5 @@
1
- import { n as __exportAll, t as sendgridOperation } from "./factory-BSL0D2L0.mjs";
2
- import { n as omitUndefined } from "./shared-CQ8JFNXi.mjs";
1
+ import { n as __exportAll, t as sendgridOperation } from "./factory-CToXR1jp.mjs";
2
+ import { n as omitUndefined } from "./shared-BayZ0Lt6.mjs";
3
3
  import { createSendGridClient } from "./client.mjs";
4
4
  import { At as sendgridAuthenticatedDomainListSchema, Nt as sendgridDomainValidateResultSchema, jt as sendgridAuthenticatedDomainSchema } from "./webhooks-CKdsIikb.mjs";
5
5
  import { z } from "zod";
@@ -1,6 +1,6 @@
1
+ import * as _keystrokehq_core0 from "@keystrokehq/core";
1
2
  import { z } from "zod";
2
3
  import * as _keystrokehq_core_credential_set0 from "@keystrokehq/core/credential-set";
3
- import * as _keystrokehq_core0 from "@keystrokehq/core";
4
4
 
5
5
  //#region src/email-validation.d.ts
6
6
  declare const validateEmail: _keystrokehq_core0.Operation<z.ZodObject<{
@@ -22,7 +22,7 @@ declare const validateEmail: _keystrokehq_core0.Operation<z.ZodObject<{
22
22
  source: z.ZodOptional<z.ZodString>;
23
23
  ip_address: z.ZodOptional<z.ZodString>;
24
24
  }, z.core.$catchall<z.ZodUnknown>>;
25
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
25
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
26
26
  SENDGRID_API_KEY: z.ZodString;
27
27
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
28
28
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -51,7 +51,7 @@ declare const listBulkEmailValidationJobs: _keystrokehq_core0.Operation<z.ZodOpt
51
51
  finished_at: z.ZodOptional<z.ZodString>;
52
52
  submitted_at: z.ZodOptional<z.ZodString>;
53
53
  }, z.core.$catchall<z.ZodUnknown>>>;
54
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
54
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
55
55
  SENDGRID_API_KEY: z.ZodString;
56
56
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
57
57
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -80,7 +80,7 @@ declare const getBulkEmailValidationJob: _keystrokehq_core0.Operation<z.ZodObjec
80
80
  started_at: z.ZodOptional<z.ZodString>;
81
81
  finished_at: z.ZodOptional<z.ZodString>;
82
82
  submitted_at: z.ZodOptional<z.ZodString>;
83
- }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
83
+ }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
84
84
  SENDGRID_API_KEY: z.ZodString;
85
85
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
86
86
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -101,8 +101,8 @@ declare const getBulkEmailValidationJob: _keystrokehq_core0.Operation<z.ZodObjec
101
101
  }, z.core.$strip>>[] | undefined>], undefined>;
102
102
  declare const createBulkEmailValidationPresignedUrl: _keystrokehq_core0.Operation<z.ZodObject<{
103
103
  fileType: z.ZodDefault<z.ZodEnum<{
104
- csv: "csv";
105
104
  zip: "zip";
105
+ csv: "csv";
106
106
  }>>;
107
107
  }, z.core.$strip>, z.ZodObject<{
108
108
  job_id: z.ZodString;
@@ -111,7 +111,7 @@ declare const createBulkEmailValidationPresignedUrl: _keystrokehq_core0.Operatio
111
111
  header: z.ZodString;
112
112
  value: z.ZodString;
113
113
  }, z.core.$strip>>;
114
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
114
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
115
115
  SENDGRID_API_KEY: z.ZodString;
116
116
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
117
117
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -1,5 +1,5 @@
1
- import { n as __exportAll, t as sendgridOperation } from "./factory-BSL0D2L0.mjs";
2
- import { n as omitUndefined } from "./shared-CQ8JFNXi.mjs";
1
+ import { n as __exportAll, t as sendgridOperation } from "./factory-CToXR1jp.mjs";
2
+ import { n as omitUndefined } from "./shared-BayZ0Lt6.mjs";
3
3
  import { createSendGridClient } from "./client.mjs";
4
4
  import { Dt as sendgridEmailValidationResponseSchema, Et as sendgridBulkEmailValidationPresignedUrlSchema, Tt as sendgridBulkEmailValidationJobSchema, in as sendgridEmailSchema, on as sendgridIdSchema, wt as sendgridBulkEmailValidationJobListSchema } from "./webhooks-CKdsIikb.mjs";
5
5
  import { z } from "zod";
@@ -1,5 +1,4 @@
1
- import { t as sendgrid } from "./integration-37BovSeK.mjs";
2
- import { createOfficialOperationFactory } from "@keystrokehq/integration-authoring/official";
1
+ import { i as createOfficialOperationFactory, t as sendgrid } from "./integration-C9EALG65.mjs";
3
2
 
4
3
  //#region \0rolldown/runtime.js
5
4
  var __defProp = Object.defineProperty;
@@ -0,0 +1,113 @@
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 stripOfficialCredentialSetIdPrefix(id) {
19
+ return id.startsWith(OFFICIAL_CREDENTIAL_SET_ID_PREFIX) ? id.slice(10) : id;
20
+ }
21
+ /**
22
+ * Creates a factory for Keystroke-official integration operations.
23
+ *
24
+ * It keeps the same flat `run(input, credentials)` ergonomics as the generic
25
+ * operation factory, while registering official metadata for builder/runtime
26
+ * operation metadata.
27
+ */
28
+ function createOfficialOperationFactory(credentialSet) {
29
+ const integrationId = stripOfficialCredentialSetIdPrefix(credentialSet.id);
30
+ return (config) => {
31
+ const wrappedRun = async (input, ctx) => {
32
+ const creds = ctx.credentials[credentialSet.id];
33
+ return config.run(input, creds);
34
+ };
35
+ const operation = new Operation({
36
+ id: config.id,
37
+ name: config.name,
38
+ description: config.description,
39
+ input: config.input,
40
+ output: config.output,
41
+ credentialSets: [credentialSet],
42
+ ...config.tags !== void 0 ? { tags: config.tags } : {},
43
+ ...config.needsApproval !== void 0 ? { needsApproval: config.needsApproval } : {},
44
+ ...config.requiredOAuthScopes !== void 0 ? { requiredOAuthScopes: config.requiredOAuthScopes } : {},
45
+ ...config.retries !== void 0 ? { retries: config.retries } : {},
46
+ ...config.timeout !== void 0 ? { timeout: config.timeout } : {},
47
+ ...config.maxDurationMs !== void 0 ? { maxDurationMs: config.maxDurationMs } : {},
48
+ run: wrappedRun
49
+ });
50
+ registerOfficialOperation(operation, { integrationId });
51
+ return operation;
52
+ };
53
+ }
54
+ /**
55
+ * Creates an official integration bundle from a single config object.
56
+ *
57
+ * - Creates the public `CredentialSet` internally.
58
+ * - Accepts optional `internal` fields for Keystroke-owned platform credentials.
59
+ */
60
+ function defineOfficialIntegration(config) {
61
+ const internalCredentialSets = config.internal ?? {};
62
+ const allInternalCredentialSets = [
63
+ ...internalCredentialSets.providerApp ? [internalCredentialSets.providerApp] : [],
64
+ ...internalCredentialSets.providerAppVariants ?? [],
65
+ ...internalCredentialSets.webhookVerification ? [internalCredentialSets.webhookVerification] : [],
66
+ ...internalCredentialSets.other ?? []
67
+ ];
68
+ const credentialSet = new CredentialSet({
69
+ id: config.id,
70
+ name: config.name,
71
+ description: config.description,
72
+ auth: config.auth,
73
+ ...config.connections ? { connections: config.connections } : {},
74
+ ...config.proxy ? { proxy: config.proxy } : {},
75
+ ...config.needsRawSecret === true ? { needsRawSecret: true } : {}
76
+ });
77
+ return Object.freeze({
78
+ integration: {
79
+ id: config.id,
80
+ name: config.name,
81
+ ...config.description !== void 0 ? { description: config.description } : {},
82
+ auth: config.auth,
83
+ ...config.proxy ? { proxy: config.proxy } : {},
84
+ ...config.needsRawSecret === true ? { needsRawSecret: true } : {},
85
+ ...config.connections ? { connections: config.connections } : {}
86
+ },
87
+ credentialSet,
88
+ internalCredentialSets,
89
+ allInternalCredentialSets
90
+ });
91
+ }
92
+
93
+ //#endregion
94
+ //#region src/integration.ts
95
+ const sendgridAuthSchema = z.object({
96
+ SENDGRID_API_KEY: z.string().min(1).regex(/^SG\./u, "SendGrid API keys start with \"SG.\""),
97
+ SENDGRID_SUBUSER: z.string().min(1).optional(),
98
+ SENDGRID_ACCOUNT_REGION: z.enum(["global", "eu"]).default("global"),
99
+ SENDGRID_EVENT_WEBHOOK_PUBLIC_KEY: z.string().min(1).optional(),
100
+ SENDGRID_INBOUND_PARSE_TOKEN: z.string().min(1).optional()
101
+ });
102
+ const sendgridOfficialIntegration = {
103
+ id: "sendgrid",
104
+ name: "SendGrid",
105
+ description: "SendGrid (Twilio) transactional + marketing email, templates, contacts, lists, segments, deliverability, and webhook helpers for Keystroke workflows",
106
+ auth: sendgridAuthSchema,
107
+ proxy: { hosts: ["api.sendgrid.com", "api.eu.sendgrid.com"] }
108
+ };
109
+ const sendgridBundle = defineOfficialIntegration(sendgridOfficialIntegration);
110
+ const sendgrid = sendgridBundle.credentialSet;
111
+
112
+ //#endregion
113
+ export { createOfficialOperationFactory as i, sendgridBundle as n, sendgridOfficialIntegration as r, sendgrid as t };
@@ -1,8 +1,7 @@
1
- import * as _keystrokehq_integration_authoring_official0 from "@keystrokehq/integration-authoring/official";
1
+ import * as _keystrokehq_core0 from "@keystrokehq/core";
2
2
  import { z } from "zod";
3
3
  import * as _keystrokehq_core_credential_set0 from "@keystrokehq/core/credential-set";
4
4
  import { InferCredentialSetAuth } from "@keystrokehq/core/credential-set";
5
- import * as _keystrokehq_core0 from "@keystrokehq/core";
6
5
 
7
6
  //#region src/integration.d.ts
8
7
  declare const sendgridOfficialIntegration: {
@@ -23,7 +22,7 @@ declare const sendgridOfficialIntegration: {
23
22
  hosts: string[];
24
23
  };
25
24
  };
26
- declare const sendgridBundle: _keystrokehq_integration_authoring_official0.OfficialIntegrationBundle<"sendgrid", z.ZodObject<{
25
+ declare const sendgridBundle: undefined<"sendgrid", z.ZodObject<{
27
26
  SENDGRID_API_KEY: z.ZodString;
28
27
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
29
28
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -33,7 +32,7 @@ declare const sendgridBundle: _keystrokehq_integration_authoring_official0.Offic
33
32
  SENDGRID_EVENT_WEBHOOK_PUBLIC_KEY: z.ZodOptional<z.ZodString>;
34
33
  SENDGRID_INBOUND_PARSE_TOKEN: z.ZodOptional<z.ZodString>;
35
34
  }, z.core.$strip>>;
36
- declare const sendgrid: _keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
35
+ declare const sendgrid: _keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
37
36
  SENDGRID_API_KEY: z.ZodString;
38
37
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
39
38
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -1,6 +1,6 @@
1
+ import * as _keystrokehq_core0 from "@keystrokehq/core";
1
2
  import { z } from "zod";
2
3
  import * as _keystrokehq_core_credential_set0 from "@keystrokehq/core/credential-set";
3
- import * as _keystrokehq_core0 from "@keystrokehq/core";
4
4
 
5
5
  //#region src/mail-send.d.ts
6
6
  declare const sendEmail: _keystrokehq_core0.Operation<z.ZodObject<{
@@ -115,7 +115,7 @@ declare const sendEmail: _keystrokehq_core0.Operation<z.ZodObject<{
115
115
  }, z.core.$strip>, z.ZodObject<{
116
116
  messageId: z.ZodOptional<z.ZodString>;
117
117
  accepted: z.ZodBoolean;
118
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
118
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
119
119
  SENDGRID_API_KEY: z.ZodString;
120
120
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
121
121
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -136,7 +136,7 @@ declare const sendEmail: _keystrokehq_core0.Operation<z.ZodObject<{
136
136
  }, z.core.$strip>>[] | undefined>], undefined>;
137
137
  declare const createBatchId: _keystrokehq_core0.Operation<z.ZodOptional<z.ZodObject<{}, z.core.$strip>>, z.ZodObject<{
138
138
  batch_id: z.ZodString;
139
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
139
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
140
140
  SENDGRID_API_KEY: z.ZodString;
141
141
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
142
142
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -159,7 +159,7 @@ declare const validateBatchId: _keystrokehq_core0.Operation<z.ZodObject<{
159
159
  batchId: z.ZodString;
160
160
  }, z.core.$strip>, z.ZodObject<{
161
161
  batch_id: z.ZodString;
162
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
162
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
163
163
  SENDGRID_API_KEY: z.ZodString;
164
164
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
165
165
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -190,7 +190,7 @@ declare const cancelOrPauseScheduledSend: _keystrokehq_core0.Operation<z.ZodObje
190
190
  cancel: "cancel";
191
191
  pause: "pause";
192
192
  }>>;
193
- }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
193
+ }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
194
194
  SENDGRID_API_KEY: z.ZodString;
195
195
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
196
196
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -217,7 +217,7 @@ declare const updateScheduledSend: _keystrokehq_core0.Operation<z.ZodObject<{
217
217
  }>;
218
218
  }, z.core.$strip>, z.ZodObject<{
219
219
  success: z.ZodBoolean;
220
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
220
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
221
221
  SENDGRID_API_KEY: z.ZodString;
222
222
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
223
223
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -240,7 +240,7 @@ declare const deleteScheduledSend: _keystrokehq_core0.Operation<z.ZodObject<{
240
240
  batchId: z.ZodString;
241
241
  }, z.core.$strip>, z.ZodObject<{
242
242
  success: z.ZodBoolean;
243
- }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
243
+ }, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
244
244
  SENDGRID_API_KEY: z.ZodString;
245
245
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
246
246
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -265,7 +265,7 @@ declare const listScheduledSends: _keystrokehq_core0.Operation<z.ZodOptional<z.Z
265
265
  cancel: "cancel";
266
266
  pause: "pause";
267
267
  }>>;
268
- }, z.core.$catchall<z.ZodUnknown>>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
268
+ }, z.core.$catchall<z.ZodUnknown>>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
269
269
  SENDGRID_API_KEY: z.ZodString;
270
270
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
271
271
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -292,7 +292,7 @@ declare const getScheduledSend: _keystrokehq_core0.Operation<z.ZodObject<{
292
292
  cancel: "cancel";
293
293
  pause: "pause";
294
294
  }>>;
295
- }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:sendgrid", z.ZodObject<{
295
+ }, z.core.$catchall<z.ZodUnknown>>, readonly [_keystrokehq_core0.CredentialSet<"sendgrid", z.ZodObject<{
296
296
  SENDGRID_API_KEY: z.ZodString;
297
297
  SENDGRID_SUBUSER: z.ZodOptional<z.ZodString>;
298
298
  SENDGRID_ACCOUNT_REGION: z.ZodDefault<z.ZodEnum<{
@@ -1,5 +1,5 @@
1
- import { n as __exportAll, t as sendgridOperation } from "./factory-BSL0D2L0.mjs";
2
- import { n as omitUndefined } from "./shared-CQ8JFNXi.mjs";
1
+ import { n as __exportAll, t as sendgridOperation } from "./factory-CToXR1jp.mjs";
2
+ import { n as omitUndefined } from "./shared-BayZ0Lt6.mjs";
3
3
  import { createSendGridClient } from "./client.mjs";
4
4
  import { _t as sendgridScheduledSendSchema, ft as sendgridMailSendInputSchema, gt as sendgridScheduledSendListSchema, lt as sendgridBatchIdSchema, on as sendgridIdSchema, pt as sendgridMailSendResultSchema, vt as sendgridScheduledSendStatusSchema } from "./webhooks-CKdsIikb.mjs";
5
5
  import { z } from "zod";