I use the Ruby and Google Drive APIs.How to create a folder in the root directory?
A folder in Google Drive is essentially a file with the type MIME application/vnd.google-apps.folder , so you can use the Ruby code in the reference guide and set the mimeType field for it.
application/vnd.google-apps.folder
mimeType
Check the docs for the full snippet:
https://developers.google.com/drive/v2/reference/files/insert