Skip to main content
Glama
ReviewWebsite MCP Server

ReviewWebsite MCP Server

by mrgoonie

ReviewWebsite.com - MCP 服务器

该项目提供了一个模型上下文协议 (MCP) 服务器,将 AI 助手连接到ReviewWebsite.com API,以创建和管理网站评论、提取数据、将 URL 转换为 markdown 等。

可用功能

  • [x] 创建、阅读、更新和删除网站评论

  • [x] 获取可用的AI模型

  • [x] 使用 AI 将 URL 转换为 Markdown

  • [x] 使用 AI 从 URL 中提取结构化数据

  • [x] 抓取 URL 并提取内容

  • [x] 从网站提取链接

  • [x] 使用 AI 总结 URL 和网站

  • [x] SEO 洞察(关键词创意、关键词难度、流量分析、反向链接)

  • [x] 自定义AI模型和参数

  • [x] 控制等待行为和时间

评论网站

Related MCP server: WebforAI Text Extractor

支持的传输

如何使用

命令行界面

# Get available AI models
npm run dev:cli -- get-ai-models --api-key "your-api-key"

# Create a new review
npm run dev:cli -- create-review --url "https://example.com" --instructions "Review this website" --api-key "your-api-key"

# Get a specific review by ID
npm run dev:cli -- get-review --review-id "review-id" --api-key "your-api-key"

# List all reviews
npm run dev:cli -- list-reviews --page 1 --limit 10 --api-key "your-api-key"

# Update a review
npm run dev:cli -- update-review --review-id "review-id" --url "https://example.com" --instructions "Updated instructions" --api-key "your-api-key"

# Delete a review
npm run dev:cli -- delete-review --review-id "review-id" --api-key "your-api-key"

# Convert URL to Markdown
npm run dev:cli -- convert-to-markdown --url "https://example.com" --model "gpt-4o" --api-key "your-api-key"

# Extract structured data from URL
npm run dev:cli -- extract-data --url "https://example.com" --instructions "Extract product information" --api-key "your-api-key"

# Scrape URL
npm run dev:cli -- scrape-url --url "https://example.com" --api-key "your-api-key"

# Extract links from URL
npm run dev:cli -- extract-links --url "https://example.com" --type "all" --api-key "your-api-key"

# Summarize URL
npm run dev:cli -- summarize-url --url "https://example.com" --model "gpt-4o" --api-key "your-api-key"

# Get keyword ideas for SEO
npm run dev:cli -- seo-keyword-ideas --keyword "digital marketing" --country "us" --search-engine "Google" --api-key "your-api-key"

# Check keyword difficulty
npm run dev:cli -- seo-keyword-difficulty --keyword "digital marketing" --country "us" --api-key "your-api-key"

# Analyze website traffic
npm run dev:cli -- seo-traffic --domain-or-url "example.com" --mode "subdomains" --country "us" --api-key "your-api-key"

# Get backlinks for a domain
npm run dev:cli -- seo-backlinks --domain "example.com" --api-key "your-api-key"

MCP 设置

对于使用 stdio 传输的本地配置:

{
  "mcpServers": {
    "reviewwebsite": {
      "command": "node",
      "args": ["/path/to/reviewwebsite-mcp-server/dist/index.js"],
      "transportType": "stdio"
    }
  }
}

对于远程 HTTP 配置:

{
  "mcpServers": {
    "reviewwebsite": {
      "type": "http",
      "url": "http://localhost:8080/mcp"
    }
  }
}

HTTP 传输的环境变量:

您可以使用以下环境变量配置 HTTP 服务器:

  • MCP_HTTP_HOST :绑定到的主机(默认值: 127.0.0.1 )

  • MCP_HTTP_PORT :监听的端口(默认值: 8080 )

  • MCP_HTTP_PATH :端点路径(默认值: /mcp )


源代码概述

什么是 MCP?

模型上下文协议 (MCP) 是一种开放标准,允许 AI 系统安全且上下文地与外部工具和数据源连接。

该样板通过清晰的分层架构实现了 MCP 规范,可以扩展以构建任何 API 或数据源的自定义 MCP 服务器。

