- Home
- MCP servers
- Consul
Consul
- typescript
16
GitHub Stars
typescript
Language
4 months ago
First Indexed
3 weeks ago
Catalog Refreshed
Documentation & install
Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.
Installation
Add the following to your MCP client configuration file.
Configuration
View docs{
"mcpServers": {
"kocierik-consul-mcp-server": {
"command": "node",
"args": [
"/ABSOLUTE/PATH/TO/PARENT/FOLDER/consul-mcp-server/build/index.js"
],
"env": {
"CONSUL_HOST": "localhost",
"CONSUL_PORT": "8500"
}
}
}
}You can access Consul functionality through a dedicated MCP server that exposes Consul features via a standardized interface. This lets you manage services, health checks, KV storage, sessions, events, queries, and more from any MCP-compatible client without talking directly to the Consul API.
How to use
You will run the MCP server locally and connect your MCP client to it. The server exposes core Consul capabilities such as service management, health checks, key-value storage, and agent/system information. Use your MCP client to call the available endpoints to list, create, update, or delete resources, all through the consistent MCP interface.
How to install
Prerequisites you need before installing: Node.js and npm installed on your system.
Install dependencies, build, and run the server with these steps.
npm install
npm run build
node build/index.js
Configuration and running
Configure the MCP server to connect to your Consul instance using environment variables. The following variables are supported.
CONSUL_HOST=localhost
CONSUL_PORT=8500
Notes for Claude/Inspector integration
If you use Claude with MCP, you can provide a runtime config that runs the MCP server as a stdio process. The typical command is node with the path to the built entry point. You may also run the inspector to validate the MCP interface during development.
Available tools
listServices
List running services registered in Consul via MCP
registerService
Register a new service with Consul through MCP
deregisterService
Deregister an existing service via MCP
getServiceInfo
Get detailed information about a specific service
listCatalogServices
List catalog services from Consul
getCatalogServiceInfo
Get catalog information for a service
registerHealthCheck
Register a health check that runs for a service
deregisterHealthCheck
Remove a registered health check
getHealthChecks
Retrieve health checks for a service
kvGet
Get a value from the key-value store
kvList
List keys in the key-value store
kvPut
Put a value into the key-value store
kvDelete
Delete a key from the key-value store
listSessions
List active sessions
destroySession
Destroy a session
fireEvent
Fire an event in Consul
listEvents
List events
createPreparedQuery
Create a prepared query for repeated use
executePreparedQuery
Execute a prepared query
getLeader
Get the current leader of the Consul cluster
getPeers
Get current peers in the cluster
getAgentMembers
Get member information for the Consul agent
getAgentSelf
Get information about the agent itself
getSystemHealth
Get system health information