Provide a document downloadable link/direct download option for documents stored in Amazon S3 webstorage
We have a requirement to provide a downloadable link for the attachments uploaded in the work objects. Downloadable link needs to be provided as a REST service response which is exposed by Pega. As documents are stored in Amazon S3 there is no direct download link to documents without logging into pega. Below is the sample document location:
file://pegacloudfilestorage:/attachments/sample_CNR-10074.pdf
Also tried the direct download option by using sendFile() api but this works when service executed from Pega standalone. When we call the service from postman/SOAP UI, document download pop-up appears but there is no content and documents are getting corrupted.
Used below java in service activity to Service activity is