bowmark-mcp 1.0.1 → 2.0.0
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/README.md +16 -8
- package/dist/bridge.js +3 -3
- package/package.json +3 -2
package/README.md
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
# bowmark-mcp — Bowmark MCP over stdio (Node)
|
|
2
2
|
|
|
3
|
-
Bowmark
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
Bowmark turns the interaction-gated web into a **callable function library**.
|
|
4
|
+
An agent reads the library (`get_library`), writes a short JavaScript script
|
|
5
|
+
against it, and sends it to `run` — Bowmark executes it on the live sites in a
|
|
6
|
+
sandbox and hands back the result. The canonical server is hosted, streamable
|
|
7
|
+
HTTP, no auth required: `https://api.bowmark.ai/mcp`.
|
|
6
8
|
|
|
7
9
|
This package is a **thin stdio bridge** to that hosted server, for MCP hosts
|
|
8
10
|
whose client only speaks stdio, in Node-flavored environments. Tool schemas,
|
|
@@ -33,13 +35,13 @@ If your host speaks streamable HTTP, skip this bridge and connect directly to
|
|
|
33
35
|
| Var | Meaning |
|
|
34
36
|
|---|---|
|
|
35
37
|
| `BOWMARK_MCP_URL` | Target MCP URL. Default `https://api.bowmark.ai/mcp?s=n` (`?s=n` attributes the install to the npm bridge). Point at `http://localhost:3001/mcp` for a local Bowmark API. |
|
|
36
|
-
| `BOWMARK_API_KEY` | Optional. Forwarded as `X-Bowmark-Key`; a free key (bowmark.ai dashboard)
|
|
38
|
+
| `BOWMARK_API_KEY` | Optional. Forwarded as `X-Bowmark-Key`; a free key (bowmark.ai dashboard) lifts the anonymous per-IP daily cap to your plan budget. |
|
|
37
39
|
|
|
38
40
|
## Design notes (repo-internal)
|
|
39
41
|
|
|
40
42
|
- **One remote session per request, retried once.** The hosted MCP is
|
|
41
43
|
stateless, so a fresh connection is semantically identical and its cost (one
|
|
42
|
-
initialize round-trip) is noise next to
|
|
44
|
+
initialize round-trip) is noise next to a `run` that drives real browsers — and it
|
|
43
45
|
sidesteps long-lived-connection failure modes without reconnect bookkeeping.
|
|
44
46
|
Mirrors `packages/bowmark-mcp/python` (the PyPI bridge) exactly.
|
|
45
47
|
- **Pass-through only.** No tool logic lives here; the agent-surfaces sync
|
|
@@ -49,9 +51,15 @@ If your host speaks streamable HTTP, skip this bridge and connect directly to
|
|
|
49
51
|
- **`?s=n` source code** is registered in `apps/api/src/mcp-sources.ts` +
|
|
50
52
|
`mcp-registry/sources.json` (npm stdio bridge channel; the PyPI bridge is
|
|
51
53
|
`?s=p`).
|
|
52
|
-
- **
|
|
53
|
-
|
|
54
|
-
|
|
54
|
+
- **npm ownership verification needs BOTH markers — the registry checks the
|
|
55
|
+
published package.json, not just the README.** The `mcp-name:
|
|
56
|
+
ai.bowmark/bowmark` line above and the `"mcpName": "ai.bowmark/bowmark"`
|
|
57
|
+
field in `package.json` are both load-bearing; don't remove either. Learned
|
|
58
|
+
the hard way 2026-07-04: `release-mcp.yml`'s registry republish failed for
|
|
59
|
+
five straight api releases (`server returned status 400: ... "NPM package
|
|
60
|
+
'bowmark-mcp' is missing required 'mcpName' field"`) because only the
|
|
61
|
+
README marker was present — the package.json field is what `mcp-publisher
|
|
62
|
+
publish` actually validates against the live npm package.
|
|
55
63
|
- **Versioning is manual** (thin bridge, not the api): bump `package.json`
|
|
56
64
|
when it changes. Not wired into release-please; `private` is deliberately
|
|
57
65
|
absent so npm publish works — release-please doesn't manage this package.
|
package/dist/bridge.js
CHANGED
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
import { Client } from "@modelcontextprotocol/sdk/client/index.js";
|
|
24
24
|
import { StreamableHTTPClientTransport } from "@modelcontextprotocol/sdk/client/streamableHttp.js";
|
|
25
25
|
import { Server } from "@modelcontextprotocol/sdk/server/index.js";
|
|
26
|
-
import { CallToolRequestSchema, ListToolsRequestSchema
|
|
26
|
+
import { CallToolRequestSchema, ListToolsRequestSchema } from "@modelcontextprotocol/sdk/types.js";
|
|
27
27
|
export const DEFAULT_URL = "https://api.bowmark.ai/mcp?s=n";
|
|
28
28
|
export function targetUrl(env = process.env) {
|
|
29
29
|
return env.BOWMARK_MCP_URL?.trim() || DEFAULT_URL;
|
|
@@ -35,7 +35,7 @@ export function authHeaders(env = process.env) {
|
|
|
35
35
|
return key ? { "X-Bowmark-Key": key } : undefined;
|
|
36
36
|
}
|
|
37
37
|
async function withRemote(fn) {
|
|
38
|
-
const client = new Client({ name: "bowmark-mcp-bridge", version: "
|
|
38
|
+
const client = new Client({ name: "bowmark-mcp-bridge", version: "2.0.0" });
|
|
39
39
|
const headers = authHeaders();
|
|
40
40
|
const transport = new StreamableHTTPClientTransport(new URL(targetUrl()), {
|
|
41
41
|
requestInit: headers ? { headers } : undefined,
|
|
@@ -60,7 +60,7 @@ export async function callRemote(fn, connect = withRemote) {
|
|
|
60
60
|
}
|
|
61
61
|
}
|
|
62
62
|
export function buildServer(remote = callRemote) {
|
|
63
|
-
const server = new Server({ name: "bowmark", version: "
|
|
63
|
+
const server = new Server({ name: "bowmark", version: "2.0.0" }, { capabilities: { tools: {} } });
|
|
64
64
|
server.setRequestHandler(ListToolsRequestSchema, async () => {
|
|
65
65
|
return await remote((c) => c.listTools());
|
|
66
66
|
});
|
package/package.json
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bowmark-mcp",
|
|
3
|
-
"version": "
|
|
4
|
-
"
|
|
3
|
+
"version": "2.0.0",
|
|
4
|
+
"mcpName": "ai.bowmark/bowmark",
|
|
5
|
+
"description": "Bowmark MCP over stdio \u2014 a thin bridge to the hosted Bowmark MCP at https://api.bowmark.ai/mcp. The web as callable functions: read a typed library, write a script, Bowmark runs it on the live sites.",
|
|
5
6
|
"license": "MIT",
|
|
6
7
|
"author": "Bowmark AI <christopher@bowmark.ai>",
|
|
7
8
|
"homepage": "https://bowmark.ai",
|