AddMonitor APIs - Virtualization


This section explains how to use the AddMonitor API to add monitors of the category type Virtualization. The following monitors are supported:

VMware ESX/ESXi Server

Syntax:

http://[Host]:[Port]/AppManager/xml/AddMonitor?apikey=[APIKEY]&type=[TYPE]&displayname=[DISPLAYNAME]&host=[HOST]&port=[PORT]&username=[USERNAME]&password=[PASSWORD]&addtoGroup=[ADDTOGROUP]&groupID=[GROUPID]&monitorvms=[MONITORVMS]

Request Parameters:

The parameters involved in the API request are described below. Also, refer to the list of common Request Parameters.

Field Description
type The type of the monitor you want to add. Value should be VMware ESX/ESXi.
host The name of the host where the VMWare ESX/ESXi server is running.
port The port number where the VMware ESX/ESXi server is running.
username The user name of the VMware ESX/ESXi server.
password The password of the VMware ESX/ESXi server.
addtoGroup Denotes if the monitor should be added to monitor group. Value is either true or false
groupID The monitor group ID
monitorvms Indicates the way how the virtual machines of the ESX server are to be monitored. Possible values are:
  • no - VMs will not be discovered.
  • onlyavailability - VMs will be discovered but the metrics will not be monitored. (Will not count for licensing)
  • yes - VMs will be discovered and monitored.

Sample Request:

http://prod-server5:9090/AppManager/xml/AddMonitor?apikey=e249ce592ad1052c4ea605bcf3125ad9&type=VMWare ESX/ESXi&displayname=vnwgroup&host=esx-2&port=443&username=root&password=password&addToGroup=true&groupID=10000024&monitorvms=onlyavailability

VMware Horizon View Connection Broker

You can add the VMware Horizon View Connection Broker monitor in the following two ways:

  • Add VMware Horizon View as a new monitor group (New Monitor Group --> VMware Horizon View).This will discover all the components in the Horizon View Set up including View Connection Broker.

    Syntax:

    http://[Host]:[Port]/AppManager/xml/AddMonitor?apikey=[APIKEY]&type=VMwareView&displayname=[DISPLAYNAME]&host=[HOST]&username=[USERNAME]&password=[PASSWORD]&pollInterval=[POLL INTERVAL]

    Sample Request:

    http://prod-server5:9090/AppManager/xml/AddMonitor?apikey=f6ad2a431bb2cd5aa85c195262daef7f&type=VMwareView&displayname=HorizonView&host=172.18.144.52&username=vmwarehzview\user-test&password=APM@13&pollInterval=5

     

  • Add VMware Horizon View Connection Broker as a new monitor (New Monitor --> VMware Horizon View Connection Broker). This will discover View Connection Broker alone.

    Syntax:

    http://[Host]:[Port]/AppManager/xml/AddMonitor?apikey=[APIKEY]&type=ViewConnectionBroker&displayname=[DISPLAYNAME]&host=[HOST]&username=[USERNAME]&password=[PASSWORD]&pollInterval=[POLL INTERVAL]&addtoGroup=[TRUE/FALSE]&groupID=[GROUPID]

    Sample Request:

    http://prod-server5:9090/AppManager/xml/AddMonitor?apikey=f6ad2a431bb2cd5aa85c195262daef7f&type=ViewConnectionBroker&displayname=ViewBroker&host=172.18.144.52&username=vmwarehzview\maran-test&password=Zoho@13&pollInterval=5&addtoGroup=true&groupID=10000028

Request Parameters:

The parameters involved in the API request are described below. Also, refer the list of common Request Parameters.

Field Description
type The type of the monitor you want to add. Value should be VMwareView or ViewConnectionBroker.
host The name of the host where the VMware Horizon View server is running.
username The user name of your VMware server.
password The password of your VMware server.

Microsoft Hyper-V Server

Syntax:

http://[Host]:[Port]/AppManager/xml/AddMonitor?apikey=[APIKEY]&type=[TYPE]&host=[HOST]&displayname=[DISPLAYNAME]&password=[PASSWORD]&addvms=[ADDVMS]&username=[USERNAME]&Version=[VERSION]

Request Parameters:

