RuleGo RuleGo
🏠Home
  • Quick Start
  • Rule Chain
  • Standard Components
  • Extension Components
  • Custom Components
  • Visualization
  • RuleGo-Server
  • RuleGo-MCP-Server
  • AOP
  • Trigger
  • Advanced Topics
  • Performance
  • Standard Components
  • Extension Components
  • Custom Components
  • Components Marketplace
  • Overview
  • Quick Start
  • Routing
  • DSL
  • API
  • Options
  • Components
🔥Editor (opens new window)
  • RuleGo Editor (opens new window)
  • RuleGo Server (opens new window)
  • Github (opens new window)
  • Gitee (opens new window)
  • Changelog (opens new window)
  • English
  • 简体中文
🏠Home
  • Quick Start
  • Rule Chain
  • Standard Components
  • Extension Components
  • Custom Components
  • Visualization
  • RuleGo-Server
  • RuleGo-MCP-Server
  • AOP
  • Trigger
  • Advanced Topics
  • Performance
  • Standard Components
  • Extension Components
  • Custom Components
  • Components Marketplace
  • Overview
  • Quick Start
  • Routing
  • DSL
  • API
  • Options
  • Components
🔥Editor (opens new window)
  • RuleGo Editor (opens new window)
  • RuleGo Server (opens new window)
  • Github (opens new window)
  • Gitee (opens new window)
  • Changelog (opens new window)
  • English
  • 简体中文

广告采用随机轮播方式显示 ❤️成为赞助商
  • Quick Start

  • Rule Chain

  • Standard Components

  • Extension Components

  • Custom Components

  • Components marketplace

  • Visualization

  • AOP

  • Trigger

  • Advanced Topic

  • RuleGo-Server

    • RuleGo-Server
    • RuleGo-MCP-Server
    • MCP-Server-Endpoint
    • FAQ

    • Endpoint Module

    • Support

    目录

    MCP-Server-Endpoint

    To address the issues of inaccurate agent recognition and permission granularity caused by the multitude of MCP tools, we have provided the MCP-Server input endpoint. Through rule chain configuration, users can provide a set of MCP tools. A single rule chain represents an MCP server, with all configurations and tool logic encapsulated within the rule chain, allowing for flexible real-time updates.

    # Configuring MCP Server with RuleGo-Editor

    1. Download and Run RuleGo-Server
    2. Open RuleGo-Editor: http://8.134.32.225:9090/editor
    3. Create a Rule Chain and drag the MCP Server onto the canvas. mcp_server.png
    4. Configure the server port (you can reuse the default HTTP server port). config.png
    5. Configure the routing settings. Each route represents an MCP tool. tool_list.png
    6. Click the Add button to configure an MCP tool, including the tool identifier, tool description, and input JsonSchema. tool_config.png
    7. JsonSchema example
    {
       "type": "object",
       "properties": {
          "scaleFactor": {
             "type": "number",
             "title": "Scale Factor",
             "default": 1.8
          }
       },
       "required": ["scaleFactor"]
    }
    
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    1. Drag the logic nodes that implement the tool into the canvas.
    2. Connect the tool's identifier with the processing node. The following example configures two MCP tools: tool_link.png
    3. In Settings - Integration, copy the MCP SSE address of the rule chain for testing in the MCP client. sse_url.png
    4. Test using the TraeMCP client. After successful configuration, all tools will be displayed in the left-hand list of the client. trae_mcp.png
    5. Once the configuration is complete, you can call these tools in the AI assistant.

    # Example Rule Chain DSL

    {
       "ruleChain": {
          "id": "TAR_5Z82C07p",
          "name": "MCP Server",
          "debugMode": true,
          "root": true,
          "disabled": false,
          "additionalInfo": {
             "createTime": "2025/04/28 15:28:06",
             "description": "Provide MCP tools to AI agents through rule chains",
             "layoutX": "450",
             "layoutY": "770",
             "updateTime": "2025/04/29 13:47:23",
             "username": "admin"
          }
       },
       "metadata": {
          "endpoints": [
             {
                "id": "node_2",
                "additionalInfo": {
                   "layoutX": 380,
                   "layoutY": 190
                },
                "type": "endpoint/mcpServer",
                "name": "MCP Server",
                "debugMode": false,
                "configuration": {
                   "allowCors": true,
                   "name": "Test MCP Server",
                   "server": "ref://:9090",
                   "version": "v1.0.0"
                },
                "processors": null,
                "routers": [
                   {
                      "id": "cm2iZUH32xEt",
                      "params": [
                         "Convert temperature by passing in a scale factor",
                         "{\n  \"type\": \"object\",\n  \"properties\": {\n    \"scaleFactor\": {\n      \"type\": \"number\",\n      \"title\": \"Scale Factor\",\n      \"default\": 1.8\n    }\n  },\n  \"required\": [\"scaleFactor\"]\n}\n"
                      ],
                      "from": {
                         "path": "transformText",
                         "configuration": null,
                         "processors": []
                      },
                      "to": {
                         "path": "TAR_5Z82C07p:node_4",
                         "configuration": null,
                         "wait": false,
                         "processors": []
                      }
                   },
                   {
                      "id": "_PztDG6f5MO7",
                      "params": [
                         "Fetch content via URL parameter",
                         "{\n  \"type\": \"object\",\n  \"properties\": {\n    \"url\": {\n      \"type\": \"string\",\n      \"title\": \"URL\"\n    }\n  },\n  \"required\": [\"url\"]\n}\n"
                      ],
                      "from": {
                         "path": "fetchUrl",
                         "configuration": null,
                         "processors": []
                      },
                      "to": {
                         "path": "TAR_5Z82C07p:node_6",
                         "configuration": null,
                         "wait": false,
                         "processors": []
                      }
                   }
                ]
             }
          ],
          "nodes": [
             {
                "id": "node_6",
                "additionalInfo": {
                   "layoutX": 890,
                   "layoutY": 340
                },
                "type": "restApiCall",
                "name": "Fetch Page Content",
                "debugMode": false,
                "configuration": {
                   "headers": {
                      "Content-Type": "application/json"
                   },
                   "maxParallelRequestsCount": 200,
                   "proxyPort": 0,
                   "readTimeoutMs": 2000,
                   "requestMethod": "GET",
                   "restEndpointUrlPattern": "${msg.url}"
                }
             },
             {
                "id": "node_4",
                "additionalInfo": {
                   "layoutX": 820,
                   "layoutY": 100
                },
                "type": "jsTransform",
                "name": "Convert Temperature",
                "debugMode": false,
                "configuration": {
                   "jsScript": "var newMsg=msg||{}\nnewMsg.value=msg.from||\"test01\"\nreturn {'msg':newMsg,'metadata':metadata,'msgType':msgType};"
                }
             }
          ],
          "connections": []
       }
    }
    
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    Edit this page on GitHub (opens new window)
    Last Updated: 2025/04/28, 11:45:54
    RuleGo-MCP-Server
    FAQ

    ← RuleGo-MCP-Server FAQ→

    Theme by Vdoing | Copyright © 2023-2025 RuleGo Team | Apache 2.0 License

    • 跟随系统
    • 浅色模式
    • 深色模式
    • 阅读模式