Skip to content

Commit ba020ed

Browse files
docs: add Claude Code onboarding instructions (#49)
* docs: add Claude Code onboarding instructions for MCP server setup Add a Claude Code section to the README covering all transport modes: - STDIO with Docker (CLI and .mcp.json) - STDIO with JAR (CLI and .mcp.json) - HTTP mode (CLI and .mcp.json) Signed-off-by: Aditya Parikh <adityamparikh@gmail.com> Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: adityamparikh <aditya.m.parikh@gmail.com> * fix(docs): use -e short flag for claude mcp add env vars The --env long form with variadic args greedily consumes the next positional argument (the server name), causing a parse error. Use the -e short form which works correctly. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: adityamparikh <aditya.m.parikh@gmail.com> --------- Signed-off-by: adityamparikh <aditya.m.parikh@gmail.com> Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
1 parent ef1bac0 commit ba020ed

1 file changed

Lines changed: 81 additions & 0 deletions

File tree

README.md

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,87 @@ Then add to your `claude_desktop_config.json`:
178178

179179
More configuration options: docs/DEPLOYMENT.md#docker-images-with-jib
180180

181+
### Claude Code
182+
183+
Add Solr MCP to [Claude Code](https://docs.anthropic.com/en/docs/claude-code) using the CLI or by adding a `.mcp.json` file to your project root.
184+
185+
**STDIO mode (default)**
186+
187+
Using Docker (CLI):
188+
```bash
189+
claude mcp add --transport stdio solr-mcp -- docker run -i --rm ghcr.io/apache/solr-mcp:latest
190+
```
191+
192+
Using JAR (CLI):
193+
```bash
194+
claude mcp add --transport stdio -e SOLR_URL=http://localhost:8983/solr/ solr-mcp -- java -jar /absolute/path/to/solr-mcp-1.0.0-SNAPSHOT.jar
195+
```
196+
197+
Or add to your project's `.mcp.json`:
198+
199+
Using Docker:
200+
```json
201+
{
202+
"mcpServers": {
203+
"solr-mcp": {
204+
"type": "stdio",
205+
"command": "docker",
206+
"args": ["run", "-i", "--rm", "ghcr.io/apache/solr-mcp:latest"],
207+
"env": {
208+
"SOLR_URL": "http://localhost:8983/solr/"
209+
}
210+
}
211+
}
212+
}
213+
```
214+
215+
Using JAR:
216+
```json
217+
{
218+
"mcpServers": {
219+
"solr-mcp": {
220+
"type": "stdio",
221+
"command": "java",
222+
"args": ["-jar", "/absolute/path/to/solr-mcp-1.0.0-SNAPSHOT.jar"],
223+
"env": {
224+
"SOLR_URL": "http://localhost:8983/solr/"
225+
}
226+
}
227+
}
228+
}
229+
```
230+
231+
**HTTP mode**
232+
233+
Start the server first (pick one):
234+
```bash
235+
# Gradle
236+
PROFILES=http ./gradlew bootRun
237+
238+
# JAR
239+
PROFILES=http java -jar build/libs/solr-mcp-1.0.0-SNAPSHOT.jar
240+
241+
# Docker
242+
docker run -p 8080:8080 --rm -e PROFILES=http ghcr.io/apache/solr-mcp:latest
243+
```
244+
245+
Then add to Claude Code:
246+
```bash
247+
claude mcp add --transport http solr-mcp http://localhost:8080/mcp
248+
```
249+
250+
Or add to `.mcp.json`:
251+
```json
252+
{
253+
"mcpServers": {
254+
"solr-mcp": {
255+
"type": "http",
256+
"url": "http://localhost:8080/mcp"
257+
}
258+
}
259+
}
260+
```
261+
181262
## Security (OAuth2)
182263
183264
The Solr MCP server supports OAuth2 authentication when running in HTTP mode, providing secure access control for your

0 commit comments

Comments
 (0)