The parameters involved in the API request are described below. Also, refer the list of common Request Parameters.

Field Description
type The type of the monitor you want to add. Value should be Hyper-V Server.
host The name of the host where the Hyper-V server is running.
password The password of the Hyper-V server.
addvms Indicates the way how the virtual machines (VMs) of the Hyper-V server are to be monitored. Possible values are:
  • no - VMs will not be discovered.
  • onlyavailability - VMs will be discovered but the metrics will not be monitored. (Will not count for licensing)
  • yes - VMs will be discovered and monitored.
username The user name of the Hyper-V server.
Version The version of your Microsoft Hyper-V Server. Possible values are 2008, 2012, 2016 or 2019.

Sample Request:

http://prod-server6:9090/AppManager/xml/AddMonitor?apikey=256d041620d0aee9901558b44706dc84&type=Hyper-V Server&host=amp-w2k8-64&displayname=apmhyperv&password=admin123app2&addvms=yes&username=administrator&Version=2008

Citrix Xenserver

Syntax:

http://[Host]:[Port]/AppManager/xml/AddMonitor?apikey=[APIKEY]&type=[TYPE] &host=[HOST]&displayname=[DISPLAYNAME]&username=[USERNAME]&password=[PASSWORD]&port=[PORT] &addvms=[ADDVMS]&addToGroup=[TRUE/FALSE]&groupID=[GROUPID]&monitorvms=[AVAILABILITY]

Request Parameters:

The parameters involved in the API request are described below. Also, refer the list of common Request Parameters.

Field Description
type The type of the monitor you want to add. Value should be XenServerHost.
host The name of the host where the XenServerHost is running.
password The password of the XenServerHost
addvms Denotes whether the performance metrics of VMs should be collected. Value is either yes or no
username The user name of the XenServerHost
addToGroup Denotes if the monitor should be added to monitor group. Value is either true or false
groupID The monitor group ID
monitorvms Indicates the way the virtual machines are to be monitored. Possible values are no, yes and onlyavailability.The value no means the VMs will not be discovered. The value yes indicates that the VMs will be discovered and monitored. The value onlyavailability indicates that the VMs will be discovered but the metrics will not be monitored (will not count for licensing).

Sample Request:

http://prod-server6:9090/AppManager/xml/AddMonitor?apikey=bc76b1abb8e9b209824a39d84578a194 &type=XenServerHost&host=192.18.3.75&displayname=newxen&password=sankho &addvms=yes&username=root

Citrix XenApp

Syntax:

http://[Host]:[Port]/AppManager/xml/AddMonitor?apikey=[APIKEY]&type=[TYPE] &host=[HOST]&displayname=[DISPLAYNAME]&UserName =[USERNAME]&Password=[PASSWORD]&Version=[VERSION]

Request Parameters:

The parameters involved in the API request are described below. Also, refer the list of common Request Parameters.

Field Description
apikey The key generated from the Generate API Key option in the 'Admin' tab.
type The type of the monitor you want to add. The value should be XenApp.
host The name of the host where the XenApp Server is running.
displayname The display name of the monitor.
UserName The user name of the XenApp Server Host Machine.
password The password of the XenApp Server Host Machine.
version The version of XenApp.

Sample Request:

http://prod-server6:9090/AppManager/xml/AddMonitor?apikey=bc76b1abb8e9b209824a39d84578a194&type=XenApp&host=192.18.3.75&displayname=XenAppServer&UserName =administrator&Password=pass&Version=7.6

vCenter

Syntax:

http://[Host]:[Port]/AppManager/xml/AddMonitor?apikey=[APIKEY]&type=[TYPE]
&displayname=[DISPLAYNAME]&host=[HOST]&port=[PORT]&username=[USERNAME]&password=[PASSWORD]&addtoGroup=[ADDTOGROUP]&groupID=[GROUPID]&monitorvms=[MONITORVMS]
http://[host]:[port]/AppManager/xml/AddMonitor?apikey=[apikey]&type=vCenter&displayname=vctest&vcHost=vcenter&vcPort=443&username=test&password=test&pollInterval=5&isHostDCViaVC=on

Request Parameters:

The parameters involved in the API request are described below. Also, refer the list of common Request Parameters.

