Struct chef_api::api_client::ApiClient
[−]
[src]
pub struct ApiClient { pub config: Config, pub client: Rc<HyperClient<HttpsConnector<HttpConnector>>>, pub core: Rc<RefCell<Core>>, }
Struct used to start requests to the Chef Server API.
Fields
config: Config
Configuration for the client, containing credentials
client: Rc<HyperClient<HttpsConnector<HttpConnector>>>
The Hyper HTTP Client.
core: Rc<RefCell<Core>>
The async core
Methods
impl ApiClient
[src]
fn new(config: Config) -> Result<Self, Error>
[src]
Create a new ApiClient struct. It takes a Config
type. Typically one would use
from_credentials
rather than calling this directly.
fn from_credentials(profile: Option<&str>) -> Result<Self, Error>
[src]
Create a new ApiClient
struct using a set of credentials as defined in Chef RFC 99.
Accepts an Option<String>
containing the name of a credentials profile.
fn clients(&self) -> ClientsQuery
[src]
Generate a new $type request.
fn containers(&self) -> ContainersQuery
[src]
Generate a new $type request.
fn controls(&self) -> ControlsQuery
[src]
Generate a new $type request.
fn cookbook_artifacts(&self) -> CookbookArtifactsQuery
[src]
Generate a new $type request.
fn cookbooks(&self) -> CookbooksQuery
[src]
Generate a new $type request.
fn data(&self) -> DataQuery
[src]
Generate a new $type request.
fn environments(&self) -> EnvironmentsQuery
[src]
Generate a new $type request.
fn groups(&self) -> GroupsQuery
[src]
Generate a new $type request.
fn nodes(&self) -> NodesQuery
[src]
Generate a new $type request.
fn policies(&self) -> PoliciesQuery
[src]
Generate a new $type request.
fn policy_groups(&self) -> PolicyGroupsQuery
[src]
Generate a new $type request.
fn principals(&self) -> PrincipalsQuery
[src]
Generate a new $type request.
fn roles(&self) -> RolesQuery
[src]
Generate a new $type request.
fn sandboxes(&self) -> SandboxesQuery
[src]
Generate a new $type request.
fn search(&self) -> SearchQuery
[src]
Generate a new $type request.
fn universe(&self) -> UniverseQuery
[src]
Generate a new $type request.
fn users(&self) -> UsersQuery
[src]
Generate a new $type request.
fn server_organizations(&self) -> ServerOrganizationsQuery
[src]
Generate a new $type request.
fn server_users(&self) -> ServerUsersQuery
[src]
Generate a new $type request.
fn server_requests(&self) -> ServerRequestsQuery
[src]
Generate a new $type request.