SentryResend

Email a digest of Sentry issues with Resend

A Sentry + Resend agent flow

Sentry's per-issue alerts work until you have enough of them, at which point they become noise and people set up a filter that buries the whole project. The signal you actually want at the team level is different: not every error, but a periodic readout of what's new and what's getting worse. This recipe builds that: your agent reads Sentry's open issues and sends a digest email through Resend, so the team gets one summary instead of a hundred alerts. It calls search_issues with a query you choose, unresolved issues above an event count in your production project, ranks them by volume or recency, and calls send-email with an HTML body listing the top issues, their counts, and links. Sentry answers when asked, so the agent runs the digest on a cadence, a daily roundup or one each release, rather than emailing per error.

The flow

Sentrysearch_issues

Searches for grouped issues/problems in Sentry, returning a list of issues.

Resendsend-email

Sends a single transactional email immediately or scheduled, with HTML/text, attachments, CC/BCC, and tags.

Step by step

  1. Define the digest query

    Tell the agent the Sentry org and project and a search filter: unresolved issues, a level like error, and a minimum event count so single stray exceptions stay out of the email. Decide whether to rank by volume or by first-seen.

  2. Read the issues

    The agent calls search_issues with that query and gets back the grouped issues, each with a title, the culprit, the event count, and a permalink. It can call search_events for sharper counts over a window if you need them.

  3. Build the summary

    It sorts and trims to a top-N list, separates issues first seen since the last digest from ongoing ones, and composes an HTML body: a count headline, then a table of issue, count, and link.

  4. Send through Resend

    It calls send-email from your verified domain to the team list with that digest. If nothing cleared the bar in the window, it can skip the send or post a short 'no new high-volume issues' line.

Tell your agent

Every weekday at 9am, search Sentry for unresolved error-level issues in the prod project with more than 25 events in the last 24 hours. Rank them by event count, flag the ones first seen since yesterday, and send an email through Resend from alerts@acme.com to eng-digest@acme.com with a subject like 'Top Sentry issues: 8' and an HTML table of each issue's title, event count, first-seen, and Sentry link.

Setup

This flow needs both servers connected to your agent. Follow each install guide:

Worth knowing

  • send-email needs a verified sending domain with SPF and DKIM configured in Resend, or the digest is rejected or filtered as spam. Set that up once before depending on it.
  • search_issues returns grouped issues, not individual events, and its count is how many times the group fired. Threshold and rank on that group count, not on single occurrences, so the digest reflects real volume.
  • Sentry's search uses its own query syntax (is:unresolved, level:error, project:). Spell the filter out for the agent so it doesn't guess and pull resolved issues or the wrong project into the email.

Questions

How is this different from Sentry's own alert rules?
Sentry alerts are per-issue and real-time, which is exactly what becomes noise at scale. This is a periodic, ranked summary of the project as a whole, so the team gets perspective on what's worst rather than a stream of individual notifications.
Does it email the instant an error spikes?
No. Sentry responds to the agent's call, it doesn't push. The digest is built on the schedule you set, so it trails real time; for spike detection, keep Sentry's native alerts and use this for the periodic readout.