Skip to Content
🚀 Welcome to Humansoft Open API Documentation

A Daily In Month

ดึงข้อมูลตารางเวลาทำงานของวันที่ระบุในรอบเดือน แสดงรายละเอียดวันทำงาน พร้อมเวลาเข้า-ออก, เอกสารต่างๆ, และผลการคำนวณ

Endpoint

GET /api/v1/open-apis/salary/get-data-filter?path_action=a_daily_in_month

Request Parameters

ParameterTypeRequiredDescriptionExample
employee_codestringYesรหัสพนักงาน"EMP001"
work_datestringYesวันที่ทำงาน (YYYY-MM-DD)"2026-02-18"
year_monthstringYesรอบเงินเดือน (YYYY-MM)"2026-02"
language_codestringNoภาษา: TH หรือ EN (ค่าเริ่มต้น: TH)"TH"

API นี้ดึงข้อมูลวันทำงานเพียงวันเดียวในรอบเดือน ต่างจาก daily_in_month ที่ดึงทั้งเดือน


Response Format

Success Response

{ "code": 200, "message": "Success", "payload": { "profile": { "employee_id": "20260121FC89F3BB9120", "employee_code": "EMP001", "employee_name": "สมชาย", "employee_last_name": "ใจดี", "employee_nickname": "ชาย", "employee_title_lv": "01", "employee_gender": "M", "salary": "35000.00", "calculate_ot": true, "round_ot_config": "Y", "round_worktime_config": "N" }, "daily": [ { "time_attendance_group_transac_id": "20260218ABC123456789", "work_date": "2026-02-18", "day_status": "วันทำงาน", "work_cycle_code": "WC002", "work_cycle_type_lv": "00", "work_cycle_start_time": "2026-02-18 09:00:00", "work_cycle_end_time": "2026-02-18 18:00:00", "work_cycle_hour": "09:00:00", "break_cycle_start_time": "2026-02-18 12:00:00", "break_cycle_end_time": "2026-02-18 13:00:00", "break_cycle_hour": "01:00:00", "holiday_flag_lv": "00", "work_time_count": "2", "work_sum_time": "08:05:00", "work_total_time": "08:05:00", "work_total_in_cycle": "08:00:00", "late_sum_time": "00:05:00", "late_total": "0.00", "early_sum_time": "00:00:00", "early_total": "0.00", "absence_day": "0.0000", "absence_total": "0.00", "time": [ { "time_attendance_transac_id": "20260218IN123456789", "attendance_datetime": "2026-02-18 09:05:00", "work_type_lv": "01", "time_attendance_type_lv": "Manual" }, { "time_attendance_transac_id": "20260218OUT987654321", "attendance_datetime": "2026-02-18 18:10:00", "work_type_lv": "02", "time_attendance_type_lv": "Manual" } ], "time_leave": [], "work_cycle_change": [], "holiday_change": [], "time_adjust": [], "ot_work": [] } ] } }

Key Response Fields - profile

FieldTypeDescription
employee_codestringรหัสพนักงาน
employee_namestringชื่อพนักงาน
salarystringเงินเดือน (decimal string)
calculate_otbooleanคำนวณ OT หรือไม่
round_ot_configstringConfig รอบ OT: "Y" หรือ "N"
round_worktime_configstringConfig รอบเวลาทำงาน: "Y" หรือ "N"

Key Response Fields - daily[]

FieldTypeDescription
work_datestringวันที่ (YYYY-MM-DD)
day_statusstringสถานะวัน
work_cycle_codestringรหัสกะ
work_cycle_type_lvstringประเภทกะ: "00" (ปกติ), "01" (กำหนดชั่วโมง), "02" (ข้ามวัน), "04" (กะควบ)
work_sum_timestringเวลาทำงานรวม (HH:mm:ss)
work_total_in_cyclestringชั่วโมงที่คำนวณในรอบกะ
late_sum_timestringเวลาสาย (HH:mm:ss)
early_sum_timestringเวลากลับก่อน (HH:mm:ss)
timearrayรายการลงเวลาเข้า-ออก
time_leavearrayรายการเอกสารลา
work_cycle_changearrayรายการเอกสารเปลี่ยนกะ
holiday_changearrayรายการเอกสารเปลี่ยนวันหยุด
time_adjustarrayรายการเอกสารแก้เวลา
ot_workarrayรายการเอกสาร OT

day_status Values

ValueDescription
"วันทำงาน"วันทำงานปกติ
"วันหยุดพนักงาน"วันหยุดของพนักงาน
"วันหยุดบริษัท"วันหยุดของบริษัท
"วันหยุดสาขา"วันหยุดของสาขา
"ยังไม่ได้เริ่มงาน/ลาออกไปแล้ว"พนักงานยังไม่เริ่มงานหรือลาออกไปแล้ว

Error Response

{ "code": 404, "message": "Employee not found with code: 9999", "payload": [] }
HTTP StatusDescription
400พารามิเตอร์ไม่ถูกต้อง เช่น work_date หรือ year_month ผิดรูปแบบ
401API Key ไม่ถูกต้องหรือไม่ได้ส่ง
404ไม่พบพนักงาน หรือไม่พบรอบเดือนที่ระบุ

Code Examples

curl -X GET "https://openapi.humansoft.co.th/api/v1/open-apis/salary/get-data-filter?path_action=a_daily_in_month&employee_code=EMP001&work_date=2026-02-18&year_month=2026-02&language_code=TH" \ -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY"

Notes

  • Response จะมี daily เป็น array ที่มี 1 element เท่านั้น (ข้อมูลวันที่ระบุ)
  • ถ้ากะข้ามวัน (work_cycle_type_lv = '02' หรือ '03') ระบบจะจัดการเอกสารลาให้ถูกต้องโดยอัตโนมัติ
  • ถ้ากะควบ (work_cycle_type_lv = '04') จะมีข้อมูล merge_cycle เพิ่มเติม

  • Daily In Month - ดูตารางเวลาทั้งเดือน
  • Daily Info - ดูรายละเอียดวันทำงาน พร้อม options สำหรับแก้ไข
  • Current Month - ดูรอบเดือนปัจจุบัน เพื่อหา year_month
  • Calculate Month - คำนวณเวลาทำงาน เพื่อให้ได้ผลการคำนวณ
Last updated on