BackupRestore-Restore.ReadWrite.All
Allows the app to search all backup snapshots for Microsoft 365 resources, and restore Microsoft 365 resources from a backed-up snapshot, without a signed-in user.
In short
BackupRestore-Restore.ReadWrite.All is available as both an application permission and a delegated permission in the Microsoft Graph API, grouped under the BackupRestore-Restore category. Allows the app to search all backup snapshots for Microsoft 365 resources, and restore Microsoft 365 resources from a backed-up snapshot, without a signed-in user. It grants read and write access to resources. Application permissions always require admin consent.
Permission Details
Read restore all sessions and start restore sessions from backups
Allows the app to search all backup snapshots for Microsoft 365 resources, and restore Microsoft 365 resources from a backed-up snapshot, without a signed-in user.
bebd0841-a3d8-4313-a51d-731112c8ee41
Read restore sessions and start restore sessions from backups
Allows the app to search the backup snapshots for Microsoft 365 resources, and restore Microsoft 365 resources from a backed-up snapshot, on behalf of the signed in user.
9f89e109-94b9-4c9b-b4fc-98cdaa54f574
Properties
Properties is shown from stable Microsoft Graph v1.0 metadata.
| Property | Type | Description |
|---|---|---|
backupSizeInBytes |
StringNullable |
The size of the backup in bytes. |
createdDateTime |
DateTimeOffsetNullable |
The time of the creation of the browse session. |
directoryObjectId |
StringNullable |
Id of the backed-up OneDrive. |
error |
publicError |
Contains the error details if the browse session creation fails. |
expirationDateTime |
DateTimeOffsetNullable |
The time after which the browse session is deleted automatically. |
id |
String |
The unique identifier of the browse session. Inherits from entity. |
restorePointDateTime |
DateTimeOffsetNullable |
The date time of the restore point on which browse session is created. |
status |
browseSessionStatus |
The status of the browse session. The possible values are: creating, created, failed, unknownFutureValue. |
restorePointId |
stringNullable |
JSON Representation
JSON representation is shown from stable Microsoft Graph v1.0 metadata.
{
"@odata.type": "#microsoft.graph.oneDriveForBusinessBrowseSession",
"id": "String (identifier)",
"status": "String",
"createdDateTime": "String (timestamp)",
"expirationDateTime": "String (timestamp)",
"restorePointDateTime": "String (timestamp)",
"backupSizeInBytes": "String",
"error": {
"@odata.type": "microsoft.graph.publicError"
},
"directoryObjectId": "String"
}
Relationships
Relationships is shown from stable Microsoft Graph v1.0 metadata.
| Relationship | Type | Description |
|---|---|---|
status |
browseSessionStatus |
Related status data exposed by this resource. |
Graph Methods
Microsoft Graph v1.0 endpoints are mapped directly from refreshed Microsoft Learn permissions tables.
Microsoft Graph beta endpoints are mapped directly from refreshed Microsoft Learn permissions tables.
Microsoft Graph PowerShell v1.0 commands are mapped directly from refreshed Microsoft Learn PowerShell snippets.
Microsoft Graph PowerShell beta commands are mapped directly from refreshed Microsoft Learn PowerShell snippets.
Code Examples
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Models;
var requestBody = new DriveRestoreArtifactsBulkAdditionRequest
{
DisplayName = "ODB-BulkRestoreArtifacts",
Drives = new List<string>
{
"[email protected]",
"[email protected]",
"[email protected]",
},
DirectoryObjectIds = new List<string>
{
},
ProtectionUnitIds = new List<string>
{
},
ProtectionTimePeriod = new TimePeriod
{
StartDateTime = DateTimeOffset.Parse("2021-01-01T00:00:00Z"),
EndDateTime = DateTimeOffset.Parse("2021-01-08T00:00:00Z"),
},
DestinationType = DestinationType.New,
Tags = RestorePointTags.FastRestore,
RestorePointPreference = RestorePointPreference.Latest,
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.Solutions.BackupRestore.OneDriveForBusinessRestoreSessions["{oneDriveForBusinessRestoreSession-id}"].DriveRestoreArtifactsBulkAdditionRequests.PostAsync(requestBody);
const options = {
authProvider,
};
const client = Client.init(options);
const driveRestoreArtifactsBulkAdditionRequest = {
displayName: 'ODB-BulkRestoreArtifacts',
drives: [
'[email protected]',
'[email protected]',
'[email protected]'
],
directoryObjectIds: [],
protectionUnitIds: [],
protectionTimePeriod: {
startDateTime: '2021-01-01T00:00:00Z',
endDateTime: '2021-01-08T00:00:00Z'
},
destinationType: 'new',
tags: 'fastRestore',
restorePointPreference: 'latest'
};
await client.api('/solutions/backupRestore/oneDriveForBusinessRestoreSessions/493635f0-b8c0-4c7f-bcb7-b20c85d97efe/driveRestoreArtifactsBulkAdditionRequests')
.post(driveRestoreArtifactsBulkAdditionRequest);
Import-Module Microsoft.Graph.BackupRestore
$params = @{
displayName = "ODB-BulkRestoreArtifacts"
drives = @(
"[email protected]"
"[email protected]"
"[email protected]"
)
directoryObjectIds = @(
)
protectionUnitIds = @(
)
protectionTimePeriod = @{
startDateTime = [System.DateTime]::Parse("2021-01-01T00:00:00Z")
endDateTime = [System.DateTime]::Parse("2021-01-08T00:00:00Z")
}
destinationType = "new"
tags = "fastRestore"
restorePointPreference = "latest"
}
New-MgSolutionBackupRestoreOneDriveForBusinessRestoreSessionDriveRestoreArtifactBulkAdditionRequest -OneDriveForBusinessRestoreSessionId $oneDriveForBusinessRestoreSessionId -BodyParameter $params
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph import GraphServiceClient
from msgraph.generated.models.drive_restore_artifacts_bulk_addition_request import DriveRestoreArtifactsBulkAdditionRequest
from msgraph.generated.models.time_period import TimePeriod
from msgraph.generated.models.destination_type import DestinationType
from msgraph.generated.models.restore_point_tags import RestorePointTags
from msgraph.generated.models.restore_point_preference import RestorePointPreference
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = DriveRestoreArtifactsBulkAdditionRequest(
display_name = "ODB-BulkRestoreArtifacts",
drives = [
"[email protected]",
"[email protected]",
"[email protected]",
],
directory_object_ids = [
],
protection_unit_ids = [
],
protection_time_period = TimePeriod(
start_date_time = "2021-01-01T00:00:00Z",
end_date_time = "2021-01-08T00:00:00Z",
),
destination_type = DestinationType.New,
tags = RestorePointTags.FastRestore,
restore_point_preference = RestorePointPreference.Latest,
)
result = await graph_client.solutions.backup_restore.one_drive_for_business_restore_sessions.by_one_drive_for_business_restore_session_id('oneDriveForBusinessRestoreSession-id').drive_restore_artifacts_bulk_addition_requests.post(request_body)
App Registration
Navigate to Azure Portal
Go to App registrations in Microsoft Entra admin center
Add API Permission
Select your app → API permissions → Add a permission → Microsoft Graph
Select Permission Type
Choose Application permissions or delegated permissions and search for BackupRestore-Restore.ReadWrite.All
Grant Admin Consent
Application permissions always require admin consent.
Frequently asked questions
What is the BackupRestore-Restore.ReadWrite.All Microsoft Graph permission?
BackupRestore-Restore.ReadWrite.All is available as both an application permission and a delegated permission in the Microsoft Graph API, grouped under the BackupRestore-Restore category. Allows the app to search all backup snapshots for Microsoft 365 resources, and restore Microsoft 365 resources from a backed-up snapshot, without a signed-in user. It grants read and write access to resources. Application permissions always require admin consent. It is mapped to the Microsoft Graph onedriveforbusinessbrowsesession resource type. 53 documented Microsoft Graph REST methods require it. 47 Microsoft Graph PowerShell commands are documented for it.
Is BackupRestore-Restore.ReadWrite.All an application or a delegated permission?
BackupRestore-Restore.ReadWrite.All is available as both an application permission (app-only access, no signed-in user) and a delegated permission (access on behalf of a signed-in user).
Does BackupRestore-Restore.ReadWrite.All require admin consent?
Application permissions always require admin consent.
What is the permission ID (GUID) for BackupRestore-Restore.ReadWrite.All?
For BackupRestore-Restore.ReadWrite.All, the application (app role) ID is bebd0841-a3d8-4313-a51d-731112c8ee41, and the delegated (OAuth2 scope) ID is 9f89e109-94b9-4c9b-b4fc-98cdaa54f574. These are the real Microsoft Graph identifiers and can be used directly in an app registration manifest.