Skip to content
Docs
API 1.0.0 · 22 Nov 2026

Search the docs

    Română

    People and employments

    A person, the periods of their employment and the status that is read from them.

    On this page

    A person is one record per employee. What changes over time, the job, the department, the manager, the workplace, the contract and the salary, is not in the person but in their employments: one period for each time one of these changed. The person carries the fields of the period that runs, so a list of people reads like a staff directory.

    The person

    FieldMeaning
    idThe identifier every request names.
    numberThe staff number, A- and four digits. It is assigned when the person is hired.
    name, jobThe name, and the job of the period that runs, as it was entered.
    departmentId, managerId, workplaceIdThe department, the manager (a person of your account, null at the top) and the workplace of the period that runs. See Organisation.
    contractType, contractEndindefinite, or fixed-term with the last day of the contract. A fixed-term contract always has its end, and an indefinite one never does.
    startDate, lastDayThe first day of work, and the last once it is set.
    statusRead, never set. See below.
    revisionCounts the changes of the person. Send it as expectedRevision to change them.

    curl

    curl "$RDC_BASE_URL/hr/v1/employees?limit=2" \
      -H "Authorization: Bearer $RDC_TOKEN"

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/hr/v1/employees?limit=2`, {
      method: 'GET',
      headers: {
        Authorization: `Bearer ${process.env.RDC_TOKEN}`,
      },
    });
    const result = await response.json();

    Python

    import os
    import requests
    
    response = requests.request(
        'GET',
        f'{os.environ["RDC_BASE_URL"]}/hr/v1/employees?limit=2',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
    )
    result = response.json()

    PHP

    <?php
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/hr/v1/employees?limit=2');
    curl_setopt_array($curl, [
        CURLOPT_CUSTOMREQUEST => 'GET',
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_HTTPHEADER => [
            'Authorization: Bearer ' . getenv('RDC_TOKEN'),
        ],
    ]);
    $result = json_decode(curl_exec($curl), true);
    curl_close($curl);

    C#

    using System.Net.Http.Headers;
    
    var client = new HttpClient();
    var request = new HttpRequestMessage(HttpMethod.Get, $"{Environment.GetEnvironmentVariable("RDC_BASE_URL")}/hr/v1/employees?limit=2");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 200

    {
      "items": [
        {
          "id": "93c566c1-799c-4ccf-afac-244ff06d2537",
          "number": "A-0052",
          "name": "Raluca Toma",
          "job": "Sales representative",
          "departmentId": "sales",
          "managerId": "46419e0c-a16f-4e44-bed0-0b9700635fd6",
          "workplaceId": "office",
          "contractType": "indefinite",
          "contractEnd": null,
          "startDate": "2026-12-08",
          "lastDay": null,
          "status": "onboarding",
          "externalId": null,
          "revision": 2
        },
        {
          "id": "11729ba4-78ca-4dfb-9165-03367b42d67a",
          "number": "A-0041",
          "name": "Dan Ilie",
          "job": "Picker",
          "departmentId": "warehouse",
          "managerId": "21bd8239-2794-4320-adba-9128b6a6219b",
          "workplaceId": "warehouse",
          "contractType": "indefinite",
          "contractEnd": null,
          "startDate": "2022-02-07",
          "lastDay": null,
          "status": "active",
          "externalId": "hr-0187",
          "revision": 1
        }
      ],
      "nextCursor": null
    }

    Status

    The status of a person is read on the day of the request, in this order: left when the last day has passed; onboarding before the first day of work; on_leave while an approved leave request covers the day; offboarding when a last day is set; otherwise active. Nobody sets it, so it cannot disagree with the dates and the leave it comes from. A pending, rejected or cancelled request puts nobody on leave.

    Hiring and leaving

    Hire a person creates the person, their first employment and their onboarding checklist in one change. The first day of work is today or later and a working day. Set a last day of work ends the period that runs on that day. It is refused while a pending or approved leave request ends after it: cancel the request first.

    Your own ids

    The answer to a change is an operation result and does not carry the identifier of the new person. Give each person the number your own system has for them as externalId when you hire them, and find them with listEmployees and that number. A second person with the same externalId is refused with external_id_taken, so a run that is repeated finds the person instead of hiring them twice.