How to Restart a Device using API

Modified on Sun, Jun 14 at 2:00 PM

Overview

This API allows users to remotely reboot a device from the TestGrid Device Cloud.


Endpoint

URL : https://{your_base_url}.testgrid.io/devicecloud/api/restartDevice


Method : POST


Request Parameters

Parameter

Type

Required

Description

user_token

String

Yes

User authentication token

device_id

String

Yes

Unique device identifier


Example Request

curl --location 'https://{your_base_url}.testgrid.io/devicecloud/api/restartDevice' \

--form 'user_token="YOUR_USER_TOKEN"' \

--form 'device_id="DEVICE_ID"'


Success Response

{

  "status": 1,

  "msg": "The device reboot request has been sent. Please wait for a while."

}


Failure Response

{

  "status": 0,

  "msg": "Device not found.",

  "statuscode": 403

}


Outcome

The selected device receives a reboot request and restarts automatically.

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article