Overview
The ScopeDocs MCP server exposes your workspace's documentation and knowledge graph to any AI assistant that supports the Model Context Protocol. Once connected, your AI assistant can search and retrieve context from your codebase docs directly within its reasoning — without you having to copy-paste anything.
The server is hosted remotely at {API_BASE_URL}/mcp and supports both MCP transports on that single URL: Streamable HTTP (recommended) and legacy SSE for older clients. Clients that require a local stdio process can use mcp-remote as a bridge.
The server exposes 29 tools. Tool names below are exactly what your client sees — no route suffix to decode.
Retrieval — Return the evidence itself, so your assistant reasons over the raw material instead of a summary of it.
| Tool | Description |
|---|---|
search_code | Search indexed code and return the matching chunks themselves. |
search_context | Search the non-code knowledge — Slack threads, tickets, PRs, wiki pages. |
search_docs | Vector search over generated documentation, optionally filtered by category. |
get_snippet | Read the actual source lines behind a search hit or citation. |
get_file_context | Everything indexed about one file: chunks, graph nodes, generated docs. |
Documentation and wiki — The prose ScopeDocs generates and keeps up to date.
| Tool | Description |
|---|---|
list_docs | List generated documentation. |
get_doc | Retrieve a specific generated document. |
generate_doc | Trigger documentation generation for a graph node. |
get_wiki | The generated wiki index for a repo — module list, staleness, freshness. |
get_wiki_page | One wiki page with its full markdown. |
Code graph — Structure, ownership, and blast radius.
| Tool | Description |
|---|---|
list_graph_repos | List repositories that have graph/embedding/doc data. |
get_full_graph | Return the full knowledge graph (nodes + edges) for a repository. |
get_node | Return a single graph node with its linked documentation. |
get_node_context | Discussion attached to a code node — the Linear issues and Slack threads about it. |
get_node_cross_refs | Cross-references between code and database schema for a node. |
impact | Map blast radius for a target — direct consumers, recent incidents, verdict. |
Change history and delivery — What changed, why, and whether it matched the spec.
| Tool | Description |
|---|---|
get_pr_timeline | Change history for a repo — PRs/MRs newest first, with the why-summary when one has been generated. |
get_pr | Return a PR with its cached explanation snapshot (if available). |
get_repo_story | The generated narrative of how a repo evolved, read from cache. |
get_scope_report | Agreed-vs-built report: what was agreed, what got added later, and what shipped that nobody agreed to. |
drift_check | Run a spec drift check: does this code change actually implement this spec? |
drift_run_report | Fetch the report for a spec drift run. |
Ask a question — One call that searches everything and answers in prose, with citations.
| Tool | Description |
|---|---|
ask | Ask a question about this workspace and get an answer with citations. |
rate_answer | Rate an answer a previous `ask` call returned. |
Workspace and connection state — What this key can see, and whether the data is there yet.
| Tool | Description |
|---|---|
get_caller_identity | Identity attached to this API key. |
get_workspace_info | Return workspace(s) accessible to this API key. |
get_index_status | Per-repo indexing status — is a repo indexed, indexing, or failed. |
get_integration_status | Return which integrations are connected for the workspace(s) accessible to this API key. |
get_integration_sync_status | Return last sync timestamps for each integration for the workspace(s) accessible to this API key. |
Tip:Start with
get_index_status. Every other tool depends on the repo having been indexed, and it is the fastest way to tell an empty answer apart from an unindexed repo.
Prerequisites
You need a ScopeDocs API key with the relevant scopes. Create one in Settings → Organization.
The following scopes are required depending on which MCP tools you want to expose:
| Scope | Description |
|---|---|
docs:read | `get_doc`, `get_scope_report`, `get_wiki`, `get_wiki_page`, `list_docs`, `search_context`, `search_docs` |
docs:write | `generate_doc` |
graph:read | `get_file_context`, `get_full_graph`, `get_node`, `get_node_context`, `get_node_cross_refs`, `get_snippet`, `impact`, `list_graph_repos`, `search_code` |
prs:read | `drift_check`, `drift_run_report`, `get_pr`, `get_pr_timeline`, `get_repo_story` |
chat:write | `ask`, `rate_answer` |
workspace:read | `get_caller_identity`, `get_index_status`, `get_integration_status`, `get_integration_sync_status`, `get_workspace_info` |
Tip:Create a dedicated key named something like
mcp-claudeso you can revoke it independently if needed.
Configuration
Pick the client you use and paste the matching config. Replace <your_api_key> with your actual API key before saving.
claude mcp add scopedocs \
--transport http \
"https://api.scopedocs.ai/mcp" \
--header "Authorization: Bearer <your_api_key>"Use npx mcp-remote for clients that only support a local stdio process. If your MCP client supports streamableHttp natively, use the Direct HTTP tab instead. Clients that only speak the legacy SSE transport can point at the same URL — {API_BASE_URL}/mcp serves both transports (SSE clients use "type": "sse" or the equivalent setting).
Note:Using an environment variable for the key keeps secrets out of version control when the config file is committed or synced.
Client notes
- Claude Code: the CLI command is the quickest setup path and avoids editing JSON by hand.
- Cursor: open
Settings → MCP, then add the server or paste the JSON into~/.cursor/mcp.json. - Cline: open
MCP Servers → Edit Configand ensuremcpServersstays at the top level. - Other clients: if they support
streamableHttpdirectly, nomcp-remotebridge is needed.
Warning:Restart the client after saving the config. The
scopedocsserver should appear as active before you start prompting.
Usage
Once the server is connected, your AI assistant can reference ScopeDocs context automatically. You can also prompt it explicitly:
- "Search the docs for how authentication works in this project."
- "Use ScopeDocs to find all functions related to the ingestion pipeline."
- "What does the
EmbeddingServiceclass do? Check the ScopeDocs knowledge graph."
The assistant will call the appropriate MCP tool, retrieve the relevant documentation, and incorporate it into its response.
Troubleshooting
401 Unauthorized
Your API key is missing, malformed, or has been revoked. Check that:
- The
Authorizationheader is set toBearer <your_api_key>(with theBearerprefix) - The key hasn't expired — check Settings → Organization
- The key has the required scopes for the tools you're using
Connection timeout / server not reachable
- Confirm your network can reach
{API_BASE_URL} - If you're behind a corporate proxy, you may need to whitelist the domain
- Try running
npx mcp-remote {API_BASE_URL}/mcpdirectly in your terminal to test connectivity
No results returned
- Try broader or different keywords — the search is semantic, not keyword-exact
- Check that your workspace has indexed documentation. Go to your dashboard and verify docs are present
- Ensure the API key has
docs:readscope for search tools