pub struct Notice {
pub hat_id: String,
pub urgency: Urgency,
pub title: String,
pub generic_title: String,
pub body: String,
pub detail: Option<String>,
pub url: String,
pub tag: String,
}Expand description
A notification for the owner’s devices, before the hat’s policy is applied (kernel spec §6; plan 10b decision 1). The modules that own a trigger fill it in (ACP core §10, gateway §7); delivery applies the policy, so no caller re-implements it:
- a muted hat: nothing is sent;
generic_title:generic_titlereplacestitle, andbodyis dropped;details:detail, when there is one, replacesbody.
Fields§
§hat_id: StringThe hat whose policy applies; '' (a session from before hats) has
the default.
urgency: Urgency§title: StringThe session title, or the connection’s label.
generic_title: StringThe title with nothing of the session’s own: “Session needs your answer”.
body: String§detail: Option<String>More than the default shows (the agent’s question title), only
under a hat with details.
url: StringThe same-origin path the notification opens: /sessions/<id>, or
/mcp for the gateway’s. Never a URL.
tag: StringOne notification per tag on a device: a newer one replaces it.
Trait Implementations§
impl Eq for Notice
impl StructuralPartialEq for Notice
Auto Trait Implementations§
impl Freeze for Notice
impl RefUnwindSafe for Notice
impl Send for Notice
impl Sync for Notice
impl Unpin for Notice
impl UnsafeUnpin for Notice
impl UnwindSafe for Notice
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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