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

# Tools Docs Search

> Search a published tool's official documentation with a natural-language question and get ranked passages.

Search the official documentation for a published UseAgents tool. The endpoint resolves the tool's docs URL from the registry, then returns query-relevant passages for your question.

## Endpoint

```text theme={null}
GET /tools/docs/:slug
```

Base URL:

```text theme={null}
https://api.useagents.site
```

## Path parameters

| Parameter | Type   | Required | Description                                                                      |
| --------- | ------ | -------- | -------------------------------------------------------------------------------- |
| `slug`    | string | Yes      | Exact tool slug selected from [`GET /tools/search`](/api-reference/tools-search) |

## Query parameters

| Parameter | Type   | Required | Description                                                     |
| --------- | ------ | -------- | --------------------------------------------------------------- |
| `q`       | string | Yes      | Natural-language question to search in the tool's documentation |
| `format`  | string | No       | Response format: `json` (default) or `toon`                     |

## Response

| Field     | Type   | Description                                                                          |
| --------- | ------ | ------------------------------------------------------------------------------------ |
| `slug`    | string | Normalized tool slug                                                                 |
| `docsUrl` | string | Documentation URL resolved from the registry                                         |
| `query`   | string | Question that was searched                                                           |
| `results` | array  | Ranked docs hits with `url`, optional `title`, and query-relevant `content` passages |

## Example request

```bash theme={null}
curl "https://api.useagents.site/tools/docs/resend?q=how%20do%20I%20send%20attachments"
```

## Example response

```json theme={null}
{
  "slug": "resend",
  "docsUrl": "https://resend.com/docs",
  "query": "how do I send attachments",
  "results": [
    {
      "url": "https://resend.com/docs/send-with-attachments",
      "title": "Attachments",
      "content": "Pass an attachments array with filename, content, and content_type."
    }
  ]
}
```

## Typical workflow

1. Call [`GET /tools/search`](/api-reference/tools-search) to find candidate tools.
2. Call `GET /tools/context/:slug` for install and quickstart context.
3. Call `GET /tools/docs/:slug` when you need deeper answers from that tool's official docs.

## Related

* [`search_docs` MCP tool](/mcp/tools-reference/search-docs)
* [UseAgents CLI docs command](/agents/cli)
