How to get notified when Claude Code finishes a task
Four ways to stop watching your terminal while Claude Code works — a shell bell, a desktop notification, a push service, and a Live Activity. With the trade-offs of each.
Long agent runs created a problem nobody had two years ago: the work is happening, it is going to take a while, and there is nothing useful for you to do while it does. So you check. Then you check again. The checking costs more focus than the waiting.
Here are the four approaches people actually use, roughly in order of effort, and what each one gets wrong.
1. The terminal bell
The cheapest possible answer: make the shell make a noise when the command exits.
claude "refactor the auth module"; printf "\a"This works and costs nothing. It also only works if you are within earshot of the machine, tells you nothing about what happened, and cannot distinguish “finished” from “failed” or “stuck asking you a question twenty minutes ago”.
2. A desktop notification
One step up, on macOS:
claude "refactor the auth module"; osascript -e 'display notification "Claude Code finished" with title "Agent"'Better — it has text, and it persists in Notification Center. Still tied to being at the machine, which defeats most of the point. If you are at the machine, you can see the terminal.
3. Push to your phone with ntfy or Pushover
This is where most people land, and honestly it is a good answer:
claude "refactor the auth module"; curl -d "Claude Code done" ntfy.sh/my-agent-topicNow the signal reaches you anywhere. The limitation shows up when you scale past one agent or one event. Every update is a separate banner, so a chatty agent floods your Lock Screen and you end up muting it. And a notification is a moment, not a state — it can tell you something happened, but never what is happening now.
4. A Live Activity
The version that fits the shape of the problem: one live strip on the Lock Screen that updates in place while the agent runs, shows progress, turns amber when the agent needs an answer, and ends when the task ends. That is what Codeaton does, and it is why it models agents rather than messages.
The wiring is the same one line you were already writing, it just describes a state instead of a sentence:
curl -X POST https://codeaton.com/api/ingest \
-H "Authorization: Bearer $CODEATON_KEY" \
-H "Content-Type: application/json" \
-d '{"agentKey":"claude-code@laptop","type":"completed","message":"Refactored auth"}'Which one to use
- One agent, you only care about “done”: the bell or a push message is genuinely enough. Do not over-build this.
- Several agents, or long runs where an agent may stop and wait for you: a state-based surface is worth it, because the question you are asking is “what is happening”, not “did something happen”.
The general rule: match the tool to the question. Notifications answer “did it finish?” Live Activities answer “where is it?”