> ## Documentation Index
> Fetch the complete documentation index at: https://mintlify.com/Falasefemi2/companyflow/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Employee

> Retrieve an employee by their ID

## Authentication

This endpoint requires Bearer token authentication with one of the following roles:

* `super_admin`
* `hr_manager`

## Path Parameters

<ParamField path="id" type="string" required>
  The unique identifier of the employee (UUID format)
</ParamField>

## Response

<ResponseField name="success" type="boolean">
  Indicates if the request was successful
</ResponseField>

<ResponseField name="data" type="object">
  <ResponseField name="id" type="string">
    Employee UUID
  </ResponseField>

  <ResponseField name="company_id" type="string">
    Company UUID
  </ResponseField>

  <ResponseField name="email" type="string">
    Employee email address
  </ResponseField>

  <ResponseField name="phone" type="string">
    Employee phone number
  </ResponseField>

  <ResponseField name="first_name" type="string">
    Employee first name
  </ResponseField>

  <ResponseField name="last_name" type="string">
    Employee last name
  </ResponseField>

  <ResponseField name="employee_code" type="string">
    Internal employee code
  </ResponseField>

  <ResponseField name="department_id" type="string">
    Department UUID
  </ResponseField>

  <ResponseField name="designation_id" type="string">
    Designation UUID
  </ResponseField>

  <ResponseField name="level_id" type="string">
    Level UUID
  </ResponseField>

  <ResponseField name="role_id" type="string">
    Role UUID
  </ResponseField>

  <ResponseField name="manager_id" type="string">
    Manager UUID
  </ResponseField>

  <ResponseField name="status" type="string">
    Employee status (active, inactive, on\_leave, terminated, probation)
  </ResponseField>

  <ResponseField name="employment_type" type="string">
    Employment type (full\_time, part\_time, contract, intern)
  </ResponseField>

  <ResponseField name="date_of_birth" type="string" nullable>
    Date of birth (ISO 8601 format)
  </ResponseField>

  <ResponseField name="hire_date" type="string">
    Hire date (ISO 8601 format)
  </ResponseField>

  <ResponseField name="termination_date" type="string" nullable>
    Termination date (ISO 8601 format)
  </ResponseField>

  <ResponseField name="gender" type="string">
    Employee gender
  </ResponseField>

  <ResponseField name="address" type="string">
    Employee address
  </ResponseField>

  <ResponseField name="emergency_contact_name" type="string">
    Emergency contact name
  </ResponseField>

  <ResponseField name="emergency_contact_phone" type="string">
    Emergency contact phone
  </ResponseField>

  <ResponseField name="profile_image_url" type="string">
    Profile image URL
  </ResponseField>

  <ResponseField name="last_login_at" type="string" nullable>
    Last login timestamp (ISO 8601 format)
  </ResponseField>

  <ResponseField name="created_at" type="string">
    Creation timestamp (ISO 8601 format)
  </ResponseField>

  <ResponseField name="updated_at" type="string">
    Last update timestamp (ISO 8601 format)
  </ResponseField>
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET https://api.companyflow.com/employees/emp-uuid-here \
    -H "Authorization: Bearer YOUR_TOKEN"
  ```
</RequestExample>

<ResponseExample>
  ```json 200 Success theme={null}
  {
    "success": true,
    "data": {
      "id": "emp-uuid-here",
      "company_id": "123e4567-e89b-12d3-a456-426614174000",
      "email": "john.doe@example.com",
      "phone": "+1234567890",
      "first_name": "John",
      "last_name": "Doe",
      "employee_code": "EMP001",
      "department_id": "dept-uuid-here",
      "designation_id": "desig-uuid-here",
      "level_id": "level-uuid-here",
      "role_id": "role-uuid-here",
      "manager_id": "manager-uuid-here",
      "status": "active",
      "employment_type": "full_time",
      "date_of_birth": "1990-01-15T00:00:00Z",
      "hire_date": "2024-01-01T00:00:00Z",
      "termination_date": null,
      "gender": "Male",
      "address": "123 Main St, City, State",
      "emergency_contact_name": "Jane Doe",
      "emergency_contact_phone": "+1987654321",
      "profile_image_url": "",
      "last_login_at": "2024-03-01T15:30:00Z",
      "created_at": "2024-01-01T10:00:00Z",
      "updated_at": "2024-03-01T15:30:00Z"
    }
  }
  ```

  ```json 400 Bad Request theme={null}
  {
    "success": false,
    "message": "invalid employee id"
  }
  ```

  ```json 401 Unauthorized theme={null}
  {
    "success": false,
    "message": "insufficient role"
  }
  ```

  ```json 500 Internal Server Error theme={null}
  {
    "success": false,
    "message": "employee not found"
  }
  ```
</ResponseExample>
