How do I test Sentry issue alerts about error spikes before a real incident?
Tares lets you test Sentry issue alerts by posting a sample payload to the source’s ingest URL, then checking Recent events and Fields on the source page. Sentry reaches Tares through the webhook connector and a vendor setup, and Tares has no connector of its own for Sentry today. The test shows whether your label mapping and event type work before an error spike fires a real alert.
How it works
Sentry sends issue and error alerts to a Tares webhook source. Each delivery is stored lossless, and the labels you declare map payload fields into the event so you can correlate on them. This is the same flow as any other webhook source, so the inbound webhook connector page applies in full.
- Sentry posts a JSON body with the top-level fields
action,installation,dataandactor. The resource, such as an issue or an error, is named in theSentry-Hook-Resourceheader and not in the body. actionis a top-level field, so it can be theevent_type_field. Labels andtext_templateread payload fields by name.- Sentry signs its deliveries. On the Tares side you set
signature_schemetohmac_sha256,signature_headertoSentry-Hook-Signatureandsigning_secretto the integration Client Secret. The signature is the authentication for this source. - For a push source, the
test_sourcetool takes no payload and only returns the ingest endpoint. It does not check your label mapping, so you test by posting a payload yourself.
The signing options are described only in the release notes, not on the webhook connector page.
Set it up
- Create a webhook source for Sentry. Ask a connected agent to create it with
create_source, or use Sources, Add source, webhook. Declare a label for each payload field you want to correlate on and mark one asprimary. For the first test, leave the signing options out so a hand-made post is a clean check of the mapping.
- name: sentry-issues
connector: webhook
config:
event_type_field: action
labels:
- { name: action, field: action, primary: true }- Copy the ingest endpoint from the source page. If you ask an agent to run
test_source, expect only that endpoint back. - Post a sample payload shaped like a Sentry delivery to the ingest URL.
curl -X POST http://localhost:8787/ingest/<ingest_key> \
-H 'Content-Type: application/json' \
-d '{"action": "created", "installation": {"uuid": "test"}, "data": {}, "actor": {"type": "application", "id": 1, "name": "Sentry"}}'- Open the source page. In Recent events, confirm the event appears with the event type
createdand your label values. In Fields, confirm which payload fields arrive and how often, and pick a reliable primary label from them. - Adjust labels or
text_templateand post again until the event reads the way you want on the timeline. - Connect Sentry. Under Settings, Developer Settings, add an integration and set its Webhook URL to the Tares ingest URL. Subscribe it to issues or errors, and turn on Alert Action so your alert rules can call it.
- Add the signing options to the source, using the integration Client Secret.
- name: sentry-issues
connector: webhook
config:
event_type_field: action
signature_scheme: hmac_sha256
signature_header: Sentry-Hook-Signature
signing_secret: <client-secret>
labels:
- { name: action, field: action, primary: true }- Trigger a test alert from a Sentry alert rule that uses the integration, and check Recent events again. This confirms the live path from Sentry end to end.
What you get
- A tested label mapping, so the first real error spike lands with the labels you correlate on.
- A visible event on the timeline for each delivery, with the full Sentry payload kept as received.
- A Fields view that shows which payload fields arrive, so you choose the key from evidence.
- A source that Sentry signs, with the Client Secret as the credential, so no separate credential is needed on the Tares side.
- Confidence that the source works before an incident, since you have seen an event arrive from a sample and from Sentry itself.
When something else fits
- If your error alerts reach you through Prometheus and Alertmanager, use the Alertmanager connector. It fans a batch out into one event per alert and is verified the same way, with a test post and Recent events.
- If you want to plan how Tares watches and escalates across all your sources, start from AI SRE and come back to this page for the Sentry source.