Back to MCP directory
publicPublicdnsLocal runtime

mcp-news

一个基于NewsAPI.org的FastMCP新闻服务,提供关键词搜索、日期范围筛选和新闻来源过滤功能

article

README

🚀 新闻 MCP 服务器

本项目是一个快速MCP服务器,借助 NewsAPI.org 服务来提供新闻文章。它公开了 get_news() 工具,可依据搜索查询、日期范围和新闻来源获取新闻。

🚀 快速开始

本服务器借助 NewsAPI.org 服务获取新闻文章,公开了 get_news() 工具用于获取新闻。

✨ 主要特性

  • 可根据 关键词 (q) 搜索新闻文章。
  • 能依据 日期范围 (from, to) 过滤新闻。
  • 可按照特定的 新闻来源 (sources) 进行筛选, 默认为 abc-news

📦 安装指南

NewsAPI.org 获取 API Key。

使用与 Claude Desktop 结合

在你的 claude_desktop_config.json 中添加以下内容:

{
    "mcpServers": {
        "news": {
            "command": "uv",
            "args": [
                "--directory",
                "/PATH/TO/YOUR/news",
                "run",
                "news.py"
            ]
        }
    }
}
help

Runtime guide

cloud

Hosted runtime

Hosted servers run from a provider-managed environment. You usually connect the MCP client to the hosted endpoint or follow the provider's authorization flow, without keeping a local process alive

  1. Open provider connection page
  2. Authorize or copy endpoint
  3. Connect from your MCP client
terminal

Local runtime / other methods

Local servers run on your own machine or infrastructure. You normally copy the server_config into your MCP client, install the required package, and provide env variables from env_schema when needed

  1. Copy server_config
  2. Install required package
  3. Fill env variables and restart client