Modules

filter

 

Objects/Functions

module (N/sftp)

SuiteScript 2.0

Connection.download(options)

{Connection}.download({filename: {string},directory: {string},timeout: {number}})

N/sftp Module
Connection.download()
Method Description: Downloads a file from the remote FTP server.
Returns: file.File Object
Supported Script Types: Server-side scripts For more information, see SuiteScript 2.0 Script Types.
Governance: 100 units
Module: N/sftp Module
Since: 2016.2
Search NetSuite - https://system.netsuite.com/app/help/helpcenter.nl?search=Connection.download(options)

Example:

// Code Example 1
//Add additional code
//...
var downloadedFile = objConnection.download({
directory: 'relative/path/to/file',
filename: 'downloadMe.js'
});
//...
//Add additional code

//SOURCE: https://system.netsuite.com/app/help/helpcenter.nl?fid=section_4618664030.html