nadeo_api_rs::core

Trait CoreApiClient

Source
pub trait CoreApiClient: NadeoApiClient {
    // Provided methods
    async fn get_zones(&self) -> Result<Vec<Zone>, Box<dyn Error>> { ... }
    async fn get_zone_tree(&self) -> Result<&ZoneTree, Box<dyn Error>> { ... }
    async fn get_user_zones<T: Into<String> + Clone>(
        &self,
        player_ids: &[T],
    ) -> Result<HashMap<String, PlayerZone>, Box<dyn Error + Send + Sync>> { ... }
}
Expand description

API calls for the Core API

Provided Methods§

Source

async fn get_zones(&self) -> Result<Vec<Zone>, Box<dyn Error>>

Source

async fn get_zone_tree(&self) -> Result<&ZoneTree, Box<dyn Error>>

Get the zone tree – cached!

Source

async fn get_user_zones<T: Into<String> + Clone>( &self, player_ids: &[T], ) -> Result<HashMap<String, PlayerZone>, Box<dyn Error + Send + Sync>>

Get players’ zone details

https://webservices.openplanet.dev/core/accounts/zones

https://prod.trackmania.core.nadeo.online/accounts/zones/?accountIdList={accountIdList}

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§