Skip to main content
Glama
NimbleBrainInc

NewsAPI MCP Server

Get Top Headlines

get_top_headlines

Fetch top news headlines filtered by country, category, or keywords. Use this to quickly see the leading stories for any region or topic.

Instructions

Get top news headlines by country and category.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryNoKeywords to search in article headlines.
countryNo2-letter ISO 3166-1 country code (default: "us").us
categoryNoNews category: "business", "entertainment", "general", "health", "science", "sports", or "technology".
page_sizeNoNumber of results to return (default: 10, max: 100).

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryNoThe search query (if provided)
countryYesCountry code used for the request
articlesNoTop headline articles
categoryNoCategory filter (if provided)
total_resultsNoTotal number of results available

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.2

TDQS

A3.6/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It does not mention that this is a read-only operation, any rate limits, pagination behavior, or what the response format looks like. The description simply restates the name's meaning without adding any behavioral context beyond the obvious.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single concise sentence that front-loads the core purpose. There is zero redundancy or fluff. Every word earns its place, making it easy for an agent to parse quickly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool is simple with only four parameters, all documented in the schema, and an output schema exists to describe the return structure. The description covers the essential purpose and filters. While it does not mention optional parameters like query, the schema already does. For this low-complexity tool, the description is sufficiently complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so all four parameters (query, country, category, page_size) have descriptions in the schema. The tool description adds no additional parameter context, such as relationships or usage hints. Given the high schema coverage, the baseline of 3 is appropriate; the description does not need to compensate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool retrieves top news headlines, specifying the two primary filters (country and category). This distinguishes it from the sibling 'search_news', which implies a different use case (searching for specific articles rather than aggregated headlines). The verb 'get' and resource 'top news headlines' are specific and unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage when one wants top headlines by country/category, but it does not explicitly contrast with search_news or state when to prefer one over the other. No exclusions or alternative routing are mentioned, leaving the agent to infer from the tool's name and description. This is adequate but not explicit guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools