Connecting MCP Clients to PipesHub MCP Server
以下摘录自该仓库的 README(片段) · 在 GitHub 读完整 README →
This guide covers how to connect PipesHub's remote MCP server to **Cursor**, **Claude Code**, **Gemini CLI**, **Codex CLI**, **Claude.ai (Web)**, and **LibreChat** using static OAuth credentials or bearer tokens.
PipesHub exposes a remote MCP endpoint over **Streamable HTTP** at /mcp. MCP Clients connect to this endpoint directly -- no local npm packages or stdio processes needed.
**▶ Watch the 2½-minute demo**: Claude Code using this MCP server to answer from Jira, Slack, GitHub and Drive, with each person's own permissions.
> **Coding agent?** Start at For coding agents. Install the skill into the *user's* repo with npx skills add pipeshub-ai/mcp-server (see skills/pipeshub) and append the AGENTS.md snippet on that page. Listed on the official MCP registry as io.github.pipeshub-ai/mcp and on Cursor Directory as PipesHub. The listing files (plugin.json, mcp.json) default MCP to http://localhost:3000/mcp (Docker). Change the URL for a company instance; they contain no secrets. Contributors working in this repository: read AGENTS.md.
>
> **Looking for the tool reference?** See TOOLS.md for descriptions, arguments, and a decision guide for each tool the MCP server exposes (pipeshub_chat, pipeshub_search, pipeshub_get_record_content, pipeshub_download_record, pipeshub_directory, pipeshub_sources, pipeshub_agents).
>
> **Using QM?** QM cannot attach a third-party MCP endpoint — it is an MCP *server* to its own harness, not a client. Follow Use PipesHub with QM. The deployment-layer bundle in qm/ gives agents a pipeshub command inside their sandbox; this package ships that command as a second bin.
Prerequisites
- A running PipesHub instance (self-hosted or cloud). If they have none yet, the local Docker demo playbook covers install and first-run — do not scaffold LangChain. First-run (account + LLM) is still in the browser; search 500s until an LLM is configured.
- An OAuth app created in PipesHub (see Step 1)
Step 1: Create an OAuth App in PipesHub
1. Log in to your PipesHub instance as an admin
2. Navigate to **Settings > Developer Settings > OAuth Apps**
3. Click **Create OAuth App**
4. Fill in the app details:
- **Name**: e.g., MCP Integration
- **Redirect URIs**: Add all the redirect URIs for the clients you plan to use:
| Client | Redirect URI |
|---|---|
| **Cursor** | cursor://anysphere.cursor-mcp/oauth/callback |
| **Claude Code** | http://localhost: /callback (e.g., http://localhost:8080/callback) |
| **Claude.ai (Web)** | https://claude.ai/api/mcp/auth_callback |
| **Gemini CLI** | http://localhost:7777/oauth/callback |
| **LibreChat** | http://localhost:3080/api/mcp/ /oauth/callback |
> **Important:** The scopes in MCP_SCOPES must match the scopes granted to your OAuth app — a mismatch will result in an authorization error.
5. Save the app and copy the **Client ID** and **Client Secret**
Customizing Default Scopes
By default, PipesHub exposes some default scopes in its /.well-known/oauth-protected-resource/mcp discovery endpoint. You can customize which scopes are exposed by setting the MCP_SCOPES environment variable on your PipesHub instance. This is useful for clients like Claude Code that automatically request all exposed scopes.
Placeholders
Replace these in all configurations below:
| Placeholder | Description | Example |
|---|---|---|
| PIPESHUB_INSTANCE_URL | Your PipesHub instance URL | https://app.pipeshub.com |
| YOUR_CLIENT_ID | OAuth app client ID | clid_abc123... |
| YOUR_CLIENT_SECRET | OAuth app client secret | clsec_xyz789... |
The remote MCP endpoint URL is: PIPESHUB_INSTANCE_URL/mcp
---
Remote MCP Setup
Cursor
Cursor supports static OAuth for remote MCP servers via the auth object in mcp.json.
Configuration
Open Cursor Settings > Tools and Integrations > New MCP Server, or edit your project's .cursor/mcp.json:
Cursor will auto-discover the authorization and token endpoints via PipesHub's /.well-known/oauth-protected-resource/mcp metadata.
> **Note:** If the scopes field is omitted, Cursor fetches /.well-known/oauth-protected-resource/mcp and requests **all** scopes_supported listed there. To limit access, explicitly list only the scopes you need. You can also control which scopes are exposed server-side — see Customizing Default Scopes.