
Make Your First Public Holidays API Request in Five Minutes
You can make your first public holidays request in about five minutes. You need an account, your API key and one command. This guide walks through each step and explains the errors you are most likely to see.
Step 1: Create an account
Go to the sign-up page and create an account. The free plan includes 100 calls a month and needs no payment details. Some accounts ask you to confirm your email address first, so check your inbox if you are asked.
Step 2: Find your API key
Log in and open the dashboard. The API KEY section shows your key. Use the copy button to copy it.
Keep the key private. Anyone with the key can use your calls. If you think it has leaked, choose Regenerate on the dashboard. This creates a new key, and the old key stops working straight away, so update your applications with the new one.
The dashboard also has an API tester. Paste a request into it to see the response without using a terminal.
Step 3: Make the request
Replace YOUR_API_KEY with your key and run this command in a terminal:
curl "https://holidaysmap.com/api/v1/holidays?key=YOUR_API_KEY&code=RO&date=01-01-2026"
The request asks for the holidays in Romania (code=RO) on 1 January 2026. The response is JSON:
{
"count": 1,
"holidays": [
{
"name": "New Year's Day",
"date": "01-01-2026",
"is_public": true,
"country": "Romania",
"country_code": "RO"
}
]
}
If the date has no holiday, holidays is an empty list and the request still succeeds. An empty list is a regular working day, not an error.
Store the key safely
Do not paste your key into source code, and do not commit it to a repository. Store it as an environment variable and read it in your code:
const key = process.env.HOLIDAYS_API_KEY;
import os
key = os.environ["HOLIDAYS_API_KEY"]
Errors you may see
- 401 with “Missing api key”: the request has no
keyparameter. Add it to the URL. - 401 with “Invalid api key”: the key is wrong or was regenerated. Copy the current key from the dashboard.
- 400 with “Provide at least one of: country, code”: the request needs a country code or a country name.
- 400 with “Unsupported date format”: the
formatvalue is not one of the supported formats. The documentation lists them. - 403 with “User plan must be at least Premium”: date ranges (
startandend) need the Premium plan. Usedatefor single days, or upgrade. - 429 with “Too many requests”: you sent too many requests in one minute. Wait a minute and try again, and cache your results.
- 429 with “Account limit exceeded”: you used all the calls of your plan this month. It resets at the start of the next month, or you can upgrade.
The usage limits article explains the monthly limit and the rate limit in more detail.
Next steps
- Read the API documentation for every parameter, including
startandendfor date ranges. - Find the code for your country on the supported countries page.
- Check how the response fields work in the JSON format guide.
- Look at the pricing page when you need more than 100 calls a month.