Create an employment period
Records a new employment period for the given employee.
Availability: Full version and ZEP Clock
Request
curl --request POST \
--url 'https://www.zep-online.de/zepinstanz/next/api/v1/employees/{username}/employment-periods' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {token}' \
--header 'Content-Type: application/json' \
--data '{
"employee_id": "max.mustermann",
"start_date": "2024-01-15T00:00:00.000000Z",
"end_date": "2024-01-16T00:00:00.000000Z",
"note": "Familienurlaub",
"annual_leave_entitlement": 30,
"beginning_of_year": "2024-01-01T00:00:00.000000Z",
"period_holiday_entitlement": 30,
"is_holiday_per_year": true,
"day_absent_in_hours": 8
}'Path parameters
- Name
username- Type
- string
- Description
The employee username
Request body
- Name
employee_id- Type
- string, required
- Description
Username of the employee this employment period is recorded for.
- Name
start_date- Type
- string (date-time), required
- Description
First calendar day the employee is employed under this period.
- Name
end_date- Type
- string (date-time), nullable
- Description
Last calendar day the employee is employed under this period, if it ends.
- Name
note- Type
- string, nullable
- Description
Free-text note attached to the employment period.
- Name
annual_leave_entitlement- Type
- number, required
- Description
Number of vacation days the employee is entitled to per full leave year.
- Name
beginning_of_year- Type
- string (date-time), nullable
- Description
Calendar day the leave year begins on for this employment period.
- Name
period_holiday_entitlement- Type
- number, nullable
- Description
Number of vacation days the employee is entitled to, prorated for this period.
- Name
is_holiday_per_year- Type
- boolean, nullable
- Description
Whether the annual leave entitlement is expressed per calendar year rather than per employment period.
- Name
day_absent_in_hours- Type
- number, nullable
- Description
Number of hours a full day of absence is booked as for this employment period.
Response
{
"data": {
"id": 1,
"employee_id": "max.mustermann",
"start_date": "2024-01-15T00:00:00.000000Z",
"end_date": "2024-01-16T00:00:00.000000Z",
"note": "Familienurlaub",
"beginning_of_year": "2024-01-01T00:00:00.000000Z",
"annual_leave_entitlement": 30,
"period_holiday_entitlement": 30,
"is_holiday_per_year": true,
"day_absent_in_hours": 8,
"created": "2024-07-20T11:30:00.000000Z",
"modified": "2024-07-20T12:30:00.000000Z"
}
}Response fields
- Name
id- Type
- integer
- Description
Unique identifier of the employment period.
- Name
employee_id- Type
- string
- Description
Username of the employee this employment period belongs to.
- Name
start_date- Type
- string (date-time), nullable
- Description
First calendar day the employee was employed under this period.
- Name
end_date- Type
- string (date-time), nullable
- Description
Last calendar day the employee was employed under this period, if it ended.
- Name
note- Type
- string, nullable
- Description
Free-text note attached to the employment period.
- Name
beginning_of_year- Type
- string (date-time), nullable
- Description
Calendar day the leave year begins on for this employment period.
- Name
annual_leave_entitlement- Type
- number, nullable
- Description
Number of vacation days the employee is entitled to per full leave year.
- Name
period_holiday_entitlement- Type
- number, nullable
- Description
Number of vacation days the employee is entitled to, prorated for this period.
- Name
is_holiday_per_year- Type
- boolean, nullable
- Description
Whether the annual leave entitlement is expressed per calendar year rather than per employment period.
- Name
day_absent_in_hours- Type
- number, nullable
- Description
Number of hours a full day of absence is booked as for this employment period.
- Name
created- Type
- string (date-time), nullable
- Description
Timestamp the employment period was created.
- Name
modified- Type
- string (date-time), nullable
- Description
Timestamp the employment period was last modified.