Use the interface to obtain logs of specified devices.

clear-logs can be used to clear logs.


URL ip[:port]/sc_cloud/scapi/get-dev-logs?sn=xxx
Data Format Response: Content-Type: application/json

Request URL

Parameter Description
sn Device serial number.

Request Cookies

Parameter Description
mwcloud-sid A string value that is used to uniquely identify user logged-in.
mwcloud-uid Current logged-in username.

Request Example

GET /sc_cloud/scapi/get-dev-logs?sn=D301210104248 HTTP/1.1
Accept: application/json, text/plain, */*
Cookie: mwcloud-sid=OCXWUMGEYPGIAWWOETYXPNMVHDZIAZJP; mwcloud-uid=Admin;

Response Parameters

Response Header
Parameter Description
Content-Type Value: 'application/json; charset=UTF-8'
Response Body
Parameter Description
result Result code. The options are as follows:
  • 0: success.
  • Other values. For details about the result codes, please refer to API Status.
logs Device logs displayed on Cloud.
Parameter Description
id Log ID.
date Log generated time.
info Log information.
type Log types. The options are as follows:
1: information. 2: warning. 3: error.
sn Device serial number.

Response Example

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
  "result": 0,
  "logs": [
      "id": 3630,
      "date": 1635217459,
      "info": "The device is offline.",
      "type": 2,
      "sn": "D301210104248"
      "id": 3631,
      "date": 1635218146,
      "info": "The device is online.",
      "type": 1,
      "sn": "D301210104248"

results matching ""

    No results matching ""

    results matching ""

      No results matching ""