On a schedule
Archive monday.com items Done for 30 days
Every night, items that have sat in Done for more than 30 days are archived from a monday.com board, and you get an email listing them.
- Runs
- On a schedule
- Apps
- monday.com
- AI
- Not needed
- Access
- boards:read, boards:write
Send this to your assistant
Create a ClickRuntime automation: every night at 2am, find items on my Projects board in monday.com whose status has been Done for more than 30 days, archive them, and email me the list.
First time? Adding ClickRuntime to your assistant takes about two minutes.
Why use it
Why teams use this automation
Boards fill up with finished work. After a few months the Done group is longer than everything else and slows down scrolling, filtering and loading.
Archiving finished items after a month keeps the board focused on current work while leaving a grace period for recent wins and follow-ups.
Because the age comes from when the status changed to Done, items finished last week stay put even if they were created months ago.
What you get out of it
Lighter boards
Old finished items leave the board so current work is easier to see.
Recent work stays
Items stay on the board for 30 days after they are finished.
Nothing is lost
Archived items can be restored from monday.com at any time.
You see what moved
A nightly email lists every item that was archived.
Runs at night
Archiving happens at 2am, when nobody is working on the board.
How it works
What happens, step by step
Every night ClickRuntime reads every item on your board, page by page.
It checks when each Done item's status last changed.
Items that have been Done for more than 30 days are archived.
You get an email listing what was archived; archived items can be restored in monday.com.
Before it runs live
- Connect monday.com
What you get
Build your own
Need it to work differently?
Your own rules
Conditions, thresholds, filters and exceptions, written the way you'd explain them to a colleague.
Any number of apps
One automation can read from one app and update several others. Over 248 apps are ready, and anything with an API works too.
AI where it helps
Summaries, classification, extraction and drafts use ClickRuntime's built-in AI, with no extra key.
On a schedule or on each event
Runs as often as every 5 minutes, or the moment an app sends an event, and keeps track of what it already handled.
Changes you can ask for
- Run it at a different time, more or less often, or only on weekdays
- Add an AI step, for example to summarize, sort or draft a reply
- Add another app, for example also send it to Slack
- Combine it with other monday.com steps into one automation
Under the hood
The code that runs this automation
import json
from datetime import datetime, timedelta, timezone
from clickruntime import on_trigger, credentials, http, notify
BOARD, DAYS = 1234567890, 30
FIRST = """query ($board: [ID!]) { boards(ids: $board) { name items_page(limit: 500) { cursor
items { id name column_values(ids: ["status"]) { text value } } } } }"""
NEXT = """query ($cursor: String!) { next_items_page(limit: 500, cursor: $cursor) { cursor
items { id name column_values(ids: ["status"]) { text value } } } }"""
ARCHIVE = """mutation ($id: ID!) { archive_item(item_id: $id) { id } }"""
def monday(query, **variables):
resp = http.post("https://api.monday.com/v2", json={"query": query, "variables": variables},
headers={"Authorization": credentials.secret("MONDAY_API_TOKEN"), "API-Version": "2024-10"})
resp.raise_for_status()
return resp.json()["data"]
@on_trigger
def run(event):
board = monday(FIRST, board=[BOARD])["boards"][0]
page, items = board["items_page"], []
while True:
items += page["items"]
if not page["cursor"]:
break
page = monday(NEXT, cursor=page["cursor"])["next_items_page"]
cutoff = datetime.now(timezone.utc) - timedelta(days=DAYS)
archived = []
for i in items:
status = i["column_values"][0]
if status["text"] != "Done" or not status["value"]:
continue
changed = json.loads(status["value"]).get("changed_at")
if not changed:
continue
when = datetime.fromisoformat(changed.replace("Z", "+00:00"))
if when < cutoff:
monday(ARCHIVE, id=i["id"])
archived.append(f"• {i['name']} (Done since {when:%b %-d})")
if archived:
notify.email_me(f"Archived {len(archived)} old items from {board['name']}",
f"Archived {len(archived)} items that were Done for {DAYS}+ days:\n" + "\n".join(archived))
return {"archived": len(archived)}FAQ
Common questions
Are archived items deleted?
How does it know when an item was marked Done?
Can I use a different number of days or another status?
What permissions does it need?
Does it need AI?
How many runs does it use?
Can I change how it works?
Related
You might also like
Email yourself overdue monday.com items each morning
One morning email lists every item past its due date that isn't marked Done.
See how it worksSee the week's due dates grouped by owner
Each weekday morning you get everything due in the next seven days, sorted under the person responsible.
See how it worksBack up a monday.com board to CSV nightly
A CSV copy of the whole board, with every column, arrives in your inbox each night.
See how it worksKeep exploring
Set up “Archive monday.com items Done for 30 days” from your assistant
Copy the prompt above, or connect your assistant first. Free plan, no credit card.