pub trait RequestInfo {
    const BASE_URL: &'static str;

    // Required method
    fn client(&self) -> &Client;
}
Expand description

Trait to provide some basic info about API

Required Associated Constants§

source

const BASE_URL: &'static str

The base URL for the requests.

Required Methods§

source

fn client(&self) -> &Client

Returns the reqwest::Client instance associated with the API client.

The client is used to send HTTP requests to the API.

Examples
fn main() {
    let api_client = APIClient::new();
    let client = api_client.client();

    // Use the client to make HTTP requests
    // ...
}

Implementors§