A Model Context Protocol (MCP) server enabling AI assistants to interact with Outline (https://www.getoutline.com)
This project implements a Model Context Protocol (MCP) server that allows AI assistants (like Claude) to interact with Outline document services, providing a bridge between natural language interactions and Outline's document management capabilities.
Currently implemented:
- Document Search: Search for documents by keywords across content and titles
- Document Reading: Read document content and export as markdown
- Document Creation: Create new documents in collections
- Document Editing: Update document content and move documents
- Document Import: Import external content (markdown, text, HTML) as new documents
- Revision Tracking: List and retrieve specific document revisions
- Revision Comparison: Compare document versions with detailed change analysis
- Revision Analytics: Analyze revision history patterns and contributor activity
- Metadata Enrichment: Enhanced revision information with statistics and timestamps
- Collection Operations: List collections, view document structure, create/update/delete collections
- Collection Export: Export collections in multiple formats (markdown, JSON, HTML)
- Draft Management: List and manage draft documents
- Activity Tracking: View recently viewed documents
- Collaboration Features: View and add comments, manage document backlinks
- Natural Language Q&A: Ask questions about document content with AI-powered responses
We recommend running this python MCP server using Docker to avoid having to install dependencies on your machine.
- Install and run Docker (or Docker Desktop)
- Build the Docker image
docker buildx build -t mcp-outline .
- In Cursor, go to the "MCP Servers" tab and click "Add Server"
{ "mcpServers": { "mcp-outline": { "command": "docker", "args": [ "run", "-i", "--rm", "--init", "-e", "DOCKER_CONTAINER=true", "-e", "OUTLINE_API_KEY", "-e", "OUTLINE_API_URL", "mcp-outline" ], "env": { "OUTLINE_API_KEY": "<YOUR_OUTLINE_API_KEY>", "OUTLINE_API_URL": "<YOUR_OUTLINE_API_URL>", "MCP_TRANSPORT": "stdio" } } } }
OUTLINE_API_URL is optional, defaulting to https://app.getoutline.com/api
- Debug the docker image by using MCP inspector and passing the docker image to it:
npx @modelcontextprotocol/inspector docker run -i --rm --init -e DOCKER_CONTAINER=true --env-file .env mcp-outline
- Python 3.10+
- Outline account with API access
- Outline API key (get this from your Outline account settings)
# Clone the repository
git clone https://github.com/Vortiago/mcp-outline.git
cd mcp-outline
# Install in development mode
uv pip install -e ".[dev]"
Create a .env
file in the project root with the following variables:
# Outline API Configuration
OUTLINE_API_KEY=your_outline_api_key_here
# For cloud-hosted Outline (default)
# OUTLINE_API_URL=https://app.getoutline.com/api
# For self-hosted Outline
# OUTLINE_API_URL=https://your-outline-instance.example.com/api
# Development mode with the MCP Inspector
mcp dev src/mcp_outline/server.py
# Or use the provided script
./start_server.sh
# Install in Claude Desktop (if available)
mcp install src/mcp_outline/server.py --name "Document Outline Assistant"
The MCP Outline server supports two transport modes:
stdio
(default): Standard input/output for direct process communicationsse
: HTTP Server-Sent Events for web-based communication
Set the MCP_TRANSPORT
environment variable to choose your transport mode:
# For stdio mode (default - backward compatible)
export MCP_TRANSPORT=stdio
mcp-outline
# For HTTP/SSE mode (useful for Docker deployments)
export MCP_TRANSPORT=sse
mcp-outline
For Docker deployments, use SSE transport to enable HTTP endpoints:
environment:
- MCP_TRANSPORT=sse # Enables HTTP transport on port 3001
- OUTLINE_API_KEY=your_api_key
- OUTLINE_API_URL=https://your-outline-instance.com/api
When using MCP_TRANSPORT=sse
, the server will start on port 3001 with the following endpoints:
/sse
- Server-Sent Events endpoint for MCP communication/messages/
- HTTP message endpoint (requires session_id parameter)
When running the MCP Inspector, go to Tools > Click on a tool > it appears on the right side so that you can query it.
search_documents
: Search for documents by keywords across content and titleslist_collections
: List all available collections in the workspaceget_collection_structure
: View hierarchical document structure within a collectionget_document_id_from_title
: Find document ID by searching for its title
read_document
: Retrieve and display full document contentexport_document
: Export document content as plain markdowncreate_document
: Create new documents in specified collectionsupdate_document
: Modify existing document contentmove_document
: Move documents between collections
get_document_revision
: Retrieve specific document revision by ID (with caching)get_document_revision_with_metadata
: Get revision with enriched statisticslist_document_revisions
: List all revisions for a document (supports pagination)compare_document_revisions
: Compare two revisions with detailed change analysisget_revision_history_summary
: Analyze revision patterns and contributor activity
import_document
: Import external content (markdown, text, HTML) as new documentsimport_document_from_file_content
: Auto-detect format and import from file contentlist_draft_documents
: List draft documents for the current userget_recently_viewed_documents
: Get recently viewed documents
create_collection
: Create new collections for organizing documentsupdate_collection
: Modify collection properties (name, description, color)delete_collection
: Remove collections and all contained documentsexport_collection
: Export entire collections to downloadable filesexport_all_collections
: Export all workspace content
archive_document
: Archive documents without deletingunarchive_document
: Restore archived documentslist_trash
: View documents in trashrestore_document
: Restore documents from trashpermanently_delete_document
: Permanently remove documents
list_document_comments
: View all comments on a documentget_comment
: Retrieve specific comment detailsadd_comment
: Add comments to documentsget_document_backlinks
: Find documents that link to a specific document
ask_ai_about_documents
: Ask natural language questions about document content with AI-powered responses
- Caching: Frequently accessed revisions are cached for improved performance
- Pagination: Large result sets support offset/limit pagination
- Format Validation: Import tools validate file formats and content
- Error Handling: Comprehensive error messages for troubleshooting
- Performance: Optimized for large document repositories and revision histories
Search for documents containing "project planning"
Show me all available collections
Get the content of document with ID "docId123"
Create a new document titled "Research Report" in collection "colId456" with content "# Introduction\n\nThis is a research report..."
List all revisions for document "docId123"
Compare revisions "rev001" and "rev002" and show me the differences
Get a summary of revision history for document "docId123"
Import this markdown content as a new document titled "Imported Guide" in collection "colId456"
Import the content from file "README.md" as a new document
Show me my draft documents
List the documents I've recently viewed
Add a comment to document "docId123" saying "This looks great, but we should add more details to the methodology section."
Move document "docId123" to collection "colId789"
Export collection "colId456" as markdown format
Contributions are welcome! Please feel free to submit a Pull Request.
This project uses semantic versioning with conventional commits for automatic version management and Docker image tagging, supporting both stable releases and release candidates.
- Conventional Commits: All commits must follow the Conventional Commits specification
- Dual Branch Strategy: Automatic versioning works on both
main
(stable) andrc
(release candidate) branches:- Main branch: Creates stable releases (e.g.,
v1.2.3
) and tags Docker images withlatest
+ version - RC branch: Creates pre-releases (e.g.,
v1.2.3-rc.1
) and tags Docker images withrc
+ version
- Main branch: Creates stable releases (e.g.,
- Version Bump Rules: Semantic-release analyzes commits and determines version bumps:
- Major: commits with
BREAKING CHANGE
in body or!
suffix (e.g.,feat!: ...
) - Minor: commits starting with
feat:
- Patch: commits starting with
fix:
- No bump: commits starting with
docs:
,chore:
,style:
,test:
, etc.
- Major: commits with
- Automatic Updates: The
pyproject.toml
version is automatically updated on releases
# Stable releases (main branch)
feat: add new document export feature # Minor bump (0.3.0 → 0.4.0)
fix: resolve authentication issue # Patch bump (0.3.0 → 0.3.1)
feat!: remove deprecated API endpoints # Major bump (0.3.0 → 1.0.0)
docs: update README with new examples # No version bump
# Release candidates (rc branch)
feat: add experimental search filters # Pre-release (0.3.0 → 0.4.0-rc.1)
fix: improve rc stability # Pre-release (0.4.0-rc.1 → 0.4.0-rc.2)
- Main branch releases:
harbor.example.com/library/mcp-outline:latest
+harbor.example.com/library/mcp-outline:v1.2.3
- RC branch releases:
harbor.example.com/library/mcp-outline:rc
+harbor.example.com/library/mcp-outline:v1.2.3-rc.1
This ensures RC versions never override the production latest
tag while providing proper versioned releases for testing.
See docs/semantic-versioning.md for detailed information.
# Run tests
uv run pytest tests/
# Format code
uv run ruff format .
This project is licensed under the MIT License - see the LICENSE file for details.
- Built with MCP Python SDK
- Uses Outline API for document management