TM Employee Api V1

Limits

Please read the API Usage Notice before implementing API consumption. This api will by default get 25 employees and have a max of 100, to change this or do paging please read the section about common parameters for RESTFul apis

URL Format

All the Web Service methods use a common convention in their URLs. The URLs consist of parts for customer alias, API key and method name. E.g.:

https://manager-api.hr-manager.net/restful.svc/{CUSTOMER-ALIAS}/{API-KEY}/Employees/

When calling an API method, simply replace these parts with proper values.

Note that, to get the contents Details, you must use the empid parameter.


Items

The node for items include the list of position data objects.

{
	"Id": 100,
	"FirstName": "",
	"LastName": "",
	"Email": "john.doe@hrmts.cool",
	"Birthdate": "/Date(1524816000000)/",
	"Gender": 1,
	"DepartmentId": 100,
	"DepartmentName": "",
	"EmploymentDatetime": "/Date(1524816000000)/",
        // ResignationDate:
        // Should not be used. Will be deprecated soon. (01.05.2021) 
        // 'Lastworkingdate' should be used instead
        // (24.02.2021)	"ResignationDatetime": "/Date(1524816000000)/",

	"LastUpdated": "/Date(1524816000000)/",
	"Details": {
		"SecondLastName": "",
		"ProfileImage": link,
		"SecondEmail": "",
		"Superior": "",
		"SuperiorId": 100,
		"MaritalStatus": "",
		"AnniversaryDate": "/Date(1524816000000)/",
		"Nationality": "",
		"Address": "",
		"Address2": "",
		"POBox": "",
		"SSN": "",
		"EmploymentId": "",
		"Zip": "",
		"City": "",
		"Country": "",
		"PhonePrivate": "",
		"PhoneMobile": "",
		"PhoneWork": "",
		"PhoneFax": "",
		"WebSite": "",
		"WorkHours": 0,
// WorkHours defaults to 0 and will be removed in next version //
		"WorkLocation": "",
		"WorkPercentage": "",
// WorkPercentage defaults to 0 and will be removed in next version //
		"AvailabilityDate": "/Date(1524816000000)/",
		"BankAccountNumber": "",
		"StaffCategory": "",
		"CostCenter": "",
		"JobTitle": "",
		"JobType": "",
		"NoticeTime": "",
		"ProbationPeriod": {
			"Id": 1,
			"Name": "0 Month(s)"
		},
		"EducationArea": "",
		"PreferredLanguage": "",
		"RelativeInfo1Name": "",
		"RelativeInfo1Phone": "",
		"RelativeInfo1Email": "",
		"RelativeInfo1Relation": "",
		"RelativeInfo2Name": "",
		"RelativeInfo2Phone": "",
		"RelativeInfo2Email": "",
		"RelativeInfo2Relation": "",
		"Rank": "",
		"LastLoginDateTimeUtc": "/Date(1524816000000)/",
		"CreatedDateTimeUtc": "/Date(1524816000000)/",
		"SeniorityDate": "/Date(1524816000000)/",
		"ReasonForLeavingId": -1,
		"FTE": 0.1,
		"BankRegistrationNumber": "",
		"LastWorkingDate": "/Date(1524816000000)/",
		"EmploymentEndDate": "/Date(1524816000000)/",
		"Salary": "",
		"Tags": [],
		"DocumentList": null,
		"ActivityLogs": [],
		"CommunicationLog": [],
		"EmployeeHistory": {
			"EmployeeWorkHistory": [],
			"EmployeeLeaveHistory": [],
			"EmployeeSalaryHistory": []
		},
		"Notes": [],
		"Course": [],
		"Certificates": [],
		"KeyQuestionnaire": {
			"ModuleType": 0,
			"Id": 100,
			"Title": "",
			"QuestionList": null,
			"AverageScore": 0,
			"RawXml": 
				<XML>
					<QuestionCollection>
						<Name/>
						<Description>
							<LocalizedText/>
						</Description>
						<QuestionGroupList>
							<QuestionGroup id="100">
								<Name>
									<LocalizedText/>
								</Name>
								<QuestionList>
									<QuestionBase Id="100">
										<Text>
											<LocalizedText/>
										</Text>
										<AnswerGroupList>
											<AnswerGroup ID="100">
												<Name>
													<LocalizedText/>
												</Name>
												<AnswerOptionList>
													<AnswerOption Id="100">
														<Name>
															<LocalizedText/>
														</Name>
													</AnswerOption>
												</AnswerOptionList>	
												<UserAnswers>
													<UserAnswer id="100" RowID="100">
														<CustomAnswer/>
														<DateTimeAnswer/>
														<UserOptionList>
															<UserAnswerOption Id="100">
																<UserAnswerId>100</UserAnswerId>
																<AnswerOptionId>100</AnswerOptionId>
															</UserAnswerOption>
														</UserOptionList>
													</UserAnswer>
												</UserAnswers>
											</AnswerGroup>
										</AnswerGroupList>
									</QuestionBase>
								</QuestionList>
							</QuestionGroup>
						</QuestionGroupList>			
					</QuestionCollection>	
				</XML>		
	},
		"CvQuestionnaire": null,
		"AppraisalQuestionnaire": null,
		"DevelopmentPlanQuestionnaire": null,
		"CompetencyQuestionnaire": null,
		"TalentReviewQuestionnaire": null
	}
}


