gcloud_storage/http/notifications/
get.rs1use reqwest_middleware::{ClientWithMiddleware as Client, RequestBuilder};
2
3use crate::http::Escape;
4
5#[derive(Clone, PartialEq, Eq, serde::Deserialize, serde::Serialize, Debug)]
7#[serde(rename_all = "camelCase")]
8pub struct GetNotificationRequest {
9 pub bucket: String,
11 pub notification: String,
13}
14
15pub(crate) fn build(base_url: &str, client: &Client, req: &GetNotificationRequest) -> RequestBuilder {
16 let url = format!(
17 "{}/b/{}/notificationConfigs/{}",
18 base_url,
19 req.bucket.escape(),
20 req.notification.escape()
21 );
22 client.get(url)
23}