If the employee with the specified ID already exists, update it. Otherwise, create a new employee.

Request

POST https://api.nzpayroll.co.nz/api/v2/business/{businessId}/employee/unstructured

Path parameters

Parameter name Value Description Additional
businessId string Required

Request body

The request body takes a complete NzUnstructuredEmployeeModel resource, containing the following writable properties:

{
    "anniversaryDate": "date-time",
    "automaticallyPayEmployee": "string",
    "bankAccount1_AccountName": "string",
    "bankAccount1_AccountNumber": "string",
    "bankAccount1_AllocatedPercentage": "double",
    "bankAccount1_BankCode": "string",
    "bankAccount1_FixedAmount": "double",
    "bankAccount2_AccountName": "string",
    "bankAccount2_AccountNumber": "string",
    "bankAccount2_AllocatedPercentage": "double",
    "bankAccount2_BankCode": "string",
    "bankAccount2_FixedAmount": "double",
    "bankAccount3_AccountName": "string",
    "bankAccount3_AccountNumber": "string",
    "bankAccount3_AllocatedPercentage": "double",
    "bankAccount3_BankCode": "string",
    "bankAccount3_FixedAmount": "double",
    "dateCreated": "date-time",
    "dateOfBirth": "date-time",
    "emailAddress": "string",
    "emergencyContact1_Address": "string",
    "emergencyContact1_AlternateContactNumber": "string",
    "emergencyContact1_ContactNumber": "string",
    "emergencyContact1_Name": "string",
    "emergencyContact1_Relationship": "string",
    "emergencyContact2_Address": "string",
    "emergencyContact2_AlternateContactNumber": "string",
    "emergencyContact2_ContactNumber": "string",
    "emergencyContact2_Name": "string",
    "emergencyContact2_Relationship": "string",
    "employmentType": "string",
    "endDate": "date-time",
    "externalId": "string",
    "firstName": "string",
    "gender": "string",
    "homePhone": "string",
    "hoursPerWeek": "double",
    "id": "int32",
    "isEnabledForTimesheets": "string",
    "jobTitle": "string",
    "kiwiSaver_ContributionHolidayFromDate": "date-time",
    "kiwiSaver_ContributionHolidayToDate": "date-time",
    "kiwiSaver_EmployeeContribution": "int32",
    "kiwiSaver_EmployerContribution": "int32",
    "kiwiSaver_EnrollmentStatus": "string",
    "kiwiSaver_IneligibilityReason": "string",
    "kiwiSaver_OptOutDate": "date-time",
    "leaveAccrualStartDateType": "string",
    "leaveTemplate": "string",
    "leaveYearStart": "date-time",
    "locations": "string",
    "middleName": "string",
    "mobilePhone": "string",
    "overrideTemplateRate": "string",
    "payConditionRuleSet": "string",
    "payRateTemplate": "string",
    "paySchedule": "string",
    "paySlipNotificationType": "string",
    "postalAddressLine2": "string",
    "postalPostCode": "string",
    "postalState": "string",
    "postalStreetAddress": "string",
    "postalSuburb": "string",
    "preferredName": "string",
    "previousSurname": "string",
    "primaryLocation": "string",
    "primaryPayCategory": "string",
    "rate": "double",
    "rateUnit": "string",
    "residentialAddressLine2": "string",
    "residentialPostCode": "string",
    "residentialState": "string",
    "residentialStreetAddress": "string",
    "residentialSuburb": "string",
    "rosteringNotificationChoices": "string",
    "startDate": "date-time",
    "status": "string",
    "surname": "string",
    "tags": "string",
    "taxCodeDeclaration_DateSigned": "date-time",
    "taxCodeDeclaration_ElectedExtraPayRate": "double",
    "taxCodeDeclaration_EmploymentType": "string",
    "taxCodeDeclaration_EsctRate": "double",
    "taxCodeDeclaration_FtcOverseasSuperOrPension": "boolean",
    "taxCodeDeclaration_IncomeAppliedToTestedBenefit": "boolean",
    "taxCodeDeclaration_IncomeBand": "int32",
    "taxCodeDeclaration_IrdNumber": "string",
    "taxCodeDeclaration_IsNonDisclosed": "boolean",
    "taxCodeDeclaration_IsPrimaryIncome": "boolean",
    "taxCodeDeclaration_MeetsMainIncomeMeansTest": "boolean",
    "taxCodeDeclaration_NewZealandResident": "boolean",
    "taxCodeDeclaration_SpecialTaxCode": "string",
    "taxCodeDeclaration_SpecialTaxCodeRate": "double",
    "taxCodeDeclaration_SpecialTaxCodeRateEndDate": "date-time",
    "taxCodeDeclaration_StudentLoan": "boolean",
    "taxCodeDeclaration_StudentLoanRate": "double",
    "taxCodeDeclaration_StudentLoanRateEndDate": "date-time",
    "title": "string",
    "workPhone": "string",
    "workTypes": "string"
}

