bitwarden_api_base/configuration.rs
1//! Configuration types for API clients.
2
3/// Configuration for an API client.
4///
5/// This struct provides all the configuration options needed for making
6/// authenticated HTTP requests to Bitwarden APIs.
7#[derive(Debug, Clone)]
8pub struct Configuration {
9 /// Base URL path for the API (e.g., "<https://api.bitwarden.com>" or "<https://identity.bitwarden.com>").
10 pub base_path: String,
11 /// HTTP client with middleware support.
12 pub client: reqwest_middleware::ClientWithMiddleware,
13 /// OAuth access token for authentication.
14 pub oauth_access_token: Option<String>,
15
16 /// User-Agent header value to be sent with requests.
17 /// This is deprecated and kept only for backward compatibility.
18 /// Instead we recommend setting the User-Agent via middleware
19 /// or reqwest's default headers.
20 pub user_agent: Option<String>,
21}