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

# Connect

> Query the UseAgents registry from your agent over MCP, the REST API, or the UseAgents CLI.

UseAgents is one registry. Pick the surface that fits how you build agents.

<CardGroup cols={3}>
  <Card title="MCP" icon="plug" href="/mcp/connecting">
    Connect an MCP-compatible client (Cursor, Claude, Codex, and more) so the
    agent can search and fetch tool context in-session.
  </Card>

  <Card title="REST API" icon="square-terminal" href="/api-reference/introduction">
    Call the registry from your own agent runtime, backend, or automation with
    standard HTTP.
  </Card>

  <Card title="CLI" icon="terminal" href="/agents/cli">
    Search the registry and fetch context from a terminal or script.
  </Card>
</CardGroup>

<Note>
  Querying UseAgents is **currently free** during our public beta. Requests are subject to [rate limits](/api-reference/rate-limit).
</Note>

## Same workflow, any surface

Whatever you connect with, keep this order:

1. **Search** the registry with a task and constraints.
2. **Shortlist** candidates from the returned metadata.
3. **Fetch context** for the chosen tool (install, examples, docs link).
4. **Search docs** for deeper how-to answers from that tool's official documentation - do not invent setup from training data when context is missing.
5. **Test** a small snippet in a UseAgents sandbox when you want to confirm the packages install and the code runs.

| Surface      | Search                                              | Context                                                     | Docs                                                 | Test                                            |
| ------------ | --------------------------------------------------- | ----------------------------------------------------------- | ---------------------------------------------------- | ----------------------------------------------- |
| **MCP**      | [`search_tools`](/mcp/tools-reference/search-tools) | [`get_tool_context`](/mcp/tools-reference/get-tool-context) | [`search_docs`](/mcp/tools-reference/search-docs)    | [`test_tool`](/mcp/tools-reference/test-tool)   |
| **REST API** | [`GET /tools/search`](/api-reference/tools-search)  | `GET /tools/context/:slug`                                  | [`GET /tools/docs/:slug`](/api-reference/tools-docs) | [`POST /tools/test`](/api-reference/tools-test) |
| **CLI**      | `useagents search`                                  | `useagents context`                                         | `useagents docs`                                     | `useagents test`                                |

## MCP

Best when your agent already speaks MCP. Add the UseAgents server once, then ask the agent to search when it needs a tool.

| Setting | Value                            |
| ------- | -------------------------------- |
| **URL** | `https://mcp.useagents.site/mcp` |

See [Connecting over MCP](/mcp/connecting) and [client guides](/mcp/clients/cursor).

## REST API

Best when you own the agent loop (custom runtime, backend job, evaluation harness).

| Setting      | Value                        |
| ------------ | ---------------------------- |
| **Base URL** | `https://api.useagents.site` |

See the [API Reference](/api-reference/introduction), [`GET /tools/search`](/api-reference/tools-search), and [`GET /tools/docs/:slug`](/api-reference/tools-docs).

## CLI

Install the CLI with npm or the standalone installer, then run `useagents --help`. Upgrade a standalone binary with `useagents upgrade`.

See [UseAgents CLI](/agents/cli) for installation, upgrade, filters, output formats, and scripting examples.

## Skills

Install the UseAgents [Agent Skill](/agents/skills) so coding agents automatically follow the search → context → docs → implement workflow when they need a developer tool:

```bash theme={null}
npx skills add useagentsai/skills
```

The skill directs the agent; MCP, CLI, or the API is how it reaches the registry.

## Next steps

* [Agents introduction](/agents/introduction) - Why query a registry at runtime
* [Skills](/agents/skills) - Install the Agent Skill for discovery guidance
* [Connecting over MCP](/mcp/connecting) - MCP setup and verification
* [API Reference](/api-reference/introduction) - HTTP access to the registry
