Cover image
Try Now
2025-04-14

轻巧,配置驱动的MCP服务器,将策划的GraphQl查询作为模块化工具,从而实现了代理的故意API交互。

3 years

Works with Finder

0

Github Watches

0

Github Forks

0

Github Stars

GitHub release License Work In Progress

mcp-graphql-forge

A lightweight, configuration-driven MCP server that exposes curated GraphQL queries as modular tools, enabling intentional API interactions from your agents.

Purpose

mcp-graphql-forge lets you turn any GraphQL endpoint into an MCP server whose tools are defined in YAML files that specify the GraphQL queries and their parameters. This allows you to create a modular, secure, and minimal server that can be easily extended without modifying the application code.

Configuration

The server is configured using environment variables and YAML files.

Environment Variables

  • FORGE_CONFIG: Specifies the path to the folder containing the YAML configuration files (forge.yaml and tool definitions). Defaults to the current directory (.) if not set.
  • FORGE_DEBUG: If set to true (case-insensitive), enables detailed debug logging to stderr, including the obtained token and the full HTTP request/response for GraphQL calls. Defaults to false.

forge.yaml

The configuration folder uses a special configuration file forge.yaml that specifies the common configuration attributes.

The following attributes can be specified in the file:

  • name: The name of the MCP server
  • version: The version of the MCP server
  • url: The URL of the GraphQL endpoint
  • token_command: The command to use to request the Bearer token for the Authorization header (optional)

An example configuration would look like:

name: "ExampleServer"
version: "0.1.0"
url: "https://api.github.com/graphql"
token_command: "gh auth token"

Tool Configuration

All other YAML files located in the folder are treated as configuration files. Each YAML file defines a tool for the MCP server.

The following attributes can be specified in the file:

  • name: The name of the MCP tool
  • description: The description of the MCP tool
  • query: The GraphQL query to execute
  • inputs: The list of inputs defined by the MCP tool and passed into the GraphQL query as variables
    • name: The name of the input
    • type: The parameter type; can be 'string' or 'number'
    • description: The description of the parameter for the MCP tool to use
    • required: Boolean value specifying if the attribute is required

An example configuration would look like:

name: "getUser"
description: "Fetch basic information about a user by `login`, including their name, URL, and location."
query: |
  query ($login: String!) {
    user(login: $login) {
      id
      name
      url
      location
    }
  }
inputs:
  - name: "login"
    type: "string"
    description: "The user `login` that uniquely identifies their account."
    required: true

Limitations

  • Each instance of mcp-graphql-forge can only be used with a single GraphQL server at a single URL.
  • All requests use the same Authorization header in the form of a Bearer token.
  • The GraphQL queries are all exposed as Tools and not as Resources, even if they are not mutations. This is because not all MCP clients currently support Resources.

相关推荐

  • av
  • 毫不费力地使用一个命令运行LLM后端,API,前端和服务。

  • 1Panel-dev
  • 🔥1Panel提供了直观的Web接口和MCP服务器,用于在Linux服务器上管理网站,文件,容器,数据库和LLMS。

  • rulego
  • ⛓️Rulego是一种轻巧,高性能,嵌入式,下一代组件编排规则引擎框架。

  • WangRongsheng
  • 🧑‍🚀 llm 资料总结(数据处理、模型训练、模型部署、 o1 模型、mcp 、小语言模型、视觉语言模型)|摘要世界上最好的LLM资源。

  • Onelevenvy
  • Flock是一个基于工作流程的低音平台,可快速构建聊天机器人,抹布和协调多代理团队,由Langgraph,Langchain,Langchain,Fastapi和Nextjs提供支持。(羊群工作流工作流的低代码平台,rag rag rag 用于快速构建聊天机器人、 rag temant Agent fastem temantfaster和muti-agent agagent应用

  • Byaidu
  • PDF科学纸翻译带有保留格式的pdf -基于ai完整保留排版的pdf文档全文双语翻译

  • n8n-io
  • 具有本机AI功能的公平代码工作流程自动化平台。将视觉构建与自定义代码,自宿主或云相结合,400+集成。

  • hkr04
  • 轻巧的C ++ MCP(模型上下文协议)SDK

  • sigoden
  • 使用普通的bash/javascript/python函数轻松创建LLM工具和代理。

  • RockChinQ
  • 😎简单易用、🧩丰富生态 -大模型原生即时通信机器人平台| 适配QQ / 微信(企业微信、个人微信) /飞书 /钉钉 / discord / telegram / slack等平台| 支持chatgpt,deepseek,dify,claude,基于LLM的即时消息机器人平台,支持Discord,Telegram,微信,Lark,Dingtalk,QQ,Slack

  • modelscope
  • 开始以更轻松的方式开始构建具有LLM授权的多代理应用程序。

    Reviews

    2.3 (6)
    Avatar
    user_V5viXkZr
    2025-04-24

    As a dedicated MCP user, I highly recommend the mcp-graphql-forge by UnitVectorY-Labs. This tool has significantly streamlined my workflow with its robust GraphQL capabilities, making data querying efficient and intuitive. The product's seamless integration and user-friendly interface are commendable. A must-have for anyone looking to optimize their MCP applications!

    Avatar
    user_5nCu5dJX
    2025-04-24

    As a loyal MCP user, I was thoroughly impressed with UnitVectorY-Labs' mcp-graphql-forge. This powerful tool streamlines the development of GraphQL APIs, making them more efficient and easier to manage. The setup is straightforward, and the detailed documentation ensures that even complex integration processes are smooth. It’s obvious this tool was designed with developers in mind and stands out for its reliability and functionality. Highly recommended!

    Avatar
    user_r0F8x8SR
    2025-04-24

    I've been using mcp-graphql-forge by UnitVectorY-Labs and it's been a game-changer for my GraphQL projects. Its seamless integration and powerful features have accelerated my development workflow. The product is intuitive and well-documented, making it easy to get started. Highly recommend for anyone looking to enhance their GraphQL experience!

    Avatar
    user_qtAVhhD1
    2025-04-24

    mcp-graphql-forge by UnitVectorY-Labs is a game-changer for developers. The seamless integration of GraphQL with excellent documentation and support makes it a must-have tool. Its reliability and efficiency in simplifying complex queries are unmatched. Highly recommend it to anyone looking for robust GraphQL solutions.

    Avatar
    user_NUxu1a8m
    2025-04-24

    As an avid user of mcp-graphql-forge, I highly recommend it for any GraphQL project. Created by UnitVectorY-Labs, this tool is incredibly user-friendly and efficient. It helps streamline development and management of GraphQL schemas seamlessly. The intuitive interface and robust functionality make it a must-have for developers. Bravo to the team for such an innovative product!

    Avatar
    user_CI2AQjee
    2025-04-24

    As an avid user of the mcp-graphql-forge by UnitVectorY-Labs, I must say it has significantly streamlined my workflow. The intuitive design and robust capabilities make it an indispensable tool for handling complex data queries. This product is a game-changer for anyone heavily invested in GraphQL development. Highly recommend it!