Cloudflare MCP Logging
Enables logging management through Cloudflare LogPush and R2 storage buckets, including scripts to download and process server logs.
Supports deploying MCP servers as Cloudflare Workers with features for handling Server-Sent Events (SSE) and utilizing worker-specific execution contexts.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Cloudflare MCP Loggingfetch my execution logs from R2 for the last hour"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Setup
Start up container
docker compose up -dInitialize package.json
npm init -y(First time to create package.json)npm install
MCP Server Creation
Create from CF template
npm create cloudflare@latest -- mcp-logging --template=cloudflare/ai/demos/remote-mcp-authlessIf clone template failed, git clone cloudflare/ai repo below, then recreate
git clone https://github.com/cloudflare/ai.git
Start dev server
Update to use
wrangler dev --ip 0.0.0.0IP in package.jsonPort mapping
8787:8787in docker-compose.ymlnpm startORwrangler dev --ip 0.0.0.0Access via
localhost:8787/sse
Deploy CF Worker
Set CF account ID to wrangler.jsonc
"account_id": "<EDIT-HERE>"Set CF API key in env
API's permission template:
Edit Cloudflare WorkersENV:
CLOUDFLARE_API_TOKEN=<EDIT-HERE>
Deploy worker to CF
npm run deployORnpx wrangler deploy
MCP Inspector
Start inspector
npx @modelcontextprotocol/inspector@latest
Connect via MCP Host/Client
mcp-remote
{ "mcpServers": { "CF Remote MCP": { "command": "npx", "args": [ "-y", "mcp-remote", "https://<MCP_SERVER_URL>/sse" ] } } }supergateway
{ "mcpServers": { "Basic Calculator": { "command": "npx", "args": [ "-y", "supergateway", "--sse", "http://localhost:8787/sse", "--header", "X-UserID:USERID_123", "--header", "X-SecretKey:SKEY_456" ] } } }
LogPush
Enable
logpushfor CF workerSet
"logpush": truein wrangler.jsoncDeploy to CF & check settings
Create R2 API token
Create R2 bucket
Create LogPush job
Set env (edit the value)
R2_BUCKET_NAME="EDIT: R2 BUCKET NAME"
R2_LOG_BASE_PREFIX="EDIT: R2 FOLDER NAME"
CF_R2_ACCESS_KEY_ID="EDIT: R2 ACCESS KEY ID"
CF_R2_SECRET_ACCESS_KEY="EDIT: R2 ACCESS SECRET"Run
utils/download_r2_logs.jsscript to get logsnode utils/download_r2_logs.js --start-date "2025-06-27 07:00:00" --end-date "2025-06-27 08:00:00"
Pass Variable to Tool Function
Set
ctx.propsin fetch entrypoint.export default { fetch(request: Request, env: Env, ctx: ExecutionContext) { const userId: string | null = request.headers.get('X-UserID'); const secretKey: string | null = request.headers.get('X-SecretKey'); ctx.props = { userId, secretKey }; // add thisUse
this.props.<VARIABLE_NAME>in tool.this.server.tool( "calculate", { operation: z.enum(["add", "subtract", "multiply", "divide"]), a: z.number(), b: z.number() }, async ({ operation, a, b,}) => { try { // retrieve here const userId: string | null = this.props.userId as string; const secretKey: string | null = this.props.secretKey as string;
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Alicense-qualityCmaintenanceA template for deploying authentication-free MCP servers on Cloudflare Workers. Enables users to create custom tools accessible through Claude Desktop or the Cloudflare AI Playground.2,504MIT
- Flicense-qualityDmaintenanceA template for deploying MCP servers on Cloudflare Workers without authentication. Enables users to create and customize their own remote MCP tools that can be accessed from Claude Desktop or AI playgrounds.
- Flicense-qualityCmaintenanceA template for deploying authentication-free MCP servers on Cloudflare Workers, enabling custom tool creation and integration with Claude Desktop and AI Playground via remote connections.7
- Alicense-qualityCmaintenanceA template for deploying custom MCP servers on Cloudflare Workers without authentication. Enables users to create and deploy their own tools accessible from Claude Desktop and AI Playground via SSE endpoints.2,504MIT
Related MCP Connectors
MCP server for AI agents to plan, verify, and deploy Cloudflare-native apps.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/weyseing/cloudflare-mcp-logging'
If you have feedback or need assistance with the MCP directory API, please join our Discord server