loading…
Search for a command to run...
loading…
Enables LLMs to scrape, index, and search modern and legacy Salesforce documentation by piercing complex Shadow DOM and iframe structures. It supports hierarchi
Enables LLMs to scrape, index, and search modern and legacy Salesforce documentation by piercing complex Shadow DOM and iframe structures. It supports hierarchical spidering of entire guides and local RAG capabilities using a SQLite database for offline querying.
A powerful Model Context Protocol (MCP) server that empowers LLMs to scrape, digest, and search through modern and legacy Salesforce documentation. It elegantly handles deeply nested Shadow DOMs, typical of Lightning Web Components (LWC), and legacy iframe-based documentation structures.
help.salesforce.com and developer.salesforce.com to extract only the pure article Markdown.mass_extract_guide.docs.db) allowing for instantaneous local search using search_local_docs.scrape_single_page: Provide a Salesforce documentation URL. The server will use a headless browser (Puppeteer) to load the page, wait for dynamic content, pierce all shadow DOMs, and return clean Markdown.mass_extract_guide: Provide a "Table of Contents" or central guide URL. The server will extract the parent page, find all hierarchical child links, scrape them concurrently, chunk their content, and save them to a local SQLite database for offline querying.search_local_docs: Provide a natural language query (e.g., LWC lifecycle hooks). The server queries the SQLite database using fuzzy SQL search to instantly return the best matching pre-scraped chunks of documentation.read_local_document: Rapidly extracts the full Markdown content of a documentation page that has already been indexed locally, instantly returning the content without needing to re-run headless Chromium to bypass CDNs.export_local_documents: Safely compile an entire guide (or multiple guides) stored in the offline SQLite database into a massive concatenated Markdown file exported directly to your local file system, without saturating LLM context windows or writing complex CLI scripts.MCP servers act as a bridge between an LLM and local tools. To actually use this server, you need to plug it into an AI coding assistant like Cursor or Claude Desktop.
The absolute easiest way to do this is to use npx, which will automatically download and run the latest version of the server from NPM.
commandunified-sf-docsnpx -y unified-sf-docs-mcp~/Library/Application Support/Claude/claude_desktop_config.json%APPDATA%\Claude\claude_desktop_config.jsonmcpServers object:{
"mcpServers": {
"unified-sf-docs": {
"command": "npx",
"args": [
"-y",
"unified-sf-docs-mcp"
],
"env": {
"SF_DOCS_DB_DIR": "/absolute/path/to/your/private/github/repository"
}
}
}
}
By default, the SQLite database is securely stored entirely offline at ~/.unified-sf-docs-mcp/salesforce-docs.db.
If you want to sync your scraped AI Knowledge Base across multiple computers, or share a pre-scraped docs.db vector database with a private engineering team:
/Users/todd/my-private-sf-kb).SF_DOCS_DB_DIR environment variable to your Cursor or Claude Desktop MCP settings, pointing to your cloned folder.mass_extract_guide via your AI to scrape the documentation. The 100MB+ salesforce-docs.db will be securely created inside your Git repository, ready to be committed and pushed!If you want to modify the source code yourself, you can point your AI assistant to a local installation instead of using npx:
git clone https://github.com/tmtrevisan/unified-sf-docs-mcp.git
cd unified-sf-docs-mcp
npm install && npm run build
(Note: The server runs from the compiled /dist directory, so building is required).You can use the provided test scripts to verify the core functionality or the scraper against different Salesforce URL layouts:
# Test the database, chunking, and search functionality
npx tsx tests/test-core.js
# Test the robust Shadow DOM scraper against 4 different URL permutations
npx tsx tests/test-all.js
commandnode /ABSOLUTE/PATH/TO/unified-sf-docs-mcp/dist/index.jsДобавь это в claude_desktop_config.json и перезапусти Claude Desktop.
{
"mcpServers": {
"unified-salesforce-documentation-mcp-server": {
"command": "npx",
"args": []
}
}
}