Skip to content

Commit 1ee0ca4

Browse files
authored
Readme Fix, Added new unit test (#345)
* initial Signed-off-by: Rakhi Dutta <[email protected]> * update readme,unit test Signed-off-by: Rakhi Dutta <[email protected]> * update readme,unit test Signed-off-by: Rakhi Dutta <[email protected]> * update readme,unit test Signed-off-by: Rakhi Dutta <[email protected]> * Readme fix Signed-off-by: Rakhi Dutta <[email protected]> * Readme fix Signed-off-by: Rakhi Dutta <[email protected]> --------- Signed-off-by: Rakhi Dutta <[email protected]>
1 parent 409f20f commit 1ee0ca4

File tree

3 files changed

+389
-6
lines changed

3 files changed

+389
-6
lines changed

README.md

Lines changed: 37 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -255,18 +255,24 @@ python3 -m mcpgateway.translate --stdio "uvx mcp-server-git" --port 9000
255255
# 2️⃣ Register it with the gateway
256256
curl -s -X POST -H "Authorization: Bearer $MCPGATEWAY_BEARER_TOKEN" \
257257
-H "Content-Type: application/json" \
258-
-d '{"name":"fast_time","url":"http://localhost:8002/sse"}' \
258+
-d '{"name":"fast_time","url":"http://localhost:9000/sse"}' \
259259
http://localhost:4444/gateways
260260

261261
# 3️⃣ Verify tool catalog
262262
curl -s -H "Authorization: Bearer $MCPGATEWAY_BEARER_TOKEN" http://localhost:4444/tools | jq
263263

264-
# 4️⃣ Create a *virtual server* bundling those tools
264+
# 4️⃣ Create a *virtual server* bundling those tools. Use the ID of tools from the tool catalog (Step #3) and pass them in the associatedTools list.
265265
curl -s -X POST -H "Authorization: Bearer $MCPGATEWAY_BEARER_TOKEN" \
266266
-H "Content-Type: application/json" \
267-
-d '{"name":"time_server","description":"Fast time tools","associatedTools":["1"]}' \
267+
-d '{"name":"time_server","description":"Fast time tools","associatedTools":[<ID_OF_TOOLS>]}' \
268268
http://localhost:4444/servers | jq
269269

270+
# Example curl
271+
curl -s -X POST -H "Authorization: Bearer $MCPGATEWAY_BEARER_TOKEN"
272+
-H "Content-Type: application/json"
273+
-d '{"name":"time_server","description":"Fast time tools","associatedTools":["6018ca46d32a4ac6b4c054c13a1726a2"]}' \
274+
http://localhost:4444/servers | jq
275+
270276
# 5️⃣ List servers (should now include the UUID of the newly created virtual server)
271277
curl -s -H "Authorization: Bearer $MCPGATEWAY_BEARER_TOKEN" http://localhost:4444/servers | jq
272278

@@ -355,6 +361,12 @@ Browse to **[http://localhost:4444/admin](http://localhost:4444/admin)** (user `
355361
```bash
356362
mkdir -p $(pwd)/data
357363

364+
touch $(pwd)/data/mcp.db
365+
366+
sudo chown -R :docker $(pwd)/data
367+
368+
chmod 777 $(pwd)/data
369+
358370
docker run -d --name mcpgateway \
359371
--restart unless-stopped \
360372
-p 4444:4444 \
@@ -372,6 +384,14 @@ SQLite now lives on the host at `./data/mcp.db`.
372384
#### 3 - Local tool discovery (host network)
373385

374386
```bash
387+
mkdir -p $(pwd)/data
388+
389+
touch $(pwd)/data/mcp.db
390+
391+
sudo chown -R :docker $(pwd)/data
392+
393+
chmod 777 $(pwd)/data
394+
375395
docker run -d --name mcpgateway \
376396
--network=host \
377397
-e HOST=0.0.0.0 \
@@ -402,6 +422,12 @@ podman run -d --name mcpgateway \
402422
```bash
403423
mkdir -p $(pwd)/data
404424

425+
touch $(pwd)/data/mcp.db
426+
427+
sudo chown -R :docker $(pwd)/data
428+
429+
chmod 777 $(pwd)/data
430+
405431
podman run -d --name mcpgateway \
406432
--restart=on-failure \
407433
-p 4444:4444 \
@@ -413,6 +439,14 @@ podman run -d --name mcpgateway \
413439
#### 3 - Host networking (rootless)
414440

415441
```bash
442+
mkdir -p $(pwd)/data
443+
444+
touch $(pwd)/data/mcp.db
445+
446+
sudo chown -R :docker $(pwd)/data
447+
448+
chmod 777 $(pwd)/data
449+
416450
podman run -d --name mcpgateway \
417451
--network=host \
418452
-v $(pwd)/data:/data \

docs/docs/using/agents/langchain.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,9 +67,6 @@ Once the agent is created, you can use it to perform tasks:
6767
response = agent.run("Use the 'weather' tool to get the forecast for Dublin.")
6868
print(response)
6969
```
70-
71-
---
72-
7370
## 📚 Additional Resources
7471

7572
* [LangChain MCP Adapters Documentation](https://langchain-ai.github.io/langgraph/agents/mcp/)

0 commit comments

Comments
 (0)