Frends.GoogleDrive.Upload / 1.1.0
Summary
Copies local files matching a pattern into a Drive folder, using a service account rather than a signed-in person's credentials.
Typical use — publishing reports where people, not systems, are the consumers
Input parameters.
| Name | Type | Default | Example | Description |
|---|---|---|---|---|
| SourceDirectory | String |
– | c:\temp, \\network\folder |
Source directory. |
| FileMask | String |
* |
*.* , ?_file.*, foo_*.txt, singlefile.txt |
Windows-style filemask. Empty field = all objects (*). If you want to upload only one file, define exact filename as filemask. Consider using .zip (for example) when uploading multiple objects at the same time. |
| TargetFolderId | String |
– | 42o3j8D7cmhMJFAAlbZb5B_8u9OqnAIkn |
Id of the target Google Drive folder. |
| ServiceAccountKeyJSONSecret | String |
– |
{
"type": "service_account",
"project_id": "something",
"private_key_id": "fdsafdsafdsalmnop12345678909876543212344",
"private_key": "-----BEGIN PRIVATE KEY-----\nMIIE.......Hw==\n-----END PRIVATE KEY-----\n",
"client_email": "someone@something.iam.gserviceaccount.com",
"client_id": "123456789012345678900",
"auth_uri": "https://accounts.google.com/o/oauth2/auth",
"token_uri": "https://oauth2.googleapis.com/token",
"auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs",
"client_x509_cert_url": "https://www....nt.com"
}
,
C:\temp\ServiceAccountKeyJSON.json
|
The JSON service account key generated in the Google Cloud portal. Value can be either JSON string or full filepath to JSON file. |
| IncludeSharedDrives | Boolean |
False |
false |
Whether to enable support for shared drives. |