Issue
When Salesforce community user generates a DocGen package, they run into an error when it's trying to attach the document back to the record as a Salesforce File
Error Code
You do not have the level of access necessary to perform the operation you requested. Please contact the owner of the record or your administrator if access is necessary.
Resolution
Option 1 - Change the storage location to Attachment instead of FIles
(Until Community write back to Files is supported, use a custom trigger or Flow to moved the generated document to Files if required)
(Option 2 - not available for Salesforce Gov. Cloud - use Option 1 above)
Option 2 - Create an insert-update that will attach back to the record using the Admin credentials
(The admin credentials being used are whoever is authorized in the DocGen Admin tab)
Additional Information
Related Links