Get Current Drive User
Automatically get Current Drive User on drive.google.com. Report which Google account Google Drive is signed in as in this browser: display name and email, read from Google's account button. Being signed out is reported as a normal answer (loggedIn false), not an error, so it can be used to check a session before running other Drive scripts.
Input
None
Output
loggedIn requiredname optionalemail optionalFAQ
Move a Google Drive file to the Bin
Moves a file to Drive's Bin (never a permanent delete), given just the file's id — its parent folder is resolved automatically.
Upload a file to Google Drive
Upload a file into a Google Drive folder, or into My Drive when no folder is given. Pass the bytes inline as base64 for small files, or point fileUrl at the file served over http://127.0.0.1:<port>/ on the machine running the browser for larger ones. Before reporting success it waits for a row in the destination that was absent beforehand AND carries this call's own filename, so it cannot credit itself with a file another upload created; it returns that file's Drive id. A filename already present in the destination is refused up front, because a dropped file does NOT replace or get declined — Drive happily stores a second, separate file under the same name. For the same reason a lost upload is reported as a failure rather than retried: a re-drop would duplicate an upload that merely landed slowly.
List a Google Drive folder
List the files and sub-folders directly inside a Google Drive folder, without recursing or downloading anything. Returns each item's id, name, type, size, last-modified date, owner and link. Omit folderId to list My Drive's root.
