Review a page and let Claude Code fix it.
Pin a comment on the element that needs to change. Claude Code reads the comment over MCP with the page, selector and conversation attached, makes the change, and replies in the thread.
What you need
- A site with the pinthread script tag. Sign up free and the install guide take a few minutes.
- An agent token from Agent access in the dashboard. Store it as
PINTHREAD_TOKEN, never in your repository. - Claude Code with access to your repository.
<script src="https://pinthread.dev/embed.js"
data-project="YOUR_PROJECT_KEY" defer></script>Connect Claude Code
The server is https://pinthread.dev/mcp. The token decides which project Claude Code sees.
claude mcp add --transport http pinthread https://pinthread.dev/mcp \
--header "Authorization: Bearer $PINTHREAD_TOKEN"Run it in your project with PINTHREAD_TOKEN set to your agent token.
To share the setup with your team, commit a .mcp.json in the project root. It expands the environment variable, so no token is stored in the file:
{
"mcpServers": {
"pinthread": {
"type": "http",
"url": "https://pinthread.dev/mcp",
"headers": { "Authorization": "Bearer ${PINTHREAD_TOKEN}" }
}
}
}Checked on 10 October 2026. Source: Claude Code MCP documentation. The server side (a POST-only streamable HTTP endpoint with a bearer token) is described on the MCP server page.
Tell it how to work
Add this to your CLAUDE.md so every session follows the same steps:
When I mention pinthread comments, use the pinthread MCP tools. List the open threads, read each one with get_thread, then make the change and check it. Reply with what you changed. Resolve a thread only when you are confident the fix is complete. If a comment is a question or needs a decision, reply and leave it open.Or paste this prompt in a session:
Fix the open pinthread comments on /pricing. List the threads, read each one with get_thread, change the code, and check the change. Reply in each thread with what you changed. Resolve a thread only when the fix is complete. If a comment is a question, reply and leave it open.How it works, step by step
- Maya opens your staging site, clicks the annual plan button, and writes: “Make it clear this is billed annually.”
- You tell Claude Code: “Fix the open pinthread comments on /pricing.”
- Claude Code calls
list_threadswith the page filter, thenget_thread. It receives the page/pricing, the selector, the text “Choose plan”, and Maya’s words. - Claude Code edits the component that renders the button and checks the change.
- With a write token it calls
reply_thread(“Label now reads Choose annual plan; monthly price stays visible”) andresolve_thread. With a read token it reports the change to you and you resolve the thread in the sidebar.
How Claude Code reads and replies
pinthread exposes tools only. Claude Code uses these:
list_threadslists threads. Filter by status, page, assignee, priority or label.get_threadreads one thread with every comment.get_page_contextreturns the open threads on one page.list_eventsreturns new threads and replies after a cursor. Start withsince: "latest".reply_threadandresolve_threadneed a write token.
The tool table lists all 12 tools.
Check the connection
Run claude mcp list or type /mcp in a session. pinthread should be listed as connected. Then ask Claude Code to call whoami. It returns the project, token name and scope.
Troubleshooting
- The server shows as failed in /mcp
- Start Claude Code from a shell where
PINTHREAD_TOKENis set, or runclaude mcp get pinthreadto read the stored header. If you added the server in the wrong scope, remove it withclaude mcp remove pinthreadand add it again. - HTTP 401: An agent token is required.
- The request had no valid
ptk_token. Check thatPINTHREAD_TOKENis set in the environment that starts Claude Code, and that the token is not revoked or expired. Tokens expire after 90 days by default. - HTTP 405: Send MCP messages with POST.
- The endpoint accepts only POST. Opening
https://pinthread.dev/mcpin a browser or sending GET returns this. It is not a fault in your setup. - A write tool fails
reply_thread,resolve_threadand the other write tools need a write token. Callwhoamito read the scope of the connection.- The list is empty
- Threads are per project and per page. Call
whoamito confirm the project, andlist_threadswith statusallto see resolved threads too.
Questions
Does Claude Code need a plugin or extension for pinthread?
No. Claude Code connects to the pinthread MCP server over HTTP with an agent token. Your site only needs the pinthread script tag.
Can Claude Code resolve threads on its own?
Only with a write token. A read token lists and reads threads and lets Claude Code propose fixes. Create the token in Agent access in the dashboard.
Which scope should I use for claude mcp add?
Use the default local scope for a private setup. Use --scope project to write a shared .mcp.json, or --scope user to make the server available in every project.
Try it
Start on the free plan, or read the general agent workflow. Pinthread carries the feedback. Claude Code edits your code.
Guides for other agents
- pinthread for CursorAdd the server in .cursor/mcp.json.
- pinthread for CodexAdd the server in config.toml or with codex mcp add.
- Agent workflowThe loop from comment to fix, for any agent.
- MCP serverTools, tokens and scopes.
- For your agentToken, setup and the prompt to paste.
- InstallOne script tag for your site.