# Search Saved Searches

`Search_Saved_Searches` returns saved search records that teams use to persist search criteria and monitor result changes over time.

## When To Use

Typical questions this tool answers well:

* Which saved searches already exist for this workspace or user?
* What criteria, filters, and cadence are configured for a specific saved search?
* Which saved searches belong to one owner or were created by a specific user?
* Which saved searches match a topic or phrase in their saved query content?
* What is the `search_persistence_id` or result URL I need for related saved-search workflows?

## Required Reading

1. [Search\_Mode\_And\_Query\_Guide](/user-guide/mcp/guides/search_mode_and_query_guide.md): Required before setting free-text query strings.

## Output Contract

* Top-level keys:
  * `current_page`: Current page number when `per_page > 0`.
  * `data`: Array of result rows when `per_page > 0`.
  * `from`: First row position in the current page.
  * `last_page`: Last page number for current filters.
  * `path`: GovTribe search URL for this result set.
  * `per_page`: Applied page size.
  * `to`: Last row position in the current page.
  * `total`: Total matched row count for current query filters.
  * `contains`: Dataset label for the returned result set.
  * `search_results_id_can_generate_saved_search`: Saved-search eligibility flag.
  * `search_results_id`: Server-side search result identifier.
  * `view_search_results_url`: URL to open this exact result set.
  * `per_page: 0` behavior: returns only `path`, `total`, `contains`, `search_results_id_can_generate_saved_search`, `search_results_id`, and `view_search_results_url`.
* Row keys:
  * `govtribe_id`
  * `govtribe_type`
  * `govtribe_url`
  * `name`
  * `frequency`
  * `q`
  * `filters`
  * `sorts`
  * `view_results_url`
  * `searches_govtribe_type`
  * `search_persistence_id`
  * `last_sent`
  * `created_at`
  * `updated_at`
  * `owner`
  * `creator`
* Relationship retrieval map:
  * `creator`
    * `resource_type`: `user`
    * `tool`: `Search_Users`
    * `filter`: `user_ids`
    * `nested_keys`: `govtribe_id`, `govtribe_type`, `name`, `email`
  * `owner`
    * `resource_type`: `user`
    * `tool`: `Search_Users`
    * `filter`: `user_ids`
    * `nested_keys`: `govtribe_id`, `govtribe_type`, `name`, `email`

## Usage Patterns

Pattern A: List saved searches with default text-match behavior. Tool: `Search_Saved_Searches`

```json
{
  "fields_to_return": [
    "govtribe_id"
  ],
  "page": 1,
  "per_page": 10
}
```

Pattern B: Exact lookup by saved-search name. Tool: `Search_Saved_Searches`

```json
{
  "query": "\"pipeline monitor\"",
  "fields_to_return": [
    "govtribe_id"
  ],
  "page": 1,
  "per_page": 10
}
```

Pattern C: Fetch only saved searches owned by specific users. Tool: `Search_Saved_Searches`

```json
{
  "fields_to_return": [
    "govtribe_id"
  ],
  "owner_ids": [
    "<OWNER_USER_ID_1>",
    "<OWNER_USER_ID_2>"
  ],
  "owner_ids_operator": "in",
  "page": 1,
  "per_page": 25
}
```

Pattern D: Exclude saved searches created by a service account. Tool: `Search_Saved_Searches`

```json
{
  "fields_to_return": [
    "govtribe_id"
  ],
  "creator_ids": [
    "<CREATOR_USER_ID>"
  ],
  "creator_ids_operator": "not_in",
  "page": 1,
  "per_page": 25
}
```

Pattern E: Metadata-only response to get count and reusable result identifier. Tool: `Search_Saved_Searches`

```json
{
  "query": "opportunity alerts",
  "page": 1,
  "per_page": 0
}
```

Then rerun with the same filters and `per_page > 0` to fetch row payloads.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.govtribe.com/user-guide/mcp/tools/search-saved-searches.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
