Use API functionality to check projects for 3 departments and add one if missing

Use API functionality to check projects for 3 departments and add one if missing

I use Postman with Zoho People for my APIs (I may not be saying that correctly). I have approximately 10,000 projects. Is it possible to create some sort of API that checks each of the projects and adds all three departments to a project if it does not already have three associated with it? Further, it would then add one or all three to the project?

Alternatively, is there a way using API to pull a report of all projects and jobs and their associated departments? In other words, it would show a list of each project and in the column next to it list each department that has access to the project.