Run agents on schedules, events, webhooks, chat mentions or on demand.
triggers:
- type: schedule
cron: "0 7 * * 1-5"
timezone: Europe/Helsinki
- type: email.received
mailbox: invoices@
- type: event
source: zendesk
event: ticket.created
- type: webhook
# POST https://api.brewmycode.com/v1/agents/{id}/trigger with the agent's webhook secret
- type: mention
channels: ["#finance-agent"]
- type: manual
| Trigger | Starts a run when |
|---|---|
schedule | A cron expression fires |
email.received | A message arrives in a connected mailbox (optionally filtered by sender, subject, attachment type) |
event | A connected system emits an event: new ticket, new deal, file added, row inserted… |
webhook | Your system calls the agent's webhook URL |
mention | Someone mentions the agent in an allowed channel |
manual | A user clicks Run or calls POST /agents/{id}/runs |
Triggers pass an input object to the run (the email, the ticket, the webhook body). The job can refer to it; tools can use it. Inputs are stored with the trace.
Event and email triggers deduplicate on the source item id, so a retried notification doesn't start a second run. Webhooks accept an optional Idempotency-Key.
For high-volume events, set batch: { size: 50, window: 10m } to process items in one run rather than one run per item.
BrewMy{Code} is a verified Zapier partner. The Zapier app exposes Run agent and Query knowledge base actions and Run completed / Approval requested triggers, so agents can be started from — and results pushed to — 7,000+ other apps.
Agents → (agent) → Runs lists runs by status and trigger. Set alerts for failed runs, hand-off rate and approval backlog under Alerts. Alerts deliver to Slack, Teams, email or a webhook.