# Claude Code

Use pdf-mcp's PDF tools from Claude Code. You need Claude Code installed and a [pdf-mcp account](https://app.pdf-mcp.io).

## Add the server

Run this command in your terminal:

```bash
claude mcp add --transport http --scope user pdf-mcp https://api.pdf-mcp.io/mcp
```

The `--scope user` option makes the connection available across projects for your local user. Omit it to keep the connection local to the current project. Claude Code connects directly to the hosted server; there is no pdf-mcp package to install.

## Sign in

1. Start Claude Code with `claude`.
2. Enter `/mcp` inside Claude Code.
3. Choose `pdf-mcp`, then **Authenticate**.
4. Sign in to pdf-mcp in your browser, select your workspace, and approve access.
5. Check `/mcp` again to confirm the server is connected.

These commands follow Anthropic's [Claude Code MCP guide](https://code.claude.com/docs/en/mcp).

## Try it

Ask Claude Code:

> Use pdf-mcp to turn this project's README into a PDF. Store it and return the browser view link.

Review the proposed tool call and allow it when prompted. Generation uses the connected workspace's [credits](https://pdf-mcp.io/credits).

## Troubleshooting

- **`claude` command not found:** Install or update Claude Code using Anthropic's instructions.
- **Authentication required:** Use `/mcp` inside Claude Code and select the authentication action; `/mcp` is not a shell command.
- **Wrong workspace:** Reauthorize the connection for the intended workspace. Switching the dashboard workspace does not change the saved authorization.

See [MCP troubleshooting](https://pdf-mcp.io/docs/mcp-server#troubleshooting) for credit and permission errors.
