Track 04 · Multi-agent & integrationLesson 08 of 11

Agents started by events and schedules

Begin work from business events, not from someone opening a chat.

What you'll be able to do

What you'll be able to do

01
  1. Identify the trigger sources in a customer's estate (events, webhooks, CDC, queues, schedules, file drops, email) and choose one per use case.
  2. Design an event envelope with stable IDs, a business key and a version, using CloudEvents attributes where they fit.
  3. Implement an idempotent consumer for at-least-once delivery, with bounded retries and a dead-letter queue.
  4. Design ordering, fan-out and debouncing so a burst of correlated events starts the right amount of agent work, once.
  5. Avoid the scheduling pitfalls (time zones, overlapping runs, catch-up after an outage) and hand work to a durable workflow safely.
  6. Defend which inputs may start an agent at all, in front of a security reviewer.
Before you start

Before you start

The short version

The short version

In production, agents rarely start because a person typed into a chat window. They start because something happened: SAP marked a container as delayed, a ServiceNow incident was reassigned, a customs file landed in an SFTP folder, or a schedule said "every 15 minutes, re-check open exceptions". The trigger layer turns those signals into agent work, and it has to do so exactly once in effect, even though almost every delivery mechanism delivers at least once, sometimes out of order, sometimes in bursts of hundreds. So you design an event envelope with a stable ID and a business key, make every consumer idempotent, bound retries and park poison messages in a dead-letter queue, keep ordering only where the business needs it, group correlated bursts before they fan out, run schedules with explicit time zones and overlap policies, and hand each unit of work to a durable workflow whose ID makes duplicates impossible. And you decide, in writing, what is never allowed to trigger an agent.

Key takeaways:

  • Assume at-least-once delivery everywhere. Idempotency is the consumer's job.
  • The deduplication key is the event's identity (source plus ID), and the workflow ID is the business identity. You need both.
  • Order per business key, not globally. Global ordering is expensive and rarely needed.
  • Debounce correlated bursts: one vessel re-sequence should start one batch, not 180 crews.
  • Every schedule needs a time zone, an overlap policy and a catch-up policy written down.

Pro lesson

The rest of this lesson is in Pro.

The mental model, worked example, field note, failure table, exercise and self-check, with the voice tutor.

  • Every stage and specialisation, in full
  • Every lab and every role project
  • Halden weeks 2–10, on your record
  • Every drill, live in the playground
  • All solutions, plus the server judge
  • Lab Assistant and every Teach with AI