---
sourceDocument: Xanadu Build workflows
sourceDocumentLink: https://www.servicenow.com/docs/r/xanadu/build-workflows

 Release :

    - xanadu

ft:locale :

    - en-US

ft:publication_title :

    - Xanadu Build workflows

ft:clusterId :

    - crworkflow

bundleId :

    - crworkflow

workflow :

    - Creator


---

# Copy Files To This Instance

# Copy Files To This Instance {#ariaid-title1}

* Release version: Xanadu
* 
* Updated August 1, 2024
* 
* ![](https://www.servicenow.com/docs/portal-asset/ico-clock) 4 minutes to read

Attaches the specified files in the SFTP server to the specified record in ServiceNow instance.{#copy-files-instace__copy-file-instance}
{#copy-files-instace__table_ypp_krp_nnb__entry__2}

| Field | Description |
|-|-|
| Connections ||
| Connection | Type of connection to use to connect to the source SFTP server. * Define Connection Inline: Define connection information within the action step. * Use Connection Alias: Define connection information using the Connection Alias table. Using an alias eliminates the need to configure multiple credentials and connection information profiles when using an action in multiple environments. Likewise, if the connection information changes, you don't need to update your custom action. {#copy-files-instace__ul_bfs_tvt_khb} To learn more about connections and credentials, see [Introduction to credentials, connections, and aliases](https://www.servicenow.com/docs/access?context=credentials-connections-alias&version=xanadu&pubname=xanadu-platform-security&ft:locale=en-US). |
| Connection Alias | Connection \& Credential alias record that the system uses to run the action step. Users with the flow_designer or admin role can create or select an associated Connection record. Using an alias eliminates the need to configure multiple credentials and connection information profiles when using an action in multiple environments. Likewise, if the connection information changes, you don't need to update your custom action. To learn more about connections and credentials, see [credentials, connections, and aliases](https://www.servicenow.com/docs/access?context=credentials-connections-alias&version=xanadu&pubname=xanadu-platform-security&ft:locale=en-US). The credential value is displayed as a Password (2 Way Encrypted) data pill on the data panel. This field is available when Use Connection Alias is selected from the Connection list. |
| Credential Alias | Credential alias that the system uses to run the action step. Users with the flow_designer or admin role can create or select an associated Connection record. Using an alias eliminates the need to configure multiple credentials when using an action in multiple environments. Likewise, if the credential information changes, you don't need to update your custom action. To learn more about connections and credentials, see [credentials, connections, and aliases](https://www.servicenow.com/docs/access?context=credentials-connections-alias&version=xanadu&pubname=xanadu-platform-security&ft:locale=en-US). The credential value is displayed as a Password (2 Way Encrypted) data pill on the data panel. This field is available when Define Connection Inline is selected from the Connection list. Note: The SFTP step requires a credential record that supports either SSH private key credentials or SSH credentials. This step does not support Windows credentials where the Use MID Server service account option is selected. |
| Host | Name or IP address of the SFTP server to which the files you should be copied. This field is available when Define Connection Inline is selected from the Connection list. |
| Port | Port number to communicate with the server. This field is available when Define Connection Inline is selected from the Connection list. |
| MID Selection | Option to select a specific MID Server or MID Cluster. Choose any one of the following options. * Auto-Select MID Server: Your ServiceNow instance selects the MID Server without manual input. * Specific MID Server: Your ServiceNow instance uses MID Server that you specify. * Specific MID Cluster: Your ServiceNow instance uses the MID Cluster that you specify. A MID Cluster is a group of MID Servers that enables your ServiceNow instance to handle multiple integrations, and improve integration speed. For more information, see [Configure a MID Server cluster](https://www.servicenow.com/docs/access?context=t_ConfigureAMIDServerCluster&version=xanadu&pubname=xanadu-servicenow-platform&ft:locale=en-US). {#copy-files-instace__ul_cdk_njb_htb} This field is available when Define Connection Inline is selected from the Source Connection list. |
| MID Server | Specific MID Server to run the SFTP step. This field is available when Specific MID Server is selected from the MID Selection list. |
| MID Cluster | Data pill for the MID Cluster you want to use. This field is available when Define Connection Inline is selected from the Source Connection list, and Specific MID Cluster is selected from the MID Selection list. |
| MID Application | Option to use a MID Server to run the SFTP step. This field is available when Define Connection Inline is selected from the Connection list and Auto-Select MID Server is selected from the MID Selection list. |
| Capabilities | Capability of the MID Server. Select SSH. This field is available when Define Connection Inline is selected from the Connection list and Auto-Select MID Server is selected from the MID Selection list. |
| MID Server | Data pill of the required MID Server. This field is available when Define Connection Inline is selected from the Connection list and Specific MID Server is selected from the MID Selection list. |
| SFTP Files To Copy ||
| Source Path | Path of the directory that contains the files you want to copy. For example, <kbd class="ph userinput">/root/doc/</kbd>. |
| Include Files | List of target files to copy. This is a semicolon separated list that accepts wild cards, such as <kbd class="ph userinput">*.txt</kbd>. Note: If no value is provided, subfolders in the specified directory are copied. |
| Exclude Files | List of target files that should not be copied. This is a semicolon separated list that accepts wild cards, such as <kbd class="ph userinput">*.txt</kbd>. |
| Maximum File Size (KB) | Maximum size of the file that can be copied. |
| Maximum Number of Files | Maximum number of files that can be copied in a request. |
| Attach Files To This Target Record ||
| Target Record | Record in ServiceNow instance to which you want to attach the files. |
| Table | ServiceNow table in which the target record is saved. |
| Retry Policy ||
| Enable Retry Policy | Option to enable the retry policy. For more information, see [Retry policy](https://www.servicenow.com/docs/bDj7eiMJxqf_pNxzKa~eFQ#retry-policy "Automatically retry failed requests when a step encounters an intermittent issue such as a network failure or request rate limit. Set a retry policy to prevent having to manually trigger the step again."). |
| Override Default Policy for Alias | Option to override the default retry policy. This option is not applicable when Define Connection Inline is selected from the Connection list. |
| Retry Policy | Default retry policy associated with Connection Alias. If Override Default Policy for Alias is selected, you can override the default retry policy and select another existing retry policy based on your requirement. |
[Table 1. Fields]

{#copy-files-instace__table_ypp_krp_nnb}

## Action error evaluation {#copy-files-instace__id_lg2_4s3_15b}

If this step fails
:   Data type: Choice

    Option to continue running the next step or go to error evaluation. To use the step status code or message for a custom action error condition, see [Action error evaluation](https://www.servicenow.com/docs/UX~xSz7YRW1LunX5VfnB7A "Enable actions to catch step failures and continue running. Identify when specific error conditions occur and return your own action status code, status message, and error state.").

