Adding Uptime Devices
Last updated – 23 April, 2026
You can use LogicMonitor REST API v3 to add both internal and external Uptime web and ping devices to your LogicMonitor account.
Adding Uptime Internal Web Device
You can use LogicMonitor REST API v3 to add Uptime internal web devices. You must authenticate before making the API request.
URI: POST /device/devices
The following table describes parameters used in the API request:
| Parameter | Type | Description |
|---|---|---|
type | String |
Specify the Uptime device type. Supported values are:
"type": "uptimewebcheck"
|
deviceType | Integer | For Uptime internal web check device, specify the device type as 18.By default, the value is set to 0.Example— "deviceType":18 |
name | String | Name of the Uptime internal web check device that you want to add. Example— "name": "Test-Web-Check-Int-V3-Int-New-4" |
description | String | Description of the Uptime internal web check device. Example— "description": "Internal Web Check for google.com" |
groupIds | List of String | A list of group IDs associated with the Uptime internal web check device. For example, "groupIds": ["1","3774"] indicate that Uptime internal web check device is part of groupId “1” and “3774”.Example— "groupIds": "3774" |
isInternal | Boolean | For Uptime internal web check device, set the value to true indicating that the device is monitored by an internal LogicMonitor Collector.Example— "isInternal": true |
individualSmAlertEnable | Boolean |
You can associate Uptime internal web check device with a single or multiple LogicMonitor Collectors.
false.Example— "individualSmAlertEnable": true
|
individualAlertLevel | String | The alert level set for individual instance if individualSmAlertEnable=trueSupported values are warn, error, and critical. By default, the alert level is set to warn.Example— "individualAlertLevel": "error" |
overallAlertLevel | String | The alert level applied to the overall instance of the web check. Supported values are warn, error, and critical. By default, the alert level is set to warn.Example— "overallAlertLevel": "warn" |
pollingInterval | Integer | Indicates the interval (in minutes) of checking service on a regular basis. Supported polling interval must be between 1 to 10 minutes. The default polling interval is set to 5 minutes.Example— "pollingInterval": 1 |
transition | Integer | The number of checks that must fail before an alert is triggered. Supported values are 1–10, 30, and 60. By default, the number of check is set to 1 indicating that an alert is triggered immediately after the first occurrence of incorrect raw data.Example— "transition": 1 |
globalSmAlertCond | Integer |
Indicates the minimum number of test locations that must fail to trigger an alert. Supported values are:
0.Example— "globalSmAlertCond": 1
|
useDefaultLocationSetting | Boolean | Indicate whether the website’s default location settings must be used when creating instances for the selected default checkpoints. By default, the value is set to false, indicating that settings in the current request are used for instance creation.Example— "useDefaultLocationSetting": false |
useDefaultAlertSetting | Boolean | Indicate whether the website’s default alert settings must be applied to instances created for the selected checkpoints. By default, the value is set to false, indicating that settings in the current request are applied to the instances.Example— "useDefaultAlertSetting": false |
testLocation | JSON Object |
The location from which the configured check is monitored. For internal web check, configured collectorIds monitor the devices.The following parameters must be specified in the JSON object:
“{\”collectorIds\”:[12,67]}”By default, the value is set to “{\”all\”:true}”Example— "testLocation": { "all": false, "collectorIds": [ 12248 ], "smgIds": [] }
|
properties | List of Key Value | Properties linked with the web check. You must provide properties in the following format:[{name1, value1}, {name2, value2}]Example— "properties": [{ "name": "testname", "value": "testvalue" }] |
template | JSON Object | A template to create website. By default, the value is set to null.Example— "template": null |
steps | JSON Object |
An object comprising one or more steps.
|
domain | String | Domain or base URL of the website. Example— "domain": "www.google.com" |
ignoreSSL | Boolean | Indicate whether SSL must be ignored or applied for each web check. By default, the value is set to false.Example— "ignoreSSL": true |
pageLoadAlertTimeInMS | Integer | Maximum time (in milliseconds) a web page can load for each step before an alert is triggered. By default, the value is set to 30000.Example— "pageLoadAlertTimeInMS": 30000 |
schema | String | The schema or protocol associated with the URL. Supported values are http and https.By default, the value is set to http.Example— "schema": "https" |
alertExpr | String |
The SSL certificate alert threshold (in days). If triggerSSLExpirationAlert is true, then it is mandatory to specify value for alertExpr.Example— "< 200 100 50"
"alertExpr": "< 30 25 15"
|
triggerSSLStatusAlert | Boolean |
You can enable or disable alerts based on the current status of the SSL certificate.
false.Example— "triggerSSLStatusAlert": false
|
triggerSSLExpirationAlert | Boolean |
You can enable or disable alerts reminding of upcoming SSL certificate expiry.
false.Example— "triggerSSLExpirationAlert": false
|
The following Python script adds Uptime internal web device to your LogicMonitor account:
#!/bin/env python
import requests
import json
import hashlib
import base64
import time
import hmac
import getpass
#Account Info: LogicMonitor recommends to NEVER hardcode the credentials. Instead, retrieve the values from a secure storage.
#Note: The below is provided for illustration purposes only.
AccessId = getpass.getpass("Enter your AccessId: ")
AccessKey = getpass.getpass("Enter your AccessKey: ")
Company = 'COMPANY_NAME'
#Request Info
httpVerb ='POST'
resourcePath = '/device/devices'
queryParams = ''
data = '{"type":"uptimewebcheck","deviceType":18,"id":0,"name":"UptimeInternalWebCheck","description":"","groupIds":["1"],"isInternal":true,"individualSmAlertEnable":true,"individualAlertLevel":"error","overallAlertLevel":"warn","pollingInterval":1,"transition":1,"globalSmAlertCond":0,"useDefaultLocationSetting":false,"useDefaultAlertSetting":false,"testLocation":{"all":true,"collectorIds":[4],"smgIds":[]},"properties":[],"template":null,"steps":[{"type":"script","enable":true,"useDefaultRoot":true,"url":"","HTTPVersion":"1.1","HTTPMethod":"GET","name":"__step0","followRedirection":true,"fullpageLoad":false,"requireAuth":false,"auth":{"domain":"","password":"","type":"basic","userName":""},"HTTPHeaders":"","reqType":"config","respType":"config","matchType":"plain","keyword":"","invertMatch":"false","statusCode":"","path":""}],"domain":"www.google.com","ignoreSSL":true,"pageLoadAlertTimeInMS":30000,"schema":"https","alertExpr":"","triggerSSLStatusAlert":false,"triggerSSLExpirationAlert":false}'
#Construct URL
url = 'https://'+ Company +'.logicmonitor.com/santaba/rest' + resourcePath +queryParams
#Get current time in milliseconds
epoch = str(int(time.time() * 1000))
#Concatenate Request details
requestVars = httpVerb + epoch + data + resourcePath
#Construct signature
digest = hmac.new(
AccessKey.encode('utf-8'),
msg=requestVars.encode('utf-8'),
digestmod=hashlib.sha256).hexdigest()
signature = base64.b64encode(digest.encode('utf-8')).decode('utf-8')
#Construct headers
auth = 'LMv1 ' + AccessId + ':' + str(signature) + ':' + epoch
headers = {'Content-Type':'application/json','Authorization':auth,'X-Version':'3'}
#Make request
response = requests.post(url, data=data, headers=headers)
#Print status and body of response
print('Response Status:',response.status_code)
print('Response Body:',response.content)Adding Uptime External Web Device
You can use LogicMonitor REST API v3 to add Uptime external web devices. You must authenticate before making the API request.
URI: POST /device/devices
The following table describes parameters used in the API request:
| Parameter | Type | Description |
|---|---|---|
type | String |
Specify the Uptime device type. Supported values are:
"type": "uptimewebcheck"
|
deviceType | Integer | For Uptime external web check device, set the device type as 18.By default, the value is set to 0.Example— "deviceType":18 |
name | String | Name of the Uptime external web check device that you want to add. Example— "name": "Test-Web-Check-Ext-V3-Ext-New-5" |
description | String | Description of the Uptime external web check device. Example— "description": "External Web Check for google.com" |
groupIds | List of String | A list of group IDs associated with the Uptime external web check device. For example, "groupIds": ["2","3775"] indicate that Uptime internal web check device is part of groupId “2” and “3775”.Example— "groupIds": "3775" |
isInternal | Boolean | For Uptime external web check device, set the value to false indicating that the device is monitored by external Site Monitors located at various geographical regions.Example— "isInternal": false |
individualSmAlertEnable | Boolean | You can associate Uptime external web check device with a single or multiple Site Monitors.
false.Example— "individualSmAlertEnable": true |
individualAlertLevel | String | The alert level set for individual instance if individualSmAlertEnable=trueSupported values are warn, error, and critical. By default, the alert level is set to warn.Example— "individualAlertLevel": "error" |
overallAlertLevel | String | The alert level applied to the overall instance of the web check. Supported values are warn, error, and critical. By default, the alert level is set to warn.Example— "overallAlertLevel": "warn" |
pollingInterval | Integer | Indicates the interval (in minutes) of checking service on a regular basis. Supported polling interval must be between 1 to 10 minutes. By default, the polling interval is set to 5 minutes.Example— "pollingInterval": 2 |
transition | Integer | The number of checks that must fail before an alert is triggered. Supported values are 1–10, 30, and 60. By default, the number of check is set to 1 indicating that an alert is triggered immediately after the first occurrence of incorrect raw data.Example— "transition": 1 |
globalSmAlertCond | Integer | Indicates the minimum number of test locations that must fail to trigger an alert. Supported values are:
0.Example— "globalSmAlertCond": 0 |
useDefaultLocationSetting | Boolean | Indicate whether the default location settings of the website must be used when creating instances for selected default checkpoints. By default, the value is set to false, indicating that settings in the current request are used for instance creation.Example— "useDefaultLocationSetting": false |
useDefaultAlertSetting | Boolean | Indicate whether the default alert settings of the website must be applied to instances created for selected checkpoints. By default, the value is set to false, indicating that settings in the current request are applied to the instances.Example— "useDefaultAlertSetting": false |
testLocation | JSON Object | The location from which the configured check is monitored. For external web check, configured smgIds monitor the devices.The following parameters must be specified in the JSON object:
Example— “{\”smgIds\”:[2,3]}”Note: You must encode the inner string. By default, the value is set to “{\”all\”:true}”Example— "testLocation": { "all": true, "collectorIds": [ ], "smgIds": [2,3,4] } |
properties | List of Key Value | Properties linked with the web check. You must provide properties in the following format:[{name1, value1}, {name2, value2}]Example— "properties": [{ "name": "testname", "value": "testvalue" }] |
template | JSON Object | A template to create website. By default, the value is set to null.Example— "template": null |
steps | JSON Object |
An object comprising one or more steps.
|
domain | String | Domain or base URL of the website. Example— "domain": "www.google.com" |
ignoreSSL | Boolean | Indicate whether SSL must be ignored or applied for each web check. By default, the value is set to false.Example— "ignoreSSL": true |
pageLoadAlertTimeInMS | Integer | Maximum time (in milliseconds) a web page can load for each step before an alert is triggered. By default, the value is set to 30000.Example— "pageLoadAlertTimeInMS": 30000 |
schema | String | The schema or protocol associated with the URL. Supported values are http and https.By default, the value is set to http.Example— "schema": "https" |
alertExpr | String | The SSL certificate alert threshold (in days). If triggerSSLExpirationAlert is true, then it is mandatory to specify value for alertExpr.Example— "< 150 100 50"
"alertExpr": "< 35 25 15" |
triggerSSLStatusAlert | Boolean |
You can enable or disable alerts based on the current status of the SSL certificate.
false.Example— "triggerSSLStatusAlert": false
|
triggerSSLExpirationAlert | Boolean |
You can enable or disable alerts reminding of upcoming SSL certificate expiry.
false.Example— "triggerSSLExpirationAlert": false
|
The following Python script adds Uptime external web device to your LogicMonitor account:
#!/bin/env python
import requests
import json
import hashlib
import base64
import time
import hmac
import getpass
#Account Info: LogicMonitor recommends to NEVER hardcode the credentials. Instead, retrieve the values from a secure storage.
#Note: The below is provided for illustration purposes only.
AccessId = getpass.getpass("Enter your AccessId: ")
AccessKey = getpass.getpass("Enter your AccessKey: ")
Company = 'COMPANY_NAME'
#Request Info
httpVerb ='POST'
resourcePath = '/device/devices'
queryParams = ''
data = '{"type":"uptimewebcheck","deviceType":18,"id":0,"name":"UptimeExternalWebCheck","description":"","groupIds":["1"],"isInternal":false,"individualSmAlertEnable":true,"individualAlertLevel":"error","overallAlertLevel":"warn","pollingInterval":1,"transition":1,"globalSmAlertCond":0,"useDefaultLocationSetting":false,"useDefaultAlertSetting":false,"testLocation":{"collectorIds":[],"collectors":[],"smgIds":["2","4","3"],"all":false},"properties":[],"template":null,"steps":[{"enable":true,"useDefaultRoot":true,"url":"","HTTPVersion":"1.1","HTTPMethod":"GET","name":"__step0","followRedirection":true,"fullpageLoad":false,"requireAuth":false,"auth":{"domain":"","password":"","type":"basic","userName":""},"HTTPHeaders":"","reqType":"config","respType":"config","matchType":"plain","keyword":"","invertMatch":"false","statusCode":"","path":""}],"domain":"google.com","ignoreSSL":true,"pageLoadAlertTimeInMS":30000,"schema":"https","alertExpr":"","triggerSSLStatusAlert":false,"triggerSSLExpirationAlert":false}'
#Construct URL
url = 'https://'+ Company +'.logicmonitor.com/santaba/rest' + resourcePath +queryParams
#Get current time in milliseconds
epoch = str(int(time.time() * 1000))
#Concatenate Request details
requestVars = httpVerb + epoch + data + resourcePath
#Construct signature
digest = hmac.new(
AccessKey.encode('utf-8'),
msg=requestVars.encode('utf-8'),
digestmod=hashlib.sha256).hexdigest()
signature = base64.b64encode(digest.encode('utf-8')).decode('utf-8')
#Construct headers
auth = 'LMv1 ' + AccessId + ':' + str(signature) + ':' + epoch
headers = {'Content-Type':'application/json','Authorization':auth,'X-Version':'3'}
#Make request
response = requests.post(url, data=data, headers=headers)
#Print status and body of response
print('Response Status:',response.status_code)
print('Response Body:',response.content)

