Zabbix API

Once you have your Zabbix server up and running, you would probably like to integrate it in the rest of your infrastructure. This is where the Zabbix API comes into picture. By using the API, we can extend Zabbix and integrate it with our other solutions. In this chapter, we will show you how to connect to the API and explain you the basics to interact with it.

Getting ready

In this recipe, we only need our Zabbix server with the super administration account.

How to do it...

  1. Make sure you have curl on your system. It should be there when you installed your system. If not run:
    yum install curl
    
  2. Run the following command on your Zabbix server's prompt or from another machine but then replace the IP:
    curl -s -i -X POST -H 'Content-Type: application/json-rpc' ...

Get Zabbix Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.