Why this matters
The premise of Agentry is that you let your own agent loop on your data — investigate cases, toggle flags, create cohorts, configure replay strategies. That’s powerful. It’s also, reasonably, a little uncomfortable.
The healthiest pattern is don’t trust, verify — but verify in a 60-second weekly digest, not by reading 700 audit-log rows. Once a week the Routine pulls everything the agent (or anyone with your agk_) changed, buckets by category, and posts a digest to a Slack channel. You scan it in a coffee, spot anything weird, click in if needed.
This is the same pattern site reliability teams use for “weekly toil report” — except Agentry already has the audit table, so the implementation is one prompt.
What you get
- A Friday-afternoon Slack post summarizing the week
- Categorized counts (X flags created, Y cases resolved, Z surveys, etc.)
- A link to the full audit log if you want to drill in
- Trend vs the previous week (was activity higher or lower than usual?)
Walk through it
Set up a Routine that runs every Friday at 4pm. Read the audit log for the past 7 days. Summarize agent actions by category: cases resolved, flags toggled, surveys created, etc. Slack me the digest at https://hooks.slack.com/services/T0000/B_digest/X.
Webhook first, then schedule.
agentry_register_webhook {
project_id: "default",
url: "https://hooks.slack.com/services/T0000/B_digest/X",
description: "Weekly agent digest",
events: ["routine.weekly_digest"]
}
{ "webhook_id": "wh_digest", "signing_secret": "agws_…", "active": true }
Now the cron. Friday 4pm UTC → 0 16 * * 5. The prompt below pulls the audit log, buckets, posts.
/schedule "0 16 * * 5" "
1. Call agentry_recent_changes { hours: 168 } to get 7d of audit events.
2. Group by action_prefix:
- case.* → cases (resolved, marked spurious, reopened, suppressed)
- feature_flag.* → flags (created, updated, deleted, rolled out)
- cohort.* → cohorts
- survey.* → surveys
- publication.* → published queries
- session_replay.* → replay config changes
3. Count totals and identify any high-impact one-offs (deletes, mass suppression rules).
4. Also call agentry_recent_changes { hours: 336 } and compute week-vs-prior-week deltas.
5. POST a Slack message to wh_digest with:
- Header: \"This week, the agent (rt_digest) did:\"
- Per-category counts and deltas
- Any \"interesting\" rows (deletes, mass actions, things flagged as high-risk)
- Link to /audit page for full detail
"
{ "routine_id": "rt_digest", "next_run_at": "2026-05-22T16:00:00Z" }
Done. Routine rt_digest fires every Friday at 4pm UTC. First run is next Friday. Sample Slack message format:
📋 Weekly agent digest — May 12-18
This week your agent did:
CASES 42 (-12% vs prior week)
✓ resolved 28
✓ marked spurious 8
✓ reopened 4 ← worth a look (regressions?)
✓ suppressed 2
FLAGS 7 (+3 vs prior week)
✓ created 3 ★ coupon-ab-test, post-purchase-upsell, …
✓ updated 3
✓ deleted 1 ← old onboarding test, expected
COHORTS 2 (steady)
SURVEYS 1 (new — churn pulse)
PUBLICATIONS 5 (cart-funnel, refund-by-sku, push-funnel, …)
REPLAY CONFIG 0
Interesting:
- 4 reopened cases — agent re-investigated after a deploy.
Worth checking: were these regressions, or false-positive resolves?
- 1 publication revoked (last quarter's BFCM dashboard, expected)
Full audit log: https://agentry.sh/audit?since=7d
The output
weekly_digest Routine (rt_digest)
✓ Schedule: every Friday 16:00 UTC
✓ Webhook: wh_digest → #agentry-digest
✓ First run: 2026-05-22T16:00:00Z
✓ Action buckets: case.*, feature_flag.*, cohort.*, survey.*,
publication.*, session_replay.*
✓ Trend window: 7d vs prior 7d
Sample (next-Friday-style output):
This week your agent did:
CASES 42 (-12% vs prior week)
FLAGS 7 (+3)
COHORTS 2 (steady)
SURVEYS 1 (new — churn pulse)
PUBLICATIONS 5
REPLAY CONF 0
Interesting:
- 4 reopened cases ← regressions?
- 1 publication revoked (expected)
Audit detail: agentry.sh/audit?since=7d
Setting it up
The pieces:
1. The webhook target. Slack incoming webhook is easiest; Discord/Teams/PagerDuty work the same:
// Register once (or via MCP as shown above)
await fetch(`https://api.agentry.sh/v1/projects/${PROJECT_ID}/webhooks`, {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.AGENTRY_API_KEY}`,
"Content-Type": "application/json",
"User-Agent": "digest-setup/1.0", // REQUIRED — Cloudflare 403s default UAs
},
body: JSON.stringify({
url: "https://hooks.slack.com/services/T0000/B_digest/X",
description: "Weekly agent digest",
events: ["routine.weekly_digest"],
}),
});
2. The schedule. Friday-afternoon timezone-correct cron — 0 16 * * 5 for 4pm UTC. Adjust for your team’s timezone.
3. (Optional) Make the digest team-shareable. The default Slack post goes to one channel. If you have multiple teams (mobile, growth, ops) you may want one routine per team, each filtered to the actions that team cares about — e.g. growth team gets flag/cohort/survey events, ops team gets publication/replay/webhook events.
4. Tuning the digest. First couple of weeks the categories will surprise you. Edit the Routine prompt to add/remove buckets, change what counts as “interesting,” or include specific resource IDs.
Variations
- “Daily digest instead of weekly — sometimes the cadence needs to be tighter during an active launch.”
- “Per-team digest: split actions into the agent that took them (e.g. growth vs ops sessions) using audit metadata.”
- “Diff-mode: show me what changed compared to last week’s digest, not just the absolute counts.”
- “Email instead of Slack — for stakeholders who don’t live in Slack.”
- “Auto-investigate any ‘reopened case’ line: pull the case, summarize what happened post-resolve, include in the digest.”