Skip to main content

Integrations

Webhook Integration

Configure custom webhook integrations to connect Pingara with any external system, with payload formats, event types, authentication and testing strategies.

5 min readUpdated November 23, 2026

webhookapicustomintegration

Webhooks let you connect Pingara with any system that can receive HTTP POST requests, such as custom dashboards, ticketing systems, ChatOps bots, automation platforms, or your own backend services.

How Webhooks Work

When an alert condition is met, Pingara sends an HTTP POST request to your configured endpoint with a JSON payload containing all incident details.

Pingara detects incident
        ↓
POST https://your-endpoint.com/pingara-webhook
Content-Type: application/json
        ↓
Your system receives and processes the event

Setting Up a Webhook

Step 1: Prepare Your Endpoint

Create an HTTP endpoint that:

  • Accepts POST requests
  • Parses JSON request bodies
  • Returns a 2xx status code on success
  • Is publicly accessible from the internet

Example (Node.js/Express):

app.post('/pingara-webhook', (req, res) => {
  const event = req.body;
  console.log('Pingara event:', event.event, event.monitor.name);
  
  // Process the event...
  
  res.status(200).json({ received: true });
});

Step 2: Add the Webhook in Pingara

  1. Go to Settings → Alert policies → [Your Policy]
  2. Click Add channel
  3. Select Webhook
  4. Enter your endpoint URL
  5. Click Save

Step 3: Test the Webhook

Click Send test to send a sample event to your endpoint. Verify:

  • Your endpoint receives the request
  • The JSON payload is parsed correctly
  • Your endpoint returns 200 OK

Payload Format

Standard Payload Structure

Every incident-related webhook event follows this structure. monitor carries only id, name and url, with no status or region, so infer the status from the event name. incident only carries the fields below; there is no status, startedAt, resolvedAt, or performance metrics block, and there is no top-level organization object:

{
  "event": "incident.created",
  "timestamp": "2024-01-15T14:32:05.000Z",
  "monitor": {
    "id": "m1aa2b3c4d5e6f",
    "name": "API Production",
    "url": "https://api.example.com/health"
  },
  "incident": {
    "id": "i9zz8y7x6w5v4u",
    "errorType": "timeout",
    "errorMessage": "Connection timeout after 30000ms",
    "affectedRegions": ["us-east-1", "eu-west-1"],
    "passingRegions": ["ap-southeast-1"]
  }
}

incident.passingRegions is always an array, right after affectedRegions: the regions whose latest checks were healthy when the incident opened (on a recovery, the regions that confirmed it). It is never every configured region that is not failing, and a region failing now is never in it. On incident.resolved, affectedRegions lists the regions that were failing, so a region that recovered can be in both. It is [] for a monitor with one region, for an incident with no verdict, or when nothing is left. It is on the same payloads that carry the top-level verdict key and absent on the others. Webhook subscription events are unchanged.

incident.duration (a formatted string like "12 mins, 4 secs", not a number of seconds) is only present on incident.resolved and incident.escalated events. incident.escalationCount and incident.escalationSeverity are only present on incident.escalated. All three are omitted entirely, not sent as null, when they don't apply.

incident.escalationSeverity is "down" or "degraded", placed right after escalationCount. It says which kind of incident the escalation is about: a down incident is "down", and a slow, content-check-degraded or up-but-broken incident is "degraded". It is the same value the escalation email uses for "still down", "still degraded" or "still broken", and the one that decides which alert settings the escalation follows. A consumer that ignores it keeps working.

The verdict field

Incident payloads carry a top-level verdict object that says what kind of problem Pingara found, in a form your code can branch on. It is additive: every key above is unchanged, and the event names are unchanged. There is no new event for a page that loads but is broken. It arrives as incident.created or incident.degraded, with a verdict.code that tells you which. An incident.escalated payload repeats the incident's current verdict: the one it opened with, or the down verdict if a degraded incident became an outage. On a recovery, verdict.regions.passing and verdict.regions.failing never share a region: a region that confirmed the recovery is in passing only, and one that is still failing or still over the slow threshold is in failing only. The same holds for data.verdict on webhook subscription events.

