Skip to main content
Glama
daniil-shumko

Cloudflare Workers MCP Server

Query Worker Logs

query_worker_logs
Read-onlyIdempotent

Retrieve recent logs from a Cloudflare Worker to inspect messages, outcomes, requests, and timings. Filter by search, error-only, time window, and result limit for diagnostics.

Instructions

Query a Worker's logs (Workers Logs / observability). Returns the most recent matching events with message, outcome, request, and timing. The Worker must have observability enabled (deploy_worker's enable_observability or update_worker_settings).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoMaximum events to return (default 20)
searchNoFull-text needle matched across all log fields
minutesNoLook-back window in minutes (default 60; retention is 3–7 days)
errors_onlyNoOnly return events that carry an error
script_nameYesThe Worker whose logs to query
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint, idempotentHint, and destructiveHint=false, covering safety. The description adds behavioral context beyond annotations, such as returning 'most recent matching events' and listing the fields included (message, outcome, request, timing). This goes beyond simple read-only disclosure and aligns with annotations, with no contradictions.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences with no fluff. The first sentence states the primary action and what is returned, the second covers the key prerequisite. Every word adds value, and it is appropriately front-loaded.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a read-only log query with no output schema, the description adequately explains the tool's purpose, return fields, and the key prerequisite. It does not cover pagination or error handling, but these are not critical given the well-documented parameters and read-only safety annotations. Overall, it provides enough context for an agent to use it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema descriptions cover 100% of the 5 parameters, so the baseline is 3. The description does not add parameter-specific meaning beyond what the schema already provides; it only mentions the observability prerequisite, which is a precondition rather than a parameter semantic.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's function: 'Query a Worker's logs' with a specific verb and resource. It also distinguishes itself from sibling tools by being the only log-querying tool and by describing what it returns (message, outcome, request, timing). This is unambiguous and specific.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear usage context by stating the prerequisite that observability must be enabled and explicitly references deploy_worker's enable_observability or update_worker_settings. It does not mention alternative tools or when-not-to-use, but since no sibling tool competes for log access, the guidance is sufficient for selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/daniil-shumko/cloudflare-workers-mcp'

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