Properties

Name Type Description
anniversaryDate date-time Nullable
automaticallyPayEmployee string String
bankAccount1_AccountName string String
bankAccount1_AccountNumber string String
bankAccount1_AllocatedPercentage double Nullable
bankAccount1_BankCode string String
bankAccount1_FixedAmount double Nullable
bankAccount2_AccountName string String
bankAccount2_AccountNumber string String
bankAccount2_AllocatedPercentage double Nullable
bankAccount2_BankCode string String
bankAccount2_FixedAmount double Nullable
bankAccount3_AccountName string String
bankAccount3_AccountNumber string String
bankAccount3_AllocatedPercentage double Nullable
bankAccount3_BankCode string String
bankAccount3_FixedAmount double Nullable
dateCreated date-time DateTime
dateOfBirth date-time Nullable
emailAddress string String
emergencyContact1_Address string String
emergencyContact1_AlternateContactNumber string String
emergencyContact1_ContactNumber string String
emergencyContact1_Name string String
emergencyContact1_Relationship string String
emergencyContact2_Address string String
emergencyContact2_AlternateContactNumber string String
emergencyContact2_ContactNumber string String
emergencyContact2_Name string String
emergencyContact2_Relationship string String
employmentType string String
endDate date-time Nullable
externalId string String
firstName string String
gender string String
homePhone string String
hoursPerWeek double Nullable
id int32 Int32
isEnabledForTimesheets string String
jobTitle string String
kiwiSaver_ContributionHolidayFromDate date-time Nullable
kiwiSaver_ContributionHolidayToDate date-time Nullable
kiwiSaver_EmployeeContribution int32 Nullable
kiwiSaver_EmployerContribution int32 Nullable
kiwiSaver_EnrollmentStatus string String
kiwiSaver_IneligibilityReason string String
kiwiSaver_OptOutDate date-time Nullable
leaveAccrualStartDateType string Nullable

Possible values are:

  • EmployeeStartDate
  • SpecifiedDate
leaveTemplate string String
leaveYearStart date-time Nullable
locations string String
middleName string String
mobilePhone string String
overrideTemplateRate string String
payConditionRuleSet string String
payRateTemplate string String
paySchedule string String
paySlipNotificationType string String
postalAddressLine2 string String
postalPostCode string String
postalState string String
postalStreetAddress string String
postalSuburb string String
preferredName string String
previousSurname string String
primaryLocation string String
primaryPayCategory string String
rate double Nullable
rateUnit string String
residentialAddressLine2 string String
residentialPostCode string String
residentialState string String
residentialStreetAddress string String
residentialSuburb string String
rosteringNotificationChoices string String
startDate date-time Nullable
status string EmployeeStatusEnum

Possible values are:

  • Active
  • Terminated
  • Incomplete
surname string String
tags string String
taxCodeDeclaration_DateSigned date-time Nullable
taxCodeDeclaration_ElectedExtraPayRate double Nullable
taxCodeDeclaration_EmploymentType string String
taxCodeDeclaration_EsctRate double Nullable
taxCodeDeclaration_FtcOverseasSuperOrPension boolean Boolean
taxCodeDeclaration_IncomeAppliedToTestedBenefit boolean Boolean
taxCodeDeclaration_IncomeBand int32 Nullable
taxCodeDeclaration_IrdNumber string String
taxCodeDeclaration_IsNonDisclosed boolean Nullable
taxCodeDeclaration_IsPrimaryIncome boolean Boolean
taxCodeDeclaration_MeetsMainIncomeMeansTest boolean Boolean
taxCodeDeclaration_NewZealandResident boolean Boolean
taxCodeDeclaration_SpecialTaxCode string String
taxCodeDeclaration_SpecialTaxCodeRate double Nullable
taxCodeDeclaration_SpecialTaxCodeRateEndDate date-time Nullable
taxCodeDeclaration_StudentLoan boolean Boolean
taxCodeDeclaration_StudentLoanRate double Nullable
taxCodeDeclaration_StudentLoanRateEndDate date-time Nullable
title string String
workPhone string String
workTypes string String

Response

The following HTTP status codes may be returned, optionally with a response resource.

Status code Description Resource
200 OK

OK