Server Scout sends webhook notifications as HTTP POST requests with JSON payloads whenever alerts are triggered, resolved, or repeated. Understanding the payload structure allows you to integrate Server Scout with various notification systems and build custom handlers.
Payload Structure
Server Scout sends a standardised JSON payload to your webhook endpoint using Content-Type: application/json. The payload contains the following fields:
- text: Human-readable summary of the alert
- color: Hex colour code indicating severity
- server_name: Name of the monitored server
- metric: The monitored metric (CPU, memory, disk, etc.)
- current_value: Current value that triggered the alert
- threshold: Configured threshold that was breached
- operator: Comparison operator (>, <, >=, <=)
- severity: Alert severity level (warning, critical)
- status: Alert status (fired, resolved, reminder)
- timestamp: ISO 8601 timestamp when the alert occurred
Colour Coding
The color field uses the following hex codes based on alert status:
- Green (#36a64f): Resolved alerts
- Orange (#ff9500): Warning severity
- Red (#d63638): Critical severity
Example Payloads
Fired Alert
{
"text": "Critical Alert: CPU usage on web-server-01 is 95.2% (threshold: >= 90%)",
"color": "#d63638",
"server_name": "web-server-01",
"metric": "CPU usage",
"current_value": "95.2%",
"threshold": "90%",
"operator": ">=",
"severity": "critical",
"status": "fired",
"timestamp": "2024-01-15T14:30:22Z"
}
Resolved Alert
{
"text": "Resolved: CPU usage on web-server-01 is now 45.1% (was 95.2%)",
"color": "#36a64f",
"server_name": "web-server-01",
"metric": "CPU usage",
"current_value": "45.1%",
"threshold": "90%",
"operator": ">=",
"severity": "critical",
"status": "resolved",
"timestamp": "2024-01-15T14:45:18Z"
}
Platform Integration
Slack
Server Scout's webhook payload is designed to be Slack-compatible. Simply use your Slack Incoming Webhook URL directly in Server Scout's webhook configuration. The text field becomes the message content, and the color field provides visual coding in Slack channels.
Discord
Discord supports Slack-compatible webhooks with a simple URL modification. Append /slack to your Discord webhook URL:
Original: https://discord.com/api/webhooks/123456/abcdef
Modified: https://discord.com/api/webhooks/123456/abcdef/slack
Microsoft Teams
Teams doesn't natively support Slack-format webhooks, but you can use connectors that accept Slack-format payloads. Look for "Incoming Webhook" connectors in the Teams App Store that specifically mention Slack compatibility.
PagerDuty
For PagerDuty integration, you'll need to create a middleware service that maps Server Scout's webhook payload to PagerDuty's Events API v2 format. The key mappings are:
status: "fired"→event_action: "trigger"status: "resolved"→event_action: "resolve"text→summaryseverity→severity
Custom Implementations
When building custom webhook handlers, remember that Server Scout sends POST requests with the JSON payload in the request body. Your endpoint should:
- Accept POST requests
- Parse JSON from the request body
- Handle the
Content-Type: application/jsonheader - Respond with a 2xx status code to acknowledge receipt
The standardised payload format makes it straightforward to route alerts to multiple systems, create custom dashboards, or integrate with existing monitoring workflows. All fields are consistently present in every webhook, making parsing reliable and predictable.
Frequently Asked Questions
How do I set up ServerScout webhooks for Slack?
What fields are included in ServerScout webhook payloads?
Why am I not receiving webhook notifications from ServerScout?
How does ServerScout color coding work in webhook payloads?
Can I integrate ServerScout webhooks with Discord?
What webhook payload statuses does ServerScout send?
How do I integrate ServerScout webhooks with PagerDuty?
Was this article helpful?