Add a vacancy
This endpoint allows creating a vacancy and making it public for the employees specified in the request.
POST /api/v1/businesses/{businessId}/vacancies
Mandatory fields are marked with an asterisk (*). |
Request body
JSON Analysis |
---|
Details
|
Request example
Once the analysis of the different fields has been done, an example of the request body is shown:
{
"id": "0625-vac",
"product": "0001-G",
"day": "2024-06-25",
"expiration": "2024-06-24T10:00:00Z",
"employees": [
"1006355",
"1006356"
],
"shifts": [
{
"start": "2024-06-25T10:00:00Z",
"end": "2024-06-25T17:00:00Z"
}
]
}
Considerations
Times must be sent in UTC, and the publication is done considering the service’s time zone. In the example given in the request, for a service in UTC+2, the published vacancy would be as follows:
-
Shift: 25 Jun. 2024 12:00 - 25 Jun. 2024 19:00
-
Expiration: 24 Jun. 2024 12:00
If the data is correct, the vacancy will be published and will be visible under Scheduling > Vacant offers.
If the vacancy already exists, the request will return a 400 - Bad request
error indicating Vacancy already exists.
Different vacancies can be published for the same date and interval as long as the identifiers do not match.