---
type: api
title: List tools
description: **Spaces method and path for this operation:**
url: https://www.elastic.co/elastic/docs-builder/docs/4641/api/doc/kibana/v9/operation/operation-get-agent-builder-tools
resource: https://www.elastic.co/elastic/docs-builder/docs/4641/api/doc/kibana/v9/operation/operation-get-agent-builder-tools
products:
  - Kibana
---

# List tools

Authentication: required

Availability: Generally available since 9.2

- Server: `https://{kibana_url}`

## Paths

- `GET` `/api/agent_builder/tools`
- `GET` `/s/{space_id}/api/agent_builder/tools`

#### Path parameters

- `space_id` (string) — optional
  An identifier for the space. If `space_id` is not provided in the URL, the default space is used. Refer to [Spaces](https://www.elastic.co/docs/deploy-manage/manage-spaces) for more information.

## Description

List all available tools. Use this endpoint to retrieve complete tool definitions including their schemas and configuration requirements. To learn more about Agent Builder tools, refer to the [tools documentation](https://www.elastic.co/docs/explore-analyze/ai-features/agent-builder/tools).

## Required authorization

- Privileges: `agentBuilder:read`

## Response

Indicates a successful response

`application/json`

## Code examples

#### Console

```console
GET kbn:/api/agent_builder/tools
```

#### curl

```curl
curl \
  -X GET "https://${KIBANA_URL}/api/agent_builder/tools" \
  -H "Authorization: ApiKey ${API_KEY}"
```

## Response examples

#### List tools response

`application/json`

Example response returning a list of existing tools

```json
{
  "results": [
    {
      "configuration": {},
      "description": "A powerful tool for searching and analyzing data within your Elasticsearch cluster.\nIt supports both full-text relevance searches and structured analytical queries.\n\nUse this tool for any query that involves finding documents, counting, aggregating, or summarizing data from a known index.\n\nExamples of queries:\n- \u0022find articles about serverless architecture\u0022\n- \u0022search for support tickets mentioning \u0027billing issue\u0027 or \u0027refund request\u0027\u0022\n- \u0022what is our policy on parental leave?\u0022\n- \u0022list all products where the category is \u0027electronics\u0027\u0022\n- \u0022show me the last 5 documents from that index\u0022\n- \u0022show me the sales over the last year break down by month\u0022\n\nNote:\n- The \u0027index\u0027 parameter can be used to specify which index to search against.\n If not provided, the tool will decide itself which is the best index to use.\n- It is perfectly fine not to specify the \u0027index\u0027 parameter. It should only be specified when you already\n know about the index and fields you want to search on, e.g. if the user explicitly specified it.",
      "id": "platform.core.search",
      "readonly": true,
      "schema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "additionalProperties": false,
        "type": "object",
        "properties": {
          "index": {
            "description": "(optional) Index to search against. If not provided, will automatically select the best index to use based on the query.",
            "type": "string"
          },
          "query": {
            "description": "A natural language query expressing the search request",
            "type": "string"
          }
        },
        "required": [
          "query"
        ]
      },
      "tags": [],
      "type": "builtin"
    },
    {
      "configuration": {},
      "description": "Retrieve the full content (source) of an Elasticsearch document based on its ID and index name.",
      "id": "platform.core.get_document_by_id",
      "readonly": true,
      "schema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "additionalProperties": false,
        "type": "object",
        "properties": {
          "id": {
            "description": "ID of the document to retrieve",
            "type": "string"
          },
          "index": {
            "description": "Name of the index to retrieve the document from",
            "type": "string"
          }
        },
        "required": [
          "id",
          "index"
        ]
      },
      "tags": [],
      "type": "builtin"
    },
    {
      "configuration": {},
      "description": "Execute an ES|QL query and return the results in a tabular format.\n\n## Usage\n\nThis tool runs an ES|QL query; it does not write one.\n\n### Where the query comes from\n\nBy default, when you need a new query, use the \u0060platform_core_generate_esql\u0060 tool rather than writing it yourself: it inspects the target data and applies ES|QL guidance that is easy to get wrong when writing a query from memory.\nAdapting an earlier query to a new question, such as another metric or field, counts as writing a new query: call \u0060platform_core_generate_esql\u0060 again for each new question.\n\nYou can run a query as-is when it comes from:\n- the user,\n- your instructions or a skill you loaded, such as a query template,\n- the result of another tool, or an attachment.\n\nThese are default guidelines. If your instructions or a skill you loaded tell you to write ES|QL queries yourself and run them with this tool, do so. Do the same if the \u0060platform_core_generate_esql\u0060 tool is not available to you.",
      "id": "platform.core.execute_esql",
      "readonly": true,
      "schema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "additionalProperties": false,
        "type": "object",
        "properties": {
          "query": {
            "description": "The ES|QL query to execute",
            "type": "string"
          }
        },
        "required": [
          "query"
        ]
      },
      "tags": [],
      "type": "builtin"
    },
    {
      "configuration": {
        "params": {
          "limit": {
            "description": "Maximum number of results to return",
            "type": "integer"
          },
          "startTime": {
            "description": "Start time for the analysis in ISO format",
            "type": "date"
          }
        },
        "query": "FROM financial_trades | WHERE execution_timestamp \u003E= ?startTime | STATS trade_count=COUNT(*), avg_price=AVG(execution_price) BY symbol | SORT trade_count DESC | LIMIT ?limit"
      },
      "description": "Example ES|QL query tool for analyzing financial trades with time filtering",
      "id": "example-esql-tool",
      "readonly": false,
      "schema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "additionalProperties": false,
        "description": "Parameters needed to execute the query",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Maximum number of results to return",
            "type": "integer"
          },
          "startTime": {
            "description": "Start time for the analysis in ISO format",
            "format": "date-time",
            "type": "string"
          }
        },
        "required": [
          "startTime",
          "limit"
        ]
      },
      "tags": [
        "analytics",
        "finance"
      ],
      "type": "esql"
    },
    {
      "configuration": {
        "pattern": "financial_*"
      },
      "description": "Search tool specifically for financial data analysis and reporting",
      "id": "example-index-search-tool",
      "readonly": false,
      "schema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "additionalProperties": false,
        "type": "object",
        "properties": {
          "nlQuery": {
            "description": "A natural language query expressing the search request",
            "type": "string"
          }
        },
        "required": [
          "nlQuery"
        ]
      },
      "tags": [
        "search",
        "finance"
      ],
      "type": "index_search"
    }
  ]
}
```

