Skip to main content
Triggers automatically invoke agents in response to events. They enable autonomous workflows without manual intervention.

Available Trigger Types

Jira Triggers
Run agents when Jira issues are created or updated

Slack Triggers
Invoke agents from Slack mentions and commands

Linear Triggers
Execute agents when Linear issues are created

Cron Triggers
Schedule agents to run on a recurring basis

Webhook Triggers
Invoke agents via webhooks from any system

Email Triggers
Run agents when emails arrive at a dedicated address

How Triggers Work

When a trigger fires:
  1. The event payload is captured
  2. Your agent receives the event data as context
  3. The agent executes with access to relevant tools
  4. Results are logged and can be posted back to the source

Slack Triggers

Slack triggers allow you to invoke agents by @mentioning the Cotool bot in channels where it’s installed. In DMs, the bot can create personal chats or invoke agents depending on your trigger configuration.

Setting Up a Slack Trigger

  1. Navigate to your agent’s Triggers tab
  2. Click Add Trigger and select Slack
  3. Choose the channel(s) where the trigger should be active, or select “All Channels”
  4. Save the trigger
Once configured, @mentioning the Cotool bot in the specified channels will invoke your agent with the message content as context.

One Trigger Per Channel

Each Slack channel can only have one active trigger. This prevents conflicts where multiple agents could respond to the same @mention. What this means:
  • You can create multiple Slack triggers for different channels (e.g., one for #alerts, another for #support)
  • You cannot create two triggers that both include the same channel
  • An “All Channels” trigger cannot coexist with any other Slack trigger
Example configurations:
ConfigurationValid?
Trigger A: #alerts + Trigger B: #support✅ Yes
Trigger A: #alerts, #support + Trigger B: #incidents✅ Yes
Trigger A: #alerts + Trigger B: #alerts, #support❌ No (overlap on #alerts)
Trigger A: All Channels + Trigger B: #alerts❌ No (all channels conflicts)
If you need different agents for the same channel based on context (e.g., user groups or keywords), consider using a single trigger with conditional logic in your agent’s system prompt.

Thread Conversations (Re-entry)

When Cotool responds in Slack, users can continue the conversation by @mentioning Cotool in the same thread. This enables back-and-forth interactions without starting a new execution each time. How it works:
  • @mention Cotool in a thread that already has a Cotool response to continue that conversation
  • Both agent-triggered conversations and personal chats support thread re-entry
  • The conversation has full context of the previous messages in that thread
  • This allows for follow-up questions, clarifications, and iterative workflows
Note: An @mention is required for all interactions with Cotool, including thread re-entry. Simply replying in a thread without @mentioning will not trigger a response. Example flow (agent):
  1. User @mentions Cotool: “@Cotool investigate alert #12345”
  2. Agent responds with initial findings
  3. User replies in thread: “@Cotool can you check if this IP has been seen before?”
  4. Agent continues the same execution with the new request
Example flow (personal chat):
  1. User DMs Cotool: “@Cotool help me analyze this log file”
  2. Cotool responds with analysis
  3. User replies in thread: “@Cotool can you summarize the key findings?”
  4. Cotool continues the conversation and responds in the thread

Permissions

  • User matching: The Slack user’s email must match a Cotool account in your organization
  • Agent execution: Users must have the agent.execute permission for the specific agent to trigger or re-enter conversations
  • Thread ownership: Only users with appropriate permissions can continue agent conversations in threads

Response Buttons

Each Cotool response in Slack includes a button to view the full conversation in the web interface:
ModeButton
Personal chat (DM)Open Chat in Cotool
Agent triggerOpen Agent Run in Cotool
These buttons provide quick access to the full conversation context, tool outputs, and any visualizations in the Cotool web interface.

DM vs Channel Behavior

Direct Messages (DMs):
  • DMs always create a personal chat accessible via the web interface
  • Slack triggers do not apply to DMs—this ensures consistent, predictable behavior
  • Thread re-entry works for both personal chats and agent conversations (see below)
Channels:
  • @mentions in channels require a configured trigger for that channel
  • If no trigger is configured for the channel, users see a message prompting them to set up a trigger
  • This ensures public channel conversations are always handled by a configured agent with appropriate guardrails
This separation provides a clear mental model: DMs = personal assistant, Channels = agent workflows.

Thread Re-entry for Personal Chats

Personal chats (started via DM) support thread re-entry just like agent conversations:
  1. Start a conversation by @mentioning Cotool in a DM
  2. Cotool responds in a thread
  3. @mention Cotool in the thread to continue the conversation
  4. Cotool will respond directly in the Slack thread
Note: Only the original chat owner can continue personal chat conversations. The system verifies that the Slack user’s email matches the Cotool account that owns the chat.