nominal-api 0.1239.0

API bindings for the Nominal platform
Documentation
/// A permission definition for MediaMTX authentication
#[derive(
    Debug,
    Clone,
    conjure_object::serde::Serialize,
    conjure_object::serde::Deserialize,
    PartialEq,
    Eq,
    PartialOrd,
    Ord,
    Hash
)]
#[serde(crate = "conjure_object::serde")]
#[conjure_object::private::staged_builder::staged_builder]
#[builder(crate = conjure_object::private::staged_builder, update, inline)]
pub struct MediaMtxPermission {
    #[builder(into)]
    #[serde(rename = "action")]
    action: String,
    #[builder(into)]
    #[serde(rename = "path")]
    path: String,
}
impl MediaMtxPermission {
    /// Constructs a new instance of the type.
    #[inline]
    pub fn new(action: impl Into<String>, path: impl Into<String>) -> Self {
        Self::builder().action(action).path(path).build()
    }
    /// The action permitted. Allowed values are publish, read, playback, api, metrics, pprof.
    #[inline]
    pub fn action(&self) -> &str {
        &*self.action
    }
    /// The stream path this permission applies to (e.g., "stream/test")
    #[inline]
    pub fn path(&self) -> &str {
        &*self.path
    }
}