BPM Attachments

I really like the functionality of adding attachments to the BPM process. i noticed that whenever I upload a file from the application, that file can be visible by going to Administration -> External Files.
My BPM process starts by a service task that will generate a file. I was wondering if it was possible to have my service task include the generated file as part of the attachment so that when the user that is assigned the task can just see the attached file and review it?
Thanks.

All you have to do is to store a couple of entities to the database.
First you have to create a FileDesriptor object (you can use FileStorageAPI methods for saving the content of your files into file storage).
Then create a ProcAttachment entity, fill required fields and links to FileDescriptor and ProcInstance objects.
The BPM data model diagram is here: [url=]https://doc.cuba-platform.com/bpm-6.0/datamodel.html[/url].