1// @generated by jacquard-lexicon. DO NOT EDIT.
2//
3// Lexicon: com.atproto.repo.describeRepo
4//
5// This file was automatically generated from Lexicon schemas.
6// Any manual changes will be overwritten on the next regeneration.
7
8#[derive(
9 serde::Serialize,
10 serde::Deserialize,
11 Debug,
12 Clone,
13 PartialEq,
14 Eq,
15 bon::Builder
16)]
17#[builder(start_fn = new)]
18#[serde(rename_all = "camelCase")]
19pub struct DescribeRepo<'a> {
20 #[serde(borrow)]
21 pub repo: jacquard_common::types::ident::AtIdentifier<'a>,
22}
23
24impl jacquard_common::IntoStatic for DescribeRepo<'_> {
25 type Output = DescribeRepo<'static>;
26 fn into_static(self) -> Self::Output {
27 DescribeRepo {
28 repo: self.repo.into_static(),
29 }
30 }
31}
32
33#[jacquard_derive::lexicon]
34#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
35#[serde(rename_all = "camelCase")]
36pub struct DescribeRepoOutput<'a> {
37 ///List of all the collections (NSIDs) for which this repo contains at least one record.
38 #[serde(borrow)]
39 pub collections: Vec<jacquard_common::types::string::Nsid<'a>>,
40 #[serde(borrow)]
41 pub did: jacquard_common::types::string::Did<'a>,
42 ///The complete DID document for this account.
43 #[serde(borrow)]
44 pub did_doc: jacquard_common::types::value::Data<'a>,
45 #[serde(borrow)]
46 pub handle: jacquard_common::types::string::Handle<'a>,
47 ///Indicates if handle is currently valid (resolves bi-directionally)
48 pub handle_is_correct: bool,
49}
50
51impl jacquard_common::IntoStatic for DescribeRepoOutput<'_> {
52 type Output = DescribeRepoOutput<'static>;
53 fn into_static(self) -> Self::Output {
54 DescribeRepoOutput {
55 collections: self.collections.into_static(),
56 did: self.did.into_static(),
57 did_doc: self.did_doc.into_static(),
58 handle: self.handle.into_static(),
59 handle_is_correct: self.handle_is_correct.into_static(),
60 extra_data: self.extra_data.into_static(),
61 }
62 }
63}
64
65impl jacquard_common::types::xrpc::XrpcRequest for DescribeRepo<'_> {
66 const NSID: &'static str = "com.atproto.repo.describeRepo";
67 const METHOD: jacquard_common::types::xrpc::XrpcMethod = jacquard_common::types::xrpc::XrpcMethod::Query;
68 const OUTPUT_ENCODING: &'static str = "application/json";
69 type Output<'de> = DescribeRepoOutput<'de>;
70 type Err<'de> = jacquard_common::types::xrpc::GenericError<'de>;
71}