Research API for name day view #974

Open
opened 2026-05-15 12:24:13 +00:00 by a24julot · 7 comments
Collaborator

See if there is an API we could use to display todays name day (namnsdag).

See if there is an API we could use to display todays name day (namnsdag).
Collaborator

Damberg Namnsdag API

Swedish name day API (free) that provides full dataset export, name-based search, date-based lookup (month + day) and today endpoint.

API design

Single endpoint api.php which support queries:

Features

Can give exact match, composite name match, partial contains match and closest match. Which also returns a "queryStatus" with the possible values:

  • Exact match.
  • Part of composite name match.
  • Name contains match.
  • Closest name.
## [Damberg Namnsdag API](https://www.damberg.one/blogg/2024/namnsdagar/api.html) Swedish name day API (free) that provides full dataset export, name-based search, date-based lookup (month + day) and today endpoint. ## API design Single endpoint api.php which support queries: - [?today](https://damberg.one/blogg/2024/namnsdagar/api.php?today). - [?name=anders](https://damberg.one/blogg/2024/namnsdagar/api.php?name=anders). - [?month=4&day=12](https://damberg.one/blogg/2024/namnsdagar/api.php?month=4&day=12). - no params is full [dataset](https://damberg.one/blogg/2024/namnsdagar/api.php). ## Features Can give exact match, composite name match, partial contains match and closest match. Which also returns a "queryStatus" with the possible values: - Exact match. - Part of composite name match. - Name contains match. - Closest name.
Collaborator

Workgroup Namnsdag API

Swedish name day API (free), simple that focused on:

  • Name lookup.
  • Date lookup.
  • Wildcard search (Ann* find all names starting with Ann).

API design

Easy and clear separation between search and date lookup.

  • /api/namnsdag
  • /api/namnsdag?sök=anna
  • /api/namnsdag?sök=anna
  • /api/namnsdag?datum=2026-12-09
## ~~[Workgroup Namnsdag API](https://workgroup.se/api/namnsdag/)~~ ~~Swedish name day API (free), simple that focused on:~~ - ~~Name lookup.~~ - ~~Date lookup.~~ - ~~Wildcard search (Ann* find all names starting with Ann).~~ ## ~~API design~~ ~~Easy and clear separation between search and date lookup.~~ - ~~/api/namnsdag~~ - ~~/api/namnsdag?sök=anna~~ - ~~/api/namnsdag?sök=anna~~ - ~~/api/namnsdag?datum=2026-12-09~~
Collaborator

After investigating Workgroup further, it does not appear to be a real JSON API despite what the website states. The data seems to be loaded client-side via JavaScript. I will continue looking into other APIs.

After investigating Workgroup further, it does not appear to be a real JSON API despite what the website states. The [data](https://workgroup.se/namnsdagar.js) seems to be loaded client-side via JavaScript. I will continue looking into other APIs.
Collaborator

Faboul API

Swedish days API (free), focused on:

  • Swedish holidays.
  • Name days.
  • Flag days.
  • Date-based lookup.

API design

Easy and structured with date endpoints.

Features

  • JSON support.
  • JSONP support.
  • HTTPS support.
## [Faboul API](https://sholiday.faboul.se/) Swedish days API (free), focused on: - Swedish holidays. - Name days. - Flag days. - Date-based lookup. ## API design Easy and structured with date endpoints. - [/dagar/v2.1/2015](https://sholiday.faboul.se/dagar/v2.1/2015) (year). - [/dagar/v2.1/2015/02](https://sholiday.faboul.se/dagar/v2.1/2015/02) (month). - [/dagar/v2.1/2015/01/06](http://sholiday.faboul.se/dagar/v2.1/2015/01/06) (date). - /dagar/v2.1/2015?callback=dinmetod (JSONP). ## Features - JSON support. - JSONP support. - HTTPS support.
Collaborator

Conclusion

Faboul API is the better choice. It returns well-structured JSON data, unlike the Damberg API, whose responses are less organized.

Faboul also uses clearer endpoints while offering additional calendar features such as:

  • Swedish holidays
  • Flag days

Another downside of the Damberg API is that its name day data does not always align with "standard" Swedish name days, with some dates containing more than six names (link).

## Conclusion Faboul API is the better choice. It returns well-structured JSON data, unlike the Damberg API, whose responses are less organized. Faboul also uses clearer endpoints while offering additional calendar features such as: - Swedish holidays - Flag days Another downside of the Damberg API is that its name day data does not always align with "standard" Swedish name days, with some dates containing more than six names ([link](https://www.damberg.one/blogg/2024/namnsdagar/)).
Author
Collaborator

Requesting review from @f21marfo

Requesting review from @f21marfo
Collaborator

Review on #974

Whats done

Tested endpoints on Windows 11 25H2 using Edge

  • Damberg Namsdag API's do not return true JSON results.
    • Name endpoint produces a JSON that is often polluted with php-error codes.
  • Faboul API does return true JSON results.

Conclusion

  • The research appears sound and I concur with the recommendation of Faboul API over Damberg, the later of which is wholly unsuitable. Especially since the one and only endpoint that yields a true JSON, is frequently polluted.
  • Of additional note, that should be mentioned, is that the Faboul API JSON's are nested and contain nested key-value pairs as well as nested arrays. I have enclosed an indented version output from the date example above, for clarity.
{
	"cachetid":"2026-05-21 10:54:20","version":"2.1",
	"uri":"\/dagar\/v2.1\/2015\/01\/06",
	"startdatum":"2015-01-06",
	"slutdatum":"2015-01-06",
	"dagar":[
	{
		"datum":"2015-01-06",
		"veckodag":"Tisdag",
		"arbetsfri dag":"Ja",
		"r\u00f6d dag":"Ja",
		"vecka":"02",
		"dag i vecka":"2",
		"helgdag":"Trettondedag jul",
		"namnsdag":["Kasper","Melker","Baltsar"],
		"flaggdag":""
	}]
}
# Review on #974 ## Whats done ### Tested endpoints on Windows 11 25H2 using Edge + Damberg Namsdag API's do not return true JSON results. + Name endpoint produces a JSON that is often polluted with php-error codes. + Faboul API does return true JSON results. ## Conclusion + The research appears sound and I concur with the recommendation of Faboul API over Damberg, the later of which is wholly unsuitable. Especially since the one and only endpoint that yields a true JSON, is frequently polluted. + Of additional note, that should be mentioned, is that the Faboul API JSON's are nested and contain nested key-value pairs as well as nested arrays. I have enclosed an indented version output from the date example above, for clarity. ``` { "cachetid":"2026-05-21 10:54:20","version":"2.1", "uri":"\/dagar\/v2.1\/2015\/01\/06", "startdatum":"2015-01-06", "slutdatum":"2015-01-06", "dagar":[ { "datum":"2015-01-06", "veckodag":"Tisdag", "arbetsfri dag":"Ja", "r\u00f6d dag":"Ja", "vecka":"02", "dag i vecka":"2", "helgdag":"Trettondedag jul", "namnsdag":["Kasper","Melker","Baltsar"], "flaggdag":"" }] } ```
Sign in to join this conversation.
No milestone
No project
No assignees
3 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Andras/BoundlessFlowCampus2K#974
No description provided.