Skip to main content
Glama
jerrelblankenship

Kibana MCP Server

list_data_views

Retrieve all available data views (index patterns) from Kibana to access and analyze Elasticsearch data sources.

Instructions

List all data views (index patterns) in Kibana

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler for the 'list_data_views' tool, which calls the kibanaClient and formats the output.
    case 'list_data_views': {
      const dataViews = await kibanaClient.listDataViews();
    
      return {
        content: [
          {
            type: 'text' as const,
            text: JSON.stringify(
              {
                total: dataViews.total,
                dataViews: dataViews.saved_objects.map((dv) => ({
                  id: dv.id,
                  title: dv.attributes.title,
                  timeFieldName: dv.attributes.timeFieldName,
                })),
              },
              null,
              2
            ),
          },
        ],
      };
    }
  • Tool registration for 'list_data_views' in the MCP server setup.
      name: 'list_data_views',
      description: 'List all data views (index patterns) in Kibana',
      inputSchema: {
        type: 'object',
        properties: {},
      },
    },
  • The KibanaClient implementation that performs the actual API request to list index patterns (data views).
    async listDataViews(): Promise<SavedObjectsResponse<KibanaDataView>> {
      const response = await this.axiosInstance.get('/api/saved_objects/_find', {
        params: {
          type: 'index-pattern',
          per_page: 100,
        },
      });
    
      return response.data;
    }

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/jerrelblankenship/jb-kibana-mcp'

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