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 the illustration rest_adapter_octet_str1.png
-
Configure an FTP Adapter with the List Files operation to list files from an SFTP server.
Description of the illustration rest_adapter_list_files.png -
Configure a for-each action to iterate through the List Files operation response.
Description of the illustration rest_adapter_for_each.png -
Configure a second FTP Adapter with the Read Files operation to read individual files inside the loop.
Description of the illustration rest_adapter_read_files.png -
Configure the FTP Adapter to not specify a structure of the file.
Description of the illustration rest_adapter_read_files2.png -
Configure a REST Adapter. The reference of the Read Files operation is handed over to the outbound REST Adapter.
-
Configure the REST Adapter payload as application/octet-stream.
-
Configure the mapper to read individual files in the for-each loop.
Description of the illustration rest_adapter_map_for1.png -
Configure the mapper to send the read file to the outbound REST Adapter.
Description of the illustration rest_adapter_map_for2.png