pub struct BouncesApi {
pub client: Client,
}
Fields§
§client: Client
Implementations§
Source§impl BouncesApi
impl BouncesApi
Sourcepub async fn get_suppression_bounces(
&self,
start_time: i64,
end_time: i64,
) -> Result<Response<Vec<BounceResponse>>, ClientError>
pub async fn get_suppression_bounces( &self, start_time: i64, end_time: i64, ) -> Result<Response<Vec<BounceResponse>>, ClientError>
Retrieve all bounces.
This function performs a GET
to the /suppression/bounces
endpoint.
This endpoint allows you to retrieve all of your bounces.
Parameters:
start_time: i64
– Refers start of the time range in unix timestamp when a bounce was created (inclusive).end_time: i64
– Refers end of the time range in unix timestamp when a bounce was created (inclusive).accept: &str
– The license key provided with your New Relic account.on_behalf_of: &str
– The license key provided with your New Relic account.
Sourcepub async fn get_all_suppression_bounces(
&self,
start_time: i64,
end_time: i64,
) -> Result<Response<Vec<BounceResponse>>, ClientError>
pub async fn get_all_suppression_bounces( &self, start_time: i64, end_time: i64, ) -> Result<Response<Vec<BounceResponse>>, ClientError>
Retrieve all bounces.
This function performs a GET
to the /suppression/bounces
endpoint.
As opposed to get_suppression_bounces
, this function returns all the pages of the request at once.
This endpoint allows you to retrieve all of your bounces.
Sourcepub async fn delete_suppression_bounces(
&self,
body: &DeleteSuppressionBouncesRequest,
) -> Result<Response<()>, ClientError>
pub async fn delete_suppression_bounces( &self, body: &DeleteSuppressionBouncesRequest, ) -> Result<Response<()>, ClientError>
Delete bounces.
This function performs a DELETE
to the /suppression/bounces
endpoint.
This endpoint allows you to delete all emails on your bounces list.
There are two options for deleting bounced emails:
- You can delete all bounced emails by setting
delete_all
totrue
in the request body. - You can delete a selection of bounced emails by specifying the email addresses in the
emails
array of the request body.
Parameters:
on_behalf_of: &str
– The license key provided with your New Relic account.
Sourcepub async fn get_suppression_bounces_email(
&self,
email: &str,
) -> Result<Response<Vec<BounceResponse>>, ClientError>
pub async fn get_suppression_bounces_email( &self, email: &str, ) -> Result<Response<Vec<BounceResponse>>, ClientError>
Retrieve a Bounce.
This function performs a GET
to the /suppression/bounces/{email}
endpoint.
This endpoint allows you to retrieve a specific bounce by email address.
Parameters:
on_behalf_of: &str
– The license key provided with your New Relic account.
Sourcepub async fn get_all_suppression_bounces_email(
&self,
email: &str,
) -> Result<Response<Vec<BounceResponse>>, ClientError>
pub async fn get_all_suppression_bounces_email( &self, email: &str, ) -> Result<Response<Vec<BounceResponse>>, ClientError>
Retrieve a Bounce.
This function performs a GET
to the /suppression/bounces/{email}
endpoint.
As opposed to get_suppression_bounces_email
, this function returns all the pages of the request at once.
This endpoint allows you to retrieve a specific bounce by email address.
Sourcepub async fn delete_suppression_bounces_email(
&self,
email: &str,
email_address: &str,
body: &Value,
) -> Result<Response<Help>, ClientError>
pub async fn delete_suppression_bounces_email( &self, email: &str, email_address: &str, body: &Value, ) -> Result<Response<Help>, ClientError>
Delete a bounce.
This function performs a DELETE
to the /suppression/bounces/{email}
endpoint.
This endpoint allows you to remove an email address from your bounce list.
Parameters:
email_address: &str
– The email address you would like to remove from the bounce list.on_behalf_of: &str
– The license key provided with your New Relic account.