File → Upload
AI-generatedSummary
Upload a file to Google Drive with specified name, content, and optional parent folder and MIME type.
Inputs
- Authentication (required) — Choose between 'Refresh Token (Auto-Refresh)' for automatic token renewal or 'Bearer Token (Manual)' for manual token use.
- File Name (required) — Specify the name of the file to upload.
- File Content (required) — Provide the content of the file as text or base64 encoded string.
- Options — Set optional parameters including 'Parent Folder ID' to upload the file into a specific folder, override 'MIME Type' (default is 'text/plain'), or specify a custom refresh token when using refresh token authentication.
Output shape
a single JSON object representing the uploaded file's metadata as returned by the Google Drive API.
Returns Google Drive API response JSON for the created file including properties like file ID, name, and MIME type.
Examples
Example 1: Upload a plain text file named 'example.txt' with some content to the root folder.
Authentication set to 'Refresh Token (Auto-Refresh)', File Name as 'example.txt', File Content with desired text, MIME Type left to default 'text/plain', no Parent Folder ID specified.