Most problems come from a wrong value, missing caching, or calling the API from the browser. Work through this page before you contact support.
Check the API directly
Rule out your own code first. From a terminal on your web server:
curl -i "https://api.lernmark.app/api/v1/public/site/your-school/institutions/YOUR_INSTITUTION_ID/programmes?per_page=5"
-i prints the response headers, including the status, the rate-limit
headers, and the X-Request-Id you need if you contact us.
Error guide
| What you see | What to check | What visitors should see |
|---|---|---|
404 Not Found | Recopy the school slug and school ID. Ask your Lernmark administrator to check the Your website card under Admissions: the institution must be listed. | Programme information is temporarily unavailable. |
429 Too Many Requests | Your site reached the per-minute or daily limit. Check that every page shares one server cache. | Programme information is temporarily unavailable. |
Timeout or 5xx | Keep the 5-second timeout. Try again on a later request, not in a loop. | Programme information is temporarily unavailable. |
200 OK with no programmes | No programmes are listed for this institution yet, or you used a different institution's ID. | “No programmes are currently listed.” |
Fail closed
Never replace an error with guessed, placeholder, or expired programme details. Show the unavailable message until a new request succeeds.
Why do I get a 404?
The school slug or school ID is wrong, or the school is not listed
yet (see the Your website card under Admissions). The API gives the same 404 for all of these on purpose, so
it cannot be used to discover schools. Recopy both values exactly; see
Before you start.
Why is the programme list empty?
The school is listed, but none of its programmes are. Ask your Lernmark administrator to turn on On your website for each programme under Admissions → Programme availability. Also confirm you are using the intended school ID.
Why do I get a 429?
Your site made more than 60 requests in a minute or 1,000 in a day from the same IP address. This almost always means the cache is missing or not shared:
- Cache successful responses on your server for 5–15 minutes.
- Use one cache for all visitors, not one per visitor or per session.
- If you pass visitors' search text to the API, every new term is a new request. Prefer filtering the cached list on your server.
- After a
429, wait for the number of seconds inRetry-Afterbefore trying again.
Can I call the API from browser JavaScript?
It is not a supported pattern. Programmes loaded in the browser are missing from your page's HTML, so search engines may not see them; every visitor makes their own request, so you lose caching and the fail-closed message; and cross-origin browser access may be restricted in future. Fetch on your server, or through your own backend route, and send finished HTML.
Why is my page out of date?
Your server cache has not expired yet. Changes in Lernmark appear once the cache expires, so a 10-minute cache means up to 10 minutes' delay. Shorten it if you need faster updates, but keep it long enough that most page views are served from the cache.
Can I accept applications on my own form?
Not through this API; it is read-only. Link to your school's application form instead, or contact us about a managed integration.
Get help
If these checks do not solve it, contact us. Include the request
URL, the time it failed, the HTTP status, and the X-Request-Id response
header. Never send passwords, cookies, or tokens.