Using WebDAVClient to Integrate Backend Systems with Salesforce B2C Commerce

B2C Commerce implements a WebDAV client in the B2C Commerce Script API to enable developers to access remote locations via the WebDAV protocol.

You must have File Transfer Manager access privileges to access the Import/Export WebDAV share.

The WebDAVClient class is the actual client, while the WebDAVFileInfo class is used to store information about the files that are at the remote destination. Use the WebDAVClient class to synchronize directories from a remote server with the B2C Commerce file system or to export files out of the B2C Commerce system. The client supports the following common WebDAV methods:

The names of the script methods correspond exactly with the names of the WebDAV methods. The methods propfind() and list(), used to get information about remote files and directories, return instances of WebDAVFileInformation, which encapsulate this information.

Note: This client can't be used to access the B2C Commerce server via the WebDAV protocol.


    var webdavClient : WebDAVClient = new
     var getString : String = webdav.get("","UTF-8");
     var message : String;
       message = webDavClient.statusText;
     // error handling
       message="An error occurred with status code "+webdavClient.statusCode;
     var data : XML = new XML(getString));

For more information, see the section on classes and methods.

X Privacy Update: We use cookies to make interactions with our websites and services easy and meaningful, to better understand how they are used. By continuing to use this site you are giving us your consent to do this. Privacy Policy.