Back to Home
CyrilBaah icon

hn-mcp-server

Verified Safe

by CyrilBaah

Overview

Provides programmatic access to HackerNews content via the Model Context Protocol (MCP) for AI assistants and other clients to search, retrieve, and analyze stories, comments, and user profiles.

Installation

Run Command
docker-compose up

Environment Variables

  • LOG_LEVEL
  • HN_API_BASE_URL
  • HN_REQUEST_TIMEOUT
  • HN_MAX_RETRIES
  • PORT

Security Notes

The server uses Pydantic models extensively for input and output validation, significantly reducing common injection and data integrity risks. It leverages `httpx` for secure (HTTPS) external API communication. Environment variables are used for configuration, avoiding hardcoded secrets. A client-side rate limiter is implemented to prevent abuse of the upstream HackerNews Algolia API. No `eval` or `exec` calls are present. The HTTP transport relies on `uvicorn` and `starlette`, which are well-vetted libraries. One point is deducted as it exposes an HTTP/SSE endpoint, which inherently has a broader attack surface than stdio, although secured by standard practices.

Similar Servers

Stats

Interest Score32
Security Score9
Cost ClassMedium
Avg Tokens1500
Stars1
Forks0
Last Update2026-01-16

Tags

HackerNewsMCPAPI ProxySearchStoriesCommentsUsers