Struct mailchimp_api::batch_webhooks::BatchWebhooks
source · pub struct BatchWebhooks {
pub client: Client,
}Fields
client: ClientImplementations
sourceimpl BatchWebhooks
impl BatchWebhooks
sourcepub async fn get(
&self,
fields: &[String],
exclude_fields: &[String],
count: i64,
offset: i64
) -> Result<BatchWebhooks>
pub async fn get(
&self,
fields: &[String],
exclude_fields: &[String],
count: i64,
offset: i64
) -> Result<BatchWebhooks>
List batch webhooks.
This function performs a GET to the /batch-webhooks endpoint.
Get all webhooks that have been configured for batches.
Parameters:
fields: &[String]– A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.exclude_fields: &[String]– A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.count: i64– The number of records to return. Default value is 10. Maximum value is 1000.offset: i64– Used for pagination, this it the number of records from a collection to skip. Default value is 0.
sourcepub async fn post(&self, body: &BatchWebhook) -> Result<Webhooks>
pub async fn post(&self, body: &BatchWebhook) -> Result<Webhooks>
Add batch webhook.
This function performs a POST to the /batch-webhooks endpoint.
Configure a webhook that will fire whenever any batch request completes processing.
sourcepub async fn get_batch_webhooks(
&self,
fields: &[String],
exclude_fields: &[String],
batch_webhook_id: &str
) -> Result<Webhooks>
pub async fn get_batch_webhooks(
&self,
fields: &[String],
exclude_fields: &[String],
batch_webhook_id: &str
) -> Result<Webhooks>
Get batch webhook info.
This function performs a GET to the /batch-webhooks/{batch_webhook_id} endpoint.
Get information about a specific batch webhook.
Parameters:
fields: &[String]– A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.exclude_fields: &[String]– A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.batch_webhook_id: &str– The unique id for the batch webhook.
sourcepub async fn delete(&self, batch_webhook_id: &str) -> Result<()>
pub async fn delete(&self, batch_webhook_id: &str) -> Result<()>
Delete batch webhook.
This function performs a DELETE to the /batch-webhooks/{batch_webhook_id} endpoint.
Remove a batch webhook. Webhooks will no longer be sent to the given URL.
Parameters:
batch_webhook_id: &str– The unique id for the batch webhook.
sourcepub async fn patch(
&self,
batch_webhook_id: &str,
body: &BatchWebhook
) -> Result<Webhooks>
pub async fn patch(
&self,
batch_webhook_id: &str,
body: &BatchWebhook
) -> Result<Webhooks>
Update batch webhook.
This function performs a PATCH to the /batch-webhooks/{batch_webhook_id} endpoint.
Update a webhook that will fire whenever any batch request completes processing.
Parameters:
batch_webhook_id: &str– The unique id for the batch webhook.