Masked email: Fastmail's Masked Email API, MaskedEmail/get and /set (ME-1, ME-7a, ME-16)
Advertised as https://www.fastmail.com/dev/maskedemail in the session and on every account that may hold masks. Masks created through it start pending unless the create sets a state; pending can't be set again once left; state and the other mutable fields map onto the same records the x: API uses.
This commit is contained in:
@@ -98,6 +98,7 @@ pub enum GetResponseMethod {
|
||||
ParticipantIdentity(GetResponse<ParticipantIdentity>),
|
||||
ShareNotification(GetResponse<ShareNotification>),
|
||||
Registry(GetResponse<Registry>),
|
||||
MaskedEmail(GetResponse<crate::object::fastmail_masked_email::FastmailMaskedEmail>),
|
||||
}
|
||||
|
||||
#[derive(Debug, serde::Serialize)]
|
||||
@@ -119,6 +120,7 @@ pub enum SetResponseMethod {
|
||||
CalendarEventNotification(Box<SetResponse<CalendarEventNotification>>),
|
||||
ParticipantIdentity(Box<SetResponse<ParticipantIdentity>>),
|
||||
Registry(Box<SetResponse<Registry>>),
|
||||
MaskedEmail(Box<SetResponse<crate::object::fastmail_masked_email::FastmailMaskedEmail>>),
|
||||
}
|
||||
|
||||
#[derive(Debug, serde::Serialize)]
|
||||
@@ -265,6 +267,19 @@ impl<'x> From<GetResponse<Sieve>> for ResponseMethod<'x> {
|
||||
}
|
||||
}
|
||||
|
||||
// inbuxa: Fastmail's MaskedEmail
|
||||
impl<'x> From<GetResponse<crate::object::fastmail_masked_email::FastmailMaskedEmail>> for ResponseMethod<'x> {
|
||||
fn from(value: GetResponse<crate::object::fastmail_masked_email::FastmailMaskedEmail>) -> Self {
|
||||
ResponseMethod::Get(GetResponseMethod::MaskedEmail(value))
|
||||
}
|
||||
}
|
||||
|
||||
impl<'x> From<SetResponse<crate::object::fastmail_masked_email::FastmailMaskedEmail>> for ResponseMethod<'x> {
|
||||
fn from(value: SetResponse<crate::object::fastmail_masked_email::FastmailMaskedEmail>) -> Self {
|
||||
ResponseMethod::Set(SetResponseMethod::MaskedEmail(Box::new(value)))
|
||||
}
|
||||
}
|
||||
|
||||
impl<'x> From<GetResponse<VacationResponse>> for ResponseMethod<'x> {
|
||||
fn from(value: GetResponse<VacationResponse>) -> Self {
|
||||
ResponseMethod::Get(GetResponseMethod::VacationResponse(value))
|
||||
|
||||
Reference in New Issue
Block a user