redis-mcp
6
The Redis MCP Server is designed to provide access to Redis database operations through the Model Context Protocol. It supports various Redis commands for managing hashes, strings, keys, and sorted sets. The server is integrated with MCP clients for seamless usage.
Redis MCP Server
A Model Context Protocol (MCP) server that provides access to Redis database operations.
Available Tools
- hmset: Set multiple hash fields to multiple values
- hget: Get the value of a hash field
- hgetall: Get all fields and values in a hash
- scan: Scan Redis keys matching a pattern
- set: Set string value with optional NX and PX options
- get: Get string value
- del: Delete a key
- zadd: Add one or more members to a sorted set
- zrange: Return a range of members from a sorted set by index
- zrangebyscore: Return members from a sorted set with scores between min and max
- zrem: Remove one or more members from a sorted set
- sadd: Add one or more members to a set
- smembers: Get all members in a set
Usage
Configure in your MCP client (e.g., Claude Desktop) using command line arguments like --redis-host
and --redis-port
.
Development
Add a new Redis tool by creating a new class extending RedisTool
, defining its interface, and registering it within the tool registry.