@leadbay/mcp 0.16.2 → 0.17.1

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.
@@ -0,0 +1,46 @@
1
+ const { app, BrowserWindow, shell } = require("electron");
2
+ const path = require("node:path");
3
+ const { pathToFileURL } = require("node:url");
4
+
5
+ let handle;
6
+ let win;
7
+
8
+ if (process.platform === "linux" && process.env.LEADBAY_INSTALLER_ELECTRON_SANDBOX !== "1") {
9
+ app.commandLine.appendSwitch("no-sandbox");
10
+ }
11
+
12
+ async function createWindow() {
13
+ const mod = await import(pathToFileURL(path.join(__dirname, "../dist/installer-gui.js")).href);
14
+ const isUninstall = process.argv.includes("--uninstall");
15
+ handle = isUninstall
16
+ ? await mod.startUninstallerGui({ openBrowser: false })
17
+ : await mod.startInstallerGui({ openBrowser: false });
18
+
19
+ win = new BrowserWindow({
20
+ width: 920,
21
+ height: 760,
22
+ minWidth: 720,
23
+ minHeight: 620,
24
+ title: isUninstall ? "Leadbay MCP Uninstaller" : "Leadbay MCP Installer",
25
+ backgroundColor: "#f6f7f4",
26
+ autoHideMenuBar: true,
27
+ webPreferences: {
28
+ contextIsolation: true,
29
+ nodeIntegration: false,
30
+ sandbox: true,
31
+ },
32
+ });
33
+
34
+ win.webContents.setWindowOpenHandler(({ url }) => {
35
+ shell.openExternal(url);
36
+ return { action: "deny" };
37
+ });
38
+ await win.loadURL(handle.url);
39
+ }
40
+
41
+ app.whenReady().then(createWindow);
42
+
43
+ app.on("window-all-closed", async () => {
44
+ if (handle) await handle.close().catch(() => undefined);
45
+ app.quit();
46
+ });
package/package.json CHANGED
@@ -1,14 +1,18 @@
1
1
  {
2
2
  "name": "@leadbay/mcp",
3
- "version": "0.16.2",
3
+ "version": "0.17.1",
4
4
  "mcpName": "io.github.leadbay/leadbay-mcp",
5
5
  "description": "Model Context Protocol (MCP) server for Leadbay — AI lead discovery, qualification, and enrichment for Claude Desktop, Cursor, and Claude Code.",
6
6
  "type": "module",
7
7
  "bin": {
8
- "leadbay-mcp": "dist/bin.js"
8
+ "leadbay-mcp": "dist/bin.js",
9
+ "leadbay-mcp-http": "dist/http-server.js",
10
+ "installer": "dist/installer-electron.js",
11
+ "leadbay-mcp-installer": "dist/installer-electron.js"
9
12
  },
10
13
  "files": [
11
14
  "dist/",
15
+ "installer/electron-main.cjs",
12
16
  "README.md",
13
17
  "MIGRATION.md",
14
18
  "CHANGELOG.md",
@@ -18,16 +22,21 @@
18
22
  "access": "public"
19
23
  },
20
24
  "scripts": {
21
- "prebuild": "pnpm --filter @leadbay/promptforge build",
25
+ "prebuild": "pnpm --filter @leadbay/core build",
22
26
  "build": "tsup",
23
27
  "typecheck": "tsc --noEmit",
24
28
  "test": "vitest run",
25
29
  "test:smoke": "vitest run --config vitest.smoke.config.ts",
26
- "prepublishOnly": "pnpm run build && pnpm run typecheck && pnpm run test"
30
+ "prepublishOnly": "pnpm run build && pnpm run typecheck && pnpm run test",
31
+ "installer": "pnpm run build && electron --no-sandbox installer/electron-main.cjs",
32
+ "installer:gui": "pnpm run installer",
33
+ "installer:gui:web": "pnpm run build && node dist/installer-gui.js"
27
34
  },
28
35
  "dependencies": {
36
+ "@hono/node-server": "^1.13.7",
29
37
  "@modelcontextprotocol/sdk": "1.29.0",
30
38
  "@sentry/node": "^9.0.0",
39
+ "hono": "^4.6.14",
31
40
  "posthog-node": "^4.5.0"
32
41
  },
33
42
  "devDependencies": {
@@ -35,6 +44,9 @@
35
44
  "@leadbay/core": "workspace:*",
36
45
  "@leadbay/promptforge": "workspace:*"
37
46
  },
47
+ "optionalDependencies": {
48
+ "electron": "^42.3.0"
49
+ },
38
50
  "engines": {
39
51
  "node": ">=22"
40
52
  },
@@ -1,255 +0,0 @@
1
- #!/usr/bin/env node
2
- import {
3
- AgentMemoryCaptureInputSchema,
4
- AgentMemoryEntrySchema,
5
- AgentMemoryInjectionError,
6
- AgentMemoryScopeSchema,
7
- AgentMemorySourceSchema,
8
- AgentMemoryTombstoneSchema,
9
- COMPOSITE_FILE_TOOL_NAMES,
10
- InMemoryBulkStore,
11
- LeadbayClient,
12
- LocalBulkStore,
13
- REGIONS,
14
- accountStatus,
15
- addLeadsToCampaign,
16
- addNote,
17
- adjustAudience,
18
- agentMemoryCapture,
19
- agentMemoryRecall,
20
- agentMemoryReview,
21
- agentMemoryTools,
22
- answerClarification,
23
- appendEntry,
24
- appendTombstone,
25
- assertSafeInsight,
26
- bulkEnrichStatus,
27
- bulkQualifyLeads,
28
- campaignCallSheet,
29
- campaignProgression,
30
- clearAgentMemoryCache,
31
- clearMockJournal,
32
- clearSelection,
33
- clearUserPrompt,
34
- compositeReadTools,
35
- compositeTools,
36
- compositeWriteTools,
37
- consolidate,
38
- createAgentMemoryId,
39
- createCampaign,
40
- createClient,
41
- createCustomField,
42
- createDefaultBulkStore,
43
- createLens,
44
- createLensDraft,
45
- createTopupLink,
46
- deselectLeads,
47
- discoverLeads,
48
- dislikeLead,
49
- dismissClarification,
50
- enrichContacts,
51
- enrichTitles,
52
- ensureAgentMemorySummary,
53
- followupsMap,
54
- formatLoginError,
55
- getClarification,
56
- getContacts,
57
- getEnrichmentJobTitles,
58
- getEpilogueResponses,
59
- getLeadActivities,
60
- getLeadNotes,
61
- getLeadProfile,
62
- getLensFilter,
63
- getLensScoring,
64
- getMockJournal,
65
- getProspectingActions,
66
- getQuota,
67
- getSelectionIds,
68
- getTasteProfile,
69
- getUserPrompt,
70
- getWebFetch,
71
- granularReadTools,
72
- granularTools,
73
- granularWriteTools,
74
- hashAccountId,
75
- importAndQualify,
76
- importLeads,
77
- importStatus,
78
- invalidateAgentMemoryCache,
79
- isAgentMemoryEnabled,
80
- isValidBulkId,
81
- launchBulkEnrichment,
82
- likeLead,
83
- listCampaigns,
84
- listLenses,
85
- listLocations,
86
- listMappableFields,
87
- listSectors,
88
- login,
89
- makeAgentMemoryEntry,
90
- makeAgentMemoryTombstone,
91
- normalizeInsight,
92
- openBillingPortal,
93
- pickClarification,
94
- prepareOutreach,
95
- previewBulkEnrichment,
96
- promoteLens,
97
- pullFollowups,
98
- pullLeads,
99
- qualifyLead,
100
- qualifyStatus,
101
- readEntries,
102
- readTombstones,
103
- recallOrderedTitles,
104
- refinePrompt,
105
- removeEpilogue,
106
- removeLeadsFromCampaign,
107
- removePushback,
108
- reportFriction,
109
- reportOutreach,
110
- researchLeadById,
111
- researchLeadByNameFuzzy,
112
- resolveAgentMemoryForClient,
113
- resolveAgentMemoryPaths,
114
- resolveAgentMemoryRoot,
115
- resolveAgentMemorySummary,
116
- resolveImportRows,
117
- resolveRegion,
118
- selectLeads,
119
- setActiveLens,
120
- setEpilogueStatus,
121
- setPushback,
122
- setUserPrompt,
123
- tools,
124
- tourPlan,
125
- updateLens,
126
- updateLensFilter,
127
- withAgentMemoryMeta
128
- } from "./chunk-3V3EPBLZ.js";
129
- export {
130
- AgentMemoryCaptureInputSchema,
131
- AgentMemoryEntrySchema,
132
- AgentMemoryInjectionError,
133
- AgentMemoryScopeSchema,
134
- AgentMemorySourceSchema,
135
- AgentMemoryTombstoneSchema,
136
- COMPOSITE_FILE_TOOL_NAMES,
137
- InMemoryBulkStore,
138
- LeadbayClient,
139
- LocalBulkStore,
140
- REGIONS,
141
- accountStatus,
142
- addLeadsToCampaign,
143
- addNote,
144
- adjustAudience,
145
- agentMemoryCapture,
146
- agentMemoryRecall,
147
- agentMemoryReview,
148
- agentMemoryTools,
149
- answerClarification,
150
- appendEntry,
151
- appendTombstone,
152
- assertSafeInsight,
153
- bulkEnrichStatus,
154
- bulkQualifyLeads,
155
- campaignCallSheet,
156
- campaignProgression,
157
- clearAgentMemoryCache,
158
- clearMockJournal,
159
- clearSelection,
160
- clearUserPrompt,
161
- compositeReadTools,
162
- compositeTools,
163
- compositeWriteTools,
164
- consolidate,
165
- createAgentMemoryId,
166
- createCampaign,
167
- createClient,
168
- createCustomField,
169
- createDefaultBulkStore,
170
- createLens,
171
- createLensDraft,
172
- createTopupLink,
173
- deselectLeads,
174
- discoverLeads,
175
- dislikeLead,
176
- dismissClarification,
177
- enrichContacts,
178
- enrichTitles,
179
- ensureAgentMemorySummary,
180
- followupsMap,
181
- formatLoginError,
182
- getClarification,
183
- getContacts,
184
- getEnrichmentJobTitles,
185
- getEpilogueResponses,
186
- getLeadActivities,
187
- getLeadNotes,
188
- getLeadProfile,
189
- getLensFilter,
190
- getLensScoring,
191
- getMockJournal,
192
- getProspectingActions,
193
- getQuota,
194
- getSelectionIds,
195
- getTasteProfile,
196
- getUserPrompt,
197
- getWebFetch,
198
- granularReadTools,
199
- granularTools,
200
- granularWriteTools,
201
- hashAccountId,
202
- importAndQualify,
203
- importLeads,
204
- importStatus,
205
- invalidateAgentMemoryCache,
206
- isAgentMemoryEnabled,
207
- isValidBulkId,
208
- launchBulkEnrichment,
209
- likeLead,
210
- listCampaigns,
211
- listLenses,
212
- listLocations,
213
- listMappableFields,
214
- listSectors,
215
- login,
216
- makeAgentMemoryEntry,
217
- makeAgentMemoryTombstone,
218
- normalizeInsight,
219
- openBillingPortal,
220
- pickClarification,
221
- prepareOutreach,
222
- previewBulkEnrichment,
223
- promoteLens,
224
- pullFollowups,
225
- pullLeads,
226
- qualifyLead,
227
- qualifyStatus,
228
- readEntries,
229
- readTombstones,
230
- recallOrderedTitles,
231
- refinePrompt,
232
- removeEpilogue,
233
- removeLeadsFromCampaign,
234
- removePushback,
235
- reportFriction,
236
- reportOutreach,
237
- researchLeadById,
238
- researchLeadByNameFuzzy,
239
- resolveAgentMemoryForClient,
240
- resolveAgentMemoryPaths,
241
- resolveAgentMemoryRoot,
242
- resolveAgentMemorySummary,
243
- resolveImportRows,
244
- resolveRegion,
245
- selectLeads,
246
- setActiveLens,
247
- setEpilogueStatus,
248
- setPushback,
249
- setUserPrompt,
250
- tools,
251
- tourPlan,
252
- updateLens,
253
- updateLensFilter,
254
- withAgentMemoryMeta
255
- };