pub struct Webhooks { /* private fields */ }Expand description
Webhook endpoints and their delivery log.
Implementations§
Source§impl Webhooks
impl Webhooks
Sourcepub fn list<T: DeserializeOwned>(&self) -> Result<T, Error>
pub fn list<T: DeserializeOwned>(&self) -> Result<T, Error>
List your webhook endpoints.
Sourcepub fn create(&self, webhook: &NewWebhook) -> Result<Value, Error>
pub fn create(&self, webhook: &NewWebhook) -> Result<Value, Error>
Register a webhook endpoint for a set of events.
Sourcepub fn delete(&self, id: impl Display) -> Result<Value, Error>
pub fn delete(&self, id: impl Display) -> Result<Value, Error>
Delete a webhook endpoint by id.
Sourcepub fn test(&self, id: impl Display) -> Result<Value, Error>
pub fn test(&self, id: impl Display) -> Result<Value, Error>
Send a test event to a webhook endpoint.
Sourcepub fn deliveries<T: DeserializeOwned>(
&self,
id: impl Display,
params: Params,
) -> Result<Page<T>, Error>
pub fn deliveries<T: DeserializeOwned>( &self, id: impl Display, params: Params, ) -> Result<Page<T>, Error>
Delivery log for a webhook endpoint (paginated). Params: page, per_page.
Auto Trait Implementations§
impl !RefUnwindSafe for Webhooks
impl !UnwindSafe for Webhooks
impl Freeze for Webhooks
impl Send for Webhooks
impl Sync for Webhooks
impl Unpin for Webhooks
impl UnsafeUnpin for Webhooks
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