Problem
When querying Workers logs via the workers-observability MCP server's events view, custom fields from structured console.log() calls are not included in the response. The fields are indexed and work for filtering and calculations/groupBy, but their values are never returned in event results.
Example
A Worker logging:
console.log({ event: "sync_complete", userId: "abc-123", synced: 10, durationMs: 1307 })
Cloudflare Dashboard shows the full event with custom fields at the top level:
{
"event": "sync_complete",
"userId": "abc-123",
"synced": 10,
"durationMs": 1307,
"$workers": { ... },
"$metadata": { "type": "cf-worker", ... }
}
MCP events view returns the same event (same $metadata.id) without the custom fields:
{
"dataset": "cloudflare-workers",
"timestamp": 1775208144119,
"source": {},
"$workers": { ... },
"$metadata": { ... }
}
What works vs what doesn't
| Feature |
Custom fields work? |
Filtering (event eq "sync_complete") |
Yes |
observability_values (list values for event, userId) |
Yes |
Calculations with groupBy (count by event + userId) |
Yes |
| Events view — seeing the actual field values |
No |
Current workaround
We currently have to call the REST API directly via a custom script to bypass the MCP and get the full event payload:
const url = `https://api.cloudflare.com/client/v4/accounts/${ACCOUNT_ID}/workers/observability/telemetry/query`;
const response = await fetch(url, {
method: 'POST',
headers: {
Authorization: `Bearer ${API_TOKEN}`,
'Content-Type': 'application/json',
},
body: JSON.stringify(query), // same query format as MCP
});
const data = await response.json();
const events = data.result?.events?.events; // these DO include custom fields
The API returns the custom fields correctly — it's only the MCP response that strips them.
Question
Is this intentional, or is there a recommended way to retrieve the full console.log content through the MCP server that we're missing?
Problem
When querying Workers logs via the
workers-observabilityMCP server's events view, custom fields from structuredconsole.log()calls are not included in the response. The fields are indexed and work for filtering and calculations/groupBy, but their values are never returned in event results.Example
A Worker logging:
Cloudflare Dashboard shows the full event with custom fields at the top level:
{ "event": "sync_complete", "userId": "abc-123", "synced": 10, "durationMs": 1307, "$workers": { ... }, "$metadata": { "type": "cf-worker", ... } }MCP events view returns the same event (same
$metadata.id) without the custom fields:{ "dataset": "cloudflare-workers", "timestamp": 1775208144119, "source": {}, "$workers": { ... }, "$metadata": { ... } }What works vs what doesn't
event eq "sync_complete")observability_values(list values forevent,userId)event+userId)Current workaround
We currently have to call the REST API directly via a custom script to bypass the MCP and get the full event payload:
The API returns the custom fields correctly — it's only the MCP response that strips them.
Question
Is this intentional, or is there a recommended way to retrieve the full console.log content through the MCP server that we're missing?