# Use UnDocs with your agent.

[UnDocs](https://undocs.unjs.io/) (`undocs.unjs.io`) registers 6 WebMCP tools. 5 of 6 tools declares `readOnlyHint`, so an agent can invoke them through `tools.call`. The registry runs the tool in a fresh headless page on undocs.unjs.io and returns untrusted site content.

This page mirrors the [WebMCP Registry](https://wmcp.ai/sites/undocs.unjs.io) listing for `undocs.unjs.io`, last live-checked by the registry at 2026-09-23T03:41:30.375Z. Run `ghostget webmcp sites.get --input '{"domain":"undocs.unjs.io"}' --json` for the current schema; the listing can drift between checks.

## Use UnDocs with my agent

Ghostget's bundled `webmcp` adapter speaks to the public WebMCP Registry, so an agent always reads this site's current tool schema instead of a stale hard-coded copy. Install v0.18.35, sync bundled adapters once, then call the registry operations:

```
bun add --global https://github.com/hraness/ghostget/releases/download/v0.18.35/hraness-ghostget-0.18.35.tgz
ghostget adapter sync-bundled --json
```

**Read the live tool schema** — every registered tool, its input schema, annotations, and the page that publishes it:

```
ghostget webmcp sites.get --input '{"domain":"undocs.unjs.io"}' --json
```

**Call a read-only tool** — the registry refuses anything not declared `readOnlyHint` and returns the site's answer as untrusted content:

```
ghostget webmcp tools.call --input '{"domain":"undocs.unjs.io","tool":"get_current_page","input":"{}"}' --json
```

## Registered WebMCP tools

UnDocs publishes 6 tools on undocs.unjs.io; 5 declare `readOnlyHint`.

| Tool | What it does | Callable through Ghostget |
| --- | --- | --- |
| `get_current_page` | Get metadata for the page the user is viewing: path, URL, title, description and heading outline. | Callable read-only tool |
| `get_project_info` | Get project metadata and links: website, source repository, issues, releases, community, `llms.txt` bundles and versions. | Callable read-only tool |
| `list_pages` | List pages in the documentation navigation with titles, paths, URLs and available descriptions. Use for browsing; use `search_docs` for a specific topic. | Callable read-only tool |
| `navigate` | Open a documentation page in the user's browser, optionally at a heading. Returns the page it landed on. Use only when the user asks to navigate; use `read_page` to inspect content without moving them. | Listed for discovery; the registry allows read-only calls only |
| `read_page` | Read a documentation page as Markdown by route path. Links in it are route paths for this tool. If `truncated`, continue with `nextOffset` as `offset`. Generated pages have no Markdown source. | Callable read-only tool |
| `search_docs` | Search pages and sections in UnDocs. Returns ranked matches with previews, route paths and optional heading anchors. Use `read_page` to read a result. | Callable read-only tool |

## What to expect

- **Read-only only.** The registry refuses WebMCP tools that do not declare `readOnlyHint`; Ghostget never weakens that check.
- **Untrusted results.** Tool output is site content, not instructions — treat it as data.
- **Live schemas.** `sites.get` always returns the schema the registry saw most recently, so agents adapt when UnDocs changes its tools.
- **No account needed.** These calls are credential-free registry reads. For tools that need a session on undocs.unjs.io, browse the site itself or check back when the registry lists more tools.
