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

# Google AIモード API: 回答、Markdown、出典

> Google AIモードに質問し、テキストとMarkdownの回答を、出典、商品、引用チップとともに受け取ります。

`AIMODE` は Google AIモードに質問し、常にMarkdown付きの回答と、その裏にある出典を返します。

| | |
| - | - |
| taskType | `AIMODE` |
| エイリアス | `GOOGLE_AIMODE` |
| 読むフィールド | `query`(なければ `prompt`) |
| クレジット | 1.25 |
| 国 | 任意、既定は `US`。`CN` は AIによる概要のように米国市場へ置き換えず、Google の中国市場にそのまま質問します。 |
| 位置情報 | `payload.location` を受け付けます。[地域と位置情報](/ja/engines/capacity.md)を参照してください。 |

## リクエスト

```bash theme={"theme":"css-variables"}
curl -X POST https://api.querying.ai/v1/async/task \
  -H "Authorization: Bearer $QUERYING_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "taskType": "AIMODE", "payload": { "query": "best CRM for a small team", "country": "US" } }'
```

## レスポンス

[Google AIによる概要](/ja/engines/google-ai-overviews.md)と異なり、AIモードは結果ページのエンベロープではなく、回答そのものを返します。

| フィールド | 型 | 説明 |
| - | - | - |
| `text` | string | 回答。常に存在します。 |
| `markdown` | string | Markdownの回答。フラグなしで返ります。 |
| `sources` | array | `position`、`url`、`label`、`description`。 |
| `shoppingCards`、`inlineProducts` | array | 回答内の商品。フィールドはAIによる概要と同じです。 |
| `citationPills` | array | 各引用チップの裏にある出典。フィールドはAIによる概要と同じです。 |
| `videos` | array | 回答に表示された動画。 |
| `rawContent` | string | レンダリングされたページのHTML。`include.rawResponse` のときのみ。 |

商品、チップ、動画のフィールドは、回答にそれらが表示されたときだけ含まれます。

例:

```json theme={"theme":"css-variables"}
{
  "text": "For a small team, start with HubSpot CRM or Pipedrive ...",
  "markdown": "For a small team, start with **HubSpot CRM** or **Pipedrive** ...",
  "sources": [{ "position": 1, "url": "https://www.example.com/crm-guide", "label": "CRM guide for small teams" }]
}
```

Google がページを読み込んでも新しいセッション2回で回答を返さない場合、タスクは待たずに `ENGINE_NO_RESULT` で失敗します。

## includeフラグ

| フラグ | 効果 |
| - | - |
| `rawResponse` | `rawContent` を追加します。 |
| `html` | Google が表示したページを `html` に追加します。[HTMLページ](/ja/engines/html-pages.md)を参照してください。 |
| `analysis` | `analysis` を追加します。1クレジット。[回答の分析](/ja/engines/answer-analysis.md)を参照してください。 |
| `citationAnalysis` | 回答に対して[Citation Analysis](/ja/research/citation-analysis.md)を実行します。 |

`markdown` にフラグは不要です。`searchQueries`、`ads`、`shopping` は効果がありません。[Markdownと生のレスポンス](/ja/engines/response-options.md)を参照してください。

## 関連ページ

* [Google AIモード製品ページ](https://querying.ai/ja/engines/google-ai-mode)
* [エンジンの概要](/ja/engines/overview.md)


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