- Home
- MCP servers
- News
News
- python
3
GitHub Stars
python
Language
6 months ago
First Indexed
2 months ago
Catalog Refreshed
Documentation & install
Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.
Installation
Add the following to your MCP client configuration file.
Configuration
View docs{
"mcpServers": {
"eluc1a-mcp-news": {
"command": "uvx",
"args": [
"news-mcp"
],
"env": {
"DATABASE_URL": "postgresql://localhost/mcp_news",
"KEYWORD_FILTER": "YOUR_KEYWORDS",
"LOOKBACK_HOURS": "6",
"OPENAI_API_KEY": "YOUR_OPENAI_API_KEY",
"SUMMARY_WORD_TARGET": "500",
"MAX_ARTICLES_PER_SUMMARY": "25"
}
}
}
}You can access the latest news articles by category through a dedicated MCP server. It exposes a news resource to fetch articles and a summarization tool that retrieves articles for client-side processing. This setup keeps your article data centralized and lets you integrate concise news summaries into your workflows.
How to use
Use the news MCP server with an MCP client to fetch the latest articles by category. Retrieve articles via the news resource URI and optionally summarize or process them with the built-in tool.
Fetch a list of articles for a category using the news resource in the format news://{category}/{limit}. Replace {category} with a category such as tech, data_science, or any of the supported categories, and optionally set {limit} to limit how many articles are returned (default is 10). Each article includes the title, link, published date, and source.
Use the summarize_news tool to retrieve raw articles for summarization. You can specify an optional category and limit to control which articles are returned. The tool returns a list of articles with fields like id, title, link, published, source, and content. This enables you to generate summaries or extract key points for display or further processing.
How to install
Prerequisites: ensure you have the MCP runtime available and the required environment variables configured before starting the server.
- Prepare the MCP server configuration in your environment. The server is intended to run through the MCP manager, using the following stdio configuration to start the news MCP server.
{
"mcpServers": {
"news_mcp": {
"command": "uvx",
"args": [
"news-mcp"
]
}
}
}
Additional notes
Environment variables control data sources and operational behavior. The following environment variables are commonly used to configure the news MCP server: DATABASE_URL, OPENAI_API_KEY, LOOKBACK_HOURS, SUMMARY_WORD_TARGET, MAX_ARTICLES_PER_SUMMARY, KEYWORD_FILTER. These variables are used for database access, summarization behavior, and filters. Provide real values in your deployment.
The server relies on a PostgreSQL database configured via the DATABASE_URL environment variable (default: postgresql://localhost/mcp_news). The news_gatherer.py script collects articles from RSS feeds and populates the database. The OpenAI API key is required for the internal summarization logic.
For debugging and development, you can run the MCP Inspector to observe the runtime behavior of the server and its I/O. This helps diagnose issues when starting or querying the server in an MCP client.
Available tools
summarize_news
Retrieves raw news articles from the database to enable summarization for client-side processing. Returns a list of article dictionaries with id, title, link, published, source, and content. Supported categories include tech, data_science, llm_tools, cybersecurity, linux, audio_dsp, startups, news, science, research, policy.