> ## 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.

> ## Agent Instructions
> - Base URLs: models `https://api.aisa.one/v1` (Gemini GenerateContent: `https://api.aisa.one/v1beta`); data APIs `https://api.aisa.one/apis/v1`. The `servers` of each operation in https://aisa.one/openapi.yaml is authoritative.
> - Auth: `Authorization: Bearer $AISA_API_KEY`. Never print, log, or commit the key.
> - MCP (preferred for agents): `https://mcp.aisa.one/mcp`, signed in with OAuth, so there is no key to paste.
> - Agent Skill: `npx skills add AIsa-team/agent-skills --skill aisa`. Fallback with the AIsa CLI: `aisa skills install aisa`.
> - Spending: docs, https://aisa.one/models, https://aisa.one/api, `/v1/models`, and MCP `search`, `list_categories`, `get_details`, `batch_quote`, and the `account` operation are free. Quote the exact calls before running them (MCP `batch_quote`, CLI `aisa quote --json`). If the quote reports `auto_execute_eligible: true`, run it unless the user set a tighter limit or asked only for a quote. Otherwise, tell the user in one message the planned calls, the quoted price, and a total USD budget for the task, then wait for approval. Direct HTTP calls follow the stricter rule at https://aisa.one/docs/get-started/cli.md#direct-http-fallback. Do not make paid calls to test availability. Full rule: https://aisa.one/llms.txt

# Exa Agent Runs submit

> 把一个研究任务交给后台的 agent。

