---
title: "Initiate a restore activity"
method: POST
path: "/endpoints/v1/restores"
tags: ["Endpoints"]
---

# Initiate a restore activity

`POST /endpoints/v1/restores`

Creates a restore request. You can either restore data of users on the same device from which it was backed up or to their other devices registered with inSync. 
You can restore the data ONLY from the most recent snapshot to the target device. 
You can initiate multiple restore activities. Multiple restore activities may be consolidated into a single activity based on inSync Client version and appropriate status is displayed for each activity.

## Request body

- object
  - `deviceID` integer, required — Specify the unique ID of the device in inSync from which you want to initiate the restore activity. Get the ID of the device using the ‘List all devices’ API.
  - `targetDeviceID` integer, required — Specify the target device ID to which you intend to restore the data. The target device must belong to the same user. Get the target device ID by using the ‘List all devices’ API. Target device ID can be same in case you are restoring the data on the same device.
  - `restoreLocation` string, required — Specify the location to which you intend to restore the data on the selected device. Specify one of the following - 1) Desktop - If you want to restore the data to the desktop on the target device. 2) Original - If you want to restore data to the same location from which it was backed up. 3) If you want to restore the data at a custom location, specify absolute path of the location. Example - /home/jeremy/statusReport

## Response `200`

OK

- CreateRestores
  - `restores` RestoreDefault[]
    - `deviceID` integer — The unique ID of the device in inSync from which the restore activity was triggered. Example: 12345
    - `targetDeviceID` integer — The unique ID of the device in inSync to which the data was restored. It can be similar to 'deviceID' if the data was restored on the same device. Example: 12345.
    - `restoreLocation` string — Displays the location at which the data was restored. Example - Original. Possible values are - 1) Desktop - If the data was restored on the user desktop. 2) Original - If the data was restored to the original location from where it was backed up. 3) Absolute path of the location on the device if the data was restored at a custom location.
    - `userID` integer — The unique ID of the user in inSync for whom the restore activity was triggered. Example: 12345
    - `restoreID` integer — The unique ID of the restore activity. Example: 12345. This value is 'null' in case the restore was initiated from a mobile device.
    - `startTime` string, date-time — The start time of the restore activity. Example - 2013-04-17T09:12:36Z
    - `endTime` string, date-time — The end time of the restore activity. No value is displayed for this field as it is an ongoing restore activity.
    - `status` string — The status of the restore activity. Always displays 'Ongoing' as the restore activity is in progress
    - `restoreSize` string — The size of data restored. No value is displayed for this field as it is an ongoing restore activity.
    - `numberOfFilesRestored` integer — The number of files restored in the restore activity. 'Null' is displayed for this field as it is an ongoing restore activity..
    - `numberOfFilesMissed` integer — The number of files missed during the restore activity. 'Null' is displayed for this field as it is an ongoing restore activity.
    - `restoreMode` string — Information of the restore initiator. Always displays 'Admin' as the initiator of the restore activity.
    - `systemSettingsRestore` boolean — Displays whether system settings are restored as part of restore. 'Null' is displayed for this field as it is an ongoing restore activity.
    - `failureReason` string — Displays the reason for failure if the restore activity has failed, else the value is empty.
  - `totalSize` integer — The total number of restore activities created.

## Other responses

- `400` — Bad Request
- `401` — The request did not include an authentication token or an expired authentication token was supplied.
- `404` — The requested resource was not found.
- `422` — Unprocessable entity. Example - It is the latest un-quarantined snapshot and can't be deleted.

---

[API](https://skmtc.net/druva/apis/authentication.md) · [All operations](https://skmtc.net/druva/apis/authentication/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/druva/authentication/versions/2af2bf148b25/schema)
