hab_rs_api_client/apis/
mod.rs

1use std::error;
2use std::fmt;
3
4#[derive(Debug, Clone)]
5pub struct ResponseContent<T> {
6    pub status: reqwest::StatusCode,
7    pub content: String,
8    pub entity: Option<T>,
9}
10
11#[derive(Debug)]
12pub enum Error<T> {
13    Reqwest(reqwest::Error),
14    ReqwestMiddleware(reqwest_middleware::Error),
15    Serde(serde_json::Error),
16    Io(std::io::Error),
17    ResponseError(ResponseContent<T>),
18}
19
20impl<T> fmt::Display for Error<T> {
21    fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
22        let (module, e) = match self {
23            Error::Reqwest(e) => ("reqwest", e.to_string()),
24            Error::ReqwestMiddleware(e) => ("reqwest-middleware", e.to_string()),
25            Error::Serde(e) => ("serde", e.to_string()),
26            Error::Io(e) => ("IO", e.to_string()),
27            Error::ResponseError(e) => ("response", format!("status code {}", e.status)),
28        };
29        write!(f, "error in {}: {}", module, e)
30    }
31}
32
33impl<T: fmt::Debug> error::Error for Error<T> {
34    fn source(&self) -> Option<&(dyn error::Error + 'static)> {
35        Some(match self {
36            Error::Reqwest(e) => e,
37            Error::ReqwestMiddleware(e) => e,
38            Error::Serde(e) => e,
39            Error::Io(e) => e,
40            Error::ResponseError(_) => return None,
41        })
42    }
43}
44
45impl<T> From<reqwest::Error> for Error<T> {
46    fn from(e: reqwest::Error) -> Self {
47        Error::Reqwest(e)
48    }
49}
50
51impl<T> From<reqwest_middleware::Error> for Error<T> {
52    fn from(e: reqwest_middleware::Error) -> Self {
53        Error::ReqwestMiddleware(e)
54    }
55}
56
57impl<T> From<serde_json::Error> for Error<T> {
58    fn from(e: serde_json::Error) -> Self {
59        Error::Serde(e)
60    }
61}
62
63impl<T> From<std::io::Error> for Error<T> {
64    fn from(e: std::io::Error) -> Self {
65        Error::Io(e)
66    }
67}
68
69pub fn urlencode<T: AsRef<str>>(s: T) -> String {
70    ::url::form_urlencoded::byte_serialize(s.as_ref().as_bytes()).collect()
71}
72
73pub fn parse_deep_object(prefix: &str, value: &serde_json::Value) -> Vec<(String, String)> {
74    if let serde_json::Value::Object(object) = value {
75        let mut params = vec![];
76
77        for (key, value) in object {
78            match value {
79                serde_json::Value::Object(_) => params.append(&mut parse_deep_object(
80                    &format!("{}[{}]", prefix, key),
81                    value,
82                )),
83                serde_json::Value::Array(array) => {
84                    for (i, value) in array.iter().enumerate() {
85                        params.append(&mut parse_deep_object(
86                            &format!("{}[{}][{}]", prefix, key, i),
87                            value,
88                        ));
89                    }
90                }
91                serde_json::Value::String(s) => {
92                    params.push((format!("{}[{}]", prefix, key), s.clone()))
93                }
94                _ => params.push((format!("{}[{}]", prefix, key), value.to_string())),
95            }
96        }
97
98        return params;
99    }
100
101    unimplemented!("Only objects are supported with style=deepObject")
102}
103
104/// Internal use only
105/// A content type supported by this client.
106#[allow(dead_code)]
107enum ContentType {
108    Json,
109    Text,
110    Unsupported(String),
111}
112
113impl From<&str> for ContentType {
114    fn from(content_type: &str) -> Self {
115        if content_type.starts_with("application") && content_type.contains("json") {
116            return Self::Json;
117        } else if content_type.starts_with("text/plain") {
118            return Self::Text;
119        } else {
120            return Self::Unsupported(content_type.to_string());
121        }
122    }
123}
124
125#[cfg(feature = "actions_api")]
126#[cfg_attr(docsrs, doc(cfg(feature = "actions_api")))]
127pub mod actions_api;
128#[cfg(feature = "addons_api")]
129#[cfg_attr(docsrs, doc(cfg(feature = "addons_api")))]
130pub mod addons_api;
131#[cfg(feature = "audio_api")]
132#[cfg_attr(docsrs, doc(cfg(feature = "audio_api")))]
133pub mod audio_api;
134#[cfg(feature = "auth_api")]
135#[cfg_attr(docsrs, doc(cfg(feature = "auth_api")))]
136pub mod auth_api;
137#[cfg(feature = "channel_types_api")]
138#[cfg_attr(docsrs, doc(cfg(feature = "channel_types_api")))]
139pub mod channel_types_api;
140#[cfg(feature = "config_descriptions_api")]
141#[cfg_attr(docsrs, doc(cfg(feature = "config_descriptions_api")))]
142pub mod config_descriptions_api;
143#[cfg(feature = "discovery_api")]
144#[cfg_attr(docsrs, doc(cfg(feature = "discovery_api")))]
145pub mod discovery_api;
146#[cfg(feature = "events_api")]
147#[cfg_attr(docsrs, doc(cfg(feature = "events_api")))]
148pub mod events_api;
149#[cfg(feature = "habpanel_api")]
150#[cfg_attr(docsrs, doc(cfg(feature = "habpanel_api")))]
151pub mod habpanel_api;
152#[cfg(feature = "iconsets_api")]
153#[cfg_attr(docsrs, doc(cfg(feature = "iconsets_api")))]
154pub mod iconsets_api;
155#[cfg(feature = "inbox_api")]
156#[cfg_attr(docsrs, doc(cfg(feature = "inbox_api")))]
157pub mod inbox_api;
158#[cfg(feature = "items_api")]
159#[cfg_attr(docsrs, doc(cfg(feature = "items_api")))]
160pub mod items_api;
161#[cfg(feature = "links_api")]
162#[cfg_attr(docsrs, doc(cfg(feature = "links_api")))]
163pub mod links_api;
164#[cfg(feature = "logging_api")]
165#[cfg_attr(docsrs, doc(cfg(feature = "logging_api")))]
166pub mod logging_api;
167#[cfg(feature = "module_types_api")]
168#[cfg_attr(docsrs, doc(cfg(feature = "module_types_api")))]
169pub mod module_types_api;
170#[cfg(feature = "persistence_api")]
171#[cfg_attr(docsrs, doc(cfg(feature = "persistence_api")))]
172pub mod persistence_api;
173#[cfg(feature = "profile_types_api")]
174#[cfg_attr(docsrs, doc(cfg(feature = "profile_types_api")))]
175pub mod profile_types_api;
176#[cfg(feature = "root_api")]
177#[cfg_attr(docsrs, doc(cfg(feature = "root_api")))]
178pub mod root_api;
179#[cfg(feature = "rules_api")]
180#[cfg_attr(docsrs, doc(cfg(feature = "rules_api")))]
181pub mod rules_api;
182#[cfg(feature = "services_api")]
183#[cfg_attr(docsrs, doc(cfg(feature = "services_api")))]
184pub mod services_api;
185#[cfg(feature = "sitemaps_api")]
186#[cfg_attr(docsrs, doc(cfg(feature = "sitemaps_api")))]
187pub mod sitemaps_api;
188#[cfg(feature = "systeminfo_api")]
189#[cfg_attr(docsrs, doc(cfg(feature = "systeminfo_api")))]
190pub mod systeminfo_api;
191#[cfg(feature = "tags_api")]
192#[cfg_attr(docsrs, doc(cfg(feature = "tags_api")))]
193pub mod tags_api;
194#[cfg(feature = "templates_api")]
195#[cfg_attr(docsrs, doc(cfg(feature = "templates_api")))]
196pub mod templates_api;
197#[cfg(feature = "thing_types_api")]
198#[cfg_attr(docsrs, doc(cfg(feature = "thing_types_api")))]
199pub mod thing_types_api;
200#[cfg(feature = "things_api")]
201#[cfg_attr(docsrs, doc(cfg(feature = "things_api")))]
202pub mod things_api;
203#[cfg(feature = "transformations_api")]
204#[cfg_attr(docsrs, doc(cfg(feature = "transformations_api")))]
205pub mod transformations_api;
206#[cfg(feature = "ui_api")]
207#[cfg_attr(docsrs, doc(cfg(feature = "ui_api")))]
208pub mod ui_api;
209#[cfg(feature = "uuid_api")]
210#[cfg_attr(docsrs, doc(cfg(feature = "uuid_api")))]
211pub mod uuid_api;
212#[cfg(feature = "voice_api")]
213#[cfg_attr(docsrs, doc(cfg(feature = "voice_api")))]
214pub mod voice_api;
215
216pub mod configuration;
217
218use std::sync::Arc;
219
220pub trait Api: Send + Sync {
221    #[cfg(feature = "actions_api")]
222    #[cfg_attr(docsrs, doc(cfg(feature = "actions_api")))]
223    fn actions_api(&self) -> &dyn actions_api::ActionsApi;
224    #[cfg(feature = "addons_api")]
225    #[cfg_attr(docsrs, doc(cfg(feature = "addons_api")))]
226    fn addons_api(&self) -> &dyn addons_api::AddonsApi;
227    #[cfg(feature = "audio_api")]
228    #[cfg_attr(docsrs, doc(cfg(feature = "audio_api")))]
229    fn audio_api(&self) -> &dyn audio_api::AudioApi;
230    #[cfg(feature = "auth_api")]
231    #[cfg_attr(docsrs, doc(cfg(feature = "auth_api")))]
232    fn auth_api(&self) -> &dyn auth_api::AuthApi;
233    #[cfg(feature = "channel_types_api")]
234    #[cfg_attr(docsrs, doc(cfg(feature = "channel_types_api")))]
235    fn channel_types_api(&self) -> &dyn channel_types_api::ChannelTypesApi;
236    #[cfg(feature = "config_descriptions_api")]
237    #[cfg_attr(docsrs, doc(cfg(feature = "config_descriptions_api")))]
238    fn config_descriptions_api(&self) -> &dyn config_descriptions_api::ConfigDescriptionsApi;
239    #[cfg(feature = "discovery_api")]
240    #[cfg_attr(docsrs, doc(cfg(feature = "discovery_api")))]
241    fn discovery_api(&self) -> &dyn discovery_api::DiscoveryApi;
242    #[cfg(feature = "events_api")]
243    #[cfg_attr(docsrs, doc(cfg(feature = "events_api")))]
244    fn events_api(&self) -> &dyn events_api::EventsApi;
245    #[cfg(feature = "habpanel_api")]
246    #[cfg_attr(docsrs, doc(cfg(feature = "habpanel_api")))]
247    fn habpanel_api(&self) -> &dyn habpanel_api::HabpanelApi;
248    #[cfg(feature = "iconsets_api")]
249    #[cfg_attr(docsrs, doc(cfg(feature = "iconsets_api")))]
250    fn iconsets_api(&self) -> &dyn iconsets_api::IconsetsApi;
251    #[cfg(feature = "inbox_api")]
252    #[cfg_attr(docsrs, doc(cfg(feature = "inbox_api")))]
253    fn inbox_api(&self) -> &dyn inbox_api::InboxApi;
254    #[cfg(feature = "items_api")]
255    #[cfg_attr(docsrs, doc(cfg(feature = "items_api")))]
256    fn items_api(&self) -> &dyn items_api::ItemsApi;
257    #[cfg(feature = "links_api")]
258    #[cfg_attr(docsrs, doc(cfg(feature = "links_api")))]
259    fn links_api(&self) -> &dyn links_api::LinksApi;
260    #[cfg(feature = "logging_api")]
261    #[cfg_attr(docsrs, doc(cfg(feature = "logging_api")))]
262    fn logging_api(&self) -> &dyn logging_api::LoggingApi;
263    #[cfg(feature = "module_types_api")]
264    #[cfg_attr(docsrs, doc(cfg(feature = "module_types_api")))]
265    fn module_types_api(&self) -> &dyn module_types_api::ModuleTypesApi;
266    #[cfg(feature = "persistence_api")]
267    #[cfg_attr(docsrs, doc(cfg(feature = "persistence_api")))]
268    fn persistence_api(&self) -> &dyn persistence_api::PersistenceApi;
269    #[cfg(feature = "profile_types_api")]
270    #[cfg_attr(docsrs, doc(cfg(feature = "profile_types_api")))]
271    fn profile_types_api(&self) -> &dyn profile_types_api::ProfileTypesApi;
272    #[cfg(feature = "root_api")]
273    #[cfg_attr(docsrs, doc(cfg(feature = "root_api")))]
274    fn root_api(&self) -> &dyn root_api::RootApi;
275    #[cfg(feature = "rules_api")]
276    #[cfg_attr(docsrs, doc(cfg(feature = "rules_api")))]
277    fn rules_api(&self) -> &dyn rules_api::RulesApi;
278    #[cfg(feature = "services_api")]
279    #[cfg_attr(docsrs, doc(cfg(feature = "services_api")))]
280    fn services_api(&self) -> &dyn services_api::ServicesApi;
281    #[cfg(feature = "sitemaps_api")]
282    #[cfg_attr(docsrs, doc(cfg(feature = "sitemaps_api")))]
283    fn sitemaps_api(&self) -> &dyn sitemaps_api::SitemapsApi;
284    #[cfg(feature = "systeminfo_api")]
285    #[cfg_attr(docsrs, doc(cfg(feature = "systeminfo_api")))]
286    fn systeminfo_api(&self) -> &dyn systeminfo_api::SysteminfoApi;
287    #[cfg(feature = "tags_api")]
288    #[cfg_attr(docsrs, doc(cfg(feature = "tags_api")))]
289    fn tags_api(&self) -> &dyn tags_api::TagsApi;
290    #[cfg(feature = "templates_api")]
291    #[cfg_attr(docsrs, doc(cfg(feature = "templates_api")))]
292    fn templates_api(&self) -> &dyn templates_api::TemplatesApi;
293    #[cfg(feature = "thing_types_api")]
294    #[cfg_attr(docsrs, doc(cfg(feature = "thing_types_api")))]
295    fn thing_types_api(&self) -> &dyn thing_types_api::ThingTypesApi;
296    #[cfg(feature = "things_api")]
297    #[cfg_attr(docsrs, doc(cfg(feature = "things_api")))]
298    fn things_api(&self) -> &dyn things_api::ThingsApi;
299    #[cfg(feature = "transformations_api")]
300    #[cfg_attr(docsrs, doc(cfg(feature = "transformations_api")))]
301    fn transformations_api(&self) -> &dyn transformations_api::TransformationsApi;
302    #[cfg(feature = "ui_api")]
303    #[cfg_attr(docsrs, doc(cfg(feature = "ui_api")))]
304    fn ui_api(&self) -> &dyn ui_api::UiApi;
305    #[cfg(feature = "uuid_api")]
306    #[cfg_attr(docsrs, doc(cfg(feature = "uuid_api")))]
307    fn uuid_api(&self) -> &dyn uuid_api::UuidApi;
308    #[cfg(feature = "voice_api")]
309    #[cfg_attr(docsrs, doc(cfg(feature = "voice_api")))]
310    fn voice_api(&self) -> &dyn voice_api::VoiceApi;
311}
312
313pub struct ApiClient {
314    #[cfg(feature = "actions_api")]
315    #[cfg_attr(docsrs, doc(cfg(feature = "actions_api")))]
316    actions_api: Box<dyn actions_api::ActionsApi>,
317    #[cfg(feature = "addons_api")]
318    #[cfg_attr(docsrs, doc(cfg(feature = "addons_api")))]
319    addons_api: Box<dyn addons_api::AddonsApi>,
320    #[cfg(feature = "audio_api")]
321    #[cfg_attr(docsrs, doc(cfg(feature = "audio_api")))]
322    audio_api: Box<dyn audio_api::AudioApi>,
323    #[cfg(feature = "auth_api")]
324    #[cfg_attr(docsrs, doc(cfg(feature = "auth_api")))]
325    auth_api: Box<dyn auth_api::AuthApi>,
326    #[cfg(feature = "channel_types_api")]
327    #[cfg_attr(docsrs, doc(cfg(feature = "channel_types_api")))]
328    channel_types_api: Box<dyn channel_types_api::ChannelTypesApi>,
329    #[cfg(feature = "config_descriptions_api")]
330    #[cfg_attr(docsrs, doc(cfg(feature = "config_descriptions_api")))]
331    config_descriptions_api: Box<dyn config_descriptions_api::ConfigDescriptionsApi>,
332    #[cfg(feature = "discovery_api")]
333    #[cfg_attr(docsrs, doc(cfg(feature = "discovery_api")))]
334    discovery_api: Box<dyn discovery_api::DiscoveryApi>,
335    #[cfg(feature = "events_api")]
336    #[cfg_attr(docsrs, doc(cfg(feature = "events_api")))]
337    events_api: Box<dyn events_api::EventsApi>,
338    #[cfg(feature = "habpanel_api")]
339    #[cfg_attr(docsrs, doc(cfg(feature = "habpanel_api")))]
340    habpanel_api: Box<dyn habpanel_api::HabpanelApi>,
341    #[cfg(feature = "iconsets_api")]
342    #[cfg_attr(docsrs, doc(cfg(feature = "iconsets_api")))]
343    iconsets_api: Box<dyn iconsets_api::IconsetsApi>,
344    #[cfg(feature = "inbox_api")]
345    #[cfg_attr(docsrs, doc(cfg(feature = "inbox_api")))]
346    inbox_api: Box<dyn inbox_api::InboxApi>,
347    #[cfg(feature = "items_api")]
348    #[cfg_attr(docsrs, doc(cfg(feature = "items_api")))]
349    items_api: Box<dyn items_api::ItemsApi>,
350    #[cfg(feature = "links_api")]
351    #[cfg_attr(docsrs, doc(cfg(feature = "links_api")))]
352    links_api: Box<dyn links_api::LinksApi>,
353    #[cfg(feature = "logging_api")]
354    #[cfg_attr(docsrs, doc(cfg(feature = "logging_api")))]
355    logging_api: Box<dyn logging_api::LoggingApi>,
356    #[cfg(feature = "module_types_api")]
357    #[cfg_attr(docsrs, doc(cfg(feature = "module_types_api")))]
358    module_types_api: Box<dyn module_types_api::ModuleTypesApi>,
359    #[cfg(feature = "persistence_api")]
360    #[cfg_attr(docsrs, doc(cfg(feature = "persistence_api")))]
361    persistence_api: Box<dyn persistence_api::PersistenceApi>,
362    #[cfg(feature = "profile_types_api")]
363    #[cfg_attr(docsrs, doc(cfg(feature = "profile_types_api")))]
364    profile_types_api: Box<dyn profile_types_api::ProfileTypesApi>,
365    #[cfg(feature = "root_api")]
366    #[cfg_attr(docsrs, doc(cfg(feature = "root_api")))]
367    root_api: Box<dyn root_api::RootApi>,
368    #[cfg(feature = "rules_api")]
369    #[cfg_attr(docsrs, doc(cfg(feature = "rules_api")))]
370    rules_api: Box<dyn rules_api::RulesApi>,
371    #[cfg(feature = "services_api")]
372    #[cfg_attr(docsrs, doc(cfg(feature = "services_api")))]
373    services_api: Box<dyn services_api::ServicesApi>,
374    #[cfg(feature = "sitemaps_api")]
375    #[cfg_attr(docsrs, doc(cfg(feature = "sitemaps_api")))]
376    sitemaps_api: Box<dyn sitemaps_api::SitemapsApi>,
377    #[cfg(feature = "systeminfo_api")]
378    #[cfg_attr(docsrs, doc(cfg(feature = "systeminfo_api")))]
379    systeminfo_api: Box<dyn systeminfo_api::SysteminfoApi>,
380    #[cfg(feature = "tags_api")]
381    #[cfg_attr(docsrs, doc(cfg(feature = "tags_api")))]
382    tags_api: Box<dyn tags_api::TagsApi>,
383    #[cfg(feature = "templates_api")]
384    #[cfg_attr(docsrs, doc(cfg(feature = "templates_api")))]
385    templates_api: Box<dyn templates_api::TemplatesApi>,
386    #[cfg(feature = "thing_types_api")]
387    #[cfg_attr(docsrs, doc(cfg(feature = "thing_types_api")))]
388    thing_types_api: Box<dyn thing_types_api::ThingTypesApi>,
389    #[cfg(feature = "things_api")]
390    #[cfg_attr(docsrs, doc(cfg(feature = "things_api")))]
391    things_api: Box<dyn things_api::ThingsApi>,
392    #[cfg(feature = "transformations_api")]
393    #[cfg_attr(docsrs, doc(cfg(feature = "transformations_api")))]
394    transformations_api: Box<dyn transformations_api::TransformationsApi>,
395    #[cfg(feature = "ui_api")]
396    #[cfg_attr(docsrs, doc(cfg(feature = "ui_api")))]
397    ui_api: Box<dyn ui_api::UiApi>,
398    #[cfg(feature = "uuid_api")]
399    #[cfg_attr(docsrs, doc(cfg(feature = "uuid_api")))]
400    uuid_api: Box<dyn uuid_api::UuidApi>,
401    #[cfg(feature = "voice_api")]
402    #[cfg_attr(docsrs, doc(cfg(feature = "voice_api")))]
403    voice_api: Box<dyn voice_api::VoiceApi>,
404}
405
406impl ApiClient {
407    pub fn new(configuration: Arc<configuration::Configuration>) -> Self {
408        Self {
409            #[cfg(feature = "actions_api")]
410            actions_api: Box::new(actions_api::ActionsApiClient::new(configuration.clone())),
411            #[cfg(feature = "addons_api")]
412            addons_api: Box::new(addons_api::AddonsApiClient::new(configuration.clone())),
413            #[cfg(feature = "audio_api")]
414            audio_api: Box::new(audio_api::AudioApiClient::new(configuration.clone())),
415            #[cfg(feature = "auth_api")]
416            auth_api: Box::new(auth_api::AuthApiClient::new(configuration.clone())),
417            #[cfg(feature = "channel_types_api")]
418            channel_types_api: Box::new(channel_types_api::ChannelTypesApiClient::new(
419                configuration.clone(),
420            )),
421            #[cfg(feature = "config_descriptions_api")]
422            config_descriptions_api: Box::new(
423                config_descriptions_api::ConfigDescriptionsApiClient::new(configuration.clone()),
424            ),
425            #[cfg(feature = "discovery_api")]
426            discovery_api: Box::new(discovery_api::DiscoveryApiClient::new(
427                configuration.clone(),
428            )),
429            #[cfg(feature = "events_api")]
430            events_api: Box::new(events_api::EventsApiClient::new(configuration.clone())),
431            #[cfg(feature = "habpanel_api")]
432            habpanel_api: Box::new(habpanel_api::HabpanelApiClient::new(configuration.clone())),
433            #[cfg(feature = "iconsets_api")]
434            iconsets_api: Box::new(iconsets_api::IconsetsApiClient::new(configuration.clone())),
435            #[cfg(feature = "inbox_api")]
436            inbox_api: Box::new(inbox_api::InboxApiClient::new(configuration.clone())),
437            #[cfg(feature = "items_api")]
438            items_api: Box::new(items_api::ItemsApiClient::new(configuration.clone())),
439            #[cfg(feature = "links_api")]
440            links_api: Box::new(links_api::LinksApiClient::new(configuration.clone())),
441            #[cfg(feature = "logging_api")]
442            logging_api: Box::new(logging_api::LoggingApiClient::new(configuration.clone())),
443            #[cfg(feature = "module_types_api")]
444            module_types_api: Box::new(module_types_api::ModuleTypesApiClient::new(
445                configuration.clone(),
446            )),
447            #[cfg(feature = "persistence_api")]
448            persistence_api: Box::new(persistence_api::PersistenceApiClient::new(
449                configuration.clone(),
450            )),
451            #[cfg(feature = "profile_types_api")]
452            profile_types_api: Box::new(profile_types_api::ProfileTypesApiClient::new(
453                configuration.clone(),
454            )),
455            #[cfg(feature = "root_api")]
456            root_api: Box::new(root_api::RootApiClient::new(configuration.clone())),
457            #[cfg(feature = "rules_api")]
458            rules_api: Box::new(rules_api::RulesApiClient::new(configuration.clone())),
459            #[cfg(feature = "services_api")]
460            services_api: Box::new(services_api::ServicesApiClient::new(configuration.clone())),
461            #[cfg(feature = "sitemaps_api")]
462            sitemaps_api: Box::new(sitemaps_api::SitemapsApiClient::new(configuration.clone())),
463            #[cfg(feature = "systeminfo_api")]
464            systeminfo_api: Box::new(systeminfo_api::SysteminfoApiClient::new(
465                configuration.clone(),
466            )),
467            #[cfg(feature = "tags_api")]
468            tags_api: Box::new(tags_api::TagsApiClient::new(configuration.clone())),
469            #[cfg(feature = "templates_api")]
470            templates_api: Box::new(templates_api::TemplatesApiClient::new(
471                configuration.clone(),
472            )),
473            #[cfg(feature = "thing_types_api")]
474            thing_types_api: Box::new(thing_types_api::ThingTypesApiClient::new(
475                configuration.clone(),
476            )),
477            #[cfg(feature = "things_api")]
478            things_api: Box::new(things_api::ThingsApiClient::new(configuration.clone())),
479            #[cfg(feature = "transformations_api")]
480            transformations_api: Box::new(transformations_api::TransformationsApiClient::new(
481                configuration.clone(),
482            )),
483            #[cfg(feature = "ui_api")]
484            ui_api: Box::new(ui_api::UiApiClient::new(configuration.clone())),
485            #[cfg(feature = "uuid_api")]
486            uuid_api: Box::new(uuid_api::UuidApiClient::new(configuration.clone())),
487            #[cfg(feature = "voice_api")]
488            voice_api: Box::new(voice_api::VoiceApiClient::new(configuration.clone())),
489        }
490    }
491}
492
493impl Api for ApiClient {
494    #[cfg(feature = "actions_api")]
495    #[cfg_attr(docsrs, doc(cfg(feature = "actions_api")))]
496    fn actions_api(&self) -> &dyn actions_api::ActionsApi {
497        self.actions_api.as_ref()
498    }
499    #[cfg(feature = "addons_api")]
500    #[cfg_attr(docsrs, doc(cfg(feature = "addons_api")))]
501    fn addons_api(&self) -> &dyn addons_api::AddonsApi {
502        self.addons_api.as_ref()
503    }
504    #[cfg(feature = "audio_api")]
505    #[cfg_attr(docsrs, doc(cfg(feature = "audio_api")))]
506    fn audio_api(&self) -> &dyn audio_api::AudioApi {
507        self.audio_api.as_ref()
508    }
509    #[cfg(feature = "auth_api")]
510    #[cfg_attr(docsrs, doc(cfg(feature = "auth_api")))]
511    fn auth_api(&self) -> &dyn auth_api::AuthApi {
512        self.auth_api.as_ref()
513    }
514    #[cfg(feature = "channel_types_api")]
515    #[cfg_attr(docsrs, doc(cfg(feature = "channel_types_api")))]
516    fn channel_types_api(&self) -> &dyn channel_types_api::ChannelTypesApi {
517        self.channel_types_api.as_ref()
518    }
519    #[cfg(feature = "config_descriptions_api")]
520    #[cfg_attr(docsrs, doc(cfg(feature = "config_descriptions_api")))]
521    fn config_descriptions_api(&self) -> &dyn config_descriptions_api::ConfigDescriptionsApi {
522        self.config_descriptions_api.as_ref()
523    }
524    #[cfg(feature = "discovery_api")]
525    #[cfg_attr(docsrs, doc(cfg(feature = "discovery_api")))]
526    fn discovery_api(&self) -> &dyn discovery_api::DiscoveryApi {
527        self.discovery_api.as_ref()
528    }
529    #[cfg(feature = "events_api")]
530    #[cfg_attr(docsrs, doc(cfg(feature = "events_api")))]
531    fn events_api(&self) -> &dyn events_api::EventsApi {
532        self.events_api.as_ref()
533    }
534    #[cfg(feature = "habpanel_api")]
535    #[cfg_attr(docsrs, doc(cfg(feature = "habpanel_api")))]
536    fn habpanel_api(&self) -> &dyn habpanel_api::HabpanelApi {
537        self.habpanel_api.as_ref()
538    }
539    #[cfg(feature = "iconsets_api")]
540    #[cfg_attr(docsrs, doc(cfg(feature = "iconsets_api")))]
541    fn iconsets_api(&self) -> &dyn iconsets_api::IconsetsApi {
542        self.iconsets_api.as_ref()
543    }
544    #[cfg(feature = "inbox_api")]
545    #[cfg_attr(docsrs, doc(cfg(feature = "inbox_api")))]
546    fn inbox_api(&self) -> &dyn inbox_api::InboxApi {
547        self.inbox_api.as_ref()
548    }
549    #[cfg(feature = "items_api")]
550    #[cfg_attr(docsrs, doc(cfg(feature = "items_api")))]
551    fn items_api(&self) -> &dyn items_api::ItemsApi {
552        self.items_api.as_ref()
553    }
554    #[cfg(feature = "links_api")]
555    #[cfg_attr(docsrs, doc(cfg(feature = "links_api")))]
556    fn links_api(&self) -> &dyn links_api::LinksApi {
557        self.links_api.as_ref()
558    }
559    #[cfg(feature = "logging_api")]
560    #[cfg_attr(docsrs, doc(cfg(feature = "logging_api")))]
561    fn logging_api(&self) -> &dyn logging_api::LoggingApi {
562        self.logging_api.as_ref()
563    }
564    #[cfg(feature = "module_types_api")]
565    #[cfg_attr(docsrs, doc(cfg(feature = "module_types_api")))]
566    fn module_types_api(&self) -> &dyn module_types_api::ModuleTypesApi {
567        self.module_types_api.as_ref()
568    }
569    #[cfg(feature = "persistence_api")]
570    #[cfg_attr(docsrs, doc(cfg(feature = "persistence_api")))]
571    fn persistence_api(&self) -> &dyn persistence_api::PersistenceApi {
572        self.persistence_api.as_ref()
573    }
574    #[cfg(feature = "profile_types_api")]
575    #[cfg_attr(docsrs, doc(cfg(feature = "profile_types_api")))]
576    fn profile_types_api(&self) -> &dyn profile_types_api::ProfileTypesApi {
577        self.profile_types_api.as_ref()
578    }
579    #[cfg(feature = "root_api")]
580    #[cfg_attr(docsrs, doc(cfg(feature = "root_api")))]
581    fn root_api(&self) -> &dyn root_api::RootApi {
582        self.root_api.as_ref()
583    }
584    #[cfg(feature = "rules_api")]
585    #[cfg_attr(docsrs, doc(cfg(feature = "rules_api")))]
586    fn rules_api(&self) -> &dyn rules_api::RulesApi {
587        self.rules_api.as_ref()
588    }
589    #[cfg(feature = "services_api")]
590    #[cfg_attr(docsrs, doc(cfg(feature = "services_api")))]
591    fn services_api(&self) -> &dyn services_api::ServicesApi {
592        self.services_api.as_ref()
593    }
594    #[cfg(feature = "sitemaps_api")]
595    #[cfg_attr(docsrs, doc(cfg(feature = "sitemaps_api")))]
596    fn sitemaps_api(&self) -> &dyn sitemaps_api::SitemapsApi {
597        self.sitemaps_api.as_ref()
598    }
599    #[cfg(feature = "systeminfo_api")]
600    #[cfg_attr(docsrs, doc(cfg(feature = "systeminfo_api")))]
601    fn systeminfo_api(&self) -> &dyn systeminfo_api::SysteminfoApi {
602        self.systeminfo_api.as_ref()
603    }
604    #[cfg(feature = "tags_api")]
605    #[cfg_attr(docsrs, doc(cfg(feature = "tags_api")))]
606    fn tags_api(&self) -> &dyn tags_api::TagsApi {
607        self.tags_api.as_ref()
608    }
609    #[cfg(feature = "templates_api")]
610    #[cfg_attr(docsrs, doc(cfg(feature = "templates_api")))]
611    fn templates_api(&self) -> &dyn templates_api::TemplatesApi {
612        self.templates_api.as_ref()
613    }
614    #[cfg(feature = "thing_types_api")]
615    #[cfg_attr(docsrs, doc(cfg(feature = "thing_types_api")))]
616    fn thing_types_api(&self) -> &dyn thing_types_api::ThingTypesApi {
617        self.thing_types_api.as_ref()
618    }
619    #[cfg(feature = "things_api")]
620    #[cfg_attr(docsrs, doc(cfg(feature = "things_api")))]
621    fn things_api(&self) -> &dyn things_api::ThingsApi {
622        self.things_api.as_ref()
623    }
624    #[cfg(feature = "transformations_api")]
625    #[cfg_attr(docsrs, doc(cfg(feature = "transformations_api")))]
626    fn transformations_api(&self) -> &dyn transformations_api::TransformationsApi {
627        self.transformations_api.as_ref()
628    }
629    #[cfg(feature = "ui_api")]
630    #[cfg_attr(docsrs, doc(cfg(feature = "ui_api")))]
631    fn ui_api(&self) -> &dyn ui_api::UiApi {
632        self.ui_api.as_ref()
633    }
634    #[cfg(feature = "uuid_api")]
635    #[cfg_attr(docsrs, doc(cfg(feature = "uuid_api")))]
636    fn uuid_api(&self) -> &dyn uuid_api::UuidApi {
637        self.uuid_api.as_ref()
638    }
639    #[cfg(feature = "voice_api")]
640    #[cfg_attr(docsrs, doc(cfg(feature = "voice_api")))]
641    fn voice_api(&self) -> &dyn voice_api::VoiceApi {
642        self.voice_api.as_ref()
643    }
644}
645
646#[cfg(feature = "mockall")]
647#[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
648pub struct MockApiClient {
649    #[cfg(feature = "actions_api")]
650    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
651    pub actions_api_mock: actions_api::MockActionsApi,
652    #[cfg(feature = "addons_api")]
653    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
654    pub addons_api_mock: addons_api::MockAddonsApi,
655    #[cfg(feature = "audio_api")]
656    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
657    pub audio_api_mock: audio_api::MockAudioApi,
658    #[cfg(feature = "auth_api")]
659    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
660    pub auth_api_mock: auth_api::MockAuthApi,
661    #[cfg(feature = "channel_types_api")]
662    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
663    pub channel_types_api_mock: channel_types_api::MockChannelTypesApi,
664    #[cfg(feature = "config_descriptions_api")]
665    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
666    pub config_descriptions_api_mock: config_descriptions_api::MockConfigDescriptionsApi,
667    #[cfg(feature = "discovery_api")]
668    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
669    pub discovery_api_mock: discovery_api::MockDiscoveryApi,
670    #[cfg(feature = "events_api")]
671    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
672    pub events_api_mock: events_api::MockEventsApi,
673    #[cfg(feature = "habpanel_api")]
674    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
675    pub habpanel_api_mock: habpanel_api::MockHabpanelApi,
676    #[cfg(feature = "iconsets_api")]
677    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
678    pub iconsets_api_mock: iconsets_api::MockIconsetsApi,
679    #[cfg(feature = "inbox_api")]
680    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
681    pub inbox_api_mock: inbox_api::MockInboxApi,
682    #[cfg(feature = "items_api")]
683    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
684    pub items_api_mock: items_api::MockItemsApi,
685    #[cfg(feature = "links_api")]
686    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
687    pub links_api_mock: links_api::MockLinksApi,
688    #[cfg(feature = "logging_api")]
689    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
690    pub logging_api_mock: logging_api::MockLoggingApi,
691    #[cfg(feature = "module_types_api")]
692    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
693    pub module_types_api_mock: module_types_api::MockModuleTypesApi,
694    #[cfg(feature = "persistence_api")]
695    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
696    pub persistence_api_mock: persistence_api::MockPersistenceApi,
697    #[cfg(feature = "profile_types_api")]
698    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
699    pub profile_types_api_mock: profile_types_api::MockProfileTypesApi,
700    #[cfg(feature = "root_api")]
701    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
702    pub root_api_mock: root_api::MockRootApi,
703    #[cfg(feature = "rules_api")]
704    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
705    pub rules_api_mock: rules_api::MockRulesApi,
706    #[cfg(feature = "services_api")]
707    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
708    pub services_api_mock: services_api::MockServicesApi,
709    #[cfg(feature = "sitemaps_api")]
710    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
711    pub sitemaps_api_mock: sitemaps_api::MockSitemapsApi,
712    #[cfg(feature = "systeminfo_api")]
713    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
714    pub systeminfo_api_mock: systeminfo_api::MockSysteminfoApi,
715    #[cfg(feature = "tags_api")]
716    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
717    pub tags_api_mock: tags_api::MockTagsApi,
718    #[cfg(feature = "templates_api")]
719    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
720    pub templates_api_mock: templates_api::MockTemplatesApi,
721    #[cfg(feature = "thing_types_api")]
722    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
723    pub thing_types_api_mock: thing_types_api::MockThingTypesApi,
724    #[cfg(feature = "things_api")]
725    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
726    pub things_api_mock: things_api::MockThingsApi,
727    #[cfg(feature = "transformations_api")]
728    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
729    pub transformations_api_mock: transformations_api::MockTransformationsApi,
730    #[cfg(feature = "ui_api")]
731    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
732    pub ui_api_mock: ui_api::MockUiApi,
733    #[cfg(feature = "uuid_api")]
734    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
735    pub uuid_api_mock: uuid_api::MockUuidApi,
736    #[cfg(feature = "voice_api")]
737    #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
738    pub voice_api_mock: voice_api::MockVoiceApi,
739}
740
741#[cfg(feature = "mockall")]
742#[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
743impl MockApiClient {
744    pub fn new() -> Self {
745        Self {
746            #[cfg(feature = "actions_api")]
747            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
748            actions_api_mock: actions_api::MockActionsApi::new(),
749            #[cfg(feature = "addons_api")]
750            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
751            addons_api_mock: addons_api::MockAddonsApi::new(),
752            #[cfg(feature = "audio_api")]
753            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
754            audio_api_mock: audio_api::MockAudioApi::new(),
755            #[cfg(feature = "auth_api")]
756            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
757            auth_api_mock: auth_api::MockAuthApi::new(),
758            #[cfg(feature = "channel_types_api")]
759            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
760            channel_types_api_mock: channel_types_api::MockChannelTypesApi::new(),
761            #[cfg(feature = "config_descriptions_api")]
762            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
763            config_descriptions_api_mock: config_descriptions_api::MockConfigDescriptionsApi::new(),
764            #[cfg(feature = "discovery_api")]
765            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
766            discovery_api_mock: discovery_api::MockDiscoveryApi::new(),
767            #[cfg(feature = "events_api")]
768            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
769            events_api_mock: events_api::MockEventsApi::new(),
770            #[cfg(feature = "habpanel_api")]
771            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
772            habpanel_api_mock: habpanel_api::MockHabpanelApi::new(),
773            #[cfg(feature = "iconsets_api")]
774            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
775            iconsets_api_mock: iconsets_api::MockIconsetsApi::new(),
776            #[cfg(feature = "inbox_api")]
777            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
778            inbox_api_mock: inbox_api::MockInboxApi::new(),
779            #[cfg(feature = "items_api")]
780            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
781            items_api_mock: items_api::MockItemsApi::new(),
782            #[cfg(feature = "links_api")]
783            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
784            links_api_mock: links_api::MockLinksApi::new(),
785            #[cfg(feature = "logging_api")]
786            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
787            logging_api_mock: logging_api::MockLoggingApi::new(),
788            #[cfg(feature = "module_types_api")]
789            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
790            module_types_api_mock: module_types_api::MockModuleTypesApi::new(),
791            #[cfg(feature = "persistence_api")]
792            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
793            persistence_api_mock: persistence_api::MockPersistenceApi::new(),
794            #[cfg(feature = "profile_types_api")]
795            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
796            profile_types_api_mock: profile_types_api::MockProfileTypesApi::new(),
797            #[cfg(feature = "root_api")]
798            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
799            root_api_mock: root_api::MockRootApi::new(),
800            #[cfg(feature = "rules_api")]
801            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
802            rules_api_mock: rules_api::MockRulesApi::new(),
803            #[cfg(feature = "services_api")]
804            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
805            services_api_mock: services_api::MockServicesApi::new(),
806            #[cfg(feature = "sitemaps_api")]
807            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
808            sitemaps_api_mock: sitemaps_api::MockSitemapsApi::new(),
809            #[cfg(feature = "systeminfo_api")]
810            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
811            systeminfo_api_mock: systeminfo_api::MockSysteminfoApi::new(),
812            #[cfg(feature = "tags_api")]
813            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
814            tags_api_mock: tags_api::MockTagsApi::new(),
815            #[cfg(feature = "templates_api")]
816            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
817            templates_api_mock: templates_api::MockTemplatesApi::new(),
818            #[cfg(feature = "thing_types_api")]
819            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
820            thing_types_api_mock: thing_types_api::MockThingTypesApi::new(),
821            #[cfg(feature = "things_api")]
822            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
823            things_api_mock: things_api::MockThingsApi::new(),
824            #[cfg(feature = "transformations_api")]
825            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
826            transformations_api_mock: transformations_api::MockTransformationsApi::new(),
827            #[cfg(feature = "ui_api")]
828            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
829            ui_api_mock: ui_api::MockUiApi::new(),
830            #[cfg(feature = "uuid_api")]
831            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
832            uuid_api_mock: uuid_api::MockUuidApi::new(),
833            #[cfg(feature = "voice_api")]
834            #[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
835            voice_api_mock: voice_api::MockVoiceApi::new(),
836        }
837    }
838}
839
840#[cfg(feature = "mockall")]
841#[cfg_attr(docsrs, doc(cfg(feature = "mockall")))]
842impl Api for MockApiClient {
843    #[cfg(feature = "actions_api")]
844    fn actions_api(&self) -> &dyn actions_api::ActionsApi {
845        &self.actions_api_mock
846    }
847    #[cfg(feature = "addons_api")]
848    fn addons_api(&self) -> &dyn addons_api::AddonsApi {
849        &self.addons_api_mock
850    }
851    #[cfg(feature = "audio_api")]
852    fn audio_api(&self) -> &dyn audio_api::AudioApi {
853        &self.audio_api_mock
854    }
855    #[cfg(feature = "auth_api")]
856    fn auth_api(&self) -> &dyn auth_api::AuthApi {
857        &self.auth_api_mock
858    }
859    #[cfg(feature = "channel_types_api")]
860    fn channel_types_api(&self) -> &dyn channel_types_api::ChannelTypesApi {
861        &self.channel_types_api_mock
862    }
863    #[cfg(feature = "config_descriptions_api")]
864    fn config_descriptions_api(&self) -> &dyn config_descriptions_api::ConfigDescriptionsApi {
865        &self.config_descriptions_api_mock
866    }
867    #[cfg(feature = "discovery_api")]
868    fn discovery_api(&self) -> &dyn discovery_api::DiscoveryApi {
869        &self.discovery_api_mock
870    }
871    #[cfg(feature = "events_api")]
872    fn events_api(&self) -> &dyn events_api::EventsApi {
873        &self.events_api_mock
874    }
875    #[cfg(feature = "habpanel_api")]
876    fn habpanel_api(&self) -> &dyn habpanel_api::HabpanelApi {
877        &self.habpanel_api_mock
878    }
879    #[cfg(feature = "iconsets_api")]
880    fn iconsets_api(&self) -> &dyn iconsets_api::IconsetsApi {
881        &self.iconsets_api_mock
882    }
883    #[cfg(feature = "inbox_api")]
884    fn inbox_api(&self) -> &dyn inbox_api::InboxApi {
885        &self.inbox_api_mock
886    }
887    #[cfg(feature = "items_api")]
888    fn items_api(&self) -> &dyn items_api::ItemsApi {
889        &self.items_api_mock
890    }
891    #[cfg(feature = "links_api")]
892    fn links_api(&self) -> &dyn links_api::LinksApi {
893        &self.links_api_mock
894    }
895    #[cfg(feature = "logging_api")]
896    fn logging_api(&self) -> &dyn logging_api::LoggingApi {
897        &self.logging_api_mock
898    }
899    #[cfg(feature = "module_types_api")]
900    fn module_types_api(&self) -> &dyn module_types_api::ModuleTypesApi {
901        &self.module_types_api_mock
902    }
903    #[cfg(feature = "persistence_api")]
904    fn persistence_api(&self) -> &dyn persistence_api::PersistenceApi {
905        &self.persistence_api_mock
906    }
907    #[cfg(feature = "profile_types_api")]
908    fn profile_types_api(&self) -> &dyn profile_types_api::ProfileTypesApi {
909        &self.profile_types_api_mock
910    }
911    #[cfg(feature = "root_api")]
912    fn root_api(&self) -> &dyn root_api::RootApi {
913        &self.root_api_mock
914    }
915    #[cfg(feature = "rules_api")]
916    fn rules_api(&self) -> &dyn rules_api::RulesApi {
917        &self.rules_api_mock
918    }
919    #[cfg(feature = "services_api")]
920    fn services_api(&self) -> &dyn services_api::ServicesApi {
921        &self.services_api_mock
922    }
923    #[cfg(feature = "sitemaps_api")]
924    fn sitemaps_api(&self) -> &dyn sitemaps_api::SitemapsApi {
925        &self.sitemaps_api_mock
926    }
927    #[cfg(feature = "systeminfo_api")]
928    fn systeminfo_api(&self) -> &dyn systeminfo_api::SysteminfoApi {
929        &self.systeminfo_api_mock
930    }
931    #[cfg(feature = "tags_api")]
932    fn tags_api(&self) -> &dyn tags_api::TagsApi {
933        &self.tags_api_mock
934    }
935    #[cfg(feature = "templates_api")]
936    fn templates_api(&self) -> &dyn templates_api::TemplatesApi {
937        &self.templates_api_mock
938    }
939    #[cfg(feature = "thing_types_api")]
940    fn thing_types_api(&self) -> &dyn thing_types_api::ThingTypesApi {
941        &self.thing_types_api_mock
942    }
943    #[cfg(feature = "things_api")]
944    fn things_api(&self) -> &dyn things_api::ThingsApi {
945        &self.things_api_mock
946    }
947    #[cfg(feature = "transformations_api")]
948    fn transformations_api(&self) -> &dyn transformations_api::TransformationsApi {
949        &self.transformations_api_mock
950    }
951    #[cfg(feature = "ui_api")]
952    fn ui_api(&self) -> &dyn ui_api::UiApi {
953        &self.ui_api_mock
954    }
955    #[cfg(feature = "uuid_api")]
956    fn uuid_api(&self) -> &dyn uuid_api::UuidApi {
957        &self.uuid_api_mock
958    }
959    #[cfg(feature = "voice_api")]
960    fn voice_api(&self) -> &dyn voice_api::VoiceApi {
961        &self.voice_api_mock
962    }
963}