Skip to main content

Stations

This section documents the station management endpoints of the MiseOS API, which allow for retrieving, creating, updating, and deleting kitchen stations.

Stations represent kitchen sections (Hot Kitchen, Cold Kitchen, Pastry, etc.). Users and dishes can be assigned to stations to organize kitchen responsibilities and workflow.

Stations Endpoints
#

MethodURLAuth
GET/stationsHEAD_CHEF, SOUS_CHEF
GET/stations/{id}HEAD_CHEF, SOUS_CHEF
GET/stations/name/{name}HEAD_CHEF, SOUS_CHEF
POST/stationsHEAD_CHEF
PUT/stations/{id}HEAD_CHEF
DELETE/stations/{id}HEAD_CHEF

Station response object
#

The station object has the following structure:

{
  "id": 1,
  "stationName": "Cold Kitchen",
  "description": "Salads and starters"
}

GET /stations
#

Returns all stations.

Example Request
#

curl -H "Authorization: Bearer <token>" \
https://miseos.corral.dk/api/v1/stations

Response 200 — array of station objects.

[
  {
    "id": 1,
    "stationName": "Hot Kitchen",
    "description": "Main courses and hot dishes"
  },
  {
    "id": 2,
    "stationName": "Cold Kitchen",
    "description": "Salads and starters"
  }
]

GET /stations/{id}
#

Returns a station by ID.

Example Request
#

curl -H "Authorization: Bearer <token>" \
https://miseos.corral.dk/api/v1/stations/1

Response 200 — station object.

Errors

StatusCause
404Station not found

GET /stations/name/{name}
#

Returns a station by exact name match.

The name comparison is case-insensitive.

Example Request
#

curl -H "Authorization: Bearer <token>" \
https://miseos.corral.dk/api/v1/stations/name/Cold%20Kitchen

Response 200 — station object.

Errors

StatusCause
404Station not found

POST /stations
#

Creates a new station. Station names must be unique.

Request body

{
  "stationName": "Grill",
  "description": "Steaks and BBQ"
}

Response 201 — created station object.

Errors

StatusCause
400Invalid input — missing or empty stationName
409Station name already exists

PUT /stations/{id}
#

Updates a station’s name and description. Station names must be unique.

Request body — same shape as create.

Response 200 — updated station object.

Errors

StatusCause
400Invalid input — missing or empty stationName
404Station not found
409Station name already exists

DELETE /stations/{id}
#

Deletes a station. Deletion is blocked if the station has assigned users or dishes.

Response 204 — no content.

Errors

StatusCause
409Station has assigned users or dishes