Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ After install, set your credentials from [TestingBot account settings](https://t

## Prerequisites

- **Node.js** >= 18 (recommended: 22.15.0 or later)
- **Node.js** >= 20 (recommended: 22.15.0 or later)
- **TestingBot Account** with API credentials
- An MCP-compatible client (Claude Desktop, VS Code with Continue, Cursor, etc.)

Expand Down Expand Up @@ -856,7 +856,7 @@ If you see authentication errors:
If the MCP server won't connect:
1. Restart your MCP client (Claude Desktop, VS Code, etc.)
2. Check the MCP client logs for errors
3. Verify Node.js version is >= 18
3. Verify Node.js version is >= 20

### Tool Execution Errors

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"LICENSE"
],
"engines": {
"node": ">=18"
"node": ">=20"
},
"keywords": [
"mcp",
Expand Down
4 changes: 3 additions & 1 deletion src/server-factory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,9 @@ export class TestingBotMcpServer {
// traffic. Throws on any blocking issue so the entry point can exit with a
// clear error instead of letting the first tool call fail mysteriously.
public async preflight(): Promise<void> {
const required = 18;
// Must match `engines.node` in package.json, and the floor enforced by
// @testingbot/automation-mcp, which hard-fails its own preflight below 20.
const required = 20;
const major = Number(process.versions.node.split(".")[0]);
if (!Number.isFinite(major) || major < required) {
throw new Error(
Expand Down
10 changes: 9 additions & 1 deletion tests/server-factory.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,18 @@ describe("TestingBotMcpServer.preflight", () => {
it("rejects unsupported Node versions before hitting the API", async () => {
setNodeVersion("16.20.0");
const server = new TestingBotMcpServer(testingBotApiMock, configMock);
await expect(server.preflight()).rejects.toThrow(/Node.js 18\+ is required/);
await expect(server.preflight()).rejects.toThrow(/Node.js 20\+ is required/);
expect(testingBotApiMock.getUserInfo).not.toHaveBeenCalled();
});

it("rejects Node 18, which @testingbot/automation-mcp no longer supports", async () => {
// The bundled automation tools hard-fail their own preflight below 20, so
// accepting 18 here would install cleanly and then die at startup.
setNodeVersion("18.20.0");
const server = new TestingBotMcpServer(testingBotApiMock, configMock);
await expect(server.preflight()).rejects.toThrow(/Node.js 20\+ is required/);
});

it("starts in degraded mode (no throw) when api_key is missing", async () => {
setNodeVersion("20.10.0");
const server = new TestingBotMcpServer(testingBotApiMock, {
Expand Down
Loading