POST api/employee/UpdateCurrentStatus

Update employee's status (e.g online, offline)

Request Information

URI Parameters

None.

Body Parameters

UpdateCurrentStatusBinder
NameDescriptionTypeAdditional information
PersonId

integer

None.

IfOnline

0: Away, 1: On line

boolean

None.

Request Formats

application/json, text/json

Sample:
{
  "PersonId": 1,
  "IfOnline": true
}

application/xml, text/xml

Sample:
<UpdateCurrentStatusBinder xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TechExcel.DTKService.Model.Binding">
  <IfOnline>true</IfOnline>
  <PersonId>1</PersonId>
</UpdateCurrentStatusBinder>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

Update employee's status (e.g online, offline)

API_Data_EmployeeWorkStatus
NameDescriptionTypeAdditional information
Success

boolean

None.

Error

ErrorInfo

None.

Data

EmployeeWorkStatus

None.

Response Formats

application/json, text/json

Sample:
{
  "Success": true,
  "Error": {
    "ErrorCode": 1,
    "ErrorMessage": "sample string 1"
  },
  "Data": {
    "ClockOn": {
      "When": "2024-07-14 04:41:44",
      "IsModified": true,
      "LastModifiedBy": 3,
      "IsAutoGenerated": false
    },
    "ClockOff": {
      "When": "2024-07-14 04:41:44",
      "IsModified": true,
      "LastModifiedBy": 3,
      "IsAutoGenerated": false
    },
    "CurrentTime": "2024-07-14 04:41:44",
    "CurrentStatus": 3
  }
}

application/xml, text/xml

Sample:
<API_Data_EmployeeWorkStatus xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TechExcel.DTKService.Model.Common">
  <Data xmlns:d2p1="http://schemas.datacontract.org/2004/07/TechExcel.DTKService.Model.Entities">
    <d2p1:ClockOff xmlns:d3p1="http://schemas.datacontract.org/2004/07/TechExcel.DTKService.Model.Binding">
      <d3p1:IsModified>true</d3p1:IsModified>
      <d3p1:LastModifiedBy>3</d3p1:LastModifiedBy>
      <d3p1:When>2024-07-14T09:41:44.4412092-07:00</d3p1:When>
    </d2p1:ClockOff>
    <d2p1:ClockOn xmlns:d3p1="http://schemas.datacontract.org/2004/07/TechExcel.DTKService.Model.Binding">
      <d3p1:IsModified>true</d3p1:IsModified>
      <d3p1:LastModifiedBy>3</d3p1:LastModifiedBy>
      <d3p1:When>2024-07-14T09:41:44.4412092-07:00</d3p1:When>
    </d2p1:ClockOn>
    <d2p1:CurrentStatus>3</d2p1:CurrentStatus>
    <d2p1:CurrentTime>2024-07-14T09:41:44.4412092-07:00</d2p1:CurrentTime>
    <d2p1:IfOnline>2</d2p1:IfOnline>
  </Data>
  <Error>
    <ErrorCode>1</ErrorCode>
    <ErrorMessage>sample string 1</ErrorMessage>
  </Error>
  <Success>true</Success>
</API_Data_EmployeeWorkStatus>