Skip to main content

jacquard_api/com_atproto/sync/
notify_of_update.rs

1// @generated by jacquard-lexicon. DO NOT EDIT.
2//
3// Lexicon: com.atproto.sync.notifyOfUpdate
4//
5// This file was automatically generated from Lexicon schemas.
6// Any manual changes will be overwritten on the next regeneration.
7
8#[allow(unused_imports)]
9use alloc::collections::BTreeMap;
10
11#[allow(unused_imports)]
12use core::marker::PhantomData;
13use jacquard_common::CowStr;
14use jacquard_derive::{IntoStatic, lexicon};
15use serde::{Serialize, Deserialize};
16
17#[lexicon]
18#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
19#[serde(rename_all = "camelCase")]
20pub struct NotifyOfUpdate<'a> {
21    ///Hostname of the current service (usually a PDS) that is notifying of update.
22    #[serde(borrow)]
23    pub hostname: CowStr<'a>,
24}
25
26/// Response type for com.atproto.sync.notifyOfUpdate
27pub struct NotifyOfUpdateResponse;
28impl jacquard_common::xrpc::XrpcResp for NotifyOfUpdateResponse {
29    const NSID: &'static str = "com.atproto.sync.notifyOfUpdate";
30    const ENCODING: &'static str = "application/json";
31    type Output<'de> = ();
32    type Err<'de> = jacquard_common::xrpc::GenericError<'de>;
33}
34
35impl<'a> jacquard_common::xrpc::XrpcRequest for NotifyOfUpdate<'a> {
36    const NSID: &'static str = "com.atproto.sync.notifyOfUpdate";
37    const METHOD: jacquard_common::xrpc::XrpcMethod = jacquard_common::xrpc::XrpcMethod::Procedure(
38        "application/json",
39    );
40    type Response = NotifyOfUpdateResponse;
41}
42
43/// Endpoint type for com.atproto.sync.notifyOfUpdate
44pub struct NotifyOfUpdateRequest;
45impl jacquard_common::xrpc::XrpcEndpoint for NotifyOfUpdateRequest {
46    const PATH: &'static str = "/xrpc/com.atproto.sync.notifyOfUpdate";
47    const METHOD: jacquard_common::xrpc::XrpcMethod = jacquard_common::xrpc::XrpcMethod::Procedure(
48        "application/json",
49    );
50    type Request<'de> = NotifyOfUpdate<'de>;
51    type Response = NotifyOfUpdateResponse;
52}