highlevel_api/apis/funnels/
client.rs1use std::sync::Arc;
2use crate::{error::Result, http::HttpClient};
3use super::types::*;
4
5pub struct FunnelsApi {
6 http: Arc<HttpClient>,
7}
8
9impl FunnelsApi {
10 pub fn new(http: Arc<HttpClient>) -> Self {
11 Self { http }
12 }
13
14 pub async fn list(&self, params: &GetFunnelsParams) -> Result<GetFunnelsResponse> {
15 self.http.get_with_query("/funnels/funnel/list", params).await
16 }
17
18 pub async fn get_pages(
19 &self,
20 params: &GetFunnelPagesParams,
21 ) -> Result<GetFunnelPagesResponse> {
22 self.http.get_with_query("/funnels/page", params).await
23 }
24}