I ran into a similar problem, and although there is currently no way to do this with Drive (as far as I know), this is the solution I am facing.
I serve hundreds of thousands of files for clients using the Drive folder as a repository with a built-in user interface created using the Drive API. With this large number of files, it is ridiculously tiring for users to upload files one at a time. Therefore, the idea was to allow users to select the files that they would like to download, and then present them with a zip file containing the files.
To do this, first you need to get an array of Drive files that you want to download, regardless of which one you create programmatically or using the flags on the interface. Then you will go through this array and get the "downloadURL" value for each file and do cURL for the provided url. Depending on how many files you plan to process on demand, you can store them all in memory or temporarily store them on disk or in a database. No matter once you have all the files, you can zip them using any number of zip libraries that are there. Then just send the resulting zip file to the user.
In our case, we ended up loading individual files because of the potentially huge amount of resources and bandwidth that this can eat, but this is a potential solution if you do not serve a large number of files.
source share