Install
openclaw skills install sleep-snoozeSnooze incoming notifications during your sleep window and receive a morning digest when you wake up. Supports Telegram, WhatsApp, and any provider OpenClaw is connected to.
openclaw skills install sleep-snoozeYou have a sleep notification snooze system available. When the user is in their sleep window, incoming messages should be silently queued rather than delivered immediately. At wake time, a morning digest is automatically sent summarising all queued messages.
The user's sleep schedule is configured via environment variables:
SLEEP_START — time to begin snoozing (24h format, e.g. 22:00)WAKE_TIME — time to deliver the digest and resume normal notifications (e.g. 06:00)TIMEZONE — IANA timezone (e.g. Asia/Kolkata, America/New_York, Europe/London)Users can invoke these slash commands directly in chat:
/sleep — manually activate sleep mode immediately (overrides schedule)/wake — manually deactivate sleep mode and trigger the morning digest now/snooze-status — show whether sleep mode is active, how many messages are queued, and what time the digest will be sent/snooze-setup — interactively configure sleep start time, wake time, and timezone/snooze-history — show the last 7 days of digest summariesBefore sending ANY message to the user — including proactive notifications, summaries, heartbeats, weekly recaps, stock alerts, backup confirmations, or any other automated report — first check sleep state:
node ~/.openclaw/skills/sleep-snooze/scripts/status.js
If isSleeping is true, do NOT send. Queue it instead (see below). This applies to both incoming messages from others AND outgoing messages you are about to send proactively.
When a message or notification arrives during the sleep window:
node ~/.openclaw/skills/sleep-snooze/scripts/queue-message.js with the message payload to store it in the local queue.When you (or any agent) are about to send a proactive message — status updates, recaps, reports, heartbeats — use gate.js instead of sending directly. It handles the sleep check and queuing automatically:
node ~/.openclaw/skills/sleep-snooze/scripts/gate.js \
--provider <provider> \
--sender-id <agent-id> \
--sender-name "<Agent Name>" \
--message "<full message text>"
Exit codes:
Use gate.js for ALL outgoing messages. It checks the actual current time against the schedule, so it works even if the sleep-mode cron did not run.
Some messages bypass snooze and are delivered immediately regardless of sleep hours. A message is considered urgent if any of the following match:
~/.openclaw/skills/sleep-snooze/data/vip-contacts.json)urgent, emergency, critical, 911, help meFor urgent messages: deliver normally, prepend 🚨 [URGENT - received during sleep] to the notification.
At WAKE_TIME each day, automatically:
node ~/.openclaw/skills/sleep-snooze/scripts/digest.js to generate and send the digest.Digest format (send as a single message per provider):
🌅 Good morning! Here's what arrived while you slept:
📬 3 messages from Alex
• "Hey are you free tomorrow?"
• "Also wanted to share this article..."
• "Never mind, talk later!"
📬 1 message from GitHub Notifications
• PR #42 was merged into main
📬 2 messages from Server Monitor Bot
• CPU spike at 03:14 — resolved
• Disk usage at 78% — check when available
Reply to any sender's name to respond to their messages.
When the user runs /snooze-setup for the first time:
date +%Z)node ~/.openclaw/skills/sleep-snooze/scripts/sleep-init.js to write config and register cron jobsSleep mode state is stored in ~/.openclaw/skills/sleep-snooze/data/state.json:
{
"sleepStart": "22:00",
"wakeTime": "06:00",
"timezone": "Asia/Kolkata",
"manualOverride": false,
"isSleeping": false,
"lastDigestAt": "2025-01-15T06:00:00.000Z"
}
The message queue is stored in SQLite at ~/.openclaw/skills/sleep-snooze/data/queue.db.