pub struct MessagingPluginResponse {
pub ok: bool,
pub error: Option<String>,
pub messages: Option<Vec<FetchedMessage>>,
pub draft_id: Option<String>,
pub state: Option<DraftState>,
pub address: Option<String>,
pub provider: Option<String>,
pub capabilities: Option<Vec<String>>,
}Expand description
Response sent from a messaging plugin to TA over stdout.
One JSON line per response. Always contains ok; on success contains
the operation result fields; on failure contains error.
Fields§
§ok: boolWhether the operation succeeded.
error: Option<String>Human-readable error message (only set when ok=false).
messages: Option<Vec<FetchedMessage>>Fetched messages (only for fetch op).
draft_id: Option<String>Native draft ID assigned by the provider (only for create_draft op).
state: Option<DraftState>Current state of a draft (only for draft_status op).
address: Option<String>Connected email address (only for health op).
provider: Option<String>Provider name reported by the plugin (only for health op).
capabilities: Option<Vec<String>>Capabilities declared by the plugin (only for capabilities op).
Implementations§
Trait Implementations§
Source§impl Debug for MessagingPluginResponse
impl Debug for MessagingPluginResponse
Source§impl<'de> Deserialize<'de> for MessagingPluginResponse
impl<'de> Deserialize<'de> for MessagingPluginResponse
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for MessagingPluginResponse
impl RefUnwindSafe for MessagingPluginResponse
impl Send for MessagingPluginResponse
impl Sync for MessagingPluginResponse
impl Unpin for MessagingPluginResponse
impl UnsafeUnpin for MessagingPluginResponse
impl UnwindSafe for MessagingPluginResponse
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more