Version: 1.0Base Path: /APITestify/rest/EmployeeModule / Service: APITestifyTag: Employee
/APITestify/rest/Employee
/GetAll
Method: POSTDescription: Retrieve all employee records.
POST
Request: None
Response:Returns an object containing:
Employee[]: List of employees (Employee_DTO)
Employee[]
Employee_DTO
ServerResponse: { Code, ErrorMessage, Validations[] }
ServerResponse
{ Code, ErrorMessage, Validations[] }
Use Case:Used to fetch all employee profiles from the system.
Release Note:Initial implementation for bulk employee retrieval. Supports returning complete employee data, including department and status information.
/GetById
Method: POSTDescription: Retrieve a single employee by ID.
Parameters:
EmployeeId (query, integer, required) — e.g., 1234567891234567
EmployeeId
1234567891234567
Response:
Employee: Employee object (Employee_DTO)
Employee
ServerResponse: Operation result
Use Case:Fetch details for a specific employee record.
Release Note:Enables targeted retrieval of an employee record by unique ID.
/Create
Method: POSTDescription: Create a new employee record.
Body: CreateEmployee_DTO
CreateEmployee_DTO
{ "FullName": "string", "Role": "string", "Email": "string", "Mobile": "string", "OfficeLocation": "string", "HiringDate": "yyyy-MM-dd", "EmployeeCode": "string", "DepartmentId": 1234567891234567, "StatusId": 1234567891234567 }
CreateAPIResponse → NewEmployeeId
CreateAPIResponse
NewEmployeeId
Use Case:Register a new employee in the system.
Release Note:Added endpoint to support creation of employee profiles, including department and status assignment.
/Update
Method: POSTDescription: Update an existing employee’s data.
Body: UpdateEmployee_DTO
UpdateEmployee_DTO
{ "EmployeeId": 1234567891234567, "FullName": "string", "Role": "string", "Email": "string", "Mobile": "string", "OfficeLocation": "string", "HiringDate": "yyyy-MM-dd", "EmployeeCode": "string", "DepartmentId": 1234567891234567, "StatusId": 1234567891234567 }
Use Case:Modify employee information (e.g., promotion, department change).
Release Note:Introduced update functionality to manage employee lifecycle modifications.
/Delete
Method: POSTDescription: Delete an existing employee.
Use Case:Remove an employee record (e.g., after resignation or termination).
Release Note:Added deletion functionality with validation and server-side confirmation.
/GetLookups
Method: GETDescription: Retrieve lookup data for departments and statuses.
GET
Response:Lookups →
Lookups
Departments[]: List of Department_DTO → { Id, Name, Code }
Departments[]
Department_DTO
{ Id, Name, Code }
Status[]: List of Status_DTO → { Id, Label }
Status[]
Status_DTO
{ Id, Label }
Use Case:Populate dropdowns or reference lists in UI forms.
Release Note:Added lookup endpoint to provide static reference data for departments and statuses.
{ "Code": "200", "ErrorMessage": "", "Validations": [ { "FieldName": "string", "Validation": "string" } ] }
✅ Implemented full CRUD for Employee entity✅ Introduced reusable DTOs for create, update, and retrieval✅ Added consistent ServerResponse format✅ Added lookup endpoint for departments and statuses