Info

Created 11-03-2020 by Lavinia Gheghea

Revision



Description

The API allows you to get time ledger analyses

Endpoints


GET:  /timeledgeranalyses


Parameters
Headers and Query
 Name
 Description
 Type
 API-key - required
 Authorization Token
 String(64)
 UID - required
 UID -how can be obtained
 String
 DEVICEID - required
 DEVICEID
 String
 offset
 starting record
 Integer
 limit
 how many records displayed on a page
 Integer
 OrderFieldName
 field name to order the recordset
 String
 OrderDirection
 ASC or DESC
 String
 Filter
 filter the recordset
 String
 dtStartDate
 Start Date
 String
 dtEndDate End Date String

Curl example

curl -X GET "https://smartapi.smarttid.dk/timeledgeranalyses?dtStartDate=yyyy-mm-dd&dtEndDate=yyyy-mm-dd" -H "accept: */*" -H "UID: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" -H "DEVICEID:demo@smarttid.dk" -H "API-Key: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

Response

200 (OK) :  array of time ledger

Response body
{ "EmployeeCode": "1000", "Name": "Poul Christensen", "Date": "20-05-2018", "StartTime": "08:00", "EndTime": "17:00", "TotalTime": 8.5, "LogStart": "2019-05-20T08:01:00", "LogEnd": "2019-05-20T16:02:00", "WorkTypeCode": "NORMAL", "BreakTime": "1900-01-01T00:30:00", "Transfered": false, "WorkCalendarCode": "DAG1", "Type": "Normal", "Remark": "", "DepartmentCode": "DENMARK", "WorkFunctionCode": "", "DistrictCode": "JYL", "Week": 21, "Month": 5, "Year": 2018, "MonthName": "2018-05 May", "Relative": false, "EmployeeGroupCode": "", "SystemID": "SMARTTID\\pc", "DimensionCode1": "BMW", "DimensionCode2": "37", "DimensionCode3": "", "DimensionCode4": "", "DimensionCode5": "", "DimensionCode6": "", "DimensionCode7": "", "DimensionCode8": null, "DimensionCode9": null, "DimensionCode10": null, "KMStart": null, "KMEnd": null, "KMTotal": null, "ProfileCode": "TIME", "Registrations": 1, "JournalCode": "TIME", "Day": "Sun", "EmployeeDepartmentCode": "DENMARK", "EmployeeDistrictCode": "JYL", "BreakTimeFloat": 0.5 }, { "EmployeeCode": "1000", "Name": "Poul Christensen", "Date": "20-05-2018", "StartTime": "08:00", "EndTime": "17:00", "TotalTime": 8.5, "LogStart": "2019-05-20T08:01:00", "LogEnd": "2019-05-20T16:02:00", "WorkTypeCode": "NORMAL", "BreakTime": "1900-01-01T00:30:00", "Transfered": false, "WorkCalendarCode": "DAG1", "Type": "Normal", "Remark": "", "DepartmentCode": "DENMARK", "WorkFunctionCode": "", "DistrictCode": "JYL", "Week": 21, "Month": 5, "Year": 2018, "MonthName": "2018-05 May", "Relative": false, "EmployeeGroupCode": "", "SystemID": "SMARTTID\\pc", "DimensionCode1": "BMW", "DimensionCode2": "37", "DimensionCode3": "", "DimensionCode4": "", "DimensionCode5": "", "DimensionCode6": "", "DimensionCode7": "", "DimensionCode8": null, "DimensionCode9": null, "DimensionCode10": null, "KMStart": null, "KMEnd": null, "KMTotal": null, "ProfileCode": "TIME", "Registrations": 1, "JournalCode": "TIME", "Day": "Sun", "EmployeeDepartmentCode": "DENMARK", "EmployeeDistrictCode": "JYL", "BreakTimeFloat": 0.5 }, ]



Response headers:
content-encoding: gzip 
 content-length: 238 
 content-type: application/json; charset=utf-8 
 date: Mon, 24 Aug 2020 08:01:23 GMT 
 server: Microsoft-IIS/10.0 
 vary: Accept-Encoding 
 x-pagination: {"totalCount":4,"totalFiltered":4,"Offset":0,"Limit":4,"Returned":4} 
 x-powered-by: ASP.NET 

400 (ERROR) : Error message

Response Body
Error message