Field Description
type The type of the monitor you want to add. Value should be vCenter.
vcHost The name of the host where vCenter is running.
vcPort The port number where the vCenter is running.
username The user name of the vCenter server.
password The password of the vCenter server.
addtoGroup Denotes if the monitor should be added to monitor group. Value is either true or false
isHostDCViaVC Specifies if datacollection should happen using Vcenter credentials or not. Value can be on or off. (optional parameter).

Sample Request:

http://[host]:[port]/AppManager/xml/AddMonitor?apikey=[apikey]&type=vCenter&displayname=vctest&vcHost=vcenter&vcPort=443&username=test&password=test&pollInterval=5

Docker

Syntax:

http://[Host]:[Port]/AppManager/xml/AddMonitor?apikey=[APIKEY]&type=[TYPE]&displayname=[DISPLAYNAME]&host=[HOST]&port=[PORT]&username=[USERNAME]&password=[PASSWORD]&sslenabled=[SSL Enabled]&isAllContainerEnabled=[All Container Enabled]&isCertificateEnabled=[Certificate Enabled]&clientCertName=[Client Certificate Name]&keystorePassword=[Client Certificate Password]

The parameters involved in the API request are described below. Also, refer the list of common Request Parameters.

Field Description
type The type of the monitor you want to add. Value should be Docker.
host The name of the host where Docker is running.
port The port number where Docker is running.
username The user name of the Docker server.
password The password of the Docker server.
sslenabled Option to enable SSL. Possible values are either true or false.
isAllContainerEnabled Option to discover and monitor all the containers that are available under the Docker server. Possible values are either true or false.
isCertificateEnabled Option to enable Client Certificate Authentication for the Docker server you want to monitor. Possible values are either true or false.
clientCertName Name of the Client Certificate.
keystorePassword Password used for the Client Certificate.

Sample Request:

Without Certificate:

http://ProductionServer:6060/AppManager/xml/AddMonitor?apikey=dd2e6f7ec54632b4493d0dc13829df39&type=Docker&displayname=docker&host=testing&port=4243&username=&password=&isSSLEnabled=false&isAllContainerEnabled=true&isCertificateEnabled=false

With Certificate:

http://ProductionServer:6060/AppManager/xml/AddMonitor?apikey=dd2e6f7ec54632b4493d0dc13829df39&type=Docker&displayname=docker&host=testing&port=4243&username=&password=&isSSLEnabled=true&isAllContainerEnabled=true&isCertificateEnabled=true&clientCertName=abcd&keystorePassword=abcd123

Kubernetes

Syntax:

http://[Host]:[Port]/AppManager/xml/AddMonitor?apikey=[APIKEY]&type=[TYPE]&displayname=[DISPLAYNAME]&host=[HOST]&port=[PORT]&username=[USERNAME]&password=[PASSWORD]&mode=SSH&sshPKAuth=[true/false]&prompt=[Prompt]&timeout=[Timeout in Seconds]

The parameters involved in the API request are described below. Also, refer the list of common Request Parameters.

Field Description
type The type of the monitor you want to add. Value should be Kubernetes.
host The name of the host where the Kubernetes cluster is running.
port The port number where Kubernetes is running.
username The user name of the Kubernetes cluster.
password The password of the Kubernetes cluster.
mode The mode through which Kubernetes can be accessed.
sshPKAuth enable Public Key Authentication (Supported for SSH2 only), the SSH Key for SSH authentication.
prompt Specify the command prompt value, which is the last character in your command prompt. Default value is $ and possible values are >, #, etc.
timeout The time out value in seconds.

Sample Request:

http://prod-server5:9090/AppManager/xml/AddMonitor?apikey=0b0e064274e52eead3d1cabdd5ceee04&type=Kubernetes&displayname=kubemaster&host=kubemaster&port=22&username=test&password=test&mode=SSH&sshPKAuth=false&prompt=$&timeout=40

Red Hat Virtualization (RHV)

Syntax:

