MCP Server

by Cavumnigrum

312 downloads
Not rated
GitHub

About

MCP Server is a Python-based MCP (Model Context Protocol) server that provides the current USD exchange rate, weather forecast, and news from the last week. It is intended for developers who want to integrate these external data sources into MCP-compatible applications.

Details

Author
Cavumnigrum
Downloads
312
Categories
Developer Tools

- Provides current USD exchange rate from exchangerate-api.com.
- Delivers weather forecast from openweathermap.org.
- Supplies news articles from the last week via newsapi.org.
- Written in Python and follows the MCP protocol.
- Includes a test suite runnable with pytest.
- Docker‑Compose files for containerized server and client.

Setting up with Highlight

This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:

  1. Download and install Highlight from highlightai.com/download
  2. Navigate to the plugins tab and select "Add Custom Plugin"
  3. Configure the plugin with the settings below
    Plugin Name MCP Server
    Command (node, npx, python, etc.)

    Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.

  4. Enable "Start Automatically" if you want the plugin to start when Highlight launches

From the repository

Clone the repository, create a Python virtual environment, install dependencies, and set up API keys for exchangerate-api, openweathermap, and newsapi in a .env file. Run the server with python mcp_server.py – it becomes available at http://localhost:8000. A self‑written client can be launched with python mcp_client.py. Docker deployment is also supported via docker-compose.

Claude Desktop / Cursor

Paste into your MCP client config file to install this server.

{
    "mcpServers": {
        "mcp server": {
            "test_MCPServer": {
                "command": "python",
                "args": [
                    "-m",
                    "venv",
                    "venv"
                ]
            }
        }
    }
}

McpServers

{
    "test_MCPServer": {
        "command": "python",
        "args": [
            "-m",
            "venv",
            "venv"
        ]
    }
}

MCP Server

MCP сервер на Python, предоставляющий текущий курс доллара, прогноз погоды и новости за последнюю неделю.

Установка

1. Клонируйте репозиторий: ``bash git clone https://github.com/Cavumnigrum/mcp_server_project.git cd mcp_server_project ` 2. Создайте виртуальное окружение: `bash python -m venv venv source venv/bin/activate # Linux/Mac venv\Scripts\activate # Windows ` 3. Установите зависимости: `bash pip install -r requirements.txt ` 4. Настройте API ключи: - Зарегистрируйтесь на: - exchangerate-api.com для курса доллара. - openweathermap.org для погоды. - newsapi.org для новостей. - Скопируйте .env.example в .env и заполните своими ключами: `bash cp .env.example .env ` 5. Запустите сервер: `bash python mcp_server.py ` Сервер будет доступен по адресу http://localhost:8000.

Тестирование

Запустите тесты с помощью
pytest: `bash pytest test_mcp_server.py -v `

Подключение клиента

Самописный клиент:
`bash python mcp_client.py ` - При запуске клиента есть инструкция как им пользоваться

Дополнительно

В репозитории есть docker-файлы для создания контейнеров. Порядок работы с докер-файлами: 1. Убедиться, что установлены необходимые пакеты для docker и docker-compose 2. Перейти в папку с проектом
`bash cd path\to\project ` 3. Запустить docker-compose файл в двух режимах для сервера и клиента `bash docker-compose up -d server docker-compose run --rm client ` 4. После завершения работы можно уронить контейнеры с помощью `bash docker-compose down server client ``
No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.