Skip to main content
Glama

Weather Query MCP Server

by eternachen

날씨 쿼리 MCP 서버/클라이언트 예제

이 프로젝트는 MCP(모델-클라이언트-프로토콜) 서버와 상호 작용하여 지정된 도시의 날씨 정보를 가져와 표시하는 날씨 쿼리 클라이언트입니다.

특징

  • MCP 서버에 연결하여 사용 가능한 도구를 나열합니다.
  • 지정된 도시의 날씨 정보를 쿼리합니다.
  • 온도, 습도, 풍속, 날씨 설명을 포함한 형식화된 날씨 정보를 표시합니다.

요구 사항

  • 파이썬 3.8 이상
  • openai 라이브러리
  • dotenv 라이브러리
  • mcp 라이브러리

설정

  1. 저장소를 복제합니다.지엑스피1
  2. 가상 환경을 만들고 활성화하세요.
    python -m venv .venv source .venv/bin/activate # On Windows use `.venv\Scripts\activate`
  3. 필요한 종속성을 설치하세요:
    pip install -r requirements.txt
  4. 루트 디렉토리에 .env 파일을 만들고 OpenAI API 키와 기타 구성을 추가합니다.
    OPENAI_API_KEY=<your_openai_api_key> BASE_URL=<your_base_url> MODEL=<your_model>

용법

  1. MCP 서버를 시작합니다.
    python server.py
  2. 클라이언트를 실행하고 서버에 연결합니다.
    python client.py <path_to_server_script>
  3. 고객과 상호 작용:
    • 날씨 정보를 얻으려면 도시 이름을 영어로 입력하세요.
    • quit 입력하여 클라이언트를 종료합니다.

프로젝트 구조

  • server.py : MCP 서버 구현과 날씨 쿼리 도구가 포함되어 있습니다.
  • client.py : 서버와 상호작용하는 MCP 클라이언트 구현이 포함되어 있습니다.
  • .env : API 키 및 구성을 위한 환경 변수.
  • .gitignore : git에서 무시할 파일과 디렉토리를 지정합니다.
  • README.md : 프로젝트 설명서.

특허

이 프로젝트는 MIT 라이선스에 따라 라이선스가 부여되었습니다.

-
security - not tested
F
license - not found
-
quality - not tested

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

사용자가 특정 도시의 온도, 습도, 풍속, 날씨 설명을 포함한 날씨 정보를 가져와서 표시할 수 있도록 하는 MCP 서버 구현입니다.

  1. 특징
    1. 요구 사항
      1. 설정
        1. 용법
          1. 프로젝트 구조
            1. 특허

              Related MCP Servers

              • A
                security
                A
                license
                A
                quality
                An MCP server that provides real-time weather information including temperature, humidity, wind speed, and sunrise/sunset times through the OpenWeatherMap API.
                Last updated -
                1
                Python
                MIT License
                • Linux
                • Apple
              • -
                security
                F
                license
                -
                quality
                A simple MCP service that allows users to query weather conditions for cities worldwide through the Cursor AI assistant.
                Last updated -
                JavaScript
              • -
                security
                A
                license
                -
                quality
                An MCP server that connects to OpenWeatherMap's API to provide current weather data and multi-day forecasts for locations worldwide in different measurement units.
                Last updated -
                12
                TypeScript
                MIT License
              • A
                security
                F
                license
                A
                quality
                MCP server that provides Korean weather information using grid coordinates and the Korea Meteorological Administration API, allowing users to query current weather conditions and forecasts for specific locations in Korea.
                Last updated -
                2
                3
                Python
                • Apple
                • Linux

              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/eternachen/mcp-playground'

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