remote mcp
Serve the files, shell and tasks of a sandbox on a server as MCP tools over stdio.
Experimental. The tools and options can still change between releases.
remote mcp is a Model Context Protocol server on stdio for one
sandbox on a server. An MCP client starts it as a command
and gets tools to read, search and edit the sandbox's files, run commands and published
tasks on it, check them before a push, show what changed and push it to a branch. Like remote, it needs no build file: the tasks are the
published ones. The tools, the sign-in and the shell task are described in
Agents. It is a remote command, so a task
named mcp still runs with hammerkit mcp.
hammerkit remote mcp --server corp --sandbox sbx_4vJ0mT2cX9qLw1aB --build sha256:9f2c...| Option | What it does |
|---|---|
--server <name> | The registered server, HAMMERKIT_SERVER. Default: the one remote use set, else the only one. |
--sandbox <id> | A sandbox of yours on it, HAMMERKIT_SANDBOX. |
--repo <repo>, --ref <ref> | Instead: a sandbox of this repository at this branch, HAMMERKIT_REPO and HAMMERKIT_REF. One of yours without changes is checked out at the branch again, otherwise a new one is created. |
--build <hash> | The hash of the published version of the build file whose tasks run on the sandbox, as remote publish printed it, HAMMERKIT_BUILD. |
--shell <task> | Its task whose last command is a shell, sh by default, HAMMERKIT_SHELL. --shell '' leaves out bash. |
Standard output carries the protocol only; what remote mcp has to say goes to standard
error, warnings about the build file in the working directory too. It stops when the client
closes its input.