@keystrokehq/notion 0.0.1 → 0.0.4
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/LICENSE +21 -0
- package/dist/_official/index.d.mts +38 -2
- package/dist/_official/index.mjs +1 -1
- package/dist/_runtime/index.d.mts +24 -24
- package/dist/blocks.d.mts +5 -5
- package/dist/blocks.mjs +1 -1
- package/dist/client.d.mts +1 -1
- package/dist/client.mjs +1 -1
- package/dist/comments.d.mts +3 -3
- package/dist/comments.mjs +1 -1
- package/dist/connection.d.mts +1 -1
- package/dist/connection.mjs +1 -1
- package/dist/data-sources.d.mts +5 -5
- package/dist/data-sources.mjs +1 -1
- package/dist/{factory-BttZ5eEq.mjs → factory-ClakehEF.mjs} +1 -1
- package/dist/{integration-C7pL009K.d.mts → integration-D12eY2r0.d.mts} +1 -1
- package/dist/{integration-Hfdp-q_v.mjs → integration-q-rO2FMC.mjs} +3 -3
- package/dist/pages.d.mts +7 -7
- package/dist/pages.mjs +1 -1
- package/dist/search.d.mts +1 -1
- package/dist/search.mjs +1 -1
- package/dist/triggers.d.mts +5 -29
- package/dist/triggers.mjs +20 -133
- package/dist/users.d.mts +3 -3
- package/dist/users.mjs +1 -1
- package/package.json +19 -20
- package/dist/provider-app-DehoD5sd.d.mts +0 -38
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Buster
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -1,3 +1,39 @@
|
|
|
1
|
-
import { r as notionBundle } from "../integration-
|
|
2
|
-
import {
|
|
1
|
+
import { r as notionBundle } from "../integration-D12eY2r0.mjs";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
import { CredentialSet } from "@keystrokehq/core";
|
|
4
|
+
import * as _keystrokehq_core_credential_set0 from "@keystrokehq/core/credential-set";
|
|
5
|
+
import { InferCredentialSetAuth } from "@keystrokehq/core/credential-set";
|
|
6
|
+
|
|
7
|
+
//#region src/_official/provider-app.d.ts
|
|
8
|
+
declare const notionAppCredentialSet: CredentialSet<"keystroke:notion-app", z.ZodObject<{
|
|
9
|
+
clientId: z.ZodString;
|
|
10
|
+
clientSecret: z.ZodString;
|
|
11
|
+
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
12
|
+
clientId: z.ZodString;
|
|
13
|
+
clientSecret: z.ZodString;
|
|
14
|
+
}, z.core.$strip>>[] | undefined>;
|
|
15
|
+
declare const notionPlatformProviderSeed: {
|
|
16
|
+
readonly provider: "notion";
|
|
17
|
+
readonly appRef: "notion-platform";
|
|
18
|
+
readonly displayName: "Notion Platform";
|
|
19
|
+
readonly credentialSetName: "Keystroke Notion Platform App";
|
|
20
|
+
readonly envShape: {
|
|
21
|
+
readonly KEYSTROKE_PLATFORM_NOTION_CLIENT_ID: z.ZodOptional<z.ZodString>;
|
|
22
|
+
readonly KEYSTROKE_PLATFORM_NOTION_CLIENT_SECRET: z.ZodOptional<z.ZodString>;
|
|
23
|
+
};
|
|
24
|
+
readonly requiredEnvKeys: readonly ["KEYSTROKE_PLATFORM_NOTION_CLIENT_ID", "KEYSTROKE_PLATFORM_NOTION_CLIENT_SECRET"];
|
|
25
|
+
readonly externalAppIdEnvKey: "KEYSTROKE_PLATFORM_NOTION_CLIENT_ID";
|
|
26
|
+
readonly buildCredentials: (env: Record<string, string | undefined>) => {
|
|
27
|
+
clientId: string | undefined;
|
|
28
|
+
clientSecret: string | undefined;
|
|
29
|
+
};
|
|
30
|
+
};
|
|
31
|
+
type NotionAppCredentials = InferCredentialSetAuth<typeof notionAppCredentialSet>;
|
|
32
|
+
declare const notionWebhookCredentialSet: CredentialSet<"keystroke:notion-webhook", z.ZodObject<{
|
|
33
|
+
verificationToken: z.ZodString;
|
|
34
|
+
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
35
|
+
verificationToken: z.ZodString;
|
|
36
|
+
}, z.core.$strip>>[] | undefined>;
|
|
37
|
+
type NotionWebhookCredentials = InferCredentialSetAuth<typeof notionWebhookCredentialSet>;
|
|
38
|
+
//#endregion
|
|
3
39
|
export { NotionAppCredentials, NotionWebhookCredentials, notionAppCredentialSet, notionBundle, notionPlatformProviderSeed, notionWebhookCredentialSet };
|
package/dist/_official/index.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { a as notionPlatformProviderSeed, i as notionAppCredentialSet, n as notionBundle, o as notionWebhookCredentialSet } from "../integration-
|
|
1
|
+
import { a as notionPlatformProviderSeed, i as notionAppCredentialSet, n as notionBundle, o as notionWebhookCredentialSet } from "../integration-q-rO2FMC.mjs";
|
|
2
2
|
|
|
3
3
|
export { notionAppCredentialSet, notionBundle, notionPlatformProviderSeed, notionWebhookCredentialSet };
|
|
@@ -25,7 +25,7 @@ declare const notionOperations: {
|
|
|
25
25
|
workspace: zod.ZodOptional<zod.ZodBoolean>;
|
|
26
26
|
}, zod_v4_core0.$strip>>;
|
|
27
27
|
properties: zod.ZodRecord<zod.ZodString, zod.ZodUnknown>;
|
|
28
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
28
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
29
29
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
30
30
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
31
31
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -57,7 +57,7 @@ declare const notionOperations: {
|
|
|
57
57
|
workspace: zod.ZodOptional<zod.ZodBoolean>;
|
|
58
58
|
}, zod_v4_core0.$strip>>;
|
|
59
59
|
properties: zod.ZodRecord<zod.ZodString, zod.ZodUnknown>;
|
|
60
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
60
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
61
61
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
62
62
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
63
63
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -67,7 +67,7 @@ declare const notionOperations: {
|
|
|
67
67
|
targetPageId: zod.ZodString;
|
|
68
68
|
}, zod_v4_core0.$strip>, zod.ZodObject<{
|
|
69
69
|
success: zod.ZodLiteral<true>;
|
|
70
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
70
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
71
71
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
72
72
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
73
73
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -97,7 +97,7 @@ declare const notionOperations: {
|
|
|
97
97
|
workspace: zod.ZodOptional<zod.ZodBoolean>;
|
|
98
98
|
}, zod_v4_core0.$strip>>;
|
|
99
99
|
properties: zod.ZodRecord<zod.ZodString, zod.ZodUnknown>;
|
|
100
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
100
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
101
101
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
102
102
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
103
103
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -122,7 +122,7 @@ declare const notionOperations: {
|
|
|
122
122
|
workspace: zod.ZodOptional<zod.ZodBoolean>;
|
|
123
123
|
}, zod_v4_core0.$strip>>;
|
|
124
124
|
properties: zod.ZodRecord<zod.ZodString, zod.ZodUnknown>;
|
|
125
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
125
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
126
126
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
127
127
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
128
128
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -147,7 +147,7 @@ declare const notionOperations: {
|
|
|
147
147
|
workspace: zod.ZodOptional<zod.ZodBoolean>;
|
|
148
148
|
}, zod_v4_core0.$strip>>;
|
|
149
149
|
properties: zod.ZodRecord<zod.ZodString, zod.ZodUnknown>;
|
|
150
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
150
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
151
151
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
152
152
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
153
153
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -164,7 +164,7 @@ declare const notionOperations: {
|
|
|
164
164
|
value: zod.ZodUnknown;
|
|
165
165
|
nextCursor: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
166
166
|
hasMore: zod.ZodOptional<zod.ZodBoolean>;
|
|
167
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
167
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
168
168
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
169
169
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
170
170
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -189,7 +189,7 @@ declare const notionOperations: {
|
|
|
189
189
|
workspace: zod.ZodOptional<zod.ZodBoolean>;
|
|
190
190
|
}, zod_v4_core0.$strip>>;
|
|
191
191
|
value: zod.ZodOptional<zod.ZodUnknown>;
|
|
192
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
192
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
193
193
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
194
194
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
195
195
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -221,7 +221,7 @@ declare const notionOperations: {
|
|
|
221
221
|
}, zod_v4_core0.$strip>>;
|
|
222
222
|
hasMore: zod.ZodBoolean;
|
|
223
223
|
nextCursor: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
224
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
224
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
225
225
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
226
226
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
227
227
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -231,7 +231,7 @@ declare const notionOperations: {
|
|
|
231
231
|
children: zod.ZodArray<zod.ZodRecord<zod.ZodString, zod.ZodUnknown>>;
|
|
232
232
|
}, zod_v4_core0.$strip>, zod.ZodObject<{
|
|
233
233
|
success: zod.ZodLiteral<true>;
|
|
234
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
234
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
235
235
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
236
236
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
237
237
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -257,7 +257,7 @@ declare const notionOperations: {
|
|
|
257
257
|
workspace: zod.ZodOptional<zod.ZodBoolean>;
|
|
258
258
|
}, zod_v4_core0.$strip>>;
|
|
259
259
|
value: zod.ZodOptional<zod.ZodUnknown>;
|
|
260
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
260
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
261
261
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
262
262
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
263
263
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -282,7 +282,7 @@ declare const notionOperations: {
|
|
|
282
282
|
workspace: zod.ZodOptional<zod.ZodBoolean>;
|
|
283
283
|
}, zod_v4_core0.$strip>>;
|
|
284
284
|
value: zod.ZodOptional<zod.ZodUnknown>;
|
|
285
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
285
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
286
286
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
287
287
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
288
288
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -295,7 +295,7 @@ declare const notionOperations: {
|
|
|
295
295
|
id: zod.ZodString;
|
|
296
296
|
name: zod.ZodString;
|
|
297
297
|
}, zod_v4_core0.$strip>>;
|
|
298
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
298
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
299
299
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
300
300
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
301
301
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -318,7 +318,7 @@ declare const notionOperations: {
|
|
|
318
318
|
workspace: zod.ZodOptional<zod.ZodBoolean>;
|
|
319
319
|
}, zod_v4_core0.$strip>>;
|
|
320
320
|
properties: zod.ZodRecord<zod.ZodString, zod.ZodUnknown>;
|
|
321
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
321
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
322
322
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
323
323
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
324
324
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -351,7 +351,7 @@ declare const notionOperations: {
|
|
|
351
351
|
}, zod_v4_core0.$strip>>;
|
|
352
352
|
hasMore: zod.ZodBoolean;
|
|
353
353
|
nextCursor: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
354
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
354
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
355
355
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
356
356
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
357
357
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -378,7 +378,7 @@ declare const notionOperations: {
|
|
|
378
378
|
workspace: zod.ZodOptional<zod.ZodBoolean>;
|
|
379
379
|
}, zod_v4_core0.$strip>>;
|
|
380
380
|
properties: zod.ZodRecord<zod.ZodString, zod.ZodUnknown>;
|
|
381
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
381
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
382
382
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
383
383
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
384
384
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -405,7 +405,7 @@ declare const notionOperations: {
|
|
|
405
405
|
workspace: zod.ZodOptional<zod.ZodBoolean>;
|
|
406
406
|
}, zod_v4_core0.$strip>>;
|
|
407
407
|
properties: zod.ZodRecord<zod.ZodString, zod.ZodUnknown>;
|
|
408
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
408
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
409
409
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
410
410
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
411
411
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -441,7 +441,7 @@ declare const notionOperations: {
|
|
|
441
441
|
}, zod_v4_core0.$strip>>;
|
|
442
442
|
hasMore: zod.ZodBoolean;
|
|
443
443
|
nextCursor: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
444
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
444
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
445
445
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
446
446
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
447
447
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -471,7 +471,7 @@ declare const notionOperations: {
|
|
|
471
471
|
avatarUrl: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
472
472
|
email: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
473
473
|
}, zod_v4_core0.$strip>>;
|
|
474
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
474
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
475
475
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
476
476
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
477
477
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -507,7 +507,7 @@ declare const notionOperations: {
|
|
|
507
507
|
avatarUrl: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
508
508
|
email: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
509
509
|
}, zod_v4_core0.$strip>>;
|
|
510
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
510
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
511
511
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
512
512
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
513
513
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -519,7 +519,7 @@ declare const notionOperations: {
|
|
|
519
519
|
name: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
520
520
|
avatarUrl: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
521
521
|
email: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
522
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
522
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
523
523
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
524
524
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
525
525
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -533,7 +533,7 @@ declare const notionOperations: {
|
|
|
533
533
|
name: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
534
534
|
avatarUrl: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
535
535
|
email: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
536
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
536
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
537
537
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
538
538
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
539
539
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -552,7 +552,7 @@ declare const notionOperations: {
|
|
|
552
552
|
}, zod_v4_core0.$strip>>;
|
|
553
553
|
hasMore: zod.ZodBoolean;
|
|
554
554
|
nextCursor: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
555
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
555
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
556
556
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
557
557
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
558
558
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
@@ -590,7 +590,7 @@ declare const notionOperations: {
|
|
|
590
590
|
}, zod_v4_core0.$strip>>;
|
|
591
591
|
hasMore: zod.ZodBoolean;
|
|
592
592
|
nextCursor: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
|
|
593
|
-
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", zod.ZodObject<{
|
|
593
|
+
}, zod_v4_core0.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", zod.ZodObject<{
|
|
594
594
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
|
595
595
|
}, zod_v4_core0.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<zod.ZodObject<{
|
|
596
596
|
NOTION_ACCESS_TOKEN: zod.ZodString;
|
package/dist/blocks.d.mts
CHANGED
|
@@ -23,7 +23,7 @@ declare const getBlock: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
23
23
|
workspace: z.ZodOptional<z.ZodBoolean>;
|
|
24
24
|
}, z.core.$strip>>;
|
|
25
25
|
value: z.ZodOptional<z.ZodUnknown>;
|
|
26
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
26
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
27
27
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
28
28
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
29
29
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -55,7 +55,7 @@ declare const listBlockChildren: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
55
55
|
}, z.core.$strip>>;
|
|
56
56
|
hasMore: z.ZodBoolean;
|
|
57
57
|
nextCursor: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
58
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
58
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
59
59
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
60
60
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
61
61
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -65,7 +65,7 @@ declare const appendBlockChildren: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
65
65
|
children: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
66
66
|
}, z.core.$strip>, z.ZodObject<{
|
|
67
67
|
success: z.ZodLiteral<true>;
|
|
68
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
68
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
69
69
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
70
70
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
71
71
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -91,7 +91,7 @@ declare const updateBlock: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
91
91
|
workspace: z.ZodOptional<z.ZodBoolean>;
|
|
92
92
|
}, z.core.$strip>>;
|
|
93
93
|
value: z.ZodOptional<z.ZodUnknown>;
|
|
94
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
94
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
95
95
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
96
96
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
97
97
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -116,7 +116,7 @@ declare const deleteBlock: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
116
116
|
workspace: z.ZodOptional<z.ZodBoolean>;
|
|
117
117
|
}, z.core.$strip>>;
|
|
118
118
|
value: z.ZodOptional<z.ZodUnknown>;
|
|
119
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
119
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
120
120
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
121
121
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
122
122
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
package/dist/blocks.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { appendBlockChildrenInChunks, createNotionClient, listAllPaginatedResults, withRateLimitRetry } from "./client.mjs";
|
|
2
2
|
import { normalizeBlock, normalizeListMeta, notionBlockSchema, notionListResponseSchema, notionSuccessResponseSchema } from "./schemas.mjs";
|
|
3
|
-
import { t as notionOperation } from "./factory-
|
|
3
|
+
import { t as notionOperation } from "./factory-ClakehEF.mjs";
|
|
4
4
|
import { r as buildPaginationInput } from "./shared-C6A6JPl3.mjs";
|
|
5
5
|
import { z } from "zod";
|
|
6
6
|
|
package/dist/client.d.mts
CHANGED
package/dist/client.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as notion } from "./integration-
|
|
1
|
+
import { t as notion } from "./integration-q-rO2FMC.mjs";
|
|
2
2
|
import { CredentialRevokedError } from "@keystrokehq/core/errors";
|
|
3
3
|
import { createErrorNormalizingProxy } from "@keystrokehq/integration-authoring";
|
|
4
4
|
import { Client } from "@notionhq/client";
|
package/dist/comments.d.mts
CHANGED
|
@@ -34,7 +34,7 @@ declare const listComments: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
34
34
|
}, z.core.$strip>>;
|
|
35
35
|
hasMore: z.ZodBoolean;
|
|
36
36
|
nextCursor: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
37
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
37
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
38
38
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
39
39
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
40
40
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -64,7 +64,7 @@ declare const getComment: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
64
64
|
avatarUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
65
65
|
email: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
66
66
|
}, z.core.$strip>>;
|
|
67
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
67
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
68
68
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
69
69
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
70
70
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -100,7 +100,7 @@ declare const createComment: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
100
100
|
avatarUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
101
101
|
email: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
102
102
|
}, z.core.$strip>>;
|
|
103
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
103
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
104
104
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
105
105
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
106
106
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
package/dist/comments.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createNotionClient, withRateLimitRetry } from "./client.mjs";
|
|
2
2
|
import { normalizeComment, normalizeListMeta, notionCommentSchema, notionListResponseSchema } from "./schemas.mjs";
|
|
3
|
-
import { t as notionOperation } from "./factory-
|
|
3
|
+
import { t as notionOperation } from "./factory-ClakehEF.mjs";
|
|
4
4
|
import { i as buildPlainTextRichText, r as buildPaginationInput, t as buildCommentTarget } from "./shared-C6A6JPl3.mjs";
|
|
5
5
|
import { z } from "zod";
|
|
6
6
|
|
package/dist/connection.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { i as notionOfficialIntegration, n as notion, t as NotionCredentials } from "./integration-
|
|
1
|
+
import { i as notionOfficialIntegration, n as notion, t as NotionCredentials } from "./integration-D12eY2r0.mjs";
|
|
2
2
|
export { type NotionCredentials, notion, notionOfficialIntegration };
|
package/dist/connection.mjs
CHANGED
package/dist/data-sources.d.mts
CHANGED
|
@@ -11,7 +11,7 @@ declare const discoverDatabaseDataSources: _keystrokehq_core0.Operation<z.ZodObj
|
|
|
11
11
|
id: z.ZodString;
|
|
12
12
|
name: z.ZodString;
|
|
13
13
|
}, z.core.$strip>>;
|
|
14
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
14
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
15
15
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
16
16
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
17
17
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -34,7 +34,7 @@ declare const getDataSource: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
34
34
|
workspace: z.ZodOptional<z.ZodBoolean>;
|
|
35
35
|
}, z.core.$strip>>;
|
|
36
36
|
properties: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
37
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
37
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
38
38
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
39
39
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
40
40
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -67,7 +67,7 @@ declare const queryDataSource: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
67
67
|
}, z.core.$strip>>;
|
|
68
68
|
hasMore: z.ZodBoolean;
|
|
69
69
|
nextCursor: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
70
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
70
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
71
71
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
72
72
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
73
73
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -94,7 +94,7 @@ declare const createDataSourceEntry: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
94
94
|
workspace: z.ZodOptional<z.ZodBoolean>;
|
|
95
95
|
}, z.core.$strip>>;
|
|
96
96
|
properties: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
97
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
97
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
98
98
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
99
99
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
100
100
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -121,7 +121,7 @@ declare const updateDataSourceEntry: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
121
121
|
workspace: z.ZodOptional<z.ZodBoolean>;
|
|
122
122
|
}, z.core.$strip>>;
|
|
123
123
|
properties: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
124
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
124
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
125
125
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
126
126
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
127
127
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
package/dist/data-sources.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createNotionClient, withRateLimitRetry } from "./client.mjs";
|
|
2
2
|
import { normalizeDataSource, normalizeListMeta, normalizePage, notionDataSourceSchema, notionListResponseSchema, notionPageSchema } from "./schemas.mjs";
|
|
3
|
-
import { t as notionOperation } from "./factory-
|
|
3
|
+
import { t as notionOperation } from "./factory-ClakehEF.mjs";
|
|
4
4
|
import { r as buildPaginationInput } from "./shared-C6A6JPl3.mjs";
|
|
5
5
|
import { z } from "zod";
|
|
6
6
|
|
|
@@ -46,7 +46,7 @@ declare const notionOfficialIntegration: {
|
|
|
46
46
|
declare const notionBundle: _keystrokehq_integration_authoring_official0.OfficialIntegrationBundle<"notion", z.ZodObject<{
|
|
47
47
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
48
48
|
}, z.core.$strip>>;
|
|
49
|
-
declare const notion: _keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
49
|
+
declare const notion: _keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
50
50
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
51
51
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
52
52
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { defineOfficialIntegration } from "@keystrokehq/integration-authoring/official";
|
|
1
|
+
import { defineOfficialIntegration, officialCredentialSetId } from "@keystrokehq/integration-authoring/official";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
import { CredentialSet } from "@keystrokehq/core";
|
|
4
4
|
import { oauthDefaults, oauthPresets, pipe } from "@keystrokehq/credential-connection";
|
|
5
5
|
|
|
6
6
|
//#region src/_official/provider-app.ts
|
|
7
7
|
const notionAppCredentialSet = new CredentialSet({
|
|
8
|
-
id: "notion-app",
|
|
8
|
+
id: officialCredentialSetId("notion-app"),
|
|
9
9
|
exposure: "platform-only",
|
|
10
10
|
name: "Notion App",
|
|
11
11
|
auth: z.object({
|
|
@@ -30,7 +30,7 @@ const notionPlatformProviderSeed = {
|
|
|
30
30
|
})
|
|
31
31
|
};
|
|
32
32
|
const notionWebhookCredentialSet = new CredentialSet({
|
|
33
|
-
id: "notion-webhook",
|
|
33
|
+
id: officialCredentialSetId("notion-webhook"),
|
|
34
34
|
exposure: "platform-only",
|
|
35
35
|
name: "Notion Webhook",
|
|
36
36
|
auth: z.object({ verificationToken: z.string().min(1) })
|
package/dist/pages.d.mts
CHANGED
|
@@ -23,7 +23,7 @@ declare const getPage: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
23
23
|
workspace: z.ZodOptional<z.ZodBoolean>;
|
|
24
24
|
}, z.core.$strip>>;
|
|
25
25
|
properties: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
26
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
26
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
27
27
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
28
28
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
29
29
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -55,7 +55,7 @@ declare const createPage: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
55
55
|
workspace: z.ZodOptional<z.ZodBoolean>;
|
|
56
56
|
}, z.core.$strip>>;
|
|
57
57
|
properties: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
58
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
58
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
59
59
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
60
60
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
61
61
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -85,7 +85,7 @@ declare const updatePage: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
85
85
|
workspace: z.ZodOptional<z.ZodBoolean>;
|
|
86
86
|
}, z.core.$strip>>;
|
|
87
87
|
properties: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
88
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
88
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
89
89
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
90
90
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
91
91
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -95,7 +95,7 @@ declare const copyPageContent: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
95
95
|
targetPageId: z.ZodString;
|
|
96
96
|
}, z.core.$strip>, z.ZodObject<{
|
|
97
97
|
success: z.ZodLiteral<true>;
|
|
98
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
98
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
99
99
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
100
100
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
101
101
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -120,7 +120,7 @@ declare const trashPage: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
120
120
|
workspace: z.ZodOptional<z.ZodBoolean>;
|
|
121
121
|
}, z.core.$strip>>;
|
|
122
122
|
properties: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
123
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
123
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
124
124
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
125
125
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
126
126
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -137,7 +137,7 @@ declare const getPageProperty: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
137
137
|
value: z.ZodUnknown;
|
|
138
138
|
nextCursor: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
139
139
|
hasMore: z.ZodOptional<z.ZodBoolean>;
|
|
140
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
140
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
141
141
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
142
142
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
143
143
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -162,7 +162,7 @@ declare const restorePage: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
162
162
|
workspace: z.ZodOptional<z.ZodBoolean>;
|
|
163
163
|
}, z.core.$strip>>;
|
|
164
164
|
properties: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
165
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
165
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
166
166
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
167
167
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
168
168
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
package/dist/pages.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { NOTION_MAX_BLOCK_CHILDREN_PER_REQUEST, appendBlockChildrenAndReturnResults, chunkArray, createNotionClient, listAllPaginatedResults, withRateLimitRetry } from "./client.mjs";
|
|
2
2
|
import { normalizePage, normalizePagePropertyItem, notionPagePropertyItemSchema, notionPageSchema, notionSuccessResponseSchema } from "./schemas.mjs";
|
|
3
|
-
import { t as notionOperation } from "./factory-
|
|
3
|
+
import { t as notionOperation } from "./factory-ClakehEF.mjs";
|
|
4
4
|
import { i as buildPlainTextRichText, n as buildPageParent, r as buildPaginationInput } from "./shared-C6A6JPl3.mjs";
|
|
5
5
|
import { z } from "zod";
|
|
6
6
|
|
package/dist/search.d.mts
CHANGED
|
@@ -36,7 +36,7 @@ declare const searchWorkspace: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
36
36
|
}, z.core.$strip>>;
|
|
37
37
|
hasMore: z.ZodBoolean;
|
|
38
38
|
nextCursor: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
39
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
39
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
40
40
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
41
41
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
42
42
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
package/dist/search.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createNotionClient, withRateLimitRetry } from "./client.mjs";
|
|
2
2
|
import { normalizeListMeta, normalizeSearchResult, notionListResponseSchema, notionSearchResultSchema } from "./schemas.mjs";
|
|
3
|
-
import { t as notionOperation } from "./factory-
|
|
3
|
+
import { t as notionOperation } from "./factory-ClakehEF.mjs";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
|
|
6
6
|
//#region src/search.ts
|
package/dist/triggers.d.mts
CHANGED
|
@@ -1,10 +1,8 @@
|
|
|
1
|
-
import { n as notion } from "./integration-
|
|
2
|
-
import { a as notionWebhookCredentialSet } from "./provider-app-DehoD5sd.mjs";
|
|
3
|
-
import { NotionWebhookEvent, NotionWebhookPayload } from "./events.mjs";
|
|
1
|
+
import { n as notion } from "./integration-D12eY2r0.mjs";
|
|
4
2
|
import { z } from "zod";
|
|
5
|
-
import { BoundTrigger
|
|
6
|
-
import {
|
|
7
|
-
import { PollingTriggerManifest
|
|
3
|
+
import { BoundTrigger } from "@keystrokehq/core";
|
|
4
|
+
import { IntegrationTriggerBindingOptions } from "@keystrokehq/integration-authoring";
|
|
5
|
+
import { PollingTriggerManifest } from "@keystrokehq/core/trigger";
|
|
8
6
|
|
|
9
7
|
//#region src/triggers.d.ts
|
|
10
8
|
declare const notionPollingBatchSchema: z.ZodObject<{
|
|
@@ -21,9 +19,7 @@ declare const notionPollingBatchSchema: z.ZodObject<{
|
|
|
21
19
|
nextCursor: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
22
20
|
}, z.core.$strip>;
|
|
23
21
|
type NotionPollingBatch = z.output<typeof notionPollingBatchSchema>;
|
|
24
|
-
type NotionWebhookCredentialSets = readonly [typeof notion, typeof notionWebhookCredentialSet];
|
|
25
22
|
type NotionPollingCredentialSets = readonly [typeof notion];
|
|
26
|
-
type NotionWebhookBinding = IntegrationTriggerBindingFactory<NotionWebhookEvent, NotionWebhookCredentialSets, WebhookTriggerManifest, NotionWebhookPayload, WebhookRequest>;
|
|
27
23
|
type NotionPollingBoundTrigger<TOutput> = BoundTrigger<NotionPollingBatch, NotionPollingCredentialSets, PollingTriggerManifest, TOutput>;
|
|
28
24
|
type NotionPollingBindingOptions<TOutput = NotionPollingBatch> = IntegrationTriggerBindingOptions<NotionPollingBatch, TOutput> & {
|
|
29
25
|
readonly schedule?: string;
|
|
@@ -40,26 +36,6 @@ type NotionPollingDataSourceOptions<TOutput = NotionPollingBatch> = NotionPollin
|
|
|
40
36
|
type NotionPollingPageOptions<TOutput = NotionPollingBatch> = NotionPollingBindingOptions<TOutput> & {
|
|
41
37
|
readonly pageId: string;
|
|
42
38
|
};
|
|
43
|
-
type NotionWebhookNamespace = Readonly<{
|
|
44
|
-
pageCreated: NotionWebhookBinding;
|
|
45
|
-
pageContentUpdated: NotionWebhookBinding;
|
|
46
|
-
pagePropertiesUpdated: NotionWebhookBinding;
|
|
47
|
-
pageMoved: NotionWebhookBinding;
|
|
48
|
-
pageDeleted: NotionWebhookBinding;
|
|
49
|
-
pageUndeleted: NotionWebhookBinding;
|
|
50
|
-
pageLocked: NotionWebhookBinding;
|
|
51
|
-
pageUnlocked: NotionWebhookBinding;
|
|
52
|
-
commentCreated: NotionWebhookBinding;
|
|
53
|
-
commentUpdated: NotionWebhookBinding;
|
|
54
|
-
commentDeleted: NotionWebhookBinding;
|
|
55
|
-
dataSourceCreated: NotionWebhookBinding;
|
|
56
|
-
dataSourceContentUpdated: NotionWebhookBinding;
|
|
57
|
-
dataSourceSchemaUpdated: NotionWebhookBinding;
|
|
58
|
-
dataSourceMoved: NotionWebhookBinding;
|
|
59
|
-
dataSourceDeleted: NotionWebhookBinding;
|
|
60
|
-
dataSourceUndeleted: NotionWebhookBinding;
|
|
61
|
-
}>;
|
|
62
|
-
declare const webhooks: NotionWebhookNamespace;
|
|
63
39
|
type NotionPollingNamespace = Readonly<{
|
|
64
40
|
allPageEvents: (options: NotionPollingAllPagesOptions<unknown>) => NotionPollingBoundTrigger<unknown>;
|
|
65
41
|
commentsAdded: (options: NotionPollingCommentsOptions<unknown>) => NotionPollingBoundTrigger<unknown>;
|
|
@@ -69,4 +45,4 @@ type NotionPollingNamespace = Readonly<{
|
|
|
69
45
|
}>;
|
|
70
46
|
declare const polling: NotionPollingNamespace;
|
|
71
47
|
//#endregion
|
|
72
|
-
export { NotionPollingNamespace,
|
|
48
|
+
export { NotionPollingNamespace, polling };
|
package/dist/triggers.mjs
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { t as notion } from "./integration-q-rO2FMC.mjs";
|
|
2
2
|
import { createNotionClient, withRateLimitRetry } from "./client.mjs";
|
|
3
|
-
import { createPollingEvent,
|
|
4
|
-
import { verifyNotionWebhook } from "./verification.mjs";
|
|
3
|
+
import { createPollingEvent, notionPollingEventSchema } from "./events.mjs";
|
|
5
4
|
import { z } from "zod";
|
|
6
|
-
import { createPollingTriggerBindingFactory
|
|
5
|
+
import { createPollingTriggerBindingFactory } from "@keystrokehq/integration-authoring";
|
|
7
6
|
|
|
8
7
|
//#region src/triggers.ts
|
|
9
8
|
const DEFAULT_POLLING_SCHEDULE = "*/10 * * * *";
|
|
@@ -12,7 +11,6 @@ const notionPollingBatchSchema = z.object({
|
|
|
12
11
|
hasMore: z.boolean(),
|
|
13
12
|
nextCursor: z.string().nullish()
|
|
14
13
|
});
|
|
15
|
-
const notionWebhookCredentialSets = [notion, notionWebhookCredentialSet];
|
|
16
14
|
const notionPollingCredentialSets = [notion];
|
|
17
15
|
function resolveSchedule(schedule) {
|
|
18
16
|
return schedule ?? DEFAULT_POLLING_SCHEDULE;
|
|
@@ -22,45 +20,21 @@ function isAfterLastPolled(lastPolledAt, occurredAt) {
|
|
|
22
20
|
if (!lastPolledAt) return true;
|
|
23
21
|
return occurredAt > lastPolledAt;
|
|
24
22
|
}
|
|
25
|
-
function createWebhookBinding(config) {
|
|
26
|
-
return createWebhookTriggerBindingFactory({
|
|
27
|
-
defaultName: config.defaultName,
|
|
28
|
-
defaultDescription: config.defaultDescription,
|
|
29
|
-
path: "/notion",
|
|
30
|
-
method: "POST",
|
|
31
|
-
payload: notionWebhookPayloadSchema,
|
|
32
|
-
credentialSets: notionWebhookCredentialSets,
|
|
33
|
-
verify: (request, ctx) => {
|
|
34
|
-
const webhookCredentials = ctx.credentials["notion-webhook"];
|
|
35
|
-
if (!verifyNotionWebhook({
|
|
36
|
-
headers: request.headers,
|
|
37
|
-
body: request.rawBody
|
|
38
|
-
}, webhookCredentials.verificationToken)) throw new Error("Invalid Notion webhook signature.");
|
|
39
|
-
},
|
|
40
|
-
definitionFilter: (payload) => payload.type === config.eventType,
|
|
41
|
-
mapPayload: (payload) => payload.type === config.eventType ? normalizeWebhookEvent(payload) : null,
|
|
42
|
-
idempotencyKey: (payload) => payload.id,
|
|
43
|
-
response: { successStatus: 200 }
|
|
44
|
-
});
|
|
45
|
-
}
|
|
46
23
|
function createPollingBinding(config) {
|
|
47
24
|
return (options) => createPollingTriggerBindingFactory({
|
|
48
|
-
|
|
25
|
+
defaultId: config.defaultId,
|
|
49
26
|
defaultDescription: config.defaultDescription,
|
|
50
27
|
schedule: resolveSchedule(options.schedule),
|
|
51
28
|
credentialSets: notionPollingCredentialSets,
|
|
52
29
|
response: notionPollingBatchSchema,
|
|
53
30
|
poll: (ctx) => config.build(options, {
|
|
54
|
-
credentials: { notion: ctx.credentials
|
|
31
|
+
credentials: { "keystroke:notion": ctx.credentials["keystroke:notion"] },
|
|
55
32
|
lastPolledAt: ctx.lastPolledAt
|
|
56
|
-
})
|
|
57
|
-
definitionFilter: (payload) => payload.results.length > 0,
|
|
58
|
-
idempotencyKey: (payload) => payload.results[0]?.eventId
|
|
33
|
+
})
|
|
59
34
|
})({
|
|
60
|
-
|
|
61
|
-
description: options.description,
|
|
62
|
-
|
|
63
|
-
transform: options.transform
|
|
35
|
+
...options.id ? { id: options.id } : {},
|
|
36
|
+
...options.description ? { description: options.description } : {},
|
|
37
|
+
...options.transform ? { transform: options.transform } : {}
|
|
64
38
|
});
|
|
65
39
|
}
|
|
66
40
|
async function pollAllPages(credentials, lastPolledAt, query) {
|
|
@@ -166,120 +140,33 @@ async function pollPageUpdated(credentials, lastPolledAt, pageId) {
|
|
|
166
140
|
nextCursor: null
|
|
167
141
|
};
|
|
168
142
|
}
|
|
169
|
-
const webhooks = Object.freeze({
|
|
170
|
-
pageCreated: createWebhookBinding({
|
|
171
|
-
defaultName: "Notion Page Created",
|
|
172
|
-
defaultDescription: "Fires when Notion creates a page",
|
|
173
|
-
eventType: "page.created"
|
|
174
|
-
}),
|
|
175
|
-
pageContentUpdated: createWebhookBinding({
|
|
176
|
-
defaultName: "Notion Page Content Updated",
|
|
177
|
-
defaultDescription: "Fires when Notion updates page content",
|
|
178
|
-
eventType: "page.content_updated"
|
|
179
|
-
}),
|
|
180
|
-
pagePropertiesUpdated: createWebhookBinding({
|
|
181
|
-
defaultName: "Notion Page Properties Updated",
|
|
182
|
-
defaultDescription: "Fires when Notion updates page properties",
|
|
183
|
-
eventType: "page.properties_updated"
|
|
184
|
-
}),
|
|
185
|
-
pageMoved: createWebhookBinding({
|
|
186
|
-
defaultName: "Notion Page Moved",
|
|
187
|
-
defaultDescription: "Fires when a Notion page moves",
|
|
188
|
-
eventType: "page.moved"
|
|
189
|
-
}),
|
|
190
|
-
pageDeleted: createWebhookBinding({
|
|
191
|
-
defaultName: "Notion Page Deleted",
|
|
192
|
-
defaultDescription: "Fires when Notion deletes a page",
|
|
193
|
-
eventType: "page.deleted"
|
|
194
|
-
}),
|
|
195
|
-
pageUndeleted: createWebhookBinding({
|
|
196
|
-
defaultName: "Notion Page Restored",
|
|
197
|
-
defaultDescription: "Fires when Notion restores a page from trash",
|
|
198
|
-
eventType: "page.undeleted"
|
|
199
|
-
}),
|
|
200
|
-
pageLocked: createWebhookBinding({
|
|
201
|
-
defaultName: "Notion Page Locked",
|
|
202
|
-
defaultDescription: "Fires when Notion locks a page",
|
|
203
|
-
eventType: "page.locked"
|
|
204
|
-
}),
|
|
205
|
-
pageUnlocked: createWebhookBinding({
|
|
206
|
-
defaultName: "Notion Page Unlocked",
|
|
207
|
-
defaultDescription: "Fires when Notion unlocks a page",
|
|
208
|
-
eventType: "page.unlocked"
|
|
209
|
-
}),
|
|
210
|
-
commentCreated: createWebhookBinding({
|
|
211
|
-
defaultName: "Notion Comment Created",
|
|
212
|
-
defaultDescription: "Fires when Notion creates a comment",
|
|
213
|
-
eventType: "comment.created"
|
|
214
|
-
}),
|
|
215
|
-
commentUpdated: createWebhookBinding({
|
|
216
|
-
defaultName: "Notion Comment Updated",
|
|
217
|
-
defaultDescription: "Fires when Notion updates a comment",
|
|
218
|
-
eventType: "comment.updated"
|
|
219
|
-
}),
|
|
220
|
-
commentDeleted: createWebhookBinding({
|
|
221
|
-
defaultName: "Notion Comment Deleted",
|
|
222
|
-
defaultDescription: "Fires when Notion deletes a comment",
|
|
223
|
-
eventType: "comment.deleted"
|
|
224
|
-
}),
|
|
225
|
-
dataSourceCreated: createWebhookBinding({
|
|
226
|
-
defaultName: "Notion Data Source Created",
|
|
227
|
-
defaultDescription: "Fires when Notion creates a data source",
|
|
228
|
-
eventType: "data_source.created"
|
|
229
|
-
}),
|
|
230
|
-
dataSourceContentUpdated: createWebhookBinding({
|
|
231
|
-
defaultName: "Notion Data Source Content Updated",
|
|
232
|
-
defaultDescription: "Fires when Notion updates data-source content",
|
|
233
|
-
eventType: "data_source.content_updated"
|
|
234
|
-
}),
|
|
235
|
-
dataSourceSchemaUpdated: createWebhookBinding({
|
|
236
|
-
defaultName: "Notion Data Source Schema Updated",
|
|
237
|
-
defaultDescription: "Fires when Notion updates data-source schema",
|
|
238
|
-
eventType: "data_source.schema_updated"
|
|
239
|
-
}),
|
|
240
|
-
dataSourceMoved: createWebhookBinding({
|
|
241
|
-
defaultName: "Notion Data Source Moved",
|
|
242
|
-
defaultDescription: "Fires when Notion moves a data source",
|
|
243
|
-
eventType: "data_source.moved"
|
|
244
|
-
}),
|
|
245
|
-
dataSourceDeleted: createWebhookBinding({
|
|
246
|
-
defaultName: "Notion Data Source Deleted",
|
|
247
|
-
defaultDescription: "Fires when Notion deletes a data source",
|
|
248
|
-
eventType: "data_source.deleted"
|
|
249
|
-
}),
|
|
250
|
-
dataSourceUndeleted: createWebhookBinding({
|
|
251
|
-
defaultName: "Notion Data Source Restored",
|
|
252
|
-
defaultDescription: "Fires when Notion restores a data source",
|
|
253
|
-
eventType: "data_source.undeleted"
|
|
254
|
-
})
|
|
255
|
-
});
|
|
256
143
|
const polling = Object.freeze({
|
|
257
144
|
allPageEvents: createPollingBinding({
|
|
258
|
-
|
|
145
|
+
defaultId: "notion.polling.all_page_events",
|
|
259
146
|
defaultDescription: "Poll for recently changed Notion pages",
|
|
260
|
-
build: (options, ctx) => pollAllPages(ctx.credentials
|
|
147
|
+
build: (options, ctx) => pollAllPages(ctx.credentials["keystroke:notion"], ctx.lastPolledAt, options.query)
|
|
261
148
|
}),
|
|
262
149
|
commentsAdded: createPollingBinding({
|
|
263
|
-
|
|
150
|
+
defaultId: "notion.polling.comments_added",
|
|
264
151
|
defaultDescription: "Poll for newly created Notion comments on a block or page",
|
|
265
|
-
build: (options, ctx) => pollCommentsAdded(ctx.credentials
|
|
152
|
+
build: (options, ctx) => pollCommentsAdded(ctx.credentials["keystroke:notion"], ctx.lastPolledAt, options.blockId)
|
|
266
153
|
}),
|
|
267
154
|
pageAddedToDataSource: createPollingBinding({
|
|
268
|
-
|
|
155
|
+
defaultId: "notion.polling.page_added_to_data_source",
|
|
269
156
|
defaultDescription: "Poll for newly created entries in a Notion data source",
|
|
270
|
-
build: (options, ctx) => pollPagesAddedToDataSource(ctx.credentials
|
|
157
|
+
build: (options, ctx) => pollPagesAddedToDataSource(ctx.credentials["keystroke:notion"], ctx.lastPolledAt, options.dataSourceId)
|
|
271
158
|
}),
|
|
272
159
|
pageAddedToPage: createPollingBinding({
|
|
273
|
-
|
|
160
|
+
defaultId: "notion.polling.page_added_to_page",
|
|
274
161
|
defaultDescription: "Poll for new child pages added under a Notion page",
|
|
275
|
-
build: (options, ctx) => pollPagesAddedToPage(ctx.credentials
|
|
162
|
+
build: (options, ctx) => pollPagesAddedToPage(ctx.credentials["keystroke:notion"], ctx.lastPolledAt, options.pageId)
|
|
276
163
|
}),
|
|
277
164
|
pageUpdated: createPollingBinding({
|
|
278
|
-
|
|
165
|
+
defaultId: "notion.polling.page_updated",
|
|
279
166
|
defaultDescription: "Poll a single Notion page for updates",
|
|
280
|
-
build: (options, ctx) => pollPageUpdated(ctx.credentials
|
|
167
|
+
build: (options, ctx) => pollPageUpdated(ctx.credentials["keystroke:notion"], ctx.lastPolledAt, options.pageId)
|
|
281
168
|
})
|
|
282
169
|
});
|
|
283
170
|
|
|
284
171
|
//#endregion
|
|
285
|
-
export { polling
|
|
172
|
+
export { polling };
|
package/dist/users.d.mts
CHANGED
|
@@ -10,7 +10,7 @@ declare const getMe: _keystrokehq_core0.Operation<z.ZodObject<{}, z.core.$strip>
|
|
|
10
10
|
name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
11
11
|
avatarUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
12
12
|
email: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
13
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
13
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
14
14
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
15
15
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
16
16
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -24,7 +24,7 @@ declare const getUser: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
24
24
|
name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
25
25
|
avatarUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
26
26
|
email: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
27
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
27
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
28
28
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
29
29
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
30
30
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
@@ -43,7 +43,7 @@ declare const listUsers: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
43
43
|
}, z.core.$strip>>;
|
|
44
44
|
hasMore: z.ZodBoolean;
|
|
45
45
|
nextCursor: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
46
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"notion", z.ZodObject<{
|
|
46
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"keystroke:notion", z.ZodObject<{
|
|
47
47
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
|
48
48
|
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
49
49
|
NOTION_ACCESS_TOKEN: z.ZodString;
|
package/dist/users.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createNotionClient, withRateLimitRetry } from "./client.mjs";
|
|
2
2
|
import { normalizeListMeta, normalizeUser, notionListResponseSchema, notionUserSchema } from "./schemas.mjs";
|
|
3
|
-
import { t as notionOperation } from "./factory-
|
|
3
|
+
import { t as notionOperation } from "./factory-ClakehEF.mjs";
|
|
4
4
|
import { r as buildPaginationInput } from "./shared-C6A6JPl3.mjs";
|
|
5
5
|
import { z } from "zod";
|
|
6
6
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@keystrokehq/notion",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.4",
|
|
4
4
|
"private": false,
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"type": "module",
|
|
@@ -75,29 +75,20 @@
|
|
|
75
75
|
"README.md",
|
|
76
76
|
"LICENSE"
|
|
77
77
|
],
|
|
78
|
-
"scripts": {
|
|
79
|
-
"typecheck": "tsgo --build",
|
|
80
|
-
"build": "tsdown",
|
|
81
|
-
"lint": "biome check .",
|
|
82
|
-
"test:unit": "vitest run --passWithNoTests --project unit",
|
|
83
|
-
"test:int": "vitest run --passWithNoTests --project int",
|
|
84
|
-
"prepublishOnly": "pnpm build && pnpm test:unit",
|
|
85
|
-
"lint:fix": "biome check --write ."
|
|
86
|
-
},
|
|
87
78
|
"dependencies": {
|
|
79
|
+
"@keystrokehq/core": "^0.0.7",
|
|
80
|
+
"@keystrokehq/credential-connection": "^0.0.3",
|
|
81
|
+
"@keystrokehq/integration-authoring": "^0.0.4",
|
|
88
82
|
"@notionhq/client": "^5.17.0",
|
|
89
|
-
"@keystrokehq/credential-connection": "^0.0.1",
|
|
90
|
-
"@keystrokehq/integration-authoring": "^0.0.1",
|
|
91
|
-
"@keystrokehq/core": "^0.0.5",
|
|
92
83
|
"zod": "^4.3.6"
|
|
93
84
|
},
|
|
94
85
|
"devDependencies": {
|
|
95
|
-
"@types/node": "
|
|
96
|
-
"
|
|
97
|
-
"
|
|
98
|
-
"
|
|
99
|
-
"
|
|
100
|
-
"
|
|
86
|
+
"@types/node": "^22.19.11",
|
|
87
|
+
"tsdown": "^0.20.3",
|
|
88
|
+
"typescript": "^5.9.3",
|
|
89
|
+
"vitest": "^4.0.18",
|
|
90
|
+
"@keystrokehq/test-utils": "0.0.0",
|
|
91
|
+
"@keystrokehq/typescript-config": "0.0.0"
|
|
101
92
|
},
|
|
102
93
|
"keywords": [
|
|
103
94
|
"notion",
|
|
@@ -114,5 +105,13 @@
|
|
|
114
105
|
"publishConfig": {
|
|
115
106
|
"access": "public",
|
|
116
107
|
"registry": "https://registry.npmjs.org/"
|
|
108
|
+
},
|
|
109
|
+
"scripts": {
|
|
110
|
+
"typecheck": "tsgo --build",
|
|
111
|
+
"build": "tsdown",
|
|
112
|
+
"lint": "biome check .",
|
|
113
|
+
"test:unit": "vitest run --passWithNoTests --project unit",
|
|
114
|
+
"test:int": "vitest run --passWithNoTests --project int",
|
|
115
|
+
"lint:fix": "biome check --write ."
|
|
117
116
|
}
|
|
118
|
-
}
|
|
117
|
+
}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { z } from "zod";
|
|
2
|
-
import { CredentialSet } from "@keystrokehq/core";
|
|
3
|
-
import * as _keystrokehq_core_credential_set0 from "@keystrokehq/core/credential-set";
|
|
4
|
-
import { InferCredentialSetAuth } from "@keystrokehq/core/credential-set";
|
|
5
|
-
|
|
6
|
-
//#region src/_official/provider-app.d.ts
|
|
7
|
-
declare const notionAppCredentialSet: CredentialSet<"notion-app", z.ZodObject<{
|
|
8
|
-
clientId: z.ZodString;
|
|
9
|
-
clientSecret: z.ZodString;
|
|
10
|
-
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
11
|
-
clientId: z.ZodString;
|
|
12
|
-
clientSecret: z.ZodString;
|
|
13
|
-
}, z.core.$strip>>[] | undefined>;
|
|
14
|
-
declare const notionPlatformProviderSeed: {
|
|
15
|
-
readonly provider: "notion";
|
|
16
|
-
readonly appRef: "notion-platform";
|
|
17
|
-
readonly displayName: "Notion Platform";
|
|
18
|
-
readonly credentialSetName: "Keystroke Notion Platform App";
|
|
19
|
-
readonly envShape: {
|
|
20
|
-
readonly KEYSTROKE_PLATFORM_NOTION_CLIENT_ID: z.ZodOptional<z.ZodString>;
|
|
21
|
-
readonly KEYSTROKE_PLATFORM_NOTION_CLIENT_SECRET: z.ZodOptional<z.ZodString>;
|
|
22
|
-
};
|
|
23
|
-
readonly requiredEnvKeys: readonly ["KEYSTROKE_PLATFORM_NOTION_CLIENT_ID", "KEYSTROKE_PLATFORM_NOTION_CLIENT_SECRET"];
|
|
24
|
-
readonly externalAppIdEnvKey: "KEYSTROKE_PLATFORM_NOTION_CLIENT_ID";
|
|
25
|
-
readonly buildCredentials: (env: Record<string, string | undefined>) => {
|
|
26
|
-
clientId: string | undefined;
|
|
27
|
-
clientSecret: string | undefined;
|
|
28
|
-
};
|
|
29
|
-
};
|
|
30
|
-
type NotionAppCredentials = InferCredentialSetAuth<typeof notionAppCredentialSet>;
|
|
31
|
-
declare const notionWebhookCredentialSet: CredentialSet<"notion-webhook", z.ZodObject<{
|
|
32
|
-
verificationToken: z.ZodString;
|
|
33
|
-
}, z.core.$strip>, readonly _keystrokehq_core_credential_set0.CredentialConnection<z.ZodObject<{
|
|
34
|
-
verificationToken: z.ZodString;
|
|
35
|
-
}, z.core.$strip>>[] | undefined>;
|
|
36
|
-
type NotionWebhookCredentials = InferCredentialSetAuth<typeof notionWebhookCredentialSet>;
|
|
37
|
-
//#endregion
|
|
38
|
-
export { notionWebhookCredentialSet as a, notionPlatformProviderSeed as i, NotionWebhookCredentials as n, notionAppCredentialSet as r, NotionAppCredentials as t };
|