get_pageLABSCO SUMMARY
Line edits, and the destructive tools are missing until you ask for them.
Most wiki servers only offer read and replace-the-page, which makes an assistant's small correction into a rewrite you have to review in full. Editing by exact line match keeps the diff the size of the change. The other decision worth noticing is that delete_page and rewrite_page do not appear in the tool list at all by default — the model cannot call what it cannot see — and when you do enable them, a dry run tells you the line counts before anything is touched.
What it is
An MCP server for Cosense, formerly Scrapbox. Reading is straightforward; the interesting part is writing, which works line by line through the WebSocket API so an assistant can change one paragraph without re-sending the page and losing everything else on it.
What you get
- get_page — content, metadata and links for one page; get_page_url builds a direct link without any authentication
- list_pages — browse with sorting and pagination, up to 1000 pages
- search_pages — full-text search with keyword highlighting, up to 100 results
- create_page — a new page from Markdown or Scrapbox body
- insert_lines, edit_lines and delete_lines — targeted edits by exact line match, singly or across a multi-line block, and matchAll when every occurrence should change
- get_smart_context — a page together with the pages it links to, one or two hops out, formatted for an assistant to read
- delete_page and rewrite_page, which replace or empty a whole page — not registered at all unless you opt in, and offering a dry run that reports what would change before it changes
- The same binary runs as a standalone CLI, with a compact output mode meant for agents
- COSENSE_TOOL_SUFFIX renames the tools per instance, so two projects can be connected at once without a name clash
Requirements
COSENSE_PROJECT_NAME for the project you are pointing at. Public projects need nothing more to read, and get_page_url never needs credentials. Private projects and every write need COSENSE_SID — the connect.sid session cookie copied from a logged-in browser, in its decoded form; treat it as a password, and expect to replace it when it expires. Destructive tools stay unregistered until COSENSE_ENABLE_DELETE is set. Install as a desktop extension from GitHub Releases, as a Claude Code plugin, or from source.
Setup effort
One command — npx -y scrapbox-cosense-mcp
USE CASES
Fixing one wrong sentence in a long page
Match the line exactly and replace just that line, leaving the rest of the page untouched.
Getting the assistant up to speed on a topic
Pull a page along with the pages it links to, so the surrounding context arrives in one call.
Writing up meeting notes as they happen
Create the page, then append lines to it as the discussion goes on.
Finding where something was written down
Full-text search with highlighting, then open the page that matched.
Cleaning up a page that has gone stale
Preview the removal as a dry run first, and only then let it delete the lines.
Working across two Cosense projects at once
Run two instances with different tool suffixes so the names do not collide.
11 tools
Listed in project docs. Your client may show a different list.
list_pagessearch_pagescreate_pageget_page_urlinsert_linesedit_linesdelete_linesdelete_pagerewrite_pageget_smart_contextBEFORE YOU INSTALL
What to know first
Tools you get
11 tools named in the project's documentation.
Requires
- npx on PATH
- COSENSE_PROJECT_NAME in your environment
Optional
COSENSE_SID in your environment
INSTALLATION
Connect your client
Server setup
npx -y scrapbox-cosense-mcpMCP Clients
Claude Desktop — MCPB bundle
Download scrapbox-cosense-mcp.mcpb from GitHub Releases and double-click
Claude Code — plugin
/plugin marketplace add worldnine/scrapbox-cosense-mcp
/plugin install scrapbox-cosense@worldnine-scrapbox-cosense-mcpClaude Code — npx
claude mcp add scrapbox-cosense-mcp -e COSENSE_PROJECT_NAME=<YOUR_COSENSE_PROJECT_NAME> -e COSENSE_SID=<YOUR_COSENSE_SID> -- npx -y scrapbox-cosense-mcpClaude Desktop, Cursor, Windsurf
{
"mcpServers": {
"scrapbox-cosense-mcp": {
"command": "npx",
"args": [
"-y",
"scrapbox-cosense-mcp"
],
"env": {
"COSENSE_PROJECT_NAME": "<YOUR_COSENSE_PROJECT_NAME>",
"COSENSE_SID": "<YOUR_COSENSE_SID>"
}
}
}
}