Table of Contents
ONEDRIVE COMMAND
Category: Workflow / App/Cloud
Description
This action performs file operations with OneDrive. A configured OneDrive connector is required.
Action settings
Setting | Description |
---|---|
Connector* | Select the preconfigured OneDrive connector, or, build one by selecting Add connector. See OneDrive connector for details. |
Command | Select the file operation this action will perform. Options: List files, Download file, Download list of files, Upload file, Upload list of files, Delete file, or Delete list of files. See below for details of each command type. |
* Setting can be specified using a parameter.
List files settings
Description: Produce a list of files, with selected details, in a specified folder on OneDrive.
Setting | Description |
---|---|
Folder* | Select a subfolder (under the "My Files" folder) to access. By default, this action will access the "My Files" root folder (no value appears in the Folder field). |
Columns | Select the details of the found files to be included in the dataset. Each detail produces a column. Options: File name with full path, File name only, File extension, Size, Date created, Date modified, MIME type, Created by, and URL. |
* Setting can be specified using a parameter or the first value of a table column.
Download file settings
Description: Downloads the specified file from OneDrive to the local location defined.
Setting | Description |
---|---|
File path* | Enter or browse to the file in OneDrive to be downloaded. |
Local folder* | Enter or browse to the local folder to download the file to. |
If a file with such name already exists | Select how EasyMorph will handle saving the file if a file with the same name exists in the destination folder. Options: Overwrite, Do nothing, or Halt project execution. See the "File already exists" table below. |
* Setting can be specified using a parameter or the first value of a table column.
Download list of files settings
Description: Downloads multiple files specified in a column in the action's input dataset.
Setting | Description |
---|---|
File list | Select the table column containing the list of fully qualified file names to be downloaded. |
Local folder* | Enter or browse to the local folder to download the files to. This action will overwrite files with the same names that already exist in the destination folder. |
* Setting can be specified using a parameter or the first value of a table column.
Download folder settings
Description: Downloads the contents (all files and subfolders, recursively) of the specified OneDrive folder to the defined local folder.
Setting | Description |
---|---|
Folder path* | Select a OneDrive folder to download the contents of. |
Local folder* | Select the local folder to download the contents into. |
If the folder already exists | Select how EasyMorph will handle downloading the folder if a local folder with the same name exists in the selected destination folder. Options: Fail (the workflow stops with a warning), Overwrite (replace existing files and folders in the local directory with the latest versions from the OneDrive folder, and download any new files or folders that don't already exist locally), or Copy missing files (only download files and folders from the OneDrive folder that are not present in the local directory). |
* Setting can be specified using a parameter.
Upload file settings
Description: Uploads the specified local file to the defined OneDrive folder.
Setting | Description |
---|---|
File path* | Enter or browse to the local file to upload. |
Target folder* | Enter or browse to a OneDrive folder to upload the file to. |
If a file with such name already exists | Select how EasyMorph will handle saving the file if a file with the same name exists in the destination folder. Options: Overwrite, Do nothing, or Halt project execution. See the "File already exists" table below. |
* Setting can be specified using a parameter or the first value of a table column.
Upload list of files settings
Description: Uploads multiple files specified in a column in the action's input dataset.
Setting | Description |
---|---|
File list | Select the table column containing the list of fully qualified local file names to be uploaded. |
Target folder* | Enter or browse to a OneDrive folder to upload the files to. This action will overwrite files with the same names that already exist in the destination folder. |
* Setting can be specified using a parameter or the first value of a table column.
Upload folder settings
Description: Uploads the contents (all files and subfolders, recursively) of a chosen local folder to a OneDrive folder.
Setting | Description |
---|---|
Local folder* | Select the local folder to upload the contents of. |
Target folder* | Select a OneDrive folder to upload the contents to. |
If the folder already exists | Select how EasyMorph will handle downloading the folder if a local folder with the same name exists in the selected destination folder. Options: Fail (the workflow stops with a warning), Overwrite (replace existing files and folders in the OneDrive folder with the latest versions from the local folder, and upload any new files or folders that don't already exist in the OneDrive folder), or Copy missing files (only upload files and folders from the local folder that are not present in the OneDrive folder). |
* Setting can be specified using a parameter.
Delete file settings
Description: Deletes the specified file stored on OneDrive.
Setting | Description |
---|---|
File path* | Enter or browse to the remote file to delete. |
If the file doesn't exist | Select how EasyMorph handles situations when the specified file does not exist. Options: Do nothing (nothing happens, the workflow continues, no error is displayed), or Halt project execution (workflow stops, an error is displayed). |
* Setting can be specified using a parameter or the first value of a table column.
Delete list of files settings
Description: Deletes multiple files specified in a column in the action's input dataset.
Setting | Description |
---|---|
File list | Select the table column containing the list of fully qualified OneDrive file names to be deleted. |
If a file from the list doesn't exist | Select how EasyMorph handles situations when a file in the list does not exist. Options: Ignore (nothing happens, the workflow continues, no error is displayed), or Halt project execution (workflow stops, an error is displayed). |
* Setting can be specified using a parameter or the first value of a table column.
List folders settings
Description: Produce a list of subfolders, with selected details, under a specified folder on OneDrive.
Setting | Description |
---|---|
Folder* | Select the parent folder to retrieve a list of subfolders from. |
Columns | Select the details of the subfolders to be included in the dataset. Each detail produces a column. Options: Folder name with full path and Folder name only. |
* Setting can be specified using a parameter or the first value of a table column.
Create folder settings
Description: Create a new OneDrive folder under the selected parent folder.
Setting | Description |
---|---|
Parent folder* | Select a folder on OneDrive to create the new folder under. |
Folder name* | Enter the name of the new folder. |
If a folder with such name already exists | Choose how EasyMorph behaves if a folder with the Folder name already exists. Options: Fail (the workflow stops with a warning) or Do nothing (the workflow continues without creating the new folder). |
* Setting can be specified using a parameter.
Rename folder settings
Description: Rename the selected OneDrive folder.
Setting | Description |
---|---|
Folder* | Select the folder on OneDrive to rename. |
New name* | Enter the new name for the selected folder. |
* Setting can be specified using a parameter.
Delete folder settings
Description: Delete the selected OneDrive folder.
Setting | Description |
---|---|
Folder path* | Select the folder on OneDrive to delete. |
If the folder doesn't exist | Choose how EasyMorph behaves if the selected folder does not exist. Options: Do nothing (the workflow continues without creating the new folder) or Fail (the workflow stops with a warning). |
* Setting can be specified using a parameter.
File already exists options
Option | Description |
---|---|
Overwrite | The new file replaces the original file. |
Do nothing | No file is downloaded/uploaded, the workflow does not halt, and no error is displayed. |
Halt project execution | The project will stop processing and this action will display an error. |
Remarks
The easiest way to build a list of remote files on OneDrive to be downloaded or deleted is to use this action in its File list configuration, including the "File name with full path" option. This list can then be modified to generate the final list of files to be downloaded or deleted.
If building the list manually, the root folder is the "My Files" folder with subfolders falling underneath. To reference a file in the root My Files folder, just list the filename. e.g., "MyTargetFile". When defining subfolders, list the subfolder name followed by a forward-slash ("/") and the filename, or subsequent subfolders. e.g., "MySubFolder / MyTargetFile" or "SubFolder1 / Subfolder2 / MyTargetFile" (extra spaces added for clarity).