CentralMind Gateway:快速创建数据库API

CentralMind Gateway:快速创建数据库API

为数据库和AI应用优化的通用MCP服务器,支持多种协议。

快速入门

  1. 安装与运行 使用Docker快速启动:

    docker run --platform linux/amd64 -p 9090:9090 \
      ghcr.io/centralmind/gateway:v0.2.14 start \
      --connection-string "postgres://db-user:db-password@db-host/db-name?sslmode=require"
    

    启动后访问:

  2. 生成API配置 连接数据库并生成API配置文件:

    ./gateway discover \
      --ai-provider gemini \
      --connection-string "postgresql://user:password@host/dbname" \
      --prompt "生成只读API"
    

    配置文件保存在 gateway.yaml

  3. 启动服务 使用生成的配置文件启动服务:

    ./gateway start --config gateway.yaml
    
  4. 更多功能 支持REST、MCP协议,集成Swagger文档,适合多种AI工具调用。详情参考 官方文档