Implement an Integration to Send a PDF/CSV Document Downloaded from an SFTP Server to an External REST API that Accepts Only application/octet-stream as the Content Type

In an orchestrated integration, the FTP adapter is only supported as an invoke connection. Implement this use case by selecting either an App Driven Orchestration or Scheduled Orchestration integration on the Integration Style dialog.

The following example provides a high level overview on how to implement this use case as a scheduled orchestration.
Description of rest_adapter_octet_str1.png follows
Description of the illustration rest_adapter_octet_str1.png

  1. Configure an FTP Adapter with the List Files operation to list files from an SFTP server.


    Description of rest_adapter_list_files.png follows
    Description of the illustration rest_adapter_list_files.png
  2. Configure a for-each action to iterate through the List Files operation response.


    Description of rest_adapter_for_each.png follows
    Description of the illustration rest_adapter_for_each.png
  3. Configure a second FTP Adapter with the Read Files operation to read individual files inside the loop.


    Description of rest_adapter_read_files.png follows
    Description of the illustration rest_adapter_read_files.png
  4. Configure the FTP Adapter to not specify a structure of the file.


    Description of rest_adapter_read_files2.png follows
    Description of the illustration rest_adapter_read_files2.png
  5. Configure a REST Adapter. The reference of the Read Files operation is handed over to the outbound REST Adapter.



  6. Configure the REST Adapter payload as application/octet-stream.



  7. Configure the mapper to read individual files in the for-each loop.


    Description of rest_adapter_map_for1.png follows
    Description of the illustration rest_adapter_map_for1.png
  8. Configure the mapper to send the read file to the outbound REST Adapter.


    Description of rest_adapter_map_for2.png follows
    Description of the illustration rest_adapter_map_for2.png