ESC
Type to search...

Files.Read.Selected

Export JSON
Export CSV
Copy URL
Print
Delegated Read User Scope

(Preview) Allows the app to read files that the user selects. The app has access for several hours after the user selects a file.

Permission data: April 6, 2026 at 4:06 AM UTC
Delegated Access App-Only Access

Permission Details

Delegated Permission User consent allowed

Read files that the user selects (preview)

(Preview) Allows the app to read files that the user selects. The app has access for several hours after the user selects a file.

Properties

Microsoft Graph v1.0 mapped-docs

Properties is shown from stable Microsoft Graph v1.0 metadata.

Property Type Description
audio [audio][] Audio metadata, if the item is an audio file. Read-only. Read-only. Only on OneDrive Personal.
bundle [bundle][] Bundle metadata, if the item is a bundle. Read-only.
content StreamNullable The content stream, if the item represents a file.
createdBy [identitySet][] Identity of the user, device, and application that created the item. Read-only.
createdDateTime DateTimeOffset Date and time of item creation. Read-only.
cTag StringNullable An eTag for the content of the item. This eTag isn't changed if only the metadata is changed. Note This property isn't returned if the item is a folder. Read-only.
deleted [deleted][] Information about the deleted state of the item. Read-only.
description StringNullable Provides a user-visible description of the item. Read-write. Only on OneDrive Personal.
eTag StringNullable eTag for the entire item (metadata + content). Read-only.
file [file][] File metadata, if the item is a file. Read-only.
fileSystemInfo [fileSystemInfo][] File system information on client. Read-write.
folder [folder][] Folder metadata, if the item is a folder. Read-only.
id String The unique identifier of the item within the Drive. Read-only.
image [image][] Image metadata, if the item is an image. Read-only.
lastModifiedBy [identitySet][] Identity of the user, device, and application that last modified the item. Read-only.

Showing 15 of 45 properties.

JSON Representation

Microsoft Graph v1.0 mapped-docs

JSON representation is shown from stable Microsoft Graph v1.0 metadata.

JSON representation
{
  "audio": { "@odata.type": "microsoft.graph.audio" },
  "bundle": { "@odata.type": "microsoft.graph.bundle" },
  "content": { "@odata.type": "Edm.Stream" },
  "cTag": "string (etag)",
  "deleted": { "@odata.type": "microsoft.graph.deleted"},
  "description": "string",
  "file": { "@odata.type": "microsoft.graph.file" },
  "fileSystemInfo": { "@odata.type": "microsoft.graph.fileSystemInfo" },
  "folder": { "@odata.type": "microsoft.graph.folder" },
  "image": { "@odata.type": "microsoft.graph.image" },
  "location": { "@odata.type": "microsoft.graph.geoCoordinates" },
  "malware": { "@odata.type": "microsoft.graph.malware" },
  "package": { "@odata.type": "microsoft.graph.package" },
  "pendingOperations": { "@odata.type": "microsoft.graph.pendingOperations" },
  "photo": { "@odata.type": "microsoft.graph.photo" },
  "publication": {"@odata.type": "microsoft.graph.publicationFacet"},
  "remoteItem": { "@odata.type": "microsoft.graph.remoteItem" },
  "root": { "@odata.type": "microsoft.graph.root" },
  "searchResult": { "@odata.type": "microsoft.graph.searchResult" },
  "shared": { "@odata.type": "microsoft.graph.shared" },
  "sharepointIds": { "@odata.type": "microsoft.graph.sharepointIds" },
  "size": 1024,
  "specialFolder": { "@odata.type": "microsoft.graph.specialFolder" },
  "video": { "@odata.type": "microsoft.graph.video" },
  "webDavUrl": "string",

  /* relationships */
  "activities": [{"@odata.type": "microsoft.graph.itemActivity"}],
  "analytics": {"@odata.type": "microsoft.graph.itemAnalytics"},
  "children": [{ "@odata.type": "microsoft.graph.driveItem" }],
  "createdByUser": { "@odata.type": "microsoft.graph.user" },
  "retentionLabel": { "@odata.type": "microsoft.graph.itemRetentionLabel" },
  "lastModifiedByUser": { "@odata.type": "microsoft.graph.user" },
  "permissions": [ {"@odata.type": "microsoft.graph.permission"} ],
  "subscriptions": [ {"@odata.type": "microsoft.graph.subscription"} ],
  "thumbnails": [ {"@odata.type": "microsoft.graph.thumbnailSet"}],
  "versions": [ {"@odata.type": "microsoft.graph.driveItemVersion"}],

  /* inherited from baseItem */
  "createdBy": {"@odata.type": "microsoft.graph.identitySet"},
  "createdDateTime": "String (timestamp)",
  "eTag": "string",
  "id": "string (identifier)",
  "lastModifiedBy": {"@odata.type": "microsoft.graph.identitySet"},
  "lastModifiedDateTime": "String (timestamp)",
  "name": "string",
  "parentReference": {"@odata.type": "microsoft.graph.itemReference"},
  "webUrl": "string",

  /* instance annotations */
  "@microsoft.graph.conflictBehavior": "string",
  "@microsoft.graph.downloadUrl": "url",
  "@microsoft.graph.sourceUrl": "url"
}

