@leadbay/mcp 0.35.1 → 0.35.2
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/CHANGELOG.md +21 -0
- package/dist/bin.js +8 -2
- package/dist/http-server.js +8 -2
- package/dist/installer-electron.js +1 -1
- package/dist/installer-gui.js +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,26 @@
|
|
|
1
1
|
# Changelog — @leadbay/mcp
|
|
2
2
|
|
|
3
|
+
## 0.35.2 — 2026-09-08
|
|
4
|
+
|
|
5
|
+
A backend `bad_request` 400 is now `BAD_INPUT` (product#4085).
|
|
6
|
+
|
|
7
|
+
**What happened.** On 8 Sep an unattended routine on the hosted server called
|
|
8
|
+
`leadbay_research_lead_by_id` twenty times in 39 seconds with the first block
|
|
9
|
+
of each lead UUID (`/lenses/48110/leads/5585c198`, …). The backend rejected
|
|
10
|
+
every call in ~30 ms with `400 {"error":{"code":"bad_request","message":"bad
|
|
11
|
+
'leadId' parameter"}}`. `client.ts` `mapErrorResponse` filed that under the
|
|
12
|
+
`API_ERROR` catch-all, whose hint reads "Try again or check the Leadbay API
|
|
13
|
+
status". The agent did what it was told. The same pattern ran on 31 Aug.
|
|
14
|
+
|
|
15
|
+
**Change.** A 400 whose body carries the backend's `bad_request` code (a path
|
|
16
|
+
or query parameter that failed to parse, a body that failed to deserialize) is
|
|
17
|
+
`BAD_INPUT`, with the backend message verbatim and a hint that the call fails
|
|
18
|
+
identically on retry and that ids are the full values Leadbay returned. Other
|
|
19
|
+
400 codes (`duplicate`, `unpaid_invoice`, `not_allowed`, …) are domain answers
|
|
20
|
+
and stay `API_ERROR`. `leadbay_research_lead_by_id`'s `leadId` schema
|
|
21
|
+
description now says the id is the full 36-character UUID from
|
|
22
|
+
`leadbay_pull_leads` `items[].id`, never shortened. No template change.
|
|
23
|
+
|
|
3
24
|
## 0.35.1 — 2026-09-08
|
|
4
25
|
|
|
5
26
|
Release-pipeline only. No source change, no behaviour change: `packages/core`
|
package/dist/bin.js
CHANGED
|
@@ -661,6 +661,9 @@ var init_client = __esm({
|
|
|
661
661
|
if (status === 404) {
|
|
662
662
|
return this.makeError("NOT_FOUND", parsed?.message || parsed?.error?.message || "Resource not found", "Verify the ID is correct", endpoint, null, status);
|
|
663
663
|
}
|
|
664
|
+
if (status === 400 && parsed?.error?.code === "bad_request") {
|
|
665
|
+
return this.makeError("BAD_INPUT", parsed?.error?.message || parsed?.message || "Leadbay rejected the request as malformed", "Leadbay's input validation rejected this call, so the same call will fail the same way \u2014 do not retry it unchanged. Fix the parameter named in the message first; if it is an id, pass it exactly as Leadbay returned it, never shortened or reconstructed.", endpoint, null, status);
|
|
666
|
+
}
|
|
664
667
|
return this.makeError("API_ERROR", parsed?.message || parsed?.error?.message || `API error (${status})`, "Try again or check the Leadbay API status", endpoint, null, status);
|
|
665
668
|
}
|
|
666
669
|
// /me cache (60s TTL). Separate from resolveOrgId() which still works for
|
|
@@ -14817,7 +14820,10 @@ var init_research_lead_by_id = __esm({
|
|
|
14817
14820
|
inputSchema: {
|
|
14818
14821
|
type: "object",
|
|
14819
14822
|
properties: {
|
|
14820
|
-
leadId: {
|
|
14823
|
+
leadId: {
|
|
14824
|
+
type: "string",
|
|
14825
|
+
description: "Full 36-character lead UUID exactly as returned in leadbay_pull_leads items[].id (never shortened)"
|
|
14826
|
+
},
|
|
14821
14827
|
lensId: {
|
|
14822
14828
|
type: "number",
|
|
14823
14829
|
description: "Lens id (escape hatch \u2014 normally omit; auto-resolves to the active lens)"
|
|
@@ -28045,7 +28051,7 @@ var OAUTH_BASE_URLS = {
|
|
|
28045
28051
|
fr: "https://staging.api.leadbay.app"
|
|
28046
28052
|
}
|
|
28047
28053
|
};
|
|
28048
|
-
var VERSION = "0.35.
|
|
28054
|
+
var VERSION = "0.35.2";
|
|
28049
28055
|
var HELP = `
|
|
28050
28056
|
leadbay-mcp ${VERSION} \u2014 Leadbay Model Context Protocol server
|
|
28051
28057
|
|
package/dist/http-server.js
CHANGED
|
@@ -3649,6 +3649,9 @@ var LeadbayClient = class _LeadbayClient {
|
|
|
3649
3649
|
if (status === 404) {
|
|
3650
3650
|
return this.makeError("NOT_FOUND", parsed?.message || parsed?.error?.message || "Resource not found", "Verify the ID is correct", endpoint, null, status);
|
|
3651
3651
|
}
|
|
3652
|
+
if (status === 400 && parsed?.error?.code === "bad_request") {
|
|
3653
|
+
return this.makeError("BAD_INPUT", parsed?.error?.message || parsed?.message || "Leadbay rejected the request as malformed", "Leadbay's input validation rejected this call, so the same call will fail the same way \u2014 do not retry it unchanged. Fix the parameter named in the message first; if it is an id, pass it exactly as Leadbay returned it, never shortened or reconstructed.", endpoint, null, status);
|
|
3654
|
+
}
|
|
3652
3655
|
return this.makeError("API_ERROR", parsed?.message || parsed?.error?.message || `API error (${status})`, "Try again or check the Leadbay API status", endpoint, null, status);
|
|
3653
3656
|
}
|
|
3654
3657
|
// /me cache (60s TTL). Separate from resolveOrgId() which still works for
|
|
@@ -16962,7 +16965,10 @@ var researchLeadById = {
|
|
|
16962
16965
|
inputSchema: {
|
|
16963
16966
|
type: "object",
|
|
16964
16967
|
properties: {
|
|
16965
|
-
leadId: {
|
|
16968
|
+
leadId: {
|
|
16969
|
+
type: "string",
|
|
16970
|
+
description: "Full 36-character lead UUID exactly as returned in leadbay_pull_leads items[].id (never shortened)"
|
|
16971
|
+
},
|
|
16966
16972
|
lensId: {
|
|
16967
16973
|
type: "number",
|
|
16968
16974
|
description: "Lens id (escape hatch \u2014 normally omit; auto-resolves to the active lens)"
|
|
@@ -25410,7 +25416,7 @@ function parseWriteEnv(env = process.env) {
|
|
|
25410
25416
|
}
|
|
25411
25417
|
|
|
25412
25418
|
// src/http-server.ts
|
|
25413
|
-
var VERSION = true ? "0.35.
|
|
25419
|
+
var VERSION = true ? "0.35.2" : "0.0.0-dev";
|
|
25414
25420
|
var PORT = Number(process.env.PORT ?? 8080);
|
|
25415
25421
|
var HOST = process.env.HOST ?? "0.0.0.0";
|
|
25416
25422
|
var logger = {
|
package/dist/installer-gui.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@leadbay/mcp",
|
|
3
|
-
"version": "0.35.
|
|
3
|
+
"version": "0.35.2",
|
|
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",
|