Prerequisites
- An agent with a working model. See create and configure an agent.
- A publicly reachable API, or a tunnel to your local one — the sending system has to be able to reach the webhook URL.
- An access token as
AGENTAREA_TOKENand the API base URL asAGENTAREA_URL.
Steps
Create the trigger
Omit A request there is recorded in the trigger’s own event
stream before anything else happens.
webhook_id and the platform generates one with
secrets.token_urlsafe(16). Let it — a generated id is unguessable, and for
an unverified webhook the URL is the only thing standing between the agent
and the internet.The response carries both
webhook_id and webhook_url — the full
address, ready to give the sending system:Turn on signature verification
Configure the secret the provider signs with, then point the trigger at it:For Those three values are the defaults.
generic webhooks the HMAC details are configurable, because the sender
is whatever you wrote:signature_algorithm is one of sha1,
sha256, sha384 or sha512; any other value is refused with 422 when the
trigger is saved. slack, github, discord (Ed25519),
linear and stripe ignore them and use their provider’s scheme. Telegram
is validated by bot token at a different layer.Point the sending system at the URL
Register the URL wherever the events come from — a GitHub repository webhook,
a Stripe endpoint, your own service.
Only Telegram registers its inbound webhook with the provider automatically.
Every other channel is a manual step, and nothing in the platform reports
that you skipped it.
Send a test delivery
Use the provider’s own “redeliver” or “send test” button where one exists —
it exercises the real signature path, which a hand-rolled A request that passes method, signature, and size checks gets The same request repeated with the same provider delivery id (GitHub’s
curl does not.For a generic webhook with no secret configured yet:202 back
immediately:X-GitHub-Delivery, Stripe’s id, a webhook-id or Idempotency-Key
header, and a few others) gets 202 again with "status": "duplicate"
and the same sequence, instead of a second row and a second task. A
provider with none of those is never deduplicated — every delivery gets a
fresh sequence. A burst over AGENTAREA_EVENT_WRITE_QUOTA gets 429; a
body over 256 KiB gets 413.Verify
The trigger’s execution history records every delivery that actually reached condition evaluation, including ones that produced no task:status: "success" with a task_id means the delivery started a task. status: "success" with task_id: null means validation passed and the conditions
declined — the trigger is working and deliberately filtering.TriggerService ever evaluates conditions: an event filtered out by
event_types, a trigger that is paused or disabled, and a configurer who lost
access to the agent. All three still show up as the stream’s own record — read
stream_id off the trigger (GET .../triggers/$TRIGGER_ID returns it), then:
outcomes is empty when no subscription’s filter matched the event at all;
otherwise it carries a verdict (reacted, skipped, error) and reason
per subscription, independent of whether a task execution record exists. The
same list, with the trigger’s name and a link to any task it created, is on
the workspace’s Events page.
Troubleshooting
Signature verification failed
Signature verification failed
A signing secret is configured and the signature did not match. The most
common cause is the body: the signature is computed over the exact raw bytes,
so any proxy that re-serializes JSON between the provider and the API
invalidates it. The same response is returned when a secret is configured but
the raw body was unavailable to verify.
Method ... not allowed
Method ... not allowed
allowed_methods defaults to ["POST"] and is checked before signature and
validation. A provider that sends PUT, or a browser preflight, is rejected
here.The delivery was accepted (202) but no task appears
The delivery was accepted (202) but no task appears
Check the stream’s events (see Verify) before assuming a bug —
three different things look like this and each has a different cause:
- The conditions declined. Conditions with no explicit
typeare evaluated by a model against the payload once the dispatcher reaches the event, so the verdict is a judgement, not a rule mismatch. The execution record exists; readtrigger_dataon it, orreasonon the stream’s outcome, to see exactly what the model was shown. event_typesfiltered it out. The subscription only sees the kinds it names; an event of any other kind gets no outcome at all for this trigger, and no execution record — “nobody listened,” not a failure.- The trigger is paused or disabled. The event is still recorded and
the dispatcher still reaches it, but a trigger whose
is_activeis false is skipped before conditions are ever evaluated — no execution record, only askippedoutcome on the stream.
The webhook keeps answering 202, but the trigger stopped firing
The webhook keeps answering 202, but the trigger stopped firing
Crossing Re-enabling does not replay what was skipped while it was off — only
events the dispatcher reaches from then on fire.
failure_threshold consecutive failures disables the trigger —
but it does not touch the webhook source. Deliveries are still recorded
and still answered 202; only the firing is skipped. Nothing re-enables
the trigger automatically:429 on a burst of deliveries
429 on a burst of deliveries
The workspace crossed
AGENTAREA_EVENT_WRITE_QUOTA events in the trailing
minute — counted across every stream the workspace owns, not just this
one, so a quiet second stream does not help. A provider’s own retry
handles an occasional 429; a sustained one means the deployment’s
AGENTAREA_EVENT_WRITE_QUOTA needs raising. See
Configuration.413 Payload Too Large
413 Payload Too Large
The request body is over 256 KiB after headers and query parameters that
look like credentials are stripped. Send a reference to a workspace file
instead of the content itself.
I set webhook_type and assumed it was secured
I set webhook_type and assumed it was secured
It is not. The type selects which verifier runs, not whether one runs.
Verification begins only once a signing secret resolves from
webhook_config or validation_rules.Related
Triggers and channels
The model behind this, and what it does not cover.
Event streams
The journal a delivery lands in, and who else can read it.
Schedule an agent
The other way a task starts without a person.
Debug a failed task
When the delivery worked and the task did not.
Errors
What the API returns, and what is safe to retry.