@openctx/provider-mcp
v0.0.13
Published
Use information from MCP providers
Downloads
117
Readme
MCP proxy for OpenCtx
This is a context provider for OpenCtx that fetches contents from a MCP provider for use as context.
Currently, only MCP over stdio is supported (HTTP is not yet supported).
Development
- Clone the modelcontextprotocol/servers repository. Follow the instructions there to build the example providers. This should generate output files of the form
build/${example_name}/index.js
. - Run
pnpm watch
in this directory. - Add the following to your VS Code settings:
"openctx.providers": { // ...other providers... "https://openctx.org/npm/@openctx/modelcontextprotocol": { "nodeCommand": "node", "mcp.provider.uri": "file:///path/to/servers/root/build/everything/index.js", } }
- Reload the VS Code window. You should see
servers/everything
in the@
-mention dropdown.
To hook up to the Postgres MCP provider, use:
"openctx.providers": {
// ...other providers...
"https://openctx.org/npm/@openctx/modelcontextprotocol": {
"nodeCommand": "node",
"mcp.provider.uri": "file:///path/to/servers/root/build/postgres/index.js",
"mcp.provider.args": [
"postgresql://sourcegraph:sourcegraph@localhost:5432/sourcegraph"
]
}
}
More MCP Servers
The following MCP servers are available in the modelcontextprotocol/servers repository:
- Postgres - Connect to your Postgres databases to query schema information and write optimized SQL
- Everything - A demo server showing MCP capabilities
- Google Drive - Search and access your Google Drive documents
- Giphy - Search gifs
- Git - Get git history and commit information
- HubSpot - Access your HubSpot CRM data
- OSAScript - Execute AppleScript commands on macOS
- Puppeteer - Control headless Chrome for web automation
- Spotify - Access Spotify music data and playlists
Creating your own MCP server
See the MCP docs for how to create your own MCP servers.