Skip to content
Development
Hook

Hooks

What swarm runs automatically, and when. A hook is a command Claude Code fires at a fixed moment, without you asking for it.

From plugin
swarm
8513 skills2 agents10 commands2 hooks
Install
> /plugin marketplace add DheerG/swarms
> /plugin install swarm@swarms

Ships with swarm. Installing the plugin gets these hooks.

What fires, and when

SessionStart

Fires once when a session begins, and again after a context compaction. It is where a plugin sets up its environment, or restores state the compaction dropped.

  • Matchesstartup|resume|clearbash "${CLAUDE_PLUGIN_ROOT}/scripts/check-update.sh" "${CLAUDE_PLUGIN_ROOT}"

PreToolUse

  • MatchesSendMessagebash "${CLAUDE_PLUGIN_ROOT}/scripts/confirm-shutdown.sh"
Read hooks/hooks.json

In the plugin's words

How swarm describes its own hook set.

Swarm plugin hooks — update check on session start, shutdown gate on SendMessage
Ships withswarm

Describe what you want. Get a reviewed, ship-ready PR — without babysitting the agent.

Get the whole plugin