Adding Items to Backup Job

In this article

    You can add a new item to the backup job processing list.

    Request

    POST https://<hostname>:4443/v5/Jobs/{jobId}/SelectedItems

    Request Headers

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

    Request Parameters

    The following parameter must be specified in the URL of the request:

    Parameter

    Type

    Description

    jobId

    string

    Specifies the identification number of the backup job. For more information on how to get this parameter, see Getting Backup Jobs.

    Request Body

    The following table lists available request properties:

    Property

    Type

    Description

    itemToSelect

    backupItem[]

    Specifies one or more items to be added to the backup job processing list.

    For more information about properties that you must specify for different types of backup items, see backupitemType.

    Request Example

    Request:

    POST https://abc.tech.local:4443/v5/Jobs/31a66931-b5d3-49f7-bba1-c46db49d3d14/SelectedItems

     

    Request Header:

    Authorization: Bearer <Access-Token>

     

    Request Body:

    [

      {

         "type":"User",

         "user":{

            "id":"aa7dd142-bad0-41ff-8d4a-bae7ba57b50c00000000-0000-0000-0000-000000000000",

            "displayName":"Administrator",

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

            "type":"User"

         },

         "mailbox":true,

         "oneDrive":false,

         "archiveMailbox":false,

         "site":false

      },

      {

         "type":"User",

         "user":{

            "id":"defe15d6-5df0-4fa0-aeb1-9be225d7c82b00000000-0000-0000-0000-000000000000",

            "displayName":"Administrator 2",

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

            "type":"User"

         },

         "mailbox":true,

         "oneDrive":true,

         "archiveMailbox":true,

         "site":true

      }

    ]

    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

    None.

    Response Example

    Response:

    200 OK

     

    Response Body:

    [

     {

       "type": "User",

       "user": {

         "id": "2b788f9a-0c3e-4087-be1b-226a8b9f02cb9878f4b0-ec8d-4c58-bc91-277ef992c4cc",

         "displayName": "Admin",

         "name": "admin@company.onmicrosoft.com",

         "type": "User",

         "_links": {

           "self": {

             "href": "https://localhost:4443/v5/organizations/1ef78585-956d-485a-b70b-7a549f319111/users/2b788f9a-0c3e-4087-be1b-226a8b9f02cb9878f4b0-ec8d-4c58-bc91-277ef992c4cc"

           },

           "organization": {

             "href": "https://localhost:4443/v5/organizations/1ef78585-956d-485a-b70b-7a549f319111"

           },

           "onedrives": {

             "href": "https://localhost:4443/v5/organizations/1ef78585-956d-485a-b70b-7a549f319111/users/2b788f9a-0c3e-4087-be1b-226a8b9f02cb9878f4b0-ec8d-4c58-bc91-277ef992c4cc/onedrives"

           }

         }

       },

       "mailbox": false,

       "oneDrive": true,

       "archiveMailbox": false,

       "site": true,

       "id": "2b788f9a-0c3e-4087-be1b-226a8b9f02cb9878f4b0-ec8d-4c58-bc91-277ef992c4cc82aceabf-9192-4049-a6df-1d35c1318714",

       "_links": {

         "job": {

           "href": "https://localhost:4443/v5/jobs/e04edb61-cb76-4b1f-a484-62aceb067a6c"

         },

         "self": {

           "href": "https://localhost:4443/v5/jobs/e04edb61-cb76-4b1f-a484-62aceb067a6c/selectedItems/2b788f9a-0c3e-4087-be1b-226a8b9f02cb9878f4b0-ec8d-4c58-bc91-277ef992c4cc82aceabf-9192-4049-a6df-1d35c1318714"

         }

       }

     }

    ]