met_office_api/apis/
configuration.rs1#[derive(Debug, Clone)]
14pub struct Configuration {
15 pub base_path: String,
16 pub user_agent: Option<String>,
17 pub client: reqwest::Client,
18 pub basic_auth: Option<BasicAuth>,
19 pub oauth_access_token: Option<String>,
20 pub bearer_access_token: Option<String>,
21 pub api_key: Option<ApiKey>,
22 pub api_client: Option<ApiKey>,
23 }
25
26pub type BasicAuth = (String, Option<String>);
27
28#[derive(Debug, Clone)]
29pub struct ApiKey {
30 pub prefix: Option<String>,
31 pub key: String,
32}
33
34
35impl Configuration {
36 pub fn new() -> Configuration {
37 Configuration::default()
38 }
39}
40
41impl Default for Configuration {
42 fn default() -> Self {
43 Configuration {
44 base_path: "https://api-metoffice.apiconnect.ibmcloud.com/v0".to_owned(),
45 user_agent: Some("OpenAPI-Generator/1.0.1/rust".to_owned()),
46 client: reqwest::Client::new(),
47 basic_auth: None,
48 oauth_access_token: None,
49 bearer_access_token: None,
50 api_key: None,
51 api_client: None,
52
53 }
54 }
55}