To retrieve details for a specific worker. To retrieve worker details, users would need to pass account and business unit reference to the base URL, along with the worker reference.
To add a PAYE worker using the public API you must pass the account reference and business unit reference to the Base URL with the required objects in the body. Refer to Appendix A containing a sample of the request body.
Property
Validations
Account
Cannot be Null
Cannot be left blank
Business Unit
Cannot be Null
Cannot be left blank
The dependencies and validations are:
Property
Acceptable Format
Validations
Refrence
String
Cannot be null
Can be blank and the system will automatically generate a reference from the worker if reference settings is not set as manual
Title
String
Cannot be Null
You must provide a Title for the worker
If contains Invalid Characters
Title must only contain Alpha Numeric characters
If contains Insufficient Characters
Title must be between 2 and 14 characters only
Surname
String
You must provide a worker surname
Must not contain Insufficient Characters
Worker Surname must be between 2 and 26 characters only
Must not contain Invalid Characters
Forename
String
You must provide a worker surname
Must not contain Insufficient Characters
Worker Forename must be between 2 and 26 characters only
Must not contain Invalid Characters
EngagementType
String
Cannot be Null
Cannot be Blank
Accepted value - Paye
DateOfBirth
Date Time
Cannot be Null
You must enter a worker DOB
Underage
Age must be greater than 16
Overage
Age must be less than 100
Acceptable format: 1986-04-21T00:00:00
StartDate
Date Time
Cannot be Null
You must enter a Start Date
Invalid Start Date
Start Date cannot be after the Leave Date
Acceptable format: 2020-01-28T00:00:00
LeaverReason
String
Can be Null
Cannot be blank
You must provide a reason for leaving when specifying Leave Date
If starterForm = “startingdeclaration” then employeeStatement needs to be either "A", "B", “C”, “Unknown”
EmployeeStatement will default to "Starter Form" if not provided in the API request
EmployeeStatement
If starterForm = “startingdeclaration” then employeeStatement needs to be either "A", "B", “C”, “Unknown”
This is Optional
EmployeeStatement will default to "Statement Unknown" if not provided in the API request
TaxCode
Can be null
Can be blank (where not null)
This is Optional
If invalid tax code value is provided then the following validation will appear
Invalid Tax Code provided - Please check the tax code provided is in a valid format
Accepted format: “1257L”
Tax Code will default to the tax code as per the EmployeeStatement
IsWeek1
Can be null
Cannot be left blank (where not null)
This is Optional
If provided, value must be "True" or "False"
IsWeek1 will default to the value as per the EmployeeStatement
P45LeavingDate
Can be null
Cannot be left blank (where not null)
This is Optional
This is required only if StarterForm = P45
Accepted format = Date&Time e.g. 2020-12-06T00:00:00
P45Frequency
Can be null
Cannot be left blank (where not null)
This is Optional
This is required only if StarterForm = P45
Accepted values = "Week" or "Month" based on the payroll frequency
P45Period
Can be null
Cannot be left blank (where not null)
This is Optional
This is required only if StarterForm = P45
Accepted values integer (valid week or month number)
P45YtdGross
Can be null
Cannot be left blank
Can be 0
This is Optional
P45YtdTaxx
Can be null
Cannot be left blank
Can be 0
This is Optional
P45FiguresValid
Can be null
Can be left blank
This is Optional
If provided, value must be "True" or "False"
normalWorkingHours
Can be null
Cannot be left blank (where not null)
This is Optional
If provided, accepted values = A/B/C/D/E
IrregularEmployment
Can be null
Cannot be left blank (where not null)
This is Optional
If provided, value must be "True" or "False"
RTINumber
Can be null
Cannot be left blank (where not null)
This is Optional
If provided, value must be "True" or "False"
Apprentice
Can be null
Cannot be left blank (where not null)
This is Optional
If provided, value must be "True" or "False"
DirectorNi
Can be null
Cannot be left blank (where not null)
This is Optional
If provided, value must be "True" or "False"
DirectorNiMethod
Can be null
Cannot be left blank (where not null)
This is Optional
If provided, value must be "IrregularPayments" or "AlternatePayments"
P45ValidationBypass
Can be null
Cannot be left blank (where not null)
This is Optional
If provided, value must be "True" or "False"
Address
String
Can be null
If the address record doesn’t exist in the body, then will return 200 but record will display as failed validation error in the webapp
You must enter the Address Line 1
Address Line 1 must be between 1 and 35 characters
You must enter a postcode
Postcode - incorrect format
Worker has missing address detail. Please ensure at least 2 lines of the address are populated.
InternationalAddress
String
Can be true or false
If InternationalAddress = true
Mandatory values:
address1
address2
Country
Note: If Country = GB and InternationalAddress = true, then the supplied worker linked to the supplier record will be marked as validation error “Cannot set International Address when Country is UK for the supplier xx”.
Country can be provided using either the country code e.g. UK or the name e.g. United Kingdom
If InternationalAddress = false
Mandatory values:
address1 and
address2 or
address3 or
Town or
County
Postcode
InternationalAddress can be true or false
BankAccount
String
Can be null
If the bank details record doesn’t exist in the body, then will return 200 but record will display as failed validation error
Valid Account Name is required
Account Number must be 8 digits long
Sort Code must be 6 digits long
If the key paymentMethod = “cheque” then bank details are not required can be left blank otherwise you will receive the following validation: You must provide a valid Payment method.
InternationalBankAccount
String
When InternationalBankAccount = true
Mandatory values
AccountName
IBAN
BIC
Optional values:
BankReference
BankName
All other fields are ignored regardless of entry.
When InternationalBankAccount = false
Mandatory values:
AccountName
SortCode
AccountNumber
Optional values:
BankReference
BankName
InternationalBankAccount details can only be provided when BACS is set as "NatWest Bankline International"
PensionSchemeMember
String
Can be null
If the pensionSchemeMember record not provided, system will use the default pension scheme set in the configuration
schemeReference can be null
In the event, the provided pension scheme reference does not exist, the system assigns the default pension scheme set under account configuration
IsWeek1
String
Cannot be null
Can be true or false
If isWeek1 = true then P45LeavingDate, P45Frequency, P45Period, P45YtdGross and P45YtdTax are not required
Apprentice
String
Cannot be null
Can be true or false
If apprentice = true then NI Letter must be H otherwise will create the record and fail validation
To update a PAYE worker using the public API you need to pass the account and business unit reference to the Base URL with the required objects in the body. Refer to Appendix B containing a sample of the request body.
To add a contractor worker using the public API you need to pass the account and business unit reference to the URL with the required objects in the body. Refer to Appendix C containing a sample of the request body.
The key dependencies are: -
Users can add PayrollDataUK for contractors to add them as IR35
To update a contractor worker using the public API you need to pass the account and business unit reference to the Base URL with the required objects in the body. Refer to Appendix D containing a sample of the request body.
Most of the key dependencies and validations are the same as the Worker ADD as described in previous sections.
To add an Agency or Umbrella worker record using the public API you need to pass the account and business unit reference to the BASE URL with the required objects in the body. Refer to Appendix G containing a sample of the request body.
Note: A worker record can be created with or without contact and address objects
To update an Agency or Umbrella worker record using the public API you need to pass the account and business unit reference to the BASE URL with the required objects in the body. Refer to Appendix H containing a sample of the request body.
A worker record can be updated with or without contact and address objects
To search a worker using a specific search term. This parameter can also be used as a "Global Search" to search for the term across all accounts and business units (user has access to)
To enable payment after leaving for a left worker, users would need to pass the account and business unit reference to the base URL, along with the worker reference.
For further information on worker transfers, please refer to our Payment After Leaving guide.
The contents of this document, along with any associated documents, are the property of PurePro Solutions Ltd. and are shared in strict confidence with the intended recipient. These materials may not be reproduced, shared, or used in any manner without prior written consent from PurePro Solutions Ltd. Unauthorized use or distribution is prohibited.