为什么要使用这个样板?

  • 生产就绪架构:遵循已发布的 MCP 服务器中使用的相同模式,CLI、工具、控制器和服务之间有明确的分离。

  • 类型安全:使用 TypeScript 构建,以改善开发人员体验、代码质量和可维护性。

  • 工作示例:包括一个完全实现的 IP 查找工具,演示从 CLI 到 API 集成的完整模式。

  • 测试框架:配备单元和 CLI 集成测试的测试基础设施,包括覆盖率报告。

  • 开发工具:包括 ESLint、Prettier、TypeScript 和其他为 MCP 服务器开发预先配置的质量工具。


入门

先决条件

  • Node.js (>=18.x):下载

  • Git :用于版本控制


步骤 1:克隆并安装

# Clone the repository
git clone https://github.com/mrgoonie/reviewwebsite-mcp-server.git
cd reviewwebsite-mcp-server

# Install dependencies
npm install

第 2 步:运行开发服务器

使用 stdio 传输(默认)以开发模式启动服务器:

npm run dev:server

或者使用 Streamable HTTP 传输:

npm run dev:server:http

这将以热重载方式启动 MCP 服务器,并在http://localhost:5173启用 MCP 检查器。

⚙️ 代理服务器正在监听 6277 端口 🔍 MCP Inspector 已启动并运行于http://127.0.0.1:6274

当使用 HTTP 传输时,服务器默认在http://127.0.0.1:8080/mcp上可用。


步骤 3:测试 ReviewWebsite API 工具

通过 CLI 使用 ReviewWebsite API 工具:

# Get available AI models
npm run dev:cli -- get-ai-models --api-key "your-api-key"

# Create a review
npm run dev:cli -- create-review --url "https://example.com" --instructions "Review this website" --api-key "your-api-key"

# Convert URL to Markdown
npm run dev:cli -- convert-to-markdown --url "https://example.com" --model "gpt-4o" --api-key "your-api-key"

建筑学

该样板遵循清晰的分层架构模式,可分离关注点并提高可维护性。

项目结构

src/
├── cli/              # Command-line interfaces
├── controllers/      # Business logic
├── resources/        # MCP resources: expose data and content from your servers to LLMs
├── services/         # External API interactions
├── tools/            # MCP tool definitions
├── types/            # Type definitions
├── utils/            # Shared utilities
└── index.ts          # Entry point

层次和职责

