The method allows to retrieve host interfaces according to the given parameters.该方法允许根据给定的参数检索主机接口。
Parameters 参数
(object)
Parameters defining the desired output.定义所需输出的参数。
The method supports the following parameters.该方法支持以下参数。
an array of objects;一组对象;
the count of retrieved objects, if the
countOutput
parameter has been used.如果已经使用“countOutput”参数,则检索到的对象的计数。
Examples 示例
Retrieve host interfaces检索主机接口
Retrieve all data about the interfaces used by host “30057.”检索主机“30057”使用的接口的所有数据。
Response:
- {
- "jsonrpc": "2.0",
- "result": [
- {
- "interfaceid": "30050",
- "hostid": "30057",
- "main": "1",
- "useip": "1",
- "ip": "127.0.0.1",
- "dns": "",
- "port": "10050",
- "bulk": "1"
- },
- {
- "interfaceid": "30067",
- "hostid": "30057",
- "main": "0",
- "type": "1",
- "useip": "0",
- "ip": "",
- "dns": "localhost",
- "port": "10050",
- "bulk": "1"
- {
- "interfaceid": "30068",
- "hostid": "30057",
- "main": "1",
- "type": "2",
- "useip": "1",
- "ip": "127.0.0.1",
- "dns": "",
- "port": "161",
- "bulk": "1"
- }
- ],
- "id": 1
- }