Relationships

Microsoft Graph v1.0 mapped-docs

Relationships is shown from stable Microsoft Graph v1.0 metadata.

Relationship Type Description
activities [itemActivity][] collection The list of recent activities that took place on this item.
analytics [itemAnalytics][] resource Analytics about the view activities that took place on this item.
children driveItem collection Collection containing Item objects for the immediate children of Item. Only items representing folders have children. Read-only. Nullable.
createdByUser [user][] Identity of the user who created the item. Read-only.
lastModifiedByUser [user][] Identity of the user who last modified the item. Read-only.
listItem [listItem][] For drives in SharePoint, the associated document library list item. Read-only. Nullable.
permissions [permission][] collection The set of permissions for the item. Read-only. Nullable.
retentionLabel [itemRetentionLabel][] Information about retention label and settings enforced on the driveItem. Read-write.
subscriptions [subscription][] collection The set of subscriptions on the item. Only supported on the root of a drive.
thumbnails [thumbnailSet][] collection Collection of [thumbnailSet][] objects associated with the item. For more information, see [getting thumbnails][]. Read-only. Nullable.
versions [driveItemVersion][] collection The list of previous versions of the item. For more info, see [getting previous versions][]. Read-only. Nullable.
workbook [workbook][] For files that are Excel spreadsheets, access to the workbook API to work with the spreadsheet's contents. Nullable.
photo object Photo metadata, if the item is a photo. Read-only.
extensions extension collection The collection of open extensions defined for this item. Nullable.

Graph Methods

Delegated access App-only access
No Learn or OpenAPI mapping available

Microsoft Graph v1.0 endpoints are not available from refreshed Microsoft Learn or Microsoft Graph OpenAPI metadata for this permission.

No API methods available for this version.

No Learn or OpenAPI mapping available

Microsoft Graph beta endpoints are not available from refreshed Microsoft Learn or Microsoft Graph OpenAPI metadata for this permission.

No API methods available for this version.

No Microsoft Learn PowerShell mapping available

Microsoft Graph PowerShell v1.0 commands are not available from refreshed Microsoft Learn PowerShell snippets for this permission.

No deterministic PowerShell command map is available for this permission.

Browse PowerShell docs
No Microsoft Learn PowerShell mapping available

Microsoft Graph PowerShell beta commands are not available from refreshed Microsoft Learn PowerShell snippets for this permission.

No deterministic PowerShell command map is available for this permission.

Browse PowerShell docs

Code Examples

C# / .NET SDK
using Azure.Identity;
using Microsoft.Graph;

var scopes = new[] { "Files.Read.Selected" };
var credential = new InteractiveBrowserCredential(
    new InteractiveBrowserCredentialOptions
    {
        ClientId = "YOUR_CLIENT_ID",
        TenantId = "YOUR_TENANT_ID",
        RedirectUri = new Uri("http://localhost")
    });

var graphClient = new GraphServiceClient(credential, scopes);
var response = await graphClient
    .WithUrl("https://graph.microsoft.com/v1.0/driveItem")
    .GetAsync();
JavaScript
import { Client } from "@microsoft/microsoft-graph-client";
import { InteractiveBrowserCredential } from "@azure/identity";

const credential = new InteractiveBrowserCredential({
  clientId: "YOUR_CLIENT_ID",
  tenantId: "YOUR_TENANT_ID",
  redirectUri: "http://localhost"
});

const token = await credential.getToken(["Files.Read.Selected"]);
const client = Client.init({
  authProvider: (done) => done(null, token.token)
});

const response = await client.api("/driveItem").get();
PowerShell
Connect-MgGraph -Scopes "Files.Read.Selected"
Invoke-MgGraphRequest -Method GET -Uri "https://graph.microsoft.com/v1.0/driveItem"
Python
from azure.identity import InteractiveBrowserCredential
import requests

credential = InteractiveBrowserCredential(
    client_id="YOUR_CLIENT_ID",
    tenant_id="YOUR_TENANT_ID"
)

token = credential.get_token("Files.Read.Selected")
response = requests.get(
    "https://graph.microsoft.com/v1.0/driveItem",
    headers={"Authorization": f"Bearer {token.token}"}
)

print(response.json())

App Registration

1

Navigate to Azure Portal

Go to App registrations in Microsoft Entra admin center

2

Add API Permission

Select your app → API permissions → Add a permission → Microsoft Graph

3

Select Permission Type

Choose Delegated permissions and search for Files.Read.Selected

4

Grant Admin Consent

Users can consent to this permission during sign-in.