http://[ Host ]:[ Port ]/AppManager/xml/AddMonitor?apikey=[ API KEY ]&type=[ TYPE ]&displayname=[ DISPLAY NAME ]&host=[ HOST NAME ]&port=[ PORT ]&username=[ USERNAME ]&password=[ PASSWORD ]&pollInterval=[ POLL INTERVAL ]&timeout=[ TIMEOUT ]&discoverVM=[ DISCOVER VM ]

The parameters involved in the API request are described below. Also refer to the list of common Request Parameters.

Parameter Description
type The type of monitor you want to add. The value should be RHEV.
host The name of the host where the RHV server is running.
port The port number where the RHV server is running.
username The user name of the RHV server.
password The password of the RHV server.
discoverVM Indicates the way how the virtual machines of the RHV server are to be monitored. Possible values are:
  • 1 - Discover the virtual machines in Unmanaged state, and monitor only the health and availability of VMs.
  • 2 - Discover the virtual machines in Managed state and monitor all the defined metrics.

Sample Request:

http://localhost:8989/AppManager/xml/AddMonitor?apikey=47e71c777772a41d1482a394070aaae6&type=RHEV&displayname=rhevtest&host=apm-rhvm1.csez.zohocorpin.com&port=443&username=admin@internal&password=NewPassword&pollInterval=5&timeout=300&discoverVM=2

Kernel-based Virtual Machine (KVM)

Syntax:

http://[ APPMANAGER_HOSTNAME ]:[ APPMANAGER_PORT ]/AppManager/xml/AddMonitor?apikey=[ APIKEY ]&type=[ TYPE ]&HostName=[ HOSTNAME ]&displayname=[ DISPLAYNAME ]&mode=[ MODE ]&snmptelnetport=[ PORT ]&username=[ USERNAME ]&password=[ PASSWORD ]&timeout=[ TIMEOUT ]&AddVMS=[ DISCOVERVMs ]

With Credential Manager

Telnet Mode:

http://[ APPMANAGER_HOSTNAME ]:[ APPMANAGER_PORT ]/AppManager/xml/AddMonitor?apikey=[ APIKEY ]&type=[ TYPE ]&HostName=[ HOSTNAME ]&displayname=[ DISPLAYNAME ]&mode=TELNET&snmptelnetport=[ PORT ]&credentialID=[ CREDENTIALID ]&timeout=[ TIMEOUT ]&AddVMS=[ DISCOVERVMs ]&TelnetCredentialDetails=cmTelnet

SSH Mode:

http://[ APPMANAGER_HOSTNAME ]:[ APPMANAGER_PORT ]/AppManager/xml/AddMonitor?apikey=[ APIKEY ]&type=[ TYPE ]&HostName=[ HOSTNAME ]&displayname=[ DISPLAYNAME ]&mode=SSH&snmptelnetport=[ PORT ]&credentialID=[ CREDENTIALID ]&timeout=[ TIMEOUT ]&AddVMS=[ DISCOVERVMs ]&SSHCredentialDetails=cmSSH

The parameters involved in the API request are described below. Also refer to the list of common request parameters.

Parameter Description
type The type of monitor you want to add. The value should be KVM.
HostName The name of the host where the KVM server is running.
mode The mode of monitoring for the KVM server. Possible values are SSH and TELNET.
snmptelnetport The port number where the KVM server is running.
username The user name of the KVM server.
password The password of the KVM server.
AddVM Indicates the way how the virtual machines (VMs) of the KVM server are to be monitored. Possible values are:
  • 0 - VMs will not be discovered.
  • 1 - VMs will be discovered but the metrics will not be monitored. (Will not count for licensing)
  • 2 - VMs will be discovered and monitored.

Sample Request:

http://ProductionServer:6060/AppManager/xml/AddMonitor?apikey=25314fffa16c5975235d56564198e1ba&type=KVM&HostName=kvm-server&displayname=kvm&mode=TELNET&snmptelnetport=23&username=test&password=pwd&timeout=40&AddVMS=2

With Credential Manager

Telnet Mode:

http://ProductionServer:6060/AppManager/xml/AddMonitor?apikey=25314fffa16c5975235d56564198e1ba&type=KVM&HostName=kvm-server&displayname=kvm&mode=TELNET&snmptelnetport=23&credentialID=3&timeout=40&AddVMS=2&TelnetCredentialDetails=cmTelnet

