> ## Documentation Index
> Fetch the complete documentation index at: https://klef.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Deel

<div className="page-title-row">
  <img src="https://mintcdn.com/klef/clancm3d_7_jKDmR/images/connectors/deel.svg?fit=max&auto=format&n=clancm3d_7_jKDmR&q=85&s=e4a9026867a05b50b7b4419f7652a1cb" alt="" noZoom width="400" height="400" data-path="images/connectors/deel.svg" />

  <h1>Deel</h1>
</div>

## Connection

### Setup

<Steps>
  <Step>
    In Deel, [create an organization token](https://developer.deel.com/api/authentication) with the **people:read** and **contracts:read** scopes.
  </Step>

  <Step>
    Select **Organization-level access** and set **Hide Sensitive Employment Information** to true. Set **Hide all PII** to false.
  </Step>

  <Step>
    Enter the token in the connection's settings and click the **Save** button.
  </Step>
</Steps>

Deel groups people in three ways, and each is an organization unit on the assignment:

| Deel | Organization unit |
| - | - |
| Group | `group` |
| Legal entity | `legal_entity` |
| Team, in the **Teams** organizational structure | `team` |

### Settings

| Setting | Required | Description |
| - | - | - |
| Token | Yes | An organization token with the people:read and contracts:read scopes. Stored encrypted. |
| Sandbox | | Whether the organization is a Deel sandbox. |

## Fields

The [worker model](/docs/connectors/worker-model) fields Klef fills from Deel.

| Field | Type | Description |
| - | - | - |
| `worker.source_id` | string | The worker's ID in the HR system. |
| `worker.employee_id` | string | Employee number from the HR system. |
| `worker.legal_name` | object | Legal name. |
| `worker.legal_name.given` | string | Legal first name. |
| `worker.legal_name.family` | string | Legal last name. |
| `worker.preferred_name` | object | Name the worker goes by. |
| `worker.preferred_name.given` | string | Preferred first name. |
| `worker.preferred_name.family` | string | Preferred last name. |
| `worker.display_name` | string | Full name for display. |
| `worker.business_email` | string | Primary business email address. |
| `worker.personal_email` | string | Primary personal email address. |
| `worker.status` | string | Pending, Active, Leave, Terminated, Deceased or Unspecified. |
| `worker.start_date` | date | Start date of the primary assignment. |
| `worker.end_date` | date | End date of the primary assignment. |
| `worker.hire_date` | date | Original hire date. |
| `worker.department` | object | Department of the primary assignment. |
| `worker.department.code` | string | Department code. |
| `worker.department.name` | string | Department name. |
| `worker.job` | object | Job of the primary assignment. |
| `worker.job.code` | string | Job code. |
| `worker.job.name` | string | Job name. |
| `worker.manager` | string | Source ID of the primary assignment's manager. |
| `worker.location` | object | Work location of the primary assignment. |
| `worker.location.name` | string | Location name. |
| `worker.location.region` | string | State or region. |
| `worker.location.country` | string | Country. |
| `worker.worker_type` | string | Employee or Contractor, from the primary assignment. |
| `worker.custom_fields` | map | Fields your HR system defines, by name. |
| `worker.custom_fields.<name>` | string | Field value. |
| `worker.assignments` | array | Every job the worker holds. |
| `worker.assignments[].source_id` | string | The assignment's ID in the HR system. |
| `worker.assignments[].is_primary` | bool | Whether this is the worker's primary assignment. |
| `worker.assignments[].status` | string | Pending, Active, Leave, Terminated, Deceased or Unspecified. |
| `worker.assignments[].job` | object | Job of the assignment. |
| `worker.assignments[].job.code` | string | Job code. |
| `worker.assignments[].job.name` | string | Job name. |
| `worker.assignments[].department` | object | Department of the assignment. |
| `worker.assignments[].department.code` | string | Department code. |
| `worker.assignments[].department.name` | string | Department name. |
| `worker.assignments[].location` | object | Work location. |
| `worker.assignments[].location.name` | string | Location name. |
| `worker.assignments[].location.region` | string | State or region. |
| `worker.assignments[].location.country` | string | Country. |
| `worker.assignments[].manager` | string | Source ID of the assignment's manager. |
| `worker.assignments[].start_date` | date | Start date. |
| `worker.assignments[].end_date` | date | End date. |
| `worker.assignments[].worker_type` | string | Employee or Contractor. |
| `worker.assignments[].custom_fields` | map | Fields your HR system defines, by name. |
| `worker.assignments[].custom_fields.<name>` | string | Field value. |
| `worker.assignments[].org_units` | map | Organizational units the HR system places the assignment in, by type. |
| `worker.assignments[].org_units.<type>.code` | string | Unit code. |
| `worker.assignments[].org_units.<type>.name` | string | Unit name. |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.