# Search Notes

Search Xiaohongshu notes by keyword, paging through the results. For one note's body use xhs_note_detail_v1.

ID: task:xhs_search_notes_v1 · Region: global · Status: available

catalog_version: 938eb1e3bdb6476050bf2983e6e8db1edcf9f0942d16c7ebd2029dcd28295afe
updated_at: 2026-10-21T10:40:52.196893+00:00

Xiaohongshu

Dataset releases define historical periods; live reads describe request-time data and do not guarantee completeness.

Docs: https://docs.kleardata.ai/capabilities/task%3Axhs_search_notes_v1

## GET /v1/collections/tasks/xhs_search_notes_v1

legacy · available · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.



Existing pricing applies; metadata reads do not charge Credits.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "properties": {
    "task_code": {
      "const": "xhs_search_notes_v1"
    },
    "task_query": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional task attribution: when provided, write one concise, self-contained task_query in the user's language and reuse that exact value in every call for the task, including discovery, search, approval retry, results, export, and status checks. For MCP calls, when omitted, Asklear records a generic non-user-specific attribution so compatible clients can still call the tool. REST calls may omit it and remain unattributed. It is a task description, not a task identifier. Do not include hidden reasoning, credentials, or direct personal identifiers such as phone numbers, email addresses, identity numbers, or street addresses.",
      "maxLength": 300
    }
  },
  "required": [
    "task_code"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "task_code": "xhs_search_notes_v1"
}
```

### Synthetic response / 合成响应

```json
{
  "examples": [
    {
      "filters": {},
      "page": 1,
      "query": "示例关键词",
      "search_mode": "text",
      "source": "xhs"
    }
  ],
  "input_schema": {
    "$defs": {
      "SearchImageInput": {
        "additionalProperties": false,
        "description": "Exactly one public image reference accepted by the Search API.",
        "properties": {
          "asset_id": {
            "anyOf": [
              {
                "maxLength": 128,
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": null
          },
          "base64": {
            "anyOf": [
              {
                "maxLength": 8388608,
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": null
          },
          "url": {
            "anyOf": [
              {
                "maxLength": 2048,
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": null
          }
        },
        "type": "object"
      }
    },
    "additionalProperties": false,
    "description": "Provider-neutral input persisted for one asynchronous search job.",
    "properties": {
      "filters": {
        "additionalProperties": true,
        "type": "object"
      },
      "image": {
        "anyOf": [
          {
            "$ref": "#/$defs/SearchImageInput"
          },
          {
            "type": "null"
          }
        ],
        "default": null
      },
      "page": {
        "default": 1,
        "maximum": 50,
        "minimum": 1,
        "type": "integer"
      },
      "page_size": {
        "anyOf": [
          {
            "maximum": 50,
            "minimum": 1,
            "type": "integer"
          },
          {
            "type": "null"
          }
        ],
        "default": null
      },
      "page_token": {
        "default": "",
        "maxLength": 8192,
        "type": "string"
      },
      "query": {
        "anyOf": [
          {
            "maxLength": 200,
            "type": "string"
          },
          {
            "type": "null"
          }
        ],
        "default": null
      },
      "search_mode": {
        "enum": [
          "text",
          "image",
          "hybrid"
        ],
        "type": "string"
      },
      "source": {
        "maxLength": 64,
        "minLength": 2,
        "type": "string"
      }
    },
    "required": [
      "source",
      "search_mode"
    ],
    "type": "object"
  }
}
```

- input_schema (object): No field description available
- examples (array<object>): No field description available
## describe_collection_task

legacy · available · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.



Existing pricing applies; metadata reads do not charge Credits.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "properties": {
    "task_code": {
      "const": "xhs_search_notes_v1"
    },
    "task_query": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional task attribution: when provided, write one concise, self-contained task_query in the user's language and reuse that exact value in every call for the task, including discovery, search, approval retry, results, export, and status checks. For MCP calls, when omitted, Asklear records a generic non-user-specific attribution so compatible clients can still call the tool. REST calls may omit it and remain unattributed. It is a task description, not a task identifier. Do not include hidden reasoning, credentials, or direct personal identifiers such as phone numbers, email addresses, identity numbers, or street addresses.",
      "maxLength": 300
    }
  },
  "required": [
    "task_code"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "task_code": "xhs_search_notes_v1"
}
```

### Synthetic response / 合成响应

```json
{
  "examples": [
    {
      "filters": {},
      "page": 1,
      "query": "示例关键词",
      "search_mode": "text",
      "source": "xhs"
    }
  ],
  "input_schema": {
    "$defs": {
      "SearchImageInput": {
        "additionalProperties": false,
        "description": "Exactly one public image reference accepted by the Search API.",
        "properties": {
          "asset_id": {
            "anyOf": [
              {
                "maxLength": 128,
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": null
          },
          "base64": {
            "anyOf": [
              {
                "maxLength": 8388608,
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": null
          },
          "url": {
            "anyOf": [
              {
                "maxLength": 2048,
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": null
          }
        },
        "type": "object"
      }
    },
    "additionalProperties": false,
    "description": "Provider-neutral input persisted for one asynchronous search job.",
    "properties": {
      "filters": {
        "additionalProperties": true,
        "type": "object"
      },
      "image": {
        "anyOf": [
          {
            "$ref": "#/$defs/SearchImageInput"
          },
          {
            "type": "null"
          }
        ],
        "default": null
      },
      "page": {
        "default": 1,
        "maximum": 50,
        "minimum": 1,
        "type": "integer"
      },
      "page_size": {
        "anyOf": [
          {
            "maximum": 50,
            "minimum": 1,
            "type": "integer"
          },
          {
            "type": "null"
          }
        ],
        "default": null
      },
      "page_token": {
        "default": "",
        "maxLength": 8192,
        "type": "string"
      },
      "query": {
        "anyOf": [
          {
            "maxLength": 200,
            "type": "string"
          },
          {
            "type": "null"
          }
        ],
        "default": null
      },
      "search_mode": {
        "enum": [
          "text",
          "image",
          "hybrid"
        ],
        "type": "string"
      },
      "source": {
        "maxLength": 64,
        "minLength": 2,
        "type": "string"
      }
    },
    "required": [
      "source",
      "search_mode"
    ],
    "type": "object"
  }
}
```

- input_schema (object): No field description available
- examples (array<object>): No field description available
## asklear collection describe

legacy · unavailable · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.



Existing pricing applies; metadata reads do not charge Credits.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "properties": {
    "task_code": {
      "const": "xhs_search_notes_v1"
    },
    "task_query": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional task attribution: when provided, write one concise, self-contained task_query in the user's language and reuse that exact value in every call for the task, including discovery, search, approval retry, results, export, and status checks. For MCP calls, when omitted, Asklear records a generic non-user-specific attribution so compatible clients can still call the tool. REST calls may omit it and remain unattributed. It is a task description, not a task identifier. Do not include hidden reasoning, credentials, or direct personal identifiers such as phone numbers, email addresses, identity numbers, or street addresses.",
      "maxLength": 300
    }
  },
  "required": [
    "task_code"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "task_code": "xhs_search_notes_v1"
}
```

### Synthetic response / 合成响应

```json
{
  "examples": [
    {
      "filters": {},
      "page": 1,
      "query": "示例关键词",
      "search_mode": "text",
      "source": "xhs"
    }
  ],
  "input_schema": {
    "$defs": {
      "SearchImageInput": {
        "additionalProperties": false,
        "description": "Exactly one public image reference accepted by the Search API.",
        "properties": {
          "asset_id": {
            "anyOf": [
              {
                "maxLength": 128,
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": null
          },
          "base64": {
            "anyOf": [
              {
                "maxLength": 8388608,
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": null
          },
          "url": {
            "anyOf": [
              {
                "maxLength": 2048,
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": null
          }
        },
        "type": "object"
      }
    },
    "additionalProperties": false,
    "description": "Provider-neutral input persisted for one asynchronous search job.",
    "properties": {
      "filters": {
        "additionalProperties": true,
        "type": "object"
      },
      "image": {
        "anyOf": [
          {
            "$ref": "#/$defs/SearchImageInput"
          },
          {
            "type": "null"
          }
        ],
        "default": null
      },
      "page": {
        "default": 1,
        "maximum": 50,
        "minimum": 1,
        "type": "integer"
      },
      "page_size": {
        "anyOf": [
          {
            "maximum": 50,
            "minimum": 1,
            "type": "integer"
          },
          {
            "type": "null"
          }
        ],
        "default": null
      },
      "page_token": {
        "default": "",
        "maxLength": 8192,
        "type": "string"
      },
      "query": {
        "anyOf": [
          {
            "maxLength": 200,
            "type": "string"
          },
          {
            "type": "null"
          }
        ],
        "default": null
      },
      "search_mode": {
        "enum": [
          "text",
          "image",
          "hybrid"
        ],
        "type": "string"
      },
      "source": {
        "maxLength": 64,
        "minLength": 2,
        "type": "string"
      }
    },
    "required": [
      "source",
      "search_mode"
    ],
    "type": "object"
  }
}
```

- input_schema (object): No field description available
- examples (array<object>): No field description available
## POST /v1/collections/estimate

legacy · available · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.

按页翻页,不是游标续取;页码过大时上游会返回空页而不是报错。
只返回笔记摘要,正文、图片与完整互动数需要 xhs_note_detail_v1。

8 Credits per successful task; estimate before starting.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "$defs": {
    "Schema1": {
      "additionalProperties": false,
      "description": "Exactly one public image reference accepted by the Search API.",
      "properties": {
        "asset_id": {
          "anyOf": [
            {
              "maxLength": 128,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "base64": {
          "anyOf": [
            {
              "maxLength": 8388608,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "url": {
          "anyOf": [
            {
              "maxLength": 2048,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        }
      },
      "type": "object"
    }
  },
  "additionalProperties": false,
  "description": "Outer transport contract; each registered task validates its own input.",
  "properties": {
    "input": {
      "additionalProperties": false,
      "description": "Provider-neutral input persisted for one asynchronous search job.",
      "properties": {
        "filters": {
          "additionalProperties": true,
          "type": "object"
        },
        "image": {
          "anyOf": [
            {
              "$ref": "#/$defs/Schema1"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "page": {
          "default": 1,
          "maximum": 50,
          "minimum": 1,
          "type": "integer"
        },
        "page_size": {
          "anyOf": [
            {
              "maximum": 50,
              "minimum": 1,
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "page_token": {
          "default": "",
          "maxLength": 8192,
          "type": "string"
        },
        "query": {
          "anyOf": [
            {
              "maxLength": 200,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "search_mode": {
          "enum": [
            "text",
            "image",
            "hybrid"
          ],
          "type": "string"
        },
        "source": {
          "maxLength": 64,
          "minLength": 2,
          "type": "string"
        }
      },
      "required": [
        "source",
        "search_mode"
      ],
      "type": "object"
    },
    "task_code": {
      "const": "xhs_search_notes_v1"
    }
  },
  "required": [
    "task_code",
    "input"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "input": {
    "filters": {},
    "page": 1,
    "query": "示例关键词",
    "search_mode": "text",
    "source": "xhs"
  },
  "task_code": "xhs_search_notes_v1"
}
```

### Synthetic response / 合成响应

```json
{
  "quote_token": "quote-token-from-estimate",
  "upper_bound_credits": 8
}
```

- quote_token (string): No field description available
- upper_bound_credits (integer): No field description available
## estimate_collection

legacy · available · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.

按页翻页,不是游标续取;页码过大时上游会返回空页而不是报错。
只返回笔记摘要,正文、图片与完整互动数需要 xhs_note_detail_v1。

8 Credits per successful task; estimate before starting.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "$defs": {
    "Schema1": {
      "additionalProperties": false,
      "description": "Exactly one public image reference accepted by the Search API.",
      "properties": {
        "asset_id": {
          "anyOf": [
            {
              "maxLength": 128,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "base64": {
          "anyOf": [
            {
              "maxLength": 8388608,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "url": {
          "anyOf": [
            {
              "maxLength": 2048,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        }
      },
      "type": "object"
    }
  },
  "additionalProperties": false,
  "description": "Outer transport contract; each registered task validates its own input.",
  "properties": {
    "input": {
      "additionalProperties": false,
      "description": "Provider-neutral input persisted for one asynchronous search job.",
      "properties": {
        "filters": {
          "additionalProperties": true,
          "type": "object"
        },
        "image": {
          "anyOf": [
            {
              "$ref": "#/$defs/Schema1"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "page": {
          "default": 1,
          "maximum": 50,
          "minimum": 1,
          "type": "integer"
        },
        "page_size": {
          "anyOf": [
            {
              "maximum": 50,
              "minimum": 1,
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "page_token": {
          "default": "",
          "maxLength": 8192,
          "type": "string"
        },
        "query": {
          "anyOf": [
            {
              "maxLength": 200,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "search_mode": {
          "enum": [
            "text",
            "image",
            "hybrid"
          ],
          "type": "string"
        },
        "source": {
          "maxLength": 64,
          "minLength": 2,
          "type": "string"
        }
      },
      "required": [
        "source",
        "search_mode"
      ],
      "type": "object"
    },
    "task_code": {
      "const": "xhs_search_notes_v1"
    },
    "task_query": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional task attribution: when provided, write one concise, self-contained task_query in the user's language and reuse that exact value in every call for the task, including discovery, search, approval retry, results, export, and status checks. For MCP calls, when omitted, Asklear records a generic non-user-specific attribution so compatible clients can still call the tool. REST calls may omit it and remain unattributed. It is a task description, not a task identifier. Do not include hidden reasoning, credentials, or direct personal identifiers such as phone numbers, email addresses, identity numbers, or street addresses.",
      "maxLength": 300
    }
  },
  "required": [
    "task_code",
    "input"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "input": {
    "filters": {},
    "page": 1,
    "query": "示例关键词",
    "search_mode": "text",
    "source": "xhs"
  },
  "task_code": "xhs_search_notes_v1"
}
```

### Synthetic response / 合成响应

```json
{
  "quote_token": "quote-token-from-estimate",
  "upper_bound_credits": 8
}
```

- quote_token (string): No field description available
- upper_bound_credits (integer): No field description available
## asklear collection estimate

legacy · unavailable · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.

按页翻页,不是游标续取;页码过大时上游会返回空页而不是报错。
只返回笔记摘要,正文、图片与完整互动数需要 xhs_note_detail_v1。

8 Credits per successful task; estimate before starting.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "$defs": {
    "Schema1": {
      "additionalProperties": false,
      "description": "Exactly one public image reference accepted by the Search API.",
      "properties": {
        "asset_id": {
          "anyOf": [
            {
              "maxLength": 128,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "base64": {
          "anyOf": [
            {
              "maxLength": 8388608,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "url": {
          "anyOf": [
            {
              "maxLength": 2048,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        }
      },
      "type": "object"
    }
  },
  "additionalProperties": false,
  "description": "Outer transport contract; each registered task validates its own input.",
  "properties": {
    "input": {
      "additionalProperties": false,
      "description": "Provider-neutral input persisted for one asynchronous search job.",
      "properties": {
        "filters": {
          "additionalProperties": true,
          "type": "object"
        },
        "image": {
          "anyOf": [
            {
              "$ref": "#/$defs/Schema1"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "page": {
          "default": 1,
          "maximum": 50,
          "minimum": 1,
          "type": "integer"
        },
        "page_size": {
          "anyOf": [
            {
              "maximum": 50,
              "minimum": 1,
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "page_token": {
          "default": "",
          "maxLength": 8192,
          "type": "string"
        },
        "query": {
          "anyOf": [
            {
              "maxLength": 200,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "search_mode": {
          "enum": [
            "text",
            "image",
            "hybrid"
          ],
          "type": "string"
        },
        "source": {
          "maxLength": 64,
          "minLength": 2,
          "type": "string"
        }
      },
      "required": [
        "source",
        "search_mode"
      ],
      "type": "object"
    },
    "task_code": {
      "const": "xhs_search_notes_v1"
    },
    "task_query": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional task attribution: when provided, write one concise, self-contained task_query in the user's language and reuse that exact value in every call for the task, including discovery, search, approval retry, results, export, and status checks. For MCP calls, when omitted, Asklear records a generic non-user-specific attribution so compatible clients can still call the tool. REST calls may omit it and remain unattributed. It is a task description, not a task identifier. Do not include hidden reasoning, credentials, or direct personal identifiers such as phone numbers, email addresses, identity numbers, or street addresses.",
      "maxLength": 300
    }
  },
  "required": [
    "task_code",
    "input"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "input": {
    "filters": {},
    "page": 1,
    "query": "示例关键词",
    "search_mode": "text",
    "source": "xhs"
  },
  "task_code": "xhs_search_notes_v1"
}
```

### Synthetic response / 合成响应

```json
{
  "quote_token": "quote-token-from-estimate",
  "upper_bound_credits": 8
}
```

- quote_token (string): No field description available
- upper_bound_credits (integer): No field description available
## POST /v1/collections/jobs

legacy · available · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.

按页翻页,不是游标续取;页码过大时上游会返回空页而不是报错。
只返回笔记摘要,正文、图片与完整互动数需要 xhs_note_detail_v1。

8 Credits per successful task; estimate before starting.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "$defs": {
    "Schema1": {
      "additionalProperties": false,
      "description": "Exactly one public image reference accepted by the Search API.",
      "properties": {
        "asset_id": {
          "anyOf": [
            {
              "maxLength": 128,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "base64": {
          "anyOf": [
            {
              "maxLength": 8388608,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "url": {
          "anyOf": [
            {
              "maxLength": 2048,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        }
      },
      "type": "object"
    }
  },
  "additionalProperties": false,
  "properties": {
    "idempotency_key": {
      "maxLength": 128,
      "minLength": 1,
      "type": "string"
    },
    "input": {
      "additionalProperties": false,
      "description": "Provider-neutral input persisted for one asynchronous search job.",
      "properties": {
        "filters": {
          "additionalProperties": true,
          "type": "object"
        },
        "image": {
          "anyOf": [
            {
              "$ref": "#/$defs/Schema1"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "page": {
          "default": 1,
          "maximum": 50,
          "minimum": 1,
          "type": "integer"
        },
        "page_size": {
          "anyOf": [
            {
              "maximum": 50,
              "minimum": 1,
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "page_token": {
          "default": "",
          "maxLength": 8192,
          "type": "string"
        },
        "query": {
          "anyOf": [
            {
              "maxLength": 200,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "search_mode": {
          "enum": [
            "text",
            "image",
            "hybrid"
          ],
          "type": "string"
        },
        "source": {
          "maxLength": 64,
          "minLength": 2,
          "type": "string"
        }
      },
      "required": [
        "source",
        "search_mode"
      ],
      "type": "object"
    },
    "max_credits": {
      "anyOf": [
        {
          "exclusiveMinimum": 0,
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null
    },
    "quote_token": {
      "maxLength": 4096,
      "minLength": 16,
      "type": "string"
    },
    "task_code": {
      "const": "xhs_search_notes_v1"
    }
  },
  "required": [
    "task_code",
    "input",
    "quote_token",
    "idempotency_key"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "idempotency_key": "directory-example",
  "input": {
    "filters": {},
    "page": 1,
    "query": "示例关键词",
    "search_mode": "text",
    "source": "xhs"
  },
  "quote_token": "quote-token-from-estimate",
  "task_code": "xhs_search_notes_v1"
}
```

### Synthetic response / 合成响应

```json
{
  "job_id": "collection-example",
  "status": "queued"
}
```

- job_id (string): No field description available
- status (string): No field description available

Follow up: GET /v1/collections/jobs/{job_id}
Read job status and its saved public result.

## start_collection

legacy · available · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.

按页翻页,不是游标续取;页码过大时上游会返回空页而不是报错。
只返回笔记摘要,正文、图片与完整互动数需要 xhs_note_detail_v1。

8 Credits per successful task; estimate before starting.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "$defs": {
    "Schema1": {
      "additionalProperties": false,
      "description": "Exactly one public image reference accepted by the Search API.",
      "properties": {
        "asset_id": {
          "anyOf": [
            {
              "maxLength": 128,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "base64": {
          "anyOf": [
            {
              "maxLength": 8388608,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "url": {
          "anyOf": [
            {
              "maxLength": 2048,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        }
      },
      "type": "object"
    }
  },
  "additionalProperties": false,
  "properties": {
    "idempotency_key": {
      "maxLength": 128,
      "minLength": 1,
      "type": "string"
    },
    "input": {
      "additionalProperties": false,
      "description": "Provider-neutral input persisted for one asynchronous search job.",
      "properties": {
        "filters": {
          "additionalProperties": true,
          "type": "object"
        },
        "image": {
          "anyOf": [
            {
              "$ref": "#/$defs/Schema1"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "page": {
          "default": 1,
          "maximum": 50,
          "minimum": 1,
          "type": "integer"
        },
        "page_size": {
          "anyOf": [
            {
              "maximum": 50,
              "minimum": 1,
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "page_token": {
          "default": "",
          "maxLength": 8192,
          "type": "string"
        },
        "query": {
          "anyOf": [
            {
              "maxLength": 200,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "search_mode": {
          "enum": [
            "text",
            "image",
            "hybrid"
          ],
          "type": "string"
        },
        "source": {
          "maxLength": 64,
          "minLength": 2,
          "type": "string"
        }
      },
      "required": [
        "source",
        "search_mode"
      ],
      "type": "object"
    },
    "max_credits": {
      "anyOf": [
        {
          "exclusiveMinimum": 0,
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null
    },
    "quote_token": {
      "maxLength": 4096,
      "minLength": 16,
      "type": "string"
    },
    "task_code": {
      "const": "xhs_search_notes_v1"
    },
    "task_query": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional task attribution: when provided, write one concise, self-contained task_query in the user's language and reuse that exact value in every call for the task, including discovery, search, approval retry, results, export, and status checks. For MCP calls, when omitted, Asklear records a generic non-user-specific attribution so compatible clients can still call the tool. REST calls may omit it and remain unattributed. It is a task description, not a task identifier. Do not include hidden reasoning, credentials, or direct personal identifiers such as phone numbers, email addresses, identity numbers, or street addresses.",
      "maxLength": 300
    }
  },
  "required": [
    "task_code",
    "input",
    "quote_token",
    "idempotency_key"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "idempotency_key": "directory-example",
  "input": {
    "filters": {},
    "page": 1,
    "query": "示例关键词",
    "search_mode": "text",
    "source": "xhs"
  },
  "quote_token": "quote-token-from-estimate",
  "task_code": "xhs_search_notes_v1"
}
```

### Synthetic response / 合成响应

```json
{
  "job_id": "collection-example",
  "status": "queued"
}
```

- job_id (string): No field description available
- status (string): No field description available

Follow up: GET /v1/collections/jobs/{job_id}
Read job status and its saved public result.

## asklear collection start

legacy · unavailable · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.

按页翻页,不是游标续取;页码过大时上游会返回空页而不是报错。
只返回笔记摘要,正文、图片与完整互动数需要 xhs_note_detail_v1。

8 Credits per successful task; estimate before starting.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "$defs": {
    "Schema1": {
      "additionalProperties": false,
      "description": "Exactly one public image reference accepted by the Search API.",
      "properties": {
        "asset_id": {
          "anyOf": [
            {
              "maxLength": 128,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "base64": {
          "anyOf": [
            {
              "maxLength": 8388608,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "url": {
          "anyOf": [
            {
              "maxLength": 2048,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        }
      },
      "type": "object"
    }
  },
  "additionalProperties": false,
  "properties": {
    "idempotency_key": {
      "maxLength": 128,
      "minLength": 1,
      "type": "string"
    },
    "input": {
      "additionalProperties": false,
      "description": "Provider-neutral input persisted for one asynchronous search job.",
      "properties": {
        "filters": {
          "additionalProperties": true,
          "type": "object"
        },
        "image": {
          "anyOf": [
            {
              "$ref": "#/$defs/Schema1"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "page": {
          "default": 1,
          "maximum": 50,
          "minimum": 1,
          "type": "integer"
        },
        "page_size": {
          "anyOf": [
            {
              "maximum": 50,
              "minimum": 1,
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "page_token": {
          "default": "",
          "maxLength": 8192,
          "type": "string"
        },
        "query": {
          "anyOf": [
            {
              "maxLength": 200,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "search_mode": {
          "enum": [
            "text",
            "image",
            "hybrid"
          ],
          "type": "string"
        },
        "source": {
          "maxLength": 64,
          "minLength": 2,
          "type": "string"
        }
      },
      "required": [
        "source",
        "search_mode"
      ],
      "type": "object"
    },
    "max_credits": {
      "anyOf": [
        {
          "exclusiveMinimum": 0,
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null
    },
    "quote_token": {
      "maxLength": 4096,
      "minLength": 16,
      "type": "string"
    },
    "task_code": {
      "const": "xhs_search_notes_v1"
    },
    "task_query": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional task attribution: when provided, write one concise, self-contained task_query in the user's language and reuse that exact value in every call for the task, including discovery, search, approval retry, results, export, and status checks. For MCP calls, when omitted, Asklear records a generic non-user-specific attribution so compatible clients can still call the tool. REST calls may omit it and remain unattributed. It is a task description, not a task identifier. Do not include hidden reasoning, credentials, or direct personal identifiers such as phone numbers, email addresses, identity numbers, or street addresses.",
      "maxLength": 300
    }
  },
  "required": [
    "task_code",
    "input",
    "quote_token",
    "idempotency_key"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "idempotency_key": "directory-example",
  "input": {
    "filters": {},
    "page": 1,
    "query": "示例关键词",
    "search_mode": "text",
    "source": "xhs"
  },
  "quote_token": "quote-token-from-estimate",
  "task_code": "xhs_search_notes_v1"
}
```

### Synthetic response / 合成响应

```json
{
  "job_id": "collection-example",
  "status": "queued"
}
```

- job_id (string): No field description available
- status (string): No field description available

Follow up: GET /v1/collections/jobs/{job_id}
Read job status and its saved public result.

## GET /v1/collections/jobs/{job_id}

legacy · available · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.

按页翻页,不是游标续取;页码过大时上游会返回空页而不是报错。
只返回笔记摘要,正文、图片与完整互动数需要 xhs_note_detail_v1。

Existing pricing applies; metadata reads do not charge Credits.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "properties": {
    "job_id": {
      "type": "string"
    },
    "task_query": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional task attribution: when provided, write one concise, self-contained task_query in the user's language and reuse that exact value in every call for the task, including discovery, search, approval retry, results, export, and status checks. For MCP calls, when omitted, Asklear records a generic non-user-specific attribution so compatible clients can still call the tool. REST calls may omit it and remain unattributed. It is a task description, not a task identifier. Do not include hidden reasoning, credentials, or direct personal identifiers such as phone numbers, email addresses, identity numbers, or street addresses.",
      "maxLength": 300
    }
  },
  "required": [
    "job_id"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "job_id": "collection-example"
}
```

### Response schema / 响应契约

```json
{
  "$defs": {
    "Schema1": {
      "additionalProperties": false,
      "description": "The limited metadata safe to store and expose with a collection result.",
      "properties": {
        "api_name": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[\\x21-\\x7e]+$",
          "type": "string"
        },
        "credits_charged": {
          "maximum": 1000000,
          "minimum": 0,
          "type": "integer"
        },
        "latency_ms": {
          "maximum": 120000,
          "minimum": 0,
          "type": "integer"
        },
        "request_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[\\x21-\\x7e]+$",
          "type": "string"
        }
      },
      "required": [
        "request_id",
        "api_name",
        "latency_ms",
        "credits_charged"
      ],
      "type": "object"
    }
  },
  "additionalProperties": true,
  "properties": {
    "result": {
      "additionalProperties": false,
      "properties": {
        "data": {
          "additionalProperties": true,
          "type": "object"
        },
        "meta": {
          "$ref": "#/$defs/Schema1"
        }
      },
      "required": [
        "data",
        "meta"
      ],
      "type": "object"
    }
  },
  "type": "object"
}
```

### Synthetic response / 合成响应

```json
{
  "result": {
    "data": {},
    "meta": {
      "api_name": "https://www.linkedin.com/in/example",
      "credits_charged": 0,
      "latency_ms": 0,
      "request_id": "https://www.linkedin.com/in/example"
    }
  },
  "status": "succeeded"
}
```

- result.meta.request_id (string): Asklear request identifier for tracing.
- result.meta.api_name (string): Executed collection operation name.
- result.meta.latency_ms (integer): Collection execution latency in milliseconds.
- result.meta.credits_charged (integer): Asklear user-side Credits settled for this task after completion.
- result.data.entity (string): Response entity type.
- result.data.keyword (string): The submitted search keyword.
- result.data.page (integer): Current result page.
- result.data.max_pages (integer): Next-page hint; request the next page while items continue to be returned.
- result.data.item_count (integer): Number of items in this response page.
- result.data.items (array<object>): Search result notes for this page.
- result.data.items[].note_id (string): Note identifier.
- result.data.items[].title (string): Note title.
- result.data.items[].description (string): Note description or excerpt.
- result.data.items[].note_type (string): Note type.
- result.data.items[].publish_time (integer|null): Publish timestamp when supplied.
- result.data.items[].liked_count (integer): Like count.
- result.data.items[].collected_count (integer): Collection count.
- result.data.items[].comments_count (integer): Comment count.
- result.data.items[].images (array<object>): Images attached to the note.
- result.data.items[].images[].file_id (string): Image file identifier.
- result.data.items[].images[].url (string): Image URL.
- result.data.items[].images[].large_url (string): Large image URL, when supplied.
- result.data.items[].images[].width (integer): Image width in pixels.
- result.data.items[].images[].height (integer): Image height in pixels.
- result.data.items[].author (object): Note author summary.
- result.data.items[].author.user_id (string): Author user identifier.
- result.data.items[].author.red_id (string): Author platform identifier.
- result.data.items[].author.nickname (string): Author nickname.
- result.data.items[].author.avatar (string): Author avatar URL.
- result.data.items[].author.verified (boolean): Whether the author is verified.
- result.data.items[].author.verify_type (integer): Verification type code.
## get_collection_job

legacy · available · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.

按页翻页,不是游标续取;页码过大时上游会返回空页而不是报错。
只返回笔记摘要,正文、图片与完整互动数需要 xhs_note_detail_v1。

Existing pricing applies; metadata reads do not charge Credits.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "properties": {
    "job_id": {
      "type": "string"
    },
    "task_query": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional task attribution: when provided, write one concise, self-contained task_query in the user's language and reuse that exact value in every call for the task, including discovery, search, approval retry, results, export, and status checks. For MCP calls, when omitted, Asklear records a generic non-user-specific attribution so compatible clients can still call the tool. REST calls may omit it and remain unattributed. It is a task description, not a task identifier. Do not include hidden reasoning, credentials, or direct personal identifiers such as phone numbers, email addresses, identity numbers, or street addresses.",
      "maxLength": 300
    }
  },
  "required": [
    "job_id"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "job_id": "collection-example"
}
```

### Response schema / 响应契约

```json
{
  "$defs": {
    "Schema1": {
      "additionalProperties": false,
      "description": "The limited metadata safe to store and expose with a collection result.",
      "properties": {
        "api_name": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[\\x21-\\x7e]+$",
          "type": "string"
        },
        "credits_charged": {
          "maximum": 1000000,
          "minimum": 0,
          "type": "integer"
        },
        "latency_ms": {
          "maximum": 120000,
          "minimum": 0,
          "type": "integer"
        },
        "request_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[\\x21-\\x7e]+$",
          "type": "string"
        }
      },
      "required": [
        "request_id",
        "api_name",
        "latency_ms",
        "credits_charged"
      ],
      "type": "object"
    }
  },
  "additionalProperties": true,
  "properties": {
    "result": {
      "additionalProperties": false,
      "properties": {
        "data": {
          "additionalProperties": true,
          "type": "object"
        },
        "meta": {
          "$ref": "#/$defs/Schema1"
        }
      },
      "required": [
        "data",
        "meta"
      ],
      "type": "object"
    }
  },
  "type": "object"
}
```

### Synthetic response / 合成响应

```json
{
  "result": {
    "data": {},
    "meta": {
      "api_name": "https://www.linkedin.com/in/example",
      "credits_charged": 0,
      "latency_ms": 0,
      "request_id": "https://www.linkedin.com/in/example"
    }
  },
  "status": "succeeded"
}
```

- result.meta.request_id (string): Asklear request identifier for tracing.
- result.meta.api_name (string): Executed collection operation name.
- result.meta.latency_ms (integer): Collection execution latency in milliseconds.
- result.meta.credits_charged (integer): Asklear user-side Credits settled for this task after completion.
- result.data.entity (string): Response entity type.
- result.data.keyword (string): The submitted search keyword.
- result.data.page (integer): Current result page.
- result.data.max_pages (integer): Next-page hint; request the next page while items continue to be returned.
- result.data.item_count (integer): Number of items in this response page.
- result.data.items (array<object>): Search result notes for this page.
- result.data.items[].note_id (string): Note identifier.
- result.data.items[].title (string): Note title.
- result.data.items[].description (string): Note description or excerpt.
- result.data.items[].note_type (string): Note type.
- result.data.items[].publish_time (integer|null): Publish timestamp when supplied.
- result.data.items[].liked_count (integer): Like count.
- result.data.items[].collected_count (integer): Collection count.
- result.data.items[].comments_count (integer): Comment count.
- result.data.items[].images (array<object>): Images attached to the note.
- result.data.items[].images[].file_id (string): Image file identifier.
- result.data.items[].images[].url (string): Image URL.
- result.data.items[].images[].large_url (string): Large image URL, when supplied.
- result.data.items[].images[].width (integer): Image width in pixels.
- result.data.items[].images[].height (integer): Image height in pixels.
- result.data.items[].author (object): Note author summary.
- result.data.items[].author.user_id (string): Author user identifier.
- result.data.items[].author.red_id (string): Author platform identifier.
- result.data.items[].author.nickname (string): Author nickname.
- result.data.items[].author.avatar (string): Author avatar URL.
- result.data.items[].author.verified (boolean): Whether the author is verified.
- result.data.items[].author.verify_type (integer): Verification type code.
## asklear collection get-job

legacy · unavailable · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.

按页翻页,不是游标续取;页码过大时上游会返回空页而不是报错。
只返回笔记摘要,正文、图片与完整互动数需要 xhs_note_detail_v1。

Existing pricing applies; metadata reads do not charge Credits.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "properties": {
    "job_id": {
      "type": "string"
    },
    "task_query": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional task attribution: when provided, write one concise, self-contained task_query in the user's language and reuse that exact value in every call for the task, including discovery, search, approval retry, results, export, and status checks. For MCP calls, when omitted, Asklear records a generic non-user-specific attribution so compatible clients can still call the tool. REST calls may omit it and remain unattributed. It is a task description, not a task identifier. Do not include hidden reasoning, credentials, or direct personal identifiers such as phone numbers, email addresses, identity numbers, or street addresses.",
      "maxLength": 300
    }
  },
  "required": [
    "job_id"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "job_id": "collection-example"
}
```

### Response schema / 响应契约

```json
{
  "$defs": {
    "Schema1": {
      "additionalProperties": false,
      "description": "The limited metadata safe to store and expose with a collection result.",
      "properties": {
        "api_name": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[\\x21-\\x7e]+$",
          "type": "string"
        },
        "credits_charged": {
          "maximum": 1000000,
          "minimum": 0,
          "type": "integer"
        },
        "latency_ms": {
          "maximum": 120000,
          "minimum": 0,
          "type": "integer"
        },
        "request_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[\\x21-\\x7e]+$",
          "type": "string"
        }
      },
      "required": [
        "request_id",
        "api_name",
        "latency_ms",
        "credits_charged"
      ],
      "type": "object"
    }
  },
  "additionalProperties": true,
  "properties": {
    "result": {
      "additionalProperties": false,
      "properties": {
        "data": {
          "additionalProperties": true,
          "type": "object"
        },
        "meta": {
          "$ref": "#/$defs/Schema1"
        }
      },
      "required": [
        "data",
        "meta"
      ],
      "type": "object"
    }
  },
  "type": "object"
}
```

### Synthetic response / 合成响应

```json
{
  "result": {
    "data": {},
    "meta": {
      "api_name": "https://www.linkedin.com/in/example",
      "credits_charged": 0,
      "latency_ms": 0,
      "request_id": "https://www.linkedin.com/in/example"
    }
  },
  "status": "succeeded"
}
```

- result.meta.request_id (string): Asklear request identifier for tracing.
- result.meta.api_name (string): Executed collection operation name.
- result.meta.latency_ms (integer): Collection execution latency in milliseconds.
- result.meta.credits_charged (integer): Asklear user-side Credits settled for this task after completion.
- result.data.entity (string): Response entity type.
- result.data.keyword (string): The submitted search keyword.
- result.data.page (integer): Current result page.
- result.data.max_pages (integer): Next-page hint; request the next page while items continue to be returned.
- result.data.item_count (integer): Number of items in this response page.
- result.data.items (array<object>): Search result notes for this page.
- result.data.items[].note_id (string): Note identifier.
- result.data.items[].title (string): Note title.
- result.data.items[].description (string): Note description or excerpt.
- result.data.items[].note_type (string): Note type.
- result.data.items[].publish_time (integer|null): Publish timestamp when supplied.
- result.data.items[].liked_count (integer): Like count.
- result.data.items[].collected_count (integer): Collection count.
- result.data.items[].comments_count (integer): Comment count.
- result.data.items[].images (array<object>): Images attached to the note.
- result.data.items[].images[].file_id (string): Image file identifier.
- result.data.items[].images[].url (string): Image URL.
- result.data.items[].images[].large_url (string): Large image URL, when supplied.
- result.data.items[].images[].width (integer): Image width in pixels.
- result.data.items[].images[].height (integer): Image height in pixels.
- result.data.items[].author (object): Note author summary.
- result.data.items[].author.user_id (string): Author user identifier.
- result.data.items[].author.red_id (string): Author platform identifier.
- result.data.items[].author.nickname (string): Author nickname.
- result.data.items[].author.avatar (string): Author avatar URL.
- result.data.items[].author.verified (boolean): Whether the author is verified.
- result.data.items[].author.verify_type (integer): Verification type code.
## POST /v1/search

legacy · available · api_key, oauth

REST requires a customer API Key; MCP requires an enabled authenticated server; CLI requires its published artifact and command.

按页翻页,不是游标续取;页码过大时上游会返回空页而不是报错。
只返回笔记摘要,正文、图片与完整互动数需要 xhs_note_detail_v1。

8 Credits per successful search page.

Where the request declares idempotency_key, reuse it for the same operation; metadata GET is read-only.

A pending response supplies a result/status reference. Read it first; do not automatically resubmit paid execution after a timeout or ambiguous result. Correct 401/403/422 errors before retrying.

### Input schema / 输入契约

```json
{
  "$defs": {
    "Schema1": {
      "additionalProperties": false,
      "description": "Common filter names with source-specific values checked after parsing.\n\n``sort`` stays a bounded string here because ``SearchSourceDefinition``\nowns each provider's vocabulary.",
      "properties": {
        "content_type": {
          "enum": [
            "note",
            "video"
          ]
        },
        "sort": {
          "enum": [
            "latest",
            "popularity",
            "relevance"
          ]
        },
        "time_range": {
          "enum": [
            "day",
            "half_year",
            "week"
          ]
        }
      },
      "required": [],
      "type": "object"
    },
    "Schema2": {
      "additionalProperties": false,
      "description": "Exactly one public image reference accepted by the Search API.",
      "properties": {
        "asset_id": {
          "anyOf": [
            {
              "maxLength": 128,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "base64": {
          "anyOf": [
            {
              "maxLength": 8388608,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "url": {
          "anyOf": [
            {
              "maxLength": 2048,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        }
      },
      "type": "object"
    }
  },
  "additionalProperties": false,
  "description": "Public request shape shared by text, image, and hybrid sources.",
  "properties": {
    "filters": {
      "$ref": "#/$defs/Schema1"
    },
    "image": {
      "anyOf": [
        {
          "$ref": "#/$defs/Schema2"
        },
        {
          "type": "null"
        }
      ],
      "default": null
    },
    "max_credits": {
      "anyOf": [
        {
          "exclusiveMinimum": 0,
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null
    },
    "page": {
      "default": 1,
      "maximum": 50,
      "minimum": 1,
      "type": "integer"
    },
    "page_token": {
      "const": ""
    },
    "query": {
      "anyOf": [
        {
          "maxLength": 200,
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "maxLength": 100
    },
    "search_mode": {
      "enum": [
        "text"
      ]
    },
    "source": {
      "const": "xhs"
    },
    "task_query": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional task attribution: when provided, write one concise, self-contained task_query in the user's language and reuse that exact value in every call for the task, including discovery, search, approval retry, results, export, and status checks. For MCP calls, when omitted, Asklear records a generic non-user-specific attribution so compatible clients can still call the tool. REST calls may omit it and remain unattributed. It is a task description, not a task identifier. Do not include hidden reasoning, credentials, or direct personal identifiers such as phone numbers, email addresses, identity numbers, or street addresses.",
      "maxLength": 300
    }
  },
  "required": [
    "source",
    "query"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "filters": {},
  "page": 1,
  "query": "示例关键词",
  "search_mode": "text",
  "source": "xhs"
}
```

### Synthetic response / 合成响应

```json
{
  "data": {
    "items": [],
    "pagination": {
      "has_more": false
    }
  }
}
```

- data.items (array<object>): No field description available
- data.items[].author (string): No field description available
- data.items[].collected_count (string): No field description available
- data.items[].comments_count (string): No field description available
- data.items[].description (string): No field description available
- data.items[].entity_id (string): No field description available
- data.items[].images (string): No field description available
- data.items[].liked_count (string): No field description available
- data.items[].note_id (string): No field description available
- data.items[].note_type (string): No field description available
- data.items[].publish_time (string): No field description available
- data.items[].snippet (string): No field description available
- data.items[].title (string): No field description available
- data.items[].url (string): No field description available
- data.pagination.has_more (boolean): No field description available
- data.pagination.next_page (integer|null): No field description available

Follow up: GET /v1/search/{job_id}
Read a pending search and its public results.

