{"id":4778,"date":"2026-10-12T17:08:10","date_gmt":"2026-10-12T14:08:10","guid":{"rendered":"https:\/\/modulus.help\/kb\/docs\/documentation\/personnel-apis-v1\/api-list-attendance-logs\/"},"modified":"2026-10-12T18:23:38","modified_gmt":"2026-10-12T15:23:38","slug":"api-list-employees","status":"publish","type":"docs","link":"https:\/\/modulus.help\/kb\/docs\/documentation\/personnel-apis-v1\/api-list-employees\/","title":{"rendered":"API: List Employees"},"content":{"rendered":"<p>The purpose of this API is to retrieve a paginated list of employees, with optional filters and additional personal and employment information. If groups is omitted, only employee_code, full_name, and short_name are returned.<\/p>\n<h4>Request<\/h4>\n<table style=\"width: auto;\">\n<thead>\n<tr>\n<th>Property<\/th>\n<th>Value<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>API Name<\/td>\n<td>Employee<\/td>\n<\/tr>\n<tr>\n<td>URL<\/td>\n<td>https:\/\/your_account.modulus.biz\/api\/hr\/v1\/Employee<\/td>\n<\/tr>\n<tr>\n<td>Method<\/td>\n<td>GET<\/td>\n<\/tr>\n<tr>\n<td>Source<\/td>\n<td>Third Party Server<\/td>\n<\/tr>\n<tr>\n<td>Recipient<\/td>\n<td>modulus\u00ae Server<\/td>\n<\/tr>\n<tr>\n<td>Accept<\/td>\n<td>application\/json<\/td>\n<\/tr>\n<tr>\n<td>Authentication<\/td>\n<td>Bearer token<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Request Headers<\/h4>\n<table style=\"width: auto;\">\n<thead>\n<tr>\n<th>Header<\/th>\n<th>Required<\/th>\n<th>Description<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>Authorization<\/td>\n<td>Yes<\/td>\n<td>Bearer token for authentication. Format: Bearer &lt;token&gt;<\/td>\n<\/tr>\n<tr>\n<td>Accept<\/td>\n<td>Yes<\/td>\n<td>application\/json<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Query String Parameters<\/h4>\n<table style=\"width: auto;\">\n<thead>\n<tr>\n<th>Parameter<\/th>\n<th>Required<\/th>\n<th>Type<\/th>\n<th>Description<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>employee_code<\/td>\n<td>No<\/td>\n<td>String<\/td>\n<td>Filter by employee code.<\/td>\n<\/tr>\n<tr>\n<td>employment_status<\/td>\n<td>No<\/td>\n<td>String<\/td>\n<td>Filter by employment status. Possible values: Working, Terminated, Resigned.<\/td>\n<\/tr>\n<tr>\n<td>location_id<\/td>\n<td>No<\/td>\n<td>Integer<\/td>\n<td>Filter by location ID.<\/td>\n<\/tr>\n<tr>\n<td>position_id<\/td>\n<td>No<\/td>\n<td>Integer<\/td>\n<td>Filter by position ID.<\/td>\n<\/tr>\n<tr>\n<td>department_id<\/td>\n<td>No<\/td>\n<td>Integer<\/td>\n<td>Filter by department ID.<\/td>\n<\/tr>\n<tr>\n<td>direct_head_code<\/td>\n<td>No<\/td>\n<td>String<\/td>\n<td>Filter employees reporting directly to the specified employee code.<\/td>\n<\/tr>\n<tr>\n<td>groups<\/td>\n<td>No<\/td>\n<td>String<\/td>\n<td>Comma-separated information groups: personal_info, employment_info. Omit to return root fields only.<\/td>\n<\/tr>\n<tr>\n<td>page_number<\/td>\n<td>No<\/td>\n<td>Integer<\/td>\n<td>Page number. Default = 1.<\/td>\n<\/tr>\n<tr>\n<td>page_size<\/td>\n<td>No<\/td>\n<td>Integer<\/td>\n<td>Records per page. Default = 50; recommended maximum = 500.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>When multiple employee filters are supplied, they are combined using AND logic. Employee codes are strings; preserve leading zeros.<\/p>\n<h4>Information Groups<\/h4>\n<table style=\"width: auto;\">\n<thead>\n<tr>\n<th>Group<\/th>\n<th>Description<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>personal_info<\/td>\n<td>Gender, date of birth, nationality, religion, marital status, military status, and education.<\/td>\n<\/tr>\n<tr>\n<td>employment_info<\/td>\n<td>Employment status, join date, layoff date, location, position, department, contract type, working days, working hours, attendance scheme, and direct head code.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>Example: groups=personal_info,employment_info. Unrequested groups are omitted completely, rather than returned as null.<\/p>\n<h4>Responses<\/h4>\n<table style=\"width: auto;\">\n<thead>\n<tr>\n<th>HTTP Status<\/th>\n<th>result<\/th>\n<th>title<\/th>\n<th>message<\/th>\n<th>object<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>200 OK<\/td>\n<td>true<\/td>\n<td>Success<\/td>\n<td>Employees listed successfully.<\/td>\n<td>\n<pre>{\n  \"meta_data\": {\n    \"page_count\": 3,\n    \"page_number\": 1,\n    \"page_size\": 50,\n    \"record_count\": 127\n  },\n  \"data\": [\n    {\n      \"employee_code\": \"0001\",\n      \"full_name\": \"Ahmed Mohamed Hassan\",\n      \"short_name\": \"Ahmed Hassan\",\n      \"personal_info\": {\n        \"gender\": \"Male\",\n        \"date_of_birth\": \"1990-05-15\",\n        \"nationality\": \"Egyptian\",\n        \"religion\": \"Muslim\",\n        \"marital_status\": \"Married\",\n        \"military_status\": \"Completed\",\n        \"education\": \"Bachelor of Commerce\"\n      },\n      \"employment_info\": {\n        \"employment_status\": \"Working\",\n        \"join_date\": \"2020-01-15\",\n        \"layoff_date\": null,\n        \"location\": {\n          \"id\": 3,\n          \"name\": \"Cairo HQ\"\n        },\n        \"position\": {\n          \"id\": 17,\n          \"name\": \"Senior Accountant\"\n        },\n        \"department\": {\n          \"id\": 12,\n          \"name\": \"Finance\"\n        },\n        \"contract_type\": {\n          \"id\": 1,\n          \"name\": \"Full Time\"\n        },\n        \"working_days\": 5,\n        \"working_hours\": 40,\n        \"attendance_scheme\": {\n          \"id\": 4,\n          \"name\": \"Standard Office Hours\"\n        },\n        \"direct_head_code\": \"0025\"\n      }\n    }\n  ]\n}<\/pre>\n<\/td>\n<\/tr>\n<tr>\n<td>200 OK (No Matches)<\/td>\n<td>true<\/td>\n<td>Success<\/td>\n<td>No employees found matching your conditions.<\/td>\n<td>\n<pre>{\n  \"meta_data\": {\n    \"page_count\": 0,\n    \"page_number\": 1,\n    \"page_size\": 50,\n    \"record_count\": 0\n  },\n  \"data\": []\n}<\/pre>\n<\/td>\n<\/tr>\n<tr>\n<td>400 Bad Request<\/td>\n<td>false<\/td>\n<td>Invalid Request<\/td>\n<td>Invalid information group: payroll_info.<\/td>\n<td>\n<pre>null<\/pre>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Response Structure<\/h4>\n<table style=\"width: auto;\">\n<thead>\n<tr>\n<th>Field<\/th>\n<th>Type<\/th>\n<th>Description<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>result<\/td>\n<td>Boolean<\/td>\n<td>Indicates whether the request was processed successfully.<\/td>\n<\/tr>\n<tr>\n<td>title<\/td>\n<td>String<\/td>\n<td>Short response title.<\/td>\n<\/tr>\n<tr>\n<td>message<\/td>\n<td>String<\/td>\n<td>Human-readable response message.<\/td>\n<\/tr>\n<tr>\n<td>object<\/td>\n<td>Object \/ null<\/td>\n<td>Response payload containing meta_data and data for successful list requests.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Pagination Metadata<\/h4>\n<table style=\"width: auto;\">\n<thead>\n<tr>\n<th>Field<\/th>\n<th>Type<\/th>\n<th>Description<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>page_count<\/td>\n<td>Integer<\/td>\n<td>Total number of pages.<\/td>\n<\/tr>\n<tr>\n<td>page_number<\/td>\n<td>Integer<\/td>\n<td>Current page number.<\/td>\n<\/tr>\n<tr>\n<td>page_size<\/td>\n<td>Integer<\/td>\n<td>Requested records per page.<\/td>\n<\/tr>\n<tr>\n<td>record_count<\/td>\n<td>Integer<\/td>\n<td>Total records matching supplied filters.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Root Employee Fields<\/h4>\n<table style=\"width: auto;\">\n<thead>\n<tr>\n<th>Field<\/th>\n<th>Type<\/th>\n<th>Nullable<\/th>\n<th>Description<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>employee_code<\/td>\n<td>String<\/td>\n<td>No<\/td>\n<td>Employee code. Always returned. Preserve leading zeros.<\/td>\n<\/tr>\n<tr>\n<td>full_name<\/td>\n<td>String<\/td>\n<td>No<\/td>\n<td>Employee full name. Always returned.<\/td>\n<\/tr>\n<tr>\n<td>short_name<\/td>\n<td>String<\/td>\n<td>Yes<\/td>\n<td>Employee short\/display name. Always returned.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Personal Information Fields<\/h4>\n<table style=\"width: auto;\">\n<thead>\n<tr>\n<th>Field<\/th>\n<th>Type<\/th>\n<th>Nullable<\/th>\n<th>Description<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>gender<\/td>\n<td>String<\/td>\n<td>Yes<\/td>\n<td>Employee gender.<\/td>\n<\/tr>\n<tr>\n<td>date_of_birth<\/td>\n<td>Date<\/td>\n<td>Yes<\/td>\n<td>Date of birth in YYYY-MM-DD format.<\/td>\n<\/tr>\n<tr>\n<td>nationality<\/td>\n<td>String<\/td>\n<td>Yes<\/td>\n<td>Employee nationality.<\/td>\n<\/tr>\n<tr>\n<td>religion<\/td>\n<td>String<\/td>\n<td>Yes<\/td>\n<td>Employee religion.<\/td>\n<\/tr>\n<tr>\n<td>marital_status<\/td>\n<td>String<\/td>\n<td>Yes<\/td>\n<td>Employee marital status.<\/td>\n<\/tr>\n<tr>\n<td>military_status<\/td>\n<td>String<\/td>\n<td>Yes<\/td>\n<td>Employee military service status.<\/td>\n<\/tr>\n<tr>\n<td>education<\/td>\n<td>String<\/td>\n<td>Yes<\/td>\n<td>Employee education information.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Employment Information Fields<\/h4>\n<table style=\"width: auto;\">\n<thead>\n<tr>\n<th>Field<\/th>\n<th>Type<\/th>\n<th>Nullable<\/th>\n<th>Description<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>employment_status<\/td>\n<td>String<\/td>\n<td>No<\/td>\n<td>Current employment status.<\/td>\n<\/tr>\n<tr>\n<td>join_date<\/td>\n<td>Date<\/td>\n<td>Yes<\/td>\n<td>Join date in YYYY-MM-DD format.<\/td>\n<\/tr>\n<tr>\n<td>layoff_date<\/td>\n<td>Date<\/td>\n<td>Yes<\/td>\n<td>Layoff\/termination date in YYYY-MM-DD format.<\/td>\n<\/tr>\n<tr>\n<td>location<\/td>\n<td>Object<\/td>\n<td>Yes<\/td>\n<td>Assigned location as {id, name}.<\/td>\n<\/tr>\n<tr>\n<td>position<\/td>\n<td>Object<\/td>\n<td>Yes<\/td>\n<td>Assigned position as {id, name}.<\/td>\n<\/tr>\n<tr>\n<td>department<\/td>\n<td>Object<\/td>\n<td>Yes<\/td>\n<td>Assigned department as {id, name}.<\/td>\n<\/tr>\n<tr>\n<td>contract_type<\/td>\n<td>Object<\/td>\n<td>Yes<\/td>\n<td>Assigned contract type as {id, name}.<\/td>\n<\/tr>\n<tr>\n<td>working_days<\/td>\n<td>Number<\/td>\n<td>Yes<\/td>\n<td>Configured working days.<\/td>\n<\/tr>\n<tr>\n<td>working_hours<\/td>\n<td>Number<\/td>\n<td>Yes<\/td>\n<td>Configured working hours.<\/td>\n<\/tr>\n<tr>\n<td>attendance_scheme<\/td>\n<td>Object<\/td>\n<td>Yes<\/td>\n<td>Attendance scheme as {id, name}.<\/td>\n<\/tr>\n<tr>\n<td>direct_head_code<\/td>\n<td>String<\/td>\n<td>Yes<\/td>\n<td>Employee code of direct head\/supervisor.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Reference Objects<\/h4>\n<p>The location, position, department, contract_type, and attendance_scheme fields use reference objects with an integer id and string name. Unassigned references are returned as null.<\/p>\n<pre>{\n  \"id\": 12,\n  \"name\": \"Finance\"\n}<\/pre>\n<h4>Example 1 &#8211; Root Information Only<\/h4>\n<table style=\"width: auto;\">\n<tbody>\n<tr>\n<th style=\"text-align: left;\">Request<\/th>\n<td>\n<pre>curl --request GET 'https:\/\/your_account.modulus.biz\/api\/hr\/v1\/Employee?page_number=1&amp;page_size=50' \\\n--header 'Accept: application\/json' \\\n--header 'Authorization: Bearer &lt;token&gt;'<\/pre>\n<\/td>\n<\/tr>\n<tr>\n<th style=\"text-align: left;\">200 OK<\/th>\n<td>\n<pre>{\n  \"result\": true,\n  \"title\": \"Success\",\n  \"message\": \"Employees listed successfully.\",\n  \"object\": {\n    \"meta_data\": {\n      \"page_count\": 1,\n      \"page_number\": 1,\n      \"page_size\": 50,\n      \"record_count\": 1\n    },\n    \"data\": [\n      {\n        \"employee_code\": \"0001\",\n        \"full_name\": \"Ahmed Mohamed Hassan\",\n        \"short_name\": \"Ahmed Hassan\"\n      }\n    ]\n  }\n}<\/pre>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Example 2 &#8211; Personal and Employment Information<\/h4>\n<table style=\"width: auto;\">\n<tbody>\n<tr>\n<th style=\"text-align: left;\">Request<\/th>\n<td>\n<pre>curl --request GET 'https:\/\/your_account.modulus.biz\/api\/hr\/v1\/Employee?groups=personal_info,employment_info&amp;page_number=1&amp;page_size=50' \\\n--header 'Accept: application\/json' \\\n--header 'Authorization: Bearer &lt;token&gt;'<\/pre>\n<\/td>\n<\/tr>\n<tr>\n<th style=\"text-align: left;\">200 OK<\/th>\n<td>\n<pre>{\n  \"result\": true,\n  \"title\": \"Success\",\n  \"message\": \"Employees listed successfully.\",\n  \"object\": {\n    \"meta_data\": {\n      \"page_count\": 3,\n      \"page_number\": 1,\n      \"page_size\": 50,\n      \"record_count\": 127\n    },\n    \"data\": [\n      {\n        \"employee_code\": \"0001\",\n        \"full_name\": \"Ahmed Mohamed Hassan\",\n        \"short_name\": \"Ahmed Hassan\",\n        \"personal_info\": {\n          \"gender\": \"Male\",\n          \"date_of_birth\": \"1990-05-15\",\n          \"nationality\": \"Egyptian\",\n          \"religion\": \"Muslim\",\n          \"marital_status\": \"Married\",\n          \"military_status\": \"Completed\",\n          \"education\": \"Bachelor of Commerce\"\n        },\n        \"employment_info\": {\n          \"employment_status\": \"Working\",\n          \"join_date\": \"2020-01-15\",\n          \"layoff_date\": null,\n          \"location\": {\n            \"id\": 3,\n            \"name\": \"Cairo HQ\"\n          },\n          \"position\": {\n            \"id\": 17,\n            \"name\": \"Senior Accountant\"\n          },\n          \"department\": {\n            \"id\": 12,\n            \"name\": \"Finance\"\n          },\n          \"contract_type\": {\n            \"id\": 1,\n            \"name\": \"Full Time\"\n          },\n          \"working_days\": 5,\n          \"working_hours\": 40,\n          \"attendance_scheme\": {\n            \"id\": 4,\n            \"name\": \"Standard Office Hours\"\n          },\n          \"direct_head_code\": \"0025\"\n        }\n      }\n    ]\n  }\n}<\/pre>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Example 3 &#8211; Filtered Employee List<\/h4>\n<table style=\"width: auto;\">\n<tbody>\n<tr>\n<th style=\"text-align: left;\">Request<\/th>\n<td>\n<pre>curl --request GET 'https:\/\/your_account.modulus.biz\/api\/hr\/v1\/Employee?employment_status=Working&amp;location_id=3&amp;department_id=12&amp;direct_head_code=0025&amp;groups=employment_info&amp;page_number=1&amp;page_size=50' \\\n--header 'Accept: application\/json' \\\n--header 'Authorization: Bearer &lt;token&gt;'<\/pre>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Example 4 &#8211; Specific Employee<\/h4>\n<table style=\"width: auto;\">\n<tbody>\n<tr>\n<th style=\"text-align: left;\">Request<\/th>\n<td>\n<pre>curl --request GET 'https:\/\/your_account.modulus.biz\/api\/hr\/v1\/Employee?employee_code=0001&amp;groups=personal_info,employment_info' \\\n--header 'Accept: application\/json' \\\n--header 'Authorization: Bearer &lt;token&gt;'<\/pre>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Example 5 &#8211; No Matching Employees<\/h4>\n<table style=\"width: auto;\">\n<tbody>\n<tr>\n<th style=\"text-align: left;\">Request<\/th>\n<td>\n<pre>curl --request GET 'https:\/\/your_account.modulus.biz\/api\/hr\/v1\/Employee?employee_code=NONEXISTENT' \\\n--header 'Accept: application\/json' \\\n--header 'Authorization: Bearer &lt;token&gt;'<\/pre>\n<\/td>\n<\/tr>\n<tr>\n<th style=\"text-align: left;\">200 OK<\/th>\n<td>\n<pre>{\n  \"result\": true,\n  \"title\": \"Success\",\n  \"message\": \"No employees found matching your conditions.\",\n  \"object\": {\n    \"meta_data\": {\n      \"page_count\": 0,\n      \"page_number\": 1,\n      \"page_size\": 50,\n      \"record_count\": 0\n    },\n    \"data\": []\n  }\n}<\/pre>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Example 6 &#8211; Invalid Group<\/h4>\n<table style=\"width: auto;\">\n<tbody>\n<tr>\n<th style=\"text-align: left;\">Request<\/th>\n<td>\n<pre>curl --request GET 'https:\/\/your_account.modulus.biz\/api\/hr\/v1\/Employee?groups=personal_info,payroll_info' \\\n--header 'Accept: application\/json' \\\n--header 'Authorization: Bearer &lt;token&gt;'<\/pre>\n<\/td>\n<\/tr>\n<tr>\n<th style=\"text-align: left;\">400 Bad Request<\/th>\n<td>\n<pre>{\n  \"result\": false,\n  \"title\": \"Invalid Request\",\n  \"message\": \"Invalid information group: payroll_info.\",\n  \"object\": null\n}<\/pre>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Integration Notes<\/h4>\n<ul>\n<li>Use employee_code and direct_head_code as strings to preserve leading zeros.<\/li>\n<li>Use location_id, position_id, and department_id to filter organizational assignments.<\/li>\n<li>Contract type is returned in employment_info but is not currently exposed as a request filter.<\/li>\n<li>When groups is omitted, only employee_code, full_name, and short_name are returned.<\/li>\n<li>Requested groups are expanded for each employee; unrequested groups are omitted.<\/li>\n<li>Use pagination metadata instead of assuming a response contains the full result set.<\/li>\n<\/ul>\n","protected":false},"featured_media":0,"parent":3773,"menu_order":3,"comment_status":"closed","ping_status":"closed","template":"","doc_tag":[],"comment_count":0,"_links":{"self":[{"href":"https:\/\/modulus.help\/kb\/wp-json\/wp\/v2\/docs\/4778"}],"collection":[{"href":"https:\/\/modulus.help\/kb\/wp-json\/wp\/v2\/docs"}],"about":[{"href":"https:\/\/modulus.help\/kb\/wp-json\/wp\/v2\/types\/docs"}],"replies":[{"embeddable":true,"href":"https:\/\/modulus.help\/kb\/wp-json\/wp\/v2\/comments?post=4778"}],"version-history":[{"count":8,"href":"https:\/\/modulus.help\/kb\/wp-json\/wp\/v2\/docs\/4778\/revisions"}],"predecessor-version":[{"id":4801,"href":"https:\/\/modulus.help\/kb\/wp-json\/wp\/v2\/docs\/4778\/revisions\/4801"}],"up":[{"embeddable":true,"href":"https:\/\/modulus.help\/kb\/wp-json\/wp\/v2\/docs\/3773"}],"next":[{"title":"API: List Employee Schedules","link":"https:\/\/modulus.help\/kb\/docs\/documentation\/personnel-apis-v1\/api-list-employee-schedules\/","href":"https:\/\/modulus.help\/kb\/wp-json\/wp\/v2\/docs\/4558"}],"prev":[{"title":"API: List Attendance Logs","link":"https:\/\/modulus.help\/kb\/docs\/documentation\/personnel-apis-v1\/api-list-attendance-logs\/","href":"https:\/\/modulus.help\/kb\/wp-json\/wp\/v2\/docs\/4771"}],"wp:attachment":[{"href":"https:\/\/modulus.help\/kb\/wp-json\/wp\/v2\/media?parent=4778"}],"wp:term":[{"taxonomy":"doc_tag","embeddable":true,"href":"https:\/\/modulus.help\/kb\/wp-json\/wp\/v2\/doc_tag?post=4778"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}