# Handle Download Block

<figure><img src="https://742850480-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fmtnl2J19CnNVA5fLFAPs%2Fuploads%2FG2xtbGyk957m1xQDy9Fn%2FHandle%20download.jpg?alt=media&#x26;token=4cc1c8ef-dd44-4e48-b908-376d8b7ccac5" alt=""><figcaption></figcaption></figure>

This block processes the downloaded file. Please note that the block must be set before the file is uploaded. You need to use this block before the process of downloading a file from the site begins. For example, when the download occurs after clicking on the download button.

<figure><img src="https://742850480-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fmtnl2J19CnNVA5fLFAPs%2Fuploads%2F3I6ijHQhPdLI63j4k4CW%2FHandle%20download1.jpg?alt=media&#x26;token=cad752a4-bb12-48a5-878e-7c8dde48b8b6" alt=""><figcaption></figcaption></figure>

Below is a screenshot of the block settings.

<figure><img src="https://742850480-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fmtnl2J19CnNVA5fLFAPs%2Fuploads%2FBGXhO9ElvpLNmgsCl8ee%2FHandle%20download2.jpg?alt=media&#x26;token=01b06bae-5d7b-4c8d-8325-436d9169e110" alt=""><figcaption></figcaption></figure>

Settings of the Handle Download block:

* **Timeout.** Set the workflow pending time for the downloaded file to complete (by default, it is 20000ms - 20 seconds. After the time is up, the workflow continues to execute the block.
* **Download id.** The id of download item to handle. File download ID is a unique identifier that is assigned to the downloaded file. This identifier is used to track the download process, as well as to ensure security and control access to the file.
* **File name.** The name of the downloaded file. Leave this field empty if you want to keep the name unchanged.
* **On conflict.** Indicates what to do if a downloaded file's name conflicts with an existing file.
  * `"uniquify".`The browser will change the file name to be unique..
  * `"overwrite".`The browser will overwrite the old file with the recently uploaded file.
  * `"prompt".`The browser will ask the user to make a choice between uniquify or overwrite.

<figure><img src="https://742850480-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fmtnl2J19CnNVA5fLFAPs%2Fuploads%2FJdx61BQz7iOYgqVpsopA%2FHandle%20download3.jpg?alt=media&#x26;token=60648547-8e26-4dbb-8404-bfffa2228f0b" alt=""><figcaption></figcaption></figure>

* **Wait for the file to be downloaded.** Wait until the file is completely downloaded before continuing to the next block. Setting this setting allows you to access the ability to save information about the uploaded file to a variable or table.

<figure><img src="https://742850480-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fmtnl2J19CnNVA5fLFAPs%2Fuploads%2Fgm75n3WbyNDZ4BbTUy3P%2FHandle%20download4.jpg?alt=media&#x26;token=0d2bddba-f020-4706-af7b-dd5f5ef52e6c" alt=""><figcaption></figcaption></figure>

* **Assign to variable.** Defines whether the downloaded file's path will be assigned to a variable or not.
* **Variable name.** Variable name to assign a file path.
* **Insert to table.** Defines whether to insert or not the filepath in the table.
* **Select column.** A column to insert the file path.
