UiPath Documentation
activities
latest
false
Workflow activities

Upload Storage File

Upload Storage File activity that uploads a file to a specified Storage Bucket in Orchestrator.

UiPath.Core.Activities.Storage.UploadStorageFile

Description​

Uploads a file to a specified Storage Bucket in Orchestrator.

Note:

Orchestrator permissions

This activity runs under the Orchestrator account of the robot that executes it. It must hold the following Orchestrator role permissions on the target folder:

  • Storage Buckets.View: used to resolve the storage bucket
  • Storage Files.Create: used to upload or write files to the bucket
  • Folders.View: used to browse and select the Orchestrator folder

In Windows and cross-platform projects with System 26.10.0 or later, the activity stores the uploaded file with its content type (MIME type). The content type is taken from the extension of the uploaded file name, then from the type that the file resource reports, then from the extension of the local file.

The following buckets do not keep the content type, because Orchestrator discards it:

  • On-premises file-system buckets
  • On-premises encrypted buckets
  • MinIO buckets

Project compatibility​

Windows - Legacy | Windows | Cross-platform

Cross-platform configuration​

  • Orchestrator folder path—The path to the Orchestrator Folder you want to use with this activity. If left empty, the current Orchestrator folder is used. This field supports only strings and String variables. Use / as a subfolder separator to specify the desired folder.
  • Storage Bucket Name—The name of the Storage Bucket where you want to upload the file. This field is mandatory. This field supports only strings and String variables.
  • File—The full path of the file you want to upload to the mentioned Storage Bucket. You can use toggle between using a local path or a variable of IResource type. If you are using a local path, relative folder paths are recommended to account for the different file structure between Windows and Linux machines when executing a project. Example: newFolder/newFileName.txt.
  • Destination path—The path in the storage bucket where the file is uploaded, including the file name. A value that ends with / is used as a folder, as is any value when Uploaded file name is set, and the file name then comes from Uploaded file name or from the source file. An empty value uploads the file to the root of the bucket.
  • Uploaded file name—The name of the file in the storage bucket. When set, it is appended to Destination path, which is then used as a folder. If left empty, the name comes from Destination path or, when that is a folder or empty, from the source file.
Note:

In the designer, Destination path offers a searchable list of the bucket folders, with entries ending in /, such as archive/, and refreshes it when the Orchestrator folder or the bucket changes. You can still type a value or an expression. In Studio Web solutions, the field is plain text with no list.

1For cross-platform projects created in Studio Web as part of a solution, the Orchestrator folder path field is unavailable. If the activity had a folder path before it became part of the solution, the field is displayed as read-only, and that folder overrides the solution resource. Selecting the resource again removes the folder.

2For cross-platform projects created in Studio Web as part of a solution, the name field provides options to Define new Orchestrator resources, such as queues, assets, or storage buckets, during design time, or Open Orchestrator for resource management.

Advanced options​

Others​
  • Timeout (milliseconds)—Specifies the amount of time (in milliseconds) to wait for Orchestrator to respond, or for the file transfer to make progress, before an error is thrown. It does not limit total transfer time, so large files over slow connections still complete. The default value is 300000 milliseconds (5 minutes). Opening a connection is always limited to 30 seconds.

    Note:

    On a timeout the activity fails with a TimeoutException carrying the error code Orchestrator_Sys_Timeout, so Continue On Error and Retry Scope apply as they do to any other error. A value of 0 or a negative number is replaced with 30 seconds, and cancelling the job is reported as a cancellation rather than a timeout.

    When Orchestrator serves the file content itself instead of handing out a provider URL, which is the case on Orchestrator-managed storage with the Features.Buckets.StorageOffloadRequiresAuth feature enabled, the upload must also finish in total within this value.

  • Continue On Error—Specifies if the automation should continue even when the activity throws an error. This field only supports Boolean values (True, False). The default value is False. As a result, if the field is blank and an error is thrown, the execution of the project stops. If the value is set to True, the execution of the project continues regardless of any error.

    Note:

    If this activity is included in Try Catch and the value of the Continue On Error property is True, no error is caught when the project is executed.

