EdgeOne Pages MCP
An MCP server and client implementation for EdgeOne Pages Functions, supporting OpenAI-formatted requests.
EdgeOne Pages: MCP Client and Server Implementation with Functions
Project Overview
This project showcases an intelligent chat application built with EdgeOne Pages Functions technology. It interacts with backend functions through a web interface, implementing a complete Model Context Protocol (MCP) workflow.
The system architecture consists of the following core components:
- MCP Streamable HTTP Server (
functions/mcp-server/index.ts) - MCP Client (
functions/mcp-client/index.ts) - Backend API (
functions/v1/chat/completions/index.ts) as the MCP HOST, responsible for coordinating the entire MCP workflow
Through this architecture, users can access powerful MCP tool capabilities in the browser, enabling intelligent interactions such as "generating online webpages with a single prompt."
Core Features
- Interactive Chat Interface: Modern, responsive web interface built with Next.js and React
- High-Performance Edge Functions: Critical business logic deployed on highly scalable EdgeOne Pages Functions
- Complete MCP Implementation: Model Context Protocol implementation based on the latest specifications, providing powerful context management and request routing capabilities
- OpenAI Format Compatible: Backend API fully supports OpenAI-formatted request and response handling
Streamable HTTP MCP Server
Configure remote MCP services in applications that support Streamable HTTP MCP Server.
{
"mcpServers": {
"edgeone-pages-mcp-server": {
"url": "https://mcp-on-edge.edgeone.site/mcp-server"
}
}
}
Deploy
More Templates: EdgeOne Pages
Local Development
Environment Setup
First, install dependencies and start the development server:
# Install dependencies
npm install
# Or use other package managers
# yarn install / pnpm install / bun install
# Start development server
npm run dev
# Or use other package managers
# yarn dev / pnpm dev / bun dev
Configure environment variables: Copy the .env.example file and rename it to .env, then fill in your AI service interface configuration information.
After starting, visit http://localhost:3000 in your browser to view the application.
Project Structure
- Frontend Interface:
app/page.tsxcontains the main page logic and UI components - Backend Functions: All edge functions are in the
functionsdirectory- Chat API:
functions/v1/chat/completions - MCP Server:
functions/mcp-server - MCP Client:
functions/mcp-client
- Chat API:
Technical Documentation
Learn more about related technologies:
- Next.js Documentation - Next.js framework features and API
- EdgeOne Pages Functions Documentation - Detailed explanation of EdgeOne serverless functions
- Model Context Protocol (MCP) - Implemented based on the 2025-03-26 version of Streamable HTTP transport
Servidores relacionados
Alpha Vantage MCP Server
patrocinadorAccess financial market data: realtime & historical stock, ETF, options, forex, crypto, commodities, fundamentals, technical indicators, & more
OPNsense MCP Server
A comprehensive MCP server for managing OPNsense firewalls, offering over 300 tools for configuration and monitoring.
Elementor MCP Server
Perform CRUD operations on Elementor page data for a target WordPress website.
MCP Server with Ollama Integration
An MCP server that integrates with Ollama to provide tools for file operations, calculations, and text processing. Requires a running Ollama instance.
milo-usage-forecaster
MCP server that predicts your monthly LLM spend from local Claude Code / Cursor / Codex logs. Forecasts end-of-month $, ranks spike drivers, warns before budget breach. Free tier + paid tier ($19/mo), MIT licensed.
Nauro
Persistent project context for AI coding agents: captures decisions, rationale, and rejected paths so agents stay consistent across Claude, Cursor, Codex, and any MCP enabled platform.
Dappier MCP Server
An MCP server for interacting with Dappier's Retrieval-Augmented Generation (RAG) models.
BAMM
Interact with the Borrow Automated Market Maker (BAMM) protocol on the Fraxtal blockchain.
MCP Stdio Server
An MCP server using stdio transport, offering file system access, a calculator, and a code review tool. Requires Node.js.
IIIF Images Server
A server for working with IIIF (International Image Interoperability Framework) manifests and images.
Kamy
Kamy renders invoices, receipts, contracts, and 5 more production-grade templates with a single REST call or TypeScript SDK method. No headless browser. No DevOps.