1pub struct AtpServiceClient<T>
5where
6 T: atrium_xrpc::XrpcClient + Send + Sync,
7{
8 pub service: Service<T>,
9}
10impl<T> AtpServiceClient<T>
11where
12 T: atrium_xrpc::XrpcClient + Send + Sync,
13{
14 pub fn new(xrpc: T) -> Self {
15 Self {
16 service: Service::new(std::sync::Arc::new(xrpc)),
17 }
18 }
19}
20pub struct Service<T>
21where
22 T: atrium_xrpc::XrpcClient + Send + Sync,
23{
24 pub app: app::Service<T>,
25 pub chat: chat::Service<T>,
26 pub com: com::Service<T>,
27 pub tools: tools::Service<T>,
28 pub(crate) _phantom: core::marker::PhantomData<T>,
29}
30pub mod app {
31 pub struct Service<T>
32 where
33 T: atrium_xrpc::XrpcClient + Send + Sync,
34 {
35 #[cfg_attr(docsrs, doc(cfg(feature = "namespace-appbsky")))]
36 #[cfg(feature = "namespace-appbsky")]
37 pub bsky: bsky::Service<T>,
38 pub(crate) _phantom: core::marker::PhantomData<T>,
39 }
40 #[cfg_attr(docsrs, doc(cfg(feature = "namespace-appbsky")))]
41 #[cfg(feature = "namespace-appbsky")]
42 pub mod bsky {
43 pub struct Service<T>
44 where
45 T: atrium_xrpc::XrpcClient + Send + Sync,
46 {
47 pub actor: actor::Service<T>,
48 pub feed: feed::Service<T>,
49 pub graph: graph::Service<T>,
50 pub labeler: labeler::Service<T>,
51 pub notification: notification::Service<T>,
52 pub unspecced: unspecced::Service<T>,
53 pub video: video::Service<T>,
54 pub(crate) _phantom: core::marker::PhantomData<T>,
55 }
56 pub mod actor {
57 pub struct Service<T>
58 where
59 T: atrium_xrpc::XrpcClient + Send + Sync,
60 {
61 pub(crate) xrpc: std::sync::Arc<T>,
62 pub(crate) _phantom: core::marker::PhantomData<T>,
63 }
64 }
65 pub mod feed {
66 pub struct Service<T>
67 where
68 T: atrium_xrpc::XrpcClient + Send + Sync,
69 {
70 pub(crate) xrpc: std::sync::Arc<T>,
71 pub(crate) _phantom: core::marker::PhantomData<T>,
72 }
73 }
74 pub mod graph {
75 pub struct Service<T>
76 where
77 T: atrium_xrpc::XrpcClient + Send + Sync,
78 {
79 pub(crate) xrpc: std::sync::Arc<T>,
80 pub(crate) _phantom: core::marker::PhantomData<T>,
81 }
82 }
83 pub mod labeler {
84 pub struct Service<T>
85 where
86 T: atrium_xrpc::XrpcClient + Send + Sync,
87 {
88 pub(crate) xrpc: std::sync::Arc<T>,
89 pub(crate) _phantom: core::marker::PhantomData<T>,
90 }
91 }
92 pub mod notification {
93 pub struct Service<T>
94 where
95 T: atrium_xrpc::XrpcClient + Send + Sync,
96 {
97 pub(crate) xrpc: std::sync::Arc<T>,
98 pub(crate) _phantom: core::marker::PhantomData<T>,
99 }
100 }
101 pub mod unspecced {
102 pub struct Service<T>
103 where
104 T: atrium_xrpc::XrpcClient + Send + Sync,
105 {
106 pub(crate) xrpc: std::sync::Arc<T>,
107 pub(crate) _phantom: core::marker::PhantomData<T>,
108 }
109 }
110 pub mod video {
111 pub struct Service<T>
112 where
113 T: atrium_xrpc::XrpcClient + Send + Sync,
114 {
115 pub(crate) xrpc: std::sync::Arc<T>,
116 pub(crate) _phantom: core::marker::PhantomData<T>,
117 }
118 }
119 }
120}
121pub mod chat {
122 pub struct Service<T>
123 where
124 T: atrium_xrpc::XrpcClient + Send + Sync,
125 {
126 #[cfg_attr(docsrs, doc(cfg(feature = "namespace-chatbsky")))]
127 #[cfg(feature = "namespace-chatbsky")]
128 pub bsky: bsky::Service<T>,
129 pub(crate) _phantom: core::marker::PhantomData<T>,
130 }
131 #[cfg_attr(docsrs, doc(cfg(feature = "namespace-chatbsky")))]
132 #[cfg(feature = "namespace-chatbsky")]
133 pub mod bsky {
134 pub struct Service<T>
135 where
136 T: atrium_xrpc::XrpcClient + Send + Sync,
137 {
138 pub actor: actor::Service<T>,
139 pub convo: convo::Service<T>,
140 pub moderation: moderation::Service<T>,
141 pub(crate) _phantom: core::marker::PhantomData<T>,
142 }
143 pub mod actor {
144 pub struct Service<T>
145 where
146 T: atrium_xrpc::XrpcClient + Send + Sync,
147 {
148 pub(crate) xrpc: std::sync::Arc<T>,
149 pub(crate) _phantom: core::marker::PhantomData<T>,
150 }
151 }
152 pub mod convo {
153 pub struct Service<T>
154 where
155 T: atrium_xrpc::XrpcClient + Send + Sync,
156 {
157 pub(crate) xrpc: std::sync::Arc<T>,
158 pub(crate) _phantom: core::marker::PhantomData<T>,
159 }
160 }
161 pub mod moderation {
162 pub struct Service<T>
163 where
164 T: atrium_xrpc::XrpcClient + Send + Sync,
165 {
166 pub(crate) xrpc: std::sync::Arc<T>,
167 pub(crate) _phantom: core::marker::PhantomData<T>,
168 }
169 }
170 }
171}
172pub mod com {
173 pub struct Service<T>
174 where
175 T: atrium_xrpc::XrpcClient + Send + Sync,
176 {
177 pub atproto: atproto::Service<T>,
178 pub(crate) _phantom: core::marker::PhantomData<T>,
179 }
180 pub mod atproto {
181 pub struct Service<T>
182 where
183 T: atrium_xrpc::XrpcClient + Send + Sync,
184 {
185 pub admin: admin::Service<T>,
186 pub identity: identity::Service<T>,
187 pub label: label::Service<T>,
188 pub moderation: moderation::Service<T>,
189 pub repo: repo::Service<T>,
190 pub server: server::Service<T>,
191 pub sync: sync::Service<T>,
192 pub temp: temp::Service<T>,
193 pub(crate) _phantom: core::marker::PhantomData<T>,
194 }
195 pub mod admin {
196 pub struct Service<T>
197 where
198 T: atrium_xrpc::XrpcClient + Send + Sync,
199 {
200 pub(crate) xrpc: std::sync::Arc<T>,
201 pub(crate) _phantom: core::marker::PhantomData<T>,
202 }
203 }
204 pub mod identity {
205 pub struct Service<T>
206 where
207 T: atrium_xrpc::XrpcClient + Send + Sync,
208 {
209 pub(crate) xrpc: std::sync::Arc<T>,
210 pub(crate) _phantom: core::marker::PhantomData<T>,
211 }
212 }
213 pub mod label {
214 pub struct Service<T>
215 where
216 T: atrium_xrpc::XrpcClient + Send + Sync,
217 {
218 pub(crate) xrpc: std::sync::Arc<T>,
219 pub(crate) _phantom: core::marker::PhantomData<T>,
220 }
221 }
222 pub mod moderation {
223 pub struct Service<T>
224 where
225 T: atrium_xrpc::XrpcClient + Send + Sync,
226 {
227 pub(crate) xrpc: std::sync::Arc<T>,
228 pub(crate) _phantom: core::marker::PhantomData<T>,
229 }
230 }
231 pub mod repo {
232 pub struct Service<T>
233 where
234 T: atrium_xrpc::XrpcClient + Send + Sync,
235 {
236 pub(crate) xrpc: std::sync::Arc<T>,
237 pub(crate) _phantom: core::marker::PhantomData<T>,
238 }
239 }
240 pub mod server {
241 pub struct Service<T>
242 where
243 T: atrium_xrpc::XrpcClient + Send + Sync,
244 {
245 pub(crate) xrpc: std::sync::Arc<T>,
246 pub(crate) _phantom: core::marker::PhantomData<T>,
247 }
248 }
249 pub mod sync {
250 pub struct Service<T>
251 where
252 T: atrium_xrpc::XrpcClient + Send + Sync,
253 {
254 pub(crate) xrpc: std::sync::Arc<T>,
255 pub(crate) _phantom: core::marker::PhantomData<T>,
256 }
257 }
258 pub mod temp {
259 pub struct Service<T>
260 where
261 T: atrium_xrpc::XrpcClient + Send + Sync,
262 {
263 pub(crate) xrpc: std::sync::Arc<T>,
264 pub(crate) _phantom: core::marker::PhantomData<T>,
265 }
266 }
267 }
268}
269pub mod tools {
270 pub struct Service<T>
271 where
272 T: atrium_xrpc::XrpcClient + Send + Sync,
273 {
274 #[cfg_attr(docsrs, doc(cfg(feature = "namespace-toolsozone")))]
275 #[cfg(feature = "namespace-toolsozone")]
276 pub ozone: ozone::Service<T>,
277 pub(crate) _phantom: core::marker::PhantomData<T>,
278 }
279 #[cfg_attr(docsrs, doc(cfg(feature = "namespace-toolsozone")))]
280 #[cfg(feature = "namespace-toolsozone")]
281 pub mod ozone {
282 pub struct Service<T>
283 where
284 T: atrium_xrpc::XrpcClient + Send + Sync,
285 {
286 pub communication: communication::Service<T>,
287 pub hosting: hosting::Service<T>,
288 pub moderation: moderation::Service<T>,
289 pub server: server::Service<T>,
290 pub set: set::Service<T>,
291 pub setting: setting::Service<T>,
292 pub signature: signature::Service<T>,
293 pub team: team::Service<T>,
294 pub verification: verification::Service<T>,
295 pub(crate) _phantom: core::marker::PhantomData<T>,
296 }
297 pub mod communication {
298 pub struct Service<T>
299 where
300 T: atrium_xrpc::XrpcClient + Send + Sync,
301 {
302 pub(crate) xrpc: std::sync::Arc<T>,
303 pub(crate) _phantom: core::marker::PhantomData<T>,
304 }
305 }
306 pub mod hosting {
307 pub struct Service<T>
308 where
309 T: atrium_xrpc::XrpcClient + Send + Sync,
310 {
311 pub(crate) xrpc: std::sync::Arc<T>,
312 pub(crate) _phantom: core::marker::PhantomData<T>,
313 }
314 }
315 pub mod moderation {
316 pub struct Service<T>
317 where
318 T: atrium_xrpc::XrpcClient + Send + Sync,
319 {
320 pub(crate) xrpc: std::sync::Arc<T>,
321 pub(crate) _phantom: core::marker::PhantomData<T>,
322 }
323 }
324 pub mod server {
325 pub struct Service<T>
326 where
327 T: atrium_xrpc::XrpcClient + Send + Sync,
328 {
329 pub(crate) xrpc: std::sync::Arc<T>,
330 pub(crate) _phantom: core::marker::PhantomData<T>,
331 }
332 }
333 pub mod set {
334 pub struct Service<T>
335 where
336 T: atrium_xrpc::XrpcClient + Send + Sync,
337 {
338 pub(crate) xrpc: std::sync::Arc<T>,
339 pub(crate) _phantom: core::marker::PhantomData<T>,
340 }
341 }
342 pub mod setting {
343 pub struct Service<T>
344 where
345 T: atrium_xrpc::XrpcClient + Send + Sync,
346 {
347 pub(crate) xrpc: std::sync::Arc<T>,
348 pub(crate) _phantom: core::marker::PhantomData<T>,
349 }
350 }
351 pub mod signature {
352 pub struct Service<T>
353 where
354 T: atrium_xrpc::XrpcClient + Send + Sync,
355 {
356 pub(crate) xrpc: std::sync::Arc<T>,
357 pub(crate) _phantom: core::marker::PhantomData<T>,
358 }
359 }
360 pub mod team {
361 pub struct Service<T>
362 where
363 T: atrium_xrpc::XrpcClient + Send + Sync,
364 {
365 pub(crate) xrpc: std::sync::Arc<T>,
366 pub(crate) _phantom: core::marker::PhantomData<T>,
367 }
368 }
369 pub mod verification {
370 pub struct Service<T>
371 where
372 T: atrium_xrpc::XrpcClient + Send + Sync,
373 {
374 pub(crate) xrpc: std::sync::Arc<T>,
375 pub(crate) _phantom: core::marker::PhantomData<T>,
376 }
377 }
378 }
379}
380impl<T> self::Service<T>
381where
382 T: atrium_xrpc::XrpcClient + Send + Sync,
383{
384 #[allow(unused_variables)]
385 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
386 Self {
387 app: app::Service::new(std::sync::Arc::clone(&xrpc)),
388 chat: chat::Service::new(std::sync::Arc::clone(&xrpc)),
389 com: com::Service::new(std::sync::Arc::clone(&xrpc)),
390 tools: tools::Service::new(std::sync::Arc::clone(&xrpc)),
391 _phantom: core::marker::PhantomData,
392 }
393 }
394}
395impl<T> app::Service<T>
396where
397 T: atrium_xrpc::XrpcClient + Send + Sync,
398{
399 #[allow(unused_variables)]
400 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
401 Self {
402 #[cfg(feature = "namespace-appbsky")]
403 bsky: app::bsky::Service::new(std::sync::Arc::clone(&xrpc)),
404 _phantom: core::marker::PhantomData,
405 }
406 }
407}
408#[cfg(feature = "namespace-appbsky")]
409impl<T> app::bsky::Service<T>
410where
411 T: atrium_xrpc::XrpcClient + Send + Sync,
412{
413 #[allow(unused_variables)]
414 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
415 Self {
416 actor: app::bsky::actor::Service::new(std::sync::Arc::clone(&xrpc)),
417 feed: app::bsky::feed::Service::new(std::sync::Arc::clone(&xrpc)),
418 graph: app::bsky::graph::Service::new(std::sync::Arc::clone(&xrpc)),
419 labeler: app::bsky::labeler::Service::new(std::sync::Arc::clone(&xrpc)),
420 notification: app::bsky::notification::Service::new(
421 std::sync::Arc::clone(&xrpc),
422 ),
423 unspecced: app::bsky::unspecced::Service::new(std::sync::Arc::clone(&xrpc)),
424 video: app::bsky::video::Service::new(std::sync::Arc::clone(&xrpc)),
425 _phantom: core::marker::PhantomData,
426 }
427 }
428}
429#[cfg(feature = "namespace-appbsky")]
430impl<T> app::bsky::actor::Service<T>
431where
432 T: atrium_xrpc::XrpcClient + Send + Sync,
433{
434 #[allow(unused_variables)]
435 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
436 Self {
437 xrpc,
438 _phantom: core::marker::PhantomData,
439 }
440 }
441 pub async fn get_preferences(
443 &self,
444 params: crate::app::bsky::actor::get_preferences::Parameters,
445 ) -> atrium_xrpc::Result<
446 crate::app::bsky::actor::get_preferences::Output,
447 crate::app::bsky::actor::get_preferences::Error,
448 > {
449 let response = self
450 .xrpc
451 .send_xrpc::<
452 _,
453 (),
454 _,
455 _,
456 >(
457 &atrium_xrpc::XrpcRequest {
458 method: http::Method::GET,
459 nsid: crate::app::bsky::actor::get_preferences::NSID.into(),
460 parameters: Some(params),
461 input: None,
462 encoding: None,
463 },
464 )
465 .await?;
466 match response {
467 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
468 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
469 }
470 }
471 pub async fn get_profile(
473 &self,
474 params: crate::app::bsky::actor::get_profile::Parameters,
475 ) -> atrium_xrpc::Result<
476 crate::app::bsky::actor::get_profile::Output,
477 crate::app::bsky::actor::get_profile::Error,
478 > {
479 let response = self
480 .xrpc
481 .send_xrpc::<
482 _,
483 (),
484 _,
485 _,
486 >(
487 &atrium_xrpc::XrpcRequest {
488 method: http::Method::GET,
489 nsid: crate::app::bsky::actor::get_profile::NSID.into(),
490 parameters: Some(params),
491 input: None,
492 encoding: None,
493 },
494 )
495 .await?;
496 match response {
497 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
498 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
499 }
500 }
501 pub async fn get_profiles(
503 &self,
504 params: crate::app::bsky::actor::get_profiles::Parameters,
505 ) -> atrium_xrpc::Result<
506 crate::app::bsky::actor::get_profiles::Output,
507 crate::app::bsky::actor::get_profiles::Error,
508 > {
509 let response = self
510 .xrpc
511 .send_xrpc::<
512 _,
513 (),
514 _,
515 _,
516 >(
517 &atrium_xrpc::XrpcRequest {
518 method: http::Method::GET,
519 nsid: crate::app::bsky::actor::get_profiles::NSID.into(),
520 parameters: Some(params),
521 input: None,
522 encoding: None,
523 },
524 )
525 .await?;
526 match response {
527 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
528 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
529 }
530 }
531 pub async fn get_suggestions(
533 &self,
534 params: crate::app::bsky::actor::get_suggestions::Parameters,
535 ) -> atrium_xrpc::Result<
536 crate::app::bsky::actor::get_suggestions::Output,
537 crate::app::bsky::actor::get_suggestions::Error,
538 > {
539 let response = self
540 .xrpc
541 .send_xrpc::<
542 _,
543 (),
544 _,
545 _,
546 >(
547 &atrium_xrpc::XrpcRequest {
548 method: http::Method::GET,
549 nsid: crate::app::bsky::actor::get_suggestions::NSID.into(),
550 parameters: Some(params),
551 input: None,
552 encoding: None,
553 },
554 )
555 .await?;
556 match response {
557 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
558 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
559 }
560 }
561 pub async fn put_preferences(
563 &self,
564 input: crate::app::bsky::actor::put_preferences::Input,
565 ) -> atrium_xrpc::Result<(), crate::app::bsky::actor::put_preferences::Error> {
566 let response = self
567 .xrpc
568 .send_xrpc::<
569 (),
570 _,
571 (),
572 _,
573 >(
574 &atrium_xrpc::XrpcRequest {
575 method: http::Method::POST,
576 nsid: crate::app::bsky::actor::put_preferences::NSID.into(),
577 parameters: None,
578 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
579 encoding: Some(String::from("application/json")),
580 },
581 )
582 .await?;
583 match response {
584 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
585 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
586 }
587 }
588 pub async fn search_actors(
590 &self,
591 params: crate::app::bsky::actor::search_actors::Parameters,
592 ) -> atrium_xrpc::Result<
593 crate::app::bsky::actor::search_actors::Output,
594 crate::app::bsky::actor::search_actors::Error,
595 > {
596 let response = self
597 .xrpc
598 .send_xrpc::<
599 _,
600 (),
601 _,
602 _,
603 >(
604 &atrium_xrpc::XrpcRequest {
605 method: http::Method::GET,
606 nsid: crate::app::bsky::actor::search_actors::NSID.into(),
607 parameters: Some(params),
608 input: None,
609 encoding: None,
610 },
611 )
612 .await?;
613 match response {
614 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
615 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
616 }
617 }
618 pub async fn search_actors_typeahead(
620 &self,
621 params: crate::app::bsky::actor::search_actors_typeahead::Parameters,
622 ) -> atrium_xrpc::Result<
623 crate::app::bsky::actor::search_actors_typeahead::Output,
624 crate::app::bsky::actor::search_actors_typeahead::Error,
625 > {
626 let response = self
627 .xrpc
628 .send_xrpc::<
629 _,
630 (),
631 _,
632 _,
633 >(
634 &atrium_xrpc::XrpcRequest {
635 method: http::Method::GET,
636 nsid: crate::app::bsky::actor::search_actors_typeahead::NSID.into(),
637 parameters: Some(params),
638 input: None,
639 encoding: None,
640 },
641 )
642 .await?;
643 match response {
644 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
645 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
646 }
647 }
648}
649#[cfg(feature = "namespace-appbsky")]
650impl<T> app::bsky::feed::Service<T>
651where
652 T: atrium_xrpc::XrpcClient + Send + Sync,
653{
654 #[allow(unused_variables)]
655 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
656 Self {
657 xrpc,
658 _phantom: core::marker::PhantomData,
659 }
660 }
661 pub async fn describe_feed_generator(
663 &self,
664 ) -> atrium_xrpc::Result<
665 crate::app::bsky::feed::describe_feed_generator::Output,
666 crate::app::bsky::feed::describe_feed_generator::Error,
667 > {
668 let response = self
669 .xrpc
670 .send_xrpc::<
671 (),
672 (),
673 _,
674 _,
675 >(
676 &atrium_xrpc::XrpcRequest {
677 method: http::Method::GET,
678 nsid: crate::app::bsky::feed::describe_feed_generator::NSID.into(),
679 parameters: None,
680 input: None,
681 encoding: None,
682 },
683 )
684 .await?;
685 match response {
686 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
687 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
688 }
689 }
690 pub async fn get_actor_feeds(
692 &self,
693 params: crate::app::bsky::feed::get_actor_feeds::Parameters,
694 ) -> atrium_xrpc::Result<
695 crate::app::bsky::feed::get_actor_feeds::Output,
696 crate::app::bsky::feed::get_actor_feeds::Error,
697 > {
698 let response = self
699 .xrpc
700 .send_xrpc::<
701 _,
702 (),
703 _,
704 _,
705 >(
706 &atrium_xrpc::XrpcRequest {
707 method: http::Method::GET,
708 nsid: crate::app::bsky::feed::get_actor_feeds::NSID.into(),
709 parameters: Some(params),
710 input: None,
711 encoding: None,
712 },
713 )
714 .await?;
715 match response {
716 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
717 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
718 }
719 }
720 pub async fn get_actor_likes(
722 &self,
723 params: crate::app::bsky::feed::get_actor_likes::Parameters,
724 ) -> atrium_xrpc::Result<
725 crate::app::bsky::feed::get_actor_likes::Output,
726 crate::app::bsky::feed::get_actor_likes::Error,
727 > {
728 let response = self
729 .xrpc
730 .send_xrpc::<
731 _,
732 (),
733 _,
734 _,
735 >(
736 &atrium_xrpc::XrpcRequest {
737 method: http::Method::GET,
738 nsid: crate::app::bsky::feed::get_actor_likes::NSID.into(),
739 parameters: Some(params),
740 input: None,
741 encoding: None,
742 },
743 )
744 .await?;
745 match response {
746 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
747 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
748 }
749 }
750 pub async fn get_author_feed(
752 &self,
753 params: crate::app::bsky::feed::get_author_feed::Parameters,
754 ) -> atrium_xrpc::Result<
755 crate::app::bsky::feed::get_author_feed::Output,
756 crate::app::bsky::feed::get_author_feed::Error,
757 > {
758 let response = self
759 .xrpc
760 .send_xrpc::<
761 _,
762 (),
763 _,
764 _,
765 >(
766 &atrium_xrpc::XrpcRequest {
767 method: http::Method::GET,
768 nsid: crate::app::bsky::feed::get_author_feed::NSID.into(),
769 parameters: Some(params),
770 input: None,
771 encoding: None,
772 },
773 )
774 .await?;
775 match response {
776 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
777 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
778 }
779 }
780 pub async fn get_feed(
782 &self,
783 params: crate::app::bsky::feed::get_feed::Parameters,
784 ) -> atrium_xrpc::Result<
785 crate::app::bsky::feed::get_feed::Output,
786 crate::app::bsky::feed::get_feed::Error,
787 > {
788 let response = self
789 .xrpc
790 .send_xrpc::<
791 _,
792 (),
793 _,
794 _,
795 >(
796 &atrium_xrpc::XrpcRequest {
797 method: http::Method::GET,
798 nsid: crate::app::bsky::feed::get_feed::NSID.into(),
799 parameters: Some(params),
800 input: None,
801 encoding: None,
802 },
803 )
804 .await?;
805 match response {
806 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
807 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
808 }
809 }
810 pub async fn get_feed_generator(
812 &self,
813 params: crate::app::bsky::feed::get_feed_generator::Parameters,
814 ) -> atrium_xrpc::Result<
815 crate::app::bsky::feed::get_feed_generator::Output,
816 crate::app::bsky::feed::get_feed_generator::Error,
817 > {
818 let response = self
819 .xrpc
820 .send_xrpc::<
821 _,
822 (),
823 _,
824 _,
825 >(
826 &atrium_xrpc::XrpcRequest {
827 method: http::Method::GET,
828 nsid: crate::app::bsky::feed::get_feed_generator::NSID.into(),
829 parameters: Some(params),
830 input: None,
831 encoding: None,
832 },
833 )
834 .await?;
835 match response {
836 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
837 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
838 }
839 }
840 pub async fn get_feed_generators(
842 &self,
843 params: crate::app::bsky::feed::get_feed_generators::Parameters,
844 ) -> atrium_xrpc::Result<
845 crate::app::bsky::feed::get_feed_generators::Output,
846 crate::app::bsky::feed::get_feed_generators::Error,
847 > {
848 let response = self
849 .xrpc
850 .send_xrpc::<
851 _,
852 (),
853 _,
854 _,
855 >(
856 &atrium_xrpc::XrpcRequest {
857 method: http::Method::GET,
858 nsid: crate::app::bsky::feed::get_feed_generators::NSID.into(),
859 parameters: Some(params),
860 input: None,
861 encoding: None,
862 },
863 )
864 .await?;
865 match response {
866 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
867 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
868 }
869 }
870 pub async fn get_feed_skeleton(
872 &self,
873 params: crate::app::bsky::feed::get_feed_skeleton::Parameters,
874 ) -> atrium_xrpc::Result<
875 crate::app::bsky::feed::get_feed_skeleton::Output,
876 crate::app::bsky::feed::get_feed_skeleton::Error,
877 > {
878 let response = self
879 .xrpc
880 .send_xrpc::<
881 _,
882 (),
883 _,
884 _,
885 >(
886 &atrium_xrpc::XrpcRequest {
887 method: http::Method::GET,
888 nsid: crate::app::bsky::feed::get_feed_skeleton::NSID.into(),
889 parameters: Some(params),
890 input: None,
891 encoding: None,
892 },
893 )
894 .await?;
895 match response {
896 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
897 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
898 }
899 }
900 pub async fn get_likes(
902 &self,
903 params: crate::app::bsky::feed::get_likes::Parameters,
904 ) -> atrium_xrpc::Result<
905 crate::app::bsky::feed::get_likes::Output,
906 crate::app::bsky::feed::get_likes::Error,
907 > {
908 let response = self
909 .xrpc
910 .send_xrpc::<
911 _,
912 (),
913 _,
914 _,
915 >(
916 &atrium_xrpc::XrpcRequest {
917 method: http::Method::GET,
918 nsid: crate::app::bsky::feed::get_likes::NSID.into(),
919 parameters: Some(params),
920 input: None,
921 encoding: None,
922 },
923 )
924 .await?;
925 match response {
926 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
927 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
928 }
929 }
930 pub async fn get_list_feed(
932 &self,
933 params: crate::app::bsky::feed::get_list_feed::Parameters,
934 ) -> atrium_xrpc::Result<
935 crate::app::bsky::feed::get_list_feed::Output,
936 crate::app::bsky::feed::get_list_feed::Error,
937 > {
938 let response = self
939 .xrpc
940 .send_xrpc::<
941 _,
942 (),
943 _,
944 _,
945 >(
946 &atrium_xrpc::XrpcRequest {
947 method: http::Method::GET,
948 nsid: crate::app::bsky::feed::get_list_feed::NSID.into(),
949 parameters: Some(params),
950 input: None,
951 encoding: None,
952 },
953 )
954 .await?;
955 match response {
956 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
957 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
958 }
959 }
960 pub async fn get_post_thread(
962 &self,
963 params: crate::app::bsky::feed::get_post_thread::Parameters,
964 ) -> atrium_xrpc::Result<
965 crate::app::bsky::feed::get_post_thread::Output,
966 crate::app::bsky::feed::get_post_thread::Error,
967 > {
968 let response = self
969 .xrpc
970 .send_xrpc::<
971 _,
972 (),
973 _,
974 _,
975 >(
976 &atrium_xrpc::XrpcRequest {
977 method: http::Method::GET,
978 nsid: crate::app::bsky::feed::get_post_thread::NSID.into(),
979 parameters: Some(params),
980 input: None,
981 encoding: None,
982 },
983 )
984 .await?;
985 match response {
986 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
987 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
988 }
989 }
990 pub async fn get_posts(
992 &self,
993 params: crate::app::bsky::feed::get_posts::Parameters,
994 ) -> atrium_xrpc::Result<
995 crate::app::bsky::feed::get_posts::Output,
996 crate::app::bsky::feed::get_posts::Error,
997 > {
998 let response = self
999 .xrpc
1000 .send_xrpc::<
1001 _,
1002 (),
1003 _,
1004 _,
1005 >(
1006 &atrium_xrpc::XrpcRequest {
1007 method: http::Method::GET,
1008 nsid: crate::app::bsky::feed::get_posts::NSID.into(),
1009 parameters: Some(params),
1010 input: None,
1011 encoding: None,
1012 },
1013 )
1014 .await?;
1015 match response {
1016 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1017 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1018 }
1019 }
1020 pub async fn get_quotes(
1022 &self,
1023 params: crate::app::bsky::feed::get_quotes::Parameters,
1024 ) -> atrium_xrpc::Result<
1025 crate::app::bsky::feed::get_quotes::Output,
1026 crate::app::bsky::feed::get_quotes::Error,
1027 > {
1028 let response = self
1029 .xrpc
1030 .send_xrpc::<
1031 _,
1032 (),
1033 _,
1034 _,
1035 >(
1036 &atrium_xrpc::XrpcRequest {
1037 method: http::Method::GET,
1038 nsid: crate::app::bsky::feed::get_quotes::NSID.into(),
1039 parameters: Some(params),
1040 input: None,
1041 encoding: None,
1042 },
1043 )
1044 .await?;
1045 match response {
1046 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1047 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1048 }
1049 }
1050 pub async fn get_reposted_by(
1052 &self,
1053 params: crate::app::bsky::feed::get_reposted_by::Parameters,
1054 ) -> atrium_xrpc::Result<
1055 crate::app::bsky::feed::get_reposted_by::Output,
1056 crate::app::bsky::feed::get_reposted_by::Error,
1057 > {
1058 let response = self
1059 .xrpc
1060 .send_xrpc::<
1061 _,
1062 (),
1063 _,
1064 _,
1065 >(
1066 &atrium_xrpc::XrpcRequest {
1067 method: http::Method::GET,
1068 nsid: crate::app::bsky::feed::get_reposted_by::NSID.into(),
1069 parameters: Some(params),
1070 input: None,
1071 encoding: None,
1072 },
1073 )
1074 .await?;
1075 match response {
1076 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1077 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1078 }
1079 }
1080 pub async fn get_suggested_feeds(
1082 &self,
1083 params: crate::app::bsky::feed::get_suggested_feeds::Parameters,
1084 ) -> atrium_xrpc::Result<
1085 crate::app::bsky::feed::get_suggested_feeds::Output,
1086 crate::app::bsky::feed::get_suggested_feeds::Error,
1087 > {
1088 let response = self
1089 .xrpc
1090 .send_xrpc::<
1091 _,
1092 (),
1093 _,
1094 _,
1095 >(
1096 &atrium_xrpc::XrpcRequest {
1097 method: http::Method::GET,
1098 nsid: crate::app::bsky::feed::get_suggested_feeds::NSID.into(),
1099 parameters: Some(params),
1100 input: None,
1101 encoding: None,
1102 },
1103 )
1104 .await?;
1105 match response {
1106 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1107 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1108 }
1109 }
1110 pub async fn get_timeline(
1112 &self,
1113 params: crate::app::bsky::feed::get_timeline::Parameters,
1114 ) -> atrium_xrpc::Result<
1115 crate::app::bsky::feed::get_timeline::Output,
1116 crate::app::bsky::feed::get_timeline::Error,
1117 > {
1118 let response = self
1119 .xrpc
1120 .send_xrpc::<
1121 _,
1122 (),
1123 _,
1124 _,
1125 >(
1126 &atrium_xrpc::XrpcRequest {
1127 method: http::Method::GET,
1128 nsid: crate::app::bsky::feed::get_timeline::NSID.into(),
1129 parameters: Some(params),
1130 input: None,
1131 encoding: None,
1132 },
1133 )
1134 .await?;
1135 match response {
1136 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1137 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1138 }
1139 }
1140 pub async fn search_posts(
1142 &self,
1143 params: crate::app::bsky::feed::search_posts::Parameters,
1144 ) -> atrium_xrpc::Result<
1145 crate::app::bsky::feed::search_posts::Output,
1146 crate::app::bsky::feed::search_posts::Error,
1147 > {
1148 let response = self
1149 .xrpc
1150 .send_xrpc::<
1151 _,
1152 (),
1153 _,
1154 _,
1155 >(
1156 &atrium_xrpc::XrpcRequest {
1157 method: http::Method::GET,
1158 nsid: crate::app::bsky::feed::search_posts::NSID.into(),
1159 parameters: Some(params),
1160 input: None,
1161 encoding: None,
1162 },
1163 )
1164 .await?;
1165 match response {
1166 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1167 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1168 }
1169 }
1170 pub async fn send_interactions(
1172 &self,
1173 input: crate::app::bsky::feed::send_interactions::Input,
1174 ) -> atrium_xrpc::Result<
1175 crate::app::bsky::feed::send_interactions::Output,
1176 crate::app::bsky::feed::send_interactions::Error,
1177 > {
1178 let response = self
1179 .xrpc
1180 .send_xrpc::<
1181 (),
1182 _,
1183 _,
1184 _,
1185 >(
1186 &atrium_xrpc::XrpcRequest {
1187 method: http::Method::POST,
1188 nsid: crate::app::bsky::feed::send_interactions::NSID.into(),
1189 parameters: None,
1190 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
1191 encoding: Some(String::from("application/json")),
1192 },
1193 )
1194 .await?;
1195 match response {
1196 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1197 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1198 }
1199 }
1200}
1201#[cfg(feature = "namespace-appbsky")]
1202impl<T> app::bsky::graph::Service<T>
1203where
1204 T: atrium_xrpc::XrpcClient + Send + Sync,
1205{
1206 #[allow(unused_variables)]
1207 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
1208 Self {
1209 xrpc,
1210 _phantom: core::marker::PhantomData,
1211 }
1212 }
1213 pub async fn get_actor_starter_packs(
1215 &self,
1216 params: crate::app::bsky::graph::get_actor_starter_packs::Parameters,
1217 ) -> atrium_xrpc::Result<
1218 crate::app::bsky::graph::get_actor_starter_packs::Output,
1219 crate::app::bsky::graph::get_actor_starter_packs::Error,
1220 > {
1221 let response = self
1222 .xrpc
1223 .send_xrpc::<
1224 _,
1225 (),
1226 _,
1227 _,
1228 >(
1229 &atrium_xrpc::XrpcRequest {
1230 method: http::Method::GET,
1231 nsid: crate::app::bsky::graph::get_actor_starter_packs::NSID.into(),
1232 parameters: Some(params),
1233 input: None,
1234 encoding: None,
1235 },
1236 )
1237 .await?;
1238 match response {
1239 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1240 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1241 }
1242 }
1243 pub async fn get_blocks(
1245 &self,
1246 params: crate::app::bsky::graph::get_blocks::Parameters,
1247 ) -> atrium_xrpc::Result<
1248 crate::app::bsky::graph::get_blocks::Output,
1249 crate::app::bsky::graph::get_blocks::Error,
1250 > {
1251 let response = self
1252 .xrpc
1253 .send_xrpc::<
1254 _,
1255 (),
1256 _,
1257 _,
1258 >(
1259 &atrium_xrpc::XrpcRequest {
1260 method: http::Method::GET,
1261 nsid: crate::app::bsky::graph::get_blocks::NSID.into(),
1262 parameters: Some(params),
1263 input: None,
1264 encoding: None,
1265 },
1266 )
1267 .await?;
1268 match response {
1269 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1270 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1271 }
1272 }
1273 pub async fn get_followers(
1275 &self,
1276 params: crate::app::bsky::graph::get_followers::Parameters,
1277 ) -> atrium_xrpc::Result<
1278 crate::app::bsky::graph::get_followers::Output,
1279 crate::app::bsky::graph::get_followers::Error,
1280 > {
1281 let response = self
1282 .xrpc
1283 .send_xrpc::<
1284 _,
1285 (),
1286 _,
1287 _,
1288 >(
1289 &atrium_xrpc::XrpcRequest {
1290 method: http::Method::GET,
1291 nsid: crate::app::bsky::graph::get_followers::NSID.into(),
1292 parameters: Some(params),
1293 input: None,
1294 encoding: None,
1295 },
1296 )
1297 .await?;
1298 match response {
1299 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1300 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1301 }
1302 }
1303 pub async fn get_follows(
1305 &self,
1306 params: crate::app::bsky::graph::get_follows::Parameters,
1307 ) -> atrium_xrpc::Result<
1308 crate::app::bsky::graph::get_follows::Output,
1309 crate::app::bsky::graph::get_follows::Error,
1310 > {
1311 let response = self
1312 .xrpc
1313 .send_xrpc::<
1314 _,
1315 (),
1316 _,
1317 _,
1318 >(
1319 &atrium_xrpc::XrpcRequest {
1320 method: http::Method::GET,
1321 nsid: crate::app::bsky::graph::get_follows::NSID.into(),
1322 parameters: Some(params),
1323 input: None,
1324 encoding: None,
1325 },
1326 )
1327 .await?;
1328 match response {
1329 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1330 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1331 }
1332 }
1333 pub async fn get_known_followers(
1335 &self,
1336 params: crate::app::bsky::graph::get_known_followers::Parameters,
1337 ) -> atrium_xrpc::Result<
1338 crate::app::bsky::graph::get_known_followers::Output,
1339 crate::app::bsky::graph::get_known_followers::Error,
1340 > {
1341 let response = self
1342 .xrpc
1343 .send_xrpc::<
1344 _,
1345 (),
1346 _,
1347 _,
1348 >(
1349 &atrium_xrpc::XrpcRequest {
1350 method: http::Method::GET,
1351 nsid: crate::app::bsky::graph::get_known_followers::NSID.into(),
1352 parameters: Some(params),
1353 input: None,
1354 encoding: None,
1355 },
1356 )
1357 .await?;
1358 match response {
1359 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1360 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1361 }
1362 }
1363 pub async fn get_list(
1365 &self,
1366 params: crate::app::bsky::graph::get_list::Parameters,
1367 ) -> atrium_xrpc::Result<
1368 crate::app::bsky::graph::get_list::Output,
1369 crate::app::bsky::graph::get_list::Error,
1370 > {
1371 let response = self
1372 .xrpc
1373 .send_xrpc::<
1374 _,
1375 (),
1376 _,
1377 _,
1378 >(
1379 &atrium_xrpc::XrpcRequest {
1380 method: http::Method::GET,
1381 nsid: crate::app::bsky::graph::get_list::NSID.into(),
1382 parameters: Some(params),
1383 input: None,
1384 encoding: None,
1385 },
1386 )
1387 .await?;
1388 match response {
1389 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1390 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1391 }
1392 }
1393 pub async fn get_list_blocks(
1395 &self,
1396 params: crate::app::bsky::graph::get_list_blocks::Parameters,
1397 ) -> atrium_xrpc::Result<
1398 crate::app::bsky::graph::get_list_blocks::Output,
1399 crate::app::bsky::graph::get_list_blocks::Error,
1400 > {
1401 let response = self
1402 .xrpc
1403 .send_xrpc::<
1404 _,
1405 (),
1406 _,
1407 _,
1408 >(
1409 &atrium_xrpc::XrpcRequest {
1410 method: http::Method::GET,
1411 nsid: crate::app::bsky::graph::get_list_blocks::NSID.into(),
1412 parameters: Some(params),
1413 input: None,
1414 encoding: None,
1415 },
1416 )
1417 .await?;
1418 match response {
1419 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1420 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1421 }
1422 }
1423 pub async fn get_list_mutes(
1425 &self,
1426 params: crate::app::bsky::graph::get_list_mutes::Parameters,
1427 ) -> atrium_xrpc::Result<
1428 crate::app::bsky::graph::get_list_mutes::Output,
1429 crate::app::bsky::graph::get_list_mutes::Error,
1430 > {
1431 let response = self
1432 .xrpc
1433 .send_xrpc::<
1434 _,
1435 (),
1436 _,
1437 _,
1438 >(
1439 &atrium_xrpc::XrpcRequest {
1440 method: http::Method::GET,
1441 nsid: crate::app::bsky::graph::get_list_mutes::NSID.into(),
1442 parameters: Some(params),
1443 input: None,
1444 encoding: None,
1445 },
1446 )
1447 .await?;
1448 match response {
1449 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1450 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1451 }
1452 }
1453 pub async fn get_lists(
1455 &self,
1456 params: crate::app::bsky::graph::get_lists::Parameters,
1457 ) -> atrium_xrpc::Result<
1458 crate::app::bsky::graph::get_lists::Output,
1459 crate::app::bsky::graph::get_lists::Error,
1460 > {
1461 let response = self
1462 .xrpc
1463 .send_xrpc::<
1464 _,
1465 (),
1466 _,
1467 _,
1468 >(
1469 &atrium_xrpc::XrpcRequest {
1470 method: http::Method::GET,
1471 nsid: crate::app::bsky::graph::get_lists::NSID.into(),
1472 parameters: Some(params),
1473 input: None,
1474 encoding: None,
1475 },
1476 )
1477 .await?;
1478 match response {
1479 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1480 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1481 }
1482 }
1483 pub async fn get_mutes(
1485 &self,
1486 params: crate::app::bsky::graph::get_mutes::Parameters,
1487 ) -> atrium_xrpc::Result<
1488 crate::app::bsky::graph::get_mutes::Output,
1489 crate::app::bsky::graph::get_mutes::Error,
1490 > {
1491 let response = self
1492 .xrpc
1493 .send_xrpc::<
1494 _,
1495 (),
1496 _,
1497 _,
1498 >(
1499 &atrium_xrpc::XrpcRequest {
1500 method: http::Method::GET,
1501 nsid: crate::app::bsky::graph::get_mutes::NSID.into(),
1502 parameters: Some(params),
1503 input: None,
1504 encoding: None,
1505 },
1506 )
1507 .await?;
1508 match response {
1509 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1510 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1511 }
1512 }
1513 pub async fn get_relationships(
1515 &self,
1516 params: crate::app::bsky::graph::get_relationships::Parameters,
1517 ) -> atrium_xrpc::Result<
1518 crate::app::bsky::graph::get_relationships::Output,
1519 crate::app::bsky::graph::get_relationships::Error,
1520 > {
1521 let response = self
1522 .xrpc
1523 .send_xrpc::<
1524 _,
1525 (),
1526 _,
1527 _,
1528 >(
1529 &atrium_xrpc::XrpcRequest {
1530 method: http::Method::GET,
1531 nsid: crate::app::bsky::graph::get_relationships::NSID.into(),
1532 parameters: Some(params),
1533 input: None,
1534 encoding: None,
1535 },
1536 )
1537 .await?;
1538 match response {
1539 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1540 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1541 }
1542 }
1543 pub async fn get_starter_pack(
1545 &self,
1546 params: crate::app::bsky::graph::get_starter_pack::Parameters,
1547 ) -> atrium_xrpc::Result<
1548 crate::app::bsky::graph::get_starter_pack::Output,
1549 crate::app::bsky::graph::get_starter_pack::Error,
1550 > {
1551 let response = self
1552 .xrpc
1553 .send_xrpc::<
1554 _,
1555 (),
1556 _,
1557 _,
1558 >(
1559 &atrium_xrpc::XrpcRequest {
1560 method: http::Method::GET,
1561 nsid: crate::app::bsky::graph::get_starter_pack::NSID.into(),
1562 parameters: Some(params),
1563 input: None,
1564 encoding: None,
1565 },
1566 )
1567 .await?;
1568 match response {
1569 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1570 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1571 }
1572 }
1573 pub async fn get_starter_packs(
1575 &self,
1576 params: crate::app::bsky::graph::get_starter_packs::Parameters,
1577 ) -> atrium_xrpc::Result<
1578 crate::app::bsky::graph::get_starter_packs::Output,
1579 crate::app::bsky::graph::get_starter_packs::Error,
1580 > {
1581 let response = self
1582 .xrpc
1583 .send_xrpc::<
1584 _,
1585 (),
1586 _,
1587 _,
1588 >(
1589 &atrium_xrpc::XrpcRequest {
1590 method: http::Method::GET,
1591 nsid: crate::app::bsky::graph::get_starter_packs::NSID.into(),
1592 parameters: Some(params),
1593 input: None,
1594 encoding: None,
1595 },
1596 )
1597 .await?;
1598 match response {
1599 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1600 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1601 }
1602 }
1603 pub async fn get_suggested_follows_by_actor(
1605 &self,
1606 params: crate::app::bsky::graph::get_suggested_follows_by_actor::Parameters,
1607 ) -> atrium_xrpc::Result<
1608 crate::app::bsky::graph::get_suggested_follows_by_actor::Output,
1609 crate::app::bsky::graph::get_suggested_follows_by_actor::Error,
1610 > {
1611 let response = self
1612 .xrpc
1613 .send_xrpc::<
1614 _,
1615 (),
1616 _,
1617 _,
1618 >(
1619 &atrium_xrpc::XrpcRequest {
1620 method: http::Method::GET,
1621 nsid: crate::app::bsky::graph::get_suggested_follows_by_actor::NSID
1622 .into(),
1623 parameters: Some(params),
1624 input: None,
1625 encoding: None,
1626 },
1627 )
1628 .await?;
1629 match response {
1630 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1631 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1632 }
1633 }
1634 pub async fn mute_actor(
1636 &self,
1637 input: crate::app::bsky::graph::mute_actor::Input,
1638 ) -> atrium_xrpc::Result<(), crate::app::bsky::graph::mute_actor::Error> {
1639 let response = self
1640 .xrpc
1641 .send_xrpc::<
1642 (),
1643 _,
1644 (),
1645 _,
1646 >(
1647 &atrium_xrpc::XrpcRequest {
1648 method: http::Method::POST,
1649 nsid: crate::app::bsky::graph::mute_actor::NSID.into(),
1650 parameters: None,
1651 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
1652 encoding: Some(String::from("application/json")),
1653 },
1654 )
1655 .await?;
1656 match response {
1657 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
1658 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1659 }
1660 }
1661 pub async fn mute_actor_list(
1663 &self,
1664 input: crate::app::bsky::graph::mute_actor_list::Input,
1665 ) -> atrium_xrpc::Result<(), crate::app::bsky::graph::mute_actor_list::Error> {
1666 let response = self
1667 .xrpc
1668 .send_xrpc::<
1669 (),
1670 _,
1671 (),
1672 _,
1673 >(
1674 &atrium_xrpc::XrpcRequest {
1675 method: http::Method::POST,
1676 nsid: crate::app::bsky::graph::mute_actor_list::NSID.into(),
1677 parameters: None,
1678 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
1679 encoding: Some(String::from("application/json")),
1680 },
1681 )
1682 .await?;
1683 match response {
1684 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
1685 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1686 }
1687 }
1688 pub async fn mute_thread(
1690 &self,
1691 input: crate::app::bsky::graph::mute_thread::Input,
1692 ) -> atrium_xrpc::Result<(), crate::app::bsky::graph::mute_thread::Error> {
1693 let response = self
1694 .xrpc
1695 .send_xrpc::<
1696 (),
1697 _,
1698 (),
1699 _,
1700 >(
1701 &atrium_xrpc::XrpcRequest {
1702 method: http::Method::POST,
1703 nsid: crate::app::bsky::graph::mute_thread::NSID.into(),
1704 parameters: None,
1705 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
1706 encoding: Some(String::from("application/json")),
1707 },
1708 )
1709 .await?;
1710 match response {
1711 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
1712 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1713 }
1714 }
1715 pub async fn search_starter_packs(
1717 &self,
1718 params: crate::app::bsky::graph::search_starter_packs::Parameters,
1719 ) -> atrium_xrpc::Result<
1720 crate::app::bsky::graph::search_starter_packs::Output,
1721 crate::app::bsky::graph::search_starter_packs::Error,
1722 > {
1723 let response = self
1724 .xrpc
1725 .send_xrpc::<
1726 _,
1727 (),
1728 _,
1729 _,
1730 >(
1731 &atrium_xrpc::XrpcRequest {
1732 method: http::Method::GET,
1733 nsid: crate::app::bsky::graph::search_starter_packs::NSID.into(),
1734 parameters: Some(params),
1735 input: None,
1736 encoding: None,
1737 },
1738 )
1739 .await?;
1740 match response {
1741 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1742 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1743 }
1744 }
1745 pub async fn unmute_actor(
1747 &self,
1748 input: crate::app::bsky::graph::unmute_actor::Input,
1749 ) -> atrium_xrpc::Result<(), crate::app::bsky::graph::unmute_actor::Error> {
1750 let response = self
1751 .xrpc
1752 .send_xrpc::<
1753 (),
1754 _,
1755 (),
1756 _,
1757 >(
1758 &atrium_xrpc::XrpcRequest {
1759 method: http::Method::POST,
1760 nsid: crate::app::bsky::graph::unmute_actor::NSID.into(),
1761 parameters: None,
1762 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
1763 encoding: Some(String::from("application/json")),
1764 },
1765 )
1766 .await?;
1767 match response {
1768 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
1769 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1770 }
1771 }
1772 pub async fn unmute_actor_list(
1774 &self,
1775 input: crate::app::bsky::graph::unmute_actor_list::Input,
1776 ) -> atrium_xrpc::Result<(), crate::app::bsky::graph::unmute_actor_list::Error> {
1777 let response = self
1778 .xrpc
1779 .send_xrpc::<
1780 (),
1781 _,
1782 (),
1783 _,
1784 >(
1785 &atrium_xrpc::XrpcRequest {
1786 method: http::Method::POST,
1787 nsid: crate::app::bsky::graph::unmute_actor_list::NSID.into(),
1788 parameters: None,
1789 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
1790 encoding: Some(String::from("application/json")),
1791 },
1792 )
1793 .await?;
1794 match response {
1795 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
1796 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1797 }
1798 }
1799 pub async fn unmute_thread(
1801 &self,
1802 input: crate::app::bsky::graph::unmute_thread::Input,
1803 ) -> atrium_xrpc::Result<(), crate::app::bsky::graph::unmute_thread::Error> {
1804 let response = self
1805 .xrpc
1806 .send_xrpc::<
1807 (),
1808 _,
1809 (),
1810 _,
1811 >(
1812 &atrium_xrpc::XrpcRequest {
1813 method: http::Method::POST,
1814 nsid: crate::app::bsky::graph::unmute_thread::NSID.into(),
1815 parameters: None,
1816 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
1817 encoding: Some(String::from("application/json")),
1818 },
1819 )
1820 .await?;
1821 match response {
1822 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
1823 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1824 }
1825 }
1826}
1827#[cfg(feature = "namespace-appbsky")]
1828impl<T> app::bsky::labeler::Service<T>
1829where
1830 T: atrium_xrpc::XrpcClient + Send + Sync,
1831{
1832 #[allow(unused_variables)]
1833 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
1834 Self {
1835 xrpc,
1836 _phantom: core::marker::PhantomData,
1837 }
1838 }
1839 pub async fn get_services(
1841 &self,
1842 params: crate::app::bsky::labeler::get_services::Parameters,
1843 ) -> atrium_xrpc::Result<
1844 crate::app::bsky::labeler::get_services::Output,
1845 crate::app::bsky::labeler::get_services::Error,
1846 > {
1847 let response = self
1848 .xrpc
1849 .send_xrpc::<
1850 _,
1851 (),
1852 _,
1853 _,
1854 >(
1855 &atrium_xrpc::XrpcRequest {
1856 method: http::Method::GET,
1857 nsid: crate::app::bsky::labeler::get_services::NSID.into(),
1858 parameters: Some(params),
1859 input: None,
1860 encoding: None,
1861 },
1862 )
1863 .await?;
1864 match response {
1865 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1866 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1867 }
1868 }
1869}
1870#[cfg(feature = "namespace-appbsky")]
1871impl<T> app::bsky::notification::Service<T>
1872where
1873 T: atrium_xrpc::XrpcClient + Send + Sync,
1874{
1875 #[allow(unused_variables)]
1876 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
1877 Self {
1878 xrpc,
1879 _phantom: core::marker::PhantomData,
1880 }
1881 }
1882 pub async fn get_unread_count(
1884 &self,
1885 params: crate::app::bsky::notification::get_unread_count::Parameters,
1886 ) -> atrium_xrpc::Result<
1887 crate::app::bsky::notification::get_unread_count::Output,
1888 crate::app::bsky::notification::get_unread_count::Error,
1889 > {
1890 let response = self
1891 .xrpc
1892 .send_xrpc::<
1893 _,
1894 (),
1895 _,
1896 _,
1897 >(
1898 &atrium_xrpc::XrpcRequest {
1899 method: http::Method::GET,
1900 nsid: crate::app::bsky::notification::get_unread_count::NSID.into(),
1901 parameters: Some(params),
1902 input: None,
1903 encoding: None,
1904 },
1905 )
1906 .await?;
1907 match response {
1908 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1909 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1910 }
1911 }
1912 pub async fn list_notifications(
1914 &self,
1915 params: crate::app::bsky::notification::list_notifications::Parameters,
1916 ) -> atrium_xrpc::Result<
1917 crate::app::bsky::notification::list_notifications::Output,
1918 crate::app::bsky::notification::list_notifications::Error,
1919 > {
1920 let response = self
1921 .xrpc
1922 .send_xrpc::<
1923 _,
1924 (),
1925 _,
1926 _,
1927 >(
1928 &atrium_xrpc::XrpcRequest {
1929 method: http::Method::GET,
1930 nsid: crate::app::bsky::notification::list_notifications::NSID
1931 .into(),
1932 parameters: Some(params),
1933 input: None,
1934 encoding: None,
1935 },
1936 )
1937 .await?;
1938 match response {
1939 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
1940 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1941 }
1942 }
1943 pub async fn put_preferences(
1945 &self,
1946 input: crate::app::bsky::notification::put_preferences::Input,
1947 ) -> atrium_xrpc::Result<
1948 (),
1949 crate::app::bsky::notification::put_preferences::Error,
1950 > {
1951 let response = self
1952 .xrpc
1953 .send_xrpc::<
1954 (),
1955 _,
1956 (),
1957 _,
1958 >(
1959 &atrium_xrpc::XrpcRequest {
1960 method: http::Method::POST,
1961 nsid: crate::app::bsky::notification::put_preferences::NSID.into(),
1962 parameters: None,
1963 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
1964 encoding: Some(String::from("application/json")),
1965 },
1966 )
1967 .await?;
1968 match response {
1969 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
1970 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1971 }
1972 }
1973 pub async fn register_push(
1975 &self,
1976 input: crate::app::bsky::notification::register_push::Input,
1977 ) -> atrium_xrpc::Result<(), crate::app::bsky::notification::register_push::Error> {
1978 let response = self
1979 .xrpc
1980 .send_xrpc::<
1981 (),
1982 _,
1983 (),
1984 _,
1985 >(
1986 &atrium_xrpc::XrpcRequest {
1987 method: http::Method::POST,
1988 nsid: crate::app::bsky::notification::register_push::NSID.into(),
1989 parameters: None,
1990 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
1991 encoding: Some(String::from("application/json")),
1992 },
1993 )
1994 .await?;
1995 match response {
1996 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
1997 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
1998 }
1999 }
2000 pub async fn update_seen(
2002 &self,
2003 input: crate::app::bsky::notification::update_seen::Input,
2004 ) -> atrium_xrpc::Result<(), crate::app::bsky::notification::update_seen::Error> {
2005 let response = self
2006 .xrpc
2007 .send_xrpc::<
2008 (),
2009 _,
2010 (),
2011 _,
2012 >(
2013 &atrium_xrpc::XrpcRequest {
2014 method: http::Method::POST,
2015 nsid: crate::app::bsky::notification::update_seen::NSID.into(),
2016 parameters: None,
2017 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
2018 encoding: Some(String::from("application/json")),
2019 },
2020 )
2021 .await?;
2022 match response {
2023 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
2024 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2025 }
2026 }
2027}
2028#[cfg(feature = "namespace-appbsky")]
2029impl<T> app::bsky::unspecced::Service<T>
2030where
2031 T: atrium_xrpc::XrpcClient + Send + Sync,
2032{
2033 #[allow(unused_variables)]
2034 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
2035 Self {
2036 xrpc,
2037 _phantom: core::marker::PhantomData,
2038 }
2039 }
2040 pub async fn get_config(
2042 &self,
2043 ) -> atrium_xrpc::Result<
2044 crate::app::bsky::unspecced::get_config::Output,
2045 crate::app::bsky::unspecced::get_config::Error,
2046 > {
2047 let response = self
2048 .xrpc
2049 .send_xrpc::<
2050 (),
2051 (),
2052 _,
2053 _,
2054 >(
2055 &atrium_xrpc::XrpcRequest {
2056 method: http::Method::GET,
2057 nsid: crate::app::bsky::unspecced::get_config::NSID.into(),
2058 parameters: None,
2059 input: None,
2060 encoding: None,
2061 },
2062 )
2063 .await?;
2064 match response {
2065 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2066 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2067 }
2068 }
2069 pub async fn get_popular_feed_generators(
2071 &self,
2072 params: crate::app::bsky::unspecced::get_popular_feed_generators::Parameters,
2073 ) -> atrium_xrpc::Result<
2074 crate::app::bsky::unspecced::get_popular_feed_generators::Output,
2075 crate::app::bsky::unspecced::get_popular_feed_generators::Error,
2076 > {
2077 let response = self
2078 .xrpc
2079 .send_xrpc::<
2080 _,
2081 (),
2082 _,
2083 _,
2084 >(
2085 &atrium_xrpc::XrpcRequest {
2086 method: http::Method::GET,
2087 nsid: crate::app::bsky::unspecced::get_popular_feed_generators::NSID
2088 .into(),
2089 parameters: Some(params),
2090 input: None,
2091 encoding: None,
2092 },
2093 )
2094 .await?;
2095 match response {
2096 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2097 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2098 }
2099 }
2100 pub async fn get_suggested_feeds(
2102 &self,
2103 params: crate::app::bsky::unspecced::get_suggested_feeds::Parameters,
2104 ) -> atrium_xrpc::Result<
2105 crate::app::bsky::unspecced::get_suggested_feeds::Output,
2106 crate::app::bsky::unspecced::get_suggested_feeds::Error,
2107 > {
2108 let response = self
2109 .xrpc
2110 .send_xrpc::<
2111 _,
2112 (),
2113 _,
2114 _,
2115 >(
2116 &atrium_xrpc::XrpcRequest {
2117 method: http::Method::GET,
2118 nsid: crate::app::bsky::unspecced::get_suggested_feeds::NSID.into(),
2119 parameters: Some(params),
2120 input: None,
2121 encoding: None,
2122 },
2123 )
2124 .await?;
2125 match response {
2126 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2127 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2128 }
2129 }
2130 pub async fn get_suggested_feeds_skeleton(
2132 &self,
2133 params: crate::app::bsky::unspecced::get_suggested_feeds_skeleton::Parameters,
2134 ) -> atrium_xrpc::Result<
2135 crate::app::bsky::unspecced::get_suggested_feeds_skeleton::Output,
2136 crate::app::bsky::unspecced::get_suggested_feeds_skeleton::Error,
2137 > {
2138 let response = self
2139 .xrpc
2140 .send_xrpc::<
2141 _,
2142 (),
2143 _,
2144 _,
2145 >(
2146 &atrium_xrpc::XrpcRequest {
2147 method: http::Method::GET,
2148 nsid: crate::app::bsky::unspecced::get_suggested_feeds_skeleton::NSID
2149 .into(),
2150 parameters: Some(params),
2151 input: None,
2152 encoding: None,
2153 },
2154 )
2155 .await?;
2156 match response {
2157 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2158 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2159 }
2160 }
2161 pub async fn get_suggested_starter_packs(
2163 &self,
2164 params: crate::app::bsky::unspecced::get_suggested_starter_packs::Parameters,
2165 ) -> atrium_xrpc::Result<
2166 crate::app::bsky::unspecced::get_suggested_starter_packs::Output,
2167 crate::app::bsky::unspecced::get_suggested_starter_packs::Error,
2168 > {
2169 let response = self
2170 .xrpc
2171 .send_xrpc::<
2172 _,
2173 (),
2174 _,
2175 _,
2176 >(
2177 &atrium_xrpc::XrpcRequest {
2178 method: http::Method::GET,
2179 nsid: crate::app::bsky::unspecced::get_suggested_starter_packs::NSID
2180 .into(),
2181 parameters: Some(params),
2182 input: None,
2183 encoding: None,
2184 },
2185 )
2186 .await?;
2187 match response {
2188 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2189 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2190 }
2191 }
2192 pub async fn get_suggested_starter_packs_skeleton(
2194 &self,
2195 params: crate::app::bsky::unspecced::get_suggested_starter_packs_skeleton::Parameters,
2196 ) -> atrium_xrpc::Result<
2197 crate::app::bsky::unspecced::get_suggested_starter_packs_skeleton::Output,
2198 crate::app::bsky::unspecced::get_suggested_starter_packs_skeleton::Error,
2199 > {
2200 let response = self
2201 .xrpc
2202 .send_xrpc::<
2203 _,
2204 (),
2205 _,
2206 _,
2207 >(
2208 &atrium_xrpc::XrpcRequest {
2209 method: http::Method::GET,
2210 nsid: crate::app::bsky::unspecced::get_suggested_starter_packs_skeleton::NSID
2211 .into(),
2212 parameters: Some(params),
2213 input: None,
2214 encoding: None,
2215 },
2216 )
2217 .await?;
2218 match response {
2219 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2220 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2221 }
2222 }
2223 pub async fn get_suggested_users(
2225 &self,
2226 params: crate::app::bsky::unspecced::get_suggested_users::Parameters,
2227 ) -> atrium_xrpc::Result<
2228 crate::app::bsky::unspecced::get_suggested_users::Output,
2229 crate::app::bsky::unspecced::get_suggested_users::Error,
2230 > {
2231 let response = self
2232 .xrpc
2233 .send_xrpc::<
2234 _,
2235 (),
2236 _,
2237 _,
2238 >(
2239 &atrium_xrpc::XrpcRequest {
2240 method: http::Method::GET,
2241 nsid: crate::app::bsky::unspecced::get_suggested_users::NSID.into(),
2242 parameters: Some(params),
2243 input: None,
2244 encoding: None,
2245 },
2246 )
2247 .await?;
2248 match response {
2249 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2250 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2251 }
2252 }
2253 pub async fn get_suggested_users_skeleton(
2255 &self,
2256 params: crate::app::bsky::unspecced::get_suggested_users_skeleton::Parameters,
2257 ) -> atrium_xrpc::Result<
2258 crate::app::bsky::unspecced::get_suggested_users_skeleton::Output,
2259 crate::app::bsky::unspecced::get_suggested_users_skeleton::Error,
2260 > {
2261 let response = self
2262 .xrpc
2263 .send_xrpc::<
2264 _,
2265 (),
2266 _,
2267 _,
2268 >(
2269 &atrium_xrpc::XrpcRequest {
2270 method: http::Method::GET,
2271 nsid: crate::app::bsky::unspecced::get_suggested_users_skeleton::NSID
2272 .into(),
2273 parameters: Some(params),
2274 input: None,
2275 encoding: None,
2276 },
2277 )
2278 .await?;
2279 match response {
2280 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2281 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2282 }
2283 }
2284 pub async fn get_suggestions_skeleton(
2286 &self,
2287 params: crate::app::bsky::unspecced::get_suggestions_skeleton::Parameters,
2288 ) -> atrium_xrpc::Result<
2289 crate::app::bsky::unspecced::get_suggestions_skeleton::Output,
2290 crate::app::bsky::unspecced::get_suggestions_skeleton::Error,
2291 > {
2292 let response = self
2293 .xrpc
2294 .send_xrpc::<
2295 _,
2296 (),
2297 _,
2298 _,
2299 >(
2300 &atrium_xrpc::XrpcRequest {
2301 method: http::Method::GET,
2302 nsid: crate::app::bsky::unspecced::get_suggestions_skeleton::NSID
2303 .into(),
2304 parameters: Some(params),
2305 input: None,
2306 encoding: None,
2307 },
2308 )
2309 .await?;
2310 match response {
2311 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2312 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2313 }
2314 }
2315 pub async fn get_tagged_suggestions(
2317 &self,
2318 params: crate::app::bsky::unspecced::get_tagged_suggestions::Parameters,
2319 ) -> atrium_xrpc::Result<
2320 crate::app::bsky::unspecced::get_tagged_suggestions::Output,
2321 crate::app::bsky::unspecced::get_tagged_suggestions::Error,
2322 > {
2323 let response = self
2324 .xrpc
2325 .send_xrpc::<
2326 _,
2327 (),
2328 _,
2329 _,
2330 >(
2331 &atrium_xrpc::XrpcRequest {
2332 method: http::Method::GET,
2333 nsid: crate::app::bsky::unspecced::get_tagged_suggestions::NSID
2334 .into(),
2335 parameters: Some(params),
2336 input: None,
2337 encoding: None,
2338 },
2339 )
2340 .await?;
2341 match response {
2342 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2343 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2344 }
2345 }
2346 pub async fn get_trending_topics(
2348 &self,
2349 params: crate::app::bsky::unspecced::get_trending_topics::Parameters,
2350 ) -> atrium_xrpc::Result<
2351 crate::app::bsky::unspecced::get_trending_topics::Output,
2352 crate::app::bsky::unspecced::get_trending_topics::Error,
2353 > {
2354 let response = self
2355 .xrpc
2356 .send_xrpc::<
2357 _,
2358 (),
2359 _,
2360 _,
2361 >(
2362 &atrium_xrpc::XrpcRequest {
2363 method: http::Method::GET,
2364 nsid: crate::app::bsky::unspecced::get_trending_topics::NSID.into(),
2365 parameters: Some(params),
2366 input: None,
2367 encoding: None,
2368 },
2369 )
2370 .await?;
2371 match response {
2372 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2373 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2374 }
2375 }
2376 pub async fn get_trends(
2378 &self,
2379 params: crate::app::bsky::unspecced::get_trends::Parameters,
2380 ) -> atrium_xrpc::Result<
2381 crate::app::bsky::unspecced::get_trends::Output,
2382 crate::app::bsky::unspecced::get_trends::Error,
2383 > {
2384 let response = self
2385 .xrpc
2386 .send_xrpc::<
2387 _,
2388 (),
2389 _,
2390 _,
2391 >(
2392 &atrium_xrpc::XrpcRequest {
2393 method: http::Method::GET,
2394 nsid: crate::app::bsky::unspecced::get_trends::NSID.into(),
2395 parameters: Some(params),
2396 input: None,
2397 encoding: None,
2398 },
2399 )
2400 .await?;
2401 match response {
2402 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2403 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2404 }
2405 }
2406 pub async fn get_trends_skeleton(
2408 &self,
2409 params: crate::app::bsky::unspecced::get_trends_skeleton::Parameters,
2410 ) -> atrium_xrpc::Result<
2411 crate::app::bsky::unspecced::get_trends_skeleton::Output,
2412 crate::app::bsky::unspecced::get_trends_skeleton::Error,
2413 > {
2414 let response = self
2415 .xrpc
2416 .send_xrpc::<
2417 _,
2418 (),
2419 _,
2420 _,
2421 >(
2422 &atrium_xrpc::XrpcRequest {
2423 method: http::Method::GET,
2424 nsid: crate::app::bsky::unspecced::get_trends_skeleton::NSID.into(),
2425 parameters: Some(params),
2426 input: None,
2427 encoding: None,
2428 },
2429 )
2430 .await?;
2431 match response {
2432 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2433 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2434 }
2435 }
2436 pub async fn search_actors_skeleton(
2438 &self,
2439 params: crate::app::bsky::unspecced::search_actors_skeleton::Parameters,
2440 ) -> atrium_xrpc::Result<
2441 crate::app::bsky::unspecced::search_actors_skeleton::Output,
2442 crate::app::bsky::unspecced::search_actors_skeleton::Error,
2443 > {
2444 let response = self
2445 .xrpc
2446 .send_xrpc::<
2447 _,
2448 (),
2449 _,
2450 _,
2451 >(
2452 &atrium_xrpc::XrpcRequest {
2453 method: http::Method::GET,
2454 nsid: crate::app::bsky::unspecced::search_actors_skeleton::NSID
2455 .into(),
2456 parameters: Some(params),
2457 input: None,
2458 encoding: None,
2459 },
2460 )
2461 .await?;
2462 match response {
2463 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2464 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2465 }
2466 }
2467 pub async fn search_posts_skeleton(
2469 &self,
2470 params: crate::app::bsky::unspecced::search_posts_skeleton::Parameters,
2471 ) -> atrium_xrpc::Result<
2472 crate::app::bsky::unspecced::search_posts_skeleton::Output,
2473 crate::app::bsky::unspecced::search_posts_skeleton::Error,
2474 > {
2475 let response = self
2476 .xrpc
2477 .send_xrpc::<
2478 _,
2479 (),
2480 _,
2481 _,
2482 >(
2483 &atrium_xrpc::XrpcRequest {
2484 method: http::Method::GET,
2485 nsid: crate::app::bsky::unspecced::search_posts_skeleton::NSID
2486 .into(),
2487 parameters: Some(params),
2488 input: None,
2489 encoding: None,
2490 },
2491 )
2492 .await?;
2493 match response {
2494 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2495 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2496 }
2497 }
2498 pub async fn search_starter_packs_skeleton(
2500 &self,
2501 params: crate::app::bsky::unspecced::search_starter_packs_skeleton::Parameters,
2502 ) -> atrium_xrpc::Result<
2503 crate::app::bsky::unspecced::search_starter_packs_skeleton::Output,
2504 crate::app::bsky::unspecced::search_starter_packs_skeleton::Error,
2505 > {
2506 let response = self
2507 .xrpc
2508 .send_xrpc::<
2509 _,
2510 (),
2511 _,
2512 _,
2513 >(
2514 &atrium_xrpc::XrpcRequest {
2515 method: http::Method::GET,
2516 nsid: crate::app::bsky::unspecced::search_starter_packs_skeleton::NSID
2517 .into(),
2518 parameters: Some(params),
2519 input: None,
2520 encoding: None,
2521 },
2522 )
2523 .await?;
2524 match response {
2525 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2526 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2527 }
2528 }
2529}
2530#[cfg(feature = "namespace-appbsky")]
2531impl<T> app::bsky::video::Service<T>
2532where
2533 T: atrium_xrpc::XrpcClient + Send + Sync,
2534{
2535 #[allow(unused_variables)]
2536 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
2537 Self {
2538 xrpc,
2539 _phantom: core::marker::PhantomData,
2540 }
2541 }
2542 pub async fn get_job_status(
2544 &self,
2545 params: crate::app::bsky::video::get_job_status::Parameters,
2546 ) -> atrium_xrpc::Result<
2547 crate::app::bsky::video::get_job_status::Output,
2548 crate::app::bsky::video::get_job_status::Error,
2549 > {
2550 let response = self
2551 .xrpc
2552 .send_xrpc::<
2553 _,
2554 (),
2555 _,
2556 _,
2557 >(
2558 &atrium_xrpc::XrpcRequest {
2559 method: http::Method::GET,
2560 nsid: crate::app::bsky::video::get_job_status::NSID.into(),
2561 parameters: Some(params),
2562 input: None,
2563 encoding: None,
2564 },
2565 )
2566 .await?;
2567 match response {
2568 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2569 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2570 }
2571 }
2572 pub async fn get_upload_limits(
2574 &self,
2575 ) -> atrium_xrpc::Result<
2576 crate::app::bsky::video::get_upload_limits::Output,
2577 crate::app::bsky::video::get_upload_limits::Error,
2578 > {
2579 let response = self
2580 .xrpc
2581 .send_xrpc::<
2582 (),
2583 (),
2584 _,
2585 _,
2586 >(
2587 &atrium_xrpc::XrpcRequest {
2588 method: http::Method::GET,
2589 nsid: crate::app::bsky::video::get_upload_limits::NSID.into(),
2590 parameters: None,
2591 input: None,
2592 encoding: None,
2593 },
2594 )
2595 .await?;
2596 match response {
2597 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2598 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2599 }
2600 }
2601 pub async fn upload_video(
2603 &self,
2604 input: Vec<u8>,
2605 ) -> atrium_xrpc::Result<
2606 crate::app::bsky::video::upload_video::Output,
2607 crate::app::bsky::video::upload_video::Error,
2608 > {
2609 let response = self
2610 .xrpc
2611 .send_xrpc::<
2612 (),
2613 Vec<u8>,
2614 _,
2615 _,
2616 >(
2617 &atrium_xrpc::XrpcRequest {
2618 method: http::Method::POST,
2619 nsid: crate::app::bsky::video::upload_video::NSID.into(),
2620 parameters: None,
2621 input: Some(atrium_xrpc::InputDataOrBytes::Bytes(input)),
2622 encoding: Some(String::from("video/mp4")),
2623 },
2624 )
2625 .await?;
2626 match response {
2627 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2628 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2629 }
2630 }
2631}
2632impl<T> chat::Service<T>
2633where
2634 T: atrium_xrpc::XrpcClient + Send + Sync,
2635{
2636 #[allow(unused_variables)]
2637 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
2638 Self {
2639 #[cfg(feature = "namespace-chatbsky")]
2640 bsky: chat::bsky::Service::new(std::sync::Arc::clone(&xrpc)),
2641 _phantom: core::marker::PhantomData,
2642 }
2643 }
2644}
2645#[cfg(feature = "namespace-chatbsky")]
2646impl<T> chat::bsky::Service<T>
2647where
2648 T: atrium_xrpc::XrpcClient + Send + Sync,
2649{
2650 #[allow(unused_variables)]
2651 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
2652 Self {
2653 actor: chat::bsky::actor::Service::new(std::sync::Arc::clone(&xrpc)),
2654 convo: chat::bsky::convo::Service::new(std::sync::Arc::clone(&xrpc)),
2655 moderation: chat::bsky::moderation::Service::new(
2656 std::sync::Arc::clone(&xrpc),
2657 ),
2658 _phantom: core::marker::PhantomData,
2659 }
2660 }
2661}
2662#[cfg(feature = "namespace-chatbsky")]
2663impl<T> chat::bsky::actor::Service<T>
2664where
2665 T: atrium_xrpc::XrpcClient + Send + Sync,
2666{
2667 #[allow(unused_variables)]
2668 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
2669 Self {
2670 xrpc,
2671 _phantom: core::marker::PhantomData,
2672 }
2673 }
2674 pub async fn delete_account(
2675 &self,
2676 ) -> atrium_xrpc::Result<
2677 crate::chat::bsky::actor::delete_account::Output,
2678 crate::chat::bsky::actor::delete_account::Error,
2679 > {
2680 let response = self
2681 .xrpc
2682 .send_xrpc::<
2683 (),
2684 (),
2685 _,
2686 _,
2687 >(
2688 &atrium_xrpc::XrpcRequest {
2689 method: http::Method::POST,
2690 nsid: crate::chat::bsky::actor::delete_account::NSID.into(),
2691 parameters: None,
2692 input: None,
2693 encoding: None,
2694 },
2695 )
2696 .await?;
2697 match response {
2698 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2699 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2700 }
2701 }
2702 pub async fn export_account_data(
2703 &self,
2704 ) -> atrium_xrpc::Result<
2705 Vec<u8>,
2706 crate::chat::bsky::actor::export_account_data::Error,
2707 > {
2708 let response = self
2709 .xrpc
2710 .send_xrpc::<
2711 (),
2712 (),
2713 (),
2714 _,
2715 >(
2716 &atrium_xrpc::XrpcRequest {
2717 method: http::Method::GET,
2718 nsid: crate::chat::bsky::actor::export_account_data::NSID.into(),
2719 parameters: None,
2720 input: None,
2721 encoding: None,
2722 },
2723 )
2724 .await?;
2725 match response {
2726 atrium_xrpc::OutputDataOrBytes::Bytes(bytes) => Ok(bytes),
2727 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2728 }
2729 }
2730}
2731#[cfg(feature = "namespace-chatbsky")]
2732impl<T> chat::bsky::convo::Service<T>
2733where
2734 T: atrium_xrpc::XrpcClient + Send + Sync,
2735{
2736 #[allow(unused_variables)]
2737 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
2738 Self {
2739 xrpc,
2740 _phantom: core::marker::PhantomData,
2741 }
2742 }
2743 pub async fn accept_convo(
2744 &self,
2745 input: crate::chat::bsky::convo::accept_convo::Input,
2746 ) -> atrium_xrpc::Result<
2747 crate::chat::bsky::convo::accept_convo::Output,
2748 crate::chat::bsky::convo::accept_convo::Error,
2749 > {
2750 let response = self
2751 .xrpc
2752 .send_xrpc::<
2753 (),
2754 _,
2755 _,
2756 _,
2757 >(
2758 &atrium_xrpc::XrpcRequest {
2759 method: http::Method::POST,
2760 nsid: crate::chat::bsky::convo::accept_convo::NSID.into(),
2761 parameters: None,
2762 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
2763 encoding: Some(String::from("application/json")),
2764 },
2765 )
2766 .await?;
2767 match response {
2768 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2769 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2770 }
2771 }
2772 pub async fn add_reaction(
2774 &self,
2775 input: crate::chat::bsky::convo::add_reaction::Input,
2776 ) -> atrium_xrpc::Result<
2777 crate::chat::bsky::convo::add_reaction::Output,
2778 crate::chat::bsky::convo::add_reaction::Error,
2779 > {
2780 let response = self
2781 .xrpc
2782 .send_xrpc::<
2783 (),
2784 _,
2785 _,
2786 _,
2787 >(
2788 &atrium_xrpc::XrpcRequest {
2789 method: http::Method::POST,
2790 nsid: crate::chat::bsky::convo::add_reaction::NSID.into(),
2791 parameters: None,
2792 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
2793 encoding: Some(String::from("application/json")),
2794 },
2795 )
2796 .await?;
2797 match response {
2798 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2799 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2800 }
2801 }
2802 pub async fn delete_message_for_self(
2803 &self,
2804 input: crate::chat::bsky::convo::delete_message_for_self::Input,
2805 ) -> atrium_xrpc::Result<
2806 crate::chat::bsky::convo::delete_message_for_self::Output,
2807 crate::chat::bsky::convo::delete_message_for_self::Error,
2808 > {
2809 let response = self
2810 .xrpc
2811 .send_xrpc::<
2812 (),
2813 _,
2814 _,
2815 _,
2816 >(
2817 &atrium_xrpc::XrpcRequest {
2818 method: http::Method::POST,
2819 nsid: crate::chat::bsky::convo::delete_message_for_self::NSID.into(),
2820 parameters: None,
2821 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
2822 encoding: Some(String::from("application/json")),
2823 },
2824 )
2825 .await?;
2826 match response {
2827 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2828 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2829 }
2830 }
2831 pub async fn get_convo(
2832 &self,
2833 params: crate::chat::bsky::convo::get_convo::Parameters,
2834 ) -> atrium_xrpc::Result<
2835 crate::chat::bsky::convo::get_convo::Output,
2836 crate::chat::bsky::convo::get_convo::Error,
2837 > {
2838 let response = self
2839 .xrpc
2840 .send_xrpc::<
2841 _,
2842 (),
2843 _,
2844 _,
2845 >(
2846 &atrium_xrpc::XrpcRequest {
2847 method: http::Method::GET,
2848 nsid: crate::chat::bsky::convo::get_convo::NSID.into(),
2849 parameters: Some(params),
2850 input: None,
2851 encoding: None,
2852 },
2853 )
2854 .await?;
2855 match response {
2856 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2857 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2858 }
2859 }
2860 pub async fn get_convo_availability(
2862 &self,
2863 params: crate::chat::bsky::convo::get_convo_availability::Parameters,
2864 ) -> atrium_xrpc::Result<
2865 crate::chat::bsky::convo::get_convo_availability::Output,
2866 crate::chat::bsky::convo::get_convo_availability::Error,
2867 > {
2868 let response = self
2869 .xrpc
2870 .send_xrpc::<
2871 _,
2872 (),
2873 _,
2874 _,
2875 >(
2876 &atrium_xrpc::XrpcRequest {
2877 method: http::Method::GET,
2878 nsid: crate::chat::bsky::convo::get_convo_availability::NSID.into(),
2879 parameters: Some(params),
2880 input: None,
2881 encoding: None,
2882 },
2883 )
2884 .await?;
2885 match response {
2886 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2887 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2888 }
2889 }
2890 pub async fn get_convo_for_members(
2891 &self,
2892 params: crate::chat::bsky::convo::get_convo_for_members::Parameters,
2893 ) -> atrium_xrpc::Result<
2894 crate::chat::bsky::convo::get_convo_for_members::Output,
2895 crate::chat::bsky::convo::get_convo_for_members::Error,
2896 > {
2897 let response = self
2898 .xrpc
2899 .send_xrpc::<
2900 _,
2901 (),
2902 _,
2903 _,
2904 >(
2905 &atrium_xrpc::XrpcRequest {
2906 method: http::Method::GET,
2907 nsid: crate::chat::bsky::convo::get_convo_for_members::NSID.into(),
2908 parameters: Some(params),
2909 input: None,
2910 encoding: None,
2911 },
2912 )
2913 .await?;
2914 match response {
2915 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2916 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2917 }
2918 }
2919 pub async fn get_log(
2920 &self,
2921 params: crate::chat::bsky::convo::get_log::Parameters,
2922 ) -> atrium_xrpc::Result<
2923 crate::chat::bsky::convo::get_log::Output,
2924 crate::chat::bsky::convo::get_log::Error,
2925 > {
2926 let response = self
2927 .xrpc
2928 .send_xrpc::<
2929 _,
2930 (),
2931 _,
2932 _,
2933 >(
2934 &atrium_xrpc::XrpcRequest {
2935 method: http::Method::GET,
2936 nsid: crate::chat::bsky::convo::get_log::NSID.into(),
2937 parameters: Some(params),
2938 input: None,
2939 encoding: None,
2940 },
2941 )
2942 .await?;
2943 match response {
2944 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2945 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2946 }
2947 }
2948 pub async fn get_messages(
2949 &self,
2950 params: crate::chat::bsky::convo::get_messages::Parameters,
2951 ) -> atrium_xrpc::Result<
2952 crate::chat::bsky::convo::get_messages::Output,
2953 crate::chat::bsky::convo::get_messages::Error,
2954 > {
2955 let response = self
2956 .xrpc
2957 .send_xrpc::<
2958 _,
2959 (),
2960 _,
2961 _,
2962 >(
2963 &atrium_xrpc::XrpcRequest {
2964 method: http::Method::GET,
2965 nsid: crate::chat::bsky::convo::get_messages::NSID.into(),
2966 parameters: Some(params),
2967 input: None,
2968 encoding: None,
2969 },
2970 )
2971 .await?;
2972 match response {
2973 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
2974 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
2975 }
2976 }
2977 pub async fn leave_convo(
2978 &self,
2979 input: crate::chat::bsky::convo::leave_convo::Input,
2980 ) -> atrium_xrpc::Result<
2981 crate::chat::bsky::convo::leave_convo::Output,
2982 crate::chat::bsky::convo::leave_convo::Error,
2983 > {
2984 let response = self
2985 .xrpc
2986 .send_xrpc::<
2987 (),
2988 _,
2989 _,
2990 _,
2991 >(
2992 &atrium_xrpc::XrpcRequest {
2993 method: http::Method::POST,
2994 nsid: crate::chat::bsky::convo::leave_convo::NSID.into(),
2995 parameters: None,
2996 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
2997 encoding: Some(String::from("application/json")),
2998 },
2999 )
3000 .await?;
3001 match response {
3002 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3003 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3004 }
3005 }
3006 pub async fn list_convos(
3007 &self,
3008 params: crate::chat::bsky::convo::list_convos::Parameters,
3009 ) -> atrium_xrpc::Result<
3010 crate::chat::bsky::convo::list_convos::Output,
3011 crate::chat::bsky::convo::list_convos::Error,
3012 > {
3013 let response = self
3014 .xrpc
3015 .send_xrpc::<
3016 _,
3017 (),
3018 _,
3019 _,
3020 >(
3021 &atrium_xrpc::XrpcRequest {
3022 method: http::Method::GET,
3023 nsid: crate::chat::bsky::convo::list_convos::NSID.into(),
3024 parameters: Some(params),
3025 input: None,
3026 encoding: None,
3027 },
3028 )
3029 .await?;
3030 match response {
3031 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3032 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3033 }
3034 }
3035 pub async fn mute_convo(
3036 &self,
3037 input: crate::chat::bsky::convo::mute_convo::Input,
3038 ) -> atrium_xrpc::Result<
3039 crate::chat::bsky::convo::mute_convo::Output,
3040 crate::chat::bsky::convo::mute_convo::Error,
3041 > {
3042 let response = self
3043 .xrpc
3044 .send_xrpc::<
3045 (),
3046 _,
3047 _,
3048 _,
3049 >(
3050 &atrium_xrpc::XrpcRequest {
3051 method: http::Method::POST,
3052 nsid: crate::chat::bsky::convo::mute_convo::NSID.into(),
3053 parameters: None,
3054 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3055 encoding: Some(String::from("application/json")),
3056 },
3057 )
3058 .await?;
3059 match response {
3060 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3061 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3062 }
3063 }
3064 pub async fn remove_reaction(
3066 &self,
3067 input: crate::chat::bsky::convo::remove_reaction::Input,
3068 ) -> atrium_xrpc::Result<
3069 crate::chat::bsky::convo::remove_reaction::Output,
3070 crate::chat::bsky::convo::remove_reaction::Error,
3071 > {
3072 let response = self
3073 .xrpc
3074 .send_xrpc::<
3075 (),
3076 _,
3077 _,
3078 _,
3079 >(
3080 &atrium_xrpc::XrpcRequest {
3081 method: http::Method::POST,
3082 nsid: crate::chat::bsky::convo::remove_reaction::NSID.into(),
3083 parameters: None,
3084 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3085 encoding: Some(String::from("application/json")),
3086 },
3087 )
3088 .await?;
3089 match response {
3090 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3091 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3092 }
3093 }
3094 pub async fn send_message(
3095 &self,
3096 input: crate::chat::bsky::convo::send_message::Input,
3097 ) -> atrium_xrpc::Result<
3098 crate::chat::bsky::convo::send_message::Output,
3099 crate::chat::bsky::convo::send_message::Error,
3100 > {
3101 let response = self
3102 .xrpc
3103 .send_xrpc::<
3104 (),
3105 _,
3106 _,
3107 _,
3108 >(
3109 &atrium_xrpc::XrpcRequest {
3110 method: http::Method::POST,
3111 nsid: crate::chat::bsky::convo::send_message::NSID.into(),
3112 parameters: None,
3113 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3114 encoding: Some(String::from("application/json")),
3115 },
3116 )
3117 .await?;
3118 match response {
3119 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3120 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3121 }
3122 }
3123 pub async fn send_message_batch(
3124 &self,
3125 input: crate::chat::bsky::convo::send_message_batch::Input,
3126 ) -> atrium_xrpc::Result<
3127 crate::chat::bsky::convo::send_message_batch::Output,
3128 crate::chat::bsky::convo::send_message_batch::Error,
3129 > {
3130 let response = self
3131 .xrpc
3132 .send_xrpc::<
3133 (),
3134 _,
3135 _,
3136 _,
3137 >(
3138 &atrium_xrpc::XrpcRequest {
3139 method: http::Method::POST,
3140 nsid: crate::chat::bsky::convo::send_message_batch::NSID.into(),
3141 parameters: None,
3142 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3143 encoding: Some(String::from("application/json")),
3144 },
3145 )
3146 .await?;
3147 match response {
3148 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3149 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3150 }
3151 }
3152 pub async fn unmute_convo(
3153 &self,
3154 input: crate::chat::bsky::convo::unmute_convo::Input,
3155 ) -> atrium_xrpc::Result<
3156 crate::chat::bsky::convo::unmute_convo::Output,
3157 crate::chat::bsky::convo::unmute_convo::Error,
3158 > {
3159 let response = self
3160 .xrpc
3161 .send_xrpc::<
3162 (),
3163 _,
3164 _,
3165 _,
3166 >(
3167 &atrium_xrpc::XrpcRequest {
3168 method: http::Method::POST,
3169 nsid: crate::chat::bsky::convo::unmute_convo::NSID.into(),
3170 parameters: None,
3171 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3172 encoding: Some(String::from("application/json")),
3173 },
3174 )
3175 .await?;
3176 match response {
3177 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3178 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3179 }
3180 }
3181 pub async fn update_all_read(
3182 &self,
3183 input: crate::chat::bsky::convo::update_all_read::Input,
3184 ) -> atrium_xrpc::Result<
3185 crate::chat::bsky::convo::update_all_read::Output,
3186 crate::chat::bsky::convo::update_all_read::Error,
3187 > {
3188 let response = self
3189 .xrpc
3190 .send_xrpc::<
3191 (),
3192 _,
3193 _,
3194 _,
3195 >(
3196 &atrium_xrpc::XrpcRequest {
3197 method: http::Method::POST,
3198 nsid: crate::chat::bsky::convo::update_all_read::NSID.into(),
3199 parameters: None,
3200 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3201 encoding: Some(String::from("application/json")),
3202 },
3203 )
3204 .await?;
3205 match response {
3206 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3207 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3208 }
3209 }
3210 pub async fn update_read(
3211 &self,
3212 input: crate::chat::bsky::convo::update_read::Input,
3213 ) -> atrium_xrpc::Result<
3214 crate::chat::bsky::convo::update_read::Output,
3215 crate::chat::bsky::convo::update_read::Error,
3216 > {
3217 let response = self
3218 .xrpc
3219 .send_xrpc::<
3220 (),
3221 _,
3222 _,
3223 _,
3224 >(
3225 &atrium_xrpc::XrpcRequest {
3226 method: http::Method::POST,
3227 nsid: crate::chat::bsky::convo::update_read::NSID.into(),
3228 parameters: None,
3229 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3230 encoding: Some(String::from("application/json")),
3231 },
3232 )
3233 .await?;
3234 match response {
3235 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3236 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3237 }
3238 }
3239}
3240#[cfg(feature = "namespace-chatbsky")]
3241impl<T> chat::bsky::moderation::Service<T>
3242where
3243 T: atrium_xrpc::XrpcClient + Send + Sync,
3244{
3245 #[allow(unused_variables)]
3246 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
3247 Self {
3248 xrpc,
3249 _phantom: core::marker::PhantomData,
3250 }
3251 }
3252 pub async fn get_actor_metadata(
3253 &self,
3254 params: crate::chat::bsky::moderation::get_actor_metadata::Parameters,
3255 ) -> atrium_xrpc::Result<
3256 crate::chat::bsky::moderation::get_actor_metadata::Output,
3257 crate::chat::bsky::moderation::get_actor_metadata::Error,
3258 > {
3259 let response = self
3260 .xrpc
3261 .send_xrpc::<
3262 _,
3263 (),
3264 _,
3265 _,
3266 >(
3267 &atrium_xrpc::XrpcRequest {
3268 method: http::Method::GET,
3269 nsid: crate::chat::bsky::moderation::get_actor_metadata::NSID.into(),
3270 parameters: Some(params),
3271 input: None,
3272 encoding: None,
3273 },
3274 )
3275 .await?;
3276 match response {
3277 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3278 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3279 }
3280 }
3281 pub async fn get_message_context(
3282 &self,
3283 params: crate::chat::bsky::moderation::get_message_context::Parameters,
3284 ) -> atrium_xrpc::Result<
3285 crate::chat::bsky::moderation::get_message_context::Output,
3286 crate::chat::bsky::moderation::get_message_context::Error,
3287 > {
3288 let response = self
3289 .xrpc
3290 .send_xrpc::<
3291 _,
3292 (),
3293 _,
3294 _,
3295 >(
3296 &atrium_xrpc::XrpcRequest {
3297 method: http::Method::GET,
3298 nsid: crate::chat::bsky::moderation::get_message_context::NSID
3299 .into(),
3300 parameters: Some(params),
3301 input: None,
3302 encoding: None,
3303 },
3304 )
3305 .await?;
3306 match response {
3307 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3308 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3309 }
3310 }
3311 pub async fn update_actor_access(
3312 &self,
3313 input: crate::chat::bsky::moderation::update_actor_access::Input,
3314 ) -> atrium_xrpc::Result<
3315 (),
3316 crate::chat::bsky::moderation::update_actor_access::Error,
3317 > {
3318 let response = self
3319 .xrpc
3320 .send_xrpc::<
3321 (),
3322 _,
3323 (),
3324 _,
3325 >(
3326 &atrium_xrpc::XrpcRequest {
3327 method: http::Method::POST,
3328 nsid: crate::chat::bsky::moderation::update_actor_access::NSID
3329 .into(),
3330 parameters: None,
3331 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3332 encoding: Some(String::from("application/json")),
3333 },
3334 )
3335 .await?;
3336 match response {
3337 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
3338 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3339 }
3340 }
3341}
3342impl<T> com::Service<T>
3343where
3344 T: atrium_xrpc::XrpcClient + Send + Sync,
3345{
3346 #[allow(unused_variables)]
3347 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
3348 Self {
3349 atproto: com::atproto::Service::new(std::sync::Arc::clone(&xrpc)),
3350 _phantom: core::marker::PhantomData,
3351 }
3352 }
3353}
3354impl<T> com::atproto::Service<T>
3355where
3356 T: atrium_xrpc::XrpcClient + Send + Sync,
3357{
3358 #[allow(unused_variables)]
3359 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
3360 Self {
3361 admin: com::atproto::admin::Service::new(std::sync::Arc::clone(&xrpc)),
3362 identity: com::atproto::identity::Service::new(std::sync::Arc::clone(&xrpc)),
3363 label: com::atproto::label::Service::new(std::sync::Arc::clone(&xrpc)),
3364 moderation: com::atproto::moderation::Service::new(
3365 std::sync::Arc::clone(&xrpc),
3366 ),
3367 repo: com::atproto::repo::Service::new(std::sync::Arc::clone(&xrpc)),
3368 server: com::atproto::server::Service::new(std::sync::Arc::clone(&xrpc)),
3369 sync: com::atproto::sync::Service::new(std::sync::Arc::clone(&xrpc)),
3370 temp: com::atproto::temp::Service::new(std::sync::Arc::clone(&xrpc)),
3371 _phantom: core::marker::PhantomData,
3372 }
3373 }
3374}
3375impl<T> com::atproto::admin::Service<T>
3376where
3377 T: atrium_xrpc::XrpcClient + Send + Sync,
3378{
3379 #[allow(unused_variables)]
3380 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
3381 Self {
3382 xrpc,
3383 _phantom: core::marker::PhantomData,
3384 }
3385 }
3386 pub async fn delete_account(
3388 &self,
3389 input: crate::com::atproto::admin::delete_account::Input,
3390 ) -> atrium_xrpc::Result<(), crate::com::atproto::admin::delete_account::Error> {
3391 let response = self
3392 .xrpc
3393 .send_xrpc::<
3394 (),
3395 _,
3396 (),
3397 _,
3398 >(
3399 &atrium_xrpc::XrpcRequest {
3400 method: http::Method::POST,
3401 nsid: crate::com::atproto::admin::delete_account::NSID.into(),
3402 parameters: None,
3403 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3404 encoding: Some(String::from("application/json")),
3405 },
3406 )
3407 .await?;
3408 match response {
3409 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
3410 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3411 }
3412 }
3413 pub async fn disable_account_invites(
3415 &self,
3416 input: crate::com::atproto::admin::disable_account_invites::Input,
3417 ) -> atrium_xrpc::Result<
3418 (),
3419 crate::com::atproto::admin::disable_account_invites::Error,
3420 > {
3421 let response = self
3422 .xrpc
3423 .send_xrpc::<
3424 (),
3425 _,
3426 (),
3427 _,
3428 >(
3429 &atrium_xrpc::XrpcRequest {
3430 method: http::Method::POST,
3431 nsid: crate::com::atproto::admin::disable_account_invites::NSID
3432 .into(),
3433 parameters: None,
3434 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3435 encoding: Some(String::from("application/json")),
3436 },
3437 )
3438 .await?;
3439 match response {
3440 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
3441 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3442 }
3443 }
3444 pub async fn disable_invite_codes(
3446 &self,
3447 input: crate::com::atproto::admin::disable_invite_codes::Input,
3448 ) -> atrium_xrpc::Result<
3449 (),
3450 crate::com::atproto::admin::disable_invite_codes::Error,
3451 > {
3452 let response = self
3453 .xrpc
3454 .send_xrpc::<
3455 (),
3456 _,
3457 (),
3458 _,
3459 >(
3460 &atrium_xrpc::XrpcRequest {
3461 method: http::Method::POST,
3462 nsid: crate::com::atproto::admin::disable_invite_codes::NSID.into(),
3463 parameters: None,
3464 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3465 encoding: Some(String::from("application/json")),
3466 },
3467 )
3468 .await?;
3469 match response {
3470 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
3471 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3472 }
3473 }
3474 pub async fn enable_account_invites(
3476 &self,
3477 input: crate::com::atproto::admin::enable_account_invites::Input,
3478 ) -> atrium_xrpc::Result<
3479 (),
3480 crate::com::atproto::admin::enable_account_invites::Error,
3481 > {
3482 let response = self
3483 .xrpc
3484 .send_xrpc::<
3485 (),
3486 _,
3487 (),
3488 _,
3489 >(
3490 &atrium_xrpc::XrpcRequest {
3491 method: http::Method::POST,
3492 nsid: crate::com::atproto::admin::enable_account_invites::NSID
3493 .into(),
3494 parameters: None,
3495 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3496 encoding: Some(String::from("application/json")),
3497 },
3498 )
3499 .await?;
3500 match response {
3501 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
3502 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3503 }
3504 }
3505 pub async fn get_account_info(
3507 &self,
3508 params: crate::com::atproto::admin::get_account_info::Parameters,
3509 ) -> atrium_xrpc::Result<
3510 crate::com::atproto::admin::get_account_info::Output,
3511 crate::com::atproto::admin::get_account_info::Error,
3512 > {
3513 let response = self
3514 .xrpc
3515 .send_xrpc::<
3516 _,
3517 (),
3518 _,
3519 _,
3520 >(
3521 &atrium_xrpc::XrpcRequest {
3522 method: http::Method::GET,
3523 nsid: crate::com::atproto::admin::get_account_info::NSID.into(),
3524 parameters: Some(params),
3525 input: None,
3526 encoding: None,
3527 },
3528 )
3529 .await?;
3530 match response {
3531 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3532 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3533 }
3534 }
3535 pub async fn get_account_infos(
3537 &self,
3538 params: crate::com::atproto::admin::get_account_infos::Parameters,
3539 ) -> atrium_xrpc::Result<
3540 crate::com::atproto::admin::get_account_infos::Output,
3541 crate::com::atproto::admin::get_account_infos::Error,
3542 > {
3543 let response = self
3544 .xrpc
3545 .send_xrpc::<
3546 _,
3547 (),
3548 _,
3549 _,
3550 >(
3551 &atrium_xrpc::XrpcRequest {
3552 method: http::Method::GET,
3553 nsid: crate::com::atproto::admin::get_account_infos::NSID.into(),
3554 parameters: Some(params),
3555 input: None,
3556 encoding: None,
3557 },
3558 )
3559 .await?;
3560 match response {
3561 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3562 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3563 }
3564 }
3565 pub async fn get_invite_codes(
3567 &self,
3568 params: crate::com::atproto::admin::get_invite_codes::Parameters,
3569 ) -> atrium_xrpc::Result<
3570 crate::com::atproto::admin::get_invite_codes::Output,
3571 crate::com::atproto::admin::get_invite_codes::Error,
3572 > {
3573 let response = self
3574 .xrpc
3575 .send_xrpc::<
3576 _,
3577 (),
3578 _,
3579 _,
3580 >(
3581 &atrium_xrpc::XrpcRequest {
3582 method: http::Method::GET,
3583 nsid: crate::com::atproto::admin::get_invite_codes::NSID.into(),
3584 parameters: Some(params),
3585 input: None,
3586 encoding: None,
3587 },
3588 )
3589 .await?;
3590 match response {
3591 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3592 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3593 }
3594 }
3595 pub async fn get_subject_status(
3597 &self,
3598 params: crate::com::atproto::admin::get_subject_status::Parameters,
3599 ) -> atrium_xrpc::Result<
3600 crate::com::atproto::admin::get_subject_status::Output,
3601 crate::com::atproto::admin::get_subject_status::Error,
3602 > {
3603 let response = self
3604 .xrpc
3605 .send_xrpc::<
3606 _,
3607 (),
3608 _,
3609 _,
3610 >(
3611 &atrium_xrpc::XrpcRequest {
3612 method: http::Method::GET,
3613 nsid: crate::com::atproto::admin::get_subject_status::NSID.into(),
3614 parameters: Some(params),
3615 input: None,
3616 encoding: None,
3617 },
3618 )
3619 .await?;
3620 match response {
3621 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3622 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3623 }
3624 }
3625 pub async fn search_accounts(
3627 &self,
3628 params: crate::com::atproto::admin::search_accounts::Parameters,
3629 ) -> atrium_xrpc::Result<
3630 crate::com::atproto::admin::search_accounts::Output,
3631 crate::com::atproto::admin::search_accounts::Error,
3632 > {
3633 let response = self
3634 .xrpc
3635 .send_xrpc::<
3636 _,
3637 (),
3638 _,
3639 _,
3640 >(
3641 &atrium_xrpc::XrpcRequest {
3642 method: http::Method::GET,
3643 nsid: crate::com::atproto::admin::search_accounts::NSID.into(),
3644 parameters: Some(params),
3645 input: None,
3646 encoding: None,
3647 },
3648 )
3649 .await?;
3650 match response {
3651 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3652 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3653 }
3654 }
3655 pub async fn send_email(
3657 &self,
3658 input: crate::com::atproto::admin::send_email::Input,
3659 ) -> atrium_xrpc::Result<
3660 crate::com::atproto::admin::send_email::Output,
3661 crate::com::atproto::admin::send_email::Error,
3662 > {
3663 let response = self
3664 .xrpc
3665 .send_xrpc::<
3666 (),
3667 _,
3668 _,
3669 _,
3670 >(
3671 &atrium_xrpc::XrpcRequest {
3672 method: http::Method::POST,
3673 nsid: crate::com::atproto::admin::send_email::NSID.into(),
3674 parameters: None,
3675 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3676 encoding: Some(String::from("application/json")),
3677 },
3678 )
3679 .await?;
3680 match response {
3681 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3682 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3683 }
3684 }
3685 pub async fn update_account_email(
3687 &self,
3688 input: crate::com::atproto::admin::update_account_email::Input,
3689 ) -> atrium_xrpc::Result<
3690 (),
3691 crate::com::atproto::admin::update_account_email::Error,
3692 > {
3693 let response = self
3694 .xrpc
3695 .send_xrpc::<
3696 (),
3697 _,
3698 (),
3699 _,
3700 >(
3701 &atrium_xrpc::XrpcRequest {
3702 method: http::Method::POST,
3703 nsid: crate::com::atproto::admin::update_account_email::NSID.into(),
3704 parameters: None,
3705 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3706 encoding: Some(String::from("application/json")),
3707 },
3708 )
3709 .await?;
3710 match response {
3711 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
3712 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3713 }
3714 }
3715 pub async fn update_account_handle(
3717 &self,
3718 input: crate::com::atproto::admin::update_account_handle::Input,
3719 ) -> atrium_xrpc::Result<
3720 (),
3721 crate::com::atproto::admin::update_account_handle::Error,
3722 > {
3723 let response = self
3724 .xrpc
3725 .send_xrpc::<
3726 (),
3727 _,
3728 (),
3729 _,
3730 >(
3731 &atrium_xrpc::XrpcRequest {
3732 method: http::Method::POST,
3733 nsid: crate::com::atproto::admin::update_account_handle::NSID.into(),
3734 parameters: None,
3735 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3736 encoding: Some(String::from("application/json")),
3737 },
3738 )
3739 .await?;
3740 match response {
3741 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
3742 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3743 }
3744 }
3745 pub async fn update_account_password(
3747 &self,
3748 input: crate::com::atproto::admin::update_account_password::Input,
3749 ) -> atrium_xrpc::Result<
3750 (),
3751 crate::com::atproto::admin::update_account_password::Error,
3752 > {
3753 let response = self
3754 .xrpc
3755 .send_xrpc::<
3756 (),
3757 _,
3758 (),
3759 _,
3760 >(
3761 &atrium_xrpc::XrpcRequest {
3762 method: http::Method::POST,
3763 nsid: crate::com::atproto::admin::update_account_password::NSID
3764 .into(),
3765 parameters: None,
3766 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3767 encoding: Some(String::from("application/json")),
3768 },
3769 )
3770 .await?;
3771 match response {
3772 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
3773 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3774 }
3775 }
3776 pub async fn update_account_signing_key(
3778 &self,
3779 input: crate::com::atproto::admin::update_account_signing_key::Input,
3780 ) -> atrium_xrpc::Result<
3781 (),
3782 crate::com::atproto::admin::update_account_signing_key::Error,
3783 > {
3784 let response = self
3785 .xrpc
3786 .send_xrpc::<
3787 (),
3788 _,
3789 (),
3790 _,
3791 >(
3792 &atrium_xrpc::XrpcRequest {
3793 method: http::Method::POST,
3794 nsid: crate::com::atproto::admin::update_account_signing_key::NSID
3795 .into(),
3796 parameters: None,
3797 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3798 encoding: Some(String::from("application/json")),
3799 },
3800 )
3801 .await?;
3802 match response {
3803 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
3804 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3805 }
3806 }
3807 pub async fn update_subject_status(
3809 &self,
3810 input: crate::com::atproto::admin::update_subject_status::Input,
3811 ) -> atrium_xrpc::Result<
3812 crate::com::atproto::admin::update_subject_status::Output,
3813 crate::com::atproto::admin::update_subject_status::Error,
3814 > {
3815 let response = self
3816 .xrpc
3817 .send_xrpc::<
3818 (),
3819 _,
3820 _,
3821 _,
3822 >(
3823 &atrium_xrpc::XrpcRequest {
3824 method: http::Method::POST,
3825 nsid: crate::com::atproto::admin::update_subject_status::NSID.into(),
3826 parameters: None,
3827 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3828 encoding: Some(String::from("application/json")),
3829 },
3830 )
3831 .await?;
3832 match response {
3833 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3834 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3835 }
3836 }
3837}
3838impl<T> com::atproto::identity::Service<T>
3839where
3840 T: atrium_xrpc::XrpcClient + Send + Sync,
3841{
3842 #[allow(unused_variables)]
3843 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
3844 Self {
3845 xrpc,
3846 _phantom: core::marker::PhantomData,
3847 }
3848 }
3849 pub async fn get_recommended_did_credentials(
3851 &self,
3852 ) -> atrium_xrpc::Result<
3853 crate::com::atproto::identity::get_recommended_did_credentials::Output,
3854 crate::com::atproto::identity::get_recommended_did_credentials::Error,
3855 > {
3856 let response = self
3857 .xrpc
3858 .send_xrpc::<
3859 (),
3860 (),
3861 _,
3862 _,
3863 >(
3864 &atrium_xrpc::XrpcRequest {
3865 method: http::Method::GET,
3866 nsid: crate::com::atproto::identity::get_recommended_did_credentials::NSID
3867 .into(),
3868 parameters: None,
3869 input: None,
3870 encoding: None,
3871 },
3872 )
3873 .await?;
3874 match response {
3875 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3876 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3877 }
3878 }
3879 pub async fn refresh_identity(
3881 &self,
3882 input: crate::com::atproto::identity::refresh_identity::Input,
3883 ) -> atrium_xrpc::Result<
3884 crate::com::atproto::identity::refresh_identity::Output,
3885 crate::com::atproto::identity::refresh_identity::Error,
3886 > {
3887 let response = self
3888 .xrpc
3889 .send_xrpc::<
3890 (),
3891 _,
3892 _,
3893 _,
3894 >(
3895 &atrium_xrpc::XrpcRequest {
3896 method: http::Method::POST,
3897 nsid: crate::com::atproto::identity::refresh_identity::NSID.into(),
3898 parameters: None,
3899 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
3900 encoding: Some(String::from("application/json")),
3901 },
3902 )
3903 .await?;
3904 match response {
3905 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3906 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3907 }
3908 }
3909 pub async fn request_plc_operation_signature(
3911 &self,
3912 ) -> atrium_xrpc::Result<
3913 (),
3914 crate::com::atproto::identity::request_plc_operation_signature::Error,
3915 > {
3916 let response = self
3917 .xrpc
3918 .send_xrpc::<
3919 (),
3920 (),
3921 (),
3922 _,
3923 >(
3924 &atrium_xrpc::XrpcRequest {
3925 method: http::Method::POST,
3926 nsid: crate::com::atproto::identity::request_plc_operation_signature::NSID
3927 .into(),
3928 parameters: None,
3929 input: None,
3930 encoding: None,
3931 },
3932 )
3933 .await?;
3934 match response {
3935 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
3936 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3937 }
3938 }
3939 pub async fn resolve_did(
3941 &self,
3942 params: crate::com::atproto::identity::resolve_did::Parameters,
3943 ) -> atrium_xrpc::Result<
3944 crate::com::atproto::identity::resolve_did::Output,
3945 crate::com::atproto::identity::resolve_did::Error,
3946 > {
3947 let response = self
3948 .xrpc
3949 .send_xrpc::<
3950 _,
3951 (),
3952 _,
3953 _,
3954 >(
3955 &atrium_xrpc::XrpcRequest {
3956 method: http::Method::GET,
3957 nsid: crate::com::atproto::identity::resolve_did::NSID.into(),
3958 parameters: Some(params),
3959 input: None,
3960 encoding: None,
3961 },
3962 )
3963 .await?;
3964 match response {
3965 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3966 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3967 }
3968 }
3969 pub async fn resolve_handle(
3971 &self,
3972 params: crate::com::atproto::identity::resolve_handle::Parameters,
3973 ) -> atrium_xrpc::Result<
3974 crate::com::atproto::identity::resolve_handle::Output,
3975 crate::com::atproto::identity::resolve_handle::Error,
3976 > {
3977 let response = self
3978 .xrpc
3979 .send_xrpc::<
3980 _,
3981 (),
3982 _,
3983 _,
3984 >(
3985 &atrium_xrpc::XrpcRequest {
3986 method: http::Method::GET,
3987 nsid: crate::com::atproto::identity::resolve_handle::NSID.into(),
3988 parameters: Some(params),
3989 input: None,
3990 encoding: None,
3991 },
3992 )
3993 .await?;
3994 match response {
3995 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
3996 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
3997 }
3998 }
3999 pub async fn resolve_identity(
4001 &self,
4002 params: crate::com::atproto::identity::resolve_identity::Parameters,
4003 ) -> atrium_xrpc::Result<
4004 crate::com::atproto::identity::resolve_identity::Output,
4005 crate::com::atproto::identity::resolve_identity::Error,
4006 > {
4007 let response = self
4008 .xrpc
4009 .send_xrpc::<
4010 _,
4011 (),
4012 _,
4013 _,
4014 >(
4015 &atrium_xrpc::XrpcRequest {
4016 method: http::Method::GET,
4017 nsid: crate::com::atproto::identity::resolve_identity::NSID.into(),
4018 parameters: Some(params),
4019 input: None,
4020 encoding: None,
4021 },
4022 )
4023 .await?;
4024 match response {
4025 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4026 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4027 }
4028 }
4029 pub async fn sign_plc_operation(
4031 &self,
4032 input: crate::com::atproto::identity::sign_plc_operation::Input,
4033 ) -> atrium_xrpc::Result<
4034 crate::com::atproto::identity::sign_plc_operation::Output,
4035 crate::com::atproto::identity::sign_plc_operation::Error,
4036 > {
4037 let response = self
4038 .xrpc
4039 .send_xrpc::<
4040 (),
4041 _,
4042 _,
4043 _,
4044 >(
4045 &atrium_xrpc::XrpcRequest {
4046 method: http::Method::POST,
4047 nsid: crate::com::atproto::identity::sign_plc_operation::NSID.into(),
4048 parameters: None,
4049 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4050 encoding: Some(String::from("application/json")),
4051 },
4052 )
4053 .await?;
4054 match response {
4055 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4056 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4057 }
4058 }
4059 pub async fn submit_plc_operation(
4061 &self,
4062 input: crate::com::atproto::identity::submit_plc_operation::Input,
4063 ) -> atrium_xrpc::Result<
4064 (),
4065 crate::com::atproto::identity::submit_plc_operation::Error,
4066 > {
4067 let response = self
4068 .xrpc
4069 .send_xrpc::<
4070 (),
4071 _,
4072 (),
4073 _,
4074 >(
4075 &atrium_xrpc::XrpcRequest {
4076 method: http::Method::POST,
4077 nsid: crate::com::atproto::identity::submit_plc_operation::NSID
4078 .into(),
4079 parameters: None,
4080 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4081 encoding: Some(String::from("application/json")),
4082 },
4083 )
4084 .await?;
4085 match response {
4086 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
4087 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4088 }
4089 }
4090 pub async fn update_handle(
4092 &self,
4093 input: crate::com::atproto::identity::update_handle::Input,
4094 ) -> atrium_xrpc::Result<(), crate::com::atproto::identity::update_handle::Error> {
4095 let response = self
4096 .xrpc
4097 .send_xrpc::<
4098 (),
4099 _,
4100 (),
4101 _,
4102 >(
4103 &atrium_xrpc::XrpcRequest {
4104 method: http::Method::POST,
4105 nsid: crate::com::atproto::identity::update_handle::NSID.into(),
4106 parameters: None,
4107 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4108 encoding: Some(String::from("application/json")),
4109 },
4110 )
4111 .await?;
4112 match response {
4113 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
4114 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4115 }
4116 }
4117}
4118impl<T> com::atproto::label::Service<T>
4119where
4120 T: atrium_xrpc::XrpcClient + Send + Sync,
4121{
4122 #[allow(unused_variables)]
4123 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
4124 Self {
4125 xrpc,
4126 _phantom: core::marker::PhantomData,
4127 }
4128 }
4129 pub async fn query_labels(
4131 &self,
4132 params: crate::com::atproto::label::query_labels::Parameters,
4133 ) -> atrium_xrpc::Result<
4134 crate::com::atproto::label::query_labels::Output,
4135 crate::com::atproto::label::query_labels::Error,
4136 > {
4137 let response = self
4138 .xrpc
4139 .send_xrpc::<
4140 _,
4141 (),
4142 _,
4143 _,
4144 >(
4145 &atrium_xrpc::XrpcRequest {
4146 method: http::Method::GET,
4147 nsid: crate::com::atproto::label::query_labels::NSID.into(),
4148 parameters: Some(params),
4149 input: None,
4150 encoding: None,
4151 },
4152 )
4153 .await?;
4154 match response {
4155 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4156 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4157 }
4158 }
4159}
4160impl<T> com::atproto::moderation::Service<T>
4161where
4162 T: atrium_xrpc::XrpcClient + Send + Sync,
4163{
4164 #[allow(unused_variables)]
4165 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
4166 Self {
4167 xrpc,
4168 _phantom: core::marker::PhantomData,
4169 }
4170 }
4171 pub async fn create_report(
4173 &self,
4174 input: crate::com::atproto::moderation::create_report::Input,
4175 ) -> atrium_xrpc::Result<
4176 crate::com::atproto::moderation::create_report::Output,
4177 crate::com::atproto::moderation::create_report::Error,
4178 > {
4179 let response = self
4180 .xrpc
4181 .send_xrpc::<
4182 (),
4183 _,
4184 _,
4185 _,
4186 >(
4187 &atrium_xrpc::XrpcRequest {
4188 method: http::Method::POST,
4189 nsid: crate::com::atproto::moderation::create_report::NSID.into(),
4190 parameters: None,
4191 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4192 encoding: Some(String::from("application/json")),
4193 },
4194 )
4195 .await?;
4196 match response {
4197 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4198 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4199 }
4200 }
4201}
4202impl<T> com::atproto::repo::Service<T>
4203where
4204 T: atrium_xrpc::XrpcClient + Send + Sync,
4205{
4206 #[allow(unused_variables)]
4207 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
4208 Self {
4209 xrpc,
4210 _phantom: core::marker::PhantomData,
4211 }
4212 }
4213 pub async fn apply_writes(
4215 &self,
4216 input: crate::com::atproto::repo::apply_writes::Input,
4217 ) -> atrium_xrpc::Result<
4218 crate::com::atproto::repo::apply_writes::Output,
4219 crate::com::atproto::repo::apply_writes::Error,
4220 > {
4221 let response = self
4222 .xrpc
4223 .send_xrpc::<
4224 (),
4225 _,
4226 _,
4227 _,
4228 >(
4229 &atrium_xrpc::XrpcRequest {
4230 method: http::Method::POST,
4231 nsid: crate::com::atproto::repo::apply_writes::NSID.into(),
4232 parameters: None,
4233 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4234 encoding: Some(String::from("application/json")),
4235 },
4236 )
4237 .await?;
4238 match response {
4239 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4240 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4241 }
4242 }
4243 pub async fn create_record(
4245 &self,
4246 input: crate::com::atproto::repo::create_record::Input,
4247 ) -> atrium_xrpc::Result<
4248 crate::com::atproto::repo::create_record::Output,
4249 crate::com::atproto::repo::create_record::Error,
4250 > {
4251 let response = self
4252 .xrpc
4253 .send_xrpc::<
4254 (),
4255 _,
4256 _,
4257 _,
4258 >(
4259 &atrium_xrpc::XrpcRequest {
4260 method: http::Method::POST,
4261 nsid: crate::com::atproto::repo::create_record::NSID.into(),
4262 parameters: None,
4263 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4264 encoding: Some(String::from("application/json")),
4265 },
4266 )
4267 .await?;
4268 match response {
4269 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4270 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4271 }
4272 }
4273 pub async fn delete_record(
4275 &self,
4276 input: crate::com::atproto::repo::delete_record::Input,
4277 ) -> atrium_xrpc::Result<
4278 crate::com::atproto::repo::delete_record::Output,
4279 crate::com::atproto::repo::delete_record::Error,
4280 > {
4281 let response = self
4282 .xrpc
4283 .send_xrpc::<
4284 (),
4285 _,
4286 _,
4287 _,
4288 >(
4289 &atrium_xrpc::XrpcRequest {
4290 method: http::Method::POST,
4291 nsid: crate::com::atproto::repo::delete_record::NSID.into(),
4292 parameters: None,
4293 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4294 encoding: Some(String::from("application/json")),
4295 },
4296 )
4297 .await?;
4298 match response {
4299 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4300 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4301 }
4302 }
4303 pub async fn describe_repo(
4305 &self,
4306 params: crate::com::atproto::repo::describe_repo::Parameters,
4307 ) -> atrium_xrpc::Result<
4308 crate::com::atproto::repo::describe_repo::Output,
4309 crate::com::atproto::repo::describe_repo::Error,
4310 > {
4311 let response = self
4312 .xrpc
4313 .send_xrpc::<
4314 _,
4315 (),
4316 _,
4317 _,
4318 >(
4319 &atrium_xrpc::XrpcRequest {
4320 method: http::Method::GET,
4321 nsid: crate::com::atproto::repo::describe_repo::NSID.into(),
4322 parameters: Some(params),
4323 input: None,
4324 encoding: None,
4325 },
4326 )
4327 .await?;
4328 match response {
4329 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4330 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4331 }
4332 }
4333 pub async fn get_record(
4335 &self,
4336 params: crate::com::atproto::repo::get_record::Parameters,
4337 ) -> atrium_xrpc::Result<
4338 crate::com::atproto::repo::get_record::Output,
4339 crate::com::atproto::repo::get_record::Error,
4340 > {
4341 let response = self
4342 .xrpc
4343 .send_xrpc::<
4344 _,
4345 (),
4346 _,
4347 _,
4348 >(
4349 &atrium_xrpc::XrpcRequest {
4350 method: http::Method::GET,
4351 nsid: crate::com::atproto::repo::get_record::NSID.into(),
4352 parameters: Some(params),
4353 input: None,
4354 encoding: None,
4355 },
4356 )
4357 .await?;
4358 match response {
4359 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4360 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4361 }
4362 }
4363 pub async fn import_repo(
4365 &self,
4366 input: Vec<u8>,
4367 ) -> atrium_xrpc::Result<(), crate::com::atproto::repo::import_repo::Error> {
4368 let response = self
4369 .xrpc
4370 .send_xrpc::<
4371 (),
4372 Vec<u8>,
4373 (),
4374 _,
4375 >(
4376 &atrium_xrpc::XrpcRequest {
4377 method: http::Method::POST,
4378 nsid: crate::com::atproto::repo::import_repo::NSID.into(),
4379 parameters: None,
4380 input: Some(atrium_xrpc::InputDataOrBytes::Bytes(input)),
4381 encoding: Some(String::from("application/vnd.ipld.car")),
4382 },
4383 )
4384 .await?;
4385 match response {
4386 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
4387 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4388 }
4389 }
4390 pub async fn list_missing_blobs(
4392 &self,
4393 params: crate::com::atproto::repo::list_missing_blobs::Parameters,
4394 ) -> atrium_xrpc::Result<
4395 crate::com::atproto::repo::list_missing_blobs::Output,
4396 crate::com::atproto::repo::list_missing_blobs::Error,
4397 > {
4398 let response = self
4399 .xrpc
4400 .send_xrpc::<
4401 _,
4402 (),
4403 _,
4404 _,
4405 >(
4406 &atrium_xrpc::XrpcRequest {
4407 method: http::Method::GET,
4408 nsid: crate::com::atproto::repo::list_missing_blobs::NSID.into(),
4409 parameters: Some(params),
4410 input: None,
4411 encoding: None,
4412 },
4413 )
4414 .await?;
4415 match response {
4416 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4417 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4418 }
4419 }
4420 pub async fn list_records(
4422 &self,
4423 params: crate::com::atproto::repo::list_records::Parameters,
4424 ) -> atrium_xrpc::Result<
4425 crate::com::atproto::repo::list_records::Output,
4426 crate::com::atproto::repo::list_records::Error,
4427 > {
4428 let response = self
4429 .xrpc
4430 .send_xrpc::<
4431 _,
4432 (),
4433 _,
4434 _,
4435 >(
4436 &atrium_xrpc::XrpcRequest {
4437 method: http::Method::GET,
4438 nsid: crate::com::atproto::repo::list_records::NSID.into(),
4439 parameters: Some(params),
4440 input: None,
4441 encoding: None,
4442 },
4443 )
4444 .await?;
4445 match response {
4446 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4447 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4448 }
4449 }
4450 pub async fn put_record(
4452 &self,
4453 input: crate::com::atproto::repo::put_record::Input,
4454 ) -> atrium_xrpc::Result<
4455 crate::com::atproto::repo::put_record::Output,
4456 crate::com::atproto::repo::put_record::Error,
4457 > {
4458 let response = self
4459 .xrpc
4460 .send_xrpc::<
4461 (),
4462 _,
4463 _,
4464 _,
4465 >(
4466 &atrium_xrpc::XrpcRequest {
4467 method: http::Method::POST,
4468 nsid: crate::com::atproto::repo::put_record::NSID.into(),
4469 parameters: None,
4470 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4471 encoding: Some(String::from("application/json")),
4472 },
4473 )
4474 .await?;
4475 match response {
4476 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4477 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4478 }
4479 }
4480 pub async fn upload_blob(
4482 &self,
4483 input: Vec<u8>,
4484 ) -> atrium_xrpc::Result<
4485 crate::com::atproto::repo::upload_blob::Output,
4486 crate::com::atproto::repo::upload_blob::Error,
4487 > {
4488 let response = self
4489 .xrpc
4490 .send_xrpc::<
4491 (),
4492 Vec<u8>,
4493 _,
4494 _,
4495 >(
4496 &atrium_xrpc::XrpcRequest {
4497 method: http::Method::POST,
4498 nsid: crate::com::atproto::repo::upload_blob::NSID.into(),
4499 parameters: None,
4500 input: Some(atrium_xrpc::InputDataOrBytes::Bytes(input)),
4501 encoding: Some(String::from("*/*")),
4502 },
4503 )
4504 .await?;
4505 match response {
4506 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4507 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4508 }
4509 }
4510}
4511impl<T> com::atproto::server::Service<T>
4512where
4513 T: atrium_xrpc::XrpcClient + Send + Sync,
4514{
4515 #[allow(unused_variables)]
4516 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
4517 Self {
4518 xrpc,
4519 _phantom: core::marker::PhantomData,
4520 }
4521 }
4522 pub async fn activate_account(
4524 &self,
4525 ) -> atrium_xrpc::Result<(), crate::com::atproto::server::activate_account::Error> {
4526 let response = self
4527 .xrpc
4528 .send_xrpc::<
4529 (),
4530 (),
4531 (),
4532 _,
4533 >(
4534 &atrium_xrpc::XrpcRequest {
4535 method: http::Method::POST,
4536 nsid: crate::com::atproto::server::activate_account::NSID.into(),
4537 parameters: None,
4538 input: None,
4539 encoding: None,
4540 },
4541 )
4542 .await?;
4543 match response {
4544 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
4545 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4546 }
4547 }
4548 pub async fn check_account_status(
4550 &self,
4551 ) -> atrium_xrpc::Result<
4552 crate::com::atproto::server::check_account_status::Output,
4553 crate::com::atproto::server::check_account_status::Error,
4554 > {
4555 let response = self
4556 .xrpc
4557 .send_xrpc::<
4558 (),
4559 (),
4560 _,
4561 _,
4562 >(
4563 &atrium_xrpc::XrpcRequest {
4564 method: http::Method::GET,
4565 nsid: crate::com::atproto::server::check_account_status::NSID.into(),
4566 parameters: None,
4567 input: None,
4568 encoding: None,
4569 },
4570 )
4571 .await?;
4572 match response {
4573 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4574 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4575 }
4576 }
4577 pub async fn confirm_email(
4579 &self,
4580 input: crate::com::atproto::server::confirm_email::Input,
4581 ) -> atrium_xrpc::Result<(), crate::com::atproto::server::confirm_email::Error> {
4582 let response = self
4583 .xrpc
4584 .send_xrpc::<
4585 (),
4586 _,
4587 (),
4588 _,
4589 >(
4590 &atrium_xrpc::XrpcRequest {
4591 method: http::Method::POST,
4592 nsid: crate::com::atproto::server::confirm_email::NSID.into(),
4593 parameters: None,
4594 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4595 encoding: Some(String::from("application/json")),
4596 },
4597 )
4598 .await?;
4599 match response {
4600 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
4601 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4602 }
4603 }
4604 pub async fn create_account(
4606 &self,
4607 input: crate::com::atproto::server::create_account::Input,
4608 ) -> atrium_xrpc::Result<
4609 crate::com::atproto::server::create_account::Output,
4610 crate::com::atproto::server::create_account::Error,
4611 > {
4612 let response = self
4613 .xrpc
4614 .send_xrpc::<
4615 (),
4616 _,
4617 _,
4618 _,
4619 >(
4620 &atrium_xrpc::XrpcRequest {
4621 method: http::Method::POST,
4622 nsid: crate::com::atproto::server::create_account::NSID.into(),
4623 parameters: None,
4624 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4625 encoding: Some(String::from("application/json")),
4626 },
4627 )
4628 .await?;
4629 match response {
4630 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4631 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4632 }
4633 }
4634 pub async fn create_app_password(
4636 &self,
4637 input: crate::com::atproto::server::create_app_password::Input,
4638 ) -> atrium_xrpc::Result<
4639 crate::com::atproto::server::create_app_password::Output,
4640 crate::com::atproto::server::create_app_password::Error,
4641 > {
4642 let response = self
4643 .xrpc
4644 .send_xrpc::<
4645 (),
4646 _,
4647 _,
4648 _,
4649 >(
4650 &atrium_xrpc::XrpcRequest {
4651 method: http::Method::POST,
4652 nsid: crate::com::atproto::server::create_app_password::NSID.into(),
4653 parameters: None,
4654 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4655 encoding: Some(String::from("application/json")),
4656 },
4657 )
4658 .await?;
4659 match response {
4660 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4661 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4662 }
4663 }
4664 pub async fn create_invite_code(
4666 &self,
4667 input: crate::com::atproto::server::create_invite_code::Input,
4668 ) -> atrium_xrpc::Result<
4669 crate::com::atproto::server::create_invite_code::Output,
4670 crate::com::atproto::server::create_invite_code::Error,
4671 > {
4672 let response = self
4673 .xrpc
4674 .send_xrpc::<
4675 (),
4676 _,
4677 _,
4678 _,
4679 >(
4680 &atrium_xrpc::XrpcRequest {
4681 method: http::Method::POST,
4682 nsid: crate::com::atproto::server::create_invite_code::NSID.into(),
4683 parameters: None,
4684 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4685 encoding: Some(String::from("application/json")),
4686 },
4687 )
4688 .await?;
4689 match response {
4690 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4691 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4692 }
4693 }
4694 pub async fn create_invite_codes(
4696 &self,
4697 input: crate::com::atproto::server::create_invite_codes::Input,
4698 ) -> atrium_xrpc::Result<
4699 crate::com::atproto::server::create_invite_codes::Output,
4700 crate::com::atproto::server::create_invite_codes::Error,
4701 > {
4702 let response = self
4703 .xrpc
4704 .send_xrpc::<
4705 (),
4706 _,
4707 _,
4708 _,
4709 >(
4710 &atrium_xrpc::XrpcRequest {
4711 method: http::Method::POST,
4712 nsid: crate::com::atproto::server::create_invite_codes::NSID.into(),
4713 parameters: None,
4714 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4715 encoding: Some(String::from("application/json")),
4716 },
4717 )
4718 .await?;
4719 match response {
4720 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4721 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4722 }
4723 }
4724 pub async fn create_session(
4726 &self,
4727 input: crate::com::atproto::server::create_session::Input,
4728 ) -> atrium_xrpc::Result<
4729 crate::com::atproto::server::create_session::Output,
4730 crate::com::atproto::server::create_session::Error,
4731 > {
4732 let response = self
4733 .xrpc
4734 .send_xrpc::<
4735 (),
4736 _,
4737 _,
4738 _,
4739 >(
4740 &atrium_xrpc::XrpcRequest {
4741 method: http::Method::POST,
4742 nsid: crate::com::atproto::server::create_session::NSID.into(),
4743 parameters: None,
4744 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4745 encoding: Some(String::from("application/json")),
4746 },
4747 )
4748 .await?;
4749 match response {
4750 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4751 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4752 }
4753 }
4754 pub async fn deactivate_account(
4756 &self,
4757 input: crate::com::atproto::server::deactivate_account::Input,
4758 ) -> atrium_xrpc::Result<
4759 (),
4760 crate::com::atproto::server::deactivate_account::Error,
4761 > {
4762 let response = self
4763 .xrpc
4764 .send_xrpc::<
4765 (),
4766 _,
4767 (),
4768 _,
4769 >(
4770 &atrium_xrpc::XrpcRequest {
4771 method: http::Method::POST,
4772 nsid: crate::com::atproto::server::deactivate_account::NSID.into(),
4773 parameters: None,
4774 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4775 encoding: Some(String::from("application/json")),
4776 },
4777 )
4778 .await?;
4779 match response {
4780 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
4781 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4782 }
4783 }
4784 pub async fn delete_account(
4786 &self,
4787 input: crate::com::atproto::server::delete_account::Input,
4788 ) -> atrium_xrpc::Result<(), crate::com::atproto::server::delete_account::Error> {
4789 let response = self
4790 .xrpc
4791 .send_xrpc::<
4792 (),
4793 _,
4794 (),
4795 _,
4796 >(
4797 &atrium_xrpc::XrpcRequest {
4798 method: http::Method::POST,
4799 nsid: crate::com::atproto::server::delete_account::NSID.into(),
4800 parameters: None,
4801 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
4802 encoding: Some(String::from("application/json")),
4803 },
4804 )
4805 .await?;
4806 match response {
4807 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
4808 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4809 }
4810 }
4811 pub async fn delete_session(
4813 &self,
4814 ) -> atrium_xrpc::Result<(), crate::com::atproto::server::delete_session::Error> {
4815 let response = self
4816 .xrpc
4817 .send_xrpc::<
4818 (),
4819 (),
4820 (),
4821 _,
4822 >(
4823 &atrium_xrpc::XrpcRequest {
4824 method: http::Method::POST,
4825 nsid: crate::com::atproto::server::delete_session::NSID.into(),
4826 parameters: None,
4827 input: None,
4828 encoding: None,
4829 },
4830 )
4831 .await?;
4832 match response {
4833 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
4834 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4835 }
4836 }
4837 pub async fn describe_server(
4839 &self,
4840 ) -> atrium_xrpc::Result<
4841 crate::com::atproto::server::describe_server::Output,
4842 crate::com::atproto::server::describe_server::Error,
4843 > {
4844 let response = self
4845 .xrpc
4846 .send_xrpc::<
4847 (),
4848 (),
4849 _,
4850 _,
4851 >(
4852 &atrium_xrpc::XrpcRequest {
4853 method: http::Method::GET,
4854 nsid: crate::com::atproto::server::describe_server::NSID.into(),
4855 parameters: None,
4856 input: None,
4857 encoding: None,
4858 },
4859 )
4860 .await?;
4861 match response {
4862 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4863 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4864 }
4865 }
4866 pub async fn get_account_invite_codes(
4868 &self,
4869 params: crate::com::atproto::server::get_account_invite_codes::Parameters,
4870 ) -> atrium_xrpc::Result<
4871 crate::com::atproto::server::get_account_invite_codes::Output,
4872 crate::com::atproto::server::get_account_invite_codes::Error,
4873 > {
4874 let response = self
4875 .xrpc
4876 .send_xrpc::<
4877 _,
4878 (),
4879 _,
4880 _,
4881 >(
4882 &atrium_xrpc::XrpcRequest {
4883 method: http::Method::GET,
4884 nsid: crate::com::atproto::server::get_account_invite_codes::NSID
4885 .into(),
4886 parameters: Some(params),
4887 input: None,
4888 encoding: None,
4889 },
4890 )
4891 .await?;
4892 match response {
4893 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4894 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4895 }
4896 }
4897 pub async fn get_service_auth(
4899 &self,
4900 params: crate::com::atproto::server::get_service_auth::Parameters,
4901 ) -> atrium_xrpc::Result<
4902 crate::com::atproto::server::get_service_auth::Output,
4903 crate::com::atproto::server::get_service_auth::Error,
4904 > {
4905 let response = self
4906 .xrpc
4907 .send_xrpc::<
4908 _,
4909 (),
4910 _,
4911 _,
4912 >(
4913 &atrium_xrpc::XrpcRequest {
4914 method: http::Method::GET,
4915 nsid: crate::com::atproto::server::get_service_auth::NSID.into(),
4916 parameters: Some(params),
4917 input: None,
4918 encoding: None,
4919 },
4920 )
4921 .await?;
4922 match response {
4923 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4924 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4925 }
4926 }
4927 pub async fn get_session(
4929 &self,
4930 ) -> atrium_xrpc::Result<
4931 crate::com::atproto::server::get_session::Output,
4932 crate::com::atproto::server::get_session::Error,
4933 > {
4934 let response = self
4935 .xrpc
4936 .send_xrpc::<
4937 (),
4938 (),
4939 _,
4940 _,
4941 >(
4942 &atrium_xrpc::XrpcRequest {
4943 method: http::Method::GET,
4944 nsid: crate::com::atproto::server::get_session::NSID.into(),
4945 parameters: None,
4946 input: None,
4947 encoding: None,
4948 },
4949 )
4950 .await?;
4951 match response {
4952 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4953 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4954 }
4955 }
4956 pub async fn list_app_passwords(
4958 &self,
4959 ) -> atrium_xrpc::Result<
4960 crate::com::atproto::server::list_app_passwords::Output,
4961 crate::com::atproto::server::list_app_passwords::Error,
4962 > {
4963 let response = self
4964 .xrpc
4965 .send_xrpc::<
4966 (),
4967 (),
4968 _,
4969 _,
4970 >(
4971 &atrium_xrpc::XrpcRequest {
4972 method: http::Method::GET,
4973 nsid: crate::com::atproto::server::list_app_passwords::NSID.into(),
4974 parameters: None,
4975 input: None,
4976 encoding: None,
4977 },
4978 )
4979 .await?;
4980 match response {
4981 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
4982 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
4983 }
4984 }
4985 pub async fn refresh_session(
4987 &self,
4988 ) -> atrium_xrpc::Result<
4989 crate::com::atproto::server::refresh_session::Output,
4990 crate::com::atproto::server::refresh_session::Error,
4991 > {
4992 let response = self
4993 .xrpc
4994 .send_xrpc::<
4995 (),
4996 (),
4997 _,
4998 _,
4999 >(
5000 &atrium_xrpc::XrpcRequest {
5001 method: http::Method::POST,
5002 nsid: crate::com::atproto::server::refresh_session::NSID.into(),
5003 parameters: None,
5004 input: None,
5005 encoding: None,
5006 },
5007 )
5008 .await?;
5009 match response {
5010 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5011 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5012 }
5013 }
5014 pub async fn request_account_delete(
5016 &self,
5017 ) -> atrium_xrpc::Result<
5018 (),
5019 crate::com::atproto::server::request_account_delete::Error,
5020 > {
5021 let response = self
5022 .xrpc
5023 .send_xrpc::<
5024 (),
5025 (),
5026 (),
5027 _,
5028 >(
5029 &atrium_xrpc::XrpcRequest {
5030 method: http::Method::POST,
5031 nsid: crate::com::atproto::server::request_account_delete::NSID
5032 .into(),
5033 parameters: None,
5034 input: None,
5035 encoding: None,
5036 },
5037 )
5038 .await?;
5039 match response {
5040 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
5041 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5042 }
5043 }
5044 pub async fn request_email_confirmation(
5046 &self,
5047 ) -> atrium_xrpc::Result<
5048 (),
5049 crate::com::atproto::server::request_email_confirmation::Error,
5050 > {
5051 let response = self
5052 .xrpc
5053 .send_xrpc::<
5054 (),
5055 (),
5056 (),
5057 _,
5058 >(
5059 &atrium_xrpc::XrpcRequest {
5060 method: http::Method::POST,
5061 nsid: crate::com::atproto::server::request_email_confirmation::NSID
5062 .into(),
5063 parameters: None,
5064 input: None,
5065 encoding: None,
5066 },
5067 )
5068 .await?;
5069 match response {
5070 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
5071 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5072 }
5073 }
5074 pub async fn request_email_update(
5076 &self,
5077 ) -> atrium_xrpc::Result<
5078 crate::com::atproto::server::request_email_update::Output,
5079 crate::com::atproto::server::request_email_update::Error,
5080 > {
5081 let response = self
5082 .xrpc
5083 .send_xrpc::<
5084 (),
5085 (),
5086 _,
5087 _,
5088 >(
5089 &atrium_xrpc::XrpcRequest {
5090 method: http::Method::POST,
5091 nsid: crate::com::atproto::server::request_email_update::NSID.into(),
5092 parameters: None,
5093 input: None,
5094 encoding: None,
5095 },
5096 )
5097 .await?;
5098 match response {
5099 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5100 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5101 }
5102 }
5103 pub async fn request_password_reset(
5105 &self,
5106 input: crate::com::atproto::server::request_password_reset::Input,
5107 ) -> atrium_xrpc::Result<
5108 (),
5109 crate::com::atproto::server::request_password_reset::Error,
5110 > {
5111 let response = self
5112 .xrpc
5113 .send_xrpc::<
5114 (),
5115 _,
5116 (),
5117 _,
5118 >(
5119 &atrium_xrpc::XrpcRequest {
5120 method: http::Method::POST,
5121 nsid: crate::com::atproto::server::request_password_reset::NSID
5122 .into(),
5123 parameters: None,
5124 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
5125 encoding: Some(String::from("application/json")),
5126 },
5127 )
5128 .await?;
5129 match response {
5130 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
5131 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5132 }
5133 }
5134 pub async fn reserve_signing_key(
5136 &self,
5137 input: crate::com::atproto::server::reserve_signing_key::Input,
5138 ) -> atrium_xrpc::Result<
5139 crate::com::atproto::server::reserve_signing_key::Output,
5140 crate::com::atproto::server::reserve_signing_key::Error,
5141 > {
5142 let response = self
5143 .xrpc
5144 .send_xrpc::<
5145 (),
5146 _,
5147 _,
5148 _,
5149 >(
5150 &atrium_xrpc::XrpcRequest {
5151 method: http::Method::POST,
5152 nsid: crate::com::atproto::server::reserve_signing_key::NSID.into(),
5153 parameters: None,
5154 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
5155 encoding: Some(String::from("application/json")),
5156 },
5157 )
5158 .await?;
5159 match response {
5160 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5161 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5162 }
5163 }
5164 pub async fn reset_password(
5166 &self,
5167 input: crate::com::atproto::server::reset_password::Input,
5168 ) -> atrium_xrpc::Result<(), crate::com::atproto::server::reset_password::Error> {
5169 let response = self
5170 .xrpc
5171 .send_xrpc::<
5172 (),
5173 _,
5174 (),
5175 _,
5176 >(
5177 &atrium_xrpc::XrpcRequest {
5178 method: http::Method::POST,
5179 nsid: crate::com::atproto::server::reset_password::NSID.into(),
5180 parameters: None,
5181 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
5182 encoding: Some(String::from("application/json")),
5183 },
5184 )
5185 .await?;
5186 match response {
5187 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
5188 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5189 }
5190 }
5191 pub async fn revoke_app_password(
5193 &self,
5194 input: crate::com::atproto::server::revoke_app_password::Input,
5195 ) -> atrium_xrpc::Result<
5196 (),
5197 crate::com::atproto::server::revoke_app_password::Error,
5198 > {
5199 let response = self
5200 .xrpc
5201 .send_xrpc::<
5202 (),
5203 _,
5204 (),
5205 _,
5206 >(
5207 &atrium_xrpc::XrpcRequest {
5208 method: http::Method::POST,
5209 nsid: crate::com::atproto::server::revoke_app_password::NSID.into(),
5210 parameters: None,
5211 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
5212 encoding: Some(String::from("application/json")),
5213 },
5214 )
5215 .await?;
5216 match response {
5217 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
5218 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5219 }
5220 }
5221 pub async fn update_email(
5223 &self,
5224 input: crate::com::atproto::server::update_email::Input,
5225 ) -> atrium_xrpc::Result<(), crate::com::atproto::server::update_email::Error> {
5226 let response = self
5227 .xrpc
5228 .send_xrpc::<
5229 (),
5230 _,
5231 (),
5232 _,
5233 >(
5234 &atrium_xrpc::XrpcRequest {
5235 method: http::Method::POST,
5236 nsid: crate::com::atproto::server::update_email::NSID.into(),
5237 parameters: None,
5238 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
5239 encoding: Some(String::from("application/json")),
5240 },
5241 )
5242 .await?;
5243 match response {
5244 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
5245 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5246 }
5247 }
5248}
5249impl<T> com::atproto::sync::Service<T>
5250where
5251 T: atrium_xrpc::XrpcClient + Send + Sync,
5252{
5253 #[allow(unused_variables)]
5254 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
5255 Self {
5256 xrpc,
5257 _phantom: core::marker::PhantomData,
5258 }
5259 }
5260 pub async fn get_blob(
5262 &self,
5263 params: crate::com::atproto::sync::get_blob::Parameters,
5264 ) -> atrium_xrpc::Result<Vec<u8>, crate::com::atproto::sync::get_blob::Error> {
5265 let response = self
5266 .xrpc
5267 .send_xrpc::<
5268 _,
5269 (),
5270 (),
5271 _,
5272 >(
5273 &atrium_xrpc::XrpcRequest {
5274 method: http::Method::GET,
5275 nsid: crate::com::atproto::sync::get_blob::NSID.into(),
5276 parameters: Some(params),
5277 input: None,
5278 encoding: None,
5279 },
5280 )
5281 .await?;
5282 match response {
5283 atrium_xrpc::OutputDataOrBytes::Bytes(bytes) => Ok(bytes),
5284 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5285 }
5286 }
5287 pub async fn get_blocks(
5289 &self,
5290 params: crate::com::atproto::sync::get_blocks::Parameters,
5291 ) -> atrium_xrpc::Result<Vec<u8>, crate::com::atproto::sync::get_blocks::Error> {
5292 let response = self
5293 .xrpc
5294 .send_xrpc::<
5295 _,
5296 (),
5297 (),
5298 _,
5299 >(
5300 &atrium_xrpc::XrpcRequest {
5301 method: http::Method::GET,
5302 nsid: crate::com::atproto::sync::get_blocks::NSID.into(),
5303 parameters: Some(params),
5304 input: None,
5305 encoding: None,
5306 },
5307 )
5308 .await?;
5309 match response {
5310 atrium_xrpc::OutputDataOrBytes::Bytes(bytes) => Ok(bytes),
5311 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5312 }
5313 }
5314 pub async fn get_checkout(
5316 &self,
5317 params: crate::com::atproto::sync::get_checkout::Parameters,
5318 ) -> atrium_xrpc::Result<Vec<u8>, crate::com::atproto::sync::get_checkout::Error> {
5319 let response = self
5320 .xrpc
5321 .send_xrpc::<
5322 _,
5323 (),
5324 (),
5325 _,
5326 >(
5327 &atrium_xrpc::XrpcRequest {
5328 method: http::Method::GET,
5329 nsid: crate::com::atproto::sync::get_checkout::NSID.into(),
5330 parameters: Some(params),
5331 input: None,
5332 encoding: None,
5333 },
5334 )
5335 .await?;
5336 match response {
5337 atrium_xrpc::OutputDataOrBytes::Bytes(bytes) => Ok(bytes),
5338 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5339 }
5340 }
5341 pub async fn get_head(
5343 &self,
5344 params: crate::com::atproto::sync::get_head::Parameters,
5345 ) -> atrium_xrpc::Result<
5346 crate::com::atproto::sync::get_head::Output,
5347 crate::com::atproto::sync::get_head::Error,
5348 > {
5349 let response = self
5350 .xrpc
5351 .send_xrpc::<
5352 _,
5353 (),
5354 _,
5355 _,
5356 >(
5357 &atrium_xrpc::XrpcRequest {
5358 method: http::Method::GET,
5359 nsid: crate::com::atproto::sync::get_head::NSID.into(),
5360 parameters: Some(params),
5361 input: None,
5362 encoding: None,
5363 },
5364 )
5365 .await?;
5366 match response {
5367 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5368 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5369 }
5370 }
5371 pub async fn get_host_status(
5373 &self,
5374 params: crate::com::atproto::sync::get_host_status::Parameters,
5375 ) -> atrium_xrpc::Result<
5376 crate::com::atproto::sync::get_host_status::Output,
5377 crate::com::atproto::sync::get_host_status::Error,
5378 > {
5379 let response = self
5380 .xrpc
5381 .send_xrpc::<
5382 _,
5383 (),
5384 _,
5385 _,
5386 >(
5387 &atrium_xrpc::XrpcRequest {
5388 method: http::Method::GET,
5389 nsid: crate::com::atproto::sync::get_host_status::NSID.into(),
5390 parameters: Some(params),
5391 input: None,
5392 encoding: None,
5393 },
5394 )
5395 .await?;
5396 match response {
5397 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5398 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5399 }
5400 }
5401 pub async fn get_latest_commit(
5403 &self,
5404 params: crate::com::atproto::sync::get_latest_commit::Parameters,
5405 ) -> atrium_xrpc::Result<
5406 crate::com::atproto::sync::get_latest_commit::Output,
5407 crate::com::atproto::sync::get_latest_commit::Error,
5408 > {
5409 let response = self
5410 .xrpc
5411 .send_xrpc::<
5412 _,
5413 (),
5414 _,
5415 _,
5416 >(
5417 &atrium_xrpc::XrpcRequest {
5418 method: http::Method::GET,
5419 nsid: crate::com::atproto::sync::get_latest_commit::NSID.into(),
5420 parameters: Some(params),
5421 input: None,
5422 encoding: None,
5423 },
5424 )
5425 .await?;
5426 match response {
5427 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5428 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5429 }
5430 }
5431 pub async fn get_record(
5433 &self,
5434 params: crate::com::atproto::sync::get_record::Parameters,
5435 ) -> atrium_xrpc::Result<Vec<u8>, crate::com::atproto::sync::get_record::Error> {
5436 let response = self
5437 .xrpc
5438 .send_xrpc::<
5439 _,
5440 (),
5441 (),
5442 _,
5443 >(
5444 &atrium_xrpc::XrpcRequest {
5445 method: http::Method::GET,
5446 nsid: crate::com::atproto::sync::get_record::NSID.into(),
5447 parameters: Some(params),
5448 input: None,
5449 encoding: None,
5450 },
5451 )
5452 .await?;
5453 match response {
5454 atrium_xrpc::OutputDataOrBytes::Bytes(bytes) => Ok(bytes),
5455 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5456 }
5457 }
5458 pub async fn get_repo(
5460 &self,
5461 params: crate::com::atproto::sync::get_repo::Parameters,
5462 ) -> atrium_xrpc::Result<Vec<u8>, crate::com::atproto::sync::get_repo::Error> {
5463 let response = self
5464 .xrpc
5465 .send_xrpc::<
5466 _,
5467 (),
5468 (),
5469 _,
5470 >(
5471 &atrium_xrpc::XrpcRequest {
5472 method: http::Method::GET,
5473 nsid: crate::com::atproto::sync::get_repo::NSID.into(),
5474 parameters: Some(params),
5475 input: None,
5476 encoding: None,
5477 },
5478 )
5479 .await?;
5480 match response {
5481 atrium_xrpc::OutputDataOrBytes::Bytes(bytes) => Ok(bytes),
5482 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5483 }
5484 }
5485 pub async fn get_repo_status(
5487 &self,
5488 params: crate::com::atproto::sync::get_repo_status::Parameters,
5489 ) -> atrium_xrpc::Result<
5490 crate::com::atproto::sync::get_repo_status::Output,
5491 crate::com::atproto::sync::get_repo_status::Error,
5492 > {
5493 let response = self
5494 .xrpc
5495 .send_xrpc::<
5496 _,
5497 (),
5498 _,
5499 _,
5500 >(
5501 &atrium_xrpc::XrpcRequest {
5502 method: http::Method::GET,
5503 nsid: crate::com::atproto::sync::get_repo_status::NSID.into(),
5504 parameters: Some(params),
5505 input: None,
5506 encoding: None,
5507 },
5508 )
5509 .await?;
5510 match response {
5511 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5512 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5513 }
5514 }
5515 pub async fn list_blobs(
5517 &self,
5518 params: crate::com::atproto::sync::list_blobs::Parameters,
5519 ) -> atrium_xrpc::Result<
5520 crate::com::atproto::sync::list_blobs::Output,
5521 crate::com::atproto::sync::list_blobs::Error,
5522 > {
5523 let response = self
5524 .xrpc
5525 .send_xrpc::<
5526 _,
5527 (),
5528 _,
5529 _,
5530 >(
5531 &atrium_xrpc::XrpcRequest {
5532 method: http::Method::GET,
5533 nsid: crate::com::atproto::sync::list_blobs::NSID.into(),
5534 parameters: Some(params),
5535 input: None,
5536 encoding: None,
5537 },
5538 )
5539 .await?;
5540 match response {
5541 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5542 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5543 }
5544 }
5545 pub async fn list_hosts(
5547 &self,
5548 params: crate::com::atproto::sync::list_hosts::Parameters,
5549 ) -> atrium_xrpc::Result<
5550 crate::com::atproto::sync::list_hosts::Output,
5551 crate::com::atproto::sync::list_hosts::Error,
5552 > {
5553 let response = self
5554 .xrpc
5555 .send_xrpc::<
5556 _,
5557 (),
5558 _,
5559 _,
5560 >(
5561 &atrium_xrpc::XrpcRequest {
5562 method: http::Method::GET,
5563 nsid: crate::com::atproto::sync::list_hosts::NSID.into(),
5564 parameters: Some(params),
5565 input: None,
5566 encoding: None,
5567 },
5568 )
5569 .await?;
5570 match response {
5571 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5572 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5573 }
5574 }
5575 pub async fn list_repos(
5577 &self,
5578 params: crate::com::atproto::sync::list_repos::Parameters,
5579 ) -> atrium_xrpc::Result<
5580 crate::com::atproto::sync::list_repos::Output,
5581 crate::com::atproto::sync::list_repos::Error,
5582 > {
5583 let response = self
5584 .xrpc
5585 .send_xrpc::<
5586 _,
5587 (),
5588 _,
5589 _,
5590 >(
5591 &atrium_xrpc::XrpcRequest {
5592 method: http::Method::GET,
5593 nsid: crate::com::atproto::sync::list_repos::NSID.into(),
5594 parameters: Some(params),
5595 input: None,
5596 encoding: None,
5597 },
5598 )
5599 .await?;
5600 match response {
5601 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5602 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5603 }
5604 }
5605 pub async fn list_repos_by_collection(
5607 &self,
5608 params: crate::com::atproto::sync::list_repos_by_collection::Parameters,
5609 ) -> atrium_xrpc::Result<
5610 crate::com::atproto::sync::list_repos_by_collection::Output,
5611 crate::com::atproto::sync::list_repos_by_collection::Error,
5612 > {
5613 let response = self
5614 .xrpc
5615 .send_xrpc::<
5616 _,
5617 (),
5618 _,
5619 _,
5620 >(
5621 &atrium_xrpc::XrpcRequest {
5622 method: http::Method::GET,
5623 nsid: crate::com::atproto::sync::list_repos_by_collection::NSID
5624 .into(),
5625 parameters: Some(params),
5626 input: None,
5627 encoding: None,
5628 },
5629 )
5630 .await?;
5631 match response {
5632 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5633 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5634 }
5635 }
5636 pub async fn notify_of_update(
5638 &self,
5639 input: crate::com::atproto::sync::notify_of_update::Input,
5640 ) -> atrium_xrpc::Result<(), crate::com::atproto::sync::notify_of_update::Error> {
5641 let response = self
5642 .xrpc
5643 .send_xrpc::<
5644 (),
5645 _,
5646 (),
5647 _,
5648 >(
5649 &atrium_xrpc::XrpcRequest {
5650 method: http::Method::POST,
5651 nsid: crate::com::atproto::sync::notify_of_update::NSID.into(),
5652 parameters: None,
5653 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
5654 encoding: Some(String::from("application/json")),
5655 },
5656 )
5657 .await?;
5658 match response {
5659 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
5660 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5661 }
5662 }
5663 pub async fn request_crawl(
5665 &self,
5666 input: crate::com::atproto::sync::request_crawl::Input,
5667 ) -> atrium_xrpc::Result<(), crate::com::atproto::sync::request_crawl::Error> {
5668 let response = self
5669 .xrpc
5670 .send_xrpc::<
5671 (),
5672 _,
5673 (),
5674 _,
5675 >(
5676 &atrium_xrpc::XrpcRequest {
5677 method: http::Method::POST,
5678 nsid: crate::com::atproto::sync::request_crawl::NSID.into(),
5679 parameters: None,
5680 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
5681 encoding: Some(String::from("application/json")),
5682 },
5683 )
5684 .await?;
5685 match response {
5686 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
5687 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5688 }
5689 }
5690}
5691impl<T> com::atproto::temp::Service<T>
5692where
5693 T: atrium_xrpc::XrpcClient + Send + Sync,
5694{
5695 #[allow(unused_variables)]
5696 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
5697 Self {
5698 xrpc,
5699 _phantom: core::marker::PhantomData,
5700 }
5701 }
5702 pub async fn add_reserved_handle(
5704 &self,
5705 input: crate::com::atproto::temp::add_reserved_handle::Input,
5706 ) -> atrium_xrpc::Result<
5707 crate::com::atproto::temp::add_reserved_handle::Output,
5708 crate::com::atproto::temp::add_reserved_handle::Error,
5709 > {
5710 let response = self
5711 .xrpc
5712 .send_xrpc::<
5713 (),
5714 _,
5715 _,
5716 _,
5717 >(
5718 &atrium_xrpc::XrpcRequest {
5719 method: http::Method::POST,
5720 nsid: crate::com::atproto::temp::add_reserved_handle::NSID.into(),
5721 parameters: None,
5722 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
5723 encoding: Some(String::from("application/json")),
5724 },
5725 )
5726 .await?;
5727 match response {
5728 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5729 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5730 }
5731 }
5732 pub async fn check_signup_queue(
5734 &self,
5735 ) -> atrium_xrpc::Result<
5736 crate::com::atproto::temp::check_signup_queue::Output,
5737 crate::com::atproto::temp::check_signup_queue::Error,
5738 > {
5739 let response = self
5740 .xrpc
5741 .send_xrpc::<
5742 (),
5743 (),
5744 _,
5745 _,
5746 >(
5747 &atrium_xrpc::XrpcRequest {
5748 method: http::Method::GET,
5749 nsid: crate::com::atproto::temp::check_signup_queue::NSID.into(),
5750 parameters: None,
5751 input: None,
5752 encoding: None,
5753 },
5754 )
5755 .await?;
5756 match response {
5757 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5758 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5759 }
5760 }
5761 pub async fn fetch_labels(
5763 &self,
5764 params: crate::com::atproto::temp::fetch_labels::Parameters,
5765 ) -> atrium_xrpc::Result<
5766 crate::com::atproto::temp::fetch_labels::Output,
5767 crate::com::atproto::temp::fetch_labels::Error,
5768 > {
5769 let response = self
5770 .xrpc
5771 .send_xrpc::<
5772 _,
5773 (),
5774 _,
5775 _,
5776 >(
5777 &atrium_xrpc::XrpcRequest {
5778 method: http::Method::GET,
5779 nsid: crate::com::atproto::temp::fetch_labels::NSID.into(),
5780 parameters: Some(params),
5781 input: None,
5782 encoding: None,
5783 },
5784 )
5785 .await?;
5786 match response {
5787 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5788 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5789 }
5790 }
5791 pub async fn request_phone_verification(
5793 &self,
5794 input: crate::com::atproto::temp::request_phone_verification::Input,
5795 ) -> atrium_xrpc::Result<
5796 (),
5797 crate::com::atproto::temp::request_phone_verification::Error,
5798 > {
5799 let response = self
5800 .xrpc
5801 .send_xrpc::<
5802 (),
5803 _,
5804 (),
5805 _,
5806 >(
5807 &atrium_xrpc::XrpcRequest {
5808 method: http::Method::POST,
5809 nsid: crate::com::atproto::temp::request_phone_verification::NSID
5810 .into(),
5811 parameters: None,
5812 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
5813 encoding: Some(String::from("application/json")),
5814 },
5815 )
5816 .await?;
5817 match response {
5818 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
5819 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5820 }
5821 }
5822}
5823impl<T> tools::Service<T>
5824where
5825 T: atrium_xrpc::XrpcClient + Send + Sync,
5826{
5827 #[allow(unused_variables)]
5828 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
5829 Self {
5830 #[cfg(feature = "namespace-toolsozone")]
5831 ozone: tools::ozone::Service::new(std::sync::Arc::clone(&xrpc)),
5832 _phantom: core::marker::PhantomData,
5833 }
5834 }
5835}
5836#[cfg(feature = "namespace-toolsozone")]
5837impl<T> tools::ozone::Service<T>
5838where
5839 T: atrium_xrpc::XrpcClient + Send + Sync,
5840{
5841 #[allow(unused_variables)]
5842 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
5843 Self {
5844 communication: tools::ozone::communication::Service::new(
5845 std::sync::Arc::clone(&xrpc),
5846 ),
5847 hosting: tools::ozone::hosting::Service::new(std::sync::Arc::clone(&xrpc)),
5848 moderation: tools::ozone::moderation::Service::new(
5849 std::sync::Arc::clone(&xrpc),
5850 ),
5851 server: tools::ozone::server::Service::new(std::sync::Arc::clone(&xrpc)),
5852 set: tools::ozone::set::Service::new(std::sync::Arc::clone(&xrpc)),
5853 setting: tools::ozone::setting::Service::new(std::sync::Arc::clone(&xrpc)),
5854 signature: tools::ozone::signature::Service::new(
5855 std::sync::Arc::clone(&xrpc),
5856 ),
5857 team: tools::ozone::team::Service::new(std::sync::Arc::clone(&xrpc)),
5858 verification: tools::ozone::verification::Service::new(
5859 std::sync::Arc::clone(&xrpc),
5860 ),
5861 _phantom: core::marker::PhantomData,
5862 }
5863 }
5864}
5865#[cfg(feature = "namespace-toolsozone")]
5866impl<T> tools::ozone::communication::Service<T>
5867where
5868 T: atrium_xrpc::XrpcClient + Send + Sync,
5869{
5870 #[allow(unused_variables)]
5871 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
5872 Self {
5873 xrpc,
5874 _phantom: core::marker::PhantomData,
5875 }
5876 }
5877 pub async fn create_template(
5879 &self,
5880 input: crate::tools::ozone::communication::create_template::Input,
5881 ) -> atrium_xrpc::Result<
5882 crate::tools::ozone::communication::create_template::Output,
5883 crate::tools::ozone::communication::create_template::Error,
5884 > {
5885 let response = self
5886 .xrpc
5887 .send_xrpc::<
5888 (),
5889 _,
5890 _,
5891 _,
5892 >(
5893 &atrium_xrpc::XrpcRequest {
5894 method: http::Method::POST,
5895 nsid: crate::tools::ozone::communication::create_template::NSID
5896 .into(),
5897 parameters: None,
5898 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
5899 encoding: Some(String::from("application/json")),
5900 },
5901 )
5902 .await?;
5903 match response {
5904 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5905 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5906 }
5907 }
5908 pub async fn delete_template(
5910 &self,
5911 input: crate::tools::ozone::communication::delete_template::Input,
5912 ) -> atrium_xrpc::Result<
5913 (),
5914 crate::tools::ozone::communication::delete_template::Error,
5915 > {
5916 let response = self
5917 .xrpc
5918 .send_xrpc::<
5919 (),
5920 _,
5921 (),
5922 _,
5923 >(
5924 &atrium_xrpc::XrpcRequest {
5925 method: http::Method::POST,
5926 nsid: crate::tools::ozone::communication::delete_template::NSID
5927 .into(),
5928 parameters: None,
5929 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
5930 encoding: Some(String::from("application/json")),
5931 },
5932 )
5933 .await?;
5934 match response {
5935 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
5936 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5937 }
5938 }
5939 pub async fn list_templates(
5941 &self,
5942 ) -> atrium_xrpc::Result<
5943 crate::tools::ozone::communication::list_templates::Output,
5944 crate::tools::ozone::communication::list_templates::Error,
5945 > {
5946 let response = self
5947 .xrpc
5948 .send_xrpc::<
5949 (),
5950 (),
5951 _,
5952 _,
5953 >(
5954 &atrium_xrpc::XrpcRequest {
5955 method: http::Method::GET,
5956 nsid: crate::tools::ozone::communication::list_templates::NSID
5957 .into(),
5958 parameters: None,
5959 input: None,
5960 encoding: None,
5961 },
5962 )
5963 .await?;
5964 match response {
5965 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5966 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5967 }
5968 }
5969 pub async fn update_template(
5971 &self,
5972 input: crate::tools::ozone::communication::update_template::Input,
5973 ) -> atrium_xrpc::Result<
5974 crate::tools::ozone::communication::update_template::Output,
5975 crate::tools::ozone::communication::update_template::Error,
5976 > {
5977 let response = self
5978 .xrpc
5979 .send_xrpc::<
5980 (),
5981 _,
5982 _,
5983 _,
5984 >(
5985 &atrium_xrpc::XrpcRequest {
5986 method: http::Method::POST,
5987 nsid: crate::tools::ozone::communication::update_template::NSID
5988 .into(),
5989 parameters: None,
5990 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
5991 encoding: Some(String::from("application/json")),
5992 },
5993 )
5994 .await?;
5995 match response {
5996 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
5997 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
5998 }
5999 }
6000}
6001#[cfg(feature = "namespace-toolsozone")]
6002impl<T> tools::ozone::hosting::Service<T>
6003where
6004 T: atrium_xrpc::XrpcClient + Send + Sync,
6005{
6006 #[allow(unused_variables)]
6007 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
6008 Self {
6009 xrpc,
6010 _phantom: core::marker::PhantomData,
6011 }
6012 }
6013 pub async fn get_account_history(
6015 &self,
6016 params: crate::tools::ozone::hosting::get_account_history::Parameters,
6017 ) -> atrium_xrpc::Result<
6018 crate::tools::ozone::hosting::get_account_history::Output,
6019 crate::tools::ozone::hosting::get_account_history::Error,
6020 > {
6021 let response = self
6022 .xrpc
6023 .send_xrpc::<
6024 _,
6025 (),
6026 _,
6027 _,
6028 >(
6029 &atrium_xrpc::XrpcRequest {
6030 method: http::Method::GET,
6031 nsid: crate::tools::ozone::hosting::get_account_history::NSID.into(),
6032 parameters: Some(params),
6033 input: None,
6034 encoding: None,
6035 },
6036 )
6037 .await?;
6038 match response {
6039 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6040 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6041 }
6042 }
6043}
6044#[cfg(feature = "namespace-toolsozone")]
6045impl<T> tools::ozone::moderation::Service<T>
6046where
6047 T: atrium_xrpc::XrpcClient + Send + Sync,
6048{
6049 #[allow(unused_variables)]
6050 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
6051 Self {
6052 xrpc,
6053 _phantom: core::marker::PhantomData,
6054 }
6055 }
6056 pub async fn emit_event(
6058 &self,
6059 input: crate::tools::ozone::moderation::emit_event::Input,
6060 ) -> atrium_xrpc::Result<
6061 crate::tools::ozone::moderation::emit_event::Output,
6062 crate::tools::ozone::moderation::emit_event::Error,
6063 > {
6064 let response = self
6065 .xrpc
6066 .send_xrpc::<
6067 (),
6068 _,
6069 _,
6070 _,
6071 >(
6072 &atrium_xrpc::XrpcRequest {
6073 method: http::Method::POST,
6074 nsid: crate::tools::ozone::moderation::emit_event::NSID.into(),
6075 parameters: None,
6076 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
6077 encoding: Some(String::from("application/json")),
6078 },
6079 )
6080 .await?;
6081 match response {
6082 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6083 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6084 }
6085 }
6086 pub async fn get_event(
6088 &self,
6089 params: crate::tools::ozone::moderation::get_event::Parameters,
6090 ) -> atrium_xrpc::Result<
6091 crate::tools::ozone::moderation::get_event::Output,
6092 crate::tools::ozone::moderation::get_event::Error,
6093 > {
6094 let response = self
6095 .xrpc
6096 .send_xrpc::<
6097 _,
6098 (),
6099 _,
6100 _,
6101 >(
6102 &atrium_xrpc::XrpcRequest {
6103 method: http::Method::GET,
6104 nsid: crate::tools::ozone::moderation::get_event::NSID.into(),
6105 parameters: Some(params),
6106 input: None,
6107 encoding: None,
6108 },
6109 )
6110 .await?;
6111 match response {
6112 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6113 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6114 }
6115 }
6116 pub async fn get_record(
6118 &self,
6119 params: crate::tools::ozone::moderation::get_record::Parameters,
6120 ) -> atrium_xrpc::Result<
6121 crate::tools::ozone::moderation::get_record::Output,
6122 crate::tools::ozone::moderation::get_record::Error,
6123 > {
6124 let response = self
6125 .xrpc
6126 .send_xrpc::<
6127 _,
6128 (),
6129 _,
6130 _,
6131 >(
6132 &atrium_xrpc::XrpcRequest {
6133 method: http::Method::GET,
6134 nsid: crate::tools::ozone::moderation::get_record::NSID.into(),
6135 parameters: Some(params),
6136 input: None,
6137 encoding: None,
6138 },
6139 )
6140 .await?;
6141 match response {
6142 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6143 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6144 }
6145 }
6146 pub async fn get_records(
6148 &self,
6149 params: crate::tools::ozone::moderation::get_records::Parameters,
6150 ) -> atrium_xrpc::Result<
6151 crate::tools::ozone::moderation::get_records::Output,
6152 crate::tools::ozone::moderation::get_records::Error,
6153 > {
6154 let response = self
6155 .xrpc
6156 .send_xrpc::<
6157 _,
6158 (),
6159 _,
6160 _,
6161 >(
6162 &atrium_xrpc::XrpcRequest {
6163 method: http::Method::GET,
6164 nsid: crate::tools::ozone::moderation::get_records::NSID.into(),
6165 parameters: Some(params),
6166 input: None,
6167 encoding: None,
6168 },
6169 )
6170 .await?;
6171 match response {
6172 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6173 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6174 }
6175 }
6176 pub async fn get_repo(
6178 &self,
6179 params: crate::tools::ozone::moderation::get_repo::Parameters,
6180 ) -> atrium_xrpc::Result<
6181 crate::tools::ozone::moderation::get_repo::Output,
6182 crate::tools::ozone::moderation::get_repo::Error,
6183 > {
6184 let response = self
6185 .xrpc
6186 .send_xrpc::<
6187 _,
6188 (),
6189 _,
6190 _,
6191 >(
6192 &atrium_xrpc::XrpcRequest {
6193 method: http::Method::GET,
6194 nsid: crate::tools::ozone::moderation::get_repo::NSID.into(),
6195 parameters: Some(params),
6196 input: None,
6197 encoding: None,
6198 },
6199 )
6200 .await?;
6201 match response {
6202 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6203 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6204 }
6205 }
6206 pub async fn get_reporter_stats(
6208 &self,
6209 params: crate::tools::ozone::moderation::get_reporter_stats::Parameters,
6210 ) -> atrium_xrpc::Result<
6211 crate::tools::ozone::moderation::get_reporter_stats::Output,
6212 crate::tools::ozone::moderation::get_reporter_stats::Error,
6213 > {
6214 let response = self
6215 .xrpc
6216 .send_xrpc::<
6217 _,
6218 (),
6219 _,
6220 _,
6221 >(
6222 &atrium_xrpc::XrpcRequest {
6223 method: http::Method::GET,
6224 nsid: crate::tools::ozone::moderation::get_reporter_stats::NSID
6225 .into(),
6226 parameters: Some(params),
6227 input: None,
6228 encoding: None,
6229 },
6230 )
6231 .await?;
6232 match response {
6233 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6234 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6235 }
6236 }
6237 pub async fn get_repos(
6239 &self,
6240 params: crate::tools::ozone::moderation::get_repos::Parameters,
6241 ) -> atrium_xrpc::Result<
6242 crate::tools::ozone::moderation::get_repos::Output,
6243 crate::tools::ozone::moderation::get_repos::Error,
6244 > {
6245 let response = self
6246 .xrpc
6247 .send_xrpc::<
6248 _,
6249 (),
6250 _,
6251 _,
6252 >(
6253 &atrium_xrpc::XrpcRequest {
6254 method: http::Method::GET,
6255 nsid: crate::tools::ozone::moderation::get_repos::NSID.into(),
6256 parameters: Some(params),
6257 input: None,
6258 encoding: None,
6259 },
6260 )
6261 .await?;
6262 match response {
6263 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6264 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6265 }
6266 }
6267 pub async fn get_subjects(
6269 &self,
6270 params: crate::tools::ozone::moderation::get_subjects::Parameters,
6271 ) -> atrium_xrpc::Result<
6272 crate::tools::ozone::moderation::get_subjects::Output,
6273 crate::tools::ozone::moderation::get_subjects::Error,
6274 > {
6275 let response = self
6276 .xrpc
6277 .send_xrpc::<
6278 _,
6279 (),
6280 _,
6281 _,
6282 >(
6283 &atrium_xrpc::XrpcRequest {
6284 method: http::Method::GET,
6285 nsid: crate::tools::ozone::moderation::get_subjects::NSID.into(),
6286 parameters: Some(params),
6287 input: None,
6288 encoding: None,
6289 },
6290 )
6291 .await?;
6292 match response {
6293 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6294 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6295 }
6296 }
6297 pub async fn query_events(
6299 &self,
6300 params: crate::tools::ozone::moderation::query_events::Parameters,
6301 ) -> atrium_xrpc::Result<
6302 crate::tools::ozone::moderation::query_events::Output,
6303 crate::tools::ozone::moderation::query_events::Error,
6304 > {
6305 let response = self
6306 .xrpc
6307 .send_xrpc::<
6308 _,
6309 (),
6310 _,
6311 _,
6312 >(
6313 &atrium_xrpc::XrpcRequest {
6314 method: http::Method::GET,
6315 nsid: crate::tools::ozone::moderation::query_events::NSID.into(),
6316 parameters: Some(params),
6317 input: None,
6318 encoding: None,
6319 },
6320 )
6321 .await?;
6322 match response {
6323 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6324 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6325 }
6326 }
6327 pub async fn query_statuses(
6329 &self,
6330 params: crate::tools::ozone::moderation::query_statuses::Parameters,
6331 ) -> atrium_xrpc::Result<
6332 crate::tools::ozone::moderation::query_statuses::Output,
6333 crate::tools::ozone::moderation::query_statuses::Error,
6334 > {
6335 let response = self
6336 .xrpc
6337 .send_xrpc::<
6338 _,
6339 (),
6340 _,
6341 _,
6342 >(
6343 &atrium_xrpc::XrpcRequest {
6344 method: http::Method::GET,
6345 nsid: crate::tools::ozone::moderation::query_statuses::NSID.into(),
6346 parameters: Some(params),
6347 input: None,
6348 encoding: None,
6349 },
6350 )
6351 .await?;
6352 match response {
6353 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6354 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6355 }
6356 }
6357 pub async fn search_repos(
6359 &self,
6360 params: crate::tools::ozone::moderation::search_repos::Parameters,
6361 ) -> atrium_xrpc::Result<
6362 crate::tools::ozone::moderation::search_repos::Output,
6363 crate::tools::ozone::moderation::search_repos::Error,
6364 > {
6365 let response = self
6366 .xrpc
6367 .send_xrpc::<
6368 _,
6369 (),
6370 _,
6371 _,
6372 >(
6373 &atrium_xrpc::XrpcRequest {
6374 method: http::Method::GET,
6375 nsid: crate::tools::ozone::moderation::search_repos::NSID.into(),
6376 parameters: Some(params),
6377 input: None,
6378 encoding: None,
6379 },
6380 )
6381 .await?;
6382 match response {
6383 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6384 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6385 }
6386 }
6387}
6388#[cfg(feature = "namespace-toolsozone")]
6389impl<T> tools::ozone::server::Service<T>
6390where
6391 T: atrium_xrpc::XrpcClient + Send + Sync,
6392{
6393 #[allow(unused_variables)]
6394 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
6395 Self {
6396 xrpc,
6397 _phantom: core::marker::PhantomData,
6398 }
6399 }
6400 pub async fn get_config(
6402 &self,
6403 ) -> atrium_xrpc::Result<
6404 crate::tools::ozone::server::get_config::Output,
6405 crate::tools::ozone::server::get_config::Error,
6406 > {
6407 let response = self
6408 .xrpc
6409 .send_xrpc::<
6410 (),
6411 (),
6412 _,
6413 _,
6414 >(
6415 &atrium_xrpc::XrpcRequest {
6416 method: http::Method::GET,
6417 nsid: crate::tools::ozone::server::get_config::NSID.into(),
6418 parameters: None,
6419 input: None,
6420 encoding: None,
6421 },
6422 )
6423 .await?;
6424 match response {
6425 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6426 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6427 }
6428 }
6429}
6430#[cfg(feature = "namespace-toolsozone")]
6431impl<T> tools::ozone::set::Service<T>
6432where
6433 T: atrium_xrpc::XrpcClient + Send + Sync,
6434{
6435 #[allow(unused_variables)]
6436 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
6437 Self {
6438 xrpc,
6439 _phantom: core::marker::PhantomData,
6440 }
6441 }
6442 pub async fn add_values(
6444 &self,
6445 input: crate::tools::ozone::set::add_values::Input,
6446 ) -> atrium_xrpc::Result<(), crate::tools::ozone::set::add_values::Error> {
6447 let response = self
6448 .xrpc
6449 .send_xrpc::<
6450 (),
6451 _,
6452 (),
6453 _,
6454 >(
6455 &atrium_xrpc::XrpcRequest {
6456 method: http::Method::POST,
6457 nsid: crate::tools::ozone::set::add_values::NSID.into(),
6458 parameters: None,
6459 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
6460 encoding: Some(String::from("application/json")),
6461 },
6462 )
6463 .await?;
6464 match response {
6465 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
6466 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6467 }
6468 }
6469 pub async fn delete_set(
6471 &self,
6472 input: crate::tools::ozone::set::delete_set::Input,
6473 ) -> atrium_xrpc::Result<
6474 crate::tools::ozone::set::delete_set::Output,
6475 crate::tools::ozone::set::delete_set::Error,
6476 > {
6477 let response = self
6478 .xrpc
6479 .send_xrpc::<
6480 (),
6481 _,
6482 _,
6483 _,
6484 >(
6485 &atrium_xrpc::XrpcRequest {
6486 method: http::Method::POST,
6487 nsid: crate::tools::ozone::set::delete_set::NSID.into(),
6488 parameters: None,
6489 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
6490 encoding: Some(String::from("application/json")),
6491 },
6492 )
6493 .await?;
6494 match response {
6495 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6496 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6497 }
6498 }
6499 pub async fn delete_values(
6501 &self,
6502 input: crate::tools::ozone::set::delete_values::Input,
6503 ) -> atrium_xrpc::Result<(), crate::tools::ozone::set::delete_values::Error> {
6504 let response = self
6505 .xrpc
6506 .send_xrpc::<
6507 (),
6508 _,
6509 (),
6510 _,
6511 >(
6512 &atrium_xrpc::XrpcRequest {
6513 method: http::Method::POST,
6514 nsid: crate::tools::ozone::set::delete_values::NSID.into(),
6515 parameters: None,
6516 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
6517 encoding: Some(String::from("application/json")),
6518 },
6519 )
6520 .await?;
6521 match response {
6522 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
6523 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6524 }
6525 }
6526 pub async fn get_values(
6528 &self,
6529 params: crate::tools::ozone::set::get_values::Parameters,
6530 ) -> atrium_xrpc::Result<
6531 crate::tools::ozone::set::get_values::Output,
6532 crate::tools::ozone::set::get_values::Error,
6533 > {
6534 let response = self
6535 .xrpc
6536 .send_xrpc::<
6537 _,
6538 (),
6539 _,
6540 _,
6541 >(
6542 &atrium_xrpc::XrpcRequest {
6543 method: http::Method::GET,
6544 nsid: crate::tools::ozone::set::get_values::NSID.into(),
6545 parameters: Some(params),
6546 input: None,
6547 encoding: None,
6548 },
6549 )
6550 .await?;
6551 match response {
6552 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6553 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6554 }
6555 }
6556 pub async fn query_sets(
6558 &self,
6559 params: crate::tools::ozone::set::query_sets::Parameters,
6560 ) -> atrium_xrpc::Result<
6561 crate::tools::ozone::set::query_sets::Output,
6562 crate::tools::ozone::set::query_sets::Error,
6563 > {
6564 let response = self
6565 .xrpc
6566 .send_xrpc::<
6567 _,
6568 (),
6569 _,
6570 _,
6571 >(
6572 &atrium_xrpc::XrpcRequest {
6573 method: http::Method::GET,
6574 nsid: crate::tools::ozone::set::query_sets::NSID.into(),
6575 parameters: Some(params),
6576 input: None,
6577 encoding: None,
6578 },
6579 )
6580 .await?;
6581 match response {
6582 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6583 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6584 }
6585 }
6586 pub async fn upsert_set(
6588 &self,
6589 input: crate::tools::ozone::set::upsert_set::Input,
6590 ) -> atrium_xrpc::Result<
6591 crate::tools::ozone::set::upsert_set::Output,
6592 crate::tools::ozone::set::upsert_set::Error,
6593 > {
6594 let response = self
6595 .xrpc
6596 .send_xrpc::<
6597 (),
6598 _,
6599 _,
6600 _,
6601 >(
6602 &atrium_xrpc::XrpcRequest {
6603 method: http::Method::POST,
6604 nsid: crate::tools::ozone::set::upsert_set::NSID.into(),
6605 parameters: None,
6606 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
6607 encoding: Some(String::from("application/json")),
6608 },
6609 )
6610 .await?;
6611 match response {
6612 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6613 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6614 }
6615 }
6616}
6617#[cfg(feature = "namespace-toolsozone")]
6618impl<T> tools::ozone::setting::Service<T>
6619where
6620 T: atrium_xrpc::XrpcClient + Send + Sync,
6621{
6622 #[allow(unused_variables)]
6623 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
6624 Self {
6625 xrpc,
6626 _phantom: core::marker::PhantomData,
6627 }
6628 }
6629 pub async fn list_options(
6631 &self,
6632 params: crate::tools::ozone::setting::list_options::Parameters,
6633 ) -> atrium_xrpc::Result<
6634 crate::tools::ozone::setting::list_options::Output,
6635 crate::tools::ozone::setting::list_options::Error,
6636 > {
6637 let response = self
6638 .xrpc
6639 .send_xrpc::<
6640 _,
6641 (),
6642 _,
6643 _,
6644 >(
6645 &atrium_xrpc::XrpcRequest {
6646 method: http::Method::GET,
6647 nsid: crate::tools::ozone::setting::list_options::NSID.into(),
6648 parameters: Some(params),
6649 input: None,
6650 encoding: None,
6651 },
6652 )
6653 .await?;
6654 match response {
6655 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6656 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6657 }
6658 }
6659 pub async fn remove_options(
6661 &self,
6662 input: crate::tools::ozone::setting::remove_options::Input,
6663 ) -> atrium_xrpc::Result<
6664 crate::tools::ozone::setting::remove_options::Output,
6665 crate::tools::ozone::setting::remove_options::Error,
6666 > {
6667 let response = self
6668 .xrpc
6669 .send_xrpc::<
6670 (),
6671 _,
6672 _,
6673 _,
6674 >(
6675 &atrium_xrpc::XrpcRequest {
6676 method: http::Method::POST,
6677 nsid: crate::tools::ozone::setting::remove_options::NSID.into(),
6678 parameters: None,
6679 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
6680 encoding: Some(String::from("application/json")),
6681 },
6682 )
6683 .await?;
6684 match response {
6685 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6686 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6687 }
6688 }
6689 pub async fn upsert_option(
6691 &self,
6692 input: crate::tools::ozone::setting::upsert_option::Input,
6693 ) -> atrium_xrpc::Result<
6694 crate::tools::ozone::setting::upsert_option::Output,
6695 crate::tools::ozone::setting::upsert_option::Error,
6696 > {
6697 let response = self
6698 .xrpc
6699 .send_xrpc::<
6700 (),
6701 _,
6702 _,
6703 _,
6704 >(
6705 &atrium_xrpc::XrpcRequest {
6706 method: http::Method::POST,
6707 nsid: crate::tools::ozone::setting::upsert_option::NSID.into(),
6708 parameters: None,
6709 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
6710 encoding: Some(String::from("application/json")),
6711 },
6712 )
6713 .await?;
6714 match response {
6715 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6716 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6717 }
6718 }
6719}
6720#[cfg(feature = "namespace-toolsozone")]
6721impl<T> tools::ozone::signature::Service<T>
6722where
6723 T: atrium_xrpc::XrpcClient + Send + Sync,
6724{
6725 #[allow(unused_variables)]
6726 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
6727 Self {
6728 xrpc,
6729 _phantom: core::marker::PhantomData,
6730 }
6731 }
6732 pub async fn find_correlation(
6734 &self,
6735 params: crate::tools::ozone::signature::find_correlation::Parameters,
6736 ) -> atrium_xrpc::Result<
6737 crate::tools::ozone::signature::find_correlation::Output,
6738 crate::tools::ozone::signature::find_correlation::Error,
6739 > {
6740 let response = self
6741 .xrpc
6742 .send_xrpc::<
6743 _,
6744 (),
6745 _,
6746 _,
6747 >(
6748 &atrium_xrpc::XrpcRequest {
6749 method: http::Method::GET,
6750 nsid: crate::tools::ozone::signature::find_correlation::NSID.into(),
6751 parameters: Some(params),
6752 input: None,
6753 encoding: None,
6754 },
6755 )
6756 .await?;
6757 match response {
6758 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6759 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6760 }
6761 }
6762 pub async fn find_related_accounts(
6764 &self,
6765 params: crate::tools::ozone::signature::find_related_accounts::Parameters,
6766 ) -> atrium_xrpc::Result<
6767 crate::tools::ozone::signature::find_related_accounts::Output,
6768 crate::tools::ozone::signature::find_related_accounts::Error,
6769 > {
6770 let response = self
6771 .xrpc
6772 .send_xrpc::<
6773 _,
6774 (),
6775 _,
6776 _,
6777 >(
6778 &atrium_xrpc::XrpcRequest {
6779 method: http::Method::GET,
6780 nsid: crate::tools::ozone::signature::find_related_accounts::NSID
6781 .into(),
6782 parameters: Some(params),
6783 input: None,
6784 encoding: None,
6785 },
6786 )
6787 .await?;
6788 match response {
6789 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6790 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6791 }
6792 }
6793 pub async fn search_accounts(
6795 &self,
6796 params: crate::tools::ozone::signature::search_accounts::Parameters,
6797 ) -> atrium_xrpc::Result<
6798 crate::tools::ozone::signature::search_accounts::Output,
6799 crate::tools::ozone::signature::search_accounts::Error,
6800 > {
6801 let response = self
6802 .xrpc
6803 .send_xrpc::<
6804 _,
6805 (),
6806 _,
6807 _,
6808 >(
6809 &atrium_xrpc::XrpcRequest {
6810 method: http::Method::GET,
6811 nsid: crate::tools::ozone::signature::search_accounts::NSID.into(),
6812 parameters: Some(params),
6813 input: None,
6814 encoding: None,
6815 },
6816 )
6817 .await?;
6818 match response {
6819 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6820 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6821 }
6822 }
6823}
6824#[cfg(feature = "namespace-toolsozone")]
6825impl<T> tools::ozone::team::Service<T>
6826where
6827 T: atrium_xrpc::XrpcClient + Send + Sync,
6828{
6829 #[allow(unused_variables)]
6830 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
6831 Self {
6832 xrpc,
6833 _phantom: core::marker::PhantomData,
6834 }
6835 }
6836 pub async fn add_member(
6838 &self,
6839 input: crate::tools::ozone::team::add_member::Input,
6840 ) -> atrium_xrpc::Result<
6841 crate::tools::ozone::team::add_member::Output,
6842 crate::tools::ozone::team::add_member::Error,
6843 > {
6844 let response = self
6845 .xrpc
6846 .send_xrpc::<
6847 (),
6848 _,
6849 _,
6850 _,
6851 >(
6852 &atrium_xrpc::XrpcRequest {
6853 method: http::Method::POST,
6854 nsid: crate::tools::ozone::team::add_member::NSID.into(),
6855 parameters: None,
6856 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
6857 encoding: Some(String::from("application/json")),
6858 },
6859 )
6860 .await?;
6861 match response {
6862 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6863 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6864 }
6865 }
6866 pub async fn delete_member(
6868 &self,
6869 input: crate::tools::ozone::team::delete_member::Input,
6870 ) -> atrium_xrpc::Result<(), crate::tools::ozone::team::delete_member::Error> {
6871 let response = self
6872 .xrpc
6873 .send_xrpc::<
6874 (),
6875 _,
6876 (),
6877 _,
6878 >(
6879 &atrium_xrpc::XrpcRequest {
6880 method: http::Method::POST,
6881 nsid: crate::tools::ozone::team::delete_member::NSID.into(),
6882 parameters: None,
6883 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
6884 encoding: Some(String::from("application/json")),
6885 },
6886 )
6887 .await?;
6888 match response {
6889 atrium_xrpc::OutputDataOrBytes::Bytes(_) => Ok(()),
6890 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6891 }
6892 }
6893 pub async fn list_members(
6895 &self,
6896 params: crate::tools::ozone::team::list_members::Parameters,
6897 ) -> atrium_xrpc::Result<
6898 crate::tools::ozone::team::list_members::Output,
6899 crate::tools::ozone::team::list_members::Error,
6900 > {
6901 let response = self
6902 .xrpc
6903 .send_xrpc::<
6904 _,
6905 (),
6906 _,
6907 _,
6908 >(
6909 &atrium_xrpc::XrpcRequest {
6910 method: http::Method::GET,
6911 nsid: crate::tools::ozone::team::list_members::NSID.into(),
6912 parameters: Some(params),
6913 input: None,
6914 encoding: None,
6915 },
6916 )
6917 .await?;
6918 match response {
6919 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6920 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6921 }
6922 }
6923 pub async fn update_member(
6925 &self,
6926 input: crate::tools::ozone::team::update_member::Input,
6927 ) -> atrium_xrpc::Result<
6928 crate::tools::ozone::team::update_member::Output,
6929 crate::tools::ozone::team::update_member::Error,
6930 > {
6931 let response = self
6932 .xrpc
6933 .send_xrpc::<
6934 (),
6935 _,
6936 _,
6937 _,
6938 >(
6939 &atrium_xrpc::XrpcRequest {
6940 method: http::Method::POST,
6941 nsid: crate::tools::ozone::team::update_member::NSID.into(),
6942 parameters: None,
6943 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
6944 encoding: Some(String::from("application/json")),
6945 },
6946 )
6947 .await?;
6948 match response {
6949 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6950 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6951 }
6952 }
6953}
6954#[cfg(feature = "namespace-toolsozone")]
6955impl<T> tools::ozone::verification::Service<T>
6956where
6957 T: atrium_xrpc::XrpcClient + Send + Sync,
6958{
6959 #[allow(unused_variables)]
6960 pub(crate) fn new(xrpc: std::sync::Arc<T>) -> Self {
6961 Self {
6962 xrpc,
6963 _phantom: core::marker::PhantomData,
6964 }
6965 }
6966 pub async fn grant_verifications(
6968 &self,
6969 input: crate::tools::ozone::verification::grant_verifications::Input,
6970 ) -> atrium_xrpc::Result<
6971 crate::tools::ozone::verification::grant_verifications::Output,
6972 crate::tools::ozone::verification::grant_verifications::Error,
6973 > {
6974 let response = self
6975 .xrpc
6976 .send_xrpc::<
6977 (),
6978 _,
6979 _,
6980 _,
6981 >(
6982 &atrium_xrpc::XrpcRequest {
6983 method: http::Method::POST,
6984 nsid: crate::tools::ozone::verification::grant_verifications::NSID
6985 .into(),
6986 parameters: None,
6987 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
6988 encoding: Some(String::from("application/json")),
6989 },
6990 )
6991 .await?;
6992 match response {
6993 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
6994 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
6995 }
6996 }
6997 pub async fn list_verifications(
6999 &self,
7000 params: crate::tools::ozone::verification::list_verifications::Parameters,
7001 ) -> atrium_xrpc::Result<
7002 crate::tools::ozone::verification::list_verifications::Output,
7003 crate::tools::ozone::verification::list_verifications::Error,
7004 > {
7005 let response = self
7006 .xrpc
7007 .send_xrpc::<
7008 _,
7009 (),
7010 _,
7011 _,
7012 >(
7013 &atrium_xrpc::XrpcRequest {
7014 method: http::Method::GET,
7015 nsid: crate::tools::ozone::verification::list_verifications::NSID
7016 .into(),
7017 parameters: Some(params),
7018 input: None,
7019 encoding: None,
7020 },
7021 )
7022 .await?;
7023 match response {
7024 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
7025 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
7026 }
7027 }
7028 pub async fn revoke_verifications(
7030 &self,
7031 input: crate::tools::ozone::verification::revoke_verifications::Input,
7032 ) -> atrium_xrpc::Result<
7033 crate::tools::ozone::verification::revoke_verifications::Output,
7034 crate::tools::ozone::verification::revoke_verifications::Error,
7035 > {
7036 let response = self
7037 .xrpc
7038 .send_xrpc::<
7039 (),
7040 _,
7041 _,
7042 _,
7043 >(
7044 &atrium_xrpc::XrpcRequest {
7045 method: http::Method::POST,
7046 nsid: crate::tools::ozone::verification::revoke_verifications::NSID
7047 .into(),
7048 parameters: None,
7049 input: Some(atrium_xrpc::InputDataOrBytes::Data(input)),
7050 encoding: Some(String::from("application/json")),
7051 },
7052 )
7053 .await?;
7054 match response {
7055 atrium_xrpc::OutputDataOrBytes::Data(data) => Ok(data),
7056 _ => Err(atrium_xrpc::Error::UnexpectedResponseType),
7057 }
7058 }
7059}