Generic logic (it is the same as per all other object types like Account, Contact and etc) works in a fast way with middle resource consumption but it has a limitation: it can not backup records of private files of other users (not API user) because of the salesforce API restriction by default.
The Query All files permission gives API user the possibility to access all files from generic logic. It means that with current permission, we can skip custom logic at all.
Advantages:
- speeding up the backups (for the customers who have >5 millions of files, we can even save a day, for the customers who have <100 thousands of files, the speed will be kept almost the same);
- save our cogs (by reducing memory size of redis account instances);
- track deletion of private files.
The customer should give permission to the API user by himself on salesforce side. He should create Permission Set (or take existing one), enable "Read All Files" permission and assign permission set to the API user
Salesforce Lightning:
- From Setup, in the Quick Find box, enter 'Permission Sets', and then select 'Permission Sets'.
- Click 'New'.
- Enter 'Label' and 'API Name' (any values is allowed. Spanning will find permission regardless of these values).
- Click 'Save'.
- On the newly created permission set, click 'App Permissions'.
- Click 'Edit'.
- Toggle 'Query All Files' permission under 'Content'.
- Click 'Save'.
- In the opened 'Do you want to save these permissions?' popup, click 'Save'.
- From Setup, in the Quick Find box, enter 'Users', and then select 'Users'.
- Find and click on Spanning api user that was connected to Spanning app.
- Under 'Permission Set Assignments', click 'Edit Assignments'.
- From the list of 'Available Permission Sets', move created earlier permission set to the 'Enabled Permission Sets'.
- click 'Save'.
Salesforce Classic:
- Go to Setup -> Manage Users -> Permission Sets.
- Click 'New'.
- Enter 'Label' and 'API Name' (any values is allowed. Spanning will find permission regardless of these values).
- Click 'Save'.
- On the newly created permission set, click 'App Permissions'.
- Click 'Edit'.
- Toggle 'Query All Files' permission under 'Content'.
- Click 'Save'.
- In the opened 'Do you want to save these permissions?' popup, click 'Save'.
- Go to Setup -> Manage Users -> Users.
- Find and click on Spanning api user that was connected to Spanning app.
- Under 'Permission Set Assignments', click 'Edit Assignments'.
- From the list of 'Available Permission Sets', move created earlier permission set to the 'Enabled Permission Sets'.
- click 'Save'.