4 releases
0.2.0 | Jan 21, 2025 |
---|---|
0.1.5 | Dec 21, 2024 |
#703 in Web programming
104 downloads per month
105KB
2.5K
SLoC
nadeo-api
A library to making using the Nadeo API easy.
use nadeo_api_rs::{prelude::*, user_agent_auto};
Usage
- Create a
NadeoCredentials
. - Create a
UserAgentDetails
-- easiest way viauser_agent_auto!
macro. - Create a
NadeoClient
viaNadeoClient::create
. - Call methods like
let cotd = client.get_cup_of_the_day()?;
For lower-level access, see NadeoApiClient::run_*
methods.
For examples of how to do more complex low-level requests, see LiveApiClient::get_map_group_leaderboard
for an example.
lib.rs
:
Create a NadeoClient to interact with the Nadeo API.
Use NadeoClient::create to create a new client.
You will also need to create NadeoCredentials and UserAgentDetails (see [user_agent_auto] and [user_agent_auto_ver])
API methods are defined on traits: live::LiveApiClient, meet::MeetApiClient, core::CoreApiClient.
Dependencies
~9–21MB
~273K SLoC