{
  "event": "incident.created",
  "timestamp": "2024-01-15T14:32:05.000Z",
  "monitor": { "id": "m1aa2b3c4d5e6f", "name": "API Production", "url": "https://api.example.com/health" },
  "incident": { "id": "i9zz8y7x6w5v4u", "errorType": "timeout", "errorMessage": "Connection timeout after 30000ms", "affectedRegions": ["us-east-1", "eu-west-1"] },
  "verdict": {
    "version": 1,
    "code": "down",
    "reason": "timeout",
    "headline": "Down: the request timed out from 2 of 4 regions.",
    "confidence": "confirmed",
    "regions": {
      "failing": ["us-east-1", "eu-west-1"],
      "passing": ["us-west-2"],
      "configured": ["us-east-1", "us-west-2", "eu-west-1", "ap-southeast-1"]
    },
    "evidence": []
  }
}
FieldTypeMeaning
versionnumberThe shape of this object. Currently 1
codestringOne of down, up_but_broken, content_check_failed, slow, blocked, recovered. There is no partial value. blocked is reserved and is not sent today
reasonstring or nullThe cause within the code, see below. null for slow, blocked and a recovered verdict from a system resolve
headlinestringOne sentence, at most 240 characters, suitable to show a person
confidencestringconfirmed, or likely when the cause is a lower-confidence signal or the monitor has only one region
regionsobjectfailing, passing and configured, each an array of region ids
evidencearray of stringsAt most 3 lines, each at most 200 characters. Fixed wording, numbers and region ids, never text from your page and never the error message. A down, slow or content_check_failed verdict has at most one line, Last check returned status 503., and only when the check had a status code. A timeout or a DNS failure has none, so the array is empty. A down verdict whose reason is tls can have one fixed sentence that names the certificate problem instead, and one whose reason is other can have the TLS 1.2 sentence, see below. incident.resolved has none

Reasons by code. down: dns, connection_refused, timeout, tls, status_code, other. up_but_broken: error_page, maintenance_page, login_redirect, asset_failing, content_lost, landmarks_lost. content_check_failed: keyword_missing, keyword_found, keyword_unverified, body_too_small. recovered: resolved_by_person, only when a person resolved the incident.

  • incident.resolved carries code: "recovered". When Pingara resolves the incident itself, reason is null and the headline is Recovered: checks pass again. Its regions are worked out when the incident resolves: passing is the regions that meet the recovery threshold, failing the regions still failing, and configured every region on the monitor. A region that is dark, or has no recent result, appears only in configured, so passing and failing do not always add up to configured. When a person resolves the incident, reason is resolved_by_person, the headline is Resolved by your team. Pingara has not confirmed that checks pass., passing and failing are both empty and configured lists every region on the monitor.

  • When an incident opens, passing lists only the regions whose latest check was healthy. For a down incident that is a check that succeeded. For a degraded incident it is a check that succeeded within your response-time threshold and with its content checks passing. A region that is dark or stale, or whose latest check was not healthy, appears only in configured, so passing and failing do not always add up to configured there either.

  • A down verdict with reason tls says which certificate problem it was, when Pingara can tell. evidence then holds one fixed sentence, chosen from a short list and never copied from your server. Seven problems can be named:

    • The certificate, or one in its chain, has expired.
    • The certificate, or one in its chain, is not valid yet.
    • The certificate is not valid for the host name or address the check connected to.
    • The certificate is self-signed, so it is not trusted.
    • The certificate's issuer is not trusted, or the server did not send its intermediate certificate.
    • The certificate, or one in its chain, uses a key or signature that is too weak.
    • The server did not agree to use TLS 1.2 or newer.

    The last two need a newer probe build than the first five, so they appear once every region runs it. The line for a server that will not use TLS 1.2 or newer appears on a down verdict whose reason is other (errorType network_error), not tls, because that failure is not a certificate problem. The sentence describes the check that opened the incident, so after you change the certificate, check the monitor's latest results. When the problem is not one of these, evidence is empty as before. The headline, reason and event names do not change, and the sentence is for a person to read, so branch on code and reason, not on it.

  • verdict is null for an incident that was opened before this field existed.

  • Only payloads about an incident carry it. SSL certificate expiry reminders (ssl.expiring), domain.expiring, monitor.paused, monitor.resumed, the monitoring-interruption events and test sends have no verdict key. Read it only when it is present.

  • up_but_broken is the verdict code for a page that loads but is broken. See Broken-page detection.

Event Types

