0

I have an ID of an OneDrive drive. Is there any way I can figure out the user ID to whom the OneDrive drive belongs to?

user13260866
  • 131
  • 1
  • 2
  • 9

1 Answers1

1

When you call

GET /drives/{drive-id}

it returns Drive resource type with Owner property. It's the user account that owns the drive and it includes user id.

{
    "id": "b!t18F8ybsHUq1z3LTz8xvZqP8zaSWjkFNhsME-Fepo75dTf9vQKfeRblBZjoSQrd7",
    "driveType": "business",
    "owner": {
        "user": {
            "id": "efee1b77-fb3b-4f65-99d6-274c11914d12",
            "displayName": "John Doe"
        }
    },
    ...
}
user2250152
  • 14,658
  • 4
  • 33
  • 57