Skip to content

Commit 0b807ef

Browse files
committed
Add blog post on automating Todoist projects with Python
Introduces a new post detailing Python scripts for quickly building Todoist projects from JSON files. Updates the RSS feed with the new article, including setup instructions, workflow, and use cases for automation.
1 parent a6e2de8 commit 0b807ef

2 files changed

Lines changed: 240 additions & 1 deletion

File tree

public/feed.xml

Lines changed: 109 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,117 @@
55
<link>https://pythonessprogrammer.com</link>
66
<description>Thoughts on technology, accessibility, and the human experience.</description>
77
<language>en</language>
8-
<lastBuildDate>Wed, 29 Oct 2025 00:25:55 GMT</lastBuildDate>
8+
<lastBuildDate>Thu, 30 Oct 2025 18:41:52 GMT</lastBuildDate>
99
<atom:link href="https://pythonessprogrammer.com/feed.xml" rel="self" type="application/rss+xml" />
1010

11+
<item>
12+
<title><![CDATA[Automating New Projects in Todoist with Python]]></title>
13+
<link>https://pythonessprogrammer.com/blog/todoist-scripts</link>
14+
<guid>https://pythonessprogrammer.com/blog/todoist-scripts</guid>
15+
<pubDate>Thu, 30 Oct 2025 00:00:00 GMT</pubDate>
16+
<description><![CDATA[A small set of Python scripts that build out a complete Todoist project—sections, tasks, and sub‑tasks—from a simple JSON file.]]></description>
17+
<content:encoded><![CDATA[
18+
# Automating New Projects in Todoist with Python
19+
20+
Yesterday I built a small, friendly set of scripts to remove the friction of spinning up a new project in Todoist. Instead of clicking around to add sections and tasks, I now drop a short JSON file into a folder and run one command. Two minutes later, the whole project is ready for real work.
21+
22+
Repo: [devandapaige/todoist](https://github.com/devandapaige/todoist)
23+
24+
## What it does
25+
26+
- **Creates or reuses a project**: If a project with the same name exists, it adds to it rather than duplicating it.
27+
- **Builds structure fast**: Adds sections, tasks, and optional sub‑tasks from a plain JSON file.
28+
- **Keeps focus on your flow**: I designed this to reduce cognitive load at the exact moment I’m shifting into a new initiative.
29+
30+
## Why this matters for brain-and-energy aware work
31+
32+
The first few minutes of any project are decision-heavy. By externalizing the structure—what sections I use, which tasks always start a project—I protect my energy for the meaningful parts. This is a tiny automation that creates space for momentum and reduces startup anxiety.
33+
34+
## Quick start
35+
36+
1) Create a virtual environment and install deps
37+
38+
```bash
39+
python3 -m venv .venv
40+
source .venv/bin/activate
41+
python -m pip install --upgrade pip
42+
python -m pip install todoist-api-python python-dotenv
43+
```
44+
45+
2) Add your Todoist API token
46+
47+
```bash
48+
echo "TODOIST_API_TOKEN=your-token-here" > .env
49+
```
50+
51+
3) Define your project data
52+
53+
```json
54+
{
55+
"project_name": "Client Project Template",
56+
"sections": [
57+
{
58+
"name": "Planning",
59+
"tasks": [
60+
{
61+
"content": "Kickoff notes",
62+
"sub_tasks": [
63+
{ "content": "Confirm goals" },
64+
{ "content": "List stakeholders" }
65+
]
66+
},
67+
{ "content": "Define scope", "sub_tasks": [] }
68+
]
69+
},
70+
{
71+
"name": "Execution",
72+
"tasks": [ { "content": "Set up repo" }, { "content": "First milestone" } ]
73+
}
74+
]
75+
}
76+
```
77+
78+
4) Run the importer
79+
80+
```bash
81+
python import_to_todoist.py
82+
```
83+
84+
You’ll see progress logs as the project, sections, tasks, and sub‑tasks are created. If the project already exists, the script adds the new structure to it.
85+
86+
## Notes and tradeoffs
87+
88+
- The importer intentionally adds tasks each run; it doesn’t try to de‑duplicate similar items. That keeps the script simple and predictable when you’re iterating on templates.
89+
- Put the `.env` file next to `import_to_todoist.py`. The script loads it automatically.
90+
- If you prefer environment variables, export `TODOIST_API_TOKEN` instead of using `.env`.
91+
92+
## How I’m using it
93+
94+
- **Client onboarding**: One JSON per service offering; instant sections for Planning, Execution, Review.
95+
- **Content sprints**: A lightweight editorial checklist that appears with a single command.
96+
- **Studio maintenance**: Monthly admin projects with recurring cleanup tasks bundled in.
97+
98+
This isn’t flashy; it’s deliberately boring—in a good way. It removes the micro‑decisions that slow me down and lets me get to the work that actually needs my attention.
99+
100+
With digital care,
101+
102+
The Pythoness Programmer
103+
104+
<Signature />
105+
106+
Amanda
107+
108+
Reference: the full README, setup steps, and example JSON live in the repo: [devandapaige/todoist](https://github.com/devandapaige/todoist).
109+
110+
Find the code on GitHub: [devandapaige/todoist](https://github.com/devandapaige/todoist)
111+
112+
]]></content:encoded>
113+
<author>Amanda Nelson</author>
114+
<category>automation</category>
115+
<category>todoist</category>
116+
<category>python</category>
117+
<category>workflows</category>
118+
</item>
11119
<item>
12120
<title><![CDATA[Error-Proofing Your Automation: Building Resilient Digital Systems]]></title>
13121
<link>https://pythonessprogrammer.com/blog/error-proofing-your-automation</link>
Lines changed: 131 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,131 @@
1+
---
2+
title: "Automating New Projects in Todoist with Python"
3+
date: "2025-10-30"
4+
description: "A small set of Python scripts that build out a complete Todoist project—sections, tasks, and sub‑tasks—from a simple JSON file."
5+
author: "Amanda Nelson"
6+
tags: ["automation", "todoist", "python", "workflows"]
7+
image: "https://media.beehiiv.com/cdn-cgi/image/fit=scale-down,format=auto,onerror=redirect,quality=80/uploads/asset/file/b585a570-ef5f-4988-a0bf-752b4e2d2a95/Beehiiv_Banner.png?t=1746662710"
8+
---
9+
10+
# Automating New Projects in Todoist with Python
11+
12+
Yesterday I built a small, friendly set of scripts to remove the friction of spinning up a new project in Todoist. Instead of clicking around to add sections and tasks, I now drop a short JSON file into a folder and run one command. Two minutes later, the whole project is ready for real work.
13+
14+
Repo: [devandapaige/todoist](https://github.com/devandapaige/todoist)
15+
16+
## What it does
17+
18+
- **Creates or reuses a project**: If a project with the same name exists, it adds to it rather than duplicating it.
19+
- **Builds structure fast**: Adds sections, tasks, and optional sub‑tasks from a plain JSON file.
20+
- **Keeps focus on your flow**: I designed this to reduce cognitive load at the exact moment I’m shifting into a new initiative.
21+
22+
## Why this matters for brain-and-energy aware work
23+
24+
The first few minutes of any project are decision-heavy. By externalizing the structure—what sections I use, which tasks always start a project—I protect my energy for the meaningful parts. This is a tiny automation that creates space for momentum and reduces startup anxiety.
25+
26+
## Quick start
27+
28+
1) Create a virtual environment and install deps
29+
30+
```bash
31+
python3 -m venv .venv
32+
source .venv/bin/activate
33+
python -m pip install --upgrade pip
34+
python -m pip install todoist-api-python python-dotenv
35+
```
36+
37+
2) Add your Todoist API token
38+
39+
```bash
40+
echo "TODOIST_API_TOKEN=your-token-here" > .env
41+
```
42+
43+
3) Define your project data
44+
45+
```json
46+
{
47+
"project_name": "Client Project Template",
48+
"sections": [
49+
{
50+
"name": "Planning",
51+
"tasks": [
52+
{
53+
"content": "Kickoff notes",
54+
"sub_tasks": [
55+
{ "content": "Confirm goals" },
56+
{ "content": "List stakeholders" }
57+
]
58+
},
59+
{ "content": "Define scope", "sub_tasks": [] }
60+
]
61+
},
62+
{
63+
"name": "Execution",
64+
"tasks": [ { "content": "Set up repo" }, { "content": "First milestone" } ]
65+
}
66+
]
67+
}
68+
```
69+
70+
4) Run the importer
71+
72+
```bash
73+
python import_to_todoist.py
74+
```
75+
76+
You’ll see progress logs as the project, sections, tasks, and sub‑tasks are created. If the project already exists, the script adds the new structure to it.
77+
78+
## Notes and tradeoffs
79+
80+
- The importer intentionally adds tasks each run; it doesn’t try to de‑duplicate similar items. That keeps the script simple and predictable when you’re iterating on templates.
81+
- Put the `.env` file next to `import_to_todoist.py`. The script loads it automatically.
82+
- If you prefer environment variables, export `TODOIST_API_TOKEN` instead of using `.env`.
83+
84+
## How I’m using it
85+
86+
I turn long AI chats into actionable Todoist projects by asking the model for a single JSON payload in the importer’s format. I paste that JSON into `project_data.json` and run the script—done.
87+
88+
### Prompt I use (short and strict)
89+
90+
```text
91+
You are helping me turn our conversation into an actionable Todoist project.
92+
93+
Return ONLY valid JSON in this exact schema (no prose):
94+
{
95+
"project_name": "<short-name>",
96+
"sections": [
97+
{ "name": "<section>", "tasks": [
98+
{ "content": "<task>", "sub_tasks": [ { "content": "<subtask>" } ] }
99+
]}
100+
]
101+
}
102+
103+
Rules:
104+
- Use 3–6 sections that reflect this chat’s themes.
105+
- Each section: 3–7 tasks.
106+
- Use clear, verb-led task names.
107+
- Include sub_tasks only where they reduce ambiguity.
108+
- Do not include comments, markdown, or trailing commas.
109+
```
110+
111+
### Workflow
112+
113+
1. Summarize the chat in my head into 3–6 themes (sections).
114+
2. Run the prompt with a one‑line context: “Topic: `what we discussed`.”
115+
3. Paste result into `project_data.json`.
116+
4. `python import_to_todoist.py` to create the project.
117+
118+
This isn’t flashy; it’s deliberately boring—in a good way. It removes the micro‑decisions that slow me down and lets me get to the work that actually needs my attention.
119+
120+
With digital care,
121+
122+
The Pythoness Programmer
123+
124+
<Signature />
125+
126+
Amanda
127+
128+
Reference: the full README, setup steps, and example JSON live in the repo: [devandapaige/todoist](https://github.com/devandapaige/todoist).
129+
130+
Find the code on GitHub: [devandapaige/todoist](https://github.com/devandapaige/todoist)
131+

0 commit comments

Comments
 (0)