bitwarden_pam/pam_client.rs
1use bitwarden_core::{Client, FromClient};
2#[cfg(feature = "wasm")]
3use wasm_bindgen::prelude::*;
4
5/// Entry point for Privileged Access Management (PAM) operations.
6#[derive(Clone, FromClient)]
7#[cfg_attr(feature = "wasm", wasm_bindgen)]
8pub struct PamClient {}
9
10/// Extension trait that exposes [`PamClient`] on [`Client`].
11pub trait PamClientExt {
12 /// Returns a [`PamClient`] backed by this client.
13 fn pam(&self) -> PamClient;
14}
15
16impl PamClientExt for Client {
17 fn pam(&self) -> PamClient {
18 PamClient::from_client(self)
19 }
20}