ProjectTask inaccessible through V8 API in 7.15.2 – oversight or intentional?

I’ve been doing some work integrating SuiteCRM with AI agents and ran into an interesting issue trying to retrieve Project Tasks through the V8 API in 7.15.2.

Despite granting the API user the appropriate permissions for Project Tasks, the following request fails:

GET /Api/V8/module/ProjectTask

With the error:

The API user does not have access to this module.

After digging through the source code, I’ve identified the issue in Api/V8/Helper/ModuleAccessChecker.php.

The API determines module availability based on the displayed navigation modules. However, ProjectTask is registered in $modInvisList rather than $moduleList in include/modules.php.

Consequently, the API rejects the request before it even gets to the record-level ACL checks, regardless of the permissions granted to the user.

I’ve reproduced this against a clean 7.15.2 source baseline.

Interestingly, I also found an older forum discussion where users were successfully creating ProjectTask records through the V8 API in 7.11.2, so I suspect this may be a regression.

The fix itself is relatively straightforward, but I’m struggling a bit with what the correct approach should be. @suitecrm_team

There are three possibilities I can think of:

  1. Add ProjectTask to the standard module list.

  2. Add a specific exception for ProjectTask in ModuleAccessChecker, while retaining the existing ACL checks.

  3. Introduce a configurable list of additional API-accessible modules in config_override.php, which would still be subject to normal ACL checks.

On a related note, I’ve always wondered why Project Tasks aren’t available directly from the navigation menu in the first place. Personally, I’d find it quite useful to access the Project Task list without having to open individual Projects first.

Does anyone know if there is a particular historical or technical reason why ProjectTask is excluded from the standard module list?

Also, are there other legitimate modules that are intentionally hidden from navigation but should be accessible through the API?

I’m happy to put together a patch, but I’d like to get some input from the community on the preferred approach before doing so.

Thanks for the thorough write-up, you’ve diagnosed it exactly right. This is a known issue in 7.15.2 and 8.10.2: the API checked module access against the navigation list, so modules that aren’t in the navigation, like ProjectTask, were refused before the permissions were even looked at. It wasn’t intentional.

We already have a fix for the next release, which is due out very soon. It’s PR #10944, reported as #10895, and it’s already merged on the SuiteCRM 7 hotfix branch in preparation. It makes the API check the user’s actual permissions on the module instead of the navigation, so none of the three options you listed is needed. We’re also still addressing some further related API issues with modules that don’t implement ACLs.