rustifi 1.0.0

Open source Rust library to interface with Ubiquiti's UniFi Controller API.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
use crate::api::endpoint::{Endpoint, HttpMethod};
use crate::models::Site;
use crate::response::ApiResponse;

/// Fetches all sites from the controller.
#[derive(Debug, Default)]
pub struct GetSites;

impl Endpoint for GetSites {
    const PATH: &'static str = "sites";
    const METHOD: HttpMethod = HttpMethod::Get;
    type Response = ApiResponse<Vec<Site>>;
}