{"id":35214501,"url":"https://github.com/headwindz/public-holidays","last_synced_at":"2026-04-29T03:32:02.377Z","repository":{"id":330577227,"uuid":"1123224336","full_name":"headwindz/public-holidays","owner":"headwindz","description":"public holidays open apis","archived":false,"fork":false,"pushed_at":"2026-01-24T10:05:04.000Z","size":392,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-01-24T20:05:19.669Z","etag":null,"topics":["openapi","public-holidays"],"latest_commit_sha":null,"homepage":"https://public-holidays.toolhub.run/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/headwindz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-12-26T12:34:01.000Z","updated_at":"2026-01-24T10:05:08.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/headwindz/public-holidays","commit_stats":null,"previous_names":["headwindz/public-holidays"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/headwindz/public-holidays","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/headwindz%2Fpublic-holidays","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/headwindz%2Fpublic-holidays/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/headwindz%2Fpublic-holidays/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/headwindz%2Fpublic-holidays/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/headwindz","download_url":"https://codeload.github.com/headwindz/public-holidays/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/headwindz%2Fpublic-holidays/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32409087,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-29T02:37:21.628Z","status":"ssl_error","status_checked_at":"2026-04-29T02:36:50.947Z","response_time":110,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["openapi","public-holidays"],"created_at":"2025-12-29T21:20:15.287Z","updated_at":"2026-04-29T03:32:02.371Z","avatar_url":"https://github.com/headwindz.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Public holidays API\n\nA comprehensive public holidays API providing holiday data for 60 countries and regions across multiple years (2020-2026). Built with Next.js and TypeScript.\n\n🌐 **Doc**: [https://public-holidays.toolhub.run/](https://public-holidays.toolhub.run/)\n\n## Features\n\n- 🌍 **60 countries \u0026 regions** - Comprehensive coverage of public holidays worldwide\n- 📅 **Multiple years** - Data available for 2020, 2021, 2022, 2023, 2024, 2025, and 2026\n- 🚀 **Fast API** - Built on Next.js API routes for optimal performance\n- 🎨 **Interactive documentation** - Built-in API tester and documentation\n- 📱 **Responsive design** - Works seamlessly on all devices\n\n## Supported countries\n\nThe API covers 60 countries and regions including:\n\n- 🇨🇳 China (cn)\n- 🇺🇸 United States (us)\n- 🇬🇧 United Kingdom (uk)\n- 🇨🇦 Canada (ca)\n- 🇦🇺 Australia (au)\n- 🇩🇪 Germany (de)\n- 🇫🇷 France (fr)\n- 🇯🇵 Japan (jp)\n- 🇮🇳 India (in)\n- 🇧🇷 Brazil (br)\n- 🇲🇽 Mexico (mx)\n- And 48 more...\n\nSee the [data directory](./data/2025) for the complete list of country codes.\n\n## API usage\n\n### Endpoint\n\n```\nGET https://public-holidays.toolhub.run/api/public-holidays?year={year}\u0026code={code}\n```\n\n### Parameters\n\n- `year` (required) - The year for which to retrieve holidays (e.g., 2020, 2021, 2022, 2023, 2024, 2025, 2026)\n- `code` (required) - The ISO 3166-1 alpha-2 country/region code (e.g., cn, us, uk, ca)\n\n### Example request\n\n```bash\ncurl \"https://public-holidays.toolhub.run/api/public-holidays?year=2025\u0026code=cn\"\n```\n\n### Example response\n\n```json\n{\n  \"data\": [\n    {\n      \"localName\": \"元旦\",\n      \"name\": \"New Year's Day\",\n      \"code\": \"CN\",\n      \"fixed\": true,\n      \"global\": true,\n      \"counties\": null,\n      \"launchYear\": null,\n      \"types\": [\"Public\"],\n      \"startDate\": \"2025-01-01T00:00:00.000Z\",\n      \"endDate\": \"2025-01-01T23:59:59.999Z\"\n    },\n    {\n      \"localName\": \"春节\",\n      \"name\": \"Spring Festival (Chinese New Year)\",\n      \"code\": \"CN\",\n      \"fixed\": false,\n      \"global\": true,\n      \"counties\": null,\n      \"launchYear\": null,\n      \"types\": [\"Public\"],\n      \"startDate\": \"2025-01-28T00:00:00.000Z\",\n      \"endDate\": \"2025-02-04T23:59:59.999Z\"\n    },\n    {\n      \"localName\": \"清明节\",\n      \"name\": \"Tomb Sweeping Day (Qingming Festival)\",\n      \"code\": \"CN\",\n      \"fixed\": false,\n      \"global\": true,\n      \"counties\": null,\n      \"launchYear\": null,\n      \"types\": [\"Public\"],\n      \"startDate\": \"2025-04-04T00:00:00.000Z\",\n      \"endDate\": \"2025-04-06T23:59:59.999Z\"\n    },\n    {\n      \"localName\": \"劳动节\",\n      \"name\": \"Labor Day\",\n      \"code\": \"CN\",\n      \"fixed\": true,\n      \"global\": true,\n      \"counties\": null,\n      \"launchYear\": null,\n      \"types\": [\"Public\"],\n      \"startDate\": \"2025-05-01T00:00:00.000Z\",\n      \"endDate\": \"2025-05-05T23:59:59.999Z\"\n    },\n    {\n      \"localName\": \"端午节\",\n      \"name\": \"Dragon Boat Festival\",\n      \"code\": \"CN\",\n      \"fixed\": false,\n      \"global\": true,\n      \"counties\": null,\n      \"launchYear\": null,\n      \"types\": [\"Public\"],\n      \"startDate\": \"2025-05-31T00:00:00.000Z\",\n      \"endDate\": \"2025-06-02T23:59:59.999Z\"\n    },\n    {\n      \"localName\": \"国庆节 / 中秋节\",\n      \"name\": \"National Day \u0026 Mid-Autumn Festival\",\n      \"code\": \"CN\",\n      \"fixed\": true,\n      \"global\": true,\n      \"counties\": null,\n      \"launchYear\": 1949,\n      \"types\": [\"Public\"],\n      \"startDate\": \"2025-10-01T00:00:00.000Z\",\n      \"endDate\": \"2025-10-08T23:59:59.999Z\"\n    }\n  ]\n}\n```\n\n### Error responses\n\n**400 bad request** - Missing required parameters\n\n```json\n{\n  \"error\": \"Both year and code parameters are required\"\n}\n```\n\n**404 not found** - Data not available for specified year/country\n\n```json\n{\n  \"error\": \"Data not found for the specified year and country/region code\"\n}\n```\n\n## Getting started\n\n### Prerequisites\n\n- Node.js 18+\n- pnpm (recommended) or npm\n\n### Installation\n\n1. Clone the repository:\n\n```bash\ngit clone https://github.com/headwindz/public-holidays\ncd public-holidays\n```\n\n2. Install dependencies:\n\n```bash\npnpm install\n```\n\n3. Run the development server:\n\n```bash\npnpm dev\n```\n\n4. Open [http://localhost:3000](http://localhost:3000) to view the application\n\n### Build for production\n\n```bash\npnpm build\npnpm start\n```\n\n## Project structure\n\n```\npublic-holidays/\n├── app/\n│   ├── api/\n│   │   └── public-holidays/\n│   │       └── route.ts           # API endpoint\n│   ├── globals.css                # Global styles\n│   ├── layout.tsx                 # Root layout\n│   └── page.tsx                   # Landing page\n├── data/\n│   ├── 2020/                      # 2020 holiday data\n│   ├── 2021/                      # 2021 holiday data\n│   ├── 2022/                      # 2022 holiday data\n│   ├── 2023/                      # 2023 holiday data\n│   ├── 2024/                      # 2024 holiday data\n│   └── 2025/                      # 2025 holiday data\n│       ├── cn/\n│       │   └── index.json\n│       ├── us/\n│       │   └── index.json\n│       └── ...                    # 60 countries total\n└── package.json\n```\n\n## Technology stack\n\n- **Framework**: [Next.js 15](https://nextjs.org) with App Router\n- **Language**: TypeScript\n- **Styling**: Tailwind CSS\n- **Package manager**: pnpm\n\n## Data sources\n\nHoliday data is generated by AI and includes:\n\n- Fixed national holidays\n- Movable holidays (Easter, Lunar New Year, Ramadan, etc.)\n- Holiday durations\n- Bank holidays\n\n**Note**: While the data is generated with care, please verify critical dates with official government sources for production use. If you find any discrepancies, feel free to open an issue.\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a [Issue](https://github.com/headwindz/public-holidays/issues) or [Pull Request](https://github.com/headwindz/public-holidays/pulls).\n\n## License\n\nThis project is open source and available under the MIT License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheadwindz%2Fpublic-holidays","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fheadwindz%2Fpublic-holidays","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheadwindz%2Fpublic-holidays/lists"}