Get Attendance

Requires authentication

HTTP Request

GET connector/api/get-attendance/{user_id}

URL Parameters

Parameter Status Description
user_id required id of the user

Example request:

curl -X GET \
-G "http://erp.dstadvertising.com/connector/api/get-attendance/1" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-H "Authorization: Bearer {token}"

Example response (200):

{
"data": {
"id": 4,
"user_id": 1,
"business_id": 1,
"clock_in_time": "2020-09-12 13:13:00",
"clock_out_time": "2020-09-12 13:15:00",
"essentials_shift_id": 3,
"ip_address": null,
"clock_in_note": "test clock in from api",
"clock_out_note": "test clock out from api",
"created_at": "2020-09-12 13:14:39",
"updated_at": "2020-09-12 13:15:39"
} }

javascript

const url = new URL(
"http://erp.dstadvertising.com/connector/api/get-attendance/1"
);
let headers = {
"Content-Type": "application/json",
"Accept": "application/json",
"Authorization": "Bearer {token}",
};
fetch(url, {
method: "GET",
headers: headers,
})
.then(response => response.json())
.then(json => console.log(json));