This docker container syncs tick tick tasks with Notion dbs
1.1K
This application synchronizes tasks from TickTick to a Notion database. Follow this guide to set up and use the application.
To access TickTick tasks via the API, follow these steps:
Create an App on TickTick Developer Portal:
http://localhost:YOUR_PORT where YOUR_PORT is a port on your local machine).Get Authorization Code:
https://ticktick.com/oauth/authorize?client_id=YOUR_CLIENT_ID&scope=tasks:read&redirect_uri=YOUR_REDIRECT_URI&response_type=code
YOUR_CLIENT_ID and YOUR_REDIRECT_URI with your values.code parameter in the URL.Retrieve TickTick API Token:
curl -X POST https://ticktick.com/oauth/token \
-u CLIENT_ID:CLIENT_SECRET \
-d grant_type=authorization_code \
-d code=YOUR_AUTHORIZATION_CODE \
-d redirect_uri=YOUR_REDIRECT_URI
CLIENT_ID, CLIENT_SECRET, YOUR_AUTHORIZATION_CODE, and YOUR_REDIRECT_URI with your respective details.curl -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
https://api.ticktick.com/open/v1/project
id field from each project you want to synchronize.To write tasks to a Notion database, follow these steps:
Create an Integration:
Share Database with Integration:
Get the Database ID:
https://www.notion.so/{workspace_name}/{database_id}?v={view_id}.database_id.Create a .env file in your project directory with the following content:
TICKTICK_ACCESS_TOKEN=your_ticktick_access_token_here
NOTION_TOKEN=your_notion_token_here
NOTION_DATABASE_ID=your_notion_database_id_here
PROJECT_IDS=project_id1,project_id2,project_id3
Replace the placeholders with your actual information.
Now, build your Docker image with the SYNC_INTERVAL and other parameters:
docker run -p 80:80 \
-e TICKTICK_ACCESS_TOKEN="your_ticktick_access_token_here" \
-e NOTION_TOKEN="your_other_notion_token_here" \
-e NOTION_DATABASE_ID="your_other_notion_database_id_here" \
-e PROJECT_IDS="project_id1,project_id2,project_id3" \
-e SYNC_INTERVAL="120" \
xeyf/tickticktonotion:latest
Alternatively, you can use Docker Compose and define these variables in a .env file or directly in the docker-compose.yml file.
Here’s a docker-compose.yml example:
version: '3.8'
services:
tickticktonotion:
image: xeyf/tickticktonotion:latest
ports:
- "8080:80"
environment:
TICKTICK_ACCESS_TOKEN: "9f4288b1"
NOTION_TOKEN: "secret_Hgr"
NOTION_DATABASE_ID: "92ba7e23-xxxx-xxxx-xxxx-6d60b97262a7"
PROJECT_IDS: '["5eda705b22d41a54xxxxxxxx","5eda70b022d41a54xxxxxxxx","663c8a0d8f088ed7xxxxxxxx"]'
SYNC_INTERVAL: "30"
volumes:
- /home/pi/tickticktonotion_logs:/usr/src/app/logs
restart: always
Replace placeholders with your actual data:
your_ticktick_access_token_here with your TickTick access token.your_notion_token_here with your Notion token.your_notion_database_id_here with your Notion database ID.project_id1,project_id2,project_id3 with your TickTick project IDs.60 with your desired sync interval in seconds.your_image_name with your preferred Docker image name.This will start the process of syncing tasks from TickTick to your Notion database based on the configured environment variables.
sync_log.log file in your project directory for runtime logs..env file is loaded properly.Content type
Image
Digest
sha256:47971b250…
Size
49.7 MB
Last updated
over 2 years ago
docker pull xeyf/tickticktonotion