atrium_api/com/atproto/server/
delete_account.rs1pub const NSID: &str = "com.atproto.server.deleteAccount";
4#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
5#[serde(rename_all = "camelCase")]
6pub struct InputData {
7 pub did: crate::types::string::Did,
8 pub password: String,
9 pub token: String,
10}
11pub type Input = crate::types::Object<InputData>;
12#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
13#[serde(tag = "error", content = "message")]
14pub enum Error {
15 ExpiredToken(Option<String>),
16 InvalidToken(Option<String>),
17}
18impl std::fmt::Display for Error {
19 fn fmt(&self, _f: &mut std::fmt::Formatter) -> std::fmt::Result {
20 match self {
21 Error::ExpiredToken(msg) => {
22 write!(_f, "ExpiredToken")?;
23 if let Some(msg) = msg {
24 write!(_f, ": {msg}")?;
25 }
26 }
27 Error::InvalidToken(msg) => {
28 write!(_f, "InvalidToken")?;
29 if let Some(msg) = msg {
30 write!(_f, ": {msg}")?;
31 }
32 }
33 }
34 Ok(())
35 }
36}