As far as I can find, there's no search function in the Payroll API endpoints. Which means the only solution for anything to do with them seems to be to fetch all payruns and from that data fetch all (relevant) payslips.
Which means:
- 1 API call to get the PayRun list
- 1 API Call for each relevant RayRun (based on dates) to get the PaySlips list associated with it
- 1 API Call for each PaySlip (based on EmployeeID)
When that could all be done with a single API call the same way we can for fetching eg. Invoice Data
- 1 API Call for PaySlips Where employeeID==The_ID AND periodStartDate>=...
As far as I can find, there's no search function in the Payroll API endpoints. Which means the only solution for anything to do with them seems to be to fetch all payruns and from that data fetch all (relevant) payslips.
Which means:
- 1 API call to get the PayRun list
- 1 API Call for each relevant RayRun (based on dates) to get the PaySlips list associated with it
- 1 API Call for each PaySlip (based on EmployeeID)
When that could all be done with a single API call the same way we can for fetching eg. Invoice Data
- 1 API Call for PaySlips Where employeeID==The_ID AND periodStartDate>=...