pub struct PatternMetadata {
pub provider_id: Cow<'static, str>,
pub retrieval_url_template: Cow<'static, str>,
pub default_expiry_days: Option<u32>,
pub scopes_hint: Vec<Cow<'static, str>>,
}Expand description
Optional descriptive metadata for a pattern. Consumed by the secret
store’s pattern_id inheritance (epic phase P2.4) and by the UI.
String fields are Cow<'static, str> so both built-in patterns
(which carry &'static str literals via Cow::Borrowed) and
user-loaded patterns (which carry owned Strings deserialised from
~/.devboy/secrets/patterns.d/*.toml) can populate them without
either side leaking memory or leaning on Box::leak.
Fields§
§provider_id: Cow<'static, str>Stable provider identifier, lowercase ASCII ("github",
"gitlab", "openai", …). Used as the second segment in
suggested ADR-020 paths and as the routing key for liveness
probes.
retrieval_url_template: Cow<'static, str>URL template the user opens to obtain a fresh value. May
contain {var} placeholders the UI substitutes; if it has no
placeholders, the UI opens it verbatim.
default_expiry_days: Option<u32>Default rotation cadence in days. Drives doctor’s default
reminder when the per-secret entry doesn’t override it.
scopes_hint: Vec<Cow<'static, str>>Hint on the API scopes this token is typically created with. Surfaced in the metadata card; does not validate.
Trait Implementations§
Source§impl Clone for PatternMetadata
impl Clone for PatternMetadata
Source§fn clone(&self) -> PatternMetadata
fn clone(&self) -> PatternMetadata
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PatternMetadata
impl Debug for PatternMetadata
impl Eq for PatternMetadata
Source§impl PartialEq for PatternMetadata
impl PartialEq for PatternMetadata
Source§fn eq(&self, other: &PatternMetadata) -> bool
fn eq(&self, other: &PatternMetadata) -> bool
self and other values to be equal, and is used by ==.impl StructuralPartialEq for PatternMetadata
Auto Trait Implementations§
impl Freeze for PatternMetadata
impl RefUnwindSafe for PatternMetadata
impl Send for PatternMetadata
impl Sync for PatternMetadata
impl Unpin for PatternMetadata
impl UnsafeUnpin for PatternMetadata
impl UnwindSafe for PatternMetadata
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.