这个方法允许根据给定的参数检索发现的服务。
参数
(object)
定义需要输出的参数。
这个方法支持以下参数。
一个对象数组;
如果使用了
countOutput
参数,被检索的对象的数量。
示例
检索在主机上发现的服务
检索在被发现主机 “11” 上发现的所有被发现的服务。
响应:
"jsonrpc": "2.0",
"result": [
{
"dhostid": "11",
"value": "",
"port": "80",
"status": "1",
"lastup": "0",
"lastdown": "1348650607",
"dcheckid": "5",
"ip": "192.168.1.134",
"dns": "john.local"
{
"dserviceid": "13",
"dhostid": "11",
"port": "21",
"status": "1",
"lastup": "0",
"lastdown": "1348650610",
"dcheckid": "6",
"ip": "192.168.1.134",
"dns": "john.local"
}
],
}
来源
CDService::get() in frontends/php/include/classes/api/services/CDService.php.