If you encounter the “INSUFFICIENT_PERMISSION: You need a higher level of the ‘Lists -> Documents and Files’ permission” error while using nlapiLoadFile or N/file.load() in your SuiteCommerce Advanced (SCA) environment, follow these steps to resolve it:
- Temporarily switch to the “SC Deployer” role and check if the issue persists.
- Verify and update role permissions:
- Go to Setup > Users/Roles > Manage Roles.
- Select the role used by your SSP application.
- Under Permissions → Lists, ensure Documents and Files has Full Access.
- If switching to SC Deployer fixes the issue, manually add the same permissions from SC Deployer to your new role.
- Save the changes and re-test your script.
By applying the same permissions as SC Deployer to your custom role, you can resolve permission violations and ensure seamless file access in your SuiteCommerce Advanced deployment.