Starting dates and places

Starting dates and places are metadata related for Trainings. They represent the time and place that a training takes place. This can be physical, but also online.

At this moment it is not possible to create trainings using the API. However, it is possible to create and update "starting_dateplaces" for existing trainings via the endpoint summarized on this page.

Available methods

Method Description
POST /trainings/:id/starting_dateplaces.xml Create a starting_dateplace for an existing training
PATCH /starting_dateplaces/:id.xml Updating a starting_dateplace

Note: next to .xml, .json is also supported.

Create a starting_dateplace for an existing training

Request: POST /trainings/:id/starting_dateplaces.xml?api_key=YOURAPIKEY

With this endpoint you can create a starting_dateplace for an existing training. If you do not know the id of your existing training, you can obtain that via the Trainings endpoint, by querying on the training's name with the query parameter.

Parameter Type Values Description
date Date YYYY-MM-DD Required
end_date Date YYYY-MM-DD Required
place String Place Required (unless the parameter online is true)
online Boolean true, false Optional
minimum_number_of_seats Integer Minimum number of seats Optional
maximum_number_of_seats Integer Maximum number of seats Optional
available_number_of_seats Integer Available number of seats Optional
guaranteed_start Boolean true, false Optional

Update a starting_dateplace

Request: PATCH /starting_dateplaces/:id.xml?api_key=YOURAPIKEY

Parameter Type Values Description
minimum_number_of_seats Integer Minimum number of seats Optional
maximum_number_of_seats Integer Maximum number of seats Optional
available_number_of_seats Integer Available number of seats Optional

Validations: before we create a starting_dateplace there are some validations/requirements that have to be fulfilled showing correct data to our users.

  • Startdate > now()
  • Enddate >= Startdate
  • Location contains an existing place (except when online=true) 
  • Maximum_number_of_seats > Minimum_number_of_seats
  • Maximum_number_of_seats > Available_number_of_seats