YS

yuru-sha/mcp-server-dify

Deployment & DevOps

이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요. 원문 보기

11 stars 4 forks 품질 58 트렌드 18MIT

Sample MCP Server for Dify AI

개요

Model Context Protocol Server for Dify AI. This server enables LLMs to interact with Dify AI's chat completion capabilities through a standardized protocol. - Integration with Dify AI chat completion API - Restaurant recommendation tool (meshi-doko) - Support for conversation context - Streaming response support - TypeScript implementation Add the following configuration to your claude_desktop_config.json: Replace your-dify-api-endpoint and your-dify-api-key with your actual Dify API credentials. Restaurant recommendation tool that interfaces with Dify AI: Parameters: - LOCATION (string): Location of the restaurant - BUDGET (string): Budget constraints - query (string): Query to send to Dify AI - conversation_id (string, optional): For maintaining chat context This project is released under the MIT License. This server interacts with Dify AI using your provided API key.

README

mcp-server-dify

Model Context Protocol Server for Dify AI. This server enables LLMs to interact with Dify AI’s chat completion capabilities through a standardized protocol.

Features

  • Integration with Dify AI chat completion API
  • Restaurant recommendation tool (meshi-doko)
  • Support for conversation context
  • Streaming response support
  • TypeScript implementation

Installation

Using Docker

# Build the Docker image
make docker

# Run with Docker
docker run -i --rm mcp/dify https://your-dify-api-endpoint your-dify-api-key

Usage

With Claude Desktop

Add the following configuration to your claude_desktop_config.json:

{
  "mcpServers": {
    "dify": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-dify",
        "https://your-dify-api-endpoint",
        "your-dify-api-key"
      ]
    }
  }
}

Replace your-dify-api-endpoint and your-dify-api-key with your actual Dify API credentials.

Tools

meshi-doko

Restaurant recommendation tool that interfaces with Dify AI:

Parameters:

  • LOCATION (string): Location of the restaurant
  • BUDGET (string): Budget constraints
  • query (string): Query to send to Dify AI
  • conversation_id (string, optional): For maintaining chat context

Development

# Initial setup
make setup

# Build the project
make build

# Format code
make format

# Run linter
make lint

License

This project is released under the MIT License.

Security

This server interacts with Dify AI using your provided API key. Ensure to:

  • Keep your API credentials secure
  • Use HTTPS for the API endpoint
  • Never commit API keys to version control

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

GitHub에서 전체 README 보기

설치

npx -y @modelcontextprotocol/server-dify https://your-dify-api-endpoint your-dify-api-key
MCP 초보자라면? mcpskill.org 가이드부터 시작하세요 →

설정

{ "mcpServers": { "dify": { "command": "npx", "args": [ "-y", "@modelcontextprotocol/server-dify", "https://your-dify-api-endpoint", "your-dify-api-key" ] } } }