A EVM-compatible blockchain toolkit for your AI Agents powered by Foundry
A EVM-compatible blockchain toolkit for your AI Agents powered by Foundry. The foundry mcp server wraps that behind the Model Context Protocol, so an assistant can use it through 8 defined tools rather than through you.
A simple, lightweight and fast MCP (Model Context Protocol) server that provides Solidity development capabilities using the Foundry toolchain (Forge, Cast, and Anvil).
This server connects LLM assistants to the Foundry ecosystem, enabling them to:
The server ships on npm as @pranesh.asp/foundry-mcp-server, so your MCP client can launch it on demand — there is no separate build step. Add the server block to your client's configuration, restart it, and the tools register themselves.
Everything the assistant can do here goes through one of these:
Requirements — The Requirements tool exposed by this serverConfiguration — The Configuration tool exposed by this serverWorkspace — The server maintains a persistent Forge workspace at ~/.mcp-foundry-workspace for all Solidity files, scripts, and dependenciesAnvil — The Anvil tool exposed by this serverCast — The Cast tool exposed by this serverForge — The Forge tool exposed by this serverUtilities — The Utilities tool exposed by this serverExamples — 1. Transaction analysis: Can you analyze the transaction and explain what it does? https://etherscan.io/tx/0xcb73ad3116f19358e2e649d4dc801b7ae0590You will need 2 environment variables: PRIVATE_KEY, RPC_URL. The server will not start without them, which is usually why the tools fail to appear on a first run. Keep credentials in your client's env block or a secrets manager rather than in a file you might commit.
Among the developer tooling options, the useful question is rarely "what can it do" but "what does it cost you to run" — permissions, credentials, and how much of your context its toolset consumes. Foundry's toolset — Requirements, Configuration, Workspace and 5 more — is a fair guide to whether it matches your workflow. It is maintained by PraneshASP; worth a glance at recent repository activity before you build anything load-bearing on it.
This entry was verified against Foundry's own documentation before publication; SyncDev keeps the directory reviewed rather than auto-generated.
| Tool | What it does |
|---|---|
| Requirements | The Requirements tool exposed by this server. |
| Configuration | The Configuration tool exposed by this server. |
| Workspace | The server maintains a persistent Forge workspace at ~/.mcp-foundry-workspace for all Solidity files, scripts, and dependencies. |
| Anvil | The Anvil tool exposed by this server. |
| Cast | The Cast tool exposed by this server. |
| Forge | The Forge tool exposed by this server. |
| Utilities | The Utilities tool exposed by this server. |
| Examples | 1. **Transaction analysis**: Can you analyze the transaction and explain what it does? https://etherscan.io/tx/0xcb73ad3116f19358e2e649d4dc801b7ae0590a47b8bb2e57a8e98b6daa5fb14b |
"mcpServers": {
"foundry": {
"command": "node",
"args": [
"path/to/foundry-mcp-server/dist/index.js"
],
"env" :{
"PRIVATE_KEY": "0x1234",
}
}
}Configuration as documented by the project. Restart the client after saving.
| Variable | Description | Required |
|---|---|---|
| PRIVATE_KEY | Credential the server authenticates with. | Yes |
| RPC_URL | Endpoint or connection string the server talks to. | Yes |
Kill hallucinated APIs — version-accurate, up-to-date library documentation injected straight into context.
Microsoft's official browser automation server — drive a real browser through the accessibility tree, no screenshots needed.
GitHub's official server — repos, issues, pull requests, Actions and code security, straight from your assistant.
Issue tracking at the speed of conversation — Linear's official hosted server with OAuth and zero install.
Local repository surgery — status, diffs, commits, branches and history for any repo on disk.
Timezone sanity for AI — current time anywhere and correct conversions, without the model doing date math.