- 23 Jan 2025
- 20 Minutes to read
- Print
- DarkLight
- PDF
CPM APIs
- Updated on 23 Jan 2025
- 20 Minutes to read
- Print
- DarkLight
- PDF
About this Article
This article is intended to highlight the features of the Centralized Probe Management (CPM) API. API is compatible with Version 2.9 and Above - CMS and Probes.
The Install Probe, Upgrade Probe, Uninstall Probe, Install Script and vsp-cli command APIs are available only for Version 2.11 and Above.
Sample API Usage
curl 'https://<CMS_IP_Address>/rms/probes' -H 'Authorization: Basic <base64_encode_of_userid:password>' --insecure
Header:
NOTE
Ensure that Super Admin credentials are used for CPM APIs as other users do not have permission to access the APIs
Content-type: application/json
Authorization: There are two ways of authentication:
API key based:
Applicable for local (Super Admin) users only. Click here for more information
Header Name: X-API-KEY
Header Value: <API KEY>
Auth Token based:
Applicable for both local and Auth0 (Super Admin) users
Header Name: Authorization
Header Value: Bearer <Auth Token>
NOTE
Ensure that Super Admin credentials are used for CPM APIs as other users do not have permission to access the APIs
Content-type: application/json
Authorization: Basic <base64 encode of userid:password>
Procure List of Probes
The below API URL provides information related to the Probes. Only a Super Admin user can utilize this API.
Request Type: GET
URL: https://<CMS_IP_Address>/rms/probes
Response Code:
200 - Success
Sample Response:
[
{
"identifier": "d0528643-21ae-4fe3-9067-58693893e13f",
"ipaddr": "10.15.31.15",
"hostname": "ubuntu16.virsec.local",
"vsp_version": "2.6.0",
"status": "ACTIVE"
},
{
"identifier": "3c0fae9a-0075-4e8d-8d90-59ad94d0fb12",
"ipaddr": "10.15.31.17",
"hostname": "ubuntu16.virsec.local",
"vsp_version": "dakota.qa2",
"status": "ACTIVE"
}
]
NOTE
It is recommended to use the hostname of Probes for verification purposes than the IP Address. The IP Address value may not be accurate always.
Procure Logs
The below API procures logs from the Probe instances:
URL/JSON | Request Type | Description |
---|---|---|
URL: | GET | Fetches logs from all the Probes |
URL: | GET | Fetches log from a specific probe. Probe IDs can be procured from https://<CMS_IP_Address>/rms/probes as described in Procure List of Probes |
URL: JSON: { | POST | Fetches log from a group of probes. Probe IDs can be procured from https://<CMS_IP_Address>/rms/probes as described in Procure List of Probes |
Response Code:
200 - Success
Sample Responses:
Response containing link to the status URL:
{
"status": "SUCCESS",
"message": "log-file fetch started, view status at url - /rms/status/cmd_489d40a5-85dd-4316-a06e-073e23223aca",
"url": "/rms/status/cmd_489d40a5-85dd-4316-a06e-073e23223aca",
"api": "Fetch log"
}
Response containing status of all the probes along with the download path:
{
"status": "SUCCESS",
"api": "Fetch log",
"probeList": [
{
"host": "ubuntu16",
"ip": "10.15.50.15",
"identifier": "1f96fdb6-cd50-4558-a315-530e8038b1b5",
"downloadUrl": "/rms/download/1f96fdb6-cd50-4558-a315-530e8038b1b5/vsp_log_ubuntu16_2023-07-26.tar.gz",
"status": "SUCCESS"
}
]
}
In a successful response, the download URL link is provided for each Probe. The log files can be downloaded once the status changes to “SUCCESS”. If not, access/refresh the URL after some time to ensure that the log collection is complete and the status changes to “SUCCESS”.
Procure Statistics
The below API procures statistics from the Probe instances:
URL/JSON | Request Type | Description |
---|---|---|
URL: | GET | Fetches statistics from all the Probes |
URL: | GET | Fetches statistics from a specific probe. Probe IDs can be procured from https://<CMS_IP_Address>/rms/probes as described in Procure List of Probes |
URL: JSON: { | POST | Fetches statistics from a group of probes. Probe IDs can be procured from https://<CMS_IP_Address>/rms/probes as described in Procure List of Probes |
Response Code:
200 - Success
Sample Response:
Response containing a link to the status URL:
{
"status": "SUCCESS",
"message": "stats-file fetch started, view status at url - /rms/status/cmd_489d40a5-85dd-4316-a06e-073e23223aca",
"url": "/rms/status/cmd_489d40a5-85dd-4316-a06e-073e23223aca",
"api": "Fetch stats"
}
In a successful response, the download URL link is provided for each Probe. The statistics files can be downloaded once the status changes to “SUCCESS”. If not, access/refresh the URL after some time to ensure that the statistics collection is complete and the status changes to “SUCCESS”.
Procure Data
The below API procures data from the Probe instances:
URL/JSON | Request Type | Description |
---|---|---|
URL: | GET | Fetches data from all the Probes |
URL: | GET | Fetches data from a specific probe. Probe IDs can be procured from https://<CMS_IP_Address>/rms/probes as described in Procure List of Probes |
URL: JSON: { | POST | Fetches data from a group of probes. Probe IDs can be procured from https://<CMS_IP_Address>/rms/probes as described in Procure List of Probes |
Response Code:
200 - Success
Sample Response:
Response containing a link to the status URL:
{
"status": "SUCCESS",
"message": "data-file fetch started, view data at url - /rms/status/cmd_489d40a5-85dd-4316-a06e-073e23223aca",
"url": "/rms/data/cmd_489d40a5-85dd-4316-a06e-073e23223aca",
"api": "Fetch data"
}
In a successful response, the download URL link is provided for each Probe. The data files can be downloaded once the status changes to “SUCCESS”. If not, access/refresh the URL after some time to ensure that the data collection is complete and the status changes to “SUCCESS”.
Modify Log Levels
Modify the log levels using the below information. Log level modifications are supported on individual probes only. Allowed log levels are - debug, info, trace.
URL/JSON | Description |
---|---|
URL: |
|
URL: |
|
URL: |
|
Sample Response:
Modify the log level for a specific module:
{
"status": "SUCCESS",
"logMessage": "Setting log level, view status at url - /rms/status/cmd_230ead5f-b2ce-40c0-9533-370a5476b564",
"url": "/rms/status/cmd_230ead5f-b2ce-40c0-9533-370a5476b564",
"apiCommand": "change loglevel to debug , for module ae"
}
Download Files
The API lists all the files available on the probe.
URL | Method | Description |
---|---|---|
https://<CMS_IP_Address>/rms/download/{probeid} | GET | List all available fetched files such logs/stats or data from a specific probe identified by probeid |
https://<CMS_IP_Address>/rms/download | GET | List all available fetched files such logs/stats or data from all probes |
Response Code:
200 - Success
Sample Responses:
Download file list from the required probe:
[
{
"identifier": "1f96fdb6-cd50-4558-a315-530e8038b1b5",
"name": "vsp_data_ubuntu16_2023-07-26.zip",
"probeid": "1f96fdb6-cd50-4558-a315-530e8038b1b5",
"url": "/rms/download/1f96fdb6-cd50-4558-a315-530e8038b1b5/vsp_data_ubuntu16_2023-07-26.zip"
}
]
Download file list from all probes:
[
{
"identifier": "1f96fdb6-cd50-4558-a315-530e8038b1b5",
"name": "vsp_data_ubuntu16_2023-07-26.zip",
"probeid": "1f96fdb6-cd50-4558-a315-530e8038b1b5",
"url": "/rms/download/1f96fdb6-cd50-4558-a315-530e8038b1b5/vsp_data_ubuntu16_2023-07-26.zip"
},
{
"identifier": "1f96fdb6-cd50-4558-a315-530e8038b1b5",
"name": "vsp_stats_ubuntu16_2023-07-25.zip",
"probeid": "1f96fdb6-cd50-4558-a315-530e8038b1b5",
"url": "/rms/download/1f96fdb6-cd50-4558-a315-530e8038b1b5/vsp_stats_ubuntu16_2023-07-25.zip"
},
{
"identifier": "d71d0fbf-f318-4519-bf12-facca50e9607",
"name": "vsp_log_ks2050_2023-07-26.tar.gz",
"probeid": "d71d0fbf-f318-4519-bf12-facca50e9607",
"url": "/rms/download/d71d0fbf-f318-4519-bf12-facca50e9607/vsp_log_ks2050_2023-07-26.tar.gz"
},
]
View Commands
This API lists all the requests submitted to this API with the status of completion.
Accepted Parameters:
from - Integer “n” can be provided as the optional parameter in “from” to view all the API requests submitted for the past “n” hours. If the parameter “from” is not provided or is invalid, all the API requests submitted are provided
cmdpage – Integer “i” can be provided as the optional parameter in “cmdpage” to specify the number of commands to be displayed per page
probepage - Integer “j” can be provided as the optional parameter in “probepage” to specify the number of probes to be displayed per page
Request Type: GET
URL: https://<CMS_IP_Address>/rms/view/api?from={n}&cmdpage={i}&probepage={j}
Sample Response:
{
"apiRequest": "Fetch Data",
"commandUuid": "cmd_a5929978-16c1-4489-a52d-e9fd8c65caea",
"timestamp": "2023-07-06T11:34:11.91",
"commandStatus": "SUCCESS",
"probeStatusList": {
"8aa9017b-b347-404a-8d4a-0dc90342a253": {
"tenentId": "default",
"ipaddr": "172.30.208.1",
"hostname": "host.docker.internal",
"version": "Not Installed",
"identifier": "8aa9017b-b347-404a-8d4a-0dc90342a253",
"downloadUrl": "/rms/download/8aa9017b-b347-404a-8d4a-0dc90342a253",
"executionStatusTimestamp": "2023-07-06T11:34:11.91",
"status": "SUCCESS",
"logbuffer": "\nhost.docker.internal -> Status: SUCCESS Reason: \nhost.docker.internal ->\tCommand successfully complete",
"errorbuffer": ""
}
}
}
Install Probe
This API is available only for Version 2.11 and Above.
Probe installation can be performed using the below information:
Accepted Parameters: All the parameters are optional. If they are not provided, the default values are utilized by the Probe installable
cmsdns – DNS name for CMS
kafkadns - DNS name for Kafka
remoteae – true (for Remote vRule Engine) OR false (for Embedded vRule Engine)
hostentry – Entries are not added in the file /etc/hosts to resolve the LFR and CMS DNS names. Allowed values are: true OR false
password – Base64 encoded password
sku – (Linux only) Required SKU. Allowed values are: web, host OR mem. Default value is web (if not specified)
hostname – Hostname of the Probe
hostProfileTag - Host Profile Tag allows for an application instance to be auto-associated with a process profile on CMS
appServiceTags - List of app service tags separated by a comma; App service tags enable an Application Instance to be auto-associated with an application on CMS
hostonly - (Windows only) To install HOST-ONLY features. Allowed Values are 0 (complete installation) or 1 (Host only installation)
The below parameters are available for Version 3.0.0 and above:
lfrport - VSP LFR Port
cmsip - IP Address of CMS
kafkaip - IP Address of Kafka. This parameter is required if CMS IP and Kafka IP are different
lfrip - IP Address of LFR
URL/JSON | Request Type | Description |
---|---|---|
URL: | GET | A specific Probe is installed to the Version present on LFR |
URL: Request JSON: { | POST | Installation on specific Probes connected with CMS. The provided parameter values are common for all the mentioned Probes. If the values differ, ensure that separate API calls are made for the corresponding probes |
URL/JSON | Request Type | Description |
---|---|---|
URL: | GET | A specific Probe is installed to the Version present on LFR |
URL: Request JSON: { | POST | Installation on specific Probes connected with CMS. The provided parameter values are common for all the mentioned Probes. If the values differ, ensure that separate API calls are made for the corresponding probes |
Response Code:
200 - Success
Sample Response: Single Probe Installation (GET)
{
"status": "SUCCESS",
"message": "install started, view status at url - /rms/status/cmd_0c64fb24-0bd8-4d1c-947d-f30483fafd02",
"url": "/rms/status/cmd_0c64fb24-0bd8-4d1c-947d-f30483fafd02",
"api": "install probe",
"version": "latest"
}
Upgrade Probe
This API is available only for Version 2.11 and Above.
Probe upgrade can be performed using the below information:
NOTE
sku modifications during upgrade is not supported.
Accepted Parameters: All the parameters are optional. If they are not provided, the default values are utilized by the Probe installable
version – VSP version to which the Probe must be upgraded. This version must be available on LFR. Currently, only the value “latest” is allowed as LFR contains only one VSP version
cmsdns – Custom DNS name for CMS. Ensure that the value provided during upgrade is the same as the value provided during installation
kafkadns – Custom DNS name for Kafka. Ensure that the value provided during upgrade is the same as the value provided during installation
remoteae – true (for Remote vRule Engine) OR false (for Embedded vRule Engine; Default Value)
hostentry – Entries are not added in the file /etc/hosts to resolve the LFR and CMS DNS names. Allowed values are: true (Default Value) OR false
password – Base64 encoded password
The below parameters are available for Version 3.0.0 and above:
hostname - Hostname of the Probe. This is utilized during probe registration with CMS
hostprofiletag - Appropriate Host Profile Tag. A Host Profile Tag allows for an application instance to be auto-associated with a process profile on CMS
sku – (Linux only) Required SKU. Allowed values are: web, host OR mem. Default value is web (if not specified)
appservicetags - List of comma-separated Application Service tags to enable a Probe to auto-associate with a CMS Application
hostonly - To install HOST-ONLY features. Allowed Values are: true (HOST-ONLY features) or false
lfrport - VSP LFR Port
cmsip - IP Address of CMS
kafkaip - IP Address of Kafka. This parameter is required if CMS IP and Kafka IP are different
lfrip - IP Address of LFR
URL/JSON | Request Type | Description |
---|---|---|
URL: | GET | A specific Probe is installed to the Version present on LFR. probeid is a required parameter |
URL: | GET | All Probes registered with CMS are upgraded to the provided Version present on LFR |
URL: Request JSON: { "cmsip" : "<CMS IP Address>", "lfrip" : "<LFR IP Address>", "kafkaip" : "<Kafka IP Address>", "cmsdns" : "<Custom CMS DNS Name>", "kafkadns" : "<Custom Kafka DNS Name>", "remoteae" : "<true | false>", "hostentry" : "<true | false>", "version" : "latest", "password" : "<base 64 econded>", "sku" : "<web | host | mem>", "hostname" : "<hostname>", "hostProfileTag" : "hpt1", "appServiceTags" : ["tag1","tag2"], "hostonly" : "", "probeSet" : [ "uuid1", "uuid2" ], "lfrport" : "<LFR Port>" } | POST | Specific Probes are upgraded to the provided Version present on LFR. The provided parameter values are common for all the mentioned Probes. If the values differ, ensure that separate API calls are made for the corresponding probes. All the parameters are optional |
URL/JSON | Request Type | Description |
---|---|---|
URL: | GET | A specific Probe is installed to the Version present on LFR. probeid is a required parameter |
URL: | GET | All Probes registered with CMS are upgraded to the provided Version present on LFR |
URL: Request JSON: { | POST | Specific Probes are upgraded to the provided Version present on LFR. The provided parameter values are common for all the mentioned Probes. If the values differ, ensure that separate API calls are made for the corresponding probes |
Response Code:
200 - Success
Sample Response: Single Probe Upgrade (GET)
{
"status": "SUCCESS",
"message": "upgrade started, view status at url - /rms/status/cmd_0c64fb24-0bd8-4d1c-947d-f30483fafd02",
"url": "/rms/status/cmd_0c64fb24-0bd8-4d1c-947d-f30483fafd02",
"api": "upgrade probe",
"version": "2.11.0"
}
Uninstall Probe
This API is available only for Version 2.11 and Above.
Probe installation can be performed using the below information:
Accepted Parameters:
password – Base64 encoded password
URL/JSON | Request Type | Description |
---|---|---|
URL: | GET | A specific Probe is uninstalled |
URL: Request JSON: { | POST | Un-installation on specific Probes connected with CMS |
Response Code:
200 - Success
Sample Response: Single Probe Uninstallation (GET)
{
"status": "SUCCESS",
"message": "uninstall started, view status at url - /rms/status/cmd_0c64fb24-0bd8-4d1c-947d-f30483fafd02",
"url": "/rms/status/cmd_0c64fb24-0bd8-4d1c-947d-f30483fafd02",
"api": "uninstall probe",
"version": "latest"
}
Install Script
This API is available only for Version 2.11 and Above. It enables installation of a script from LFR to a Probe machine.
Accepted Parameters:
sourcePath – (Required) Specify the relative source path of the script on LFR. It must specify a file. Example: If the LFR path is: https://<LFR_IPAddress>:8443/vsp/pas1/pa1.sh then source path must be /vsp/pas1/pa1.sh
destPath – (Required) Specify the directory path on the Probe where the script must be copied. This directory must be present on the Probe, else the API fails
user – (Optional) Specify the owner of the copied script. If not specified, it Is deployed with the same user running the CPM client
userGroup – (Optional) Specify the user group of the copied script
Request Type: POST
URL: https://<CMS_IP_Address>/rms/install/script
Request JSON:
{
"sourcePath":"/vsp/pas1/pa1.sh",
"destPath":"/opt/vspcpm/script/pas1/pas1.sh",
"user":"virsec",
"userGroup":"virsec",
"probeSet":[
"PROBE_ID1",
"PROBE_ID2"
]
}
Sample Response:
{
"status": "SUCCESS",
"message": "Installation of Script started, view status at url - /rms/status/cmd_0c64fb24-0bd8-4d1c-947d-f30483fafd02",
"url": "/rms/status/cmd_0c64fb24-0bd8-4d1c-947d-f30483fafd02",
"api": "install script",
"version": "latest"
}
Error Scenarios
sourcePath
If it is not provided, the API execution fails
It must specify a file inside the LFR. It should not be a directory
destPath – All the parent directories of the destPath must be present on the Probe. If it is not present, the API execution fails
user - Should be an existing user on the Probe. In cases where the user does not exist, the script is copied on the Probe using user running the cpm-client. The change in owner to the specified user fails
userGroup - Should be an existing user group on the Probes. In cases where the user group does not exist, the script is copied on the Probe using user running the cpm-client. The change in owner to the specified user group fails
Migrate Probe
This API is available only for Version 3.0.0 and Above.
Probe migration from On-prem to SaaS CMS can be performed using the below information:
NOTE
sku modifications during migration is not supported
Ensure that the migration process is followed along while this API is used
Accepted Parameters: All the parameters are optional. If they are not provided, the default values are utilized by the Probe installable
version – VSP version to which the Probe must be upgraded. This version must be available on LFR. Currently, only the value “latest” is allowed as LFR contains only one VSP version
cmsdns – Custom DNS name for CMS. Ensure that the value provided during upgrade is the same as the value provided during installation
kafkadns – Custom DNS name for Kafka. Ensure that the value provided during upgrade is the same as the value provided during installation
remoteae – true (for Remote vRule Engine) OR false (for Embedded vRule Engine; Default Value)
hostentry – Entries are not added in the file /etc/hosts to resolve the LFR and CMS DNS names. Allowed values are: true (Default Value) OR false
password – Base64 encoded password
hostname - Hostname of the Probe. This is utilized during probe registration with CMS
hostprofiletag - Appropriate Host Profile Tag. A Host Profile Tag allows for an application instance to be auto-associated with a process profile on CMS
sku – (Linux only) Required SKU. Allowed values are: web, host OR mem. Default value is web (if not specified)
appservicetags - List of comma-separated Application Service tags to enable a Probe to auto-associate with a CMS Application
hostonly - To install HOST-ONLY features. Allowed Values are: true (HOST-ONLY features) or false
lfrport - VSP LFR Port
cmsip - IP Address of CMS
kafkaip - IP Address of Kafka. This parameter is required if CMS IP and Kafka IP are different
lfrip - IP Address of LFR
URL/JSON | Request Type | Description |
---|---|---|
URL: | GET | A specific Probe is migrated to the Version present on LFR. probeid is a required parameter |
URL: | GET | All Probes registered with CMS are migrated to the provided Version present on LFR |
URL: Request JSON: { "cmsip" : "<CMS IP Address>", "lfrip" : "<LFR IP Address>", "kafkaip" : "<Kafka IP Address>", "cmsdns" : "<Custom CMS DNS Name>", "kafkadns" : "<Custom Kafka DNS Name>", "remoteae" : "<true | false>", "hostentry" : "<true | false>", "version" : "latest", "password" : "<base 64 econded>", "sku" : "<web | host | mem>", "hostname" : "<hostname>", "hostProfileTag" : "hpt1", "appServiceTags" : ["tag1","tag2"], "hostonly" : "", "probeSet" : [ "uuid1", "uuid2" ], "lfrport" : "<LFR Port>" } | POST | Specific Probes are migrated to the provided Version present on LFR. The provided parameter values are common for all the mentioned Probes. If the values differ, ensure that separate API calls are made for the corresponding probes. All the parameters are optional |
Response Code:
200 - Success
Sample Response: Single Probe Migration (GET)
{ "status": "SUCCESS", "message": "Probe Migration started, view status at url - /rms/status/cmd_0f42d3c3-f556-436d-8c65-bf93faefd5be. This is async operation, visit /rms/probes to check if CPM got updated.", "url": "/rms/status/cmd_0f42d3c3-f556-436d-8c65-bf93faefd5be", "api": "cpm migrate probe", "version": "latest" }
Self Upgrade
This API is available only for Version 3.0.0 and Above.
It upgrades CPM installed on the probe to the latest version that is available in LFR.
Pre-requisite: Ensure that the client certificates are downloaded and placed in LFR by following the below steps:
Download the certificates on LFR directory: /var/www/html/vsp using the API below:
Request Type: GET
URL:https://<CMS_IP_OR_DOMAIN>/rms/download/tenantcerts?type=<zip|tar>
type - Provide the value "tar" for Linux and "zip" for Windows
The file name must be certificates.tar for Linux and certificates.zip for Windows
Provide the file with appropriate read permissions
Shell
## Linux chmod 644 certificates.tar ## Windows chmod 644 certificates.zip
NOTE
Ensure that the certificates are removed from LFR after Self Upgrade using API
Version 3.1.0 and Above: Ensure that the VSP services are stopped on Linux before using this API
Accepted Parameters: All the parameters are optional. If they are not provided, the default values are utilized by the Probe installable
version – VSP version to which the Probe must be upgraded. This version must be available on LFR. Currently, only the value “latest” is allowed as LFR contains only one VSP version
cmsdns – Custom DNS name for CMS. Ensure that the value provided during upgrade is the same as the value provided during installation
kafkadns – Custom DNS name for Kafka. Ensure that the value provided during upgrade is the same as the value provided during installation
hostentry – Entries are not added in the file /etc/hosts to resolve the LFR and CMS DNS names. Allowed values are: true (Default Value) OR false
lfrport - VSP LFR Port
cmsip - IP Address of CMS
kafkaip - IP Address of Kafka. This parameter is required if CMS IP and Kafka IP are different
lfrip - IP Address of LFR
URL/JSON | Request Type | Description |
---|---|---|
URL: | GET | CPM on a specific Probe is upgraded to the specified version on LFR. probeid is a required parameter |
URL: | GET | All Probes registered with CMS are upgraded to the specified version on LFR |
URL: Request JSON: { "cmsdns" : "<Custom CMS DNS Name>", "kafkadns" : "<Custom Kafka DNS Name>", "hostentry" : "<true | false>", "probeSet" : [ "uuid1", "uuid2" ], "cmsip" : "<CMS IP Address>", "kafkaip" : "<Kafka IP Address>", "lfrip" : "<LFR IP Address>", "lfrport" : "<LFR Port>" } | POST | CPM on specific Probes are upgraded to the provided Version present on LFR. The provided parameter values are common for all the mentioned Probes. If the values differ, ensure that separate API calls are made for the corresponding probes. All the parameters are optional |
Response Code:
200 - Success
Sample Response: Single Probe Self Upgrade (GET)
{ "status": "SUCCESS", "message": "Self upgrade started, view status at url - /rms/status/cmd_892b4022-8ed9-4d3c-98a1-c207d51c3cae. This is async operation, visit /rms/probes to check if CPM got updated. ", "url": "/rms/status/cmd_892b4022-8ed9-4d3c-98a1-c207d51c3cae ", "api": "cpm self upgrade ", "version": "latest" }
VSP-CLI Command
This API is available only for Version 2.11 and Above. It API can be used to execute vsp-cli commands on a Probe machine.
Accepted Parameters:
arguments– (Required) Accepts all the arguments that are required by vsp-cli command
Example: To execute the command “vsp-cli start ae”, the value for arguments is: [“start”, “ae”]
Request Type: POST
URL: https://<CMS_IP_Address>/rms/vspcli
Request JSON:
{
"arguments":["config", "ae", "edit", "logLevel","debug"],
"password":<base64 encoded password>,
"probeSet":[
"PROBE_ID1",
"PROBE_ID2"
]
}
Sample Response:
[
{
"status": "SUCCESS",
"api": "vsp-cli command",
"probeList": [
{
"host": "EC2AMAZ-G72FI03",
"identifier": "439d26d7-694e-4dda-b8b2-d99a569fd743",
"errorMessage": "",
"logMessage": "\nEC2AMAZ-G72FI03 -> Status: SUCCESS Reason: N/A\nEC2AMAZ-G72FI03 ->\t172.31.28.107\nEC2AMAZ-G72FI03 -> Status: SUCCESS Reason: ",
"status": "SUCCESS"
}
]
}
]
Service Command
Version 3.0.0 and Above:
This API is used to start or stop VSP services using VSP-Cli command.
Accepted Parameters:
action - stop or start
serviceid – vsp
probSet - Set of probe IDs where the vsp-cli command must be executed
Request Type: POST
URL: https://<CMS_IP_Address>/rms/service
Sample Request:
{
"action":"stop/start",
"serviceId":"vsp"
"probeSet":[
"9dd25f35-3464-4b97-aa4b-c24b3d390fc5“,
"9dd25f35-3464-4b97-aa4b-c24b3d390fc4"
]
}
Sample Response:
{
"status": "SUCCESS",
"message": "vsp service is : stoped via API",
"url": "/rms/status/cmd_56036343-b49f-444a-9df7-e357d4a3c779",
"api": "service start/stop API",
"version": "latest"
}
Error Reponses
Error responses with sample responses applicable for all the APIs mentioned in the previous sections are provided here:
Error Code 400 – Probe ID is invalid or Module ID is invalid
Sample Response 1 – Invalid Probe ID
{
"status": "INVALID_PROBEID",
"errorMessage": "Invalid probeid",
"apiCommand": "change loglevel to info , for module ae"
}
Sample Response 2 – Invalid Module ID
{
"status": "INVALID_MODULE",
"errorMessage": "Invalid module, allowed - (ae|fde|fsm|hmm|rmp|vipcs|vma|weba|vmgr|aep)",
"apiCommand": "change loglevel to info , for module aem"
}
Sample Response 3 – Invalid SKU value
{
"status": "INVALID_PARAMETER",
"error": "Given sku is invalid. possible values are - (web|host|mem)",
"api": "install probe"
}
Error Code 404 – Probe is not found
{
"status": "PROBE_NOT_FOUND",
"errorMessage": "Probe not found - 3c0fae9a-0075-4e8d-8d90-59ad94d0fb13",
"apiCommand": "change loglevel to info , for module ae"
}
Error Code 401 – User is unauthorized and user authentication failed