Skip to content
Docs
API 1.0.0 · 22 Nov 2026

Search the docs

    Română

    Register a hire

    Prepare a hire, type the personal number of the employee, pass the checks and follow the operation until the register has registered it.

    On this page

    A hire makes the contract of a new employee and the register operation that registers it. You prepare both with one request, then complete the draft and take it through approval and transmission.

    What you need

    • The id of the employer, from listEmployers.
    • A designated person who holds the prepare scope for the employer. See Designated persons.
    • The contract as it was concluded, and a code from the list of occupations. See Occupation codes.
    • The personal number of the employee. You type it after the draft exists.

    Prepare the hire

    Send kind hire with the contract in hire. Choose a new operationId; sending the same request again with the same operationId is safe (see Idempotency).

    curl

    curl -X POST "$RDC_BASE_URL/reges/v1/register-operations" \
      -H "Authorization: Bearer $RDC_TOKEN" \
      -H "Content-Type: application/json" \
      -d '{
      "operationId": "fd7fb0da-e8d9-4e54-831d-70ff66d2545a",
      "employerId": "6e2aa977-c041-49c3-8c57-b9f2cd6cf3f0",
      "kind": "hire",
      "designatedPerson": "f3a70882-0da0-4686-bc0c-f29ce600bb0c",
      "hire": {
        "employeeName": "Dan Ilie",
        "citizenship": "RO",
        "contractNumber": "CIM 0391/2026",
        "concludedOn": "2026-11-20",
        "startDate": "2026-12-02",
        "occupation": "432102",
        "contractType": "indefinite",
        "workplace": {
          "kind": "fixed",
          "place": "Piatra-Neamț"
        },
        "hoursPerWeek": 40,
        "baseSalary": "4400.00"
      }
    }'

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/reges/v1/register-operations`, {
      method: 'POST',
      headers: {
        Authorization: `Bearer ${process.env.RDC_TOKEN}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        "operationId": "fd7fb0da-e8d9-4e54-831d-70ff66d2545a",
        "employerId": "6e2aa977-c041-49c3-8c57-b9f2cd6cf3f0",
        "kind": "hire",
        "designatedPerson": "f3a70882-0da0-4686-bc0c-f29ce600bb0c",
        "hire": {
          "employeeName": "Dan Ilie",
          "citizenship": "RO",
          "contractNumber": "CIM 0391/2026",
          "concludedOn": "2026-11-20",
          "startDate": "2026-12-02",
          "occupation": "432102",
          "contractType": "indefinite",
          "workplace": {
            "kind": "fixed",
            "place": "Piatra-Neamț"
          },
          "hoursPerWeek": 40,
          "baseSalary": "4400.00"
        }
      }),
    });
    const result = await response.json();

    Python

    import os
    import requests
    
    response = requests.request(
        'POST',
        f'{os.environ["RDC_BASE_URL"]}/reges/v1/register-operations',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
        json={
            'operationId': 'fd7fb0da-e8d9-4e54-831d-70ff66d2545a',
            'employerId': '6e2aa977-c041-49c3-8c57-b9f2cd6cf3f0',
            'kind': 'hire',
            'designatedPerson': 'f3a70882-0da0-4686-bc0c-f29ce600bb0c',
            'hire': {
                'employeeName': 'Dan Ilie',
                'citizenship': 'RO',
                'contractNumber': 'CIM 0391/2026',
                'concludedOn': '2026-11-20',
                'startDate': '2026-12-02',
                'occupation': '432102',
                'contractType': 'indefinite',
                'workplace': {
                    'kind': 'fixed',
                    'place': 'Piatra-Neamț',
                },
                'hoursPerWeek': 40,
                'baseSalary': '4400.00',
            },
        },
    )
    result = response.json()

    PHP

    <?php
    
    $body = <<<'JSON'
    {
      "operationId": "fd7fb0da-e8d9-4e54-831d-70ff66d2545a",
      "employerId": "6e2aa977-c041-49c3-8c57-b9f2cd6cf3f0",
      "kind": "hire",
      "designatedPerson": "f3a70882-0da0-4686-bc0c-f29ce600bb0c",
      "hire": {
        "employeeName": "Dan Ilie",
        "citizenship": "RO",
        "contractNumber": "CIM 0391/2026",
        "concludedOn": "2026-11-20",
        "startDate": "2026-12-02",
        "occupation": "432102",
        "contractType": "indefinite",
        "workplace": {
          "kind": "fixed",
          "place": "Piatra-Neamț"
        },
        "hoursPerWeek": 40,
        "baseSalary": "4400.00"
      }
    }
    JSON;
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/reges/v1/register-operations');
    curl_setopt_array($curl, [
        CURLOPT_CUSTOMREQUEST => 'POST',
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_HTTPHEADER => [
            'Authorization: Bearer ' . getenv('RDC_TOKEN'),
            'Content-Type: application/json',
        ],
        CURLOPT_POSTFIELDS => $body,
    ]);
    $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.Post, $"{Environment.GetEnvironmentVariable("RDC_BASE_URL")}/reges/v1/register-operations");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    request.Content = new StringContent("""
    {
      "operationId": "fd7fb0da-e8d9-4e54-831d-70ff66d2545a",
      "employerId": "6e2aa977-c041-49c3-8c57-b9f2cd6cf3f0",
      "kind": "hire",
      "designatedPerson": "f3a70882-0da0-4686-bc0c-f29ce600bb0c",
      "hire": {
        "employeeName": "Dan Ilie",
        "citizenship": "RO",
        "contractNumber": "CIM 0391/2026",
        "concludedOn": "2026-11-20",
        "startDate": "2026-12-02",
        "occupation": "432102",
        "contractType": "indefinite",
        "workplace": {
          "kind": "fixed",
          "place": "Piatra-Neamț"
        },
        "hoursPerWeek": 40,
        "baseSalary": "4400.00"
      }
    }
    """, System.Text.Encoding.UTF8, "application/json");
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 202

    {
      "operationId": "fd7fb0da-e8d9-4e54-831d-70ff66d2545a",
      "status": "accepted",
      "aggregateId": "447e408d-e905-4304-a4cb-9e82a9788ce6",
      "aggregateRevision": 1
    }

    FieldMeaning
    employeeNameThe name of the employee as the contract carries it.
    citizenshipRO, EU, EEA or non-EU.
    contractNumberThe number of the contract.
    concludedOnThe day the contract was concluded.
    startDateThe first day of work.
    occupationA code of the list of occupations (listOccupations).
    contractTypeindefinite or fixed-term.
    endDateThe last day of a fixed-term contract. Leave it out for an indefinite one.
    workplaceAn object with kind (fixed or mobile) and place.
    hoursPerWeekHours per week.
    baseSalaryThe monthly gross base salary in RON, as a decimal string.

    The answer is 202. Its aggregateId is the register operation: read it with getRegisterOperation once the status of the change is completed. The contract exists and is pending.

    Read the checks

    The gateway runs the checks on every change to the draft. A new draft has no personal number, so cnp-structure fails and canSend is false.

    curl

    curl "$RDC_BASE_URL/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/checks" \
      -H "Authorization: Bearer $RDC_TOKEN"

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/checks`, {
      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"]}/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/checks',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
    )
    result = response.json()

    PHP

    <?php
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/checks');
    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")}/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/checks");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 200

    {
      "registerOperationId": "447e408d-e905-4304-a4cb-9e82a9788ce6",
      "revision": 1,
      "canSend": false,
      "blocking": 1,
      "checks": [
        {
          "id": "cnp-structure",
          "severity": "blocking",
          "passed": false,
          "message": "No personal number has been entered yet.",
          "detail": {
            "check": "missing"
          }
        },
        {
          "id": "occupation-code",
          "severity": "blocking",
          "passed": true,
          "message": "Occupation code 432102 is in the list of occupations (Magaziner).",
          "detail": {
            "code": "432102"
          }
        },
        {
          "id": "minimum-salary",
          "severity": "blocking",
          "passed": true,
          "message": "The base salary of 4,400.00 RON is not below the minimum of 4,325.00 RON for this weekly schedule.",
          "detail": {
            "salary": "4400.00",
            "minimum": "4325.00"
          }
        },
        {
          "id": "working-time",
          "severity": "blocking",
          "passed": true,
          "message": "40 hours a week is within the maximum of 40 hours.",
          "detail": {
            "hours": 40,
            "maximum": 40
          }
        },
        {
          "id": "contract-state",
          "severity": "blocking",
          "passed": true,
          "message": "The contract is pending, which this operation allows.",
          "detail": {
            "status": "pending",
            "required": "pending"
          }
        },
        {
          "id": "deadline",
          "severity": "attention",
          "passed": true,
          "message": "The deadline is 1 December 2026, in 4 working days.",
          "detail": {
            "deadline": "2026-12-01",
            "late": -4
          }
        }
      ]
    }

    These are the checks of a hire. blocking stops validateOperation; attention is shown and stops nothing. fixed-term-end joins them when contractType is fixed-term.

    CheckSeverityResult for the example
    cnp-structureblockingThe personal number has a valid structure and its birth date is a real date.
    minimum-ageattentionThe employee is 25 years old; the minimum age for work is 16 years.
    occupation-codeblockingOccupation code 432102 is in the list of occupations (Magaziner).
    minimum-salaryblockingThe base salary of 4,400.00 RON is not below the minimum of 4,325.00 RON for this weekly schedule.
    working-timeblocking40 hours a week is within the maximum of 40 hours.
    contract-stateblockingThe contract is pending, which this operation allows.
    deadlineattentionWarns when the deadline has passed. It stops nothing; transmitting after it needs a reason.

    Minimum salary

    The guaranteed minimum gross base salary is 4,325 RON a month for a normal schedule of 166.667 hours a month, from 1 July 2026. The gateway scales it by the weekly hours of the contract: for 40 hours it is 4,325.00 RON, for 30 hours it is 3,243.75 RON. A baseSalary below the minimum for its hoursPerWeek fails minimum-salary.

    Minimum age

    A person acquires the capacity to work at 16. A person may be employed from 15 with the consent of the parents or legal representatives; under 15 employment is forbidden. The gateway reads the age on the start date from the birth date in the personal number, so minimum-age runs once a valid number is typed. Below 16 years it fails:

    SeverityResult
    attentionThe employee is 15 years old, under the minimum age of 16 years: from the age of 15 years work is allowed only with the consent of a parent or legal representative.
    blockingThe employee is 14 years old; a contract of employment cannot be concluded below the age of 15 years.

    Type the personal number

    Change the draft with editOperation: field personalNumber, the number with or without spaces, and the expectedRevision you read. The gateway checks its structure and drops it. The contract keeps its last four digits and the birth date.

    curl

    curl -X POST "$RDC_BASE_URL/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/edit" \
      -H "Authorization: Bearer $RDC_TOKEN" \
      -H "Content-Type: application/json" \
      -d '{
      "operationId": "91d8dc13-4627-4a5a-9f22-edf7ee81e418",
      "expectedRevision": 1,
      "field": "personalNumber",
      "value": "5 010118 27 532 8"
    }'

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/edit`, {
      method: 'POST',
      headers: {
        Authorization: `Bearer ${process.env.RDC_TOKEN}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        "operationId": "91d8dc13-4627-4a5a-9f22-edf7ee81e418",
        "expectedRevision": 1,
        "field": "personalNumber",
        "value": "5 010118 27 532 8"
      }),
    });
    const result = await response.json();

    Python

    import os
    import requests
    
    response = requests.request(
        'POST',
        f'{os.environ["RDC_BASE_URL"]}/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/edit',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
        json={
            'operationId': '91d8dc13-4627-4a5a-9f22-edf7ee81e418',
            'expectedRevision': 1,
            'field': 'personalNumber',
            'value': '5 010118 27 532 8',
        },
    )
    result = response.json()

    PHP

    <?php
    
    $body = <<<'JSON'
    {
      "operationId": "91d8dc13-4627-4a5a-9f22-edf7ee81e418",
      "expectedRevision": 1,
      "field": "personalNumber",
      "value": "5 010118 27 532 8"
    }
    JSON;
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/edit');
    curl_setopt_array($curl, [
        CURLOPT_CUSTOMREQUEST => 'POST',
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_HTTPHEADER => [
            'Authorization: Bearer ' . getenv('RDC_TOKEN'),
            'Content-Type: application/json',
        ],
        CURLOPT_POSTFIELDS => $body,
    ]);
    $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.Post, $"{Environment.GetEnvironmentVariable("RDC_BASE_URL")}/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/edit");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    request.Content = new StringContent("""
    {
      "operationId": "91d8dc13-4627-4a5a-9f22-edf7ee81e418",
      "expectedRevision": 1,
      "field": "personalNumber",
      "value": "5 010118 27 532 8"
    }
    """, System.Text.Encoding.UTF8, "application/json");
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 202

    {
      "operationId": "91d8dc13-4627-4a5a-9f22-edf7ee81e418",
      "status": "accepted",
      "aggregateId": "447e408d-e905-4304-a4cb-9e82a9788ce6",
      "aggregateRevision": 2
    }

    The deadline

    The data of a hire are transmitted at the latest the day before the person starts work. The gateway computes it from date, the start of work, and keeps it on the operation as deadline.

    curl

    curl "$RDC_BASE_URL/reges/v1/deadlines?kind=hire&date=2026-12-02" \
      -H "Authorization: Bearer $RDC_TOKEN"

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/reges/v1/deadlines?kind=hire&date=2026-12-02`, {
      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"]}/reges/v1/deadlines?kind=hire&date=2026-12-02',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
    )
    result = response.json()

    PHP

    <?php
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/reges/v1/deadlines?kind=hire&date=2026-12-02');
    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")}/reges/v1/deadlines?kind=hire&date=2026-12-02");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 200

    {
      "date": "2026-12-01",
      "rule": "hire",
      "from": "2026-12-02",
      "workingDaysLeft": 4
    }

    Validate, approve, transmit

    1. Validate

      validateOperation moves the draft to validated once no blocking check fails.

    2. Approve

      authorizeOperation, by a designated person who holds approve and did not prepare the operation.

    3. Record the transmission

      A designated person who holds transmit sends the hire to the register with the access of the employer, and submitOperation records it.

    4. Record the answer

      recordAnswer keeps the reference of the register, or its words unchanged when it rejects the hire.

    curl

    curl -X POST "$RDC_BASE_URL/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/validate" \
      -H "Authorization: Bearer $RDC_TOKEN" \
      -H "Content-Type: application/json" \
      -d '{
      "operationId": "f3e122ff-b3de-4e37-816b-035e7c22214f",
      "expectedRevision": 2
    }'

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/validate`, {
      method: 'POST',
      headers: {
        Authorization: `Bearer ${process.env.RDC_TOKEN}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        "operationId": "f3e122ff-b3de-4e37-816b-035e7c22214f",
        "expectedRevision": 2
      }),
    });
    const result = await response.json();

    Python

    import os
    import requests
    
    response = requests.request(
        'POST',
        f'{os.environ["RDC_BASE_URL"]}/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/validate',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
        json={
            'operationId': 'f3e122ff-b3de-4e37-816b-035e7c22214f',
            'expectedRevision': 2,
        },
    )
    result = response.json()

    PHP

    <?php
    
    $body = <<<'JSON'
    {
      "operationId": "f3e122ff-b3de-4e37-816b-035e7c22214f",
      "expectedRevision": 2
    }
    JSON;
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/validate');
    curl_setopt_array($curl, [
        CURLOPT_CUSTOMREQUEST => 'POST',
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_HTTPHEADER => [
            'Authorization: Bearer ' . getenv('RDC_TOKEN'),
            'Content-Type: application/json',
        ],
        CURLOPT_POSTFIELDS => $body,
    ]);
    $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.Post, $"{Environment.GetEnvironmentVariable("RDC_BASE_URL")}/reges/v1/register-operations/447e408d-e905-4304-a4cb-9e82a9788ce6/validate");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    request.Content = new StringContent("""
    {
      "operationId": "f3e122ff-b3de-4e37-816b-035e7c22214f",
      "expectedRevision": 2
    }
    """, System.Text.Encoding.UTF8, "application/json");
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 202

    {
      "operationId": "f3e122ff-b3de-4e37-816b-035e7c22214f",
      "status": "accepted",
      "aggregateId": "447e408d-e905-4304-a4cb-9e82a9788ce6",
      "aggregateRevision": 3
    }

    The whole path, with every status, is on Lifecycle and statuses.

    The contract once it is registered

    The contract was pending. When recordAnswer records registered, it becomes active. A rejected hire leaves it pending.

    The contract after the hire is registered

    {
      "number": "CIM 0391/2026",
      "status": "active"
    }