Skip to content

Commit 1f675b0

Browse files
authored
Merge pull request #7 from nafraf/vs-code-integration
Add VS Code integration instructions
2 parents 61585cf + d131c80 commit 1f675b0

File tree

1 file changed

+71
-4
lines changed

1 file changed

+71
-4
lines changed

README.md

Lines changed: 71 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ export OPENAI_API_KEY=""
9090
And run the [application](./examples/redis_assistant.py).
9191

9292
```commandline
93-
python3.13 redis_assistant.py
93+
python3.13 redis_assistant.py
9494
```
9595

9696
You can troubleshoot your agent workflows using the [OpenAI dashboard](https://platform.openai.com/traces/).
@@ -105,7 +105,7 @@ If you'd like to test the [Redis MCP Server](https://smithery.ai/server/@redis/m
105105
npx -y @smithery/cli install @redis/mcp-redis --client claude
106106
```
107107

108-
Follow the prompt and provide the details to configure the server and connect to Redis (e.g. using a Redis Cloud database).
108+
Follow the prompt and provide the details to configure the server and connect to Redis (e.g. using a Redis Cloud database).
109109
The procedure will create the proper configuration in the `claude_desktop_config.json` configuration file.
110110

111111
### Manual configuration
@@ -114,7 +114,7 @@ You can configure Claude Desktop to use this MCP Server.
114114

115115
1. Specify your Redis credentials and TLS configuration
116116
2. Retrieve your `uv` command full path (e.g. `which uv`)
117-
3. Edit the `claude_desktop_config.json` configuration file
117+
3. Edit the `claude_desktop_config.json` configuration file
118118
- on a MacOS, at `~/Library/Application\ Support/Claude/`
119119

120120
```commandline
@@ -183,6 +183,73 @@ You can troubleshoot problems by tailing the log file.
183183
tail -f ~/Library/Logs/Claude/mcp-server-redis.log
184184
```
185185

186+
## Integration with VS Code
187+
188+
To use the Redis MCP Server with VS Code, you need:
189+
190+
1. Enable the [agent mode](https://code.visualstudio.com/docs/copilot/chat/chat-agent-mode) tools. Add the following to your `settings.json`:
191+
192+
```commandline
193+
{
194+
"chat.agent.enabled": true
195+
}
196+
```
197+
198+
2. Add the Redis MCP Server configuration to your `mcp.json` or `settings.json`:
199+
200+
```commandline
201+
// Example .vscode/mcp.json
202+
{
203+
"servers": {
204+
"redis": {
205+
"type": "stdio",
206+
"command": "",
207+
"args": [
208+
"--directory",
209+
"",
210+
"run",
211+
"src/main.py"
212+
],
213+
"env": {
214+
"REDIS_HOST": "",
215+
"REDIS_PORT": "",
216+
"REDIS_USERNAME": "",
217+
"REDIS_PWD": "",
218+
}
219+
}
220+
}
221+
}
222+
```
223+
224+
```commandline
225+
// Example settings.json
226+
{
227+
"mcp": {
228+
"servers": {
229+
"redis": {
230+
"type": "stdio",
231+
"command": "",
232+
"args": [
233+
"--directory",
234+
"",
235+
"run",
236+
"src/main.py"
237+
],
238+
"env": {
239+
"REDIS_HOST": "",
240+
"REDIS_PORT": "",
241+
"REDIS_USERNAME": "",
242+
"REDIS_PWD": "",
243+
}
244+
}
245+
}
246+
}
247+
}
248+
```
249+
250+
For more information, see the [VS Code documentation](https://code.visualstudio.com/docs/copilot/chat/mcp-servers).
251+
252+
186253
## Testing
187254

188255
You can use the [MCP Inspector](https://modelcontextprotocol.io/docs/tools/inspector) for visual debugging of this MCP Server.
@@ -207,4 +274,4 @@ npx @modelcontextprotocol/inspector uv run src/main.py
207274
This project is licensed under the **MIT License**.
208275

209276
## Contact
210-
For questions or support, reach out via [GitHub Issues](https://github.com/redis/mcp-redis/issues).
277+
For questions or support, reach out via [GitHub Issues](https://github.com/redis/mcp-redis/issues).

0 commit comments

Comments
 (0)