Skip to content

Claude Integration

Lumberjack provides first-class integration with AI assistants like Claude and Cursor through Model Context Protocol (MCP). This allows AI to directly access your logs for better debugging and analysis.

The fastest way to set up Claude integration:

Terminal window
# Install Lumberjack with local server
uv add 'lumberjack_sdk[local-server]'
# Run the automated setup
uv run lumberjack claude init

This command will:

  • 🔧 Configure Claude Code MCP integration
  • 📝 Automatically instrument your application
  • 🚀 Set up all necessary configurations

If you prefer manual setup or need custom configuration:

Terminal window
uv run lumberjack serve

The MCP server starts automatically alongside the web UI.

Add the Lumberjack MCP server to your Claude Code configuration (usually in ~/.claude.json)

{
"mcpServers": {
"lumberjack": {
"type": "stdio",
"command": "lumberjack-mcp",
"args": [],
"env": {}
}
}
}
from lumberjack_sdk import Lumberjack
Lumberjack.init(
project_name="my-app"
)
LUMBERJACK_LOCAL_SERVER_ENABLED=true

Once set up, you can ask Claude natural language questions about your logs:

Finding Errors:

"Show me all error logs from the last hour"
"What's causing the database timeout errors?"

Debugging Issues:

"Use lumberjack MCP to write and read your own logs to debug"