getListOfFiles |
This Web service operation is used to list files and folders in a specified directory on the FTP server.
SOAP Request
<SOAP:Envelope xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/"> <SOAP:Body> <getListOfFiles xmlns="http://schemas.cordys.com/1.0/ftp"> <server>srv-ind-vm2b</server> <user>ftpuser</user> <password>ftpuser</password> <portno>21</portno> <notification-subject>FTP</notification-subject> <directory details="true">/</directory> </getListOfFiles> </SOAP:Body> </SOAP:Envelope>
Request Parameters
Tags |
Description |
---|---|
server |
Name of the FTP server from which the list of files must be retrieved. |
user |
Name of the FTP user. |
password |
Password for the FTP user. |
portno |
The port number used by the FTP server; this tag is optional. |
notification-subject |
Notification subject on which the user has to subscribe to the Event service, to obtain the status of the request. |
directory |
The directory path from which the files are listed. You can set the following values to this parameter.
|
SOAP Response
<getListOfFilesResponse xmlns="http://schemas.cordys.com/1.0/ftp" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/"> <server>srv-ind-vm2b</server> <user>ftpuser</user> <portno>21</portno> <notification-subject>FTP</notification-subject> <directory>/</directory> <file>aa.txt <size>33</size> <lastmodified>2009-05-18T12:01:00</lastmodified> </file> <file>dir1 <lastmodified>2010-01-25T14:21:00</lastmodified> </file> <statuscode>226</statuscode> <status>Transfer complete.</status> </getListOfFilesResponse>
Table 1. Response Parameters
Tags |
Description |
---|---|
<name> |
Name of the file. |
size |
Size of the file in bytes. |
lastmodified |
Timestamp when the file was last modified on the server. |