@keystrokehq/posthog 0.0.8 → 0.0.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_official/index.d.mts +1 -1
- package/dist/_official/index.mjs +1 -1
- package/dist/_runtime/index.d.mts +1 -2
- package/dist/_runtime/index.mjs +1 -1
- package/dist/actions.d.mts +13 -13
- package/dist/actions.mjs +1 -1
- package/dist/annotations.d.mts +6 -6
- package/dist/annotations.mjs +1 -1
- package/dist/capture.d.mts +8 -8
- package/dist/capture.mjs +1 -1
- package/dist/client.d.mts +1 -2
- package/dist/client.mjs +1 -1
- package/dist/cohorts.d.mts +9 -9
- package/dist/cohorts.mjs +1 -1
- package/dist/connection.d.mts +1 -1
- package/dist/connection.mjs +1 -1
- package/dist/dashboards.d.mts +17 -17
- package/dist/dashboards.mjs +1 -1
- package/dist/decide.d.mts +3 -3
- package/dist/decide.mjs +1 -1
- package/dist/events-management.d.mts +11 -11
- package/dist/events-management.mjs +1 -1
- package/dist/factory-C3ssyfSy.mjs +7 -0
- package/dist/feature-flags.d.mts +16 -16
- package/dist/feature-flags.mjs +1 -1
- package/dist/http-BYcjqxPi.mjs +84 -0
- package/dist/insights.d.mts +17 -17
- package/dist/insights.mjs +1 -1
- package/dist/{integration-Td6D39_E.d.mts → integration-BN7xcpga.d.mts} +15 -5
- package/dist/integration-D0HdrI0T.mjs +120 -0
- package/dist/organizations.d.mts +12 -12
- package/dist/organizations.mjs +1 -1
- package/dist/persons.d.mts +16 -16
- package/dist/persons.mjs +1 -1
- package/dist/projects.d.mts +14 -14
- package/dist/projects.mjs +1 -1
- package/dist/schemas.d.mts +3 -3
- package/dist/session-recordings.d.mts +15 -15
- package/dist/session-recordings.mjs +1 -1
- package/dist/surveys.d.mts +16 -16
- package/dist/surveys.mjs +1 -1
- package/dist/triggers.d.mts +5 -3
- package/dist/triggers.mjs +52 -3
- package/dist/webhook-management.d.mts +10 -10
- package/dist/webhook-management.mjs +1 -1
- package/package.json +4 -4
- package/dist/factory-DYDvHOGb.mjs +0 -8
- package/dist/integration-Doy2Dwli.mjs +0 -30
|
@@ -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/session-recordings.d.ts
|
|
6
6
|
declare const listSessionRecordings: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
@@ -35,7 +35,7 @@ declare const listSessionRecordings: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
35
35
|
is_identified: z.ZodOptional<z.ZodBoolean>;
|
|
36
36
|
}, z.core.$strip>>>;
|
|
37
37
|
}, z.core.$strip>>;
|
|
38
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
38
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
39
39
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
40
40
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
41
41
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -70,7 +70,7 @@ declare const getSessionRecording: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
70
70
|
created_at: z.ZodOptional<z.ZodString>;
|
|
71
71
|
is_identified: z.ZodOptional<z.ZodBoolean>;
|
|
72
72
|
}, z.core.$strip>>>;
|
|
73
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
73
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
74
74
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
75
75
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
76
76
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -107,7 +107,7 @@ declare const updateSessionRecording: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
107
107
|
created_at: z.ZodOptional<z.ZodString>;
|
|
108
108
|
is_identified: z.ZodOptional<z.ZodBoolean>;
|
|
109
109
|
}, z.core.$strip>>>;
|
|
110
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
110
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
111
111
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
112
112
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
113
113
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -125,7 +125,7 @@ declare const deleteSessionRecording: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
125
125
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
126
126
|
}, z.core.$strip>, z.ZodObject<{
|
|
127
127
|
success: z.ZodBoolean;
|
|
128
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
128
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
129
129
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
130
130
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
131
131
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -145,7 +145,7 @@ declare const getSessionRecordingSnapshots: _keystrokehq_core0.Operation<z.ZodOb
|
|
|
145
145
|
}>>;
|
|
146
146
|
id: z.ZodString;
|
|
147
147
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
148
|
-
}, z.core.$strip>, z.ZodRecord<z.ZodString, z.ZodUnknown>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
148
|
+
}, z.core.$strip>, z.ZodRecord<z.ZodString, z.ZodUnknown>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
149
149
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
150
150
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
151
151
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -161,7 +161,7 @@ declare const getSessionRecordingSnapshots: _keystrokehq_core0.Operation<z.ZodOb
|
|
|
161
161
|
declare const getSessionRecordingProperties: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
162
162
|
id: z.ZodString;
|
|
163
163
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
164
|
-
}, z.core.$strip>, z.ZodRecord<z.ZodString, z.ZodUnknown>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
164
|
+
}, z.core.$strip>, z.ZodRecord<z.ZodString, z.ZodUnknown>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
165
165
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
166
166
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
167
167
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -193,7 +193,7 @@ declare const listPlaylists: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
193
193
|
created_at: z.ZodOptional<z.ZodString>;
|
|
194
194
|
created_by: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
195
195
|
}, z.core.$strip>>;
|
|
196
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
196
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
197
197
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
198
198
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
199
199
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -219,7 +219,7 @@ declare const getPlaylist: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
219
219
|
filters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
220
220
|
created_at: z.ZodOptional<z.ZodString>;
|
|
221
221
|
created_by: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
222
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
222
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
223
223
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
224
224
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
225
225
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -248,7 +248,7 @@ declare const createPlaylist: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
248
248
|
filters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
249
249
|
created_at: z.ZodOptional<z.ZodString>;
|
|
250
250
|
created_by: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
251
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
251
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
252
252
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
253
253
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
254
254
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -279,7 +279,7 @@ declare const updatePlaylist: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
279
279
|
filters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
280
280
|
created_at: z.ZodOptional<z.ZodString>;
|
|
281
281
|
created_by: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
282
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
282
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
283
283
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
284
284
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
285
285
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -297,7 +297,7 @@ declare const deletePlaylist: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
297
297
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
298
298
|
}, z.core.$strip>, z.ZodObject<{
|
|
299
299
|
success: z.ZodBoolean;
|
|
300
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
300
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
301
301
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
302
302
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
303
303
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -338,7 +338,7 @@ declare const listPlaylistRecordings: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
338
338
|
is_identified: z.ZodOptional<z.ZodBoolean>;
|
|
339
339
|
}, z.core.$strip>>>;
|
|
340
340
|
}, z.core.$strip>>;
|
|
341
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
341
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
342
342
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
343
343
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
344
344
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -355,7 +355,7 @@ declare const addRecordingToPlaylist: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
355
355
|
session_recording_id: z.ZodString;
|
|
356
356
|
playlistId: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
|
|
357
357
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
358
|
-
}, z.core.$strip>, z.ZodRecord<z.ZodString, z.ZodUnknown>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
358
|
+
}, z.core.$strip>, z.ZodRecord<z.ZodString, z.ZodUnknown>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
359
359
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
360
360
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
361
361
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -374,7 +374,7 @@ declare const removeRecordingFromPlaylist: _keystrokehq_core0.Operation<z.ZodObj
|
|
|
374
374
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
375
375
|
}, z.core.$strip>, z.ZodObject<{
|
|
376
376
|
success: z.ZodBoolean;
|
|
377
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
377
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
378
378
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
379
379
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
380
380
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createPosthogManagementClient } from "./client.mjs";
|
|
2
2
|
import { paginatedResponseSchema, projectIdInputShape, sessionRecordingPlaylistSchema, sessionRecordingSchema } from "./schemas.mjs";
|
|
3
|
-
import { t as posthogOperation } from "./factory-
|
|
3
|
+
import { t as posthogOperation } from "./factory-C3ssyfSy.mjs";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
|
|
6
6
|
//#region src/session-recordings.ts
|
package/dist/surveys.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/surveys.d.ts
|
|
6
6
|
declare const listSurveys: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
@@ -17,12 +17,12 @@ declare const listSurveys: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
17
17
|
name: z.ZodOptional<z.ZodString>;
|
|
18
18
|
description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
19
19
|
type: z.ZodOptional<z.ZodEnum<{
|
|
20
|
+
email: "email";
|
|
20
21
|
popover: "popover";
|
|
21
22
|
api: "api";
|
|
22
23
|
widget: "widget";
|
|
23
24
|
button: "button";
|
|
24
25
|
full_screen: "full_screen";
|
|
25
|
-
email: "email";
|
|
26
26
|
}>>;
|
|
27
27
|
questions: z.ZodOptional<z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
28
28
|
conditions: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
@@ -35,7 +35,7 @@ declare const listSurveys: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
35
35
|
created_at: z.ZodOptional<z.ZodString>;
|
|
36
36
|
created_by: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
37
37
|
}, z.core.$strip>>;
|
|
38
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
38
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
39
39
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
40
40
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
41
41
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -56,12 +56,12 @@ declare const getSurvey: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
56
56
|
name: z.ZodOptional<z.ZodString>;
|
|
57
57
|
description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
58
58
|
type: z.ZodOptional<z.ZodEnum<{
|
|
59
|
+
email: "email";
|
|
59
60
|
popover: "popover";
|
|
60
61
|
api: "api";
|
|
61
62
|
widget: "widget";
|
|
62
63
|
button: "button";
|
|
63
64
|
full_screen: "full_screen";
|
|
64
|
-
email: "email";
|
|
65
65
|
}>>;
|
|
66
66
|
questions: z.ZodOptional<z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
67
67
|
conditions: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
@@ -73,7 +73,7 @@ declare const getSurvey: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
73
73
|
archived: z.ZodOptional<z.ZodBoolean>;
|
|
74
74
|
created_at: z.ZodOptional<z.ZodString>;
|
|
75
75
|
created_by: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
76
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
76
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
77
77
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
78
78
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
79
79
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -90,12 +90,12 @@ declare const createSurvey: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
90
90
|
name: z.ZodString;
|
|
91
91
|
description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
92
92
|
type: z.ZodOptional<z.ZodEnum<{
|
|
93
|
+
email: "email";
|
|
93
94
|
popover: "popover";
|
|
94
95
|
api: "api";
|
|
95
96
|
widget: "widget";
|
|
96
97
|
button: "button";
|
|
97
98
|
full_screen: "full_screen";
|
|
98
|
-
email: "email";
|
|
99
99
|
}>>;
|
|
100
100
|
questions: z.ZodOptional<z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
101
101
|
conditions: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
@@ -111,12 +111,12 @@ declare const createSurvey: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
111
111
|
name: z.ZodOptional<z.ZodString>;
|
|
112
112
|
description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
113
113
|
type: z.ZodOptional<z.ZodEnum<{
|
|
114
|
+
email: "email";
|
|
114
115
|
popover: "popover";
|
|
115
116
|
api: "api";
|
|
116
117
|
widget: "widget";
|
|
117
118
|
button: "button";
|
|
118
119
|
full_screen: "full_screen";
|
|
119
|
-
email: "email";
|
|
120
120
|
}>>;
|
|
121
121
|
questions: z.ZodOptional<z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
122
122
|
conditions: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
@@ -128,7 +128,7 @@ declare const createSurvey: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
128
128
|
archived: z.ZodOptional<z.ZodBoolean>;
|
|
129
129
|
created_at: z.ZodOptional<z.ZodString>;
|
|
130
130
|
created_by: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
131
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
131
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
132
132
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
133
133
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
134
134
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -145,12 +145,12 @@ declare const updateSurvey: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
145
145
|
name: z.ZodOptional<z.ZodString>;
|
|
146
146
|
description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
147
147
|
type: z.ZodOptional<z.ZodEnum<{
|
|
148
|
+
email: "email";
|
|
148
149
|
popover: "popover";
|
|
149
150
|
api: "api";
|
|
150
151
|
widget: "widget";
|
|
151
152
|
button: "button";
|
|
152
153
|
full_screen: "full_screen";
|
|
153
|
-
email: "email";
|
|
154
154
|
}>>;
|
|
155
155
|
questions: z.ZodOptional<z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
156
156
|
conditions: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
@@ -167,12 +167,12 @@ declare const updateSurvey: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
167
167
|
name: z.ZodOptional<z.ZodString>;
|
|
168
168
|
description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
169
169
|
type: z.ZodOptional<z.ZodEnum<{
|
|
170
|
+
email: "email";
|
|
170
171
|
popover: "popover";
|
|
171
172
|
api: "api";
|
|
172
173
|
widget: "widget";
|
|
173
174
|
button: "button";
|
|
174
175
|
full_screen: "full_screen";
|
|
175
|
-
email: "email";
|
|
176
176
|
}>>;
|
|
177
177
|
questions: z.ZodOptional<z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
178
178
|
conditions: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
@@ -184,7 +184,7 @@ declare const updateSurvey: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
184
184
|
archived: z.ZodOptional<z.ZodBoolean>;
|
|
185
185
|
created_at: z.ZodOptional<z.ZodString>;
|
|
186
186
|
created_by: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
187
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
187
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
188
188
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
189
189
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
190
190
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -202,7 +202,7 @@ declare const deleteSurvey: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
202
202
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
203
203
|
}, z.core.$strip>, z.ZodObject<{
|
|
204
204
|
success: z.ZodBoolean;
|
|
205
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
205
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
206
206
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
207
207
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
208
208
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -221,7 +221,7 @@ declare const getSurveyActivity: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
221
221
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
222
222
|
}, z.core.$strip>, z.ZodObject<{
|
|
223
223
|
results: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
224
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
224
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
225
225
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
226
226
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
227
227
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -239,7 +239,7 @@ declare const getSurveysActivityFeed: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
239
239
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
240
240
|
}, z.core.$strip>, z.ZodObject<{
|
|
241
241
|
results: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
242
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
242
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
243
243
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
244
244
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
245
245
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -254,7 +254,7 @@ declare const getSurveysActivityFeed: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
254
254
|
}, z.core.$strip>>[] | undefined>], undefined>;
|
|
255
255
|
declare const getSurveyResponsesCount: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
256
256
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
257
|
-
}, z.core.$strip>, z.ZodRecord<z.ZodString, z.ZodUnknown>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
257
|
+
}, z.core.$strip>, z.ZodRecord<z.ZodString, z.ZodUnknown>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
258
258
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
259
259
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
260
260
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -270,7 +270,7 @@ declare const getSurveyResponsesCount: _keystrokehq_core0.Operation<z.ZodObject<
|
|
|
270
270
|
declare const getSurveyStats: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
271
271
|
id: z.ZodString;
|
|
272
272
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
273
|
-
}, z.core.$strip>, z.ZodRecord<z.ZodString, z.ZodUnknown>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
273
|
+
}, z.core.$strip>, z.ZodRecord<z.ZodString, z.ZodUnknown>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
274
274
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
275
275
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
276
276
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
package/dist/surveys.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createPosthogManagementClient } from "./client.mjs";
|
|
2
2
|
import { paginatedResponseSchema, projectIdInputShape, surveySchema } from "./schemas.mjs";
|
|
3
|
-
import { t as posthogOperation } from "./factory-
|
|
3
|
+
import { t as posthogOperation } from "./factory-C3ssyfSy.mjs";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
|
|
6
6
|
//#region src/surveys.ts
|
package/dist/triggers.d.mts
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
import { n as posthog } from "./integration-
|
|
1
|
+
import { n as posthog } from "./integration-BN7xcpga.mjs";
|
|
2
|
+
import { BoundTrigger, Operation } from "@keystrokehq/core";
|
|
2
3
|
import { z } from "zod";
|
|
3
|
-
import { IntegrationTriggerBindingOptions, createPollingTriggerBindingFactory } from "@keystrokehq/integration-authoring";
|
|
4
|
-
import { BoundTrigger } from "@keystrokehq/core";
|
|
5
4
|
import { PollingTriggerManifest } from "@keystrokehq/core/trigger";
|
|
6
5
|
|
|
6
|
+
//#region ../../packages/integration-authoring/dist/index.d.mts
|
|
7
|
+
declare function createPollingTriggerBindingFactory(config: any): (options: any) => any;
|
|
8
|
+
//#endregion
|
|
7
9
|
//#region src/triggers.d.ts
|
|
8
10
|
type PosthogCredentialSets = readonly [typeof posthog];
|
|
9
11
|
type Schedule = Parameters<typeof createPollingTriggerBindingFactory>[0]['schedule'];
|
package/dist/triggers.mjs
CHANGED
|
@@ -1,15 +1,64 @@
|
|
|
1
|
-
import { t as posthog } from "./integration-
|
|
1
|
+
import { t as posthog } from "./integration-D0HdrI0T.mjs";
|
|
2
2
|
import { createPosthogManagementClient } from "./client.mjs";
|
|
3
|
+
import { Operation } from "@keystrokehq/core";
|
|
3
4
|
import { z } from "zod";
|
|
4
|
-
import {
|
|
5
|
+
import { pollingTrigger } from "@keystrokehq/core/trigger";
|
|
5
6
|
|
|
7
|
+
//#region ../../packages/integration-authoring/dist/index.mjs
|
|
8
|
+
const IntegrationConfigSchema = z.object({
|
|
9
|
+
id: z.string().min(1),
|
|
10
|
+
name: z.string().min(1),
|
|
11
|
+
description: z.string().optional()
|
|
12
|
+
});
|
|
13
|
+
function resolveMetadata(metadata, defaults) {
|
|
14
|
+
return {
|
|
15
|
+
id: metadata?.id ?? defaults.defaultId,
|
|
16
|
+
description: metadata?.description ?? defaults.defaultDescription
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
function resolveAuthorPayload(payload, mapPayload) {
|
|
20
|
+
if (!mapPayload) return payload;
|
|
21
|
+
return mapPayload(payload);
|
|
22
|
+
}
|
|
23
|
+
function createIntegrationTriggerBindingFactory(config) {
|
|
24
|
+
const bind = (options) => {
|
|
25
|
+
const resolvedMetadata = resolveMetadata(options, config);
|
|
26
|
+
const baseTrigger = config.createBaseTrigger(resolvedMetadata);
|
|
27
|
+
const userTransform = options?.transform;
|
|
28
|
+
return baseTrigger({ transform: userTransform || config.mapPayload ? (runtimePayload, request) => {
|
|
29
|
+
const authorPayload = resolveAuthorPayload(runtimePayload, config.mapPayload);
|
|
30
|
+
if (authorPayload === null) throw new Error(`Trigger "${resolvedMetadata.id}" mapPayload returned null after the trigger filter passed; tighten the trigger filter schema.`);
|
|
31
|
+
if (!userTransform) return authorPayload;
|
|
32
|
+
return userTransform(authorPayload, request);
|
|
33
|
+
} : void 0 });
|
|
34
|
+
};
|
|
35
|
+
return Object.freeze(bind);
|
|
36
|
+
}
|
|
37
|
+
function createPollingTriggerBindingFactory(config) {
|
|
38
|
+
return createIntegrationTriggerBindingFactory({
|
|
39
|
+
defaultId: config.defaultId,
|
|
40
|
+
defaultDescription: config.defaultDescription,
|
|
41
|
+
mapPayload: config.mapPayload,
|
|
42
|
+
createBaseTrigger: (metadata) => pollingTrigger({
|
|
43
|
+
id: metadata.id,
|
|
44
|
+
description: metadata.description,
|
|
45
|
+
schedule: config.schedule,
|
|
46
|
+
response: config.response,
|
|
47
|
+
poll: config.poll,
|
|
48
|
+
...config.credentialSets ? { credentialSets: config.credentialSets } : {},
|
|
49
|
+
...config.filter ? { filter: config.filter } : {}
|
|
50
|
+
})
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
//#endregion
|
|
6
55
|
//#region src/triggers.ts
|
|
7
56
|
function withDefaultSchedule(schedule) {
|
|
8
57
|
if (schedule === void 0) return "1m";
|
|
9
58
|
return schedule;
|
|
10
59
|
}
|
|
11
60
|
function extractCredentials(ctx) {
|
|
12
|
-
return ctx.credentials["
|
|
61
|
+
return ctx.credentials["posthog"];
|
|
13
62
|
}
|
|
14
63
|
function createPosthogPollingBindingFactory(config) {
|
|
15
64
|
return createPollingTriggerBindingFactory({
|
|
@@ -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/webhook-management.d.ts
|
|
6
6
|
declare const listActionWebhooks: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
@@ -20,9 +20,9 @@ declare const listActionWebhooks: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
20
20
|
event: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
21
21
|
url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
22
22
|
url_matching: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
23
|
+
exact: "exact";
|
|
23
24
|
contains: "contains";
|
|
24
25
|
regex: "regex";
|
|
25
|
-
exact: "exact";
|
|
26
26
|
}>>>;
|
|
27
27
|
text: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
28
28
|
href: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -34,7 +34,7 @@ declare const listActionWebhooks: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
34
34
|
deleted: z.ZodOptional<z.ZodBoolean>;
|
|
35
35
|
is_calculating: z.ZodOptional<z.ZodBoolean>;
|
|
36
36
|
}, z.core.$strip>>;
|
|
37
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
37
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
38
38
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
39
39
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
40
40
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -61,9 +61,9 @@ declare const attachActionWebhook: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
61
61
|
event: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
62
62
|
url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
63
63
|
url_matching: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
64
|
+
exact: "exact";
|
|
64
65
|
contains: "contains";
|
|
65
66
|
regex: "regex";
|
|
66
|
-
exact: "exact";
|
|
67
67
|
}>>>;
|
|
68
68
|
text: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
69
69
|
href: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -74,7 +74,7 @@ declare const attachActionWebhook: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
74
74
|
created_by: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
75
75
|
deleted: z.ZodOptional<z.ZodBoolean>;
|
|
76
76
|
is_calculating: z.ZodOptional<z.ZodBoolean>;
|
|
77
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
77
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
78
78
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
79
79
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
80
80
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -100,9 +100,9 @@ declare const detachActionWebhook: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
100
100
|
event: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
101
101
|
url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
102
102
|
url_matching: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
103
|
+
exact: "exact";
|
|
103
104
|
contains: "contains";
|
|
104
105
|
regex: "regex";
|
|
105
|
-
exact: "exact";
|
|
106
106
|
}>>>;
|
|
107
107
|
text: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
108
108
|
href: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -113,7 +113,7 @@ declare const detachActionWebhook: _keystrokehq_core0.Operation<z.ZodObject<{
|
|
|
113
113
|
created_by: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
114
114
|
deleted: z.ZodOptional<z.ZodBoolean>;
|
|
115
115
|
is_calculating: z.ZodOptional<z.ZodBoolean>;
|
|
116
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
116
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
117
117
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
118
118
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
119
119
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -134,7 +134,7 @@ declare const listPipelineDestinations: _keystrokehq_core0.Operation<z.ZodObject
|
|
|
134
134
|
previous: z.ZodNullable<z.ZodString>;
|
|
135
135
|
count: z.ZodNumber;
|
|
136
136
|
results: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
137
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
137
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
138
138
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
139
139
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
140
140
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -153,7 +153,7 @@ declare const createPipelineDestination: _keystrokehq_core0.Operation<z.ZodObjec
|
|
|
153
153
|
order: z.ZodOptional<z.ZodNumber>;
|
|
154
154
|
config: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
155
155
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
156
|
-
}, z.core.$strip>, z.ZodRecord<z.ZodString, z.ZodUnknown>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
156
|
+
}, z.core.$strip>, z.ZodRecord<z.ZodString, z.ZodUnknown>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
157
157
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
158
158
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
159
159
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -171,7 +171,7 @@ declare const deletePipelineDestination: _keystrokehq_core0.Operation<z.ZodObjec
|
|
|
171
171
|
projectId: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
172
172
|
}, z.core.$strip>, z.ZodObject<{
|
|
173
173
|
success: z.ZodBoolean;
|
|
174
|
-
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"
|
|
174
|
+
}, z.core.$strip>, readonly [_keystrokehq_core0.CredentialSet<"posthog", z.ZodObject<{
|
|
175
175
|
POSTHOG_PERSONAL_API_KEY: z.ZodString;
|
|
176
176
|
POSTHOG_PROJECT_API_KEY: z.ZodOptional<z.ZodString>;
|
|
177
177
|
POSTHOG_HOST: z.ZodDefault<z.ZodURL>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createPosthogManagementClient } from "./client.mjs";
|
|
2
2
|
import { actionSchema, paginatedResponseSchema, projectIdInputShape } from "./schemas.mjs";
|
|
3
|
-
import { t as posthogOperation } from "./factory-
|
|
3
|
+
import { t as posthogOperation } from "./factory-C3ssyfSy.mjs";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
|
|
6
6
|
//#region src/webhook-management.ts
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@keystrokehq/posthog",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.9",
|
|
4
4
|
"private": false,
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"type": "module",
|
|
@@ -104,7 +104,6 @@
|
|
|
104
104
|
"LICENSE"
|
|
105
105
|
],
|
|
106
106
|
"dependencies": {
|
|
107
|
-
"@keystrokehq/integration-authoring": "^0.0.8",
|
|
108
107
|
"zod": "^4.3.6"
|
|
109
108
|
},
|
|
110
109
|
"peerDependencies": {
|
|
@@ -115,9 +114,10 @@
|
|
|
115
114
|
"tsdown": "^0.20.3",
|
|
116
115
|
"typescript": "^5.9.3",
|
|
117
116
|
"vitest": "^4.0.18",
|
|
118
|
-
"@keystrokehq/core": "^0.0.
|
|
117
|
+
"@keystrokehq/core": "^0.0.12",
|
|
119
118
|
"@keystrokehq/test-utils": "0.0.0",
|
|
120
|
-
"@keystrokehq/typescript-config": "0.0.0"
|
|
119
|
+
"@keystrokehq/typescript-config": "0.0.0",
|
|
120
|
+
"@keystrokehq/integration-authoring": "0.0.9"
|
|
121
121
|
},
|
|
122
122
|
"keywords": [
|
|
123
123
|
"posthog",
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { t as posthog } from "./integration-Doy2Dwli.mjs";
|
|
2
|
-
import { createOfficialOperationFactory } from "@keystrokehq/integration-authoring/official";
|
|
3
|
-
|
|
4
|
-
//#region src/factory.ts
|
|
5
|
-
const posthogOperation = createOfficialOperationFactory(posthog);
|
|
6
|
-
|
|
7
|
-
//#endregion
|
|
8
|
-
export { posthogOperation as t };
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { defineOfficialIntegration } from "@keystrokehq/integration-authoring/official";
|
|
2
|
-
import { z } from "zod";
|
|
3
|
-
|
|
4
|
-
//#region src/integration.ts
|
|
5
|
-
const posthogAuthSchema = z.object({
|
|
6
|
-
POSTHOG_PERSONAL_API_KEY: z.string().min(1),
|
|
7
|
-
POSTHOG_PROJECT_API_KEY: z.string().min(1).optional(),
|
|
8
|
-
POSTHOG_HOST: z.url().default("https://us.posthog.com"),
|
|
9
|
-
POSTHOG_PROJECT_ID: z.string().min(1).optional(),
|
|
10
|
-
POSTHOG_SCOPES: z.array(z.string()).optional()
|
|
11
|
-
});
|
|
12
|
-
/**
|
|
13
|
-
* PostHog integration — product analytics, feature flags, experiments,
|
|
14
|
-
* session replay, surveys, and data-platform management.
|
|
15
|
-
*
|
|
16
|
-
* The personal API key is injected as `Authorization: Bearer` for every
|
|
17
|
-
* management request (see `./client.ts`). The optional project API key
|
|
18
|
-
* is required only for capture/decide operations.
|
|
19
|
-
*/
|
|
20
|
-
const posthogOfficialIntegration = {
|
|
21
|
-
id: "posthog",
|
|
22
|
-
name: "PostHog",
|
|
23
|
-
description: "PostHog product analytics, feature flags, experiments, session replay, surveys, and data-platform management",
|
|
24
|
-
auth: posthogAuthSchema
|
|
25
|
-
};
|
|
26
|
-
const posthogBundle = defineOfficialIntegration(posthogOfficialIntegration);
|
|
27
|
-
const posthog = posthogBundle.credentialSet;
|
|
28
|
-
|
|
29
|
-
//#endregion
|
|
30
|
-
export { posthogBundle as n, posthogOfficialIntegration as r, posthog as t };
|