搜索看看
获取系统日志列表,告警日志也在此接口获取
1、示例,下面【2】是参数说明:
请求URL:http://localhost:9999/log/agentList 请求方式:POST 请求参数(Content-Type:application/json): { "wgToken":"65d05df102851c6535322e73b2f99c06", "hostname":"192.168.1.2", "startTime":"2021-04-26 00:00:00", "endTime":"2021-04-26 23:59:59", "page":1, "pageSize":20 } 返回结果: { "msg":"", "code":"0", "data":{ "pageSize":2, "list":[ { "hostname":"admin修改服务接口监测信息:wgstart", "createTime":1659539385000, "infoContent":"服务接口URL:https://www.wgstart.com", "state":"2", "id":"1554846992012804096" } ], "pageNum":1, "total":15, "pages":8 } }
2、参数说明:
请求参数(Content-Type:application/json): { "wgToken":"必填,server/config/application.yml里的wgToken配置项的md5加密字符串,大小写均可", "hostname":"非必填,标题摘要", "startTime":"非必填,开始时间", "endTime":"非必填,结束时间", "page":"必填,第几页", "pageSize":"必填,每页多少条" } 返回结果: { "msg":"错误信息", "code":"0成功1错误", "data":{ "pageSize":2, "list":[ { "hostname":"标题摘要", "createTime":"创建时间,毫秒", "infoContent":"服务接口URL:https://www.wgstart.com", "state":"1业务告警,2系统操作日志,3业务告警恢复", "id":"1554846992012804096" } ], "pageNum":1, "total":15, "pages":8 } }