Zabbix
Webhook and HTTP6 steps
Zabbix alerts to your iPhone with the PagerDeck media type
A media type to import. Problem and recovery stay one incident, and the recovery closes it.
On this page
How do I get Zabbix problems on my phone, with rules?
Import the PagerDeck media type into Zabbix, enter the ingest key in the token parameter, and assign the media type to a user and a trigger action. The media type calls /v1/push and /v1/resolve: problem and recovery carry the same event ID as dedup_key, and the recovery closes the incident instead of ringing a second time.
- Tested with
- Zabbix 7.0 LTS, imports into 8.0 unchanged
- Endpoints
- /v1/push and /v1/resolve
- Incident
- dedup_key built from zabbix- and the event ID
- Severities
- Disaster becomes critical, High and Average become error, Warning becomes warning, the rest info
- Installation
- None, Zabbix runs the script itself
Prerequisites
- A PagerDeck account with at least one paired device, so alerts have somewhere to land.
- A source in the dashboard with its credentials, see the first step below.
- Zabbix 7.0 LTS (tested) or 8.0.
How to set it up
Create a source
In the dashboard, create a source for Zabbix and copy the ingest key. It starts with src_live_ and is visible exactly once.
Import the media type
Download the file and import it in Zabbix under Alerts, Media types, Import.
text https://pagerdeck.com/downloads/zabbix/media_pagerdeck.yamlEnter the key
Open the media type and set the token parameter. Only then set the status to Enabled.
text token = src_live_REPLACE_MESet the macro
Create the global macro shown in the example under Administration, Macros, without a trailing slash. The media type uses it to build the link back to the event.
text {$ZABBIX.URL} = https://zabbix.example.comAssign the media type
Add it to the user under Users, Media. Send to requires a value, and a single hyphen is enough because the key already identifies the account. Then create a trigger action with this media as its operation.
Test
Trigger a problem or use the Test button in the media type. The problem must appear in your history, and the matching recovery closes it again.
Payload
PagerDeck reads these fields on POST /v1/push. Only title is required, unknown fields are ignored.
{
"title": "Disk almost full on web-01",
"body": "/ is 94% used",
"severity": "error",
"tags": [
"prod",
"disk"
],
"dedup_key": "web-01:disk",
"url": "https://status.example.com/web-01",
"ttl": "30m"
}- title
- Required, at most 250 bytes.
- body
- Body text, at most 8 KiB.
- severity
- info, warning, error or critical. Without it the source default applies.
- tags
- At most 20, 64 bytes each.
- dedup_key
- Keeps an incident together until it is resolved.
- url
- A link for the app, http and https only.
- ttl
- Delivery deadline and automatic resolve, for example 30m.
Test it
Send a test alert straight to the API after setting PAGERDECK_KEY to your key. If it shows up in the app under your source, key and source are right and any problem sits in the sender configuration.
curl -sS -X POST https://api.pagerdeck.com/v1/push \
-H "Authorization: Bearer $PAGERDECK_KEY" \
-H "Content-Type: application/json" \
-d '{"title":"PagerDeck test","body":"If you read this, the key works.","severity":"warning"}'What the rules do with it
The sender proposes an urgency, your rule chain decides the alert level. This rule raises errors from the source zabbix to critical and repeats until you acknowledge. Use the slug of your own source.
{
"enabled": true,
"stop": false,
"when": {
"source": [
"zabbix"
],
"severity_at_least": "error"
},
"then": {
"level": "critical",
"repeat": {
"every": "5m",
"until": "ack",
"max": 6
}
}
}- Set the volume
- By source, title pattern, tags and time of day you can set a level from silent to critical.
- Repeat until acknowledged
- A rule repeats an alert at a fixed interval until you acknowledge it.
- Escalate
- If nobody reacts, PagerDeck notifies another address after a deadline.
What you should know
- The severity from Zabbix is a suggestion. Your rule chain decides what your phone does with it.
- If you already use the built in Pushover media type, you can change its address to PagerDeck's Pushover compatible route. That is faster, but you lose dedup_key and closing on recovery.
- Android devices do not get push today.
Troubleshooting
When the API answers with a status code, it usually names the cause already.
- 202
- Accepted and stored. This is not an error, delivery follows.
- 400
- The input is invalid, for example a title over 250 bytes or malformed JSON. The message field gives the reason.
- 401
- The key is missing, unknown or expired. Check the Authorization: Bearer header and that the key was copied completely.
- 402
- The account may not send. Nothing is wrong with the connection, check the plan and billing in the dashboard.
- 413
- The request is larger than 64 KiB. Limit the amount per request.
- 429
- Sent too fast or quota used up. The Retry-After header says when to continue.
Frequently asked questions
- Do I need to install anything on the Zabbix server?
- No. The media type is a webhook script that Zabbix runs itself. It only needs outbound HTTPS to api.pagerdeck.com.
- Why does an escalation not ring a second time?
- Because it carries the same event ID and therefore the same dedup_key. PagerDeck updates the open incident instead of playing a second sound.
- What happens if I already closed the incident by hand?
- The recovery then finds no open incident. The media type accepts the 404 response and still reports the action as done in Zabbix.
- Can I change the severity mapping?
- Yes, with the parameters severity_disaster, severity_high and the others in the media type. Allowed values are info, warning, error and critical.
Connect Zabbix to your rules
Import the media type, enter the key, create the action. 14 days, no payment method needed.
Last reviewed: October 2026. PagerDeck, a product of Gonzi Tech UG (haftungsbeschränkt)
Product and company names mentioned are trademarks of their respective owners. PagerDeck is not affiliated with, sponsored or endorsed by them. Details in the imprint.