@bubblelab/bubble-core 0.1.141 → 0.1.143
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 +181 -118
- package/dist/bubble-factory.d.ts.map +1 -1
- package/dist/bubble-factory.js +9 -1
- package/dist/bubble-factory.js.map +1 -1
- package/dist/bubble-flow/bubble-flow-class.d.ts +4 -0
- package/dist/bubble-flow/bubble-flow-class.d.ts.map +1 -1
- package/dist/bubble-flow/bubble-flow-class.js +1 -0
- package/dist/bubble-flow/bubble-flow-class.js.map +1 -1
- package/dist/bubbles/service-bubble/agi-inc.d.ts +140 -140
- package/dist/bubbles/service-bubble/ai-agent.d.ts +4 -4
- package/dist/bubbles/service-bubble/ai-agent.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/ai-agent.js +7 -0
- package/dist/bubbles/service-bubble/ai-agent.js.map +1 -1
- package/dist/bubbles/service-bubble/airtable.d.ts +158 -158
- package/dist/bubbles/service-bubble/apify/actors/google-maps-scraper.d.ts +6 -6
- package/dist/bubbles/service-bubble/apify/actors/linkedin-profile-detail.d.ts +806 -0
- package/dist/bubbles/service-bubble/apify/actors/linkedin-profile-detail.d.ts.map +1 -0
- package/dist/bubbles/service-bubble/apify/actors/linkedin-profile-detail.js +256 -0
- package/dist/bubbles/service-bubble/apify/actors/linkedin-profile-detail.js.map +1 -0
- package/dist/bubbles/service-bubble/apify/apify-scraper.schema.d.ts +813 -6
- package/dist/bubbles/service-bubble/apify/apify-scraper.schema.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/apify/apify-scraper.schema.js +8 -0
- package/dist/bubbles/service-bubble/apify/apify-scraper.schema.js.map +1 -1
- package/dist/bubbles/service-bubble/apify/apify.d.ts +13 -13
- package/dist/bubbles/service-bubble/apify/apify.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/apify/apify.js +1 -0
- package/dist/bubbles/service-bubble/apify/apify.js.map +1 -1
- package/dist/bubbles/service-bubble/ashby/ashby.d.ts +64 -64
- package/dist/bubbles/service-bubble/ashby/ashby.schema.d.ts +6 -6
- package/dist/bubbles/service-bubble/browserbase/browserbase.d.ts +44 -37
- package/dist/bubbles/service-bubble/browserbase/browserbase.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/browserbase/browserbase.js +66 -3
- package/dist/bubbles/service-bubble/browserbase/browserbase.js.map +1 -1
- package/dist/bubbles/service-bubble/browserbase/browserbase.schema.d.ts +59 -16
- package/dist/bubbles/service-bubble/browserbase/browserbase.schema.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/browserbase/browserbase.schema.js +19 -0
- package/dist/bubbles/service-bubble/browserbase/browserbase.schema.js.map +1 -1
- package/dist/bubbles/service-bubble/confluence/confluence.d.ts +26 -26
- package/dist/bubbles/service-bubble/crustdata/crustdata.d.ts +96 -96
- package/dist/bubbles/service-bubble/crustdata/crustdata.schema.d.ts +24 -24
- package/dist/bubbles/service-bubble/eleven-labs.d.ts +24 -24
- package/dist/bubbles/service-bubble/firecrawl.d.ts +244 -244
- package/dist/bubbles/service-bubble/followupboss.d.ts +152 -152
- package/dist/bubbles/service-bubble/fullenrich/fullenrich.d.ts +44 -44
- package/dist/bubbles/service-bubble/fullenrich/fullenrich.schema.d.ts +62 -62
- package/dist/bubbles/service-bubble/github.d.ts +148 -148
- package/dist/bubbles/service-bubble/gmail.d.ts +556 -556
- package/dist/bubbles/service-bubble/google-calendar.d.ts +34 -34
- package/dist/bubbles/service-bubble/google-drive.d.ts +102 -102
- package/dist/bubbles/service-bubble/google-sheets/google-sheets.d.ts +30 -30
- package/dist/bubbles/service-bubble/http.d.ts +20 -20
- package/dist/bubbles/service-bubble/jira/jira.d.ts +92 -92
- package/dist/bubbles/service-bubble/jira/jira.schema.d.ts +2 -2
- package/dist/bubbles/service-bubble/notion/notion.d.ts +647 -647
- package/dist/bubbles/service-bubble/resend.d.ts +32 -32
- package/dist/bubbles/service-bubble/slack/slack.d.ts +496 -496
- package/dist/bubbles/service-bubble/slack/slack.js +2 -2
- package/dist/bubbles/service-bubble/slack/slack.js.map +1 -1
- package/dist/bubbles/service-bubble/storage.d.ts +20 -20
- package/dist/bubbles/service-bubble/stripe/stripe.d.ts +87 -87
- package/dist/bubbles/service-bubble/telegram.d.ts +108 -108
- package/dist/bubbles/tool-bubble/amazon-shopping-tool/amazon-shopping-tool.d.ts +18 -18
- package/dist/bubbles/tool-bubble/browser-tools/_shared/schema.d.ts +126 -0
- package/dist/bubbles/tool-bubble/browser-tools/_shared/schema.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/_shared/schema.js +34 -0
- package/dist/bubbles/tool-bubble/browser-tools/_shared/schema.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/_shared/utils.d.ts +22 -0
- package/dist/bubbles/tool-bubble/browser-tools/_shared/utils.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/_shared/utils.js +57 -0
- package/dist/bubbles/tool-bubble/browser-tools/_shared/utils.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/index.d.ts +5 -0
- package/dist/bubbles/tool-bubble/browser-tools/index.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/index.js +5 -0
- package/dist/bubbles/tool-bubble/browser-tools/index.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/index.d.ts +3 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/index.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/index.js +3 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/index.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/schema.d.ts +158 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/schema.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/schema.js +33 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/schema.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/tool.d.ts +161 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/tool.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/tool.js +310 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/tool.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/index.d.ts +3 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/index.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/index.js +3 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/index.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/schema.d.ts +165 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/schema.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/schema.js +45 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/schema.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/tool.d.ts +171 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/tool.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/tool.js +364 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-connection/tool.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/index.d.ts +3 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/index.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/index.js +3 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/index.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/schema.d.ts +160 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/schema.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/schema.js +24 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/schema.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/tool.d.ts +160 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/tool.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/tool.js +334 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-received-invitations/tool.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/index.d.ts +3 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/index.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/index.js +3 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/index.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/schema.d.ts +152 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/schema.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/schema.js +23 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/schema.js.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/tool.d.ts +155 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/tool.d.ts.map +1 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/tool.js +233 -0
- package/dist/bubbles/tool-bubble/browser-tools/linkedin-sent-invitations/tool.js.map +1 -0
- package/dist/bubbles/tool-bubble/bubbleflow-validation-tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/company-enrichment-tool.d.ts +64 -64
- package/dist/bubbles/tool-bubble/google-maps-tool.d.ts +16 -16
- package/dist/bubbles/tool-bubble/instagram-tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/linkedin-connection-tool/linkedin-connection-tool.d.ts +2 -2
- package/dist/bubbles/tool-bubble/linkedin-tool.d.ts +1634 -196
- package/dist/bubbles/tool-bubble/linkedin-tool.d.ts.map +1 -1
- package/dist/bubbles/tool-bubble/linkedin-tool.js +300 -56
- package/dist/bubbles/tool-bubble/linkedin-tool.js.map +1 -1
- package/dist/bubbles/tool-bubble/list-capabilities-tool.d.ts +8 -8
- package/dist/bubbles/tool-bubble/people-search-tool.d.ts +108 -108
- package/dist/bubbles/tool-bubble/reddit-scrape-tool.d.ts +10 -10
- package/dist/bubbles/tool-bubble/research-agent-tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/sql-query-tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/tiktok-tool.d.ts +24 -24
- package/dist/bubbles/tool-bubble/twitter-tool.d.ts +14 -14
- package/dist/bubbles/tool-bubble/web-crawl-tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/web-extract-tool.d.ts +4 -4
- package/dist/bubbles/tool-bubble/web-scrape-tool.d.ts +8 -8
- package/dist/bubbles/tool-bubble/web-search-tool.d.ts +2 -2
- package/dist/bubbles/tool-bubble/yc-scraper-tool.d.ts +32 -32
- package/dist/bubbles/tool-bubble/youtube-tool.d.ts +14 -14
- package/dist/bubbles/workflow-bubble/pdf-form-operations.workflow.d.ts +58 -58
- package/dist/bubbles/workflow-bubble/pdf-ocr.workflow.d.ts +16 -16
- package/dist/bubbles/workflow-bubble/slack-data-assistant.workflow.d.ts +2 -2
- package/dist/bubbles/workflow-bubble/slack-formatter-agent.d.ts +46 -46
- package/dist/bubbles.json +1148 -75
- package/dist/index.d.ts +4 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -1
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
import { ToolBubble } from '../../../../types/tool-bubble-class.js';
|
|
2
|
+
import type { BubbleContext } from '../../../../types/bubble.js';
|
|
3
|
+
import { CredentialType } from '@bubblelab/shared-schemas';
|
|
4
|
+
import { type LinkedInAcceptInvitationsToolParamsInput, type LinkedInAcceptInvitationsToolResult } from './schema.js';
|
|
5
|
+
export declare class LinkedInAcceptInvitationsTool<T extends LinkedInAcceptInvitationsToolParamsInput = LinkedInAcceptInvitationsToolParamsInput> extends ToolBubble<T, LinkedInAcceptInvitationsToolResult> {
|
|
6
|
+
static readonly bubbleName: "linkedin-accept-invitations-tool";
|
|
7
|
+
static readonly schema: import("zod").ZodObject<{
|
|
8
|
+
operation: import("zod").ZodLiteral<"accept_invitations">;
|
|
9
|
+
count: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodNumber>>;
|
|
10
|
+
credentials: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodNativeEnum<typeof CredentialType>, import("zod").ZodString>>;
|
|
11
|
+
proxy: import("zod").ZodOptional<import("zod").ZodDiscriminatedUnion<"type", [import("zod").ZodObject<{
|
|
12
|
+
type: import("zod").ZodLiteral<"none">;
|
|
13
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
14
|
+
type: "none";
|
|
15
|
+
}, {
|
|
16
|
+
type: "none";
|
|
17
|
+
}>, import("zod").ZodObject<{
|
|
18
|
+
type: import("zod").ZodLiteral<"browserbase">;
|
|
19
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
20
|
+
type: "browserbase";
|
|
21
|
+
}, {
|
|
22
|
+
type: "browserbase";
|
|
23
|
+
}>, import("zod").ZodObject<{
|
|
24
|
+
type: import("zod").ZodLiteral<"custom">;
|
|
25
|
+
proxy: import("zod").ZodObject<{
|
|
26
|
+
id: import("zod").ZodString;
|
|
27
|
+
server: import("zod").ZodString;
|
|
28
|
+
username: import("zod").ZodOptional<import("zod").ZodString>;
|
|
29
|
+
password: import("zod").ZodOptional<import("zod").ZodString>;
|
|
30
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
31
|
+
id: string;
|
|
32
|
+
server: string;
|
|
33
|
+
password?: string | undefined;
|
|
34
|
+
username?: string | undefined;
|
|
35
|
+
}, {
|
|
36
|
+
id: string;
|
|
37
|
+
server: string;
|
|
38
|
+
password?: string | undefined;
|
|
39
|
+
username?: string | undefined;
|
|
40
|
+
}>;
|
|
41
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
42
|
+
type: "custom";
|
|
43
|
+
proxy: {
|
|
44
|
+
id: string;
|
|
45
|
+
server: string;
|
|
46
|
+
password?: string | undefined;
|
|
47
|
+
username?: string | undefined;
|
|
48
|
+
};
|
|
49
|
+
}, {
|
|
50
|
+
type: "custom";
|
|
51
|
+
proxy: {
|
|
52
|
+
id: string;
|
|
53
|
+
server: string;
|
|
54
|
+
password?: string | undefined;
|
|
55
|
+
username?: string | undefined;
|
|
56
|
+
};
|
|
57
|
+
}>]>>;
|
|
58
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
59
|
+
operation: "accept_invitations";
|
|
60
|
+
count: number;
|
|
61
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
62
|
+
proxy?: {
|
|
63
|
+
type: "none";
|
|
64
|
+
} | {
|
|
65
|
+
type: "browserbase";
|
|
66
|
+
} | {
|
|
67
|
+
type: "custom";
|
|
68
|
+
proxy: {
|
|
69
|
+
id: string;
|
|
70
|
+
server: string;
|
|
71
|
+
password?: string | undefined;
|
|
72
|
+
username?: string | undefined;
|
|
73
|
+
};
|
|
74
|
+
} | undefined;
|
|
75
|
+
}, {
|
|
76
|
+
operation: "accept_invitations";
|
|
77
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
78
|
+
count?: number | undefined;
|
|
79
|
+
proxy?: {
|
|
80
|
+
type: "none";
|
|
81
|
+
} | {
|
|
82
|
+
type: "browserbase";
|
|
83
|
+
} | {
|
|
84
|
+
type: "custom";
|
|
85
|
+
proxy: {
|
|
86
|
+
id: string;
|
|
87
|
+
server: string;
|
|
88
|
+
password?: string | undefined;
|
|
89
|
+
username?: string | undefined;
|
|
90
|
+
};
|
|
91
|
+
} | undefined;
|
|
92
|
+
}>;
|
|
93
|
+
static readonly resultSchema: import("zod").ZodObject<{
|
|
94
|
+
operation: import("zod").ZodLiteral<"accept_invitations">;
|
|
95
|
+
success: import("zod").ZodBoolean;
|
|
96
|
+
accepted: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
|
97
|
+
name: import("zod").ZodString;
|
|
98
|
+
headline: import("zod").ZodOptional<import("zod").ZodString>;
|
|
99
|
+
mutual_connections: import("zod").ZodOptional<import("zod").ZodString>;
|
|
100
|
+
profile_url: import("zod").ZodOptional<import("zod").ZodString>;
|
|
101
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
102
|
+
name: string;
|
|
103
|
+
headline?: string | undefined;
|
|
104
|
+
profile_url?: string | undefined;
|
|
105
|
+
mutual_connections?: string | undefined;
|
|
106
|
+
}, {
|
|
107
|
+
name: string;
|
|
108
|
+
headline?: string | undefined;
|
|
109
|
+
profile_url?: string | undefined;
|
|
110
|
+
mutual_connections?: string | undefined;
|
|
111
|
+
}>, "many">>;
|
|
112
|
+
accepted_count: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
113
|
+
skipped_count: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
114
|
+
message: import("zod").ZodOptional<import("zod").ZodString>;
|
|
115
|
+
error: import("zod").ZodString;
|
|
116
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
117
|
+
operation: "accept_invitations";
|
|
118
|
+
error: string;
|
|
119
|
+
success: boolean;
|
|
120
|
+
message?: string | undefined;
|
|
121
|
+
accepted?: {
|
|
122
|
+
name: string;
|
|
123
|
+
headline?: string | undefined;
|
|
124
|
+
profile_url?: string | undefined;
|
|
125
|
+
mutual_connections?: string | undefined;
|
|
126
|
+
}[] | undefined;
|
|
127
|
+
accepted_count?: number | undefined;
|
|
128
|
+
skipped_count?: number | undefined;
|
|
129
|
+
}, {
|
|
130
|
+
operation: "accept_invitations";
|
|
131
|
+
error: string;
|
|
132
|
+
success: boolean;
|
|
133
|
+
message?: string | undefined;
|
|
134
|
+
accepted?: {
|
|
135
|
+
name: string;
|
|
136
|
+
headline?: string | undefined;
|
|
137
|
+
profile_url?: string | undefined;
|
|
138
|
+
mutual_connections?: string | undefined;
|
|
139
|
+
}[] | undefined;
|
|
140
|
+
accepted_count?: number | undefined;
|
|
141
|
+
skipped_count?: number | undefined;
|
|
142
|
+
}>;
|
|
143
|
+
static readonly shortDescription = "Accept top N LinkedIn connection invitations";
|
|
144
|
+
static readonly longDescription = "Navigates to the LinkedIn invitation manager page and accepts the top N received connection invitations. Returns info about each accepted invitation.";
|
|
145
|
+
static readonly alias = "linkedin-accept-invitations";
|
|
146
|
+
static readonly type = "tool";
|
|
147
|
+
private sessionId;
|
|
148
|
+
private contextId;
|
|
149
|
+
private cookies;
|
|
150
|
+
constructor(params?: T, context?: BubbleContext);
|
|
151
|
+
protected chooseCredential(): string | undefined;
|
|
152
|
+
private stepStartBrowserSession;
|
|
153
|
+
private stepNavigateToInvitationManager;
|
|
154
|
+
private stepWaitForInvitationsPage;
|
|
155
|
+
private stepAcceptTopInvitations;
|
|
156
|
+
private stepEndBrowserSession;
|
|
157
|
+
private evaluate;
|
|
158
|
+
private detectIPAddress;
|
|
159
|
+
performAction(): Promise<LinkedInAcceptInvitationsToolResult>;
|
|
160
|
+
}
|
|
161
|
+
//# sourceMappingURL=tool.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tool.d.ts","sourceRoot":"","sources":["../../../../../src/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/tool.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,wCAAwC,CAAC;AACpE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAC;AAKjE,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAE3D,OAAO,EAGL,KAAK,wCAAwC,EAC7C,KAAK,mCAAmC,EAEzC,MAAM,aAAa,CAAC;AAErB,qBAAa,6BAA6B,CACxC,CAAC,SACC,wCAAwC,GAAG,wCAAwC,CACrF,SAAQ,UAAU,CAAC,CAAC,EAAE,mCAAmC,CAAC;IAC1D,MAAM,CAAC,QAAQ,CAAC,UAAU,EAAG,kCAAkC,CAAU;IACzE,MAAM,CAAC,QAAQ,CAAC,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAA6C;IACnE,MAAM,CAAC,QAAQ,CAAC,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAA6C;IACzE,MAAM,CAAC,QAAQ,CAAC,gBAAgB,kDACiB;IACjD,MAAM,CAAC,QAAQ,CAAC,eAAe,2JAC2H;IAC1J,MAAM,CAAC,QAAQ,CAAC,KAAK,iCAAiC;IACtD,MAAM,CAAC,QAAQ,CAAC,IAAI,UAAU;IAE9B,OAAO,CAAC,SAAS,CAAuB;IACxC,OAAO,CAAC,SAAS,CAAuB;IACxC,OAAO,CAAC,OAAO,CAA4B;gBAGzC,MAAM,GAAE,CAA4C,EACpD,OAAO,CAAC,EAAE,aAAa;IAKzB,SAAS,CAAC,gBAAgB,IAAI,MAAM,GAAG,SAAS;YAOlC,uBAAuB;YAgCvB,+BAA+B;YAkB/B,0BAA0B;YAqB1B,wBAAwB;YAkLxB,qBAAqB;YAYrB,QAAQ;YAaR,eAAe;IAiBvB,aAAa,IAAI,OAAO,CAAC,mCAAmC,CAAC;CA+BpE"}
|
|
@@ -0,0 +1,310 @@
|
|
|
1
|
+
import { ToolBubble } from '../../../../types/tool-bubble-class.js';
|
|
2
|
+
import { BrowserBaseBubble, } from '../../../service-bubble/browserbase/index.js';
|
|
3
|
+
import { CredentialType } from '@bubblelab/shared-schemas';
|
|
4
|
+
import { parseBrowserSessionData, buildProxyConfig } from '../_shared/utils.js';
|
|
5
|
+
import { LinkedInAcceptInvitationsToolParamsSchema, LinkedInAcceptInvitationsToolResultSchema, } from './schema.js';
|
|
6
|
+
export class LinkedInAcceptInvitationsTool extends ToolBubble {
|
|
7
|
+
static bubbleName = 'linkedin-accept-invitations-tool';
|
|
8
|
+
static schema = LinkedInAcceptInvitationsToolParamsSchema;
|
|
9
|
+
static resultSchema = LinkedInAcceptInvitationsToolResultSchema;
|
|
10
|
+
static shortDescription = 'Accept top N LinkedIn connection invitations';
|
|
11
|
+
static longDescription = 'Navigates to the LinkedIn invitation manager page and accepts the top N received connection invitations. Returns info about each accepted invitation.';
|
|
12
|
+
static alias = 'linkedin-accept-invitations';
|
|
13
|
+
static type = 'tool';
|
|
14
|
+
sessionId = null;
|
|
15
|
+
contextId = null;
|
|
16
|
+
cookies = null;
|
|
17
|
+
constructor(params = { operation: 'accept_invitations' }, context) {
|
|
18
|
+
super(params, context);
|
|
19
|
+
}
|
|
20
|
+
chooseCredential() {
|
|
21
|
+
const { credentials } = this.params;
|
|
22
|
+
return credentials?.[CredentialType.LINKEDIN_CRED];
|
|
23
|
+
}
|
|
24
|
+
async stepStartBrowserSession() {
|
|
25
|
+
if (this.sessionId)
|
|
26
|
+
return;
|
|
27
|
+
const sessionData = parseBrowserSessionData(this.chooseCredential());
|
|
28
|
+
if (sessionData) {
|
|
29
|
+
this.contextId = sessionData.contextId;
|
|
30
|
+
this.cookies = sessionData.cookies;
|
|
31
|
+
}
|
|
32
|
+
const proxyConfig = buildProxyConfig(this.params.proxy);
|
|
33
|
+
const browserbase = new BrowserBaseBubble({
|
|
34
|
+
operation: 'start_session',
|
|
35
|
+
context_id: this.contextId || undefined,
|
|
36
|
+
cookies: this.cookies || undefined,
|
|
37
|
+
credentials: this.params.credentials,
|
|
38
|
+
stealth: { solveCaptchas: true },
|
|
39
|
+
timeout_seconds: 600,
|
|
40
|
+
...proxyConfig,
|
|
41
|
+
}, this.context, 'startsession');
|
|
42
|
+
const result = await browserbase.action();
|
|
43
|
+
if (!result.data.success || !result.data.session_id) {
|
|
44
|
+
throw new Error(result.data.error || 'Failed to start browser session');
|
|
45
|
+
}
|
|
46
|
+
this.sessionId = result.data.session_id;
|
|
47
|
+
if (result.data.context_id)
|
|
48
|
+
this.contextId = result.data.context_id;
|
|
49
|
+
console.log(`[AcceptInvitations] Session started: ${this.sessionId}`);
|
|
50
|
+
const ip = await this.detectIPAddress();
|
|
51
|
+
if (ip)
|
|
52
|
+
console.log(`[AcceptInvitations] Browser IP: ${ip}`);
|
|
53
|
+
}
|
|
54
|
+
async stepNavigateToInvitationManager() {
|
|
55
|
+
if (!this.sessionId)
|
|
56
|
+
throw new Error('No active session');
|
|
57
|
+
const browserbase = new BrowserBaseBubble({
|
|
58
|
+
operation: 'navigate',
|
|
59
|
+
session_id: this.sessionId,
|
|
60
|
+
url: 'https://www.linkedin.com/mynetwork/invitation-manager/',
|
|
61
|
+
wait_until: 'domcontentloaded',
|
|
62
|
+
timeout: 30000,
|
|
63
|
+
}, this.context, 'navigate');
|
|
64
|
+
const result = await browserbase.action();
|
|
65
|
+
if (!result.data.success)
|
|
66
|
+
throw new Error(result.data.error || 'Navigation failed');
|
|
67
|
+
}
|
|
68
|
+
async stepWaitForInvitationsPage() {
|
|
69
|
+
const checkScript = `(() => {
|
|
70
|
+
const buttons = document.querySelectorAll('button');
|
|
71
|
+
let hasAcceptButton = false;
|
|
72
|
+
for (const btn of buttons) {
|
|
73
|
+
if ((btn.innerText || btn.textContent || '').trim().toLowerCase() === 'accept') {
|
|
74
|
+
hasAcceptButton = true;
|
|
75
|
+
break;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
const peopleLabel = document.body.innerText.match(/People\\s*\\(\\d+\\)/i);
|
|
79
|
+
return hasAcceptButton || !!peopleLabel;
|
|
80
|
+
})()`;
|
|
81
|
+
for (let attempt = 1; attempt <= 15; attempt++) {
|
|
82
|
+
const found = await this.evaluate(checkScript);
|
|
83
|
+
if (found)
|
|
84
|
+
return true;
|
|
85
|
+
await new Promise((r) => setTimeout(r, 1000));
|
|
86
|
+
}
|
|
87
|
+
return false;
|
|
88
|
+
}
|
|
89
|
+
async stepAcceptTopInvitations(count) {
|
|
90
|
+
const accepted = [];
|
|
91
|
+
let skipped = 0;
|
|
92
|
+
const TEMP_ID = '__bubblelab_accept_target__';
|
|
93
|
+
for (let i = 0; i < count; i++) {
|
|
94
|
+
// Step 1: Find first visible Accept button, extract card info, tag it with a temp ID
|
|
95
|
+
const extractResult = (await this.evaluate(`
|
|
96
|
+
(() => {
|
|
97
|
+
// Clean up any previous temp ID
|
|
98
|
+
const prev = document.getElementById('${TEMP_ID}');
|
|
99
|
+
if (prev) prev.removeAttribute('id');
|
|
100
|
+
|
|
101
|
+
const acceptButtons = Array.from(document.querySelectorAll('button')).filter(btn => {
|
|
102
|
+
const text = (btn.innerText || btn.textContent || '').trim().toLowerCase();
|
|
103
|
+
return text === 'accept' && btn.offsetParent !== null && !btn.disabled;
|
|
104
|
+
});
|
|
105
|
+
if (acceptButtons.length === 0) return { done: true, buttonCount: 0 };
|
|
106
|
+
|
|
107
|
+
const acceptBtn = acceptButtons[0];
|
|
108
|
+
|
|
109
|
+
// Tag the button with a temp ID so Puppeteer can click it precisely
|
|
110
|
+
acceptBtn.id = '${TEMP_ID}';
|
|
111
|
+
|
|
112
|
+
// Scroll the button into view
|
|
113
|
+
acceptBtn.scrollIntoView({ block: 'center', behavior: 'instant' });
|
|
114
|
+
|
|
115
|
+
// Walk up to find the invitation card container
|
|
116
|
+
let container = acceptBtn.parentElement;
|
|
117
|
+
for (let j = 0; j < 10 && container; j++) {
|
|
118
|
+
const text = container.innerText || '';
|
|
119
|
+
const hasProfileLink = !!container.querySelector('a[href*="/in/"]');
|
|
120
|
+
const hasTimeText = !!(text.match(/\\d+\\s+(hour|day|week|month|minute|second)s?\\s+ago/i) || text.match(/Yesterday/i));
|
|
121
|
+
if (hasProfileLink && hasTimeText) break;
|
|
122
|
+
container = container.parentElement;
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
let name = '';
|
|
126
|
+
let headline = '';
|
|
127
|
+
let mutual_connections = '';
|
|
128
|
+
let profile_url = '';
|
|
129
|
+
|
|
130
|
+
if (container) {
|
|
131
|
+
const links = container.querySelectorAll('a[href*="/in/"]');
|
|
132
|
+
for (const link of links) {
|
|
133
|
+
const href = link.getAttribute('href') || '';
|
|
134
|
+
if (href.includes('/in/')) {
|
|
135
|
+
profile_url = href.startsWith('http') ? href : 'https://www.linkedin.com' + href;
|
|
136
|
+
break;
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
for (const link of links) {
|
|
140
|
+
const linkText = (link.innerText || link.textContent || '').trim();
|
|
141
|
+
if (linkText && linkText.length > 1 && linkText.length < 100) {
|
|
142
|
+
name = linkText;
|
|
143
|
+
break;
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
if (!name) {
|
|
147
|
+
const spans = container.querySelectorAll('span');
|
|
148
|
+
for (const span of spans) {
|
|
149
|
+
const spanText = (span.innerText || span.textContent || '').trim();
|
|
150
|
+
if (spanText && spanText.length > 2 && spanText.length < 50 &&
|
|
151
|
+
!spanText.includes('Accept') && !spanText.includes('Ignore') &&
|
|
152
|
+
!spanText.includes('mutual') && !spanText.includes('ago') &&
|
|
153
|
+
!spanText.includes('Yesterday')) {
|
|
154
|
+
name = spanText;
|
|
155
|
+
break;
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
const containerText = container.innerText || '';
|
|
161
|
+
const mutualMatch = containerText.match(/(.+?(?:mutual connection|mutual connections))/i);
|
|
162
|
+
if (mutualMatch) mutual_connections = mutualMatch[0].trim();
|
|
163
|
+
|
|
164
|
+
const lines = containerText.split('\\n').map(l => l.trim()).filter(l => l);
|
|
165
|
+
let nameLineIdx = -1, endLineIdx = -1;
|
|
166
|
+
for (let k = 0; k < lines.length; k++) {
|
|
167
|
+
if (lines[k] === name) nameLineIdx = k;
|
|
168
|
+
if (endLineIdx === -1 && (
|
|
169
|
+
lines[k].match(/\\d+\\s+(hour|day|week|month|minute|second)s?\\s+ago/i) ||
|
|
170
|
+
lines[k].match(/Yesterday/i) ||
|
|
171
|
+
lines[k].match(/mutual connection/i)
|
|
172
|
+
)) endLineIdx = k;
|
|
173
|
+
}
|
|
174
|
+
if (nameLineIdx >= 0 && endLineIdx > nameLineIdx + 1) {
|
|
175
|
+
headline = lines.slice(nameLineIdx + 1, endLineIdx)
|
|
176
|
+
.filter(l => l.toLowerCase() !== 'accept' && l.toLowerCase() !== 'ignore' && l.length > 3)
|
|
177
|
+
.join(' ').trim();
|
|
178
|
+
}
|
|
179
|
+
if (!headline) {
|
|
180
|
+
for (const line of lines) {
|
|
181
|
+
if (line === name || line.toLowerCase() === 'accept' || line.toLowerCase() === 'ignore' ||
|
|
182
|
+
line.match(/\\d+\\s+(hour|day|week|month|minute|second)s?\\s+ago/i) ||
|
|
183
|
+
line.match(/Yesterday/i) || line.match(/mutual connection/i) ||
|
|
184
|
+
line.match(/^People\\s*\\(/i) || line.match(/^Message$/i)) continue;
|
|
185
|
+
if (line.length > 10 && line.length < 300) { headline = line; break; }
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
return {
|
|
191
|
+
done: false,
|
|
192
|
+
buttonCount: acceptButtons.length,
|
|
193
|
+
info: {
|
|
194
|
+
name: name || 'Unknown',
|
|
195
|
+
headline: headline || undefined,
|
|
196
|
+
mutual_connections: mutual_connections || undefined,
|
|
197
|
+
profile_url: profile_url || undefined,
|
|
198
|
+
}
|
|
199
|
+
};
|
|
200
|
+
})()
|
|
201
|
+
`));
|
|
202
|
+
if (extractResult.done) {
|
|
203
|
+
console.log(`[AcceptInvitations] No more invitations to accept after ${accepted.length}`);
|
|
204
|
+
break;
|
|
205
|
+
}
|
|
206
|
+
const prevButtonCount = extractResult.buttonCount;
|
|
207
|
+
// Step 2: Click the tagged button using BrowserBase (Puppeteer trusted click)
|
|
208
|
+
if (!this.sessionId)
|
|
209
|
+
throw new Error('No active session');
|
|
210
|
+
const clickBubble = new BrowserBaseBubble({
|
|
211
|
+
operation: 'click',
|
|
212
|
+
session_id: this.sessionId,
|
|
213
|
+
selector: `#${TEMP_ID}`,
|
|
214
|
+
wait_for_navigation: false,
|
|
215
|
+
timeout: 5000,
|
|
216
|
+
}, this.context, 'clickaccept');
|
|
217
|
+
const clickResult = await clickBubble.action();
|
|
218
|
+
if (!clickResult.data.success) {
|
|
219
|
+
console.log(`[AcceptInvitations] Click failed for invitation ${i + 1}, skipping`);
|
|
220
|
+
skipped++;
|
|
221
|
+
await new Promise((r) => setTimeout(r, 1000));
|
|
222
|
+
continue;
|
|
223
|
+
}
|
|
224
|
+
if (extractResult.info) {
|
|
225
|
+
accepted.push(extractResult.info);
|
|
226
|
+
console.log(`[AcceptInvitations] Accepted ${i + 1}/${count}: ${extractResult.info.name}`);
|
|
227
|
+
}
|
|
228
|
+
// Step 3: Wait for DOM to update — poll until Accept button count decreases
|
|
229
|
+
const MAX_WAIT_POLLS = 15;
|
|
230
|
+
for (let poll = 0; poll < MAX_WAIT_POLLS; poll++) {
|
|
231
|
+
await new Promise((r) => setTimeout(r, 500));
|
|
232
|
+
const currentCount = (await this.evaluate(`
|
|
233
|
+
Array.from(document.querySelectorAll('button')).filter(btn => {
|
|
234
|
+
const text = (btn.innerText || btn.textContent || '').trim().toLowerCase();
|
|
235
|
+
return text === 'accept' && btn.offsetParent !== null && !btn.disabled;
|
|
236
|
+
}).length
|
|
237
|
+
`));
|
|
238
|
+
if (currentCount < prevButtonCount)
|
|
239
|
+
break;
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
return { accepted, skipped };
|
|
243
|
+
}
|
|
244
|
+
async stepEndBrowserSession() {
|
|
245
|
+
if (!this.sessionId)
|
|
246
|
+
return;
|
|
247
|
+
const browserbase = new BrowserBaseBubble({ operation: 'end_session', session_id: this.sessionId }, this.context, 'endsession');
|
|
248
|
+
await browserbase.action();
|
|
249
|
+
console.log(`[AcceptInvitations] Session ended: ${this.sessionId}`);
|
|
250
|
+
this.sessionId = null;
|
|
251
|
+
}
|
|
252
|
+
async evaluate(script) {
|
|
253
|
+
if (!this.sessionId)
|
|
254
|
+
throw new Error('No active session');
|
|
255
|
+
const browserbase = new BrowserBaseBubble({ operation: 'evaluate', session_id: this.sessionId, script }, this.context, 'evaluate');
|
|
256
|
+
const result = await browserbase.action();
|
|
257
|
+
if (!result.data.success)
|
|
258
|
+
throw new Error(result.data.error || 'Evaluation failed');
|
|
259
|
+
return result.data.result;
|
|
260
|
+
}
|
|
261
|
+
async detectIPAddress() {
|
|
262
|
+
if (!this.sessionId)
|
|
263
|
+
return null;
|
|
264
|
+
try {
|
|
265
|
+
return (await this.evaluate(`
|
|
266
|
+
(async () => {
|
|
267
|
+
try {
|
|
268
|
+
const r = await fetch('https://api.ipify.org?format=json');
|
|
269
|
+
const d = await r.json();
|
|
270
|
+
return d.ip;
|
|
271
|
+
} catch { return null; }
|
|
272
|
+
})()
|
|
273
|
+
`));
|
|
274
|
+
}
|
|
275
|
+
catch {
|
|
276
|
+
return null;
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
async performAction() {
|
|
280
|
+
const count = this.params.count ?? 5;
|
|
281
|
+
try {
|
|
282
|
+
await this.stepStartBrowserSession();
|
|
283
|
+
await this.stepNavigateToInvitationManager();
|
|
284
|
+
const pageReady = await this.stepWaitForInvitationsPage();
|
|
285
|
+
if (!pageReady)
|
|
286
|
+
console.log('[AcceptInvitations] Page slow to load, continuing');
|
|
287
|
+
const { accepted, skipped } = await this.stepAcceptTopInvitations(count);
|
|
288
|
+
return {
|
|
289
|
+
operation: 'accept_invitations',
|
|
290
|
+
success: true,
|
|
291
|
+
accepted,
|
|
292
|
+
accepted_count: accepted.length,
|
|
293
|
+
skipped_count: skipped,
|
|
294
|
+
message: `Accepted ${accepted.length} invitation(s)${skipped > 0 ? `, skipped ${skipped}` : ''}`,
|
|
295
|
+
error: '',
|
|
296
|
+
};
|
|
297
|
+
}
|
|
298
|
+
catch (error) {
|
|
299
|
+
return {
|
|
300
|
+
operation: 'accept_invitations',
|
|
301
|
+
success: false,
|
|
302
|
+
error: error instanceof Error ? error.message : 'Unknown error',
|
|
303
|
+
};
|
|
304
|
+
}
|
|
305
|
+
finally {
|
|
306
|
+
await this.stepEndBrowserSession();
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
}
|
|
310
|
+
//# sourceMappingURL=tool.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tool.js","sourceRoot":"","sources":["../../../../../src/bubbles/tool-bubble/browser-tools/linkedin-accept-invitations/tool.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,wCAAwC,CAAC;AAEpE,OAAO,EACL,iBAAiB,GAElB,MAAM,8CAA8C,CAAC;AACtD,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,EAAE,uBAAuB,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAChF,OAAO,EACL,yCAAyC,EACzC,yCAAyC,GAI1C,MAAM,aAAa,CAAC;AAErB,MAAM,OAAO,6BAGX,SAAQ,UAAkD;IAC1D,MAAM,CAAU,UAAU,GAAG,kCAA2C,CAAC;IACzE,MAAM,CAAU,MAAM,GAAG,yCAAyC,CAAC;IACnE,MAAM,CAAU,YAAY,GAAG,yCAAyC,CAAC;IACzE,MAAM,CAAU,gBAAgB,GAC9B,8CAA8C,CAAC;IACjD,MAAM,CAAU,eAAe,GAC7B,uJAAuJ,CAAC;IAC1J,MAAM,CAAU,KAAK,GAAG,6BAA6B,CAAC;IACtD,MAAM,CAAU,IAAI,GAAG,MAAM,CAAC;IAEtB,SAAS,GAAkB,IAAI,CAAC;IAChC,SAAS,GAAkB,IAAI,CAAC;IAChC,OAAO,GAAuB,IAAI,CAAC;IAE3C,YACE,SAAY,EAAE,SAAS,EAAE,oBAAoB,EAAO,EACpD,OAAu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G,MAAM,IAAI,CAAC,0BAA0B,EAAE,CAAC;YAC1D,IAAI,CAAC,SAAS;gBACZ,OAAO,CAAC,GAAG,CAAC,mDAAmD,CAAC,CAAC;YAEnE,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,MAAM,IAAI,CAAC,wBAAwB,CAAC,KAAK,CAAC,CAAC;YAEzE,OAAO;gBACL,SAAS,EAAE,oBAAoB;gBAC/B,OAAO,EAAE,IAAI;gBACb,QAAQ;gBACR,cAAc,EAAE,QAAQ,CAAC,MAAM;gBAC/B,aAAa,EAAE,OAAO;gBACtB,OAAO,EAAE,YAAY,QAAQ,CAAC,MAAM,iBAAiB,OAAO,GAAG,CAAC,CAAC,CAAC,CAAC,aAAa,OAAO,EAAE,CAAC,CAAC,CAAC,EAAE,EAAE;gBAChG,KAAK,EAAE,EAAE;aACV,CAAC;QACJ,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,OAAO;gBACL,SAAS,EAAE,oBAAoB;gBAC/B,OAAO,EAAE,KAAK;gBACd,KAAK,EAAE,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe;aAChE,CAAC;QACJ,CAAC;gBAAS,CAAC;YACT,MAAM,IAAI,CAAC,qBAAqB,EAAE,CAAC;QACrC,CAAC;IACH,CAAC"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { LinkedInConnectionTool } from './tool.js';
|
|
2
|
+
export { LinkedInConnectionToolParamsSchema, LinkedInConnectionToolResultSchema, ProfileInfoSchema, type LinkedInConnectionToolParams, type LinkedInConnectionToolParamsInput, type LinkedInConnectionToolResult, type ProfileInfo, } from './schema.js';
|
|
3
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/bubbles/tool-bubble/browser-tools/linkedin-connection/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,WAAW,CAAC;AACnD,OAAO,EACL,kCAAkC,EAClC,kCAAkC,EAClC,iBAAiB,EACjB,KAAK,4BAA4B,EACjC,KAAK,iCAAiC,EACtC,KAAK,4BAA4B,EACjC,KAAK,WAAW,GACjB,MAAM,aAAa,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/bubbles/tool-bubble/browser-tools/linkedin-connection/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,WAAW,CAAC;AACnD,OAAO,EACL,kCAAkC,EAClC,kCAAkC,EAClC,iBAAiB,GAKlB,MAAM,aAAa,CAAC"}
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { CredentialType } from '@bubblelab/shared-schemas';
|
|
3
|
+
/**
|
|
4
|
+
* Profile information extracted from LinkedIn
|
|
5
|
+
*/
|
|
6
|
+
export declare const ProfileInfoSchema: z.ZodObject<{
|
|
7
|
+
name: z.ZodString;
|
|
8
|
+
headline: z.ZodOptional<z.ZodString>;
|
|
9
|
+
location: z.ZodOptional<z.ZodString>;
|
|
10
|
+
profile_url: z.ZodString;
|
|
11
|
+
}, "strip", z.ZodTypeAny, {
|
|
12
|
+
name: string;
|
|
13
|
+
profile_url: string;
|
|
14
|
+
location?: string | undefined;
|
|
15
|
+
headline?: string | undefined;
|
|
16
|
+
}, {
|
|
17
|
+
name: string;
|
|
18
|
+
profile_url: string;
|
|
19
|
+
location?: string | undefined;
|
|
20
|
+
headline?: string | undefined;
|
|
21
|
+
}>;
|
|
22
|
+
export type ProfileInfo = z.infer<typeof ProfileInfoSchema>;
|
|
23
|
+
/**
|
|
24
|
+
* LinkedIn Connection Tool parameters schema
|
|
25
|
+
*/
|
|
26
|
+
export declare const LinkedInConnectionToolParamsSchema: z.ZodObject<{
|
|
27
|
+
operation: z.ZodLiteral<"send_connection">;
|
|
28
|
+
profile_url: z.ZodString;
|
|
29
|
+
message: z.ZodOptional<z.ZodString>;
|
|
30
|
+
credentials: z.ZodOptional<z.ZodRecord<z.ZodNativeEnum<typeof CredentialType>, z.ZodString>>;
|
|
31
|
+
proxy: z.ZodOptional<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
32
|
+
type: z.ZodLiteral<"none">;
|
|
33
|
+
}, "strip", z.ZodTypeAny, {
|
|
34
|
+
type: "none";
|
|
35
|
+
}, {
|
|
36
|
+
type: "none";
|
|
37
|
+
}>, z.ZodObject<{
|
|
38
|
+
type: z.ZodLiteral<"browserbase">;
|
|
39
|
+
}, "strip", z.ZodTypeAny, {
|
|
40
|
+
type: "browserbase";
|
|
41
|
+
}, {
|
|
42
|
+
type: "browserbase";
|
|
43
|
+
}>, z.ZodObject<{
|
|
44
|
+
type: z.ZodLiteral<"custom">;
|
|
45
|
+
proxy: z.ZodObject<{
|
|
46
|
+
id: z.ZodString;
|
|
47
|
+
server: z.ZodString;
|
|
48
|
+
username: z.ZodOptional<z.ZodString>;
|
|
49
|
+
password: z.ZodOptional<z.ZodString>;
|
|
50
|
+
}, "strip", z.ZodTypeAny, {
|
|
51
|
+
id: string;
|
|
52
|
+
server: string;
|
|
53
|
+
password?: string | undefined;
|
|
54
|
+
username?: string | undefined;
|
|
55
|
+
}, {
|
|
56
|
+
id: string;
|
|
57
|
+
server: string;
|
|
58
|
+
password?: string | undefined;
|
|
59
|
+
username?: string | undefined;
|
|
60
|
+
}>;
|
|
61
|
+
}, "strip", z.ZodTypeAny, {
|
|
62
|
+
type: "custom";
|
|
63
|
+
proxy: {
|
|
64
|
+
id: string;
|
|
65
|
+
server: string;
|
|
66
|
+
password?: string | undefined;
|
|
67
|
+
username?: string | undefined;
|
|
68
|
+
};
|
|
69
|
+
}, {
|
|
70
|
+
type: "custom";
|
|
71
|
+
proxy: {
|
|
72
|
+
id: string;
|
|
73
|
+
server: string;
|
|
74
|
+
password?: string | undefined;
|
|
75
|
+
username?: string | undefined;
|
|
76
|
+
};
|
|
77
|
+
}>]>>;
|
|
78
|
+
}, "strip", z.ZodTypeAny, {
|
|
79
|
+
operation: "send_connection";
|
|
80
|
+
profile_url: string;
|
|
81
|
+
message?: string | undefined;
|
|
82
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
83
|
+
proxy?: {
|
|
84
|
+
type: "none";
|
|
85
|
+
} | {
|
|
86
|
+
type: "browserbase";
|
|
87
|
+
} | {
|
|
88
|
+
type: "custom";
|
|
89
|
+
proxy: {
|
|
90
|
+
id: string;
|
|
91
|
+
server: string;
|
|
92
|
+
password?: string | undefined;
|
|
93
|
+
username?: string | undefined;
|
|
94
|
+
};
|
|
95
|
+
} | undefined;
|
|
96
|
+
}, {
|
|
97
|
+
operation: "send_connection";
|
|
98
|
+
profile_url: string;
|
|
99
|
+
message?: string | undefined;
|
|
100
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
101
|
+
proxy?: {
|
|
102
|
+
type: "none";
|
|
103
|
+
} | {
|
|
104
|
+
type: "browserbase";
|
|
105
|
+
} | {
|
|
106
|
+
type: "custom";
|
|
107
|
+
proxy: {
|
|
108
|
+
id: string;
|
|
109
|
+
server: string;
|
|
110
|
+
password?: string | undefined;
|
|
111
|
+
username?: string | undefined;
|
|
112
|
+
};
|
|
113
|
+
} | undefined;
|
|
114
|
+
}>;
|
|
115
|
+
/**
|
|
116
|
+
* LinkedIn Connection Tool result schema
|
|
117
|
+
*/
|
|
118
|
+
export declare const LinkedInConnectionToolResultSchema: z.ZodObject<{
|
|
119
|
+
operation: z.ZodLiteral<"send_connection">;
|
|
120
|
+
success: z.ZodBoolean;
|
|
121
|
+
message: z.ZodOptional<z.ZodString>;
|
|
122
|
+
profile: z.ZodOptional<z.ZodObject<{
|
|
123
|
+
name: z.ZodString;
|
|
124
|
+
headline: z.ZodOptional<z.ZodString>;
|
|
125
|
+
location: z.ZodOptional<z.ZodString>;
|
|
126
|
+
profile_url: z.ZodString;
|
|
127
|
+
}, "strip", z.ZodTypeAny, {
|
|
128
|
+
name: string;
|
|
129
|
+
profile_url: string;
|
|
130
|
+
location?: string | undefined;
|
|
131
|
+
headline?: string | undefined;
|
|
132
|
+
}, {
|
|
133
|
+
name: string;
|
|
134
|
+
profile_url: string;
|
|
135
|
+
location?: string | undefined;
|
|
136
|
+
headline?: string | undefined;
|
|
137
|
+
}>>;
|
|
138
|
+
error: z.ZodString;
|
|
139
|
+
}, "strip", z.ZodTypeAny, {
|
|
140
|
+
error: string;
|
|
141
|
+
success: boolean;
|
|
142
|
+
operation: "send_connection";
|
|
143
|
+
message?: string | undefined;
|
|
144
|
+
profile?: {
|
|
145
|
+
name: string;
|
|
146
|
+
profile_url: string;
|
|
147
|
+
location?: string | undefined;
|
|
148
|
+
headline?: string | undefined;
|
|
149
|
+
} | undefined;
|
|
150
|
+
}, {
|
|
151
|
+
error: string;
|
|
152
|
+
success: boolean;
|
|
153
|
+
operation: "send_connection";
|
|
154
|
+
message?: string | undefined;
|
|
155
|
+
profile?: {
|
|
156
|
+
name: string;
|
|
157
|
+
profile_url: string;
|
|
158
|
+
location?: string | undefined;
|
|
159
|
+
headline?: string | undefined;
|
|
160
|
+
} | undefined;
|
|
161
|
+
}>;
|
|
162
|
+
export type LinkedInConnectionToolParams = z.output<typeof LinkedInConnectionToolParamsSchema>;
|
|
163
|
+
export type LinkedInConnectionToolParamsInput = z.input<typeof LinkedInConnectionToolParamsSchema>;
|
|
164
|
+
export type LinkedInConnectionToolResult = z.output<typeof LinkedInConnectionToolResultSchema>;
|
|
165
|
+
//# sourceMappingURL=schema.d.ts.map
|