use thiserror::Error;
#[derive(Debug, Error)]
pub enum CollabError {
#[error("not a member of team {team_id}")]
NotMember { team_id: String },
#[error("invite not found or expired")]
InviteNotFound,
#[error("pubkey mismatch in invite confirmation")]
PubkeyMismatch,
#[error("http error {status}: {body}")]
Http { status: u16, body: String },
#[error("serialization error: {0}")]
Serde(#[from] serde_json::Error),
#[error("server unreachable: {0}")]
Unreachable(String),
#[error("recovery key reconstruction failed: {0}")]
RecoveryFailed(String),
}