API v1

JSON for this week's canteen menu, in the shape the first kantine site gave. v3 and v2 add next week, allergens and other weeks.

Endpoints

Method Path Returns
GET /api/v1/canteens Every canteen with a menu
GET /api/v1/canteens/{canteen_id} One canteen and this week's menu

Conventions

Method
Every endpoint is a GET.
Data
Menus come from Kanpla, as of the last fetch.
Dates
ISO 8601, YYYY-MM-DD.
Times
UTC, ISO 8601 with a Z suffix.
Success
200 with {"data": ...}
Not found
404 for an unknown canteen_id.

Error body

{"detail": "Canteen not found"}

GET /api/v1/canteens

Every canteen with a menu.

Fields

Field Type Meaning
canteen_id string The canteen's identifier; the {canteen_id} in the path below.
name string Display name.
provider string Where the menu comes from; kanpla.
Example response
{
  "data": [
    {
      "canteen_id": "jonsvollsgaten2",
      "name": "Jonsvollsgaten 2",
      "provider": "kanpla"
    }
  ]
}

GET /api/v1/canteens/{canteen_id}

One canteen and this week's menu. Next week is never included.

Parameters

{canteen_id}
path; a canteen_id from the canteen list.

Fields

Also canteen_id, name and provider, as in the list.

Field Type Meaning
real_canteen_id string The same as canteen_id.
store_url string Where the canteen's shop is; https://app.kanpla.io/.
fetched_at string The last update from Kanpla. 1970-01-01T00:00:00Z before the first.
days object[] This week's days with a menu: date, hot, soup.
days[].hot, days[].soup object[] The dishes, sorted by name. Kanpla has no field for soup; a dish is soup when its name or Kanpla category mentions soup (suppe, soup), and hot otherwise.
dish.name string The dish.
dish.garnish string | null More about the dish; Kanpla's description.
dish.theme null Always null.
Example response
{
  "data": {
    "canteen_id": "jonsvollsgaten2",
    "real_canteen_id": "jonsvollsgaten2",
    "name": "Jonsvollsgaten 2",
    "provider": "kanpla",
    "store_url": "https://app.kanpla.io/",
    "fetched_at": "2026-10-01T07:17:07.024329Z",
    "days": [
      {
        "date": "2026-10-01",
        "hot": [
          {
            "name": "Fiskekaker med potet og hvitsaus",
            "garnish": "Fiskekaker med deilig saus, potet og salat",
            "theme": null
          }
        ],
        "soup": [
          {
            "name": "Løksuppe med brød",
            "garnish": null,
            "theme": null
          }
        ]
      }
    ]
  }
}