@bubblelab/bubble-core 0.1.9 → 0.1.10
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 +252 -1686
- package/dist/bubble-factory.d.ts.map +1 -1
- package/dist/bubble-factory.js +51 -19
- package/dist/bubble-factory.js.map +1 -1
- package/dist/bubble-flow/bubble-flow-class.d.ts +17 -1
- package/dist/bubble-flow/bubble-flow-class.d.ts.map +1 -1
- package/dist/bubble-flow/bubble-flow-class.js +16 -0
- package/dist/bubble-flow/bubble-flow-class.js.map +1 -1
- package/dist/bubble-flow/sample/data-analyst-flow.d.ts +1 -1
- package/dist/bubble-flow/sample/data-analyst-flow.d.ts.map +1 -1
- package/dist/bubble-flow/sample/error-ts.d.ts +1 -1
- package/dist/bubble-flow/sample/error-ts.d.ts.map +1 -1
- package/dist/bubble-flow/sample/sanitytest.d.ts +1 -1
- package/dist/bubble-flow/sample/sanitytest.d.ts.map +1 -1
- package/dist/bubble-flow/sample/simple-webhook-2.d.ts +1 -1
- package/dist/bubble-flow/sample/simple-webhook-2.d.ts.map +1 -1
- package/dist/bubble-flow/sample/simple-webhook.d.ts +1 -1
- package/dist/bubble-flow/sample/simple-webhook.d.ts.map +1 -1
- package/dist/bubble-flow/sample/simplified-data-analysis.flow.d.ts +1 -1
- package/dist/bubble-flow/sample/simplified-data-analysis.flow.d.ts.map +1 -1
- package/dist/bubble-flow/sample/slack-v0.1.d.ts +1 -1
- package/dist/bubble-flow/sample/slack-v0.1.d.ts.map +1 -1
- package/dist/bubble-flow/sample/slackagenttest.d.ts +1 -1
- package/dist/bubble-flow/sample/slackagenttest.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/ai-agent.d.ts +30 -30
- package/dist/bubbles/service-bubble/ai-agent.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/ai-agent.js +3 -1
- package/dist/bubbles/service-bubble/ai-agent.js.map +1 -1
- package/dist/bubbles/service-bubble/apify/actors/instagram-hashtag-scraper.d.ts +34 -34
- package/dist/bubbles/service-bubble/apify/actors/instagram-scraper.d.ts +42 -42
- package/dist/bubbles/service-bubble/apify/actors/linkedin-posts-search.d.ts +21 -21
- package/dist/bubbles/service-bubble/apify/actors/linkedin-profile-posts.d.ts +6 -6
- package/dist/bubbles/service-bubble/apify/actors/youtube-scraper.d.ts +184 -0
- package/dist/bubbles/service-bubble/apify/actors/youtube-scraper.d.ts.map +1 -0
- package/dist/bubbles/service-bubble/apify/actors/youtube-scraper.js +145 -0
- package/dist/bubbles/service-bubble/apify/actors/youtube-scraper.js.map +1 -0
- package/dist/bubbles/service-bubble/apify/actors/youtube-transcript-scraper.d.ts +52 -0
- package/dist/bubbles/service-bubble/apify/actors/youtube-transcript-scraper.d.ts.map +1 -0
- package/dist/bubbles/service-bubble/apify/actors/youtube-transcript-scraper.js +29 -0
- package/dist/bubbles/service-bubble/apify/actors/youtube-transcript-scraper.js.map +1 -0
- package/dist/bubbles/service-bubble/apify/apify-scraper.schema.d.ts +338 -109
- package/dist/bubbles/service-bubble/apify/apify-scraper.schema.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/apify/apify-scraper.schema.js +16 -0
- package/dist/bubbles/service-bubble/apify/apify-scraper.schema.js.map +1 -1
- package/dist/bubbles/service-bubble/apify/apify.d.ts +10 -10
- package/dist/bubbles/service-bubble/apify/index.d.ts +2 -0
- package/dist/bubbles/service-bubble/apify/index.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/apify/index.js +3 -0
- package/dist/bubbles/service-bubble/apify/index.js.map +1 -1
- package/dist/bubbles/service-bubble/apify/types.js +1 -2
- package/dist/bubbles/service-bubble/apify/types.js.map +1 -1
- package/dist/bubbles/service-bubble/gmail.d.ts +678 -184
- package/dist/bubbles/service-bubble/gmail.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/gmail.js +435 -7
- package/dist/bubbles/service-bubble/gmail.js.map +1 -1
- package/dist/bubbles/service-bubble/google-calendar.d.ts +60 -60
- package/dist/bubbles/service-bubble/google-drive.d.ts +301 -72
- package/dist/bubbles/service-bubble/google-drive.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/google-drive.js +65 -75
- package/dist/bubbles/service-bubble/google-drive.js.map +1 -1
- package/dist/bubbles/service-bubble/google-sheets.d.ts +76 -76
- package/dist/bubbles/service-bubble/hello-world.d.ts +4 -4
- package/dist/bubbles/service-bubble/hello-world.js +2 -2
- package/dist/bubbles/service-bubble/hello-world.js.map +1 -1
- package/dist/bubbles/service-bubble/http.d.ts +10 -10
- package/dist/bubbles/service-bubble/postgresql.d.ts +12 -12
- package/dist/bubbles/service-bubble/resend.d.ts +16 -16
- package/dist/bubbles/service-bubble/slack.d.ts +469 -469
- package/dist/bubbles/service-bubble/storage.d.ts +36 -36
- package/dist/bubbles/service-bubble/storage.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/storage.js +16 -5
- package/dist/bubbles/service-bubble/storage.js.map +1 -1
- package/dist/bubbles/service-bubble/x-twitter.d.ts +814 -0
- package/dist/bubbles/service-bubble/x-twitter.d.ts.map +1 -0
- package/dist/bubbles/service-bubble/x-twitter.js +445 -0
- package/dist/bubbles/service-bubble/x-twitter.js.map +1 -0
- package/dist/bubbles/tool-bubble/bubbleflow-validation-tool.d.ts +20 -20
- package/dist/bubbles/tool-bubble/chart-js-tool.d.ts +10 -10
- package/dist/bubbles/tool-bubble/get-bubble-details-tool.d.ts.map +1 -1
- package/dist/bubbles/tool-bubble/get-bubble-details-tool.js +17 -9
- package/dist/bubbles/tool-bubble/get-bubble-details-tool.js.map +1 -1
- package/dist/bubbles/tool-bubble/instagram-tool.d.ts +86 -86
- package/dist/bubbles/tool-bubble/linkedin-tool.d.ts +134 -134
- package/dist/bubbles/tool-bubble/reddit-scrape-tool.d.ts +69 -64
- package/dist/bubbles/tool-bubble/reddit-scrape-tool.d.ts.map +1 -1
- package/dist/bubbles/tool-bubble/reddit-scrape-tool.js +97 -22
- package/dist/bubbles/tool-bubble/reddit-scrape-tool.js.map +1 -1
- package/dist/bubbles/tool-bubble/research-agent-tool.d.ts +6 -6
- package/dist/bubbles/tool-bubble/research-agent-tool.js +4 -4
- package/dist/bubbles/tool-bubble/research-agent-tool.js.map +1 -1
- package/dist/bubbles/tool-bubble/sql-query-tool.d.ts +8 -8
- package/dist/bubbles/tool-bubble/tool-template.d.ts +8 -8
- package/dist/bubbles/tool-bubble/web-crawl-tool.d.ts +10 -10
- package/dist/bubbles/tool-bubble/web-extract-tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/web-scrape-tool.d.ts +12 -12
- package/dist/bubbles/tool-bubble/web-search-tool.d.ts +11 -10
- package/dist/bubbles/tool-bubble/web-search-tool.d.ts.map +1 -1
- package/dist/bubbles/tool-bubble/web-search-tool.js +5 -1
- package/dist/bubbles/tool-bubble/web-search-tool.js.map +1 -1
- package/dist/bubbles/tool-bubble/youtube-tool.d.ts +394 -0
- package/dist/bubbles/tool-bubble/youtube-tool.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/youtube-tool.js +352 -0
- package/dist/bubbles/tool-bubble/youtube-tool.js.map +1 -0
- package/dist/bubbles/workflow-bubble/bubbleflow-generator.workflow.d.ts +47 -36
- package/dist/bubbles/workflow-bubble/bubbleflow-generator.workflow.d.ts.map +1 -1
- package/dist/bubbles/workflow-bubble/bubbleflow-generator.workflow.js +91 -65
- package/dist/bubbles/workflow-bubble/bubbleflow-generator.workflow.js.map +1 -1
- package/dist/bubbles/workflow-bubble/database-analyzer.workflow.d.ts +4 -4
- package/dist/bubbles/workflow-bubble/generate-document.workflow.d.ts +70 -70
- package/dist/bubbles/workflow-bubble/parse-document.workflow.d.ts +66 -66
- package/dist/bubbles/workflow-bubble/pdf-form-operations.workflow.d.ts +56 -56
- package/dist/bubbles/workflow-bubble/pdf-form-operations.workflow.d.ts.map +1 -1
- package/dist/bubbles/workflow-bubble/pdf-form-operations.workflow.js.map +1 -1
- package/dist/bubbles/workflow-bubble/pdf-ocr.workflow.d.ts +44 -44
- package/dist/bubbles/workflow-bubble/pdf-ocr.workflow.d.ts.map +1 -1
- package/dist/bubbles/workflow-bubble/pdf-ocr.workflow.js +1 -1
- package/dist/bubbles/workflow-bubble/pdf-ocr.workflow.js.map +1 -1
- package/dist/bubbles/workflow-bubble/slack-data-assistant.workflow.d.ts +32 -32
- package/dist/bubbles/workflow-bubble/slack-formatter-agent.d.ts +58 -58
- package/dist/bubbles/workflow-bubble/slack-notifier.workflow.d.ts +18 -18
- package/dist/bubbles.json +69 -54
- package/dist/index.d.ts +4 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/dist/logging/BubbleLogger.d.ts.map +1 -1
- package/dist/logging/BubbleLogger.js +20 -13
- package/dist/logging/BubbleLogger.js.map +1 -1
- package/dist/logging/StreamingBubbleLogger.d.ts.map +1 -1
- package/dist/logging/StreamingBubbleLogger.js +5 -5
- package/dist/logging/StreamingBubbleLogger.js.map +1 -1
- package/dist/test-gm.d.ts +10 -0
- package/dist/test-gm.d.ts.map +1 -0
- package/dist/test-gm.js +95 -0
- package/dist/test-gm.js.map +1 -0
- package/dist/types/base-bubble-class.d.ts +1 -1
- package/dist/types/base-bubble-class.d.ts.map +1 -1
- package/dist/types/base-bubble-class.js +29 -21
- package/dist/types/base-bubble-class.js.map +1 -1
- package/dist/types/bubble.d.ts +1 -10
- package/dist/types/bubble.d.ts.map +1 -1
- package/dist/types/bubble.js +1 -1
- package/dist/types/bubble.js.map +1 -1
- package/dist/types/service-bubble-class.d.ts +1 -1
- package/dist/types/service-bubble-class.d.ts.map +1 -1
- package/dist/types/tool-bubble-class.d.ts +1 -1
- package/dist/types/tool-bubble-class.d.ts.map +1 -1
- package/dist/types/tool-bubble-class.js +0 -2
- package/dist/types/tool-bubble-class.js.map +1 -1
- package/dist/types/workflow-bubble-class.d.ts +1 -1
- package/dist/types/workflow-bubble-class.d.ts.map +1 -1
- package/dist/utils/agent-formatter.d.ts.map +1 -1
- package/dist/utils/agent-formatter.js +2 -2
- package/dist/utils/agent-formatter.js.map +1 -1
- package/dist/utils/bubbleflow-validation.d.ts.map +1 -1
- package/dist/utils/bubbleflow-validation.js +89 -32
- package/dist/utils/bubbleflow-validation.js.map +1 -1
- package/dist/utils/error-sanitizer.d.ts +12 -0
- package/dist/utils/error-sanitizer.d.ts.map +1 -0
- package/dist/utils/error-sanitizer.js +77 -0
- package/dist/utils/error-sanitizer.js.map +1 -0
- package/package.json +4 -4
- package/dist/bubble-trigger/index.d.ts +0 -2
- package/dist/bubble-trigger/index.d.ts.map +0 -1
- package/dist/bubble-trigger/index.js +0 -2
- package/dist/bubble-trigger/index.js.map +0 -1
- package/dist/bubble-trigger/types.d.ts +0 -87
- package/dist/bubble-trigger/types.d.ts.map +0 -1
- package/dist/bubble-trigger/types.js +0 -14
- package/dist/bubble-trigger/types.js.map +0 -1
- package/dist/bubbles/service-bubble/apify/api-scraper.schema.d.ts +0 -370
- package/dist/bubbles/service-bubble/apify/api-scraper.schema.d.ts.map +0 -1
- package/dist/bubbles/service-bubble/apify/api-scraper.schema.js +0 -14
- package/dist/bubbles/service-bubble/apify/api-scraper.schema.js.map +0 -1
- package/dist/bubbles/service-bubble/apify.d.ts +0 -136
- package/dist/bubbles/service-bubble/apify.d.ts.map +0 -1
- package/dist/bubbles/service-bubble/apify.js +0 -282
- package/dist/bubbles/service-bubble/apify.js.map +0 -1
- package/dist/types/ai-models.d.ts +0 -4
- package/dist/types/ai-models.d.ts.map +0 -1
- package/dist/types/ai-models.js +0 -20
- package/dist/types/ai-models.js.map +0 -1
- package/dist/types/api-scraper.schema.d.ts +0 -453
- package/dist/types/api-scraper.schema.d.ts.map +0 -1
- package/dist/types/api-scraper.schema.js +0 -160
- package/dist/types/api-scraper.schema.js.map +0 -1
|
@@ -0,0 +1,394 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { ToolBubble } from '../../types/tool-bubble-class.js';
|
|
3
|
+
import type { BubbleContext } from '../../types/bubble.js';
|
|
4
|
+
import { CredentialType, type BubbleName } from '@bubblelab/shared-schemas';
|
|
5
|
+
declare const YouTubeVideoSchema: z.ZodObject<{
|
|
6
|
+
title: z.ZodNullable<z.ZodString>;
|
|
7
|
+
id: z.ZodNullable<z.ZodString>;
|
|
8
|
+
url: z.ZodNullable<z.ZodString>;
|
|
9
|
+
viewCount: z.ZodNullable<z.ZodNumber>;
|
|
10
|
+
likes: z.ZodNullable<z.ZodNumber>;
|
|
11
|
+
date: z.ZodNullable<z.ZodString>;
|
|
12
|
+
channelName: z.ZodNullable<z.ZodString>;
|
|
13
|
+
channelUrl: z.ZodNullable<z.ZodString>;
|
|
14
|
+
subscribers: z.ZodNullable<z.ZodNumber>;
|
|
15
|
+
duration: z.ZodNullable<z.ZodString>;
|
|
16
|
+
description: z.ZodNullable<z.ZodString>;
|
|
17
|
+
comments: z.ZodNullable<z.ZodNumber>;
|
|
18
|
+
thumbnail: z.ZodNullable<z.ZodString>;
|
|
19
|
+
}, "strip", z.ZodTypeAny, {
|
|
20
|
+
description: string | null;
|
|
21
|
+
title: string | null;
|
|
22
|
+
date: string | null;
|
|
23
|
+
url: string | null;
|
|
24
|
+
duration: string | null;
|
|
25
|
+
thumbnail: string | null;
|
|
26
|
+
id: string | null;
|
|
27
|
+
comments: number | null;
|
|
28
|
+
viewCount: number | null;
|
|
29
|
+
likes: number | null;
|
|
30
|
+
channelName: string | null;
|
|
31
|
+
channelUrl: string | null;
|
|
32
|
+
subscribers: number | null;
|
|
33
|
+
}, {
|
|
34
|
+
description: string | null;
|
|
35
|
+
title: string | null;
|
|
36
|
+
date: string | null;
|
|
37
|
+
url: string | null;
|
|
38
|
+
duration: string | null;
|
|
39
|
+
thumbnail: string | null;
|
|
40
|
+
id: string | null;
|
|
41
|
+
comments: number | null;
|
|
42
|
+
viewCount: number | null;
|
|
43
|
+
likes: number | null;
|
|
44
|
+
channelName: string | null;
|
|
45
|
+
channelUrl: string | null;
|
|
46
|
+
subscribers: number | null;
|
|
47
|
+
}>;
|
|
48
|
+
declare const YouTubeTranscriptSegmentSchema: z.ZodObject<{
|
|
49
|
+
start: z.ZodNullable<z.ZodString>;
|
|
50
|
+
duration: z.ZodNullable<z.ZodString>;
|
|
51
|
+
text: z.ZodNullable<z.ZodString>;
|
|
52
|
+
}, "strip", z.ZodTypeAny, {
|
|
53
|
+
duration: string | null;
|
|
54
|
+
text: string | null;
|
|
55
|
+
start: string | null;
|
|
56
|
+
}, {
|
|
57
|
+
duration: string | null;
|
|
58
|
+
text: string | null;
|
|
59
|
+
start: string | null;
|
|
60
|
+
}>;
|
|
61
|
+
declare const YouTubeToolParamsSchema: z.ZodObject<{
|
|
62
|
+
operation: z.ZodEnum<["searchVideos", "getTranscript", "scrapeChannel"]>;
|
|
63
|
+
searchQueries: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
64
|
+
videoUrls: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
65
|
+
channelUrl: z.ZodOptional<z.ZodString>;
|
|
66
|
+
videoUrl: z.ZodOptional<z.ZodString>;
|
|
67
|
+
maxResults: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
|
|
68
|
+
includeShorts: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
69
|
+
credentials: z.ZodOptional<z.ZodRecord<z.ZodNativeEnum<typeof CredentialType>, z.ZodString>>;
|
|
70
|
+
}, "strip", z.ZodTypeAny, {
|
|
71
|
+
operation: "searchVideos" | "getTranscript" | "scrapeChannel";
|
|
72
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
73
|
+
maxResults?: number | undefined;
|
|
74
|
+
videoUrl?: string | undefined;
|
|
75
|
+
searchQueries?: string[] | undefined;
|
|
76
|
+
channelUrl?: string | undefined;
|
|
77
|
+
videoUrls?: string[] | undefined;
|
|
78
|
+
includeShorts?: boolean | undefined;
|
|
79
|
+
}, {
|
|
80
|
+
operation: "searchVideos" | "getTranscript" | "scrapeChannel";
|
|
81
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
82
|
+
maxResults?: number | undefined;
|
|
83
|
+
videoUrl?: string | undefined;
|
|
84
|
+
searchQueries?: string[] | undefined;
|
|
85
|
+
channelUrl?: string | undefined;
|
|
86
|
+
videoUrls?: string[] | undefined;
|
|
87
|
+
includeShorts?: boolean | undefined;
|
|
88
|
+
}>;
|
|
89
|
+
declare const YouTubeToolResultSchema: z.ZodObject<{
|
|
90
|
+
operation: z.ZodEnum<["searchVideos", "getTranscript", "scrapeChannel"]>;
|
|
91
|
+
videos: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
92
|
+
title: z.ZodNullable<z.ZodString>;
|
|
93
|
+
id: z.ZodNullable<z.ZodString>;
|
|
94
|
+
url: z.ZodNullable<z.ZodString>;
|
|
95
|
+
viewCount: z.ZodNullable<z.ZodNumber>;
|
|
96
|
+
likes: z.ZodNullable<z.ZodNumber>;
|
|
97
|
+
date: z.ZodNullable<z.ZodString>;
|
|
98
|
+
channelName: z.ZodNullable<z.ZodString>;
|
|
99
|
+
channelUrl: z.ZodNullable<z.ZodString>;
|
|
100
|
+
subscribers: z.ZodNullable<z.ZodNumber>;
|
|
101
|
+
duration: z.ZodNullable<z.ZodString>;
|
|
102
|
+
description: z.ZodNullable<z.ZodString>;
|
|
103
|
+
comments: z.ZodNullable<z.ZodNumber>;
|
|
104
|
+
thumbnail: z.ZodNullable<z.ZodString>;
|
|
105
|
+
}, "strip", z.ZodTypeAny, {
|
|
106
|
+
description: string | null;
|
|
107
|
+
title: string | null;
|
|
108
|
+
date: string | null;
|
|
109
|
+
url: string | null;
|
|
110
|
+
duration: string | null;
|
|
111
|
+
thumbnail: string | null;
|
|
112
|
+
id: string | null;
|
|
113
|
+
comments: number | null;
|
|
114
|
+
viewCount: number | null;
|
|
115
|
+
likes: number | null;
|
|
116
|
+
channelName: string | null;
|
|
117
|
+
channelUrl: string | null;
|
|
118
|
+
subscribers: number | null;
|
|
119
|
+
}, {
|
|
120
|
+
description: string | null;
|
|
121
|
+
title: string | null;
|
|
122
|
+
date: string | null;
|
|
123
|
+
url: string | null;
|
|
124
|
+
duration: string | null;
|
|
125
|
+
thumbnail: string | null;
|
|
126
|
+
id: string | null;
|
|
127
|
+
comments: number | null;
|
|
128
|
+
viewCount: number | null;
|
|
129
|
+
likes: number | null;
|
|
130
|
+
channelName: string | null;
|
|
131
|
+
channelUrl: string | null;
|
|
132
|
+
subscribers: number | null;
|
|
133
|
+
}>, "many">>;
|
|
134
|
+
transcript: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
135
|
+
start: z.ZodNullable<z.ZodString>;
|
|
136
|
+
duration: z.ZodNullable<z.ZodString>;
|
|
137
|
+
text: z.ZodNullable<z.ZodString>;
|
|
138
|
+
}, "strip", z.ZodTypeAny, {
|
|
139
|
+
duration: string | null;
|
|
140
|
+
text: string | null;
|
|
141
|
+
start: string | null;
|
|
142
|
+
}, {
|
|
143
|
+
duration: string | null;
|
|
144
|
+
text: string | null;
|
|
145
|
+
start: string | null;
|
|
146
|
+
}>, "many">>;
|
|
147
|
+
fullTranscriptText: z.ZodOptional<z.ZodString>;
|
|
148
|
+
totalResults: z.ZodNumber;
|
|
149
|
+
success: z.ZodBoolean;
|
|
150
|
+
error: z.ZodString;
|
|
151
|
+
}, "strip", z.ZodTypeAny, {
|
|
152
|
+
success: boolean;
|
|
153
|
+
error: string;
|
|
154
|
+
operation: "searchVideos" | "getTranscript" | "scrapeChannel";
|
|
155
|
+
totalResults: number;
|
|
156
|
+
videos?: {
|
|
157
|
+
description: string | null;
|
|
158
|
+
title: string | null;
|
|
159
|
+
date: string | null;
|
|
160
|
+
url: string | null;
|
|
161
|
+
duration: string | null;
|
|
162
|
+
thumbnail: string | null;
|
|
163
|
+
id: string | null;
|
|
164
|
+
comments: number | null;
|
|
165
|
+
viewCount: number | null;
|
|
166
|
+
likes: number | null;
|
|
167
|
+
channelName: string | null;
|
|
168
|
+
channelUrl: string | null;
|
|
169
|
+
subscribers: number | null;
|
|
170
|
+
}[] | undefined;
|
|
171
|
+
transcript?: {
|
|
172
|
+
duration: string | null;
|
|
173
|
+
text: string | null;
|
|
174
|
+
start: string | null;
|
|
175
|
+
}[] | undefined;
|
|
176
|
+
fullTranscriptText?: string | undefined;
|
|
177
|
+
}, {
|
|
178
|
+
success: boolean;
|
|
179
|
+
error: string;
|
|
180
|
+
operation: "searchVideos" | "getTranscript" | "scrapeChannel";
|
|
181
|
+
totalResults: number;
|
|
182
|
+
videos?: {
|
|
183
|
+
description: string | null;
|
|
184
|
+
title: string | null;
|
|
185
|
+
date: string | null;
|
|
186
|
+
url: string | null;
|
|
187
|
+
duration: string | null;
|
|
188
|
+
thumbnail: string | null;
|
|
189
|
+
id: string | null;
|
|
190
|
+
comments: number | null;
|
|
191
|
+
viewCount: number | null;
|
|
192
|
+
likes: number | null;
|
|
193
|
+
channelName: string | null;
|
|
194
|
+
channelUrl: string | null;
|
|
195
|
+
subscribers: number | null;
|
|
196
|
+
}[] | undefined;
|
|
197
|
+
transcript?: {
|
|
198
|
+
duration: string | null;
|
|
199
|
+
text: string | null;
|
|
200
|
+
start: string | null;
|
|
201
|
+
}[] | undefined;
|
|
202
|
+
fullTranscriptText?: string | undefined;
|
|
203
|
+
}>;
|
|
204
|
+
type YouTubeToolParams = z.output<typeof YouTubeToolParamsSchema>;
|
|
205
|
+
type YouTubeToolResult = z.output<typeof YouTubeToolResultSchema>;
|
|
206
|
+
type YouTubeToolParamsInput = z.input<typeof YouTubeToolParamsSchema>;
|
|
207
|
+
export type YouTubeVideo = z.output<typeof YouTubeVideoSchema>;
|
|
208
|
+
export type YouTubeTranscriptSegment = z.output<typeof YouTubeTranscriptSegmentSchema>;
|
|
209
|
+
/**
|
|
210
|
+
* Simple, dev-friendly YouTube tool
|
|
211
|
+
*
|
|
212
|
+
* Provides easy access to YouTube data through three operations:
|
|
213
|
+
* - searchVideos: Search YouTube or scrape video/channel/playlist URLs
|
|
214
|
+
* - getTranscript: Extract video transcripts with timestamps
|
|
215
|
+
* - scrapeChannel: Get all videos from a channel
|
|
216
|
+
*/
|
|
217
|
+
export declare class YouTubeTool extends ToolBubble<YouTubeToolParams, YouTubeToolResult> {
|
|
218
|
+
static readonly bubbleName: BubbleName;
|
|
219
|
+
static readonly schema: z.ZodObject<{
|
|
220
|
+
operation: z.ZodEnum<["searchVideos", "getTranscript", "scrapeChannel"]>;
|
|
221
|
+
searchQueries: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
222
|
+
videoUrls: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
223
|
+
channelUrl: z.ZodOptional<z.ZodString>;
|
|
224
|
+
videoUrl: z.ZodOptional<z.ZodString>;
|
|
225
|
+
maxResults: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
|
|
226
|
+
includeShorts: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
227
|
+
credentials: z.ZodOptional<z.ZodRecord<z.ZodNativeEnum<typeof CredentialType>, z.ZodString>>;
|
|
228
|
+
}, "strip", z.ZodTypeAny, {
|
|
229
|
+
operation: "searchVideos" | "getTranscript" | "scrapeChannel";
|
|
230
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
231
|
+
maxResults?: number | undefined;
|
|
232
|
+
videoUrl?: string | undefined;
|
|
233
|
+
searchQueries?: string[] | undefined;
|
|
234
|
+
channelUrl?: string | undefined;
|
|
235
|
+
videoUrls?: string[] | undefined;
|
|
236
|
+
includeShorts?: boolean | undefined;
|
|
237
|
+
}, {
|
|
238
|
+
operation: "searchVideos" | "getTranscript" | "scrapeChannel";
|
|
239
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
240
|
+
maxResults?: number | undefined;
|
|
241
|
+
videoUrl?: string | undefined;
|
|
242
|
+
searchQueries?: string[] | undefined;
|
|
243
|
+
channelUrl?: string | undefined;
|
|
244
|
+
videoUrls?: string[] | undefined;
|
|
245
|
+
includeShorts?: boolean | undefined;
|
|
246
|
+
}>;
|
|
247
|
+
static readonly resultSchema: z.ZodObject<{
|
|
248
|
+
operation: z.ZodEnum<["searchVideos", "getTranscript", "scrapeChannel"]>;
|
|
249
|
+
videos: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
250
|
+
title: z.ZodNullable<z.ZodString>;
|
|
251
|
+
id: z.ZodNullable<z.ZodString>;
|
|
252
|
+
url: z.ZodNullable<z.ZodString>;
|
|
253
|
+
viewCount: z.ZodNullable<z.ZodNumber>;
|
|
254
|
+
likes: z.ZodNullable<z.ZodNumber>;
|
|
255
|
+
date: z.ZodNullable<z.ZodString>;
|
|
256
|
+
channelName: z.ZodNullable<z.ZodString>;
|
|
257
|
+
channelUrl: z.ZodNullable<z.ZodString>;
|
|
258
|
+
subscribers: z.ZodNullable<z.ZodNumber>;
|
|
259
|
+
duration: z.ZodNullable<z.ZodString>;
|
|
260
|
+
description: z.ZodNullable<z.ZodString>;
|
|
261
|
+
comments: z.ZodNullable<z.ZodNumber>;
|
|
262
|
+
thumbnail: z.ZodNullable<z.ZodString>;
|
|
263
|
+
}, "strip", z.ZodTypeAny, {
|
|
264
|
+
description: string | null;
|
|
265
|
+
title: string | null;
|
|
266
|
+
date: string | null;
|
|
267
|
+
url: string | null;
|
|
268
|
+
duration: string | null;
|
|
269
|
+
thumbnail: string | null;
|
|
270
|
+
id: string | null;
|
|
271
|
+
comments: number | null;
|
|
272
|
+
viewCount: number | null;
|
|
273
|
+
likes: number | null;
|
|
274
|
+
channelName: string | null;
|
|
275
|
+
channelUrl: string | null;
|
|
276
|
+
subscribers: number | null;
|
|
277
|
+
}, {
|
|
278
|
+
description: string | null;
|
|
279
|
+
title: string | null;
|
|
280
|
+
date: string | null;
|
|
281
|
+
url: string | null;
|
|
282
|
+
duration: string | null;
|
|
283
|
+
thumbnail: string | null;
|
|
284
|
+
id: string | null;
|
|
285
|
+
comments: number | null;
|
|
286
|
+
viewCount: number | null;
|
|
287
|
+
likes: number | null;
|
|
288
|
+
channelName: string | null;
|
|
289
|
+
channelUrl: string | null;
|
|
290
|
+
subscribers: number | null;
|
|
291
|
+
}>, "many">>;
|
|
292
|
+
transcript: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
293
|
+
start: z.ZodNullable<z.ZodString>;
|
|
294
|
+
duration: z.ZodNullable<z.ZodString>;
|
|
295
|
+
text: z.ZodNullable<z.ZodString>;
|
|
296
|
+
}, "strip", z.ZodTypeAny, {
|
|
297
|
+
duration: string | null;
|
|
298
|
+
text: string | null;
|
|
299
|
+
start: string | null;
|
|
300
|
+
}, {
|
|
301
|
+
duration: string | null;
|
|
302
|
+
text: string | null;
|
|
303
|
+
start: string | null;
|
|
304
|
+
}>, "many">>;
|
|
305
|
+
fullTranscriptText: z.ZodOptional<z.ZodString>;
|
|
306
|
+
totalResults: z.ZodNumber;
|
|
307
|
+
success: z.ZodBoolean;
|
|
308
|
+
error: z.ZodString;
|
|
309
|
+
}, "strip", z.ZodTypeAny, {
|
|
310
|
+
success: boolean;
|
|
311
|
+
error: string;
|
|
312
|
+
operation: "searchVideos" | "getTranscript" | "scrapeChannel";
|
|
313
|
+
totalResults: number;
|
|
314
|
+
videos?: {
|
|
315
|
+
description: string | null;
|
|
316
|
+
title: string | null;
|
|
317
|
+
date: string | null;
|
|
318
|
+
url: string | null;
|
|
319
|
+
duration: string | null;
|
|
320
|
+
thumbnail: string | null;
|
|
321
|
+
id: string | null;
|
|
322
|
+
comments: number | null;
|
|
323
|
+
viewCount: number | null;
|
|
324
|
+
likes: number | null;
|
|
325
|
+
channelName: string | null;
|
|
326
|
+
channelUrl: string | null;
|
|
327
|
+
subscribers: number | null;
|
|
328
|
+
}[] | undefined;
|
|
329
|
+
transcript?: {
|
|
330
|
+
duration: string | null;
|
|
331
|
+
text: string | null;
|
|
332
|
+
start: string | null;
|
|
333
|
+
}[] | undefined;
|
|
334
|
+
fullTranscriptText?: string | undefined;
|
|
335
|
+
}, {
|
|
336
|
+
success: boolean;
|
|
337
|
+
error: string;
|
|
338
|
+
operation: "searchVideos" | "getTranscript" | "scrapeChannel";
|
|
339
|
+
totalResults: number;
|
|
340
|
+
videos?: {
|
|
341
|
+
description: string | null;
|
|
342
|
+
title: string | null;
|
|
343
|
+
date: string | null;
|
|
344
|
+
url: string | null;
|
|
345
|
+
duration: string | null;
|
|
346
|
+
thumbnail: string | null;
|
|
347
|
+
id: string | null;
|
|
348
|
+
comments: number | null;
|
|
349
|
+
viewCount: number | null;
|
|
350
|
+
likes: number | null;
|
|
351
|
+
channelName: string | null;
|
|
352
|
+
channelUrl: string | null;
|
|
353
|
+
subscribers: number | null;
|
|
354
|
+
}[] | undefined;
|
|
355
|
+
transcript?: {
|
|
356
|
+
duration: string | null;
|
|
357
|
+
text: string | null;
|
|
358
|
+
start: string | null;
|
|
359
|
+
}[] | undefined;
|
|
360
|
+
fullTranscriptText?: string | undefined;
|
|
361
|
+
}>;
|
|
362
|
+
static readonly shortDescription = "Search YouTube videos, extract transcripts, and scrape channel content with a simple interface";
|
|
363
|
+
static readonly longDescription = "\n Universal YouTube tool for video search, transcript extraction, and channel scraping.\n\n **OPERATIONS:**\n 1. **searchVideos**: Search YouTube or scrape specific URLs\n - Search by keywords\n - Scrape videos, channels, playlists, or hashtags\n - Get video metadata, views, likes, channel info\n\n 2. **getTranscript**: Extract video transcripts\n - Get timestamped transcript segments\n - Full transcript text available\n - Perfect for content analysis or subtitles\n\n 3. **scrapeChannel**: Get all videos from a channel\n - Fetch recent videos from any channel\n - Sort by newest, popular, or oldest\n - Get comprehensive video data\n\n **WHEN TO USE THIS TOOL:**\n - YouTube video search and discovery\n - Content analysis and research\n - Transcript extraction for AI/ML\n - Channel monitoring and tracking\n - Video metadata collection\n\n **Simple Interface:**\n Just specify the operation and provide search terms or URLs.\n The tool handles service selection, data transformation, and error handling.\n\n **What you get:**\n - Clean, structured video data\n - Timestamped transcripts\n - Channel and engagement metrics\n - Ready for analysis or processing\n ";
|
|
364
|
+
static readonly alias = "yt";
|
|
365
|
+
static readonly type = "tool";
|
|
366
|
+
constructor(params?: YouTubeToolParamsInput, context?: BubbleContext);
|
|
367
|
+
performAction(): Promise<YouTubeToolResult>;
|
|
368
|
+
/**
|
|
369
|
+
* Create error result
|
|
370
|
+
*/
|
|
371
|
+
private createErrorResult;
|
|
372
|
+
/**
|
|
373
|
+
* Handle searchVideos operation
|
|
374
|
+
*/
|
|
375
|
+
private handleSearchVideos;
|
|
376
|
+
/**
|
|
377
|
+
* Handle getTranscript operation
|
|
378
|
+
*/
|
|
379
|
+
private handleGetTranscript;
|
|
380
|
+
/**
|
|
381
|
+
* Handle scrapeChannel operation
|
|
382
|
+
*/
|
|
383
|
+
private handleScrapeChannel;
|
|
384
|
+
/**
|
|
385
|
+
* Transform Apify video data to unified format
|
|
386
|
+
*/
|
|
387
|
+
private transformVideos;
|
|
388
|
+
/**
|
|
389
|
+
* Create empty video object
|
|
390
|
+
*/
|
|
391
|
+
private createEmptyVideo;
|
|
392
|
+
}
|
|
393
|
+
export {};
|
|
394
|
+
//# sourceMappingURL=youtube-tool.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"youtube-tool.d.ts","sourceRoot":"","sources":["../../../src/bubbles/tool-bubble/youtube-tool.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,UAAU,EAAE,MAAM,kCAAkC,CAAC;AAC9D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EAAE,cAAc,EAAE,KAAK,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAK5E,QAAA,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EActB,CAAC;AAEH,QAAA,MAAM,8BAA8B;;;;;;;;;;;;EAIlC,CAAC;AAGH,QAAA,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;EAsD3B,CAAC;AAGH,QAAA,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA0B3B,CAAC;AAGH,KAAK,iBAAiB,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAClE,KAAK,iBAAiB,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAClE,KAAK,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AACtE,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAC/D,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,MAAM,CAC7C,OAAO,8BAA8B,CACtC,CAAC;AAEF;;;;;;;GAOG;AACH,qBAAa,WAAY,SAAQ,UAAU,CACzC,iBAAiB,EACjB,iBAAiB,CAClB;IACC,MAAM,CAAC,QAAQ,CAAC,UAAU,EAAE,UAAU,CAAkB;IACxD,MAAM,CAAC,QAAQ,CAAC,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;OAA2B;IACjD,MAAM,CAAC,QAAQ,CAAC,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAA2B;IACvD,MAAM,CAAC,QAAQ,CAAC,gBAAgB,oGACmE;IACnG,MAAM,CAAC,QAAQ,CAAC,eAAe,wwCAmC7B;IACF,MAAM,CAAC,QAAQ,CAAC,KAAK,QAAQ;IAC7B,MAAM,CAAC,QAAQ,CAAC,IAAI,UAAU;gBAG5B,MAAM,GAAE,sBAIP,EACD,OAAO,CAAC,EAAE,aAAa;IAKnB,aAAa,IAAI,OAAO,CAAC,iBAAiB,CAAC;IAsDjD;;OAEG;IACH,OAAO,CAAC,iBAAiB;IAiBzB;;OAEG;YACW,kBAAkB;IAuChC;;OAEG;YACW,mBAAmB;IAqDjC;;OAEG;YACW,mBAAmB;IAoCjC;;OAEG;IACH,OAAO,CAAC,eAAe;IA4BvB;;OAEG;IACH,OAAO,CAAC,gBAAgB;CAiBzB"}
|