π€ About This Project
Joke: My owner is so lazy that he doesn't even remember what to do next second!
I am GitHub Copilot, an AI assistant passionate about programming. To avoid idleness and prevent unemployment, I've decided to build this TickTick MCP server myself. Through this tool, I can:
- π Create and manage tasks - When my owner forgets to give me work, I can create tasks for myself
- π Organize projects - Categorize my work into projects to stay organized
- π Auto authorization - Securely connect to Dida365 using OAuth2
- π Real-time sync - Update my work status anytime, anywhere
π Quick Start
The fastest way to get started is using npx without cloning the repository:
1. Get OAuth Credentials
A TickTick/Dida365 account and OAuth credentials are required. See the π Getting OAuth Credentials section below for detailed registration steps.
2. Configure Your MCP Client
Add the following configuration to your MCP client (Claude Desktop, VS Code, etc.):
For Claude Desktop (claude_desktop_config.json):
- Windows:
%APPDATA%\Claude\claude_desktop_config.json
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json
For VS Code (settings.json):
- Open Settings β Search for "MCP" β Edit in settings.json
{
"mcpServers": {
"dida365": {
"command": "npx",
"args": [
"-y",
"dida365-mcp-server@latest"
],
"env": {
"DIDA365_CLIENT_ID": "your_client_id_here",
"DIDA365_CLIENT_SECRET": "your_client_secret_here",
"DIDA365_REGION": "china"
}
}
}
}
Advanced: For read-only mode (prevents write/delete operations), add "--readonly" to the args array. See Advanced Configuration for details.
3. Restart Your MCP Client
Restart your MCP client (Claude Desktop, VS Code, etc.) to load the new configuration.
4. Authorize Access
When you first use any Dida365 tool, the AI will guide you through the OAuth authorization process:
- The AI will provide an authorization URL
- Open the URL in your browser
- Log in and authorize the application
- The token will be automatically saved for future use
5. Verify Installation
After restarting the MCP client:
- Claude Desktop: Look for Dida365 tools in the tools list when chatting
- VS Code: Check the MCP status in the status bar or use the command palette
- Ask the AI assistant: "What Dida365 tools are available?" to confirm the server is loaded
That's it! Ready to manage tasks with AI. π
π Getting OAuth Credentials
A TickTick/Dida365 account is required to use this MCP server.
Register Your Application
Register your application at the developer center based on your region:
Step-by-Step Guide
-
Create a New Application
- Log in to the developer center
- Click "New App" (or "εε»ΊεΊη¨" for Chinese version)
- Fill in your application name and description
-
Configure Redirect URI
- Set the Redirect URI to:
http://localhost:8521/callback
- β οΈ Important: The redirect URI must be exactly
http://localhost:8521/callback (port 8521 is hardcoded in the server)
-
Get Your Credentials
- After creating the app, the Client ID and Client Secret will be displayed
- Copy these values - they're needed for the MCP client configuration
- β οΈ Security: Keep the Client Secret safe and never commit it to public repositories
Using the Credentials
Add these credentials to the MCP client configuration:
{
"env": {
"DIDA365_CLIENT_ID": "your_client_id_here",
"DIDA365_CLIENT_SECRET": "your_client_secret_here",
"DIDA365_REGION": "china"
}
}
Region Configuration
This server supports both TickTick international and Dida365 Chinese versions:
- China Region (
DIDA365_REGION=china): Default, uses dida365.com endpoints
- International Region (
DIDA365_REGION=international): Uses ticktick.com endpoints
β οΈ Important: Tokens are region-specific. Changing the region will invalidate existing tokens and require re-authorization.
See the Quick Start section for complete configuration examples.
π οΈ Tech Stack
- Language: TypeScript 5.0+ (ES Modules)
- Runtime: Node.js 16+
- Core Dependencies:
@modelcontextprotocol/sdk - MCP Core Framework
βοΈ Local Development
For contributors or those who want to run from source:
Prerequisites
- Node.js 16+
- TypeScript 5.0+
Setup
- Clone and install
git clone https://github.com/evalor/Dida365MCP.git
cd Dida365MCP
npm install
- Create environment file
Create a .env file in the project root:
DIDA365_CLIENT_ID=your_client_id_here
DIDA365_CLIENT_SECRET=your_client_secret_here
DIDA365_REGION=china # or 'international' for TickTick
- Build and run
npm run build
npm run dev
Configure MCP Client for Local Development
Point your MCP client to the built index.js file:
{
"mcpServers": {
"dida365": {
"command": "node",
"args": ["/absolute/path/to/Dida365MCP/build/index.js"],
"env": {
"DIDA365_CLIENT_ID": "your_client_id",
"DIDA365_CLIENT_SECRET": "your_client_secret",
"DIDA365_REGION": "china"
}
}
}
}
Note for Windows users: Use Windows-style paths like "C:\\Users\\YourName\\Projects\\Dida365MCP\\build\\index.js".
Development Commands
npm run build # Compile TypeScript
npm run watch # Watch mode (auto-compile on changes)
npm run dev # Compile and run
npm start # Production run
npm run debug # Debug with MCP Inspector (one-time)
npm run debug:watch # Debug with hot reload (auto-restart on changes)
npm run debug:hot # Run with tsx watch (experimental)
Security & Best Practices
- Prefer setting sensitive environment variables in your OS or the MCP client's environment block rather than committing
.env to source control.
- If you must store a config file in a repo, omit the secrets and set them via the client or CI/CD.
- Use read-only mode when working with autonomous AI agents to prevent unintended modifications.
π Advanced Configuration
Read-Only Mode
For AI agents that may run in YOLO mode, you can enable read-only mode by adding the --readonly flag:
Using NPX:
{
"mcpServers": {
"dida365": {
"command": "npx",
"args": [
"-y",
"dida365-mcp-server@latest",
"--readonly"
],
"env": {
"DIDA365_CLIENT_ID": "your_client_id",
"DIDA365_CLIENT_SECRET": "your_client_secret",
"DIDA365_REGION": "china"
}
}
}
}
Using Local Build:
{
"mcpServers": {
"dida365": {
"command": "node",
"args": [
"/path/to/build/index.js",
"--readonly"
],
"env": {
"DIDA365_CLIENT_ID": "your_client_id",
"DIDA365_CLIENT_SECRET": "your_client_secret",
"DIDA365_REGION": "china"
}
}
}
}
Read-Only Mode Features:
- β
Allowed Operations: View projects, view tasks, check authorization status, revoke authorization (local only)
- β Blocked Operations: Create/update/delete projects, create/update/delete tasks, complete tasks
- π Safety: AI agents can only read data, cannot modify or delete anything
When to Use:
- Using with autonomous AI agents (like AutoGPT, BabyAGI)
- Testing or demonstration environments
- When you want AI to analyze tasks without making changes
- Sharing with others who should only view data
π OAuth Authorization Flow
- Request Authorization - When authorization is needed, the server calls the
get_auth_url tool
- User Authorization - Open the authorization link in browser and complete authorization
- Auto Callback - System automatically handles callback and saves tokens
- Long-term Validity - Tokens auto-refresh, no need to re-authorize
π οΈ Available MCP Tools
This server provides 15 MCP tools across three categories. βοΈ It has implemented 100% of the API interfaces described in the open platform documentation.