From 0190553302e4fe6b378071fb0d95b05a24dd032c Mon Sep 17 00:00:00 2001 From: Mahendran Selvakumar Date: Thu, 9 Apr 2026 23:57:59 +0100 Subject: [PATCH 1/3] Fix MCP stdio transport and add tool descriptions Signed-off-by: Mahendran Selvakumar --- src/loader.ts | 4 ++-- src/main.ts | 20 ++++++++++++++------ 2 files changed, 16 insertions(+), 8 deletions(-) diff --git a/src/loader.ts b/src/loader.ts index 5e70458..00ad090 100644 --- a/src/loader.ts +++ b/src/loader.ts @@ -25,7 +25,7 @@ export async function loadDocsFromGitHub(): Promise { } try { - console.info(`Start cloning repo ${REPO} to ${targetDir}`); + console.error(`Start cloning repo ${REPO} to ${targetDir}`); await git.clone(REPO, targetDir, [ "--depth", "1", @@ -36,7 +36,7 @@ export async function loadDocsFromGitHub(): Promise { ]); await git.cwd(targetDir); await git.raw(["sparse-checkout", "set", DOCS_PATH]); - console.info(`Successfully cloned repo ${REPO} to ${targetDir}`); + console.error(`Successfully cloned repo ${REPO} to ${targetDir}`); } catch (error) { console.error(`Error while cloning repo ${REPO} to ${targetDir}: ${error}`); throw error; diff --git a/src/main.ts b/src/main.ts index 5fb3fb2..8309af6 100644 --- a/src/main.ts +++ b/src/main.ts @@ -18,6 +18,7 @@ async function main() { server.tool( "search_docs", + "Executes a full-text search on PipeCD docs. Provide space-separated keywords (AND search), a starting offset, and an optional result limit.", { query: z.string(), offset: z.number(), @@ -45,12 +46,19 @@ async function main() { }, ); // NOTE: read_docs might not be called because search_docs contains contents. - server.tool("read_docs", { path: z.string() }, async ({ path }) => { - const doc = docsIndexes.find((doc) => doc.path === path); - return { - content: [{ type: "text", text: doc?.content ?? "document not found" }], - }; - }); + server.tool( + "read_docs", + 'Returns the full content of a specified PipeCD doc page. Provide the relative path of the document (after "docs/content/en/").', + { path: z.string() }, + async ({ path }) => { + const doc = docsIndexes.find((doc) => doc.path === path); + return { + content: [ + { type: "text", text: doc?.content ?? "document not found" }, + ], + }; + }, + ); // Start receiving messages on stdin and sending messages on stdout const transport = new StdioServerTransport(); From 6d19bc04a857e79c482594b6e9420990571595b8 Mon Sep 17 00:00:00 2001 From: Mahendran Selvakumar <31248024+skmahe1077@users.noreply.github.com> Date: Wed, 1 Apr 2026 03:02:57 +0100 Subject: [PATCH 2/3] Fix/cursor deeplink 404 (#53) * Fix Cursor deeplink URL returning 404 error Signed-off-by: Mahendran Selvakumar * Fix Cursor deeplink to use HTML anchor tag for GitHub compatibility Signed-off-by: Mahendran Selvakumar * Fix Cursor deeplink to use correct install URL Signed-off-by: Mahendran Selvakumar --------- Signed-off-by: Mahendran Selvakumar --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 82650e9..58b8cdd 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ Documentation is cloned into a temporary directory, and Markdown files are index For Cursor users, you can install the MCP server with a single click using the deeplink below: -[![Install MCP Server](https://cursor.com/deeplink/mcp-install-dark.svg)](https://cursor.com/install-mcp?name=pipe-cd.docs-mcp-server&config=eyJ0eXBlIjoic3RkaW8iLCJjb21tYW5kIjoibnB4IEBwaXBlLWNkL2RvY3MtbWNwLXNlcnZlckBsYXRlc3QifQ%3D%3D) +[![Install MCP Server](https://cursor.com/deeplink/mcp-install-dark.svg)](https://cursor.com/en-US/install-mcp?name=pipe-cd.docs-mcp-server&config=eyJ0eXBlIjoic3RkaW8iLCJjb21tYW5kIjoibnB4IEBwaXBlLWNkL2RvY3MtbWNwLXNlcnZlckBsYXRlc3QifQ%3D%3D) This will automatically configure the MCP server in your Cursor settings. After clicking the link, Cursor will prompt you to install the server. From 260213f3d9d7e7e5a883f52cfa59bdb0c516b6f8 Mon Sep 17 00:00:00 2001 From: Mahendran Selvakumar Date: Fri, 10 Apr 2026 00:02:29 +0100 Subject: [PATCH 3/3] Fix MCP stdio transport and add tool descriptions Signed-off-by: Mahendran Selvakumar --- src/main.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.ts b/src/main.ts index 8309af6..3145441 100644 --- a/src/main.ts +++ b/src/main.ts @@ -18,7 +18,7 @@ async function main() { server.tool( "search_docs", - "Executes a full-text search on PipeCD docs. Provide space-separated keywords (AND search), a starting offset, and an optional result limit.", + "Full-text search over PipeCD docs. Query is space-separated keywords (AND search).", { query: z.string(), offset: z.number(),