v1

latestOpenAPI 3.1.0Apache 2.02026-07-22160175414.0 KB
Work-Contracts

Retrieve a work-contract

Retrieve a single work-contract by its ID.

get/directory/api/4.0/work-contracts/{id}

Response

OK

idinteger

Unique identifier of this work-contract.

ownerIdinteger

Unique identifier of the employee this work-contract belongs to.

externalIdstring nullable

Third-party identifier of this work-contract. May be not unique.

typeIdinteger

Identifier of the work-contract template this work-contract conforms to. Determines whether certain optional properties are required.

startsOnstring date

Start date of this work-contract. Format: YYYY-mm-DD.

isApplicableboolean

Readonly. Whether this work-contract applies to the employee at this very moment.

A work-contract is considered "applicable" if:

  1. It is the ongoing work-contract as of today;
  2. If there is none, then it is the first upcoming work-contract;
  3. If not, then it is the last work-contract this employee had.
establishmentIdinteger

Identifier of the establishment the employee works for.

spcIdinteger nullable

Identifier of the socio-professional category.

Refer to the API endpoint: /organization/structure/api/occupation-categories.

hiringTypeIdinteger nullable

Identifier of a hiring reason type.

Refer to the API endpoint: /directory/api/work-contract-hiring-types.

trialPeriodDaysinteger nullable

Number of days of the initial trial period.

renewedTrialPeriodDaysinteger nullable

Number of days of renewed trial period (equal to the length of the initial period, plus the renewal period).

trialPeriodEndDatestring date nullable

Initial trial period end date. Format: YYYY-mm-DD.

trialPeriodEndDate2string date nullable

Renewed trial period end date. Format: YYYY-mm-DD.

temporaryContractGroundIdinteger nullable

Identifier of the temporary contract ground.

Refer to the API endpoint: /directory/api/work-contract-temporary-contract-grounds.

internshipSupervisorIdinteger nullable

Identifier of the employee/user that acts as internship supervisor.

endsOnstring date nullable

End date of this work-contract. Leave null if not (yet) known. Format: YYYY-mm-DD.

terminationReasonIdinteger nullable

Identifier of the termination reason.

Refer to the API endpoint: /directory/api/work-contract-termination-reasons.

authorIdinteger

Read-only. Identifier of the user who created this work-contract.

createdAtstring date-time

Read-only. Timestamp of the moment this work-contract was created.

lastModifierIdinteger

Read-only. Identifier of the user who last modified this work-contract.

lastModifiedAtstring date-time

Read-only. Timestamp of the moment this work-contract was last updated.

Example response

{
  "id": 514,
  "ownerId": 416,
  "startsOn": "2021-01-01",
  "endsOn": null,
  "isApplicable": true,
  "establishmentId": 13,
  "spcId": 1,
  "typeId": 1,
  "hiringTypeId": 3,
  "terminationReasonId": null,
  "trialPeriodDays": 120,
  "renewedTrialPeriodDays": null,
  "trialPeriodEndDate": "2021-05-01",
  "trialPeriodEndDate2": null,
  "authorId": 45,
  "lastModifierId": 45,
  "createdAt": "2021-11-08T17:48:18.12",
  "lastModifiedAt": "2024-01-10T12:27:02.22"
}