Item: Employee.Workhistory:

<EmployeeSalaryHistory>
    <Id>4</Id>
    <FromDate>2019-05-03T00:00:00</FromDate>
    <ToDate>2019-05-10T00:00:00</ToDate>
    <Position>
        <Id>12729</Id>
        <Name>DBA</Name>
    </Position>
    <Salary>4344</Salary>
    <PercentageIncrease>3</PercentageIncrease>
    <Comments>test</Comments>
    <CreatedByUserId>20</CreatedByUserId>
    <CreatedDateTimeUtc>2019-05-13T07:19:22Z</CreatedDateTimeUtc>
</EmployeeSalaryHistory>


Item: Employee.EmployeeLeaveHistory:

    <EmployeeLeaveHistory>
        <Id>18</Id>
        <FromDate>2020-08-28T00:00:00</FromDate>
        <ToDate>2025-07-21T00:00:00</ToDate>
            <LeaveType>
                <Id>1234</Id>
                <Name>Leave due to XyZ</Name>
            </LeaveType>
        <Comments/>
        <CreatedByUserId>789</CreatedByUserId>
        <CreatedDateTimeUtc>2020-08-03T04:47:00Z</CreatedDateTimeUtc>
    </EmployeeLeaveHistory>


Item: Employee.EmployeeSalaryHistory:

<EmployeeSalaryHistory>
    <Id>27</Id>
    <FromDate>2020-01-01T00:00:00</FromDate>
    <ToDate>0001-01-01T00:00:00</ToDate>
    <Position>
        <Id>18879</Id>
        <Name>IT Support Technician</Name>
    </Position>
    <Salary>22000</Salary>
    <PercentageIncrease>0</PercentageIncrease>
    <Comments/>
    <CreatedByUserId>43727</CreatedByUserId>
    <CreatedDateTimeUtc>2020-01-08T09:36:47Z</CreatedDateTimeUtc>
</EmployeeSalaryHistory>




Employees Query String Parameters

Following are the query string parameters dedicated for employees


Employee Id

Parameterempid
DescriptionSend this parameter to filter the list with a single employee. Retrieving a single employee returns full details of the employee.
Value typeInteger
Default valueNone
Sample…/?empid=1
Parametersearch
Description

Send this parameter to filter the list searching the following fields:

-FirstName

-LastName

-SecondLastName

-Email

-SecondEmail

-Address

-Address2

-City

-Country

Value typeText
Default valueNone
Sample

.../?search=lastname

.../?search=myemail@domain.com

Gender

Parametergender
Description

Send this parameter to filter the list with employees’ gender. The valid values are M for males and F for females. Skip this parameter to list both males and females.

Value typeText
Default valueNone
Sample

.../?gender=F

.../?gender=M

IgnoreCertificatesDocumentBytes

ParameterIgnoreCertificatesDocumentBytes
Description

Send this parameter to exclude the property-value for the property 'Certificates.DocumentList.Document.Bytes' .
The valid values are 'true' for excluding and 'false' for including. By not specifying this parameter, or setting the parameter to 'false',  the property will be populated with data, which can yield large responses

Value typeBoolean
Default valuefalse
Sample

.../?ignoreCertificatesDocumentBytes=true

.../?ignoreCertificatesDocumentBytes=false

Updatedsince

Parameterupdatedsince
Description

Send this parameter to filter the list of employees, and only retrieve information about employees which have been updated after a given date.
The valid value must be a valid date in the format: 'YYYY-MM-DD%20HH:MM:SS'
Not specifying this parameter will retrieve all employees

Value typeFormatted-Date ('YYYY-MM-DD%20HH:MM:SS')
Default valuenull
Sample

.../?updatedsince=2019-06-20%2001:01:01

UICulture

ParameterUICulture
Description

Send this parameter to include text from drop-down lists on that language. Default is "en" or English and all other translations will be omitted.
The valid values are the shortend version of any language in the system. Most common are 'da', 'en', 'sv' and  'no' for Danish, English, Swedish and Norwegian. By not specifying this parameter,  the property will be defaulted to only include text in the English translations of the dropdown menus.

Value typeText
Default valueen
Sample

.../?UICulture=sv

.../?UICulture=da

IncFormerEmpSince

ParameterIncludeFormerEmployeesSince
Description

Send this parameter to include employees which have left the company.
It will append employees who has a "Employment End date" value equal og greater than the specified value

Value typeFormatted-Date ('YYYY-MM-DD')
Default valueNone
Sample

.../?incFormerEmpSince=2020-12-24

tpdepid

Parameter

tpdepid

Description

Filter på thirdparty-departmentid's

Value typeComma separated list of strings
Default value
Sample

.../?tpdepid=d1,d2,d3