Skip to content
Empryo

MCP Servers

Connect Empryo to Model Context Protocol (MCP) servers over stdio, HTTP or SSE, so the agent can use their tools next to the built-in ones.

Tools6 minutes to read
Copy & share
On this page10 sections

MCP (Model Context Protocol) is an open standard for giving AI agents extra tools. Connect an MCP server to Empryo and the agent can call its tools, for example to open GitHub issues or query Sentry, alongside its built-in tools.

Use it when the agent needs a service Empryo does not cover out of the box.

Quick startLink to this section

Add a server to mcpServers in your config. This one runs the GitHub server as a local process:

json
{
  "mcpServers": [
    {
      "name": "github",
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-github"],
      "env": { "GITHUB_TOKEN": "ghp_..." }
    }
  ]
}

Restart Empryo or open /mcp to check it connected. The server's tools are now available to the agent as mcp__github__<tool>.

Configs copied from Claude Code, Cursor, Gemini CLI, Windsurf or OpenCode work as they are. Empryo reads an object keyed by server name, type (stdio, local, http, streamable-http, remote, sse), httpUrl/serverUrl, a command array, environment and enabled: false. An entry with only a url connects over http, or sse when the URL ends in /sse.

Where the config livesLink to this section

  • Global: ~/.empryo/config.json (on Windows %LOCALAPPDATA%\Empryo\config.json) applies to every project.
  • Project: .empryo/config.json applies to one repository. A project server with the same name as a global one replaces it.

A project's MCP servers start when you open the project. Each server is a command on your machine, so read mcpServers before you open a repository you did not write.

Three ways to connectLink to this section

TransportUse it forNeeds
stdio (default)A server that runs as a local programcommand, optional args, env, cwd
httpA remote server over Streamable HTTP. Use this for new remote serversurl, optional headers
sseOlder remote servers that only speak Server-Sent Eventsurl, optional headers
json
{
  "mcpServers": [
    {
      "name": "sentry",
      "transport": "http",
      "url": "https://mcp.sentry.dev/mcp"
    },
    {
      "name": "legacy-service",
      "transport": "sse",
      "url": "https://legacy.example.com/events",
      "disabled": true
    }
  ]
}

SettingsLink to this section

FieldTypeWhat it does
namestring (required)The server's name. Also the prefix of its tool names
transport"stdio" \"http" \"sse"How to connect. Default "stdio"
commandstringProgram to start (stdio)
argsstring[]Arguments for command
envRecord<string,string>Extra environment variables for the program. It also gets your shell's environment and PATH, so tokens you export and tools from nvm, Homebrew, mise or uv are found
cwdstringWorking directory for the program (stdio). Default: the project root. A relative path is read from the project root
urlstringServer address (http, sse)
headersRecord<string,string>HTTP headers, such as Authorization (http, sse)
timeoutnumberTime limit for each tool call, in ms. Default 30000
disabledbooleanKeep the entry but don't connect
residentbooleanAlways send this server's tools to the model instead of loading them on demand. Use it for a server you rely on every turn. The set is fixed when a session starts, so the prompt cache holds: a server pinned later, or one that was not connected at startup, is reached on demand until the next session, and a pinned server that disconnects keeps its tools, which answer that it is not connected
redirect"follow" \"error"Whether a remote server may redirect. Set "follow" only if the server needs it
oauthboolean \objectSign in through the browser when a remote server asks for it. On by default for http and sse servers that don't send their own Authorization header. For a server that only accepts apps it registered, pass that app: { "clientId": "...", "clientSecret": "...", "issuer": "...", "scope": "...", "callbackPort": 33418 }

Keep secrets out of the fileLink to this section

Write ${NAME} (or {env:NAME}) in command, args, env, cwd, url or headers and Empryo fills it from your shell when the server starts. ${NAME:-fallback} uses the fallback when NAME is not set. A committed project config can then name the token without containing it:

json
{
  "mcpServers": {
    "github": {
      "type": "http",
      "url": "https://api.githubcopilot.com/mcp/",
      "headers": { "Authorization": "Bearer ${GITHUB_TOKEN}" }
    }
  }
}

If a server fails and a variable it names is not set, the status says which one.

Servers that need a sign-inLink to this section

Remote servers like Linear or Notion ask you to sign in. Add the server with its URL; when it first connects, Empryo opens your browser, you sign in, and the server connects on its own. If no browser can open (SSH, CI), the server's status shows the link to open. The sign-in is saved per server and refreshed for you; delete the server to forget it.

Some servers only let apps they approved sign in (Figma's remote server is one). The status says so. If the service lets you register your own app, put its clientId (and clientSecret, scope, and the callbackPort you registered as http://127.0.0.1:<port>/callback) in oauth. With a clientSecret, also set issuer to the sign-in service's issuer URL, so the secret is only ever sent there. Otherwise use its local or token-based server.

Tool namesLink to this section

Every MCP tool is renamed to mcp__<server>__<tool> so it can never clash with a built-in tool. A server named github with a tool create_issue gives the agent mcp__github__create_issue.

Connection behaviorLink to this section

  • All enabled servers connect when Empryo starts, up to four at a time.
  • If a local (stdio) server crashes, Empryo restarts it, up to three times with a growing delay.
  • If a local server fails to start, its status shows the last lines it printed to stderr, which usually name the missing token or package.
  • A remote server that is down or unreachable is retried up to three times with a growing delay. One that refuses (a wrong URL or a sign-in) stays failed until you retry it from /mcp.
  • An http server that answers 404 or 405 is tried again over sse, for older servers.
  • If a remote server forgets the session (after it restarts), Empryo reconnects and runs the tool call again.
  • When a server gives up after three restarts, its status keeps the last error.
  • When a server changes its tool list (notifications/tools/list_changed), Empryo fetches it again. From the next step of the same turn, new tools can be called through code_script, and through run_tool when tools load on demand. When every tool is loaded up front, the tool list stays as the session started, so the new tools are reached through code_script. Your tool list and system prompt do not change mid-session, so the prompt cache holds. Pinned (resident) servers keep the schemas the session started with but always run the server's current tool.
  • When Empryo exits, it closes every connection and stops every local server.

Manage servers in the terminal UILink to this section

Run /mcp to see each server's status and tools.

KeyAction
TypeFilter servers by name
Ctrl+AAdd a server
Ctrl+EEdit the selected server
Ctrl+DDelete the selected server
Ctrl+TTurn the selected server on or off
Ctrl+RReconnect a failed server
Ctrl+PPing a connected server
TabSwitch to the tools list
EnterOpen the server's details

Headless runsLink to this section

MCP servers also connect in headless mode, so scripts and CI jobs can use them:

bash
empryo --headless "use the github MCP to list open issues"