SFTP Client PWD Service

The SFTP Client PWD service retrieves the present working directory from the trading partner's SFTP server.

The following table provides an overview of the SFTP Client PWD service:

Category Description
System name SFTP Client PWD Service
Graphical Process Modeler (GPM) category All Services, B2B Protocols > SFTP Client
Description Retrieves the present working directory from the trading partner's SFTP server.
Business usage Use this service to get information about the current working directory on the trading partner SFTP server.
Usage example A business process is executed to place a document in a specific directory on the trading partner's system. To include the name of the directory where the document was placed, use the SFTP Client PWD service to place the directory information in the business process.
Preconfigured? Yes. Uses the preconfigured service in a business process.
Requires third-party files? No
Platform availability All Sterling B2B Integrator supported platforms
Related services The following services are related. Configured in a business process, they initiate the SFTP Client adapter to perform their operations:
  • SFTP Client Begin Session service
  • SFTP Client CD service
  • SFTP Client DELETE service
  • SFTP Client End Session service
  • SFTP Client GET service
  • SFTP Client LIST service
  • SFTP Client MOVE service
  • SFTP Client MKDIR service
  • SFTP Client PUT service
  • SFTP Client PWD service
  • SFTP Client RMDIR service
Application requirements An SFTP Server at the external trading partner location.
Initiates business processes? No
Invocation This service is invoked from a business process.
Business process context considerations None
Returned status values
Returned status values:
  • 0 –Success
  • 1 – Error
Restrictions N/A
Persistence level System Default
Testing considerations To test this service, run the SFTPClientDemoAllServices business process and verify that it completes successfully. For more information about the SFTPClientDemoAllServices business process, see the SFTP Client adapter. Debug information for this service is located at: Operations > System > Logs > SFTP Client Adapter and Services.

Input from Business Process to Service

The following table contains the parameters passed from the business process to the SFTP Client PWD service:

Field Description
SessionToken Specifies the identifier for the session established between the SFTP Client adapter and an SFTP server. Required.

Output from Service to Business Process

The following table contains the parameters passed from the SFTP Client PWD service to the business process:

Parameter Description
ServerResponse The SFTP server response, which may include a reply code and any text associated with the reply code. Valid values are:
  • OK - 0
  • No Such File - 2
  • Permission Denied - 3
  • General Failure - 4
  • Bad Message - 5
  • No Connection - 6
  • Connection Lost - 7
  • Operation Unsupported - 8
Pwd Directory Specifies the current directory.

Business Process Example

The following example business process excerpt illustrates using the SFTP Client PWD service:

[[Insert Begin Session]]
<operation name="SFTP PWD SERVICE">
  <participant name="SFTPClientPwd"/>
    <output message="PwdRequest">
      <assign to="SessionToken" 
    <input message="inmsg">
      <assign to="SFTPClientPwdResults" from="*"></assign>
[[Insert End Session]]