Creating Restore Session for Restore Operator

You can start a restore session to explore and restore data using Restore Portal.

To use this resource, make sure to obtain a token using an assertion obtained from Microsoft Azure and log in to Veeam Backup for Microsoft 365 REST API as a restore operator. For more information, see Authorization for Restore Operators.

Request

POST https://<hostname>:4443/v6/Organization/OperatorExplore

Request Headers

The request header must contain an authorization token of the current session.

Request Body

To start a restore session, the request body must contain the following properties:

Property

Type

Description

datetime

UTC

Specifies the date and time. You can specify the date and the time in one of the following formats:

  • <yyyy-MM-dd HH:mm:ss.SSS>
  • <yyyy.MM.dd hh:mm:ss>

type

string

Specifies the type of the restore session to start. The following types are available:

  • Vex
  • Vesp
  • Veod

showDeleted

boolean

Defines whether the restore session will show items that have been removed by the user before the specified date.

showAllVersions

boolean

Defines whether the restore session will show all versions of items that have been modified by the user before the specified date.

scope

objectToManage[]

Specifies the restore scope — a list of objects managed by the restore operator for which the restore session is created. To get this information, use the Getting Objects to Manage operation.

If you do not specify this property in the request, the restore scope will include objects backed up for the user currently logged in to Veeam Backup for Microsoft 365 REST API.

reason

string

Specifies a reason for the restore operation.

The request command will start a restore session for backups that were created at the time you have specified.

Consider the following:

  • If you specify a point in time which precedes the first time the organization was backed up, the restore session will be created with no backup data for explore or restore.
  • If you specify a point in time which exceeds the last time the organization was backed up, the restore session will be created with the backup data as of the latest restore point.

Response

The server returns the following response to the client.

Response Codes

A successfully completed operation returns a response code 200 OK.

Response Headers

The response to this request contains the following headers. The response may also include additional standard HTTPS headers.

Header

Description

Content-length

The length of the response body.

Content-type

The media type and syntax of the response body message: application/json; charset=utf-8

Response Body

In the response body, the server returns a resource representation of the restore session. The response body contains the following properties:

Property

Type

Description

id

string

Specifies the restore session ID.

name

string

Specifies a name of the restore session.

organization

string

Specifies the name of the Microsoft 365 organization.

type

string

Specifies the type of the restore session. The following types are available:

  • Vex (for Veeam Explorer for Microsoft Exchange)
  • Veod (for Veeam Explorer for Microsoft OneDrive for Business)
  • Vesp (for Veeam Explorer for Microsoft SharePoint)

creationTime

UTC

Specifies date and time when the restore session was started.

endTime

UTC

Specifies date and time when the restore session ended.

state

string

Specifies the state of the restore session. The following values are available:

  • Working
  • Stopped

result

string

Specifies the restore session result. The following values are available:

  • Success
  • Warning
  • Failed

initiatedBy

string

Specifies the name of the who initiated the restore session.

details

string

Specifies the restore session details.

scopeName

string

Specifies a scope of the restore session created using Restore Portal.

clientHost

string

Specifies a DNS name or an IP address of the Veeam Backup for Microsoft 365 server.

reason

string

Specifies a reason to perform restore operation.

_links

Dictionary of string [key] and Object [value]

Links to related resources (navigation property).

Example

The example returns a resource representation of the restore session created for the restore operator operator@abc.onmicrosoft.com.

Request:

POST https://abc.tech.local:4443/v6/Organization/OperatorExplore

 

Request Header:

Authorization: Bearer <Access-Token>

 

Request Body:

{

 "dateTime": "2022-03-25T01:58:48.209Z",

 "type": "Vex",

 "showDeleted": true,

 "showAllVersions": true,

 "scope": {

    {

     "type": "User",

     "user": {

       "id": "c0564313-6070-4ebe-8af5-2d409b04698400000000-0000-0000-0000-000000000000",

       "displayName": "User1",

       "name": "user1@abc.onmicrosoft.com",

       "type": "User"

     },

     "id": "a4e58481-9bd5-4d41-9f46-01c14862f6f4c0564313-6070-4ebe-8af5-2d409b04698400000000-0000-0000-0000-000000000000",

     "_links": {}

   },

   {

     "type": "User",

     "user": {

       "id": "52a9e4ac-2378-4238-aba3-1ef840c9476300000000-0000-0000-0000-000000000000",

       "displayName": "User2",

       "name": "user2@abc.onmicrosoft.com",

       "type": "User"

     },

     "id": "a4e58481-9bd5-4d41-9f46-01c14862f6f452a9e4ac-2378-4238-aba3-1ef840c9476300000000-0000-0000-0000-000000000000",

     "_links": {}

   },

   {

     "type": "User",

     "user": {

       "id": "7ae2c943-57c6-4cf9-82df-5ac84c10b31000000000-0000-0000-0000-000000000000",

       "displayName": "User3",

       "name": "user3@abc.onmicrosoft.com",

       "type": "User"

     },

     "id": "a4e58481-9bd5-4d41-9f46-01c14862f6f47ae2c943-57c6-4cf9-82df-5ac84c10b31000000000-0000-0000-0000-000000000000",

     "_links": {}

   }    

},

 "reason": "Restore of deleted items"

}

 

Response:

200 OK

 

Response Body:

{

 "id": "72e92978-7ec5-47e3-a31f-506a5618db22",

 "name": ""Exchange restore (Restore operator: operator@abc.onmicrosoft.com - 3/25/2022 1:58:48 AM)",

 "organization": "abc.onmicrosoft.com",

 "type": "Vex",

 "creationTime": "2022-03-25T02:01:22.7433412Z",

 "endTime": "9999-12-31T23:59:59.9999999Z",

 "state": "Working",

 "result": "Success",

 "initiatedBy": "operator@abc.onmicrosoft.com",

 "details": "",

 "scopeName": "operator@abc.onmicrosoft.com",

 "clientHost": "EPSILON (via: 127.0.0.1",

 "reason": "Restore of deleted items",

 "_links": {

   "self": {

     "href": "/v6/restoresessions/72e92978-7ec5-47e3-a31f-506a5618db22"

   },

   "organization": {

     "href": "/v6/restoresessions/72e92978-7ec5-47e3-a31f-506a5618db22/organization"

   },

   "restoreSessionEvents": {

     "href": "/v6/restoresessions/72e92978-7ec5-47e3-a31f-506a5618db22/events"

   }

 }

}