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

# Exa Answer

> 提一个问题，拿回一段带引用的答案。

提一个问题，拿回一段带引用的答案。`query` 必填；`text` 会带上来源正文，`outputSchema` 可以约束结构化输出。返回 `requestId`、成段的 `answer`、`citations[]`（含 `id`、`title`、`url`）和 `costDollars`。实测 2.1 秒、8 条引用。按次固定计费。它介于搜索和研究之间：比 [`post_exa_agent_runs`](/docs/zh/api-reference/search/post_exa-agent-runs) 更快更便宜，又比自己去读 [`post_exa_search`](/docs/zh/api-reference/search/post_exa-search) 的结果更直接。[`post_perplexity_sonar`](/docs/zh/api-reference/perplexity/post_perplexity-sonar) 也能回答同一类问题 —— 当检索本身需要语义匹配时才选 Exa。

<Note>
  **第一次用？** 把任意 MCP 客户端指向 `https://mcp.aisa.one/mcp` —— Claude Code、
  Codex、Cursor、VS Code 都可以。鉴权走 OAuth：客户端打开浏览器，你点一次
  Allow，不需要粘贴任何 key。各客户端的具体命令和每次调用的价格见
  [aisa.one/zh-cn/mcp](https://aisa.one/zh-cn/mcp#connect)。
</Note>

[在你的 agent 里把这个端点跑起来 →](https://aisa.one/mcp?from=/zh/api-reference/search/post_exa-answer)


## OpenAPI

````yaml openapi/zh/exa.json POST /exa/answer
openapi: 3.0.0
info:
  title: Exa API
  version: 1.0.0
  description: >-
    通过 AIsa 网关开放的 Exa 神经语义搜索 endpoint 的统一 API 文档：Search、Contents、Answer，以及异步的研究型
    Agent Runs。


    Search、Contents 和 Answer 为同步接口，每次成功请求按固定费率计费。Agent Runs
    为异步接口：调用方提交任务，然后轮询返回的任务资源以获取状态和结果，每次任务按固定费率计费。上游 4xx 响应（例如
    401/403/404）不计费。Exa 返回的 `costDollars` 字段是上游成本明细，仅供参考——客户计费以上述 AIsa 固定价格为准。
servers:
  - url: https://api.aisa.one/apis/v1
security:
  - bearerAuth: []
paths:
  /exa/answer:
    post:
      tags:
        - https://docs.exa.ai/reference/answer
      summary: 获得针对某个问题的带引用直接答案。
      description: >-
        提一个问题，拿回一段带引用的答案。`query` 必填；`text` 会带上来源正文，`outputSchema` 可以约束结构化输出。返回
        `requestId`、成段的 `answer`、`citations[]`（含 `id`、`title`、`url`）和
        `costDollars`。实测 2.1 秒、8 条引用。按次固定计费。它介于搜索和研究之间：比 `post_exa_agent_runs`
        更快更便宜，又比自己去读 `post_exa_search` 的结果更直接。`post_perplexity_sonar` 也能回答同一类问题
        —— 当检索本身需要语义匹配时才选 Exa。
      operationId: post_exa_answer
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                query:
                  type: string
                  description: 要回答的问题。
                  example: >-
                    Which manufacturers had the top three global EV sales in
                    2025?
                text:
                  type: boolean
                  description: 包含每条引用的完整页面文本。
                type:
                  type: string
                  enum:
                    - auto
                    - fast
                    - instant
                    - deep-lite
                    - deep
                    - deep-reasoning
                  description: 作答前用于收集来源的检索模式。
                outputSchema:
                  type: object
                  description: 用于结构化答案输出的 JSON Schema。
              required:
                - query
      responses:
        '200':
          description: 答案生成成功。
          content:
            application/json:
              schema:
                type: object
                properties:
                  requestId:
                    type: string
                  answer:
                    description: 生成的答案。为字符串；当提供了 outputSchema 时为结构化对象。
                    nullable: true
                  citations:
                    type: array
                    description: 支撑该答案的来源。
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                        url:
                          type: string
                        title:
                          type: string
                        author:
                          type: string
                        publishedDate:
                          type: string
                        text:
                          type: string
                  costDollars:
                    description: 上游 Exa 的成本明细。仅供参考；客户按每次请求的固定费率计费。
                    nullable: true
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````

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