I am trying to connect to the Zabbix API on Ubuntu with a Nginx web server installed. The Zabbix server GUI works fine and I have not problems getting info from Zabbix agents. However when I make the following call to the Zabbix API
curl -H "Content-Type: application/json.rpc" -X POST http://127.0.0.1/api_jsonrpc.php -d'
{
"jsonrpc": "2.0",
"method": "user.login",
"params": {
"user": "Admin",
"password": "zabbix"},
"id": 1
}'
Here is the response I receive:
<html>
<head><title>404 Not Found</title></head>
<body>
<center><h1>404 Not Found</h1></center>
<hr><center>nginx/1.18.0 (Ubuntu)</center>
</body>
</html>
The Zabbix server is version 5.0.9
Ubuntu version: 20.04.2
Nginx version: 1.18.0
The latest nginx error.log file is empty.
I want to be able to make API calls to retrieve data from the Zabbix server to store locally.
Thanks in advance for any help to make this work
Wil
curl -H "Content-Type: application/json.rpc" -X POST http://127.0.0.1/api_jsonrpc.php -d'
{
"jsonrpc": "2.0",
"method": "user.login",
"params": {
"user": "Admin",
"password": "zabbix"},
"id": 1
}'
Here is the response I receive:
<html>
<head><title>404 Not Found</title></head>
<body>
<center><h1>404 Not Found</h1></center>
<hr><center>nginx/1.18.0 (Ubuntu)</center>
</body>
</html>
The Zabbix server is version 5.0.9
Ubuntu version: 20.04.2
Nginx version: 1.18.0
The latest nginx error.log file is empty.
I want to be able to make API calls to retrieve data from the Zabbix server to store locally.
Thanks in advance for any help to make this work
Wil
Comment