Skip to Content
🚀 Welcome to Humansoft Open API Documentation

Get Employee Data Filter

Endpoint สำหรับดึงข้อมูลพนักงานแบบแยกเรื่อง รองรับการดึงข้อมูลทั้ง Setting, Profile และ Financial โดยสามารถกรองตามประเภทที่ต้องการได้

API นี้ใช้ Router Pattern - ระบุ path_action เพื่อเลือกประเภทข้อมูลที่ต้องการดึง

พารามิเตอร์ที่ลงท้ายด้วย _id ต้องส่งเป็น Base64-encoded ของ raw internal ID

  • Response จะ return raw string ID (เช่น 20260121FC89F3BB9120)
  • เมื่อนำ ID จาก response ไปใช้ใน request ถัดไป ต้อง encode เป็น Base64 ก่อน

Endpoint

GET /api/v1/open-apis/employee/get-employee-data-filter

Query Parameters

ParameterTypeRequiredDescription
path_actionstringYesประเภทข้อมูลที่ต้องการดึง
employee_codestringConditionalรหัสพนักงาน (สำหรับ list actions)

Available Actions

Setting Actions

ใช้ employee_code เป็น parameter

path_actionDescription
get-otดึงการตั้งค่า OT
get-quotaดึงโควตาการลา
get-holidayดึงวันหยุดประจำสัปดาห์
get-work-cycleดึงกะการทำงาน
get-time-frameดึงป้ายช่วงเวลา
get-role-dutyดึงหน้าที่ปฏิบัติงาน
get-cost-centerดึงศูนย์ต้นทุน
get-worktime-configดึงการตั้งค่าเวลาทำงาน
get-userดึงข้อมูลผู้ใช้
list-facialดึงรายการใบหน้า

Profile List Actions

ใช้ employee_code เป็น parameter

path_actionDescription
list-familyดึงรายการครอบครัว
list-workดึงรายการประวัติการทำงาน
list-educationดึงรายการประวัติการศึกษา
list-abilityดึงรายการความสามารถพิเศษ
list-language-skillดึงรายการทักษะภาษา
list-typing-skillดึงรายการทักษะพิมพ์ดีด
list-driving-skillดึงรายการทักษะการขับขี่
list-trainingดึงรายการประวัติการฝึกอบรม
list-possessดึงรายการทรัพย์สินครอบครอง
list-hospitalดึงรายการโรงพยาบาล
list-documentดึงรายการเอกสาร
list-logดึงประวัติการแก้ไขข้อมูล

Profile Get Actions (by ID)

ใช้ ID เฉพาะของแต่ละประเภท

path_actionDescriptionRequired ID
get-familyดึงข้อมูลครอบครัวemployee_family_id
get-workดึงประวัติการทำงานemployee_work_id
get-educationดึงประวัติการศึกษาemployee_education_id
get-abilityดึงความสามารถพิเศษemployee_ability_id
get-language-skillดึงทักษะภาษาemployee_language_skill_id
get-typing-skillดึงทักษะพิมพ์ดีดemployee_typing_skill_id
get-driving-skillดึงทักษะการขับขี่employee_driving_skill_id
get-trainingดึงประวัติการฝึกอบรมemployee_training_id
get-possessดึงทรัพย์สินครอบครองemployee_possess_id
get-hospitalดึงโรงพยาบาลemployee_hospital_id
get-documentดึงเอกสารemployee_documents_id

Financial Actions

path_actionDescriptionRequired Params
list-constantดึงรายการค่าคงที่employee_code
get-constantดึงค่าคงที่employee_constant_id
list-fundดึงรายการกองทุนemployee_code
get-fundดึงกองทุนfund_employee_id
list-welfareดึงรายการสวัสดิการemployee_code, welfare_year
get-welfareดึงสวัสดิการwelfare_employee_id
list-salary-auto-checkedดึงรายการเงินเดือนอัตโนมัติemployee_code
get-salary-auto-checkedดึงเงินเดือนอัตโนมัติemployee_auto_checked_id
list-work-insuranceดึงรายการประกันสังคมemployee_code
get-work-insuranceดึงประกันสังคมwork_insurance_log_id

Pagination (for list-log)

ParameterTypeDefaultDescription
year_monthstring0000-00ปี-เดือน (YYYY-MM)
_PAGEinteger1หน้าที่ต้องการแสดง
_NUMBER_PER_PAGEinteger50จำนวนรายการต่อหน้า

Response Format

List Actions Response

{ "code": 200, "message": "สำเร็จ", "payload": [ { "employee_family_id": "20260121PS01B2C3D4E5", "family_name": "สมชาย", ... }, { "employee_family_id": "20260121PS02B2C3D4E5", "family_name": "สมหญิง", ... } ] }

Get Actions Response

{ "code": 200, "message": "สำเร็จ", "payload": { "employee_family_id": "20260121PS01B2C3D4E5", "family_name": "สมชาย", "family_last_name": "ใจดี", ... } }

Error Response

{ "code": 400, "message": "ไม่สำเร็จ", "errors": ["กรุณาระบุ 'employee_code'"] }

Code Examples

# ดึงรายการครอบครัว curl -X GET "https://openapi.humansoft.co.th/api/v1/open-apis/employee/get-employee-data-filter?path_action=list-family&employee_code=EMP001" \ -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" # ดึงการตั้งค่า OT curl -X GET "https://openapi.humansoft.co.th/api/v1/open-apis/employee/get-employee-data-filter?path_action=get-ot&employee_code=EMP001" \ -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" # ดึงข้อมูลครอบครัวรายตัว curl -X GET "https://openapi.humansoft.co.th/api/v1/open-apis/employee/get-employee-data-filter?path_action=get-family&employee_family_id=MjAyNjAxMjFGTTAxQTJCM0M0RDU=" \ -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" # ดึงประวัติการแก้ไข (with pagination) curl -X GET "https://openapi.humansoft.co.th/api/v1/open-apis/employee/get-employee-data-filter?path_action=list-log&employee_code=EMP001&year_month=2026-01&_PAGE=1&_NUMBER_PER_PAGE=20" \ -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY"

Difference from Get Employee Data

FeatureGet Employee DataGet Employee Data Filter
Parametertype (all/setting/profile/financial)path_action (specific action)
Responseข้อมูลทั้งหมดตาม typeข้อมูลเฉพาะเรื่อง
Use Caseดึงข้อมูลรวมดึงข้อมูลเฉพาะรายการ

  • Get Employee Data - ดึงข้อมูลตาม type (all/setting/profile/financial)
  • Get Employee Info - ดึงข้อมูลครบถ้วนโดยใช้ employee_code
  • Get Employee List - ดึงรายการพนักงาน
Last updated on