把一个研究任务交给后台的 agent。`query` 和 `Idempotency-Key` 必填；`effort` 在深度与耗时之间取舍，`outputSchema` 约束产出结构，`dataSources` 限定检索范围，`previousRunId` 可以接着上一次继续。异步。提交后返回 HTTP 202 和一个任务信封 —— `id`、`object`、`endpoint`、`status`、`createdAt`、`completedAt`、`pricing`、`output`、`error`，此时 `output` 还是 null。轮询 [`get_exa_agent_run`](https://aisa.one/docs/zh/api-reference/search/get_exa-agent-run) 直到终态；届时 `output` 含 `text`、`structured` 和 `grounding`。一个单句问题实测远不到一分钟就完成。按次固定计费 —— `pricing.billingMode` 是 `fixed_request`，也就是说和 Firecrawl 的爬取不同，**价格不随它找到多少而增长**。当交付物本身就是一份报告时用它。想要一口气读完的答案，[`post_exa_answer`](https://aisa.one/docs/zh/api-reference/search/post_exa-answer) 约 2 秒就返回。每个不同的任务换一个新的 `Idempotency-Key`。

> [!NOTE]
>
> **第一次用？** 把任意 MCP 客户端指向 `https://mcp.aisa.one/mcp` —— Claude Code、
> Codex、Cursor、VS Code 都可以。鉴权走 OAuth：客户端打开浏览器，你点一次
> Allow，不需要粘贴任何 key。之后智能体通过几个元工具调用所有端点：
> `search`、`list_categories`、`get_details` 和 `batch_quote` 免费，`batch_use`
> 按次计费。各客户端的接入步骤见[通过 MCP 连接](https://aisa.one/docs/zh/agent-quickstart.md)；实时工具列表和
> 每次调用的价格见 [aisa.one/zh-cn/mcp](https://aisa.one/zh-cn/mcp#connect)。

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

## 请求规范

* **方法与路径:** POST /apis/v1/exa/agent/runs
* **可用状态:** enabled
* **请求 URL 模板:** `https://api.aisa.one/apis/v1/exa/agent/runs`
* **Idempotency-Key:** header; 必填
* **X-AISA-Max-Price-USD:** header; 可选
* **X-AISA-Cost-Mode:** header; 可选

[完整 OpenAPI 定义](https://aisa.one/docs/openapi/zh/exa.json)

有效请求声明（包括认证和引用的 schema）：

```json theme={null}
{
  "operationId": "post_exa_agent_runs",
  "method": "POST",
  "path": "/apis/v1/exa/agent/runs",
  "servers": [
    {
      "url": "https://api.aisa.one"
    }
  ],
  "parameters": [
    {
      "description": "Trimmed UTF-8 length must be 1 through 191 bytes.",
      "in": "header",
      "name": "Idempotency-Key",
      "required": true,
      "schema": {
        "pattern": "\\S",
        "type": "string"
      }
    },
    {
      "description": "Optional maximum customer authorization in USD, validated by the runtime price parser.",
      "in": "header",
      "name": "X-AISA-Max-Price-USD",
      "schema": {
        "type": "string"
      }
    },
    {
      "description": "Return a read-only cost quote instead of submitting a job.",
      "in": "header",
      "name": "X-AISA-Cost-Mode",
      "schema": {
        "enum": [
          "quote"
        ],
        "type": "string"
      }
    }
  ],
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "requestBody": {
    "content": {
      "application/json": {
        "example": {
          "query": "Find the official documentation for Go"
        },
        "schema": {
          "additionalProperties": false,
          "properties": {
            "effort": {
              "default": "minimal",
              "description": "Only minimal effort is supported; omitted, empty and null values normalize to minimal.",
              "enum": [
                null,
                "",
                "minimal"
              ],
              "type": [
                "string",
                "null"
              ]
            },
            "query": {
              "description": "Non-empty query after trimming whitespace.",
              "pattern": "\\S",
              "type": "string"
            },
            "systemPrompt": {
              "type": [
                "string",
                "null"
              ]
            }
          },
          "required": [
            "query"
          ],
          "type": "object"
        }
      }
    },
    "required": true
  },
  "x-aisa-status": "enabled",
  "components": {
    "securitySchemes": {
      "bearerAuth": {
        "scheme": "bearer",
        "type": "http"
      }
    }
  }
}
```

## 费用与请求规则

公开参考价格：每个完成的任务 \$0.1 USD。 账户适用价格可能不同；支持报价的接口可按实际请求获取报价。


## OpenAPI

````yaml openapi/zh/exa.json POST /apis/v1/exa/agent/runs
openapi: 3.1.0
info:
  description: ''
  title: Exa
  version: '1'
  x-aisa-capabilities:
    idempotency: Idempotency-Key
    max_price: X-AISA-Max-Price-USD
    quote:
      header: X-AISA-Cost-Mode
      value: quote
  x-aisa-catalogs:
    exa:
      description: ''
      title: Exa
      x-aisa-capabilities:
        idempotency: Idempotency-Key
        max_price: X-AISA-Max-Price-USD
        quote:
          header: X-AISA-Cost-Mode
          value: quote
      x-aisa-document:
        facts_hash: d10529a4463a002dd39ad505e0bc30212230a00b2034082221e854d90728a9b8
        generator_version: '3'
        protocol_version: '1'
        schema_version: '1'
      x-aisa-plans:
        builder: 1
        display_plan: payg
        payg: 1
        similarweb_payg: 1
        team: 1
        version: e70a0959cd1b93b84ae16dffd7a538273ddb9c1d46277b82823c37ff1b6bc0fb
  x-aisa-configured-paths:
    - /apis/v1/exa/agent/runs
    - /apis/v1/exa/answer
    - /apis/v1/exa/contents
    - /apis/v1/exa/search
  x-aisa-document:
    composer_version: '31'
    document_hash: sha256:ab46e78f199b7355eb8b0849ccc6b69f09ed9c898a6d7b83d8a86b70a43c863a
    facts_hash: d10529a4463a002dd39ad505e0bc30212230a00b2034082221e854d90728a9b8
    generator_version: '3'
    protocol_version: '1'
    response_pending: []
    schema_version: '1'
  x-aisa-plans:
    builder: 1
    display_plan: payg
    payg: 1
    similarweb_payg: 1
    team: 1
    version: e70a0959cd1b93b84ae16dffd7a538273ddb9c1d46277b82823c37ff1b6bc0fb
  x-aisa-provider: exa
servers:
  - url: https://api.aisa.one
security:
  - bearerAuth: []
paths:
  /apis/v1/exa/agent/runs:
    post:
      summary: Exa Agent Runs submit
      description: >-
        Owner-scoped local asynchronous job lifecycle. Disabling new admission
        does not disable existing job reads or cancellation. Runtime
        availability and access policy also apply.
      operationId: post_exa_agent_runs
      parameters:
        - description: Trimmed UTF-8 length must be 1 through 191 bytes.
          in: header
          name: Idempotency-Key
          required: true
          schema:
            pattern: \S
            type: string
        - description: >-
            Optional maximum customer authorization in USD, validated by the
            runtime price parser.
          in: header
          name: X-AISA-Max-Price-USD
          schema:
            type: string
        - description: Return a read-only cost quote instead of submitting a job.
          in: header
          name: X-AISA-Cost-Mode
          schema:
            enum:
              - quote
            type: string
      requestBody:
        content:
          application/json:
            example:
              query: Find the official documentation for Go
            schema:
              additionalProperties: false
              properties:
                effort:
                  default: minimal
                  description: >-
                    Only minimal effort is supported; omitted, empty and null
                    values normalize to minimal.
                  enum:
                    - null
                    - ''
                    - minimal
                  type:
                    - string
                    - 'null'
                query:
                  description: Non-empty query after trimming whitespace.
                  pattern: \S
                  type: string
                systemPrompt:
                  type:
                    - string
                    - 'null'
              required:
                - query
              type: object
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  currency:
                    type:
                      - string
                      - 'null'
                  estimate_kind:
                    type:
                      - string
                      - 'null'
                  estimated_at:
                    format: date-time
                    type:
                      - string
                      - 'null'
                  estimated_cost_micros_usd:
                    type:
                      - integer
                      - 'null'
                  max_cost_micros_usd:
                    type:
                      - integer
                      - 'null'
                  may_exceed_estimate:
                    type:
                      - boolean
                      - 'null'
                  metadata:
                    additionalProperties: {}
                    type:
                      - object
                      - 'null'
                  object:
                    type:
                      - string
                      - 'null'
                  pricing_version:
                    type:
                      - string
                      - 'null'
                required:
                  - currency
                  - estimate_kind
                  - estimated_at
                  - estimated_cost_micros_usd
                  - may_exceed_estimate
                  - object
                type: object
          description: >-
            Read-only cost quote when X-AISA-Cost-Mode is quote; no job is
            created.
        '202':
          content:
            application/json:
              schema:
                properties:
                  completedAt:
                    format: date-time
                    type:
                      - string
                      - 'null'
                  createdAt:
                    format: date-time
                    type:
                      - string
                      - 'null'
                  endpoint:
                    type:
                      - string
                      - 'null'
                  error:
                    properties:
                      code:
                        type:
                          - string
                          - 'null'
                      message:
                        type:
                          - string
                          - 'null'
                    type:
                      - object
                      - 'null'
                  id:
                    type:
                      - string
                      - 'null'
                  object:
                    const: integration_async_job
                    type: string
                  output: {}
                  outputExpired:
                    type:
                      - boolean
                      - 'null'
                  pricing:
                    properties:
                      authorizedMicrosUSD:
                        type:
                          - integer
                          - 'null'
                      billingMode:
                        type:
                          - string
                          - 'null'
                      currency:
                        type:
                          - string
                          - 'null'
                      finalMicrosUSD:
                        type:
                          - integer
                          - 'null'
                    type:
                      - object
                      - 'null'
                  status:
                    enum:
                      - queued
                      - running
                      - completed
                      - failed
                      - cancelled
                    type: string
                required:
                  - completedAt
                  - createdAt
                  - endpoint
                  - error
                  - id
                  - object
                  - output
                  - pricing
                  - status
                type: object
          description: Success
components:
  securitySchemes:
    bearerAuth:
      scheme: bearer
      type: http

````

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