EventTriggerIncident field present
incident.createdAn incident enters the down state, either opened fresh (2 consecutive failures, quorum-confirmed) or as an already-open degraded incident promoted to down. Same event either way; there is no separate "promoted" eventYes
incident.degradedNew incident opened for a degraded transition, from sustained slow responses or a keyword mismatch on a monitor whose keyword-failure severity is DegradedYes
incident.resolvedIncident resolved automatically (2 consecutive successes, quorum-confirmed)Yes, includes duration
incident.escalatedAn unacknowledged incident reaches its next escalation step. Escalation is keyed on the incident still being open and unacknowledged, not on its severity, so a degraded incident escalates on the same schedule as a down one. Whether the notice is sent follows the setting of the alert it follows up (down or degraded)Yes, includes duration, escalationCount and escalationSeverity
ssl.expiringA certificate crosses a configured expiry-warning thresholdNo, an ssl block instead
domain.expiringA monitored domain's registration crosses a configured expiry-warning thresholdNo, a domain block instead
monitor.pausedMonitor was pausedNo
monitor.resumedMonitor was resumedNo
monitor.monitoring_interruptedEvery probe region configured for this monitor is in a confirmed blackout, so Pingara cannot check it. This says nothing about your endpointYes, an incident-shaped block with errorType: "monitoring_interrupted", but there is no incident record behind it
monitor.monitoring_resumedThe probe regions came back and checks are running againYes, same shape, errorType: "monitoring_interrupted"

There is no incident.updated event. A manual status change (Investigating → Identified → Monitoring) doesn't dispatch a webhook. See Understanding Incidents for what manual status changes do and don't notify.

Event-Specific Payloads

incident.resolved:

{
  "event": "incident.resolved",
  "timestamp": "2024-01-15T14:44:00.000Z",
  "monitor": {
    "id": "m1aa2b3c4d5e6f",
    "name": "API Production",
    "url": "https://api.example.com/health"
  },
  "incident": {
    "id": "i9zz8y7x6w5v4u",
    "errorType": "timeout",
    "errorMessage": "Connection timeout after 30000ms",
    "affectedRegions": ["us-east-1", "eu-west-1"],
    "duration": "12 mins, 4 secs"
  }
}

ssl.expiring:

{
  "event": "ssl.expiring",
  "timestamp": "2024-01-15T00:00:00.000Z",
  "monitor": {
    "id": "m1aa2b3c4d5e6f",
    "name": "API Production",
    "url": "https://api.example.com"
  },
  "ssl": {
    "daysUntilExpiry": 14,
    "issue": "certificate_expiring",
    "recommendation": "Renew the certificate before expiry and verify automatic renewal is active."
  }
}

There is no expiresAt or issuer field in this payload. If you need the certificate's absolute expiry timestamp, read sslExpiresAt for the monitor from the Developer API instead of trying to derive it from daysUntilExpiry. A webhook subscription's ssl.expiring event, a different feature from this alert channel, does carry data.ssl.expiresAt directly, as epoch milliseconds.

domain.expiring:

{
  "event": "domain.expiring",
  "timestamp": "2024-01-15T00:00:00.000Z",
  "monitor": {
    "id": "m1aa2b3c4d5e6f",
    "name": "API Production",
    "url": "https://api.example.com"
  },
  "domain": {
    "name": "example.com",
    "daysUntilExpiry": 14,
    "issue": "registration_expiring",
    "recommendation": "Renew the domain at the registrar, and check that auto-renew is on and the payment method on file is current."
  }
}

An already-lapsed domain sends "issue": "registration_expired" with a negative daysUntilExpiry instead. That's channel-only wording. A webhook subscription's domain.expiring event signals the same lapse with data.domain.milestone: 0.

Authentication

Pingara does not sign or authenticate outgoing webhook requests today. There is no shared-secret header, no bearer token, and no way to configure custom headers on a webhook channel. The only headers a delivery carries are Content-Type: application/json and User-Agent: Pingara-Webhook/1.0, and the latter is trivially spoofable, so don't rely on it as proof a request came from Pingara.

The practical mitigation available today is to keep your endpoint URL private and hard to guess, using a long random path segment rather than a predictable one like /pingara-webhook. Anyone who has the URL can post to it, so treat it like a credential: don't log it, commit it, or share it outside your team.

If verified webhook signing matters for your integration, email support@pingara.io. It isn't available yet, but we'd like to know it's blocking you.

Retry Behavior

