Cloudflare Traces
Use Cloudflare's general API MCP server (https://mcp.cloudflare.com/mcp), not
a product-specific observability endpoint.
Current API mapping#
otelnormally returns trace summaries and spans, including custom spans.cloudflare-workersnormally returns invocation and structuredconsolelogs.[]searches all current datasets; use it to correlate a shared ID.
These are observed Workers Observability API dataset names, not a permanent
public schema. An otel-only query cannot prove a log is missing. Query the
keys/values endpoints when a dataset, field, or value is uncertain.
Workflow#
- Use the MCP OpenAPI search tool to verify the Workers Observability
telemetry/query,keys, andvaluesendpoints. - Select the account explicitly when more than one is available.
- Start with the narrowest known UTC timeframe and service name.
- Search all datasets for a known call/log/session/request ID.
- Follow a returned
traceIdinotel; followlog.idorlog.parentIdincloudflare-workers. - Widen the timeframe before adding complicated filters.
- Return compact fields and aggregates rather than thousands of raw events.
See EXAMPLES.md for reusable query blocks.
Trace audit#
For every semantic span report:
name,traceId,spanId,parentSpanId;- start, end, and duration;
- outcome/error attributes;
- script service/version; and
- whether the parent exists and how their time ranges overlap.
OpenTelemetry permits a child to outlive its parent. Judge timing against the application span's declared scope and code ordering: flag a mismatch only when that contract says the parent must contain the child. Treat automatic native spans separately. Cloudflare documents beta tracing limitations, including 0ms non-I/O spans and incomplete attributes. Iterate also observed native offsets that violated known code ordering on 2026-07-13; treat that as a dated product observation and corroborate it with application attributes and a controlled reproduction.
Observed on 2026-07-13: a failed custom ITX span's presentation message ended
in OK while source.itx.outcome was error. Treat message suffixes and level
as presentation metadata. Use explicit application outcome attributes; for ITX,
a correlated error-level log is useful corroboration.
Dashboard link#
Once the account and trace are known:
https://dash.cloudflare.com/<account-id>/observability/traces/<trace-id>
Report#
Include the account/service, UTC timeframe, trace deep link, script version, span/log counts, semantic chain, correlation IDs, failures, span-contract violations, and the exact query that established each conclusion.