Triggers
Manual, schedule, webhook, channel message, and named events — all start real runs.
| Trigger | Fires when |
|---|---|
| trigger.manual | You click Run. |
| trigger.scheduler | A cron schedule matches (a 30s tick fires it). |
| trigger.webhook | POST /bb-workflows/api/webhook/:id with the right secret. |
| trigger.channel | A customer message lands on a chat channel. |
| trigger.event | A named event is emitted. |
Firing an event
From an agent, call the emit_event action. Externally, hit the emit endpoint:
bash
curl -X POST $HOST/bb-workflows/api/workflows/emit \
-H 'Content-Type: application/json' \
-d '{"event":"order.updated","payload":{"order_id":"A1"}}'Webhook triggers require a non-empty secret and compare it in constant time — a webhook with no secret refuses to run.