Just noticed that when I GET a HOST object, the hostgroups are not listed:
Code: Select all
curl -XGET "http://nagios/nagiosxi/api/v1/objects/host?apikey=4n9mb3g98lezfezfegzeggze9pkurft4s9jpihmbsk8t&pretty=1&host_name=srv2012test.domain"
{
"hostlist": {
"recordcount": "1",
"host": {
"@attributes": {
"id": "13923"
},
"instance_id": "1",
"host_name": "srv2012test.domain",
"is_active": "1",
"config_type": "1",
"alias": "srv2012test.domain",
"display_name": "srv2012test.domain",
"address": "10.54.26.13",
"check_interval": "5",
"retry_interval": "1",
"max_check_attempts": "3",
"first_notification_delay": "0",
"notification_interval": "1440",
"passive_checks_enabled": "1",
"active_checks_enabled": "1",
"notifications_enabled": "1",
"notes": "",
"notes_url": "",
"action_url": "",
"icon_image": "win_server.png",
"icon_image_alt": "",
"statusmap_image": "win_server.png"
}
}
}