SSH Mode:

http://ProductionServer:6060/AppManager/xml/AddMonitor?apikey=25314fffa16c5975235d56564198e1ba&type=KVM&HostName=kvm-server&displayname=kvm&mode=SSH&snmptelnetport=23&credentialID=3&timeout=40&AddVMS=2&SSHCredentialDetails=cmSSH

OpenShift

Syntax:

http://[Host]:[Port]/AppManager/xml/AddMonitor?apikey=[APIKEY]&type=OpenShift &displayname=[DISPLAYNAME]&host=[HOST]&port=[PORT]&username=[USERNAME]&password=[PASSWORD]&mode=SSH&sshPKAuth=[true/false]&prompt=[Prompt]&OSUsername=[OpenShift Username]&OSPassword=[OpenShiftPassword]&timeout=[Timeout in Sec]

The parameters involved in the API request are described below. Also refer to the list of common Request Parameters.

Parameter Description
type Type of monitor. Value should be OpenShift.
displayname Display name of the monitor
host Name of the machine at which it is hosted on.
port The port number where OpenShift is running.
username The user name of the host server.
password The password of the host server.
mode Mode of authentication. Value should be SSH.
sshPKAuth Whether SSH2 is enabled. Value should be true or false.
prompt Specify the command prompt value, which is the last character in your command prompt.
OSUsername The user name of the OpenShift server.
OSPassword The password of the OpenShift server.

Sample Request:

http://prod-server5:9090/AppManager/xml/AddMonitor?apikey=0b0e064274e52eead3d1cabdd5ceee04&type=OpenShift&displayname=openshift&host=openshift&port=22&username=test&password=test&mode=SSH&sshPKAuth=false&OSUsername=admin&OSPassword=admin&timeout=40

Rest-API with Password:
http://localhost:7700/AppManager/xml/AddMonitor?apikey=6e793c8d4c9b811181258bcd3ce7dde6&type=OpenShift&displayname=openshift&host=openshift&port=22&username=openshift&password=Server@123&mode=SSH&sshPKAuth=false&prompt=$&OSUsername=admin&OSPassword=admin&timeout=40

Rest-API with Credentials:
http://localhost:7700/AppManager/xml/AddMonitor?apikey=6e793c8d4c9b811181258bcd3ce7dde6&type=OpenShift&displayname=openshift&host=openshift&port=22&mode=SSH&credentialID=1&OSUsername=admin&OSPassword=admin&timeout=40

Oracle VM (OVM)

Syntax:

http://[Host]:[Port]/AppManager/xml/AddMonitor?apikey=[API KEY]&type=[TYPE]&displayname=[DISPLAY NAME]&host=[HOST NAME]&port=[PORT]&username=[USERNAME]&password=[PASSWORD]&pollInterval=[POLL INTERVAL]&discoverVM=[DISCOVER VM]&credentialID=[CREDENTIAL ID]&timeout=[TIMEOUT]

The parameters involved in the API request are described below. Also refer to the list of common Request Parameters.

Parameter Description
type The type of monitor you want to add. The value should be OVM.
host The name of the host where the OVM server is running.
port The port number where the OVM server is running.
username The user name of the OVM server.
password The password of the OVM server.
discoverVM Indicates the way how the virtual machines (VMs) of the OVM server are to be monitored. Possible values are:
  • 0 - VMs will not be discovered.
  • 1 - VMs will be discovered but the metrics will not be monitored. (Will not count for licensing)
  • 2 - VMs will be discovered and monitored.
timeout The server connection timeout value of Oracle VM Manager in seconds.

Sample Request:

http://ProductionServer:6060/AppManager/xml/AddMonitor?apikey=f2fe671bf966e8607382fe9af59e9136&type=OVM&displayname=ovmmanager&host=172.24.158.227&port=7002&username=admin&password=Oracle2019&pollInterval=2&discoverVM=2&timeout=300
http://ProductionServer:6060/AppManager/xml/AddMonitor?apikey=f2fe671bf966e8607382fe9af59e9136&type=OVM&displayname=ovmmanager&host=172.24.158.227&port=7002&pollInterval=2&discoverVM=2&timeout=300&credentialID=1