Exporting Mailbox Items

In this article

    You can export backed-up items to a PST file.

    Exporting Mailbox Items Important

    To export data to PST (Personal Storage Table) files, you must have a 64-bit version of Microsoft Outlook 2016, Microsoft Outlook 2013 or Microsoft Outlook 2010 installed on a computer running restore sessions.

    Request

    POST https://<hostname>:4443/v6/RestoreSessions/{restoreSessionId}/organization/mailboxes/{mailboxId}/items/exportToPst

    Request Headers

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

    Request Parameters

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

    Parameter

    Type

    Description

    restoreSessionId

    string

    Specifies the identification number of the restore session. For more information on how to get this parameter, see Getting Restore Sessions.

    mailboxId

    string

    Specifies the identification number of the mailbox. For more information on how to get this parameter, see Getting Mailboxes.

    Request Body

    To export the backed-up items from the organization mailbox to a PST file, the request body must contain the following properties:

    Property

    Type

    Description

    items

    item[]

    Specifies the IDs of mailbox items that you want to export to a PST file. For more information on how to get such IDs, see Getting Mailbox Items.

    contentKeyword

    string

    Specifies the keyword to query backed-up mailbox folder data.

    enablePstSizeLimit

    boolean

    Defines whether to set the size limit for the exported PST file.

    If set to true, indicates that you must specify the pstSizeLimitBytes parameter.

    pstSizeLimitBytes

    integer

    Specifies the limit of the exported PST file in Bytes.

    You can choose the limit range from 1 GB to 49 GB.

    For example:

    Request Body:

    {

       "contentKeyword": "support",

       "enablePstSizeLimit": true,

       "pstSizeLimitBytes": 1073741824,

       "items":  [

       {"Id": "74685f6b-16aa-4a78-a44f-05526ce0ae30"},

       {"Id": "70013a9e-c446-429d-aa78-9c8c20d9b814"}

       ]

    }

    The request command will look for a specified keyword in item names and fields inside the organization mailbox. The backed-up data with a specified keyword then will be exported to a PST file and placed to a temporary folder on the Veeam Backup for Microsoft 365 server. After that, the PST file will be transferred as application/octet-stream media to the client. To download, read, convert to PST or perform other actions with the octet-stream, use features of programming languages.

    If the size of the exported data exceeds the limit specified for the PST file, Veeam Backup for Microsoft 365 splits the PST file into separate files and exports these files to an archive file of the ZIP format. For example, you specified 1 GB as the PST file size limit. The size of the exported data is 1.5 GB. In this case, Veeam Backup for Microsoft 365 will export data to a ZIP archive. The archive will contain two PST files: one PST file of the 1 GB size and another PST file of the 0.5 GB size.

    Exporting Mailbox Items Tip

    You can use Swagger UI to download the octet-stream file by clicking the Download action link, which server returns in the response body after a successfully completed export operation. For more information, see Evaluation in Swagger UI.

    Response

    The server returns the following response to the client.

    Response Codes

    A successfully completed operation returns 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 for the requests with the export and save actions: application/octet-stream.

    The media type and syntax of the response body message for the requests with the restore and send actions: null.

    Response Body

    In the response body, the server returns binary data stream.

    Example

    The following request exports backed-up mailbox items with the specified IDs that contain the "support" keyword to a PST file.

    Request:

    POST https://abc.tech.local:4443/v6/RestoreSessions/380d7caf-6294-4a33-b50a-b8aeb13af58c/organization/mailboxes/9e9b7199-f547-467a-b580-9d283a75eaad/Items/exportToPst

     

    Request Header:

    Authorization: Bearer <Access-Token>

     

    Request Body:

    {

       "contentKeyword": "support",

       "enablePstSizeLimit": false,

       "items":  [

         {"Id": "74685f6b-16aa-4a78-a44f-05526ce0ae30"},

         {"Id": "70013a9e-c446-429d-aa78-9c8c20d9b814"}

       ]

    }

     

    Response:

    200 OK