OpManager 提供用于从 OpManager 添加和获取数据的 REST API。使用这些 API,您可以将 OpManager 与第三方 IT 管理/服务台软件集成。
OpManager REST API 如何工作?
API使用 API密钥。API密钥对于每 OpManager帐户都是唯一的,并且对于所有API请求都是必需的。
生成 API 密钥
要生成 API 密钥,请转到 OpManager Web 客户端中的设置 > REST API 并且点击生成 Key.
OpManager 提供用于从 OpManager 添加和获取数据的 REST API。使用这些 API,您可以将 OpManager 与第三方 IT 管理/服务台软件集成。
API使用 API密钥。API密钥对于每 OpManager帐户都是唯一的,并且对于所有API请求都是必需的。
要生成 API 密钥,请转到 OpManager Web 客户端中的设置 > REST API 并且点击生成 Key.
方法: GET
描述: 列出 OpManager 中生成的所有告警。
示例URL: https://localhost:8060/api/json/alarm/listAlarms?apiKey=***************
方法: GET
描述: 列出特定告警的告警属性
示例URL: https://localhost:8060/api/json/alarm/alarmProperties?apiKey=***************&entity=entity1_Poll
方法: POST
描述: 此 API 用于向告警添加备注
示例URL: https://localhost:8060/api/json/alarm/addNotes?apiKey=***************
方法: POST
描述: 此 API 用于确认告警
示例URL: https://localhost:8060/api/json/alarm/acknowledgeAlarm?apiKey=***************
方法: POST
描述: 此 API 用于取消确认告警
示例URL: https://localhost:8060/api/json/alarm/unAcknowledgeAlarm?apiKey=***************
方法: POST
描述: 此 API 用于清除告警。
示例URL: https://localhost:8060/api/json/alarm/clearAlarm?apiKey=***************&entity=coldStart_trap
方法: POST
描述: 删除告警API
示例URL: https://localhost:8060/api/json/alarm/deleteAlarm?apiKey=***************&entity=coldStart_trap
方法: GET
描述: 按照告警排名靠前的设备
示例URL: https://localhost:8060/api/json/alarm/getTopDevicesByAlarms?apiKey=***************
方法: GET
描述: 这个API是用来获取告警的注释
示例URL: https://localhost:8060/api/json/alarm/getAnnotation?apiKey=***************
方法: GET
描述: 给定设备的ICMP/Ping 响应。
示例URL: https://localhost:8060/api/json/device/getPingResponse?apiKey=***************&deviceName=192.168.49.4
方法: GET
描述: 跟踪给定设备的路由命令响应
示例URL: https://localhost:8060/api/json/device/getTraceResponse?apiKey=***************&deviceName=192.168.49.4
方法: GET
描述: 列出当前处于停机状态且设备状态为“危急的”的设备
示例URL: https://localhost:8060/api/json/discovery/getDownDevices?apiKey=******************
方法: GET
描述: 获取给定设备或接口的可用性图表。
示例URL: https://localhost:8060/api/json/device/getAvailabilityGraphData?apiKey=******************&isFluidic=true&name=opmserver.mydomain.com
方法: GET
描述: 提供在 OpManager 中创建的停机时间表列表。
示例URL: https://localhost:8060/api/json/admin/listDownTimeSchedules?apiKey=****************
方法: POST
描述: 管理或取消管理当前添加到 OpManager 中的设备、接口或 URL 监视器。
示例URL: https://localhost:8060/api/json/device/setManaged?manage=true&apiKey=***************
方法: GET
描述: 列出在OpManager 中创建的所有业务视图。
示例URL: https://localhost:8060/api/json/businessview/getBusinessView?apiKey=***************
方法: GET
描述: 列出给定业务视图中的所有可用设备
示例URL: https://localhost:8060/api/json/businessview/getBusinessDetailsView?apiKey=***************&bvName=ProductionSite_bv
方法: GET
描述: 此 API用于获取要为给定小窗件ID 加载的数据。
示例URL: https://localhost:8060/api/json/dashboard/getWidgetData?apiKey=***************&widgetID=495
方法: GET
描述: 此 API 用于列出要为给定仪表板加载的小窗件。
示例URL: https://localhost:8060/api/json/dashboard/getWidgetsList?apiKey=***************&dashboardName=dashboardname
方法: GET
描述: 列出所有添加到 OpManager 中的设备。
示例URL: https://localhost:8060/api/json/device/listDevices?apiKey=****************&
方法: GET
描述: 提供与给定设备相关的自定义字段值,例如建筑物、机柜、序列号等。
示例URL: https://localhost:8060/api/json/device/getDeviceNotes?apiKey=***************&name=192.168.49.1
方法: GET
描述: 提供设备的类别详细信息,例如设备名称、设备显示名称、状态、IP 地址、设备类型和相关的性能监视器值。
示例URL: https://localhost:8060/api/json/discovery/getInfrastructureDetailsView?apiKey=**************&categoryName=Server
方法: GET
描述: 提供设备快照页面中的设备详细信息
示例URL: https://localhost:8060/api/json/device/getDeviceSummary?apiKey=**************&name=opmserver.testdomain.com
方法: GET
描述: 列出所选虚拟类型的所有实体。
示例URL: https://localhost:8060/api/json/device/listVirtualDevices?apiKey=***************&virtualDeviceType=VM
方法: GET
描述: 列出设备的基本详细信息和可用性
示例URL: https://localhost:8060/api/json/v2/device/getDeviceCompleteDetails?apiKey=***************&name=devicename
方法: POST
描述: 允许您将单个设备添加到 OpManager 以进行监控。
示例URL: https://localhost:8060/api/json/discovery/addDevice?apiKey=***************&name=opmserver.mydomain.com
方法: GET
描述: 这个 API 是为了列出所有的探针
示例URL: https://localhost:8060/api/json/admin/listProbes?apiKey=***************
方法: GET
描述: 列出事件历史。
示例URL: https://localhost:8060/api/json/events/listEvents?apiKey=***************&deviceName=opmrouter
方法: GET
描述: 列出 OpManager 中所有可用的组。还提供基本的组信息,例如成员计数和组健康状况。
示例URL: https://localhost:8060/api/json/admin/listAllLogicalGroups?apiKey=***************
方法: GET
描述: 提供给定组的详细信息(例如成员计数、组状态等)。
示例URL: https://localhost:8060/api/json/admin/getLogicalGroupInfo?apiKey=***************&groupName=NorthBayRegion-4201&period=3&snapType=LogicalDeviceGroup
方法: GET
描述: 获取从给定组的成员(设备/接口)生成的告警。
示例URL: https://localhost:8060/api/json/admin/getLogicalGroupAlerts?apiKey=***************&groupName=bvgcty-4201
方法: GET
描述: 提供有关给定组中可用成员的信息。
示例URL: https://localhost:8060/api/json/admin/listLogicalGroupMembers?apiKey=***************&groupName=NorthBayRegion-4201
方法: POST
描述: 允许您将设备添加到指定的组。
示例URL: https://localhost:8060/api/json/device/addToGroup?apiKey=***************&groupType=device&selectedMembers=10.1.1.20,opmserver
方法: GET
描述: 列出 OpManager 中监控的所有接口
示例URL: https://localhost:8060/api/json/device/listInterfaces?apiKey=***************&isFluidic=true&rows=100&page=1&sortByColumn=statusNum&sortByType=desc
方法: GET
描述: 供接口的基本细节,如ifIndex、ifName、ifDesc、ifAlias、父设备、Rx/Tx Traffic等。
示例URL: https://localhost:8060/api/json/device/getInterfaceSummary?apiKey=***************&interfaceName=IF-172.24.146.225-4429
方法: GET
描述: 为给定的接口提供整合的可用性和性能监控健康报表数据。
示例URL: https://localhost:8060/api/json/v2/device/getIntfAtAGlanceReportDetails?apiKey=***************&InterfaceName=IF-192.168.49.4-3820&period=Today
方法: GET
描述: 为给定接口的合并带宽报表(Rx/Tx 流量)提供数据。
示例URL: https://localhost:8060/api/json/v2/device/getIntfBWOutageReportDetails?apiKey=***************&interfaceName=IF-192.168.49.4-3836&period=Today
方法: GET
描述: 提供设备中监控的接口列表。
示例URL: https://localhost:8060/api/json/device/getInterfaces?apiKey=***************&name=opmserver.testdomain.com
方法: GET
描述: 获取与给定接口关联的自定义字段值。
示例URL: https://opmserver:8060/api/json/device/getInterfaceNotes?apiKey=************&interfaceName=IF-opmserver.testdomain.com-4505
方法: GET
描述: 获取给定接口的收集数据(例如流量、错包和丢包等)。
示例URL: https://localhost:8060/api/json/device/getInterfaceGraphs?apiKey=***************&interfaceName=IF-192.168.49.106-329&graphName=rxutilization
方法: GET
描述: 列出与设备关联的所有监视器
示例URL: https://localhost:8060/api/json/device/getDeviceAssociatedMonitors?apiKey=***************&name=devicename
方法: GET
描述: 列出特定设备的所有可用性能监视器(基于设备的类别和类型)
示例URL: https://localhost:8060/api/json/device/getPerformanceMonitors?apiKey=***************&deviceName=devicename&category=Desktop&type=Windows 2008 R2
方法: GET
描述: 列出来自特定设备的关联性能监视器的详细信息
示例URL: https://localhost:8060/api/json/device/getPerformanceMonitorDetails?apiKey=***************&name=devicename&policyName=WMI-CPUUtilization&graphName=WMI-CPUUtilization&checkNumeric=true
方法: POST
描述: 向设备添加一个新的性能监视器(或多个性能监视器)
示例URL: https://localhost:8060/api/json/device/addPerformanceMonitors?apiKey=***************&name=devicename&selectedMonitors=1166,3337,304,204,205,203,3327
方法: POST
描述: 从设备中删除性能监视器
示例URL: https://localhost:8060/api/json/device/deletePerformanceMonitors?apiKey=***************&name=devicename&pollId=332,213
方法: POST
描述: 在特定设备中测试性能监视器
示例URL: https://localhost:8060/api/json/device/TestMonitor?apiKey=***************&name=devicename&policyName=WMI-MemoryUtilization&graphName=WMI-MemoryUtilization
方法: GET
描述: 获取与设备关联的进程监视器列表
示例URL: https://localhost:8060/api/json/device/getAssociatedProcessMonitors?apiKey=***************&deviceName=devicename
方法: POST
描述: 关联进程监视器到设备
示例URL: https://localhost:8060/api/json/device/associateProcessMonitor?apiKey=***************&deviceName=devicename&processId=408,8,68&protocol=WMI
方法: GET
描述: 获取与设备关联的服务监视器列表
示例URL: https://localhost:8060/api/json/device/getAssociatedServiceMonitors?apiKey=***************&name=devicename
方法: POST
描述: 关联服务监视器到设备
示例URL: https://localhost:8060/api/json/admin/associateServiceMonitor?apiKey=***************&deviceName=devicename&serviceName=DNS,FTP,Echo
方法: GET
描述: 列出设备的关联 Windows 服务监视器
示例URL: https://localhost:8060/api/json/device/getDeviceAssociatedWindowsServiceMonitors?apiKey=***************&name=devicename
方法: GET
描述: 列出 OpManager 中所有可用的全局 URL 监视器
示例URL: https://localhost:8060/api/json/admin/listURLMonitors?apiKey=***************
方法: GET
描述: 列出 OpManager 中所有可用的脚本模板
示例URL: https://localhost:8060/api/json/admin/listScriptMonitors?apiKey=***************
方法: GET
描述: 此 API 用于列出在 OpManager 中创建的所有通知配置文件。
示例URL: https://localhost:8060/api/json/admin/listNotificationProfiles?apiKey=***************&isGlobal=true&profileFilter=All&deviceName=devicename
方法: POST
描述: 此 API 用于将通知配置文件关联到设备。
示例URL: https://localhost:8060/api/json/admin/associateNotificationProfiles?apiKey=***************&deviceName=devicename&profiles=501
方法: GET
描述: 这个 API 是为了列出所有的报表
示例URL: https://localhost:8060/api/json/reports/getReportsList?apiKey=***************&isFavouriteNeeded=true&hideintegratedReports=true&hideHardwareReport=true
方法: GET
描述: 获取所需报表数据的 API。
示例URL: https://localhost:8060/api/json/reports/getReportsData?apiKey=***************&reportID=84&isExcludeDays=true&excludedDays=Monday,Tuesday&category=Desktop&bview=All&time=Last_Month&timeWindow=8-20&isBusinessHour=false&showType=0&top=1000&viewAs=json
方法: GET
描述: 这个 api 可用于列出所有创建的工作时间规则。
示例URL: https://localhost:8060//api/json/admin/listBusinessRules?apiKey=***************
方法: POST
描述: 该api用于配置周一到周日的工作时间规则。
示例URL: https://localhost:8060/api/json/admin/addBusinessRules?apiKey=***************&businessRuleName=Rule1&description=Indian standard time shift 1.&timeSettings={"monday":"1-5","tuesday":"3-6","wednesday":"3-5","thursday":"2-5","friday":"5-13"}
方法: POST
描述: 这个api是删除已经创建的工作时间规则。
示例URL: https://localhost:8060//api/json/admin/deleteBusinessRules?apiKey=***************&businessRuleId=1
方法: GET
描述: 这个api是查看已经创建的工作时间规则。
示例URL: https://localhost:8060//api/json/admin/viewBusinessRules?apiKey=***************&businessRuleId=1
方法: POST
描述: 这个api用于更新配置的工作时间规则从周一到周日。
示例URL: https://localhost:8060/api/json/admin/updateBusinessRules?apiKey=***************&businessRuleName=Rule1&description=Indian standard time shift 1.&timeSettings={"monday":"1-5","tuesday":"3-6","wednesday":"3-5","thursday":"2-5","friday":"5-13"}&businessRuleId=1
方法: POST
描述: 用于获取报表生成器报表数据的 API。
示例URL: https://localhost:8060//api/json/admin/getReportData?apiKey=***************&deviceList=moname1,moname2&monitorList=DevicesAvailability,ResponseTime,WMI-CPUUtilization,MSSQLDataFilesSizeKB&timePeriod=Last_Month&view=table&timeWindow=0-24&startDate=2020-11-09&endDate=2020-11-18-18
方法: GET
描述: 这个 api 可用于获取所有创建的高级报表。
示例URL: https://localhost:8060//api/json/admin/listAllAdvancedReports?apiKey=***************
方法: POST
描述: 列出所有可用的设备类别
示例URL: https://localhost:8060/api/json/device/getCategoryList?apiKey=***************
方法: GET
描述: 列出 OpManager 中监控的所有子网
示例URL: https://localhost:8060/api/json/device/listSubnets?apiKey=***************
方法: GET
描述: 列出无线 LAN 控制器中每个 SSID 的接入点、客户端数量和网络使用情况
示例URL: https://localhost:8060/api/json/wireless/getWirelessNetworkDetails?apiKey=***************&deviceName=CiscoWirelessController
方法: GET
描述: 列出 WLC 设备中的所有接入点。
示例URL: https://localhost:8060/api/json/wireless/getWirelessAPList?apiKey=***************&deviceName=CiscoWirelessController
方法: GET
描述: 列出与给定 WLC设备关联的所有 SSID客户端。
示例URL: https://localhost:8060/api/json/wireless/getSSIDClientList?apiKey=***************&deviceName=CiscoWirelessController
方法: GET
描述: 获取连接到 WLC 设备给定 SSID 的客户端设备。
示例URL: https://localhost:8060/api/json/wireless/getClientDetails?apiKey=***************&deviceName=CiscoWirelessController&ssidName=WorkstationNetwork