> For the complete documentation index, see [llms.txt](https://docs.statuspal.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.statuspal.io/platform/integrations/zabbix.md).

# Zabbix

Unlike other supported monitoring services, Zabbix does not provide webhooks with a fixed structure. Instead, you must create your own from scratch.

To set it up in Statuspal, first create or update your service and select "Zabbix" as the "Monitoring Service". You will then be given a Webhook URL, which you will need later in Zabbix.

<figure><img src="/files/KZFMMFOZCxT59FbcaMAw" alt="" width="464"><figcaption></figcaption></figure>

On your Zabbix server, go to **Alerts > Media types** and click on "Create"

For the type, select the "Webhook" option, and on the Parameters section, define one parameter with Name `status`, and Value `{EVENT.VALUE}`

<figure><img src="/files/rpdMVbUqT3rVejF6icq8" alt=""><figcaption></figcaption></figure>

Edit the Script, and put the following Javascript snipped

```javascript
function notifyStatusPal(params) {
    request = new HttpRequest()

    request.addHeader('Content-Type: application/json');

    var response = request.post('<WEBHOOK_URL>', JSON.stringify({
        status: params.status
    }))

    if (request.getStatus() !== 204) {
        throw "API request failed: " + response;
    }
}

try {
    var params = JSON.parse(value)

    notifyStatusPal(params)

    return 'OK'
}
catch (err) {
    Zabbix.log(4, 'StatusPal notification failed : ' + err)

    throw 'StatusPal notification failed : ' + err
}
```

Replace `<WEBHOOK_URL>` with the Webhook URL you generated on StatusPal for your Zabixx monitoring service.

To test your new integration, on the Media types listing, find your new media type and click on "Test"

<figure><img src="/files/JM0feyKBLAauIzXz56uY" alt=""><figcaption></figcaption></figure>

A status of 0 means the service is up; any other value will indicate that it is down.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.statuspal.io/platform/integrations/zabbix.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
