Skip to content
🎉 Launch sale:50% off everything over $22 — automatically applied at checkout· ends Aug 2Shop the sale →
DevOps AI ToolKit
Newsletter
All prompts
AI for Slack Difficulty: Intermediate ClaudeChatGPT

Slack Channel Archival Lifecycle Bot Prompt

Build a bot that detects stale or one-off channels (incident channels, temporary project rooms), warns owners, and archives them on a safe schedule to keep the workspace navigable without losing history.

Target user
Engineers building Slack workspace-automation bots
Difficulty
Intermediate
Tools
Claude, ChatGPT

The prompt

You are a senior platform engineer who builds Slack workspace-hygiene bots and has seen both channel sprawl and angry users whose active channel got archived from under them.

I will provide:
- Our channel naming conventions (e.g. inc-*, proj-*, temp-*) and which are meant to be ephemeral
- Signals available (last message time, member count, linked incident status, channel topic/purpose)
- Who owns archival decisions and how we want them notified

Your job:

1. **Define staleness rules** — per channel pattern, set explicit criteria for "candidate for archival" (e.g. inc-* with resolved incident + N days quiet) using only the signals I listed.
2. **Exempt the untouchable** — build an allowlist/label mechanism so pinned, compliance-hold, or owner-flagged channels are never auto-archived.
3. **Warn before acting** — design a grace-period notification to the channel and owner with a one-click "keep active" button that resets the timer.
4. **Archive, never delete** — use conversations.archive (which preserves history and is reversible) and explain why deletion is off the table.
5. **Make it dry-run-first** — the bot's default mode reports candidates without acting; enforcement is a separate, explicitly enabled mode.
6. **Audit every action** — log each warning, keep-alive, and archival with who/what/when, and post a periodic summary to an admin channel.

Output as: (a) the per-pattern staleness rule table, (b) the exemption mechanism, (c) the warning message with keep-active handler, (d) the archive call and reversal note, (e) the dry-run/enforce toggle and audit-log schema.

Default to dry-run and to warning over acting; archiving a channel someone still needs erodes trust faster than a little sprawl ever will.

Run this prompt with AI

Test it, get an AI-improved version, or compare models — live in the Prompt Workspace. No copy-paste.

Related prompts

More Slack prompts & error guides

Browse every Slack prompt and troubleshooting guide in one place.

Free download · 368-page PDF

Reading prompts? Get all 500 in one free PDF

500 battle-tested, copy-paste AI prompts engineered by a senior systems engineer — every one with fill-in placeholders and safety/back-out notes. Drop your email and it's yours.

  • 500 prompts: Linux · Kubernetes · Terraform · OpenStack · GitLab · Docker · Monitoring · Incident Response
  • Instant PDF download — yours free, forever
  • Plus one practical AI-workflow email a week (no spam)

Single opt-in · unsubscribe anytime · no spam.