Skip to content

feat(core): Add mcp server #9389

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
May 19, 2025
Merged

feat(core): Add mcp server #9389

merged 8 commits into from
May 19, 2025

Conversation

harshil-goel
Copy link
Contributor

@harshil-goel harshil-goel commented Apr 17, 2025

Added an mcp server. To access it, add the following to your mcp config:

{
  "mcpServers": {
    "dgraph-binary": {
      "command": "/home/harshil/gopath/bin/dgraph",
      "args": ["mcp", "-c", "dgraph://localhost:9080"]
    },
    "dgraph-mcp": {
      "serverUrl": "http://localhost:8080/mcp/sse"
    },
    "dgraph-mcp-ro": {
      "serverUrl": "http://localhost:8080/mcp-ro/sse"
    }
  }
}

@harshil-goel harshil-goel requested a review from a team as a code owner April 17, 2025 11:18
@github-actions github-actions bot added the go Pull requests that update Go code label Apr 17, 2025
Copy link

trunk-io bot commented Apr 17, 2025

Static BadgeStatic BadgeStatic BadgeStatic Badge

View Full Report ↗︎Docs

@harshil-goel harshil-goel force-pushed the harshil-goel/add-mcp branch from bac3188 to d7ad607 Compare May 14, 2025 19:25
@github-actions github-actions bot added the area/documentation Documentation related issues. label May 14, 2025
Copy link

trunk-io bot commented May 14, 2025

Running Code Quality on PRs by uploading data to Trunk will soon be removed. You can still run checks on your PRs using trunk-action - see the migration guide for more information.

Copy link
Member

@matthewmcneely matthewmcneely left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, there should be tests for this new functionality. The SSEMCPClient is handy for this. https://pkg.go.dev/github.com/mark3labs/mcp-go@v0.27.0/client#NewSSEMCPClient

Here's an example from the memory server: https://github.com/hypermodeinc/kgms/blob/main/server_sse_test.go

@harshil-goel harshil-goel force-pushed the harshil-goel/add-mcp branch from 3241436 to d3c7eb5 Compare May 19, 2025 19:34
@mangalaman93 mangalaman93 enabled auto-merge (squash) May 19, 2025 19:55
@mangalaman93 mangalaman93 merged commit 8013efd into main May 19, 2025
13 checks passed
@mangalaman93 mangalaman93 deleted the harshil-goel/add-mcp branch May 19, 2025 21:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/documentation Documentation related issues. go Pull requests that update Go code
Development

Successfully merging this pull request may close these issues.

3 participants