Skip to main content
Glama

get-theverge-news

Fetch English technology news from The Verge covering innovation, product reviews, internet trends, and company developments.

Instructions

获取 The Verge 新闻,包含科技创新、数码产品评测、互联网趋势及科技公司动态的英文科技资讯

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The complete tool configuration including the handler function that fetches The Verge RSS using getRss, processes feed entries (handling specific link formats), and returns structured news items with title, description, publish_time, and link.
    export default defineToolConfig({ name: 'get-theverge-news', description: '获取 The Verge 新闻,包含科技创新、数码产品评测、互联网趋势及科技公司动态的英文科技资讯', func: async () => { const rss = await getRss('https://www.theverge.com/rss/index.xml'); if (!Array.isArray(rss.feed.entry)) { throw new Error('获取 The Verge 新闻失败'); } return (rss.feed.entry as any[]).map((item) => { let link = item.link; if (!link && item.id) { link = item.id; } const url = new URL(link); if (url.searchParams.has('p')) { url.pathname = url.searchParams.get('p') as string; url.search = ''; link = url.toString(); } return { title: item.title, description: item.summary, publish_time: item.published, link, }; }); }, });
  • Helper function to fetch RSS feed XML via HTTP and parse it using fast-xml-parser, used directly in the tool handler.
    export const getRss = async (url: string) => { const resp = await http.get(url); const parser = new XMLParser(); return parser.parse(resp.data); };

Latest Blog Posts

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/baranwang/mcp-trends-hub'

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