@bubblelab/bubble-core 0.1.157 → 0.1.158
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/bubble-bundle.d.ts +102 -102
- package/dist/bubbles/service-bubble/agi-inc.d.ts +144 -144
- package/dist/bubbles/service-bubble/ai-agent.d.ts +8 -8
- package/dist/bubbles/service-bubble/airtable.d.ts +184 -184
- package/dist/bubbles/service-bubble/apify/apify.d.ts +24 -24
- package/dist/bubbles/service-bubble/ashby/ashby.d.ts +152 -152
- package/dist/bubbles/service-bubble/browserbase/browserbase.d.ts +55 -55
- package/dist/bubbles/service-bubble/confluence/confluence.d.ts +63 -63
- package/dist/bubbles/service-bubble/crustdata/crustdata.d.ts +98 -98
- package/dist/bubbles/service-bubble/eleven-labs.d.ts +56 -56
- package/dist/bubbles/service-bubble/firecrawl.d.ts +264 -264
- package/dist/bubbles/service-bubble/followupboss.d.ts +282 -282
- package/dist/bubbles/service-bubble/fullenrich/fullenrich.d.ts +40 -40
- package/dist/bubbles/service-bubble/github.d.ts +216 -216
- package/dist/bubbles/service-bubble/gmail.d.ts +228 -228
- package/dist/bubbles/service-bubble/google-calendar.d.ts +62 -62
- package/dist/bubbles/service-bubble/google-drive.d.ts +152 -152
- package/dist/bubbles/service-bubble/google-sheets/google-sheets.d.ts +44 -44
- package/dist/bubbles/service-bubble/hello-world.d.ts +4 -4
- package/dist/bubbles/service-bubble/http.d.ts +12 -12
- package/dist/bubbles/service-bubble/insforge-db.d.ts +6 -6
- package/dist/bubbles/service-bubble/jira/jira.d.ts +107 -107
- package/dist/bubbles/service-bubble/notion/notion.d.ts +932 -932
- package/dist/bubbles/service-bubble/postgresql.d.ts +6 -6
- package/dist/bubbles/service-bubble/posthog/index.d.ts +1 -1
- package/dist/bubbles/service-bubble/posthog/index.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/posthog/index.js +1 -1
- package/dist/bubbles/service-bubble/posthog/index.js.map +1 -1
- package/dist/bubbles/service-bubble/posthog/posthog.d.ts +150 -68
- package/dist/bubbles/service-bubble/posthog/posthog.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/posthog/posthog.js +18 -0
- package/dist/bubbles/service-bubble/posthog/posthog.js.map +1 -1
- package/dist/bubbles/service-bubble/posthog/posthog.schema.d.ts +202 -89
- package/dist/bubbles/service-bubble/posthog/posthog.schema.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/posthog/posthog.schema.js +57 -3
- package/dist/bubbles/service-bubble/posthog/posthog.schema.js.map +1 -1
- package/dist/bubbles/service-bubble/resend.d.ts +16 -16
- package/dist/bubbles/service-bubble/slack/slack.d.ts +384 -384
- package/dist/bubbles/service-bubble/storage.d.ts +40 -40
- package/dist/bubbles/service-bubble/stripe/stripe.d.ts +161 -161
- package/dist/bubbles/service-bubble/telegram.d.ts +264 -264
- package/dist/bubbles/tool-bubble/amazon-shopping-tool/amazon-shopping-tool.d.ts +26 -26
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/bubbleflow-validation-tool.d.ts +8 -8
- package/dist/bubbles/tool-bubble/chart-js-tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/code-edit-tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/company-enrichment-tool.d.ts +18 -18
- package/dist/bubbles/tool-bubble/get-bubble-details-tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/get-trigger-detail-tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/google-maps-tool.d.ts +12 -12
- package/dist/bubbles/tool-bubble/instagram-tool.d.ts +22 -22
- package/dist/bubbles/tool-bubble/linkedin-tool.d.ts +108 -108
- package/dist/bubbles/tool-bubble/list-airtable-bases-tool.d.ts +12 -12
- package/dist/bubbles/tool-bubble/list-airtable-tables-tool.d.ts +24 -24
- package/dist/bubbles/tool-bubble/list-bubbles-tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/list-capabilities-tool.d.ts +12 -12
- package/dist/bubbles/tool-bubble/people-search-tool.d.ts +42 -42
- package/dist/bubbles/tool-bubble/reddit-scrape-tool.d.ts +16 -16
- package/dist/bubbles/tool-bubble/research-agent-tool.d.ts +8 -8
- package/dist/bubbles/tool-bubble/sql-query-tool.d.ts +8 -8
- package/dist/bubbles/tool-bubble/tiktok-tool.d.ts +12 -12
- package/dist/bubbles/tool-bubble/tool-template.d.ts +4 -4
- package/dist/bubbles/tool-bubble/twitter-tool.d.ts +36 -36
- package/dist/bubbles/tool-bubble/web-crawl-tool.d.ts +8 -8
- package/dist/bubbles/tool-bubble/web-extract-tool.d.ts +8 -8
- package/dist/bubbles/tool-bubble/web-scrape-tool.d.ts +8 -8
- package/dist/bubbles/tool-bubble/web-search-tool.d.ts +16 -16
- package/dist/bubbles/tool-bubble/yc-scraper-tool.d.ts +8 -8
- package/dist/bubbles/tool-bubble/youtube-tool.d.ts +18 -18
- package/dist/bubbles/workflow-bubble/database-analyzer.workflow.d.ts +4 -4
- package/dist/bubbles/workflow-bubble/generate-document.workflow.d.ts +24 -24
- package/dist/bubbles/workflow-bubble/parse-document.workflow.d.ts +4 -4
- package/dist/bubbles/workflow-bubble/pdf-form-operations.workflow.d.ts +68 -68
- package/dist/bubbles/workflow-bubble/pdf-ocr.workflow.d.ts +24 -24
- package/dist/bubbles/workflow-bubble/slack-data-assistant.workflow.d.ts +10 -10
- package/dist/bubbles/workflow-bubble/slack-formatter-agent.d.ts +70 -70
- package/dist/bubbles/workflow-bubble/slack-notifier.workflow.d.ts +4 -4
- package/dist/bubbles.json +128 -5
- package/package.json +2 -2
|
@@ -4,7 +4,8 @@ import { CredentialType } from '@bubblelab/shared-schemas';
|
|
|
4
4
|
* PostHog event object from events API
|
|
5
5
|
*/
|
|
6
6
|
export declare const PosthogEventSchema: z.ZodObject<{
|
|
7
|
-
|
|
7
|
+
id: z.ZodOptional<z.ZodString>;
|
|
8
|
+
uuid: z.ZodOptional<z.ZodString>;
|
|
8
9
|
event: z.ZodString;
|
|
9
10
|
distinct_id: z.ZodString;
|
|
10
11
|
properties: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
@@ -13,22 +14,24 @@ export declare const PosthogEventSchema: z.ZodObject<{
|
|
|
13
14
|
elements: z.ZodOptional<z.ZodArray<z.ZodUnknown, "many">>;
|
|
14
15
|
elements_chain: z.ZodOptional<z.ZodString>;
|
|
15
16
|
}, "strip", z.ZodTypeAny, {
|
|
16
|
-
uuid: string;
|
|
17
17
|
event: string;
|
|
18
18
|
distinct_id: string;
|
|
19
|
+
id?: string | undefined;
|
|
20
|
+
uuid?: string | undefined;
|
|
19
21
|
properties?: Record<string, unknown> | undefined;
|
|
20
|
-
elements?: unknown[] | undefined;
|
|
21
22
|
timestamp?: string | undefined;
|
|
22
23
|
created_at?: string | undefined;
|
|
24
|
+
elements?: unknown[] | undefined;
|
|
23
25
|
elements_chain?: string | undefined;
|
|
24
26
|
}, {
|
|
25
|
-
uuid: string;
|
|
26
27
|
event: string;
|
|
27
28
|
distinct_id: string;
|
|
29
|
+
id?: string | undefined;
|
|
30
|
+
uuid?: string | undefined;
|
|
28
31
|
properties?: Record<string, unknown> | undefined;
|
|
29
|
-
elements?: unknown[] | undefined;
|
|
30
32
|
timestamp?: string | undefined;
|
|
31
33
|
created_at?: string | undefined;
|
|
34
|
+
elements?: unknown[] | undefined;
|
|
32
35
|
elements_chain?: string | undefined;
|
|
33
36
|
}>;
|
|
34
37
|
/**
|
|
@@ -43,14 +46,14 @@ export declare const PosthogPersonSchema: z.ZodObject<{
|
|
|
43
46
|
}, "strip", z.ZodTypeAny, {
|
|
44
47
|
id: string;
|
|
45
48
|
distinct_ids: string[];
|
|
46
|
-
properties?: Record<string, unknown> | undefined;
|
|
47
49
|
uuid?: string | undefined;
|
|
50
|
+
properties?: Record<string, unknown> | undefined;
|
|
48
51
|
created_at?: string | undefined;
|
|
49
52
|
}, {
|
|
50
53
|
id: string;
|
|
51
54
|
distinct_ids: string[];
|
|
52
|
-
properties?: Record<string, unknown> | undefined;
|
|
53
55
|
uuid?: string | undefined;
|
|
56
|
+
properties?: Record<string, unknown> | undefined;
|
|
54
57
|
created_at?: string | undefined;
|
|
55
58
|
}>;
|
|
56
59
|
/**
|
|
@@ -69,21 +72,21 @@ export declare const PosthogInsightSchema: z.ZodObject<{
|
|
|
69
72
|
}, "strip", z.ZodTypeAny, {
|
|
70
73
|
id: number;
|
|
71
74
|
description?: string | null | undefined;
|
|
75
|
+
created_at?: string | undefined;
|
|
76
|
+
short_id?: string | undefined;
|
|
72
77
|
name?: string | null | undefined;
|
|
73
78
|
result?: unknown;
|
|
74
|
-
created_at?: string | undefined;
|
|
75
79
|
filters?: Record<string, unknown> | undefined;
|
|
76
|
-
short_id?: string | undefined;
|
|
77
80
|
last_refresh?: string | null | undefined;
|
|
78
81
|
last_modified_at?: string | undefined;
|
|
79
82
|
}, {
|
|
80
83
|
id: number;
|
|
81
84
|
description?: string | null | undefined;
|
|
85
|
+
created_at?: string | undefined;
|
|
86
|
+
short_id?: string | undefined;
|
|
82
87
|
name?: string | null | undefined;
|
|
83
88
|
result?: unknown;
|
|
84
|
-
created_at?: string | undefined;
|
|
85
89
|
filters?: Record<string, unknown> | undefined;
|
|
86
|
-
short_id?: string | undefined;
|
|
87
90
|
last_refresh?: string | null | undefined;
|
|
88
91
|
last_modified_at?: string | undefined;
|
|
89
92
|
}>;
|
|
@@ -93,26 +96,69 @@ export declare const PosthogInsightSchema: z.ZodObject<{
|
|
|
93
96
|
export declare const PosthogQueryResultSchema: z.ZodObject<{
|
|
94
97
|
columns: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
95
98
|
results: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodUnknown, "many">, "many">>;
|
|
96
|
-
types: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
97
|
-
hasMore: z.ZodOptional<z.ZodBoolean
|
|
99
|
+
types: z.ZodOptional<z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>, "many">>;
|
|
100
|
+
hasMore: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
98
101
|
limit: z.ZodOptional<z.ZodNumber>;
|
|
99
102
|
offset: z.ZodOptional<z.ZodNumber>;
|
|
100
103
|
}, "strip", z.ZodTypeAny, {
|
|
101
|
-
|
|
104
|
+
columns?: string[] | undefined;
|
|
105
|
+
results?: unknown[][] | undefined;
|
|
106
|
+
types?: (string | string[])[] | undefined;
|
|
107
|
+
hasMore?: boolean | null | undefined;
|
|
102
108
|
limit?: number | undefined;
|
|
103
109
|
offset?: number | undefined;
|
|
104
|
-
hasMore?: boolean | undefined;
|
|
105
|
-
results?: unknown[][] | undefined;
|
|
106
|
-
columns?: string[] | undefined;
|
|
107
110
|
}, {
|
|
108
|
-
|
|
111
|
+
columns?: string[] | undefined;
|
|
112
|
+
results?: unknown[][] | undefined;
|
|
113
|
+
types?: (string | string[])[] | undefined;
|
|
114
|
+
hasMore?: boolean | null | undefined;
|
|
109
115
|
limit?: number | undefined;
|
|
110
116
|
offset?: number | undefined;
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
117
|
+
}>;
|
|
118
|
+
/**
|
|
119
|
+
* PostHog project object from projects API
|
|
120
|
+
*/
|
|
121
|
+
export declare const PosthogProjectSchema: z.ZodObject<{
|
|
122
|
+
id: z.ZodNumber;
|
|
123
|
+
uuid: z.ZodOptional<z.ZodString>;
|
|
124
|
+
name: z.ZodString;
|
|
125
|
+
organization: z.ZodOptional<z.ZodString>;
|
|
126
|
+
created_at: z.ZodOptional<z.ZodString>;
|
|
127
|
+
timezone: z.ZodOptional<z.ZodString>;
|
|
128
|
+
is_demo: z.ZodOptional<z.ZodBoolean>;
|
|
129
|
+
}, "strip", z.ZodTypeAny, {
|
|
130
|
+
id: number;
|
|
131
|
+
name: string;
|
|
132
|
+
uuid?: string | undefined;
|
|
133
|
+
created_at?: string | undefined;
|
|
134
|
+
organization?: string | undefined;
|
|
135
|
+
timezone?: string | undefined;
|
|
136
|
+
is_demo?: boolean | undefined;
|
|
137
|
+
}, {
|
|
138
|
+
id: number;
|
|
139
|
+
name: string;
|
|
140
|
+
uuid?: string | undefined;
|
|
141
|
+
created_at?: string | undefined;
|
|
142
|
+
organization?: string | undefined;
|
|
143
|
+
timezone?: string | undefined;
|
|
144
|
+
is_demo?: boolean | undefined;
|
|
114
145
|
}>;
|
|
115
146
|
export declare const PosthogParamsSchema: z.ZodDiscriminatedUnion<"operation", [z.ZodObject<{
|
|
147
|
+
operation: z.ZodLiteral<"list_projects">;
|
|
148
|
+
host: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
149
|
+
limit: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
150
|
+
credentials: z.ZodOptional<z.ZodRecord<z.ZodNativeEnum<typeof CredentialType>, z.ZodString>>;
|
|
151
|
+
}, "strip", z.ZodTypeAny, {
|
|
152
|
+
limit: number;
|
|
153
|
+
operation: "list_projects";
|
|
154
|
+
host: string;
|
|
155
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
156
|
+
}, {
|
|
157
|
+
operation: "list_projects";
|
|
158
|
+
limit?: number | undefined;
|
|
159
|
+
host?: string | undefined;
|
|
160
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
161
|
+
}>, z.ZodObject<{
|
|
116
162
|
operation: z.ZodLiteral<"list_events">;
|
|
117
163
|
project_id: z.ZodString;
|
|
118
164
|
host: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
@@ -125,29 +171,29 @@ export declare const PosthogParamsSchema: z.ZodDiscriminatedUnion<"operation", [
|
|
|
125
171
|
limit: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
126
172
|
credentials: z.ZodOptional<z.ZodRecord<z.ZodNativeEnum<typeof CredentialType>, z.ZodString>>;
|
|
127
173
|
}, "strip", z.ZodTypeAny, {
|
|
128
|
-
operation: "list_events";
|
|
129
174
|
limit: number;
|
|
130
|
-
|
|
175
|
+
operation: "list_events";
|
|
131
176
|
host: string;
|
|
177
|
+
project_id: string;
|
|
178
|
+
event?: string | undefined;
|
|
179
|
+
distinct_id?: string | undefined;
|
|
132
180
|
properties?: string | undefined;
|
|
133
181
|
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
134
|
-
event?: string | undefined;
|
|
135
182
|
person_id?: string | undefined;
|
|
136
183
|
after?: string | undefined;
|
|
137
184
|
before?: string | undefined;
|
|
138
|
-
distinct_id?: string | undefined;
|
|
139
185
|
}, {
|
|
140
186
|
operation: "list_events";
|
|
141
187
|
project_id: string;
|
|
188
|
+
event?: string | undefined;
|
|
189
|
+
distinct_id?: string | undefined;
|
|
142
190
|
properties?: string | undefined;
|
|
143
|
-
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
144
191
|
limit?: number | undefined;
|
|
145
|
-
|
|
192
|
+
host?: string | undefined;
|
|
193
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
146
194
|
person_id?: string | undefined;
|
|
147
195
|
after?: string | undefined;
|
|
148
196
|
before?: string | undefined;
|
|
149
|
-
distinct_id?: string | undefined;
|
|
150
|
-
host?: string | undefined;
|
|
151
197
|
}>, z.ZodObject<{
|
|
152
198
|
operation: z.ZodLiteral<"query">;
|
|
153
199
|
project_id: z.ZodString;
|
|
@@ -155,17 +201,17 @@ export declare const PosthogParamsSchema: z.ZodDiscriminatedUnion<"operation", [
|
|
|
155
201
|
query: z.ZodString;
|
|
156
202
|
credentials: z.ZodOptional<z.ZodRecord<z.ZodNativeEnum<typeof CredentialType>, z.ZodString>>;
|
|
157
203
|
}, "strip", z.ZodTypeAny, {
|
|
158
|
-
query: string;
|
|
159
204
|
operation: "query";
|
|
160
|
-
project_id: string;
|
|
161
205
|
host: string;
|
|
206
|
+
project_id: string;
|
|
207
|
+
query: string;
|
|
162
208
|
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
163
209
|
}, {
|
|
164
|
-
query: string;
|
|
165
210
|
operation: "query";
|
|
166
211
|
project_id: string;
|
|
167
|
-
|
|
212
|
+
query: string;
|
|
168
213
|
host?: string | undefined;
|
|
214
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
169
215
|
}>, z.ZodObject<{
|
|
170
216
|
operation: z.ZodLiteral<"get_person">;
|
|
171
217
|
project_id: z.ZodString;
|
|
@@ -175,21 +221,21 @@ export declare const PosthogParamsSchema: z.ZodDiscriminatedUnion<"operation", [
|
|
|
175
221
|
limit: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
176
222
|
credentials: z.ZodOptional<z.ZodRecord<z.ZodNativeEnum<typeof CredentialType>, z.ZodString>>;
|
|
177
223
|
}, "strip", z.ZodTypeAny, {
|
|
178
|
-
operation: "get_person";
|
|
179
224
|
limit: number;
|
|
180
|
-
|
|
225
|
+
operation: "get_person";
|
|
181
226
|
host: string;
|
|
182
|
-
|
|
183
|
-
search?: string | undefined;
|
|
227
|
+
project_id: string;
|
|
184
228
|
distinct_id?: string | undefined;
|
|
229
|
+
search?: string | undefined;
|
|
230
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
185
231
|
}, {
|
|
186
232
|
operation: "get_person";
|
|
187
233
|
project_id: string;
|
|
188
|
-
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
189
|
-
search?: string | undefined;
|
|
190
|
-
limit?: number | undefined;
|
|
191
234
|
distinct_id?: string | undefined;
|
|
235
|
+
limit?: number | undefined;
|
|
236
|
+
search?: string | undefined;
|
|
192
237
|
host?: string | undefined;
|
|
238
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
193
239
|
}>, z.ZodObject<{
|
|
194
240
|
operation: z.ZodLiteral<"get_insight">;
|
|
195
241
|
project_id: z.ZodString;
|
|
@@ -198,22 +244,81 @@ export declare const PosthogParamsSchema: z.ZodDiscriminatedUnion<"operation", [
|
|
|
198
244
|
credentials: z.ZodOptional<z.ZodRecord<z.ZodNativeEnum<typeof CredentialType>, z.ZodString>>;
|
|
199
245
|
}, "strip", z.ZodTypeAny, {
|
|
200
246
|
operation: "get_insight";
|
|
201
|
-
project_id: string;
|
|
202
247
|
host: string;
|
|
248
|
+
project_id: string;
|
|
203
249
|
insight_id: number;
|
|
204
250
|
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
205
251
|
}, {
|
|
206
252
|
operation: "get_insight";
|
|
207
253
|
project_id: string;
|
|
208
254
|
insight_id: number;
|
|
209
|
-
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
210
255
|
host?: string | undefined;
|
|
256
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
211
257
|
}>]>;
|
|
212
258
|
export declare const PosthogResultSchema: z.ZodDiscriminatedUnion<"operation", [z.ZodObject<{
|
|
259
|
+
operation: z.ZodLiteral<"list_projects">;
|
|
260
|
+
success: z.ZodBoolean;
|
|
261
|
+
projects: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
262
|
+
id: z.ZodNumber;
|
|
263
|
+
uuid: z.ZodOptional<z.ZodString>;
|
|
264
|
+
name: z.ZodString;
|
|
265
|
+
organization: z.ZodOptional<z.ZodString>;
|
|
266
|
+
created_at: z.ZodOptional<z.ZodString>;
|
|
267
|
+
timezone: z.ZodOptional<z.ZodString>;
|
|
268
|
+
is_demo: z.ZodOptional<z.ZodBoolean>;
|
|
269
|
+
}, "strip", z.ZodTypeAny, {
|
|
270
|
+
id: number;
|
|
271
|
+
name: string;
|
|
272
|
+
uuid?: string | undefined;
|
|
273
|
+
created_at?: string | undefined;
|
|
274
|
+
organization?: string | undefined;
|
|
275
|
+
timezone?: string | undefined;
|
|
276
|
+
is_demo?: boolean | undefined;
|
|
277
|
+
}, {
|
|
278
|
+
id: number;
|
|
279
|
+
name: string;
|
|
280
|
+
uuid?: string | undefined;
|
|
281
|
+
created_at?: string | undefined;
|
|
282
|
+
organization?: string | undefined;
|
|
283
|
+
timezone?: string | undefined;
|
|
284
|
+
is_demo?: boolean | undefined;
|
|
285
|
+
}>, "many">>;
|
|
286
|
+
next: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
287
|
+
error: z.ZodString;
|
|
288
|
+
}, "strip", z.ZodTypeAny, {
|
|
289
|
+
operation: "list_projects";
|
|
290
|
+
success: boolean;
|
|
291
|
+
error: string;
|
|
292
|
+
projects?: {
|
|
293
|
+
id: number;
|
|
294
|
+
name: string;
|
|
295
|
+
uuid?: string | undefined;
|
|
296
|
+
created_at?: string | undefined;
|
|
297
|
+
organization?: string | undefined;
|
|
298
|
+
timezone?: string | undefined;
|
|
299
|
+
is_demo?: boolean | undefined;
|
|
300
|
+
}[] | undefined;
|
|
301
|
+
next?: string | null | undefined;
|
|
302
|
+
}, {
|
|
303
|
+
operation: "list_projects";
|
|
304
|
+
success: boolean;
|
|
305
|
+
error: string;
|
|
306
|
+
projects?: {
|
|
307
|
+
id: number;
|
|
308
|
+
name: string;
|
|
309
|
+
uuid?: string | undefined;
|
|
310
|
+
created_at?: string | undefined;
|
|
311
|
+
organization?: string | undefined;
|
|
312
|
+
timezone?: string | undefined;
|
|
313
|
+
is_demo?: boolean | undefined;
|
|
314
|
+
}[] | undefined;
|
|
315
|
+
next?: string | null | undefined;
|
|
316
|
+
}>, z.ZodObject<{
|
|
213
317
|
operation: z.ZodLiteral<"list_events">;
|
|
214
318
|
success: z.ZodBoolean;
|
|
215
319
|
events: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
216
|
-
|
|
320
|
+
id: z.ZodOptional<z.ZodString>;
|
|
321
|
+
uuid: z.ZodOptional<z.ZodString>;
|
|
217
322
|
event: z.ZodString;
|
|
218
323
|
distinct_id: z.ZodString;
|
|
219
324
|
properties: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
@@ -222,80 +327,84 @@ export declare const PosthogResultSchema: z.ZodDiscriminatedUnion<"operation", [
|
|
|
222
327
|
elements: z.ZodOptional<z.ZodArray<z.ZodUnknown, "many">>;
|
|
223
328
|
elements_chain: z.ZodOptional<z.ZodString>;
|
|
224
329
|
}, "strip", z.ZodTypeAny, {
|
|
225
|
-
uuid: string;
|
|
226
330
|
event: string;
|
|
227
331
|
distinct_id: string;
|
|
332
|
+
id?: string | undefined;
|
|
333
|
+
uuid?: string | undefined;
|
|
228
334
|
properties?: Record<string, unknown> | undefined;
|
|
229
|
-
elements?: unknown[] | undefined;
|
|
230
335
|
timestamp?: string | undefined;
|
|
231
336
|
created_at?: string | undefined;
|
|
337
|
+
elements?: unknown[] | undefined;
|
|
232
338
|
elements_chain?: string | undefined;
|
|
233
339
|
}, {
|
|
234
|
-
uuid: string;
|
|
235
340
|
event: string;
|
|
236
341
|
distinct_id: string;
|
|
342
|
+
id?: string | undefined;
|
|
343
|
+
uuid?: string | undefined;
|
|
237
344
|
properties?: Record<string, unknown> | undefined;
|
|
238
|
-
elements?: unknown[] | undefined;
|
|
239
345
|
timestamp?: string | undefined;
|
|
240
346
|
created_at?: string | undefined;
|
|
347
|
+
elements?: unknown[] | undefined;
|
|
241
348
|
elements_chain?: string | undefined;
|
|
242
349
|
}>, "many">>;
|
|
243
350
|
next: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
244
351
|
error: z.ZodString;
|
|
245
352
|
}, "strip", z.ZodTypeAny, {
|
|
246
|
-
error: string;
|
|
247
|
-
success: boolean;
|
|
248
353
|
operation: "list_events";
|
|
354
|
+
success: boolean;
|
|
355
|
+
error: string;
|
|
356
|
+
next?: string | null | undefined;
|
|
249
357
|
events?: {
|
|
250
|
-
uuid: string;
|
|
251
358
|
event: string;
|
|
252
359
|
distinct_id: string;
|
|
360
|
+
id?: string | undefined;
|
|
361
|
+
uuid?: string | undefined;
|
|
253
362
|
properties?: Record<string, unknown> | undefined;
|
|
254
|
-
elements?: unknown[] | undefined;
|
|
255
363
|
timestamp?: string | undefined;
|
|
256
364
|
created_at?: string | undefined;
|
|
365
|
+
elements?: unknown[] | undefined;
|
|
257
366
|
elements_chain?: string | undefined;
|
|
258
367
|
}[] | undefined;
|
|
259
|
-
next?: string | null | undefined;
|
|
260
368
|
}, {
|
|
261
|
-
error: string;
|
|
262
|
-
success: boolean;
|
|
263
369
|
operation: "list_events";
|
|
370
|
+
success: boolean;
|
|
371
|
+
error: string;
|
|
372
|
+
next?: string | null | undefined;
|
|
264
373
|
events?: {
|
|
265
|
-
uuid: string;
|
|
266
374
|
event: string;
|
|
267
375
|
distinct_id: string;
|
|
376
|
+
id?: string | undefined;
|
|
377
|
+
uuid?: string | undefined;
|
|
268
378
|
properties?: Record<string, unknown> | undefined;
|
|
269
|
-
elements?: unknown[] | undefined;
|
|
270
379
|
timestamp?: string | undefined;
|
|
271
380
|
created_at?: string | undefined;
|
|
381
|
+
elements?: unknown[] | undefined;
|
|
272
382
|
elements_chain?: string | undefined;
|
|
273
383
|
}[] | undefined;
|
|
274
|
-
next?: string | null | undefined;
|
|
275
384
|
}>, z.ZodObject<{
|
|
276
385
|
operation: z.ZodLiteral<"query">;
|
|
277
386
|
success: z.ZodBoolean;
|
|
278
387
|
columns: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
279
388
|
results: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodUnknown, "many">, "many">>;
|
|
280
|
-
types: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
281
|
-
hasMore: z.ZodOptional<z.ZodBoolean
|
|
389
|
+
types: z.ZodOptional<z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>, "many">>;
|
|
390
|
+
hasMore: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
282
391
|
error: z.ZodString;
|
|
283
392
|
}, "strip", z.ZodTypeAny, {
|
|
284
|
-
error: string;
|
|
285
|
-
success: boolean;
|
|
286
393
|
operation: "query";
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
results?: unknown[][] | undefined;
|
|
394
|
+
success: boolean;
|
|
395
|
+
error: string;
|
|
290
396
|
columns?: string[] | undefined;
|
|
397
|
+
results?: unknown[][] | undefined;
|
|
398
|
+
types?: (string | string[])[] | undefined;
|
|
399
|
+
hasMore?: boolean | null | undefined;
|
|
291
400
|
}, {
|
|
292
|
-
error: string;
|
|
293
|
-
success: boolean;
|
|
294
401
|
operation: "query";
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
results?: unknown[][] | undefined;
|
|
402
|
+
success: boolean;
|
|
403
|
+
error: string;
|
|
298
404
|
columns?: string[] | undefined;
|
|
405
|
+
results?: unknown[][] | undefined;
|
|
406
|
+
types?: (string | string[])[] | undefined;
|
|
407
|
+
hasMore?: boolean | null | undefined;
|
|
299
408
|
}>, z.ZodObject<{
|
|
300
409
|
operation: z.ZodLiteral<"get_person">;
|
|
301
410
|
success: z.ZodBoolean;
|
|
@@ -308,40 +417,40 @@ export declare const PosthogResultSchema: z.ZodDiscriminatedUnion<"operation", [
|
|
|
308
417
|
}, "strip", z.ZodTypeAny, {
|
|
309
418
|
id: string;
|
|
310
419
|
distinct_ids: string[];
|
|
311
|
-
properties?: Record<string, unknown> | undefined;
|
|
312
420
|
uuid?: string | undefined;
|
|
421
|
+
properties?: Record<string, unknown> | undefined;
|
|
313
422
|
created_at?: string | undefined;
|
|
314
423
|
}, {
|
|
315
424
|
id: string;
|
|
316
425
|
distinct_ids: string[];
|
|
317
|
-
properties?: Record<string, unknown> | undefined;
|
|
318
426
|
uuid?: string | undefined;
|
|
427
|
+
properties?: Record<string, unknown> | undefined;
|
|
319
428
|
created_at?: string | undefined;
|
|
320
429
|
}>, "many">>;
|
|
321
430
|
next: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
322
431
|
error: z.ZodString;
|
|
323
432
|
}, "strip", z.ZodTypeAny, {
|
|
324
|
-
error: string;
|
|
325
|
-
success: boolean;
|
|
326
433
|
operation: "get_person";
|
|
434
|
+
success: boolean;
|
|
435
|
+
error: string;
|
|
327
436
|
next?: string | null | undefined;
|
|
328
437
|
persons?: {
|
|
329
438
|
id: string;
|
|
330
439
|
distinct_ids: string[];
|
|
331
|
-
properties?: Record<string, unknown> | undefined;
|
|
332
440
|
uuid?: string | undefined;
|
|
441
|
+
properties?: Record<string, unknown> | undefined;
|
|
333
442
|
created_at?: string | undefined;
|
|
334
443
|
}[] | undefined;
|
|
335
444
|
}, {
|
|
336
|
-
error: string;
|
|
337
|
-
success: boolean;
|
|
338
445
|
operation: "get_person";
|
|
446
|
+
success: boolean;
|
|
447
|
+
error: string;
|
|
339
448
|
next?: string | null | undefined;
|
|
340
449
|
persons?: {
|
|
341
450
|
id: string;
|
|
342
451
|
distinct_ids: string[];
|
|
343
|
-
properties?: Record<string, unknown> | undefined;
|
|
344
452
|
uuid?: string | undefined;
|
|
453
|
+
properties?: Record<string, unknown> | undefined;
|
|
345
454
|
created_at?: string | undefined;
|
|
346
455
|
}[] | undefined;
|
|
347
456
|
}>, z.ZodObject<{
|
|
@@ -360,52 +469,52 @@ export declare const PosthogResultSchema: z.ZodDiscriminatedUnion<"operation", [
|
|
|
360
469
|
}, "strip", z.ZodTypeAny, {
|
|
361
470
|
id: number;
|
|
362
471
|
description?: string | null | undefined;
|
|
472
|
+
created_at?: string | undefined;
|
|
473
|
+
short_id?: string | undefined;
|
|
363
474
|
name?: string | null | undefined;
|
|
364
475
|
result?: unknown;
|
|
365
|
-
created_at?: string | undefined;
|
|
366
476
|
filters?: Record<string, unknown> | undefined;
|
|
367
|
-
short_id?: string | undefined;
|
|
368
477
|
last_refresh?: string | null | undefined;
|
|
369
478
|
last_modified_at?: string | undefined;
|
|
370
479
|
}, {
|
|
371
480
|
id: number;
|
|
372
481
|
description?: string | null | undefined;
|
|
482
|
+
created_at?: string | undefined;
|
|
483
|
+
short_id?: string | undefined;
|
|
373
484
|
name?: string | null | undefined;
|
|
374
485
|
result?: unknown;
|
|
375
|
-
created_at?: string | undefined;
|
|
376
486
|
filters?: Record<string, unknown> | undefined;
|
|
377
|
-
short_id?: string | undefined;
|
|
378
487
|
last_refresh?: string | null | undefined;
|
|
379
488
|
last_modified_at?: string | undefined;
|
|
380
489
|
}>>;
|
|
381
490
|
error: z.ZodString;
|
|
382
491
|
}, "strip", z.ZodTypeAny, {
|
|
383
|
-
error: string;
|
|
384
|
-
success: boolean;
|
|
385
492
|
operation: "get_insight";
|
|
493
|
+
success: boolean;
|
|
494
|
+
error: string;
|
|
386
495
|
insight?: {
|
|
387
496
|
id: number;
|
|
388
497
|
description?: string | null | undefined;
|
|
498
|
+
created_at?: string | undefined;
|
|
499
|
+
short_id?: string | undefined;
|
|
389
500
|
name?: string | null | undefined;
|
|
390
501
|
result?: unknown;
|
|
391
|
-
created_at?: string | undefined;
|
|
392
502
|
filters?: Record<string, unknown> | undefined;
|
|
393
|
-
short_id?: string | undefined;
|
|
394
503
|
last_refresh?: string | null | undefined;
|
|
395
504
|
last_modified_at?: string | undefined;
|
|
396
505
|
} | undefined;
|
|
397
506
|
}, {
|
|
398
|
-
error: string;
|
|
399
|
-
success: boolean;
|
|
400
507
|
operation: "get_insight";
|
|
508
|
+
success: boolean;
|
|
509
|
+
error: string;
|
|
401
510
|
insight?: {
|
|
402
511
|
id: number;
|
|
403
512
|
description?: string | null | undefined;
|
|
513
|
+
created_at?: string | undefined;
|
|
514
|
+
short_id?: string | undefined;
|
|
404
515
|
name?: string | null | undefined;
|
|
405
516
|
result?: unknown;
|
|
406
|
-
created_at?: string | undefined;
|
|
407
517
|
filters?: Record<string, unknown> | undefined;
|
|
408
|
-
short_id?: string | undefined;
|
|
409
518
|
last_refresh?: string | null | undefined;
|
|
410
519
|
last_modified_at?: string | undefined;
|
|
411
520
|
} | undefined;
|
|
@@ -417,6 +526,10 @@ export type PosthogEvent = z.output<typeof PosthogEventSchema>;
|
|
|
417
526
|
export type PosthogPerson = z.output<typeof PosthogPersonSchema>;
|
|
418
527
|
export type PosthogInsight = z.output<typeof PosthogInsightSchema>;
|
|
419
528
|
export type PosthogQueryResult = z.output<typeof PosthogQueryResultSchema>;
|
|
529
|
+
export type PosthogProject = z.output<typeof PosthogProjectSchema>;
|
|
530
|
+
export type PosthogListProjectsParams = Extract<PosthogParams, {
|
|
531
|
+
operation: 'list_projects';
|
|
532
|
+
}>;
|
|
420
533
|
export type PosthogListEventsParams = Extract<PosthogParams, {
|
|
421
534
|
operation: 'list_events';
|
|
422
535
|
}>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"posthog.schema.d.ts","sourceRoot":"","sources":["../../../../src/bubbles/service-bubble/posthog/posthog.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAM3D;;GAEG;AACH,eAAO,MAAM,kBAAkB
|
|
1
|
+
{"version":3,"file":"posthog.schema.d.ts","sourceRoot":"","sources":["../../../../src/bubbles/service-bubble/posthog/posthog.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAM3D;;GAEG;AACH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAkBI,CAAC;AAEpC;;GAEG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;EAaI,CAAC;AAErC;;GAEG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA0BI,CAAC;AAEtC;;GAEG;AACH,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;EAsBJ,CAAC;AAElC;;GAEG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;EAUI,CAAC;AAMtC,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAuL9B,CAAC;AAMH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAgF9B,CAAC;AAOH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAGrE,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAGjE,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAGjE,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAC/D,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,mBAAmB,CAAC,CAAC;AACjE,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,oBAAoB,CAAC,CAAC;AACnE,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAC3E,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAGnE,MAAM,MAAM,yBAAyB,GAAG,OAAO,CAC7C,aAAa,EACb;IAAE,SAAS,EAAE,eAAe,CAAA;CAAE,CAC/B,CAAC;AACF,MAAM,MAAM,uBAAuB,GAAG,OAAO,CAC3C,aAAa,EACb;IAAE,SAAS,EAAE,aAAa,CAAA;CAAE,CAC7B,CAAC;AACF,MAAM,MAAM,kBAAkB,GAAG,OAAO,CACtC,aAAa,EACb;IAAE,SAAS,EAAE,OAAO,CAAA;CAAE,CACvB,CAAC;AACF,MAAM,MAAM,sBAAsB,GAAG,OAAO,CAC1C,aAAa,EACb;IAAE,SAAS,EAAE,YAAY,CAAA;CAAE,CAC5B,CAAC;AACF,MAAM,MAAM,uBAAuB,GAAG,OAAO,CAC3C,aAAa,EACb;IAAE,SAAS,EAAE,aAAa,CAAA;CAAE,CAC7B,CAAC"}
|
|
@@ -8,7 +8,8 @@ import { CredentialType } from '@bubblelab/shared-schemas';
|
|
|
8
8
|
*/
|
|
9
9
|
export const PosthogEventSchema = z
|
|
10
10
|
.object({
|
|
11
|
-
|
|
11
|
+
id: z.string().optional().describe('Event identifier (returned by API as id)'),
|
|
12
|
+
uuid: z.string().optional().describe('Unique event identifier (legacy field name)'),
|
|
12
13
|
event: z.string().describe('Event name (e.g., $pageview, user_signed_up)'),
|
|
13
14
|
distinct_id: z.string().describe('Distinct ID of the person'),
|
|
14
15
|
properties: z
|
|
@@ -85,21 +86,58 @@ export const PosthogQueryResultSchema = z
|
|
|
85
86
|
.optional()
|
|
86
87
|
.describe('Rows of query results'),
|
|
87
88
|
types: z
|
|
88
|
-
.array(z.string())
|
|
89
|
+
.array(z.union([z.string(), z.array(z.string())]))
|
|
89
90
|
.optional()
|
|
90
91
|
.describe('Column types in the result'),
|
|
91
92
|
hasMore: z
|
|
92
93
|
.boolean()
|
|
94
|
+
.nullable()
|
|
93
95
|
.optional()
|
|
94
96
|
.describe('Whether there are more rows available'),
|
|
95
97
|
limit: z.number().optional().describe('Number of rows returned'),
|
|
96
98
|
offset: z.number().optional().describe('Offset of the first row'),
|
|
97
99
|
})
|
|
98
100
|
.describe('HogQL query result');
|
|
101
|
+
/**
|
|
102
|
+
* PostHog project object from projects API
|
|
103
|
+
*/
|
|
104
|
+
export const PosthogProjectSchema = z
|
|
105
|
+
.object({
|
|
106
|
+
id: z.number().describe('Project ID (use this as project_id in other operations)'),
|
|
107
|
+
uuid: z.string().optional().describe('Project UUID'),
|
|
108
|
+
name: z.string().describe('Project name'),
|
|
109
|
+
organization: z.string().optional().describe('Organization ID'),
|
|
110
|
+
created_at: z.string().optional().describe('ISO 8601 creation timestamp'),
|
|
111
|
+
timezone: z.string().optional().describe('Project timezone (e.g., UTC)'),
|
|
112
|
+
is_demo: z.boolean().optional().describe('Whether this is a demo project'),
|
|
113
|
+
})
|
|
114
|
+
.describe('PostHog project record');
|
|
99
115
|
// ============================================================================
|
|
100
116
|
// PARAMETER SCHEMAS - Discriminated Union for Multiple Operations
|
|
101
117
|
// ============================================================================
|
|
102
118
|
export const PosthogParamsSchema = z.discriminatedUnion('operation', [
|
|
119
|
+
// List projects operation
|
|
120
|
+
z.object({
|
|
121
|
+
operation: z
|
|
122
|
+
.literal('list_projects')
|
|
123
|
+
.describe('List all projects accessible with your API key — use this to discover valid project_id values'),
|
|
124
|
+
host: z
|
|
125
|
+
.string()
|
|
126
|
+
.optional()
|
|
127
|
+
.default('https://us.posthog.com')
|
|
128
|
+
.describe('PostHog host URL (e.g., https://us.posthog.com, https://eu.posthog.com, or your self-hosted URL)'),
|
|
129
|
+
limit: z
|
|
130
|
+
.number()
|
|
131
|
+
.min(1)
|
|
132
|
+
.max(100)
|
|
133
|
+
.optional()
|
|
134
|
+
.default(100)
|
|
135
|
+
.describe('Maximum number of projects to return (1-100)'),
|
|
136
|
+
credentials: z
|
|
137
|
+
.record(z.nativeEnum(CredentialType), z.string())
|
|
138
|
+
.optional()
|
|
139
|
+
.describe('Object mapping credential types to values (injected at runtime)'),
|
|
140
|
+
}),
|
|
103
141
|
// List events operation
|
|
104
142
|
z.object({
|
|
105
143
|
operation: z
|
|
@@ -235,6 +273,21 @@ export const PosthogParamsSchema = z.discriminatedUnion('operation', [
|
|
|
235
273
|
// RESULT SCHEMAS - Discriminated Union for Operation Results
|
|
236
274
|
// ============================================================================
|
|
237
275
|
export const PosthogResultSchema = z.discriminatedUnion('operation', [
|
|
276
|
+
// List projects result
|
|
277
|
+
z.object({
|
|
278
|
+
operation: z.literal('list_projects').describe('List projects operation'),
|
|
279
|
+
success: z.boolean().describe('Whether the operation was successful'),
|
|
280
|
+
projects: z
|
|
281
|
+
.array(PosthogProjectSchema)
|
|
282
|
+
.optional()
|
|
283
|
+
.describe('List of projects'),
|
|
284
|
+
next: z
|
|
285
|
+
.string()
|
|
286
|
+
.optional()
|
|
287
|
+
.nullable()
|
|
288
|
+
.describe('URL for fetching the next page of results'),
|
|
289
|
+
error: z.string().describe('Error message if operation failed'),
|
|
290
|
+
}),
|
|
238
291
|
// List events result
|
|
239
292
|
z.object({
|
|
240
293
|
operation: z.literal('list_events').describe('List events operation'),
|
|
@@ -263,11 +316,12 @@ export const PosthogResultSchema = z.discriminatedUnion('operation', [
|
|
|
263
316
|
.optional()
|
|
264
317
|
.describe('Rows of query results'),
|
|
265
318
|
types: z
|
|
266
|
-
.array(z.string())
|
|
319
|
+
.array(z.union([z.string(), z.array(z.string())]))
|
|
267
320
|
.optional()
|
|
268
321
|
.describe('Column types in the result'),
|
|
269
322
|
hasMore: z
|
|
270
323
|
.boolean()
|
|
324
|
+
.nullable()
|
|
271
325
|
.optional()
|
|
272
326
|
.describe('Whether more rows are available'),
|
|
273
327
|
error: z.string().describe('Error message if operation failed'),
|