pub struct MatomoClient(/* private fields */);Expand description
A reqwest-based Matomo API client and the ergonomic entry point.
Implementations§
Source§impl MatomoClient
impl MatomoClient
pub fn builder() -> ClientBuilder
pub fn api(&self) -> ApiHandle<'_>
pub fn visits_summary(&self) -> VisitsSummaryHandle<'_>
pub fn live(&self) -> LiveHandle<'_>
pub fn actions(&self) -> ActionsHandle<'_>
pub fn referrers(&self) -> ReferrersHandle<'_>
Sourcepub async fn call(&self, method: &'static str, params: &Params) -> Result<Value>
pub async fn call(&self, method: &'static str, params: &Params) -> Result<Value>
Parse once into a Value, branching on Matomo’s error envelope.
Sourcepub async fn call_typed<T: DeserializeOwned>(
&self,
method: &'static str,
params: &Params,
) -> Result<T>
pub async fn call_typed<T: DeserializeOwned>( &self, method: &'static str, params: &Params, ) -> Result<T>
Typed call. Single parse: bytes → Value once, error-check, then decode.
Source§impl MatomoClient
impl MatomoClient
Trait Implementations§
Source§impl Client for MatomoClient
impl Client for MatomoClient
Source§impl Clone for MatomoClient
impl Clone for MatomoClient
Source§fn clone(&self) -> MatomoClient
fn clone(&self) -> MatomoClient
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl !RefUnwindSafe for MatomoClient
impl !UnwindSafe for MatomoClient
impl Freeze for MatomoClient
impl Send for MatomoClient
impl Sync for MatomoClient
impl Unpin for MatomoClient
impl UnsafeUnpin for MatomoClient
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more