CLI 层( src/cli/*.cli.ts )

  • 目的:定义解析参数和调用控制器的命令行接口

  • 命名:文件应命名为<feature>.cli.ts

  • 测试: <feature>.cli.test.ts中的 CLI 集成测试

工具层( src/tools/*.tool.ts )

  • 目的:为人工智能助手定义带有模式和描述的 MCP 工具

  • 命名:文件应命名为<feature>.tool.ts ,类型为<feature>.types.ts

  • 模式:每个工具都应该使用 zod 进行参数验证

控制器层( src/controllers/*.controller.ts )

  • 目的:实现业务逻辑、处理错误和格式化响应

  • 命名:文件应命名为<feature>.controller.ts

  • 模式:应返回标准化的ControllerResponse对象

服务层( src/services/*.service.ts )

  • 目的:与外部 API 或数据源交互

  • 命名:文件应命名为<feature>.service.ts

  • 模式:纯 API 交互,逻辑最少

实用程序层 ( src/utils/*.util.ts )

  • 目的:提供跨应用程序的共享功能

  • 主要用途:

    • logger.util.ts :结构化日志记录

    • error.util.ts :错误处理和标准化

    • formatter.util.ts :Markdown 格式化助手


开发指南

开发脚本

# Start server in development mode (hot-reload & inspector)
npm run dev:server

# Run CLI in development mode
npm run dev:cli -- [command] [args]

# Build the project
npm run build

# Start server in production mode
npm run start:server

# Run CLI in production mode
npm run start:cli -- [command] [args]

测试

# Run all tests
npm test

# Run specific tests
npm test -- src/path/to/test.ts

# Generate test coverage report
npm run test:coverage

代码质量

# Lint code
npm run lint

# Format code with Prettier
npm run format

# Check types
npm run typecheck

构建自定义工具

按照以下步骤将您自己的工具添加到服务器:

1.定义服务层

在src/services/中创建一个新服务来与您的外部 API 交互:

// src/services/example.service.ts
import { Logger } from '../utils/logger.util.js';

const logger = Logger.forContext('services/example.service.ts');

export async function getData(param: string): Promise<any> {
	logger.debug('Getting data', { param });
	// API interaction code here
	return { result: 'example data' };
}

2.创建控制器

在src/controllers/中添加一个控制器来处理业务逻辑:

// src/controllers/example.controller.ts
import { Logger } from '../utils/logger.util.js';
import * as exampleService from '../services/example.service.js';
import { formatMarkdown } from '../utils/formatter.util.js';
import { handleControllerError } from '../utils/error-handler.util.js';
import { ControllerResponse } from '../types/common.types.js';

const logger = Logger.forContext('controllers/example.controller.ts');

export interface GetDataOptions {
	param?: string;
}

export async function getData(
	options: GetDataOptions = {},
): Promise<ControllerResponse> {
	try {
		logger.debug('Getting data with options', options);

		const data = await exampleService.getData(options.param || 'default');

		const content = formatMarkdown(data);

		return { content };
	} catch (error) {
		throw handleControllerError(error, {
			entityType: 'ExampleData',
			operation: 'getData',
			source: 'controllers/example.controller.ts',
		});
	}
}

3. 实现MCP工具

在src/tools/中创建工具定义:

// src/tools/example.tool.ts
import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
import { z } from 'zod';
import { Logger } from '../utils/logger.util.js';
import { formatErrorForMcpTool } from '../utils/error.util.js';
import * as exampleController from '../controllers/example.controller.js';

const logger = Logger.forContext('tools/example.tool.ts');

const GetDataArgs = z.object({
	param: z.string().optional().describe('Optional parameter'),
});

type GetDataArgsType = z.infer<typeof GetDataArgs>;

async function handleGetData(args: GetDataArgsType) {
	try {
		logger.debug('Tool get_data called', args);

		const result = await exampleController.getData({
			param: args.param,
		});

		return {
			content: [{ type: 'text' as const, text: result.content }],
		};
	} catch (error) {
		logger.error('Tool get_data failed', error);
		return formatErrorForMcpTool(error);
	}
}

export function register(server: McpServer) {
	server.tool(
		'get_data',
		`Gets data from the example API, optionally using \`param\`.
Use this to fetch example data. Returns formatted data as Markdown.`,
		GetDataArgs.shape,
		handleGetData,
	);
}

4.添加CLI支持

在src/cli/中创建一个 CLI 命令:

// src/cli/example.cli.ts
import { program } from 'commander';
import { Logger } from '../utils/logger.util.js';
import * as exampleController from '../controllers/example.controller.js';
import { handleCliError } from '../utils/error-handler.util.js';

const logger = Logger.forContext('cli/example.cli.ts');

program
	.command('get-data')
	.description('Get example data')
	.option('--param <value>', 'Optional parameter')
	.action(async (options) => {
		try {
			logger.debug('CLI get-data called', options);

			const result = await exampleController.getData({
				param: options.param,
			});

			console.log(result.content);
		} catch (error) {
			handleCliError(error);
		}
	});

5. 注册组件

更新入口点以注册新组件:

// In src/cli/index.ts
import '../cli/example.cli.js';

// In src/index.ts (for the tool)
import exampleTool from './tools/example.tool.js';
// Then in registerTools function:
exampleTool.register(server);

调试工具

MCP 检查器

访问可视化 MCP 检查器来测试您的工具并查看请求/响应详细信息:

  1. 运行npm run dev:server

  2. 在浏览器中打开http://localhost:5173

  3. 测试您的工具并直接在 UI 中查看日志

服务器日志

启用开发调试日志:

# Set environment variable
DEBUG=true npm run dev:server

# Or configure in ~/.mcp/configs.json

发布您的 MCP 服务器

准备发布您的自定义 MCP 服务器时:

  1. 使用您的详细信息更新 package.json

  2. 使用您的工具文档更新 README.md

  3. 构建项目: npm run build

  4. 测试生产版本: npm run start:server

  5. 发布到 npm: npm publish


执照

MIT 许可证

{
	"reviewwebsite": {
		"environments": {
			"DEBUG": "true",
			"REVIEWWEBSITE_API_KEY": "your-api-key-here"
		}
	}
}

**注意:**为了向后兼容,如果未找到reviewwebsite键,服务器也会识别完整软件包名称 ( reviewwebsite-mcp-server ) 或未指定范围的软件包名称 ( reviewwebsite-mcp-server ) 下的配置。但是,建议对新配置使用短reviewwebsite键。

Available Tools

16 tools
convert_multiple_to_markdownB

Convert multiple URLs to Markdown using AI via ReviewWeb.site API. Turn multiple web pages into LLM-friendly content.

Inputs: urls (required), model, instructions, delayAfterLoad, +3 more.

convert_to_markdownB

Convert a URL to Markdown using AI via ReviewWeb.site API. Turn a web page into LLM-friendly content.

Inputs: url (required), model, instructions, delayAfterLoad, +2 more.

extract_dataB

Extract structured data (JSON) from a web page URL using AI via ReviewWeb.site API.

Inputs: url (required), instructions (required), jsonTemplate (required), systemPrompt, +5 more.

extract_data_multipleB

Extract structured data (JSON) from multiple web page URLs using AI via ReviewWeb.site API.

Inputs: urls (required), instructions (required), jsonTemplate (required), systemPrompt, +4 more.

html_to_screenshotB

Convert HTML content to a screenshot image using ReviewWeb.site API. Renders raw HTML string via headless browser and returns screenshot as hosted URL or image data.

Inputs: html (required), viewport_width, viewport_height, full_page, +5 more.

scrape_urlC

Scrape a URL and return HTML content using ReviewWeb.site API.

Inputs: url (required), delayAfterLoad, api_key.

seo_keyword_difficultyC

Get keyword difficulty for a keyword using ReviewWeb.site API.

Inputs: keyword (required), country, api_key.

seo_keyword_ideasB

Get keyword ideas for a keyword using ReviewWeb.site API.

Inputs: keyword (required), country, searchEngine, api_key.

seo_trafficC

Check traffic for a domain or URL using ReviewWeb.site API.

Inputs: domainOrUrl (required), mode, country, api_key.

summarize_multiple_urlsC

Summarize multiple web page URLs using AI via ReviewWeb.site API.

Inputs: urls (required), instructions, systemPrompt, model, +6 more.

summarize_urlB

Summarize a web page URL using AI via ReviewWeb.site API.

Inputs: url (required), instructions, systemPrompt, model, +5 more.

summarize_websiteC

Summarize a website (and its internal links) using AI via ReviewWeb.site API.

Inputs: url (required), instructions, systemPrompt, model, +6 more.

url_get_after_redirectsC

Get URL after redirects using ReviewWeb.site API.

Inputs: url (required), api_key.

url_is_aliveC

Check if a URL is alive using ReviewWeb.site API.

Inputs: url (required), timeout, proxyUrl, api_key.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.2/5.0

    Scored across 16 tools

    Disambiguation4/5

    Tools are mostly distinct in purpose, but some overlap exists (e.g., convert_to_markdown and extract_data both take URLs and produce AI-generated content). However, descriptions clarify the output format (markdown vs JSON), so ambiguity is low.

    Naming Consistency3/5

    Naming conventions vary: some tools use 'convert_', 'extract_', 'summarize_', while SEO tools prefix with 'seo_' and URL tools with 'url_'. This grouping is helpful but not fully uniform across the set.

    Tool Count4/5

    With 16 tools, the server covers a broad range of web page analysis features (scraping, AI conversion, SEO, URL utilities). The number is slightly above the typical 3-15 range but justified by the breadth of functionality.

    Completeness4/5

    The tool surface covers major web page operations: scraping, AI summarization, data extraction, SEO metrics, and URL checks. Minor gaps include no tool for batch extraction of links or more granular customization, but core workflows are supported.

    Maintenance

    ActivityNo data
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      D
      maintenance
      MCP server that enables LLMs to interact with Tripadvisor API, supporting location data, reviews, and photos through standardized MCP interfaces
      5
      64
      MIT
    • A
      license
      Not graded
      quality
      Not graded
      maintenance
      An MCP server that extracts clean, structured Markdown content from web page URLs using the WebforAI library. It simplifies feeding web content into AI models by removing HTML noise and intelligently processing tables and links.
      -
    • F
      license
      Not graded
      quality
      D
      maintenance
      A locally-hosted MCP server that provides AI assistants with advanced web crawling capabilities, including structured data extraction, deep site crawling, and page screenshots. It enables users to convert single or multiple URLs into clean Markdown content for processing by LLMs without requiring external API keys for basic features.
      -
    • A
      license
      A
      quality
      B
      maintenance
      An MCP server that enables AI assistants to fetch web content in multiple formats (HTML, JSON, text, Markdown) with intelligent content extraction, chunk management, and browser automation support.
      6
      83 npm
      15
      MIT