https://github.com/guibranco/holiday-api-rust
📆 ⚙️ Holiday API Rust SDK (API Client)
https://github.com/guibranco/holiday-api-rust
api api-client api-client-rust client-wrapper hacktoberfest holiday-api-rust holidayapi rust
Last synced: 2 months ago
JSON representation
📆 ⚙️ Holiday API Rust SDK (API Client)
- Host: GitHub
- URL: https://github.com/guibranco/holiday-api-rust
- Owner: guibranco
- License: mit
- Created: 2020-01-21T07:06:18.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2025-02-21T18:53:31.000Z (5 months ago)
- Last Synced: 2025-04-15T09:09:01.707Z (3 months ago)
- Topics: api, api-client, api-client-rust, client-wrapper, hacktoberfest, holiday-api-rust, holidayapi, rust
- Language: Rust
- Homepage: http://guilherme.stracini.com.br/holiday-api-rust/
- Size: 132 KB
- Stars: 3
- Watchers: 1
- Forks: 1
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# HolidayAPI Rust client
📆⚙️ [HolidayAPI](https://holidayapi.com/docs) client wrapper for Rust projects.


[](https://wakatime.com/badge/github/guibranco/holiday-api-rust)[](https://codeclimate.com/github/guibranco/holiday-api-rust/maintainability)
[](https://codeclimate.com/github/guibranco/holiday-api-rust/test_coverage)
[](https://www.codefactor.io/repository/github/guibranco/holiday-api-rust)| Service | Status |
| ------- | :----: |
| AppVeyor CI | [](https://ci.appveyor.com/project/guibranco/holiday-api-rust/branch/main) |
| crates.io | [](https://crates.io/crates/holiday-api-rust) |Pure Rust bindings to the [Holiday API](https://holidayapi.com).
## Dependencies and support
`holiday-api-rust` is intended to work on all tier 1 supported Rust systems:
- MacOSX
- Linux
- Windows## Minimum Compiler Version
Due to the use of certain features `holiday-api-rust` requires `rustc` version 1.18 or
higher.## Getting Started
Add the following to your `Cargo.toml`
```toml
[dependencies]
holiday_api_rust = "0.3.1"
serde_json = "1.0"
```Then in your `lib.rs` or `main.rs` file add:
```rust
extern crate holiday_api_rust;let client = HolidayAPIClient::new("HolidayAPI key here");
match client.search_holidays("2019", "BR") {
Err(e) => eprintln!("{:?}", e),
Ok(holidays) => {
for holiday in holidays {
println!("Holiday: {} | Date: {} | Country: {}", holiday.name, holiday.date, holiday.country);
}
}
}
```## License
Licensed under
- MIT license ([LICENSE](https://github.com/guibranco/holiday-api-rust/blob/main/LICENSE) or [http://opensource.org/licenses/MIT](http://opensource.org/licenses/MIT))