Majid ff
Majid ff

Reputation: 249

How to get folder size in the google drive using Drive API

In Android app, is it possibale to get the folder size in the google drive using the Drive API when I have the folder ID (driveId)? I tried:

driveId.getSize();

It dosn't work? any suggestion please?

Upvotes: 1

Views: 2190

Answers (2)

John Zhang
John Zhang

Reputation: 1142

You can use a simple Google App Script to achieve that. https://github.com/zpf7879/GoogleAppScript/blob/main/README.md

Upvotes: 1

pinoyyid
pinoyyid

Reputation: 22296

you will need to recursively descend into the folder and add up the sizes.

Upvotes: 1

Related Questions