Assign a Payroll

To assign a payroll to a worker:

  1. Retrieve (GET) the PayrollId for the payroll you are assigning by using the payrollDefinitionsLOV API.
  2. Retrieve (GET) the payroll relationship details and obtain the link to the assignedPayrolls collection.
  3. Perform a POST operation on this URL by providing the Payroll ID and start date in the request body.

Example URL

Use this resource URL format.

POST

/hcmRestApi/resources/11.13.18.05/payrollRelationships/{payrollRelationshipsUniqID}/child/payrollAssignments/{payrollAssignmentsUniqID}/child/assignedPayrolls

Example Request

Here's an example of the request body in JSON format.

Provide the headers.

Content-Type : application/vnd.oracle.adf.resourceitem+json
REST-Framework-Version : 4
{
"PayrollId": 100010027340651,
"StartDate": "2019-06-01"
}

Example Response

Here's an example of the response body in JSON format.

{
"AssignedPayrollId": 300100178113576,
"PayrollId": 100010027340651,
"StartDate": "2019-05-15",
"EndDate": "4712-12-31",
"TimeCardRequired": null,
"OverridingPeriodId": null,
"EffectiveStartDate": "2019-05-15",
"EffectiveEndDate": "4712-12-31",
"Lsed": null,
"links": [...]
}