Create individual opening hours

Changed on
post/api/v1/opening_hours

Request

  • Base URL: http://varnish:8080
  • URL: http://varnish:8080/api/v1/opening_hours
  • Auth: cookie (a scheme the document does not define)

Query parameters

_format'json' required

Request format

Request body

idinteger

An serial unique id of the opening hours instance.

datestring date required

The date which the opening hours applies to. In ISO 8601 format.

start_timestring required

When the opening hours start. In format HH:MM

end_timestring required

When the opening hours end. In format HH:MM

branch_idinteger required

The id for the branch the instance belongs to

Example request

{
  "category": {
    "color": "#ff0099"
  },
  "start_time": "09:00",
  "end_time": "17:00"
}

Response

OK

idinteger required

An serial unique id of the opening hours instance.

datestring date required

The date which the opening hours applies to. In ISO 8601 format.

start_timestring required

When the opening hours start. In format HH:MM

end_timestring required

When the opening hours end. In format HH:MM

branch_idinteger required

The id for the branch the instance belongs to

branch_namestring required

The name of the branch the instance belongs to

Example response

[
  {
    "category": {
      "color": "#ff0099"
    },
    "start_time": "09:00",
    "end_time": "17:00"
  }
]

Changes