Struct hubcaps::hooks::HookCreateOptionsBuilder
source · pub struct HookCreateOptionsBuilder(_);
Implementations
sourceimpl HookCreateOptionsBuilder
impl HookCreateOptionsBuilder
pub fn active(&mut self, active: bool) -> &mut Self
sourcepub fn events<E>(&mut self, events: Vec<E>) -> &mut Selfwhere
E: Into<String>,
pub fn events<E>(&mut self, events: Vec<E>) -> &mut Selfwhere
E: Into<String>,
a list of github events this hook should receive deliveries for the default is “push”. for a full list, see the Github api docs
sourcepub fn url<U>(&mut self, url: U) -> &mut Selfwhere
U: Into<String>,
pub fn url<U>(&mut self, url: U) -> &mut Selfwhere
U: Into<String>,
web hooks must have an associated url
sourcepub fn content_type(&mut self, content_type: WebHookContentType) -> &mut Self
pub fn content_type(&mut self, content_type: WebHookContentType) -> &mut Self
web hooks can optionally specify a content_type of “form” or “json” which indicates the type of payload they will expect to receive
sourcepub fn secret<S>(&mut self, sec: S) -> &mut Selfwhere
S: Into<String>,
pub fn secret<S>(&mut self, sec: S) -> &mut Selfwhere
S: Into<String>,
web hooks can optionally provide a secret used to sign deliveries to identify that their source was indeed github
pub fn config_str_entry<K, V>(&mut self, k: K, v: V) -> &mut Selfwhere
K: Into<String>,
V: Into<String>,
pub fn config_entry<N>(&mut self, name: N, value: Value) -> &mut Selfwhere
N: Into<String>,
pub fn build(&self) -> HookCreateOptions
Auto Trait Implementations
impl RefUnwindSafe for HookCreateOptionsBuilder
impl Send for HookCreateOptionsBuilder
impl Sync for HookCreateOptionsBuilder
impl Unpin for HookCreateOptionsBuilder
impl UnwindSafe for HookCreateOptionsBuilder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more