Windows - Legacy, Windows configuration​

  • Destination path—Windows projects only. The path in the storage bucket where the file is uploaded, including the file name. A value that ends with / is used as a folder, as is any value when Uploaded file name is set, and the file name then comes from Uploaded file name or from the source file. An empty value uploads the file to the root of the bucket. This field supports only strings and String variables.
  • Uploaded file name—Windows projects only. The name of the file in the storage bucket. When set, it is appended to Destination path, which is then used as a folder. If left empty, the name comes from Destination path or, when that is a folder or empty, from the source file. If the destination file already exists, it is overwritten.
  • Destination—Windows - Legacy projects only. The path where you want to upload the file in the Storage Bucket. The directory separator is \. If the destination file already exists, it is overwritten. This field supports only strings and String variables.
  • File—The full path of the file you want to upload to the Storage bucket indicated in the Storage Bucket Name field. This field supports variables of the IResource type. Use this field when the file is dynamically obtained during execution, such as an attachment from an email.
  • Path —The full local path to the file you want to upload to the specified Storage Bucket. Relative paths are resolved based on the runtime execution directory. This field supports only strings and String variables. Use this field when the file is located in the project folder.
  • Storage Bucket Name—The name of the Storage Bucket where you want to upload the file. This field is mandatory. This field supports only strings and String variables.
    Important:

    You must use one of these fields, as they are mutually exclusive. When specifying a local path, always use relative folder paths to ensure compatibility across different file structures on Windows and Linux systems. For example: newFolder/newFileName.txt.

Properties panel​

Common​
  • Continue On Error—Specifies if the automation should continue even when the activity throws an error. This field only supports Boolean values (True, False). The default value is False. As a result, if the field is blank and an error is thrown, the execution of the project stops. If the value is set to True, the execution of the project continues regardless of any error.

    Note:

    If this activity is included in Try Catch and the value of the Continue On Error property is True, no error is caught when the project is executed.

  • DisplayName—The display name of the activity.

  • Timeout (milliseconds)—Specifies the amount of time (in milliseconds) to wait for Orchestrator to respond, or for the file transfer to make progress, before an error is thrown. It does not limit total transfer time, so large files over slow connections still complete. The default value is 300000 milliseconds (5 minutes). Opening a connection is always limited to 30 seconds.

    Note:

    On a timeout the activity fails with a TimeoutException carrying the error code Orchestrator_Sys_Timeout, so Continue On Error and Retry Scope apply as they do to any other error. A value of 0 or a negative number is replaced with 30 seconds, and cancelling the job is reported as a cancellation rather than a timeout.

    When Orchestrator serves the file content itself instead of handing out a provider URL, which is the case on Orchestrator-managed storage with the Features.Buckets.StorageOffloadRequiresAuth feature enabled, the upload must also finish in total within this value.

  • File—The full path of the file you want to upload to the Storage bucket indicated in the Storage Bucket Name field. This field supports variables of the IResource type. Use this field when the file is dynamically obtained during execution, such as an attachment from an email.
  • Path —The full local path to the file you want to upload to the specified Storage Bucket. Relative paths are resolved based on the runtime execution directory. This field supports only strings and String variables. Use this field when the file is located in the project folder.
    Important:

    You must use one of these fields, as they are mutually exclusive. When specifying a local path, always use relative folder paths to ensure compatibility across different file structures on Windows and Linux systems. For example: newFolder/newFileName.txt.

  • Folder Path—The path to the Orchestrator Folder you want to use with this activity. If left empty, the current Orchestrator folder is used. This field supports only strings and String variables. Use / as a subfolder separator to specify the desired folder.
  • Private—If selected, the values of variables and arguments are no longer logged at Verbose level.
Storage​
  • Destination path—Windows projects only. The path in the storage bucket where the file is uploaded, including the file name. A value that ends with / is used as a folder, as is any value when Uploaded file name is set, and the file name then comes from Uploaded file name or from the source file. An empty value uploads the file to the root of the bucket. This field supports only strings and String variables.
  • Uploaded file name—Windows projects only. The name of the file in the storage bucket. When set, it is appended to Destination path, which is then used as a folder. If left empty, the name comes from Destination path or, when that is a folder or empty, from the source file. If the destination file already exists, it is overwritten.
  • Destination—Windows - Legacy projects only. The path where you want to upload the file in the Storage Bucket. The directory separator is \. If the destination file already exists, it is overwritten. This field supports only strings and String variables.
  • Storage Bucket Name—The name of the Storage Bucket where you want to upload the file. This field is mandatory. This field supports only strings and String variables.
  • Description​
  • Project compatibility​
  • Cross-platform configuration​
  • Advanced options​
  • Windows - Legacy, Windows configuration​
  • Properties panel​

Was this page helpful?

Connect

Need help? Support

Want to learn? UiPath Academy

Have questions? UiPath Forum

Stay updated