Skip to content
/ mcp Public

The project is still in the incubation phase.

License

Notifications You must be signed in to change notification settings

go-tapd/mcp

Repository files navigation

Tapd MCP Server

Warning

For the convenience of unified maintenance, we recently migrated this repository to go-tapd/tapd.

📥 Usage

Use STDIO Server

Build the tapd-mcp-server

git clone git@github.com:go-tapd/mcp.git

cd mcp && make build/cmd/tapd-mcp-server

./bin/tapd-mcp-server # <--- This is the command to run the STDIO server.

Configure the MCP server

Below is a configuration example based on Cline, with different configurations for various MCP Clients.

{
  "mcpServers": {
    "github.com/go-tapd/mcp": {
      "command": "{path}/tapd-mcp-server",
      "env": {
        "TAPD_CLIENT_ID": "<YOUR_CLIENT_ID>",
        "TAPD_CLIENT_SECRET": "<YOUR_CLIENT_SECRET>",
        "TAPD_WORKSPACE_ID": "<YOUR_WORKSPACE_ID>"
      }
    }
  }
}

Use SSE Server

Install the package

go get github.com/go-tapd/mcp

Create a server

package main

import (
	"log"
	"net/http"

	"github.com/go-tapd/mcp"
	"github.com/go-tapd/tapd"
)

func main() {
	client, err := tapd.NewClient("client_id", "client_secret")
	if err != nil {
		log.Fatal(err)
	}

	workspaceID := 123456 // replace with your workspace ID

	srv, err := mcp.NewServer(workspaceID, client)
	if err != nil {
		log.Fatal(err)
	}

	http.HandleFunc("/", srv.ServeHTTP)

	if err := http.ListenAndServe(":8080", nil); err != nil {
		log.Fatal(err)
	}
}

Visit http://localhost:8080/sse to get the SSE stream.

📦 Features

需求

用户

📄 License

MIT