npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

my-scroll-mcp

v0.3.5

Published

MCP server for My Scroll document editor - enables Claude to directly edit your documents with line-level precision

Readme

My Scroll MCP Server

This is the Model Context Protocol (MCP) server for My Scroll, enabling Claude to directly read and edit your scroll documents with line-level precision.

🔒 Secure by Design: Version 0.2.0+ uses API-based token validation, requiring no sensitive database keys on the client side.

Installation

npm install -g my-scroll-mcp

Features

  • Line-based editing: Replace, insert, or delete specific lines
  • HTML-aware: Automatic Prettier formatting
  • Secure: API-based token validation with user-specific authentication
  • Real-time sync: Changes appear immediately in the web editor
  • No sensitive keys required: Fully secure without exposing database credentials

Available Tools

read_scroll

Read your current scroll document with line numbers.

replace_lines

Replace specific line(s) with new content.

  • startLine (number): Starting line number (1-based)
  • endLine (number, optional): Ending line number (defaults to startLine)
  • content (string): New HTML content

insert_at_line

Insert new content at a specific line.

  • lineNumber (number): Where to insert (1-based)
  • content (string): HTML content to insert

delete_lines

Delete specific line(s).

  • startLine (number): Starting line number (1-based)
  • endLine (number, optional): Ending line number (defaults to startLine)

append_to_scroll

Add content to the end of your scroll.

  • content (string): HTML content to append

prepend_to_scroll

Add content to the beginning of your scroll.

  • content (string): HTML content to prepend

Setup Instructions

1. Generate an MCP Token

  1. Go to your My Scroll app
  2. Visit your profile/settings page
  3. Create a new MCP token
  4. Save the token securely (it's only shown once)

2. Configure Claude Desktop

Add this to your Claude Desktop MCP configuration file:

For production use:

{
  "mcpServers": {
    "my-scroll": {
      "command": "npx",
      "args": ["-y", "my-scroll-mcp@latest"],
      "env": {
        "MY_SCROLL_API_URL": "https://myscroll.ai",
        "MY_SCROLL_AUTH_TOKEN": "mcp_your_token_here"
      }
    }
  }
}

For local development:

{
  "mcpServers": {
    "my-scroll": {
      "command": "npx",
      "args": ["-y", "my-scroll-mcp@latest"],
      "env": {
        "MY_SCROLL_API_URL": "http://localhost:3000",
        "MY_SCROLL_AUTH_TOKEN": "mcp_your_token_here"
      }
    }
  }
}

3. Test the Connection

Restart Claude Desktop and try:

"Read my scroll document"

Claude should be able to access your document and show it with line numbers!

Usage Examples

Basic Reading

"Show me the contents of my scroll"

Line Replacement

"Replace line 15 with a new heading: <h2>New Section</h2>"

Content Addition

"Add a new paragraph at the end about project conclusions"

Precise Editing

"Delete lines 8-10 and replace them with a code block showing the API example"

Security Notes

  • Each MCP token is scoped to your specific user account
  • Tokens can be revoked at any time from the web interface
  • The server only accesses your documents, not other users'
  • All changes go through the same validation as the web editor

Development

To run the MCP server in development mode:

pnpm run dev

This enables file watching for automatic restarts during development.

Troubleshooting

Authentication Errors

  • Verify your MCP token is correct and hasn't been revoked
  • Check that MY_SCROLL_AUTH_TOKEN is set in your MCP configuration

Connection Issues

  • Ensure your My Scroll app is running on the specified URL
  • Check that the API URL in the MCP config matches your app's URL

Line Number Issues

  • Line numbers are 1-based (first line is line 1)
  • After operations, Prettier may reformat and change line numbers
  • Always read the document first to see current line numbers

API Reference

The MCP server communicates with these endpoints:

  • POST /api/documents/lines - All line operations
  • POST /api/auth/mcp-token - Token management

See the API route files for detailed request/response schemas.