Skip to content

Creating MCP Servers

MCP (Model Context Protocol) servers extend Gee-Code with additional tools — database connections, API integrations, filesystem access, and more. When configured, their tools become available alongside Gee-Code’s built-in tools.

CreateMCPServer(
name="filesystem",
command="npx",
args=["-y", "@modelcontextprotocol/server-filesystem", "/path/to/project"],
description="Filesystem access for project files"
)

Add .mcp.json to your plugin:

{
"servers": {
"postgres": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-postgres"],
"env": { "DATABASE_URL": "postgresql://localhost/mydb" }
}
}
}
---
name: db-assistant
mcp_servers:
- name: postgres
command: npx
args: ["-y", "@modelcontextprotocol/server-postgres"]
env:
DATABASE_URL: "${POSTGRES_URL}"
---
FieldRequiredDescription
nameYesUnique server identifier
commandYesCommand to run (npx, python, node)
argsNoCommand arguments
envNoEnvironment variables (supports ${VAR} references)
descriptionNoHuman-readable description

MCP tools are registered with a namespaced prefix:

mcp__{server_name}__{tool_name}

For example, a PostgreSQL server named postgres with a query tool appears as mcp__postgres__query. The AI uses these tools naturally based on the task.

/mcp # List configured MCP servers
/mcp list # Show all servers with status

Delete a server you created:

DeleteMCPServer(server_name="postgres")
ServerPackageUse Case
Filesystem@modelcontextprotocol/server-filesystemFile access with path constraints
PostgreSQL@modelcontextprotocol/server-postgresDatabase queries
SQLite@modelcontextprotocol/server-sqliteLocal database access
GitHub@modelcontextprotocol/server-githubGitHub API integration
Brave Search@modelcontextprotocol/server-brave-searchWeb search

MCP server tools are subject to the same guardrails as built-in tools. If a guardrail blocks a tool name, it applies to MCP tools too.