Schedule the Script Creating SFTP Record
The script Create Generic SFTP Record needs to be scheduled, so with the selected frequency check it can check if there is any new file in the File cabinet and create a custom record for every new file.
Navigate to Customizations > Scripting > Scripts. Filter type = Map/Reduce and find the script Create Generic SFTP Record. Click View.
Navigate to the Deployments subtab, click on the Deployment Title.
Edit the Deployment and schedule it with the frequency that you would like to have the File Cabinet checked for new files waiting to be uploaded to the remote server. Navigate to the subtab Parameters to set the following information:
- Saved Search ID (this search should search the files that must be uploaded)
- Upload action configuration (select here the upload configuration that should be used to upload the files)
Configure the Upload Configuration
On the upload configuration, the user must set the correct source for the data file. To alter your upload configuration navigate to Setup > SFTP Connector > Upload Action Configuration and edit the configuration that should automatically upload the file. In the field “File source“ set the following value “custrecord_ff_sftp_gen_document“.