Skip to main content

nominal_api/conjure/clients/scout/datasource/
data_source_service.rs

1use conjure_http::endpoint;
2/// Data sources are data input to runs, including databases, CSV, video, and streaming data. They contain channels that represent the series data.
3/// The DataSource Service is responsible for indexing and searching channels across data sources.
4#[conjure_http::conjure_client(name = "DataSourceService")]
5pub trait DataSourceService<
6    #[response_body]
7    I: Iterator<
8            Item = Result<conjure_http::private::Bytes, conjure_http::private::Error>,
9        >,
10> {
11    /// Returns channels that match the search criteria. Results are sorted by similarity score.
12    #[endpoint(
13        method = POST,
14        path = "/data-source/v1/data-sources/search-channels",
15        name = "searchChannels",
16        accept = conjure_http::client::StdResponseDeserializer
17    )]
18    fn search_channels(
19        &self,
20        #[auth]
21        auth_: &conjure_object::BearerToken,
22        #[body(serializer = conjure_http::client::StdRequestSerializer)]
23        query: &super::super::super::super::objects::datasource::api::SearchChannelsRequest,
24    ) -> Result<
25        super::super::super::super::objects::datasource::api::SearchChannelsResponse,
26        conjure_http::private::Error,
27    >;
28    /// Returns channels that match the search criteria. Results are sorted by similarity score.
29    #[endpoint(
30        method = POST,
31        path = "/data-source/v1/data-sources/search-filtered-channels",
32        name = "searchFilteredChannels",
33        accept = conjure_http::client::StdResponseDeserializer
34    )]
35    fn search_filtered_channels(
36        &self,
37        #[auth]
38        auth_: &conjure_object::BearerToken,
39        #[body(serializer = conjure_http::client::StdRequestSerializer)]
40        query: &super::super::super::super::objects::datasource::api::SearchFilteredChannelsRequest,
41    ) -> Result<
42        super::super::super::super::objects::datasource::api::SearchFilteredChannelsResponse,
43        conjure_http::private::Error,
44    >;
45    /// Returns only channels that are direct children of the parent. Returns results sorted alphabetically.
46    #[endpoint(
47        method = POST,
48        path = "/data-source/v1/data-sources/search-hierarchical-channels",
49        name = "searchHierarchicalChannels",
50        accept = conjure_http::client::StdResponseDeserializer
51    )]
52    fn search_hierarchical_channels(
53        &self,
54        #[auth]
55        auth_: &conjure_object::BearerToken,
56        #[body(serializer = conjure_http::client::StdRequestSerializer)]
57        query: &super::super::super::super::objects::datasource::api::SearchHierarchicalChannelsRequest,
58    ) -> Result<
59        super::super::super::super::objects::datasource::api::SearchHierarchicalChannelsResponse,
60        conjure_http::private::Error,
61    >;
62    /// Indexes the channel prefix tree for a specified data source. This operation constructs a prefix tree from the
63    /// channels available in the data source.
64    #[endpoint(
65        method = POST,
66        path = "/data-source/v1/data-sources/index-channel-prefix-tree",
67        name = "indexChannelPrefixTree",
68        accept = conjure_http::client::StdResponseDeserializer
69    )]
70    fn index_channel_prefix_tree(
71        &self,
72        #[auth]
73        auth_: &conjure_object::BearerToken,
74        #[body(serializer = conjure_http::client::StdRequestSerializer)]
75        request: &super::super::super::super::objects::datasource::api::IndexChannelPrefixTreeRequest,
76    ) -> Result<
77        super::super::super::super::objects::datasource::api::ChannelPrefixTree,
78        conjure_http::private::Error,
79    >;
80    /// Clears the channel hierarchy delimiter for a specified data source, removing any previously indexed
81    /// prefix tree. After calling this endpoint, the data source will no longer have hierarchical channel browsing
82    /// enabled until a new delimiter is set via indexChannelPrefixTree.
83    #[endpoint(
84        method = POST,
85        path = "/data-source/v1/data-sources/clear-channel-prefix-tree",
86        name = "clearChannelPrefixTree",
87        accept = conjure_http::client::conjure::EmptyResponseDeserializer
88    )]
89    fn clear_channel_prefix_tree(
90        &self,
91        #[auth]
92        auth_: &conjure_object::BearerToken,
93        #[body(serializer = conjure_http::client::StdRequestSerializer)]
94        request: &super::super::super::super::objects::datasource::api::ClearChannelPrefixTreeRequest,
95    ) -> Result<(), conjure_http::private::Error>;
96    /// Returns the channel prefix tree for each of the specified data sources. If the tree for a data source has not
97    /// been indexed, it will be omitted from the map.
98    #[endpoint(
99        method = POST,
100        path = "/data-source/v1/data-sources/batch-get-channel-prefix-tree",
101        name = "batchGetChannelPrefixTrees",
102        accept = conjure_http::client::StdResponseDeserializer
103    )]
104    fn batch_get_channel_prefix_trees(
105        &self,
106        #[auth]
107        auth_: &conjure_object::BearerToken,
108        #[body(serializer = conjure_http::client::StdRequestSerializer)]
109        request: &super::super::super::super::objects::datasource::api::BatchGetChannelPrefixTreeRequest,
110    ) -> Result<
111        super::super::super::super::objects::datasource::api::BatchGetChannelPrefixTreeResponse,
112        conjure_http::private::Error,
113    >;
114    /// Returns the the set of all tag keys and their values that are available for the specified channel given an
115    /// initial set of filters.
116    #[endpoint(
117        method = POST,
118        path = "/data-source/v1/data-sources/get-available-tags",
119        name = "getAvailableTagsForChannel",
120        accept = conjure_http::client::StdResponseDeserializer
121    )]
122    fn get_available_tags_for_channel(
123        &self,
124        #[auth]
125        auth_: &conjure_object::BearerToken,
126        #[body(serializer = conjure_http::client::StdRequestSerializer)]
127        request: &super::super::super::super::objects::datasource::api::GetAvailableTagsForChannelRequest,
128    ) -> Result<
129        super::super::super::super::objects::datasource::api::GetAvailableTagsForChannelResponse,
130        conjure_http::private::Error,
131    >;
132    /// Returns the maximum data timestamps for the specified data scopes. Responses are returned
133    /// in the same order as requests.
134    #[endpoint(
135        method = POST,
136        path = "/data-source/v1/data-sources/get-data-scope-bounds",
137        name = "getDataScopeBounds",
138        accept = conjure_http::client::StdResponseDeserializer
139    )]
140    fn get_data_scope_bounds(
141        &self,
142        #[auth]
143        auth_: &conjure_object::BearerToken,
144        #[body(serializer = conjure_http::client::StdRequestSerializer)]
145        request: &super::super::super::super::objects::datasource::api::BatchGetDataScopeBoundsRequest,
146    ) -> Result<
147        super::super::super::super::objects::datasource::api::BatchGetDataScopeBoundsResponse,
148        conjure_http::private::Error,
149    >;
150    /// Returns available tag values for a given data source for a set of tag keys. For Nominal data sources, a time
151    /// range can be provided to filter tag values to those present within the months spanned by the range. If no
152    /// time range is provided, this defaults to the last month. For external data sources, the range must not be
153    /// specified, as all tag values are returned.
154    #[endpoint(
155        method = POST,
156        path = "/data-source/v1/data-sources/{dataSourceRid}/get-tags",
157        name = "getTagValuesForDataSource",
158        accept = conjure_http::client::conjure::CollectionResponseDeserializer
159    )]
160    fn get_tag_values_for_data_source(
161        &self,
162        #[auth]
163        auth_: &conjure_object::BearerToken,
164        #[path(
165            name = "dataSourceRid",
166            encoder = conjure_http::client::conjure::PlainEncoder
167        )]
168        data_source_rid: &super::super::super::super::objects::api::rids::DataSourceRid,
169        #[body(serializer = conjure_http::client::StdRequestSerializer)]
170        request: &super::super::super::super::objects::datasource::api::GetTagValuesForDataSourceRequest,
171    ) -> Result<
172        std::collections::BTreeMap<
173            super::super::super::super::objects::api::TagName,
174            std::collections::BTreeSet<
175                super::super::super::super::objects::api::TagValue,
176            >,
177        >,
178        conjure_http::private::Error,
179    >;
180    /// Paged endpoint returning the set of all tag keys that are available for the specified channel given an
181    /// initial set of filters.
182    /// If any tag filters are supplied, their tag keys are omitted from the result.
183    #[endpoint(
184        method = POST,
185        path = "/data-source/v1/data-sources/{dataSourceRid}/get-tag-keys",
186        name = "getAvailableTagKeys",
187        accept = conjure_http::client::StdResponseDeserializer
188    )]
189    fn get_available_tag_keys(
190        &self,
191        #[auth]
192        auth_: &conjure_object::BearerToken,
193        #[path(
194            name = "dataSourceRid",
195            encoder = conjure_http::client::conjure::PlainEncoder
196        )]
197        data_source_rid: &super::super::super::super::objects::api::rids::DataSourceRid,
198        #[body(serializer = conjure_http::client::StdRequestSerializer)]
199        request: &super::super::super::super::objects::datasource::api::GetAvailableTagKeysRequest,
200    ) -> Result<
201        super::super::super::super::objects::datasource::api::GetAvailableTagKeysResponse,
202        conjure_http::private::Error,
203    >;
204    /// Paged endpoint returning the set of all tag values that are available for the specified tag and datasource
205    /// given an initial set of filters.
206    #[endpoint(
207        method = POST,
208        path = "/data-source/v1/data-sources/{dataSourceRid}/get-tag-values",
209        name = "getAvailableTagValues",
210        accept = conjure_http::client::StdResponseDeserializer
211    )]
212    fn get_available_tag_values(
213        &self,
214        #[auth]
215        auth_: &conjure_object::BearerToken,
216        #[path(
217            name = "dataSourceRid",
218            encoder = conjure_http::client::conjure::PlainEncoder
219        )]
220        data_source_rid: &super::super::super::super::objects::api::rids::DataSourceRid,
221        #[body(serializer = conjure_http::client::StdRequestSerializer)]
222        request: &super::super::super::super::objects::datasource::api::GetAvailableTagValuesRequest,
223    ) -> Result<
224        super::super::super::super::objects::datasource::api::GetAvailableTagValuesResponse,
225        conjure_http::private::Error,
226    >;
227    /// Returns the set of all tag keys and their values for each specified channel given
228    /// initial sets of filters. Each response corresponds positionally to the input request.
229    #[endpoint(
230        method = POST,
231        path = "/data-source/v1/data-sources/batch-get-available-tags",
232        name = "batchGetAvailableTagsForChannel",
233        accept = conjure_http::client::StdResponseDeserializer
234    )]
235    fn batch_get_available_tags_for_channel(
236        &self,
237        #[auth]
238        auth_: &conjure_object::BearerToken,
239        #[body(serializer = conjure_http::client::StdRequestSerializer)]
240        request: &super::super::super::super::objects::datasource::api::BatchGetAvailableTagsForChannelRequest,
241    ) -> Result<
242        super::super::super::super::objects::datasource::api::BatchGetAvailableTagsForChannelResponse,
243        conjure_http::private::Error,
244    >;
245    /// Returns the number of distinct series matching each request's datasource, channel, range,
246    /// and tag filters. Each response corresponds positionally to the input request.
247    /// Returns empty seriesCount for non-Nominal datasources.
248    #[endpoint(
249        method = POST,
250        path = "/data-source/v1/data-sources/batch-get-series-count",
251        name = "batchGetSeriesCount",
252        accept = conjure_http::client::StdResponseDeserializer
253    )]
254    fn batch_get_series_count(
255        &self,
256        #[auth]
257        auth_: &conjure_object::BearerToken,
258        #[body(serializer = conjure_http::client::StdRequestSerializer)]
259        request: &super::super::super::super::objects::datasource::api::BatchGetSeriesCountRequest,
260    ) -> Result<
261        super::super::super::super::objects::datasource::api::BatchGetSeriesCountResponse,
262        conjure_http::private::Error,
263    >;
264    /// Returns (channel, full-tag-map) entries for a specific channel in a dataset.
265    /// If tags are provided, each entry must match all provided key/value pairs; extra tags may still be present.
266    /// Only numeric-data series are returned; video series are excluded.
267    #[endpoint(
268        method = POST,
269        path = "/data-source/v1/data-sources/get-matching-channels-with-tags",
270        name = "getMatchingChannelsWithTags",
271        accept = conjure_http::client::StdResponseDeserializer
272    )]
273    fn get_matching_channels_with_tags(
274        &self,
275        #[auth]
276        auth_: &conjure_object::BearerToken,
277        #[body(serializer = conjure_http::client::StdRequestSerializer)]
278        request: &super::super::super::super::objects::datasource::api::GetMatchingChannelsWithTagsRequest,
279    ) -> Result<
280        super::super::super::super::objects::datasource::api::GetMatchingChannelsWithTagsResponse,
281        conjure_http::private::Error,
282    >;
283}
284/// Data sources are data input to runs, including databases, CSV, video, and streaming data. They contain channels that represent the series data.
285/// The DataSource Service is responsible for indexing and searching channels across data sources.
286#[conjure_http::conjure_client(name = "DataSourceService")]
287pub trait AsyncDataSourceService<
288    #[response_body]
289    I: conjure_http::private::Stream<
290            Item = Result<conjure_http::private::Bytes, conjure_http::private::Error>,
291        >,
292> {
293    /// Returns channels that match the search criteria. Results are sorted by similarity score.
294    #[endpoint(
295        method = POST,
296        path = "/data-source/v1/data-sources/search-channels",
297        name = "searchChannels",
298        accept = conjure_http::client::StdResponseDeserializer
299    )]
300    async fn search_channels(
301        &self,
302        #[auth]
303        auth_: &conjure_object::BearerToken,
304        #[body(serializer = conjure_http::client::StdRequestSerializer)]
305        query: &super::super::super::super::objects::datasource::api::SearchChannelsRequest,
306    ) -> Result<
307        super::super::super::super::objects::datasource::api::SearchChannelsResponse,
308        conjure_http::private::Error,
309    >;
310    /// Returns channels that match the search criteria. Results are sorted by similarity score.
311    #[endpoint(
312        method = POST,
313        path = "/data-source/v1/data-sources/search-filtered-channels",
314        name = "searchFilteredChannels",
315        accept = conjure_http::client::StdResponseDeserializer
316    )]
317    async fn search_filtered_channels(
318        &self,
319        #[auth]
320        auth_: &conjure_object::BearerToken,
321        #[body(serializer = conjure_http::client::StdRequestSerializer)]
322        query: &super::super::super::super::objects::datasource::api::SearchFilteredChannelsRequest,
323    ) -> Result<
324        super::super::super::super::objects::datasource::api::SearchFilteredChannelsResponse,
325        conjure_http::private::Error,
326    >;
327    /// Returns only channels that are direct children of the parent. Returns results sorted alphabetically.
328    #[endpoint(
329        method = POST,
330        path = "/data-source/v1/data-sources/search-hierarchical-channels",
331        name = "searchHierarchicalChannels",
332        accept = conjure_http::client::StdResponseDeserializer
333    )]
334    async fn search_hierarchical_channels(
335        &self,
336        #[auth]
337        auth_: &conjure_object::BearerToken,
338        #[body(serializer = conjure_http::client::StdRequestSerializer)]
339        query: &super::super::super::super::objects::datasource::api::SearchHierarchicalChannelsRequest,
340    ) -> Result<
341        super::super::super::super::objects::datasource::api::SearchHierarchicalChannelsResponse,
342        conjure_http::private::Error,
343    >;
344    /// Indexes the channel prefix tree for a specified data source. This operation constructs a prefix tree from the
345    /// channels available in the data source.
346    #[endpoint(
347        method = POST,
348        path = "/data-source/v1/data-sources/index-channel-prefix-tree",
349        name = "indexChannelPrefixTree",
350        accept = conjure_http::client::StdResponseDeserializer
351    )]
352    async fn index_channel_prefix_tree(
353        &self,
354        #[auth]
355        auth_: &conjure_object::BearerToken,
356        #[body(serializer = conjure_http::client::StdRequestSerializer)]
357        request: &super::super::super::super::objects::datasource::api::IndexChannelPrefixTreeRequest,
358    ) -> Result<
359        super::super::super::super::objects::datasource::api::ChannelPrefixTree,
360        conjure_http::private::Error,
361    >;
362    /// Clears the channel hierarchy delimiter for a specified data source, removing any previously indexed
363    /// prefix tree. After calling this endpoint, the data source will no longer have hierarchical channel browsing
364    /// enabled until a new delimiter is set via indexChannelPrefixTree.
365    #[endpoint(
366        method = POST,
367        path = "/data-source/v1/data-sources/clear-channel-prefix-tree",
368        name = "clearChannelPrefixTree",
369        accept = conjure_http::client::conjure::EmptyResponseDeserializer
370    )]
371    async fn clear_channel_prefix_tree(
372        &self,
373        #[auth]
374        auth_: &conjure_object::BearerToken,
375        #[body(serializer = conjure_http::client::StdRequestSerializer)]
376        request: &super::super::super::super::objects::datasource::api::ClearChannelPrefixTreeRequest,
377    ) -> Result<(), conjure_http::private::Error>;
378    /// Returns the channel prefix tree for each of the specified data sources. If the tree for a data source has not
379    /// been indexed, it will be omitted from the map.
380    #[endpoint(
381        method = POST,
382        path = "/data-source/v1/data-sources/batch-get-channel-prefix-tree",
383        name = "batchGetChannelPrefixTrees",
384        accept = conjure_http::client::StdResponseDeserializer
385    )]
386    async fn batch_get_channel_prefix_trees(
387        &self,
388        #[auth]
389        auth_: &conjure_object::BearerToken,
390        #[body(serializer = conjure_http::client::StdRequestSerializer)]
391        request: &super::super::super::super::objects::datasource::api::BatchGetChannelPrefixTreeRequest,
392    ) -> Result<
393        super::super::super::super::objects::datasource::api::BatchGetChannelPrefixTreeResponse,
394        conjure_http::private::Error,
395    >;
396    /// Returns the the set of all tag keys and their values that are available for the specified channel given an
397    /// initial set of filters.
398    #[endpoint(
399        method = POST,
400        path = "/data-source/v1/data-sources/get-available-tags",
401        name = "getAvailableTagsForChannel",
402        accept = conjure_http::client::StdResponseDeserializer
403    )]
404    async fn get_available_tags_for_channel(
405        &self,
406        #[auth]
407        auth_: &conjure_object::BearerToken,
408        #[body(serializer = conjure_http::client::StdRequestSerializer)]
409        request: &super::super::super::super::objects::datasource::api::GetAvailableTagsForChannelRequest,
410    ) -> Result<
411        super::super::super::super::objects::datasource::api::GetAvailableTagsForChannelResponse,
412        conjure_http::private::Error,
413    >;
414    /// Returns the maximum data timestamps for the specified data scopes. Responses are returned
415    /// in the same order as requests.
416    #[endpoint(
417        method = POST,
418        path = "/data-source/v1/data-sources/get-data-scope-bounds",
419        name = "getDataScopeBounds",
420        accept = conjure_http::client::StdResponseDeserializer
421    )]
422    async fn get_data_scope_bounds(
423        &self,
424        #[auth]
425        auth_: &conjure_object::BearerToken,
426        #[body(serializer = conjure_http::client::StdRequestSerializer)]
427        request: &super::super::super::super::objects::datasource::api::BatchGetDataScopeBoundsRequest,
428    ) -> Result<
429        super::super::super::super::objects::datasource::api::BatchGetDataScopeBoundsResponse,
430        conjure_http::private::Error,
431    >;
432    /// Returns available tag values for a given data source for a set of tag keys. For Nominal data sources, a time
433    /// range can be provided to filter tag values to those present within the months spanned by the range. If no
434    /// time range is provided, this defaults to the last month. For external data sources, the range must not be
435    /// specified, as all tag values are returned.
436    #[endpoint(
437        method = POST,
438        path = "/data-source/v1/data-sources/{dataSourceRid}/get-tags",
439        name = "getTagValuesForDataSource",
440        accept = conjure_http::client::conjure::CollectionResponseDeserializer
441    )]
442    async fn get_tag_values_for_data_source(
443        &self,
444        #[auth]
445        auth_: &conjure_object::BearerToken,
446        #[path(
447            name = "dataSourceRid",
448            encoder = conjure_http::client::conjure::PlainEncoder
449        )]
450        data_source_rid: &super::super::super::super::objects::api::rids::DataSourceRid,
451        #[body(serializer = conjure_http::client::StdRequestSerializer)]
452        request: &super::super::super::super::objects::datasource::api::GetTagValuesForDataSourceRequest,
453    ) -> Result<
454        std::collections::BTreeMap<
455            super::super::super::super::objects::api::TagName,
456            std::collections::BTreeSet<
457                super::super::super::super::objects::api::TagValue,
458            >,
459        >,
460        conjure_http::private::Error,
461    >;
462    /// Paged endpoint returning the set of all tag keys that are available for the specified channel given an
463    /// initial set of filters.
464    /// If any tag filters are supplied, their tag keys are omitted from the result.
465    #[endpoint(
466        method = POST,
467        path = "/data-source/v1/data-sources/{dataSourceRid}/get-tag-keys",
468        name = "getAvailableTagKeys",
469        accept = conjure_http::client::StdResponseDeserializer
470    )]
471    async fn get_available_tag_keys(
472        &self,
473        #[auth]
474        auth_: &conjure_object::BearerToken,
475        #[path(
476            name = "dataSourceRid",
477            encoder = conjure_http::client::conjure::PlainEncoder
478        )]
479        data_source_rid: &super::super::super::super::objects::api::rids::DataSourceRid,
480        #[body(serializer = conjure_http::client::StdRequestSerializer)]
481        request: &super::super::super::super::objects::datasource::api::GetAvailableTagKeysRequest,
482    ) -> Result<
483        super::super::super::super::objects::datasource::api::GetAvailableTagKeysResponse,
484        conjure_http::private::Error,
485    >;
486    /// Paged endpoint returning the set of all tag values that are available for the specified tag and datasource
487    /// given an initial set of filters.
488    #[endpoint(
489        method = POST,
490        path = "/data-source/v1/data-sources/{dataSourceRid}/get-tag-values",
491        name = "getAvailableTagValues",
492        accept = conjure_http::client::StdResponseDeserializer
493    )]
494    async fn get_available_tag_values(
495        &self,
496        #[auth]
497        auth_: &conjure_object::BearerToken,
498        #[path(
499            name = "dataSourceRid",
500            encoder = conjure_http::client::conjure::PlainEncoder
501        )]
502        data_source_rid: &super::super::super::super::objects::api::rids::DataSourceRid,
503        #[body(serializer = conjure_http::client::StdRequestSerializer)]
504        request: &super::super::super::super::objects::datasource::api::GetAvailableTagValuesRequest,
505    ) -> Result<
506        super::super::super::super::objects::datasource::api::GetAvailableTagValuesResponse,
507        conjure_http::private::Error,
508    >;
509    /// Returns the set of all tag keys and their values for each specified channel given
510    /// initial sets of filters. Each response corresponds positionally to the input request.
511    #[endpoint(
512        method = POST,
513        path = "/data-source/v1/data-sources/batch-get-available-tags",
514        name = "batchGetAvailableTagsForChannel",
515        accept = conjure_http::client::StdResponseDeserializer
516    )]
517    async fn batch_get_available_tags_for_channel(
518        &self,
519        #[auth]
520        auth_: &conjure_object::BearerToken,
521        #[body(serializer = conjure_http::client::StdRequestSerializer)]
522        request: &super::super::super::super::objects::datasource::api::BatchGetAvailableTagsForChannelRequest,
523    ) -> Result<
524        super::super::super::super::objects::datasource::api::BatchGetAvailableTagsForChannelResponse,
525        conjure_http::private::Error,
526    >;
527    /// Returns the number of distinct series matching each request's datasource, channel, range,
528    /// and tag filters. Each response corresponds positionally to the input request.
529    /// Returns empty seriesCount for non-Nominal datasources.
530    #[endpoint(
531        method = POST,
532        path = "/data-source/v1/data-sources/batch-get-series-count",
533        name = "batchGetSeriesCount",
534        accept = conjure_http::client::StdResponseDeserializer
535    )]
536    async fn batch_get_series_count(
537        &self,
538        #[auth]
539        auth_: &conjure_object::BearerToken,
540        #[body(serializer = conjure_http::client::StdRequestSerializer)]
541        request: &super::super::super::super::objects::datasource::api::BatchGetSeriesCountRequest,
542    ) -> Result<
543        super::super::super::super::objects::datasource::api::BatchGetSeriesCountResponse,
544        conjure_http::private::Error,
545    >;
546    /// Returns (channel, full-tag-map) entries for a specific channel in a dataset.
547    /// If tags are provided, each entry must match all provided key/value pairs; extra tags may still be present.
548    /// Only numeric-data series are returned; video series are excluded.
549    #[endpoint(
550        method = POST,
551        path = "/data-source/v1/data-sources/get-matching-channels-with-tags",
552        name = "getMatchingChannelsWithTags",
553        accept = conjure_http::client::StdResponseDeserializer
554    )]
555    async fn get_matching_channels_with_tags(
556        &self,
557        #[auth]
558        auth_: &conjure_object::BearerToken,
559        #[body(serializer = conjure_http::client::StdRequestSerializer)]
560        request: &super::super::super::super::objects::datasource::api::GetMatchingChannelsWithTagsRequest,
561    ) -> Result<
562        super::super::super::super::objects::datasource::api::GetMatchingChannelsWithTagsResponse,
563        conjure_http::private::Error,
564    >;
565}
566/// Data sources are data input to runs, including databases, CSV, video, and streaming data. They contain channels that represent the series data.
567/// The DataSource Service is responsible for indexing and searching channels across data sources.
568#[conjure_http::conjure_client(name = "DataSourceService", local)]
569pub trait LocalAsyncDataSourceService<
570    #[response_body]
571    I: conjure_http::private::Stream<
572            Item = Result<conjure_http::private::Bytes, conjure_http::private::Error>,
573        >,
574> {
575    /// Returns channels that match the search criteria. Results are sorted by similarity score.
576    #[endpoint(
577        method = POST,
578        path = "/data-source/v1/data-sources/search-channels",
579        name = "searchChannels",
580        accept = conjure_http::client::StdResponseDeserializer
581    )]
582    async fn search_channels(
583        &self,
584        #[auth]
585        auth_: &conjure_object::BearerToken,
586        #[body(serializer = conjure_http::client::StdRequestSerializer)]
587        query: &super::super::super::super::objects::datasource::api::SearchChannelsRequest,
588    ) -> Result<
589        super::super::super::super::objects::datasource::api::SearchChannelsResponse,
590        conjure_http::private::Error,
591    >;
592    /// Returns channels that match the search criteria. Results are sorted by similarity score.
593    #[endpoint(
594        method = POST,
595        path = "/data-source/v1/data-sources/search-filtered-channels",
596        name = "searchFilteredChannels",
597        accept = conjure_http::client::StdResponseDeserializer
598    )]
599    async fn search_filtered_channels(
600        &self,
601        #[auth]
602        auth_: &conjure_object::BearerToken,
603        #[body(serializer = conjure_http::client::StdRequestSerializer)]
604        query: &super::super::super::super::objects::datasource::api::SearchFilteredChannelsRequest,
605    ) -> Result<
606        super::super::super::super::objects::datasource::api::SearchFilteredChannelsResponse,
607        conjure_http::private::Error,
608    >;
609    /// Returns only channels that are direct children of the parent. Returns results sorted alphabetically.
610    #[endpoint(
611        method = POST,
612        path = "/data-source/v1/data-sources/search-hierarchical-channels",
613        name = "searchHierarchicalChannels",
614        accept = conjure_http::client::StdResponseDeserializer
615    )]
616    async fn search_hierarchical_channels(
617        &self,
618        #[auth]
619        auth_: &conjure_object::BearerToken,
620        #[body(serializer = conjure_http::client::StdRequestSerializer)]
621        query: &super::super::super::super::objects::datasource::api::SearchHierarchicalChannelsRequest,
622    ) -> Result<
623        super::super::super::super::objects::datasource::api::SearchHierarchicalChannelsResponse,
624        conjure_http::private::Error,
625    >;
626    /// Indexes the channel prefix tree for a specified data source. This operation constructs a prefix tree from the
627    /// channels available in the data source.
628    #[endpoint(
629        method = POST,
630        path = "/data-source/v1/data-sources/index-channel-prefix-tree",
631        name = "indexChannelPrefixTree",
632        accept = conjure_http::client::StdResponseDeserializer
633    )]
634    async fn index_channel_prefix_tree(
635        &self,
636        #[auth]
637        auth_: &conjure_object::BearerToken,
638        #[body(serializer = conjure_http::client::StdRequestSerializer)]
639        request: &super::super::super::super::objects::datasource::api::IndexChannelPrefixTreeRequest,
640    ) -> Result<
641        super::super::super::super::objects::datasource::api::ChannelPrefixTree,
642        conjure_http::private::Error,
643    >;
644    /// Clears the channel hierarchy delimiter for a specified data source, removing any previously indexed
645    /// prefix tree. After calling this endpoint, the data source will no longer have hierarchical channel browsing
646    /// enabled until a new delimiter is set via indexChannelPrefixTree.
647    #[endpoint(
648        method = POST,
649        path = "/data-source/v1/data-sources/clear-channel-prefix-tree",
650        name = "clearChannelPrefixTree",
651        accept = conjure_http::client::conjure::EmptyResponseDeserializer
652    )]
653    async fn clear_channel_prefix_tree(
654        &self,
655        #[auth]
656        auth_: &conjure_object::BearerToken,
657        #[body(serializer = conjure_http::client::StdRequestSerializer)]
658        request: &super::super::super::super::objects::datasource::api::ClearChannelPrefixTreeRequest,
659    ) -> Result<(), conjure_http::private::Error>;
660    /// Returns the channel prefix tree for each of the specified data sources. If the tree for a data source has not
661    /// been indexed, it will be omitted from the map.
662    #[endpoint(
663        method = POST,
664        path = "/data-source/v1/data-sources/batch-get-channel-prefix-tree",
665        name = "batchGetChannelPrefixTrees",
666        accept = conjure_http::client::StdResponseDeserializer
667    )]
668    async fn batch_get_channel_prefix_trees(
669        &self,
670        #[auth]
671        auth_: &conjure_object::BearerToken,
672        #[body(serializer = conjure_http::client::StdRequestSerializer)]
673        request: &super::super::super::super::objects::datasource::api::BatchGetChannelPrefixTreeRequest,
674    ) -> Result<
675        super::super::super::super::objects::datasource::api::BatchGetChannelPrefixTreeResponse,
676        conjure_http::private::Error,
677    >;
678    /// Returns the the set of all tag keys and their values that are available for the specified channel given an
679    /// initial set of filters.
680    #[endpoint(
681        method = POST,
682        path = "/data-source/v1/data-sources/get-available-tags",
683        name = "getAvailableTagsForChannel",
684        accept = conjure_http::client::StdResponseDeserializer
685    )]
686    async fn get_available_tags_for_channel(
687        &self,
688        #[auth]
689        auth_: &conjure_object::BearerToken,
690        #[body(serializer = conjure_http::client::StdRequestSerializer)]
691        request: &super::super::super::super::objects::datasource::api::GetAvailableTagsForChannelRequest,
692    ) -> Result<
693        super::super::super::super::objects::datasource::api::GetAvailableTagsForChannelResponse,
694        conjure_http::private::Error,
695    >;
696    /// Returns the maximum data timestamps for the specified data scopes. Responses are returned
697    /// in the same order as requests.
698    #[endpoint(
699        method = POST,
700        path = "/data-source/v1/data-sources/get-data-scope-bounds",
701        name = "getDataScopeBounds",
702        accept = conjure_http::client::StdResponseDeserializer
703    )]
704    async fn get_data_scope_bounds(
705        &self,
706        #[auth]
707        auth_: &conjure_object::BearerToken,
708        #[body(serializer = conjure_http::client::StdRequestSerializer)]
709        request: &super::super::super::super::objects::datasource::api::BatchGetDataScopeBoundsRequest,
710    ) -> Result<
711        super::super::super::super::objects::datasource::api::BatchGetDataScopeBoundsResponse,
712        conjure_http::private::Error,
713    >;
714    /// Returns available tag values for a given data source for a set of tag keys. For Nominal data sources, a time
715    /// range can be provided to filter tag values to those present within the months spanned by the range. If no
716    /// time range is provided, this defaults to the last month. For external data sources, the range must not be
717    /// specified, as all tag values are returned.
718    #[endpoint(
719        method = POST,
720        path = "/data-source/v1/data-sources/{dataSourceRid}/get-tags",
721        name = "getTagValuesForDataSource",
722        accept = conjure_http::client::conjure::CollectionResponseDeserializer
723    )]
724    async fn get_tag_values_for_data_source(
725        &self,
726        #[auth]
727        auth_: &conjure_object::BearerToken,
728        #[path(
729            name = "dataSourceRid",
730            encoder = conjure_http::client::conjure::PlainEncoder
731        )]
732        data_source_rid: &super::super::super::super::objects::api::rids::DataSourceRid,
733        #[body(serializer = conjure_http::client::StdRequestSerializer)]
734        request: &super::super::super::super::objects::datasource::api::GetTagValuesForDataSourceRequest,
735    ) -> Result<
736        std::collections::BTreeMap<
737            super::super::super::super::objects::api::TagName,
738            std::collections::BTreeSet<
739                super::super::super::super::objects::api::TagValue,
740            >,
741        >,
742        conjure_http::private::Error,
743    >;
744    /// Paged endpoint returning the set of all tag keys that are available for the specified channel given an
745    /// initial set of filters.
746    /// If any tag filters are supplied, their tag keys are omitted from the result.
747    #[endpoint(
748        method = POST,
749        path = "/data-source/v1/data-sources/{dataSourceRid}/get-tag-keys",
750        name = "getAvailableTagKeys",
751        accept = conjure_http::client::StdResponseDeserializer
752    )]
753    async fn get_available_tag_keys(
754        &self,
755        #[auth]
756        auth_: &conjure_object::BearerToken,
757        #[path(
758            name = "dataSourceRid",
759            encoder = conjure_http::client::conjure::PlainEncoder
760        )]
761        data_source_rid: &super::super::super::super::objects::api::rids::DataSourceRid,
762        #[body(serializer = conjure_http::client::StdRequestSerializer)]
763        request: &super::super::super::super::objects::datasource::api::GetAvailableTagKeysRequest,
764    ) -> Result<
765        super::super::super::super::objects::datasource::api::GetAvailableTagKeysResponse,
766        conjure_http::private::Error,
767    >;
768    /// Paged endpoint returning the set of all tag values that are available for the specified tag and datasource
769    /// given an initial set of filters.
770    #[endpoint(
771        method = POST,
772        path = "/data-source/v1/data-sources/{dataSourceRid}/get-tag-values",
773        name = "getAvailableTagValues",
774        accept = conjure_http::client::StdResponseDeserializer
775    )]
776    async fn get_available_tag_values(
777        &self,
778        #[auth]
779        auth_: &conjure_object::BearerToken,
780        #[path(
781            name = "dataSourceRid",
782            encoder = conjure_http::client::conjure::PlainEncoder
783        )]
784        data_source_rid: &super::super::super::super::objects::api::rids::DataSourceRid,
785        #[body(serializer = conjure_http::client::StdRequestSerializer)]
786        request: &super::super::super::super::objects::datasource::api::GetAvailableTagValuesRequest,
787    ) -> Result<
788        super::super::super::super::objects::datasource::api::GetAvailableTagValuesResponse,
789        conjure_http::private::Error,
790    >;
791    /// Returns the set of all tag keys and their values for each specified channel given
792    /// initial sets of filters. Each response corresponds positionally to the input request.
793    #[endpoint(
794        method = POST,
795        path = "/data-source/v1/data-sources/batch-get-available-tags",
796        name = "batchGetAvailableTagsForChannel",
797        accept = conjure_http::client::StdResponseDeserializer
798    )]
799    async fn batch_get_available_tags_for_channel(
800        &self,
801        #[auth]
802        auth_: &conjure_object::BearerToken,
803        #[body(serializer = conjure_http::client::StdRequestSerializer)]
804        request: &super::super::super::super::objects::datasource::api::BatchGetAvailableTagsForChannelRequest,
805    ) -> Result<
806        super::super::super::super::objects::datasource::api::BatchGetAvailableTagsForChannelResponse,
807        conjure_http::private::Error,
808    >;
809    /// Returns the number of distinct series matching each request's datasource, channel, range,
810    /// and tag filters. Each response corresponds positionally to the input request.
811    /// Returns empty seriesCount for non-Nominal datasources.
812    #[endpoint(
813        method = POST,
814        path = "/data-source/v1/data-sources/batch-get-series-count",
815        name = "batchGetSeriesCount",
816        accept = conjure_http::client::StdResponseDeserializer
817    )]
818    async fn batch_get_series_count(
819        &self,
820        #[auth]
821        auth_: &conjure_object::BearerToken,
822        #[body(serializer = conjure_http::client::StdRequestSerializer)]
823        request: &super::super::super::super::objects::datasource::api::BatchGetSeriesCountRequest,
824    ) -> Result<
825        super::super::super::super::objects::datasource::api::BatchGetSeriesCountResponse,
826        conjure_http::private::Error,
827    >;
828    /// Returns (channel, full-tag-map) entries for a specific channel in a dataset.
829    /// If tags are provided, each entry must match all provided key/value pairs; extra tags may still be present.
830    /// Only numeric-data series are returned; video series are excluded.
831    #[endpoint(
832        method = POST,
833        path = "/data-source/v1/data-sources/get-matching-channels-with-tags",
834        name = "getMatchingChannelsWithTags",
835        accept = conjure_http::client::StdResponseDeserializer
836    )]
837    async fn get_matching_channels_with_tags(
838        &self,
839        #[auth]
840        auth_: &conjure_object::BearerToken,
841        #[body(serializer = conjure_http::client::StdRequestSerializer)]
842        request: &super::super::super::super::objects::datasource::api::GetMatchingChannelsWithTagsRequest,
843    ) -> Result<
844        super::super::super::super::objects::datasource::api::GetMatchingChannelsWithTagsResponse,
845        conjure_http::private::Error,
846    >;
847}