If your endpoint fails in a way that might clear on its own, Pingara retries the webhook up to 3 times after the initial attempt (4 attempts total):

AttemptDelay after previous attempt
Initial attempt-
1st retry1 minute
2nd retry5 minutes
3rd retry (final)15 minutes

Not every failure is retried. Pingara classifies the response first, and only retries what could plausibly succeed later:

ResponseRetried?
5xx (server error)Yes
408 (request timeout), 429 (rate limited)Yes
Connection error, timeout, no responseYes
3xx (redirect)No, a redirected webhook delivery is refused outright, never followed
Any other 4xx (400, 401, 403, 404, …)No, a bad URL, payload or credential won't fix itself in 21 minutes

A non-retried failure is marked failed immediately, after a single attempt, so if your endpoint answers 404 while you're deploying, you get one delivery attempt and no more. After the final retry of a retried failure fails, the notification is likewise marked as failed in the notification history.

Handling Retries

Your endpoint should be idempotent. Processing the same event twice should be safe. Use the incident.id and event fields to deduplicate:

const processedEvents = new Set();

app.post('/pingara-webhook', (req, res) => {
  const eventKey = `${req.body.incident?.id}-${req.body.event}`;
  
  if (processedEvents.has(eventKey)) {
    return res.status(200).json({ status: 'already_processed' });
  }
  
  processedEvents.add(eventKey);
  // Process the event...
  
  res.status(200).json({ received: true });
});

Common Integration Patterns

Create a Ticket on Incident

app.post('/pingara-webhook', async (req, res) => {
  if (req.body.event === 'incident.created') {
    await ticketSystem.create({
      title: `[Pingara] ${req.body.monitor.name} is down`,
      description: req.body.incident.errorMessage,
      priority: 'high',
      tags: ['monitoring', 'auto-created'],
    });
  }
  res.status(200).json({ received: true });
});

Post to a Custom Dashboard

app.post('/pingara-webhook', async (req, res) => {
  await dashboard.addEvent({
    source: 'pingara',
    type: req.body.event,
    monitor: req.body.monitor.name,
    timestamp: req.body.timestamp,
    errorType: req.body.incident?.errorType,
    duration: req.body.incident?.duration,
  });
  res.status(200).json({ received: true });
});

Trigger an Automated Remediation

app.post('/pingara-webhook', async (req, res) => {
  if (req.body.event === 'incident.created') {
    // Automatically restart the service
    await cloudProvider.restartService(req.body.monitor.name);
    console.log('Auto-remediation triggered for', req.body.monitor.name);
  }
  res.status(200).json({ received: true });
});

Testing Webhooks

Using the Test Button

Pingara's Send test button sends a realistic sample event to verify connectivity. The test payload uses dummy data but follows the exact same format as real events.

Using a Request Catcher

For development, use a request inspection tool:

  1. Go to webhook.site or requestbin.com
  2. Copy the unique URL
  3. Add it as a webhook endpoint in Pingara
  4. Send a test and inspect the full request

Local Development

Use a tunnel service like ngrok to test webhooks locally:

ngrok http 3000
# Use the generated https URL as your webhook endpoint

Troubleshooting

Webhook Not Firing

  1. Check alert policy - Is the webhook channel enabled?
  2. Check triggers - Is the event type enabled (Down, Recovery, etc.)?
  3. Check monitor link - Is the policy linked to the monitor?

Receiving 4xx/5xx Errors

  • 401/403 - Authentication failed. Verify your secret/token.
  • 404 - Endpoint URL is wrong. Check the path.
  • 500 - Your server has a bug. Check server logs.
  • Timeout - Your endpoint is too slow. Respond within 10 seconds.

Payload Parsing Errors

Ensure your endpoint:

  • Sets Content-Type: application/json middleware
  • Parses the JSON body correctly
  • Handles missing optional fields gracefully

Next Steps

Related Articles

Integrations5 min

Slack Integration

Set up Slack webhook integration to receive rich, formatted Pingara alerts directly in your Slack channels with incident details and quick action links.

Alerts6 min

Alert Channels

Configure notification channels including Email, Slack, Microsoft Teams, Discord, webhooks, and PagerDuty to receive Pingara alerts wherever your team works.

Alerts6 min

Setting Up Alerts

Learn how to create alert policies, configure notification rules, and ensure your team is always informed when monitors detect issues.