Simple API that provides public holidays information in Japan.
GET /{year}
lists holidays in a year.
Example: list holidays in 2021.
curl https://holidays-jp.shogo82148.com/2021 | jq .
{
"holidays": [
{
"date": "2021-01-01",
"name": "元日"
},
{
"date": "2021-01-11",
"name": "成人の日"
},
{
"date": "2021-02-11",
"name": "建国記念の日"
},
(snip)
{
"date": "2021-11-23",
"name": "勤労感謝の日"
}
]
}
GET /{year}/{month}
lists holidays in a year.
Example: list holidays in January 2021.
curl https://holidays-jp.shogo82148.com/2021/01 | jq .
{
"holidays": [
{
"date": "2021-01-01",
"name": "元日"
},
{
"date": "2021-01-11",
"name": "成人の日"
}
]
}
GET /holidays?from={2006-01-02}&to={2006-01-02}
lists holidays in the range.
Example: list holidays in January 2021.
curl 'https://holidays-jp.shogo82148.com/holidays?from=2021-01-01&to=2021-01-31' | jq .
{
"holidays": [
{
"date": "2021-01-01",
"name": "元日"
},
{
"date": "2021-01-11",
"name": "成人の日"
}
]
}
GET /{year}/{month}/{day}
returns whether the day is a holiday.
Example: January 1st, 2021 was a holiday. The api returns information about the holiday.
curl https://holidays-jp.shogo82148.com/2021/01/01 | jq .
{
"holidays": [
{
"date": "2021-01-01",
"name": "元日"
}
]
}
Example: February 1st, 2021 was not a holiday. The api returns an empty list in this case.
curl https://holidays-jp.shogo82148.com/2021/02/01 | jq .
{
"holidays": []
}
- 国民の祝日について - 内閣府 (Kokumin no Shukujitsu ni Tsuite: About Holidays in Japan - Cabinet Office, Government of Japan)
- 国民の祝日に関する法律 - e-Gov 法令検索 (Kokumin no Shukujitsu ni kansuru Horitsu: The Law about Holidays in Japan)
- 長沢 工(1999) "日の出・日の入りの計算 天体の出没時刻の求め方" 株式会社地人書館