opencode icon indicating copy to clipboard operation
opencode copied to clipboard

[FEATURE:] Add configurable hooks for custom commands on task events (similar to Claude Code)

Open Decade-qiu opened this issue 4 days ago • 1 comments

Feature hasn't been suggested before.

  • [x] I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

I would like to request support for configurable hooks, similar to the Hooks feature in Claude Code: https://code.claude.com/docs/en/hooks.

Hooks would allow users to define custom commands/scripts that automatically execute at specific points during a task's lifecycle, such as:

  • On successful task completion (e.g., run a notification script, trigger a deployment, or perform cleanup)
  • On task error/failure (e.g., send an alert, log details to an external service, or attempt automatic recovery)
  • When user confirmation is required (e.g., pause execution and run a custom command to prompt the user via another tool/integration)
  • more ......

Decade-qiu avatar Jan 10 '26 13:01 Decade-qiu