Skip to main content
Glama

swagger-mcp

스웨거-MCP

개요

swagger-mcp swagger.json 파일을 추출하고 런타임에 잘 정의된 mcp 도구를 동적으로 생성하여 Swagger UI를 스크래핑하도록 설계된 도구입니다. 이러한 도구는 MCP 클라이언트에서 추가 도구 선택에 활용될 수 있습니다.

📽️ 데모 영상

프로젝트가 실제로 진행되는 모습을 보여주는 데모 영상을 확인하세요.

🙌 지원

이 프로젝트가 가치 있다고 생각되시면 LinkedIn 에서 다음과 같이 지원해 주세요.

  • 👍 데모 게시물을 좋아요하고 공유해주세요
  • 💬 댓글로 여러분의 생각과 피드백을 남겨주세요
  • 🔗 향후 업데이트를 위해 저와 소통합니다

LinkedIn에서 여러분의 지원을 통해 더 많은 사람들에게 다가가고 프로젝트를 개선하는 데 도움이 될 것입니다!

필수 조건

swagger-mcp 사용하려면 다음 종속성이 있는지 확인하세요.

  1. LLM 모델 API 키/로컬 LLM : OpenAI, Claude 또는 Ollama 모델에 대한 액세스가 필요합니다.
  2. 모든 MCP 클라이언트 : ( mark3labs - mcphost 사용)

설치 및 설정

swagger-mcp 설치하고 실행하려면 다음 단계를 따르세요.

지엑스피1

실행 구성

swagger-mcp 직접 실행하려면 다음을 사용하세요.

swagger-mcp --specUrl=https://your_swagger_api_docs.json

주요 플래그:

  • --specUrl : Swagger/OpenAPI JSON URL(필수)
  • --sseMode : SSE 모드로 실행(기본값: false, true이면 SSE 서버로 실행, 그렇지 않으면 stdio 사용)
  • --sseAddr : IP 또는 형식의 SSE 서버 수신 주소(비어 있으면 --sseUrl에서 IP를 사용함)
  • --sseUrl : SSE 서버 기본 URL(비어 있는 경우 sseAddr을 사용하여 생성합니다. 예: http://IP:Port 또는 http://localhost:Port )
  • --sseAddr과 --sseUrl이 모두 설정된 경우 자동 보완 없이 그대로 사용됩니다.
  • --baseUrl : API 요청에 대한 기본 URL을 재정의합니다.
  • --security : API 보안 유형( basic , apiKey 또는 bearer )
  • --basicAuth : 사용자:암호 형식의 기본 인증
  • --bearerAuth : Authorization 헤더에 대한 Bearer 토큰
  • --apiKeyAuth : API 키, 형식은 passAs:name=value (예 header:token=abc,query:user=foo,cookie:sid=xxx )
  • 지원되는 모든 플래그와 옵션은 main.go에서 확인하세요.

MCP 구성

mcphost 와 통합하려면 .mcp.json 에 다음 구성을 포함하세요.

{ "mcpServers": { "swagger_loader": { "command": "swagger-mcp", "args": ["--specUrl=<swagger/doc.json_url>"] } } }

데모 흐름

  1. 일부 백엔드:
    go install github.com/danishjsheikh/go-backend-demo@latest go-backend-demo
  2. 올라마
    ollama run llama3.2
  3. MCP 클라이언트
    go install github.com/mark3labs/mcphost@latest mcphost -m ollama:llama3.2 --config <.mcp.json_file_path>

흐름도

흐름도

🛠️ 도움이 필요해요

저는 다음을 향상시키기 위해 도구 정의를 개선하는 작업을 진행 중입니다.
✅ 더 정확한 응답을 위한 더 나은 오류 처리
LLM 동작 제어를 통해 API 응답에만 의존하고 자체 메모리를 사용하지 않도록 보장합니다.
✅ API에서 엄격한 데이터 검색을 시행하여 환각무작위 데이터 생성 방지

이러한 측면을 개선하기 위한 통찰력이나 제안이 있으시면 다음을 통해 기여해 주시기 바랍니다.

  • 유사한 구현에 대한 경험을 공유합니다
  • 도구 정의에 대한 수정 제안
  • 현재 제한 사항에 대한 피드백 제공

귀하의 의견은 이 도구를 더욱 안정적이고 효과적으로 만드는 데 매우 귀중할 것입니다! 🚀

-
security - not tested
A
license - permissive license
-
quality - not tested

hybrid server

The server is able to function both locally and remotely, depending on the configuration or use case.

swagger-mcp는 swagger.json 파일을 추출하고 런타임에 잘 정의된 mcp 도구를 동적으로 생성하여 Swagger UI를 스크래핑하도록 설계된 도구입니다. 이러한 도구는 MCP 클라이언트에서 추가 도구 선택에 활용될 수 있습니다.

  1. 개요
    1. 📽️ 데모 영상
      1. 🙌 지원
        1. 필수 조건
          1. 설치 및 설정
            1. 실행 구성
              1. MCP 구성
                1. 데모 흐름
                  1. 흐름도
                    1. 🛠️ 도움이 필요해요

                      Related MCP Servers

                      • -
                        security
                        F
                        license
                        -
                        quality
                        A Management Control Plane server that allows users to explore and analyze Swagger/OpenAPI specifications, providing features such as endpoint exploration, schema analysis, and customizable response formatting, with support for authentication and integration with tools like Claude.
                        Last updated -
                        4
                        TypeScript
                      • -
                        security
                        A
                        license
                        -
                        quality
                        A server that enables interaction with any API that has a Swagger/OpenAPI specification through Model Context Protocol (MCP), automatically generating tools from API endpoints and supporting multiple authentication methods.
                        Last updated -
                        61
                        TypeScript
                        Apache 2.0
                      • -
                        security
                        A
                        license
                        -
                        quality
                        An MCP server that connects to a Swagger specification and helps an AI to build all the required models to generate a MCP server for that service.
                        Last updated -
                        19
                        TypeScript
                        MIT License
                        • Linux
                        • Apple
                      • -
                        security
                        A
                        license
                        -
                        quality
                        MCP server providing token-efficient access to OpenAPI/Swagger specs via MCP Resources for client-side exploration.
                        Last updated -
                        573
                        21
                        TypeScript
                        MIT License

                      View all related MCP servers

                      MCP directory API

                      We provide all the information about MCP servers via our MCP API.

                      curl -X GET 'https://glama.ai/api/mcp/v1/servers/danishjsheikh/swagger-mcp'

                      If you have feedback or need assistance with the MCP directory API, please join our Discord server