I created a custom field in a host definition that I wanted to be able to access through the APIs. However, using the object query for the host it merely tells me that the custom field exists, not the value of it. Am I not doing the query correctly? Or is this something that can be added?
Here is (part of) the host definition:
Code: Select all
define host {
use generic-host
host_name pleiades1
...
_domain pleiades
}
Code: Select all
cgi-bin/objectjson.cgi?query=host&hostname=pleiades1Code: Select all
{
"format_version": 0,
"result": {
"query_time": 1399936372000,
"cgi": "objectjson.cgi",
"query": "host",
"query_status": "beta",
"program_start": 1399935899000,
"last_data_update": 1399935899000,
"type_code": 0,
"type_text": "Success",
"message": ""
},
"data": {
"host": {
"name": "pleiades1",
"name": "pleiades1",
...
"custom_variables": [
"DOMAIN"
]
}
}
}thanks!