pub struct AlertsClient { /* private fields */ }
Expand description
The Alerts API client. Read more at https://coralogix.com/docs/coralogix-user-defined-alerts/
Implementations§
source§impl AlertsClient
impl AlertsClient
sourcepub fn new(region: CoralogixRegion, auth_context: AuthContext) -> Result<Self>
pub fn new(region: CoralogixRegion, auth_context: AuthContext) -> Result<Self>
Creates a new client for the Alerts API.
§Arguments
auth_context
- The API key to use for authentication.region
- The region to connect to.
sourcepub async fn get(&self, alert_id: String) -> Result<GetAlertDefResponse>
pub async fn get(&self, alert_id: String) -> Result<GetAlertDefResponse>
sourcepub async fn list(&self) -> Result<ListAlertDefsResponse>
pub async fn list(&self) -> Result<ListAlertDefsResponse>
List all alert definitions.
sourcepub async fn create(&self, alert: AlertDef) -> Result<CreateAlertDefResponse>
pub async fn create(&self, alert: AlertDef) -> Result<CreateAlertDefResponse>
sourcepub async fn replace(&self, alert: AlertDef) -> Result<ReplaceAlertDefResponse>
pub async fn replace(&self, alert: AlertDef) -> Result<ReplaceAlertDefResponse>
Auto Trait Implementations§
impl !Freeze for AlertsClient
impl !RefUnwindSafe for AlertsClient
impl Send for AlertsClient
impl Sync for AlertsClient
impl Unpin for AlertsClient
impl !UnwindSafe for AlertsClient
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request