> ## Documentation Index
> Fetch the complete documentation index at: https://docs.oqoqo.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# AI search tools

> MCP tools for AI search experiments: list the AI search engines, read and set brand details, and read an experiment's results and one run's answer.

List the AI search engines for an [AI search experiment](https://docs.oqoqo.ai/experiments/ai-search.md) (private beta), read and set your brand details, and read how the answers went. To launch one, pass a plan of kind `answers` to [`launch_experiment`](https://docs.oqoqo.ai/mcp-server/experiments#launch_experiment). To list them, pass `kind` `answers` to [`list_experiments`](https://docs.oqoqo.ai/mcp-server/experiments#list_experiments).

* **Badges** are explained under [Approvals](https://docs.oqoqo.ai/mcp-server/overview.md#approvals).
* **`project_id`** is optional on most tools; without it, the server picks a project for that call only ([Projects](https://docs.oqoqo.ai/mcp-server/overview.md#projects)).
* **`expected_organization_id`** is an optional string on every write tool, omitted from parameter tables; pass `organization.id` from [`get_identity`](https://docs.oqoqo.ai/mcp-server/identity-and-projects#get_identity) ([Organization check](https://docs.oqoqo.ai/mcp-server/overview.md#organization-check)).
* Every tool here refuses with `answer_engines_unavailable` when AI search experiments are not enabled for your organization.

## Tools

### list\_answer\_engines

**List the AI search engines a project can ask.** Returns every engine of the project, whether it is on, the settings it accepts, a ready `answerSettings` value, and the configuration revisions a launch plan states.

Read-only · CLI: [`oqoqo answer-engines list`](https://docs.oqoqo.ai/cli/ai-search#oqoqo-answer-engines-list)

| Parameter | Type | Required | Description |
| - | - | - | - |
| `project_id` | string | No | The `prj_` project. |

**Result fields**

| Field | Meaning |
| - | - |
| `engines[].id` | The engine's `agm_` ID. Pass it as `projectAgentModelBindingId` in a plan of kind `answers`. |
| `engines[].engine`, `name` | The engine's key (`chatgpt`, `gemini`, `google-ai-mode`, or `copilot-search`) and its name. The key is the engine's agent key. |
| `engines[].enabled` | `false` when the engine is turned off for this project. A launch that names it is refused until it is turned on. |
| `engines[].webSearchModes` | The values `answerSettings.webSearch` takes: `auto` leaves web search to the engine, and `on` turns it on. Empty when the engine has no web search setting; then leave `webSearch` out. |
| `engines[].countries` | The countries `answerSettings.country` takes. Engines differ. |
| `engines[].usStates` | The US states `answerSettings.state` takes, with `country` `US`. Empty when the engine can't be asked from one state; then leave `state` out. |
| `defaultSettings` | An `answerSettings` value to start from: `{ "country": "US" }` |
| `projectConfigurationRevision`, `organizationConfigurationRevision` | The revisions a launch plan states |
| `projectId` | The project |

Each selection of an `answers` plan names an engine's `id` and its `answerSettings`: `country` (one of the engine's `countries`), an optional `state` (one of its `usStates`, with `country` `US`), and an optional `webSearch` (one of its `webSearchModes`). Every engine answers signed out, so the account is not a setting. A launch refuses any other field, country, or state. One engine asked two ways, such as from two countries, is two selections.

An engine is an agent. To turn one on or off, call [`manage_project_ai`](https://docs.oqoqo.ai/mcp-server/agents-and-setup#manage_project_ai) with the action `set_agents` and the engine's key, such as `agents: [{ "key": "chatgpt", "enabled": false }]`. A `set_agents` call that sets `enabled` for every agent leaves the engines as they are.

### get\_brand

**Get a project's brand details.** Returns the brand's name, other names, sites, and plugin or app listing names, and the competitors to tell apart from it.

Read-only · CLI: [`oqoqo brand get`](https://docs.oqoqo.ai/cli/ai-search#oqoqo-brand-get)

| Parameter | Type | Required | Description |
| - | - | - | - |
| `project_id` | string | No | The `prj_` project. |

**Result fields**

| Field | Meaning |
| - | - |
| `brand` | `name`, `otherNames`, `domains`, `listingNames`, `competitors` (each with `name`, `otherNames`, and `domains`), and `updatedAt`, the value `set_brand` takes as `expected_updated_at`. `null` when the project has none. |
| `project` | The project |

### set\_brand

**Set a project's brand details.** Replaces all the details. `get_answer_results` and `get_run_answer` mark old runs with them at once.

Changes data · CLI: [`oqoqo brand set`](https://docs.oqoqo.ai/cli/ai-search#oqoqo-brand-set)

| Parameter | Type | Required | Description |
| - | - | - | - |
| `project_id` | string | No | The `prj_` project. |
| `name` | string | Yes | The brand's name, as an answer would write it, up to 120 characters. |
| `other_names` | array of strings | No | Other names people call the brand, up to 20. Omitted means none. |
| `domains` | array of strings | No | Your sites, as hosts or pasted addresses, up to 20. Each is saved as its host without `www.`, and a host covers its subdomains. Omitted means none. |
| `listing_names` | array of strings | No | What the brand is called in plugin or app listings, when that differs from its name, up to 20. Omitted means none. |
| `competitors` | array of objects | No | Up to 10 competitors, each with a required `name` and optional `otherNames` and `domains`, up to 20 of each. Omitted means none. |
| `expected_updated_at` | string (date-time) or null | No | The `updatedAt` you read, or `null` when you read no details. Refuses the change with `brand_changed` when someone else saved first. Omit it to replace whatever is saved. |

A field you leave out is saved as empty, so read the details with `get_brand` first and send back what should stay. Sending the saved details again changes nothing, not even `updatedAt`, so a retry is safe. A competitor can't share a name or a site with the brand or with another competitor. Details that break a rule are refused with `invalid_brand`, and the error says what to change.

**Result fields**

The same fields as `get_brand`.

### get\_answer\_results

**Get an AI search experiment's results.** Returns who the answers name and cite over all of the experiment's runs, as four short lists: brands, other sites, prompts, and fixes.

Read-only · CLI: [`oqoqo experiments answers`](https://docs.oqoqo.ai/cli/experiments#oqoqo-experiments-answers)

| Parameter | Type | Required | Description |
| - | - | - | - |
| `project_id` | string | No | The `prj_` project. |
| `experiment_id` | string | Yes | The `exp_` ID of an experiment of kind `answers`. |
| `section` | `sites`, `prompts`, or `queries` | No | Add one whole list as `detail`, a page at a time. |
| `limit` | integer | No | Rows of the section in one page, up to 100 (default 100). |
| `offset` | integer | No | Where the page of the section starts: the `nextOffset` from the previous page (default 0). |

**Result fields**

| Field | Meaning |
| - | - |
| `runs` | `total`, `completed`, and `errored` for the whole experiment. A run that stopped with an error, was cancelled, or was blocked is in `errored` and in no other count. |
| `answers` | The finished runs the read counts. Every count of answers is out of it. |
| `engines` | One per engine asked from one place: `key`, `engine`, `label` (such as "ChatGPT · US"), `answers`, and `queriesReported` |
| `brandKnown` | `true` when the project has brand details. Without them `brands` is empty, no site has an owner, and each prompt's `named` and `cited` are `null`. |
| `brands` | Your brand, then each competitor: `name`, `owner` (`yours` or `competitor`), `answersNamed`, and `answersCited` |
| `otherSites`, `otherSitesTotal` | The 5 sites, not yours, that the most answers link to: `domain`, `answersCited`, `bestPosition`, and `owner` `competitor` with `ownerName` for a competitor's site. `otherSitesTotal` counts them all. |
| `prompts`, `promptsTotal` | Up to 10 tasks, the ones whose answers name your brand least first: `taskId`, `taskVersionId`, `name`, `runs`, `named`, `cited`, `evalsPassed`, `evalsEvaluated`, `firstMissedCriterion` (`ordinal` and `text`), and `byEngine` when the experiment has more than one engine. `promptsTotal` counts the tasks. |
| `fixes`, `fixesTotal` | The 3 frictions in the most runs that you can fix in your product or setup: `frictionId`, `title`, `fixIn` (`product` or `setup`), `fixSurface`, and `runs`. `fixesTotal` counts them all. |
| `detail` | Only with `section`: `section`, `rows`, `total`, and `nextOffset` (`null` at the end of the list) |
| `notes` | Plain sentences that change how to read the counts |

`section` `sites` pages every site, `prompts` every task, and `queries` the searches the engines reported, each with `query` and `answers`. Most engines report no searches, and `queriesReported` says which did. A response that would be too large holds fewer prompts or fewer rows of a section, and `promptsTotal` and `nextOffset` still say what exists. Each field is explained under [`oqoqo experiments answers`](https://docs.oqoqo.ai/cli/experiments#oqoqo-experiments-answers).

Read a task's runs with [`list_runs`](https://docs.oqoqo.ai/mcp-server/runs-and-results#list_runs) (`experiment_id` and `task_id`), one run's answer with [`get_run_answer`](#get_run_answer), and every friction with [`list_frictions`](https://docs.oqoqo.ai/mcp-server/frictions#list_frictions). An experiment that runs agents is refused with `not_answers_experiment`.

### get\_run\_answer

**Get an AI search engine run's answer.** Returns each prompt and its answer, the engine's sources with the ones the answer links to first, and the searches the engine says it made.

Read-only · CLI: [`oqoqo runs answer`](https://docs.oqoqo.ai/cli/runs#oqoqo-runs-answer)

| Parameter | Type | Required | Description |
| - | - | - | - |
| `project_id` | string | No | The `prj_` project. |
| `run_id` | string | Yes | The run's `run_` ID, or a trial's. |

**Result fields**

| Field | Meaning |
| - | - |
| `engine`, `engineName`, `answerSettings` | The engine and how it was asked |
| `reportedModel` | The model the engine reported. `null` when it reported none. |
| `turns[].prompt`, `turns[].answer` | What the engine was asked, and its answer: `text` as Markdown, and `truncated`, `true` when the stored answer was cut at its size limit. `answer` is `null` when the engine gave none. |
| `turns[].queries` | The searches the engine says it made. Empty when it states none, which most engines do. |
| `turns[].sources` | The engine's sources, the ones the answer links to first: `position` (its place in the engine's list, from 1), `url`, an optional `title`, `domain` (`null` when `url` is not absolute), and `cited`, `true` when the answer links to it and `false` when the engine only read it |
| `turns[].mentions` | With brand details: each brand or competitor the answer names, with `name`, `owner` (`yours` or `competitor`), `count`, and `firstIndex` |
| `brandKnown` | `true` when the project has brand details. Then each source has an `owner` (`yours`, `competitor`, or `other`), a competitor's has its `ownerName`, and each turn has `mentions`. |
| `pageUrl` | A dashboard link to the run's **Answer** tab at the saved page, for a person to open. `null` when the run saved no page. |
| `counts` | `sources`, `cited`, and `queries` over all turns |
| `sourcesTruncated` | `true` when a turn lists fewer sources than the run recorded, so that the response fits its size limit. The sources the engine only read go first. `counts` still has the totals. |
| `runId`, `trialId`, `experimentId`, `capturedAt` | The run, the trial, the experiment, and when the answer finished |

The answer and the searches are never cut to fit. A run that isn't an AI search engine run, or has no recorded answer, is refused with `run_answer_not_found`.

## Related

> [card] [AI search experiments](https://docs.oqoqo.ai/experiments/ai-search.md)
>
> Launch an AI search experiment and read its results.

> [card] [oqoqo answer-engines and brand](https://docs.oqoqo.ai/cli/ai-search.md)
>
> The matching CLI commands.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.