Stop Device Reachability Monitoring

Stop Device Reachability Monitoring:
DELETE /diagnostics/basic/devicereachability

This API enables an enterprise application to request that device reachability monitoring be stopped.

Contents

Uses and Requirements

Using this API, an enterprise application will be able to request that the reachability monitoring of devices be stopped either by accountName or by monitorID (the parameter that is provided when a monitoring request is first made). At least one monitorID must be specified in the request or all monitoring requests for the specified accountName will be stopped.

Request

HTTP Request

DELETE https://thingspace.verizon.com/api/m2m/v1/diagnostics/basic/devicereachability

Query Parameters

None.

Header Parameters

The request header must contain a current ThingSpace authorization bearer token and a valid VZ-M2M session token, and must set the content-type to JSON.

Parameter Name Data Type Description
Authorization
required
string HTTP Authorization bearer token.
VZ-M2M-Token
required
string A valid session token returned by POST /session/login.
Content-Type
required
string Must be application/json.

Request Body

Parameter Name Data Type Description
accountName
required
string The name of a billing account. An account name is usually numeric, and must include any leading zeros.
monitorIds
optional
array of monitor ID objects The parameter that is provided when a device reachability monitoring request is first made. NOTE: This parameter is optional, however, if left blank, all monitoring requests for the specified accountName will be stopped.

Example Request Body

{
  "accountName": "string",
  "monitorIds": [
    "string"
  ]
}

Success Response

Status 200

Parameter Name Data Type Description
requestId string A unique string that associates the request with the results that are sent via a callback service.
The ThingSpace Platform will send a separate callback message for each device that matched the request criteria, indicating whether the operation succeeded for that device and containing any requested information. All of the callback messages will have the same requestId.

Example Success Response

{
  "requestId": "595f5c44-c31c-4552-8670-020a1545a84d"
}

Stop Monitoring Callback

Stop Monitoring Callback Parameters

Parameter Name Data Type Description
requestID
optional
string TA unique string that associates the delete request for group of devices.
monitorID
optional
string The monitorIDs (UUID) for which the monitor is to be deleted.
status
required
string
  • SUCCESS
  • FAILED
deviceId
required
device identifier object Only one object with {kind, id} where kind shall be same as the one in initial request from customer:
  • kind: the type of the identifier (IMEI, MSISDN, or External-ID)
  • id: a device identifier value
errorCode
optional
string
  • INTERNAL_ERROR
  • DEVICE_NOT_FOUND
  • MONITOR_DOES_NOT_EXIST

Example Stop Monitoring Callback Responses

Scenario - MonitorId is found.

{
   "username":"user",
   "password":"user",
   "requestId":"2c90bd28-ece4-42ef-9f02-7e3bd4fbff33",
   "diagnosticsResponse":{
      "deviceReachabilityResponse":{
         "accountName":"SomeAccountName",
         "reportedTime":"2018-11-11T16:39:58-08:00",
         "monitorId":"12345-ece4-42ef-9f02-4434002"
      }
   },
   "status":"success",
   "callbackCount":1,
   "maxCallbackThreshold":4
}

Scenario - MonitorId is NOT found

{
   "username":"user",
   "password":"user",
   "requestId":"2c90bd28-ece4-42ef-9f02-7e3bd4fbff33",
   "diagnosticsResponse":{
      "deviceReachabilityResponse":{
         "accountName":"SomeAccountName",
         "reportedTime":"2018-11-11T16:39:58-08:00",
         "monitorId":"12345-ece4-42ef-9f02-4434002",
         "reason":"Monitor id not found"
      }
   },
   "status":"failed",
   "callbackCount":1,
   "maxCallbackThreshold":4
}

Scenario- Device associated with MonitorId is not found.

{
   "username":"user",
   "password":"user",
   "requestId":"2c90bd28-ece4-42ef-9f02-7e3bd4fbff33",
   "diagnosticsResponse":{
      "deviceReachabilityResponse":{
         "accountName":"SomeAccountName",
         "reportedTime":"2018-11-11T16:39:58-08:00",
         "monitorId":"12345-ece4-42ef-9f02-4434002",
         "reason":"Device not found associated with a monitorId."
      }
   },
   "status":"failed",
   "callbackCount":1,
   "maxCallbackThreshold":4
}

Failure Response

Status 400

All error messages are returned in this format:

{
  "errorCode": "error code string",
  "errorMessage": "error message string",
  "errorUrl": "error URL string"
}

Error codes and messages are listed on the Error Messages page, along with explanations and suggestions for corrective actions.

Try It Out!