Pay Sub Type Lookup
|Pay Sub type Request|
|Department List Request|
|Classification List Request|
|Location List Request|
|Working Week Request|
Setting Up and Employee To Be Paid By Wages
The default behaviour of the REST interface is to use NetSuite Payroll Configuration to default employees as a salaried employee. This means the system automatically defaults the following fields (employmentstatus: FULLTIME, paytype: SALARY). To configure a waged employee either a new hire or to change an employee from salaried to wages the following fields need to be specified (the example below is assuming an update and creating a normal time pay component).
The pay component for normal time requires a unit of measure (uom), the employee's hourly rate (rate), a quantity (default number of hours for the period), and the amount (rate * quantity).
Adding Timing To Netsuite To Represent Time Off
Employee leave requests entered in External HR System will need to be translated into the hours of a given leave type and a create request made to create the timeentry records in NetSuite. Each time entry should comprise of 4 fields. Note: Usually 21 is internal id of Annual Leave, 22 internalid of sick leave paid.
data as array or object
The data block in the request can be specified either as a single object, or an array of objects
As there is no workday reference on the time generated updates can't be made, so instead a change will consist of two time entry additions; the first to represent the negation of the previous request that is being changed, and a second to represent the updated record. Below is an example to negate the previous request and replace it with 8 hours of paid sick leave.
Updating Leave Balances Where Accrual Is Managed Externally
If leave balances are maintained externally the totals can be updated into payroll in one of two ways:
- Using the syncEmployee function in the payroll block
- Using a newly exposed bulkUpdate function
Note: Whilst you can submit balance updates using syncEmployee, the overhead and additional business logic makes it less efficient and much slower to do so.
The bulk update action has two advantages over the syncEmployee function, it allows multiple employees to be submitted in the same request, and it performs no business or record level script resulting in less overhead and better performance. The bulk update is currently only supports the employee record and the update of leave balance fields:
|Field In JSON Request Object||Map To NetSuite Employee Field|
An example request and response is listed below, containing updates for two employees. One or more fields must be specified but it is not mandatory to submit all.
Note: The Update of the employees work schedule (working week) cannot be updated using the bulk update as it is reliant on other actions