Skip to main content
Glama
yunusemregul

Kibana Bridge MCP

by yunusemregul

summarize_logs

Returns a token-light summary of log queries: total hits, time histogram, and top values, so you can see data shape and choose filters before searching.

Instructions

Returns a cheap summary of a log query: total hits, time histogram, and top-N values for chosen dimensions. Use this BEFORE search_logs to see the shape of the data and decide which exclude_filters to apply. No hits are returned (size=0), so this is very cheap on tokens even over 7-day windows.

Typical first call for an investigation: summarize_logs(query, minutes_lookback: 10080). It gives you total hits per day and the noisy dimensions to exclude in the follow-up search.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
levelNoFilter on the level field (LEVEL_FIELD env, default logs.level; currently `logs.level`), e.g. 'ERROR' or ['ERROR','WARN']. Prefer this over putting ERROR in query, which also matches INFO messages containing the word error.
queryYesSame as search_logs. An empty string or '*' matches all documents. The text is matched against these fields: message, logs.message, msg, log, logs.loggerName, logs.thread, logs.thrown.name, logs.thrown.message, logs.request, logs.requestFirstLine (override with the QUERY_FIELDS env var).
top_nNoTop values per field. Default 10.
time_toNoAbsolute end time, ISO 8601. Without time_from, the window starts minutes_lookback before this.
query_dslNoRaw OpenSearch/Elasticsearch query DSL clause, AND-ed into the bool filter alongside `query` and the time range. Use for anything the plain text query can't express: numeric ranges ({range: {status: {gte: 500}}}), wildcards ({wildcard: {'url.keyword': '/api/*'}}), OR logic ({bool: {should: [...], minimum_should_match: 1}}), exists checks, etc.
time_fromNoAbsolute start time, ISO 8601 (e.g. '2026-09-23T10:28:00Z'). Without time_to, the window runs from here to now.
environmentNoWhich dashboard environment to search, as configured in the extension popup. The extension has not reported any environments yet, so omit this unless the user names one.
search_typeNo
exclude_filtersNoSame as search_logs: apply prior excludes so the summary reflects the narrowed set.
include_filtersNo
aggregate_fieldsNoDotted field paths to bucket by. Default ["logs.level","logs.loggerName","logs.thrown.name","kubernetes.pod_name"]. The server appends '.keyword' automatically when needed. Discover valid paths with available_log_fields.
minutes_lookbackNoWindow length in minutes. Default 15. With neither time_from nor time_to it means the last N minutes up to now; with only time_to it means the N minutes ending at time_to; ignored when time_from is given. The response header always shows the resolved absolute UTC window.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.2

TDQS

A4.3/5.0
Behavior4/5

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

No annotations are provided, so the description carries the full burden. It discloses the key behavioral traits: size=0 means no hits are returned, cost is cheap on tokens even over 7-day windows, defaults for aggregates, and that the response header shows the resolved UTC window. It does not cover permissions or rate limits, but the cost/shape disclosure is genuinely useful.

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

Conciseness4/5

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

Front-loaded with the return shape, then the routing rule, then a concrete example call. The second paragraph largely restates the first ('typical first call' repeats 'use before search_logs'), which is mild redundancy but keeps the guidance actionable.

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 12-parameter, nested-object tool with no output schema, the description states what is returned (hits total, histogram, top-N) and the cost profile, and defers field discovery to available_log_fields. It is complete enough to call correctly, though it does not warn about the interplay between time_from/minutes_lookback beyond what the schema states.

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 description coverage is 83%, so the schema already documents most parameters in detail. The description adds workflow meaning (exclude_filters should carry prior excludes so the summary reflects the narrowed set) but no syntax or format detail beyond what the schema provides; baseline 3 is appropriate.

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 first sentence states a specific verb (Returns), resource (a log query summary) and the exact payload (total hits, time histogram, top-N dimension values). It is immediately distinguishable from search_logs, which returns actual hits.

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

Usage Guidelines5/5

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

Explicitly routes the agent: 'Use this BEFORE `search_logs` to see the shape of the data and decide which `exclude_filters` to apply,' and repeats the workflow in the typical-first-call example. Both the when and the alternative are named.

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