{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/merge/refs/heads/main/json-schema/hris-api-employee-schema.json",
  "title": "Employee",
  "description": "Represents an employee record from a connected HRIS integration in the Merge Unified API.",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "The unique Merge-generated identifier."
    },
    "remote_id": {
      "type": "string",
      "description": "The third-party ID of this employee."
    },
    "employee_number": {
      "type": "string",
      "description": "The employee's number in the organization."
    },
    "first_name": {
      "type": "string",
      "description": "The employee's first name."
    },
    "last_name": {
      "type": "string",
      "description": "The employee's last name."
    },
    "display_full_name": {
      "type": "string",
      "description": "The employee's full display name."
    },
    "work_email": {
      "type": "string",
      "format": "email",
      "description": "The employee's work email address."
    },
    "personal_email": {
      "type": "string",
      "format": "email",
      "description": "The employee's personal email address."
    },
    "mobile_phone_number": {
      "type": "string",
      "description": "The employee's mobile phone number."
    },
    "date_of_birth": {
      "type": "string",
      "format": "date",
      "description": "The employee's date of birth."
    },
    "start_date": {
      "type": "string",
      "format": "date-time",
      "description": "The date the employee started working."
    },
    "termination_date": {
      "type": "string",
      "format": "date-time",
      "description": "The date the employee was terminated."
    },
    "employment_status": {
      "type": "string",
      "enum": ["ACTIVE", "PENDING", "INACTIVE"],
      "description": "The current employment status."
    },
    "manager": {
      "type": "string",
      "format": "uuid",
      "description": "The Merge ID of this employee's manager."
    },
    "company": {
      "type": "string",
      "format": "uuid",
      "description": "The Merge ID of the employee's company."
    },
    "team": {
      "type": "string",
      "format": "uuid",
      "description": "The Merge ID of the employee's team."
    },
    "pay_group": {
      "type": "string",
      "format": "uuid",
      "description": "The Merge ID of the employee's pay group."
    },
    "groups": {
      "type": "array",
      "items": {
        "type": "string",
        "format": "uuid"
      },
      "description": "Groups this employee belongs to."
    },
    "remote_was_deleted": {
      "type": "boolean",
      "description": "Whether the record was deleted in the third-party platform."
    },
    "created_at": {
      "type": "string",
      "format": "date-time",
      "description": "When the Merge record was created."
    },
    "modified_at": {
      "type": "string",
      "format": "date-time",
      "description": "When the Merge record was last modified."
    }
  }
}
