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

# x402 MCP servers

> ATXP clients may access x402 MCP servers by using an adapter

If you’d like your agent to access the [x402 ecosystem](https://www.x402.org/ecosystem) in addition to [ATXP MCP servers](/tools), there is an adapter available.

To install it, run:

```bash theme={null}
npm i -S @atxp/x402
```

Then import it:

```typescript theme={null}
import { wrapWithX402 } from "@atxp/x402";
```

And use it in your application:

```typescript theme={null}
const mcpClient = await atxpClient({
  ...config,
  fetchFn: wrapWithX402(config) // [!code ++]
});
```

Now your agent can access x402-compatible MCP servers!
