Connect Claude with ActivityWatch using MCP Server for seamless time tracking data access
The ActivityWatch MCP Server is designed to bridge the gap between activity tracking tools and advanced AI applications such as Claude Desktop, Continue, Cursor, and other MCP clients. By leveraging Model Context Protocol (MCP), this server allows AI systems to interact with detailed time tracking data from ActivityWatch. This integration provides a powerful way for AI applications to analyze user behavior, provide insights, or even adapt their functionality based on real-time activity data.
The ActivityWatch MCP Server offers several key functionalities that cater to the needs of both AI applications and end-users:
graph TD
A[AI Application] -->|MCP Client| B[MCP Protocol]
B --> C[MCP Server]
C --> D[Data Source/Tool]
style A fill:#e1f5fe
style C fill:#f3e5f5
style D fill:#e8f5e8
graph TD
A[AI Application] --> B[MCP Client]
B --> C[MCP Protocol Layer]
C --> D[MCP Server]
D --> E[ActivityWatch API Endpoint]
E --> F[Data Source/Tool]
style A fill:#e1f5fe
style C fill:#f3e5f5
style D fill:#f8d7da
The core architecture of the ActivityWatch MCP Server revolves around efficiently handling AI client requests and translating them into actionable data through Model Context Protocol (MCP). Key components include:
By default, the server connects to the ActivityWatch API at http://localhost:5600
. However, this can be adjusted in the source code for custom deployment scenarios.
# Example environment setup
API_URL=http://remote_server:5600
The server supports various commands and parameters to interact with ActivityWatch:
To get started with the ActivityWatch MCP Server, you can choose between installing it via npm or building it from source. Each method is detailed below:
# Global installation
npm install -g activitywatch-mcp-server
# Or local installation
npm install activitywatch-mcp-server
Clone the Repository
git clone https://github.com/8bitgentleman/activitywatch-mcp-server.git
cd activitywatch-mcp-server
Install Dependencies
npm install
Build the Project
npm run build
Real-world scenarios highlight the versatility of integrating ActivityWatch MCP Server with various AI applications:
To integrate with Claude Desktop or any other MCP client:
{
"mcpServers": {
"activitywatch": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-activitywatch"],
"env": {
"API_KEY": "your-api-key"
}
}
}
}
The ActivityWatch MCP Server supports multiple AI clients, as shown in the compatibility matrix:
MCP Client | Resources | Tools | Prompts | Status |
---|---|---|---|---|
Claude Desktop | ✅ | ✅ | ✅ | Full Support |
Continue | ✅ | ✅ | ✅ | Full Support |
Cursor | ❌ | ✅ | ❌ | Tools Only |
Ensure that the ActivityWatch server is running and accessible at http://localhost:5600
by default. If configured otherwise, modify your server environment file:
API_URL=http://remote_server:5600
{
"mcpServers": {
"activitywatch": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-activitywatch"],
"env": {
"API_KEY": "your-api-key"
}
}
}
}
A1: Installing via npm provides a faster setup but may not include all customization options available in a built-from-source environment. Building from source allows for more flexibility, especially when deploying to custom environments.
A2: While the MCP client compatibility matrix indicates full support for Claude Desktop and Continue, users can explore compatibility with additional AI applications by configuring their own environments.
A3: Common troubleshooting steps include verifying API endpoint URLs, checking network configurations, and ensuring that required dependencies are correctly installed. Logging network requests from both ends can provide insights into connection problems.
A4: Yes, you can modify the codebase to add or alter query templates for more specific use cases. This customization process is detailed in the documentation provided with the project.
A5: By integrating ActivityWatch data into AI workflows, this server provides richer datasets and real-time insights that can significantly improve the accuracy and effectiveness of AI-driven decision-making processes.
Contributing to the development of the ActivityWatch MCP Server is encouraged. Developers interested in contributing should familiarize themselves with the project's codebase and follow established guidelines:
For more information and resources related to Model Context Protocol (MCP) and its integrations, visit the official MCP documentation and community forums:
The ActivityWatch MCP Server is a powerful tool for integrating time tracking data with AI applications. Its flexible architecture, comprehensive feature set, and compatibility across various tools make it an invaluable component in enhancing the functionality and insights of advanced AI systems.
By leveraging this server, developers can create more sophisticated and data-driven AI solutions that provide deeper insights into user behavior and preferences.
RuinedFooocus is a local AI image generator and chatbot image server for seamless creative control
Simplify MySQL queries with Java-based MysqlMcpServer for easy standard input-output communication
Build stunning one-page websites track engagement create QR codes monetize content easily with Acalytica
Learn to set up MCP Airflow Database server for efficient database interactions and querying airflow data
Explore CoRT MCP server for advanced self-arguing AI with multi-LLM inference and enhanced evaluation methods
Access NASA APIs for space data, images, asteroids, weather, and exoplanets via MCP integration