---
title: "GET /api/search/debug"
method: GET
path: "/api/search/debug"
tags: ["/api/search"]
---

# GET /api/search/debug

`GET /api/search/debug`

## Request

- Base URL: `` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/api/search/debug`
- Auth: API key in header `X-API-Key`

Superuser-only. Explain why `expected_result_id` / `expected_result_type` does not appear in the results of
  the given search query. Accepts every `GET /api/search` parameter plus the two expected-result parameters, and
  returns `{:type ..., :details ...}` for the first stage that drops the item: `not-searchable`,
  `missing-from-index`, `not-permitted`, `filtered`, `not-matching`, or the terminal `matched` / `ranked-out`.

  - `for_user_id`: diagnose from another user's perspective (defaults to you). Permission and visibility checks run
    as that user, so a `not-permitted` result means *they* can't see the item.

  Not supported for `indexed-entity` (its id is compound).

## Query parameters

- `vector_search_ef_search` integer, nullable
- `expected_result_type` 'dashboard' | 'table' | 'exploration' | 'dataset' | 'segment' | 'collection' | 'measure' | 'transform' | 'document' | 'database' | 'data-app' | 'action' | 'indexed-entity' | 'metric' | 'card', required
- `q` string, nullable
- `collection` integer, nullable: value must be an integer greater than zero.
- `vector_search_explain` boolean, nullable
- `created_by` integer[], nullable
- `include_metadata` boolean, nullable
- `ids` integer[], nullable
- `archived` boolean, nullable
- `verified` boolean, nullable
- `last_edited_by` integer[], nullable
- `context` 'basic-actions' | 'browse' | 'command-palette' | 'data-picker' | 'dependencies' | 'document' | 'embedding-setup' | 'entity-picker' | 'library' | 'model-migration' | 'search-app' | 'search-bar' | 'type-filter' | 'api' | 'metabot'
- `vector_search_strategy` 'hnsw' | 'brute-force' | 'hnsw-iterative-relaxed' | 'hnsw-iterative-strict', nullable
- `model_ancestors` boolean, nullable
- `calculate_available_models` boolean, nullable
- `display_type` string[], nullable
- `expected_result_id` integer, required
- `created_at` string, nullable: value must be a non-blank string.
- `for_user_id` integer, nullable: value must be an integer greater than zero.
- `models` string[], nullable
- `last_edited_at` string, nullable: value must be a non-blank string.
- `search_native_query` boolean, nullable
- `table_db_id` integer, nullable: value must be an integer greater than zero.
- `include_dashboard_questions` boolean, nullable
- `vector_search_max_scan_tuples` integer, nullable
- `filter_items_in_personal_collection` 'all' | 'only' | 'only-mine' | 'exclude' | 'exclude-others', nullable
- `search_engine` string, nullable

## Response `2XX`

Successful response

## Other responses

- `4XX`: Client error response
- `5XX`: Server error response

## Changes

- **2026-11-04** `2e178f5a7934`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/metabase/apis/metabase-api/changes/api/search/debug/get.md)

---

[API](https://skmtc.dev/metabase/apis/metabase-api.md) - [All operations](https://skmtc.dev/metabase/apis/metabase-api/llms.txt) - [OpenAPI document](https://skmtc.dev/metabase/apis/metabase-api/revisions/2e178f5a7934?raw)
