Copy File
google_drive.copy_file
ActionFiles & storageconnection required
Calls Drive files.copy. Needs a read/write Drive scope (drive or drive.file) on the connection.
Copy a Drive file, optionally renaming it or placing it in another folder.
Connection
- Required
- Yes — the node will not save without one
- Auth type
- OAuth 2.0
- Providers
- Google Drive
- Secret shape
- {"client_id", "client_secret", "refresh_token"}
- Config it needs
- token_uri
- Resolved by
- config.connection_id, else node.connection_id
Configuration
3 fields, 1 required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.
| Field | Type | Required | Default | Constraints | Example |
|---|---|---|---|---|---|
file_id The Drive file id. | string | Yes | — | — | — |
name Name for the copy; defaults to Drive's. | string | No | — | — | — |
folder_id Destination folder id. | string | No | — | — | — |
Output
One shape.
file
| Field | Type | Example |
|---|---|---|
id The Drive file id. | string | — |
name File name as shown in Drive. | string | — |
mime_type Drive mime type; folders are application/vnd.google-apps.folder. | string | — |
size Bytes, when known (Google-native docs report none). | number | — |
modified_time RFC 3339 timestamp of the last content change. | string | — |
web_view_link Open-in-Drive URL. | string | — |
created_time RFC 3339 timestamp of creation. | string | — |
trashed True when the file is in the bin — files.get returns it either way. | boolean | — |
parents Ids of the folders holding this file. | array | — |
icon_link Small icon URL for the file type. | string | — |
web_content_link Direct download URL (binary files only). | string | — |
description The file's description, when it has one. | string | — |
shared True when the file is shared beyond its owner. | boolean | — |
starred True when the user starred the file. | boolean | — |
drive_id Shared Drive id, present only for shared-drive items. | string | — |
md5_checksum MD5 of the content; use it to tell a changed file from a touched one. | string | — |
file_extension Extension of the uploaded content, when any. | string | — |
owners Owners as {display_name, email_address}. | array | — |
last_modifying_user Who last changed it, as {display_name, email_address}. | object | — |
shortcut_details For a shortcut: {target_id, target_mime_type}. | object | — |
source_file_id The file that was copied. | string | — |
{
"created_time": "",
"description": "",
"drive_id": "",
"file_extension": "",
"icon_link": "",
"id": "",
"last_modifying_user": {},
"md5_checksum": "",
"mime_type": "",
"modified_time": "",
"name": "",
"owners": [],
"parents": [],
"shared": false,
"shortcut_details": {},
"size": 0,
"source_file_id": "",
"starred": false,
"trashed": false,
"web_content_link": "",
"web_view_link": ""
}Related Google Drive nodes
See Copy File run in a workflow.
In a technical demo we add the Google Drive connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.