使用语义搜索和关键词搜索来搜索你的文档,并支持可配置的过滤和分页。

使用 assistant API 密钥进行身份验证。搜索请求不消耗额度。

post/v1/search/{domain}

Request

  • Base URL
    https://api.mintlify.com/discovery
  • Auth
    HTTP bearer

Path parameters

domainstring required

来自你的 domain.mintlify.site URL 的域名标识符。可以在控制台 URL 的末尾找到。例如,dashboard.mintlify.com/organization/domain 的域名标识符就是 domain。

Request body

querystring required

在文档内容中要执行的搜索查询。

pageSizeinteger

要返回的搜索结果数量。必须在 1 到 50 之间。若未指定,默认为 10。

scoreThresholdnumber

结果的最低相关性分数。仅返回分数等于或高于此阈值的结果。必须介于 0 和 1 之间。

Response

搜索结果

contentstring

来自文档中匹配的内容。

pathstring

源文档所在的路径或 URL。

metadataobject

与搜索结果相关的附加 metadata。

Changes

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status

    3 more changes in this revision