Package com.influxdb.client.service
Interface NotificationRulesService
public interface NotificationRulesService
-
Method Summary
Modifier and TypeMethodDescriptionretrofit2.Call<NotificationRule> createNotificationRule(NotificationRule notificationRule) Add a notification ruleretrofit2.Call<Void> deleteNotificationRulesID(String ruleID, String zapTraceSpan) Delete a notification ruleretrofit2.Call<Void> deleteNotificationRulesIDLabelsID(String ruleID, String labelID, String zapTraceSpan) Delete label from a notification ruleretrofit2.Call<NotificationRules> getNotificationRules(String orgID, String zapTraceSpan, Integer offset, Integer limit, String checkID, String tag) List all notification rulesretrofit2.Call<NotificationRule> getNotificationRulesID(String ruleID, String zapTraceSpan) Retrieve a notification ruleretrofit2.Call<LabelsResponse> getNotificationRulesIDLabels(String ruleID, String zapTraceSpan) List all labels for a notification ruleretrofit2.Call<NotificationRule> patchNotificationRulesID(String ruleID, NotificationRuleUpdate notificationRuleUpdate, String zapTraceSpan) Update a notification ruleretrofit2.Call<LabelResponse> postNotificationRuleIDLabels(String ruleID, LabelMapping labelMapping, String zapTraceSpan) Add a label to a notification ruleretrofit2.Call<NotificationRule> putNotificationRulesID(String ruleID, NotificationRule notificationRule, String zapTraceSpan) Update a notification rule
-
Method Details
-
createNotificationRule
@Headers("Content-Type:application/json") @POST("api/v2/notificationRules") retrofit2.Call<NotificationRule> createNotificationRule(@Body NotificationRule notificationRule) Add a notification rule- Parameters:
notificationRule- Notification rule to create (required)- Returns:
- Call<NotificationRule>
-
deleteNotificationRulesID
@DELETE("api/v2/notificationRules/{ruleID}") retrofit2.Call<Void> deleteNotificationRulesID(@Path("ruleID") String ruleID, @Header("Zap-Trace-Span") String zapTraceSpan) Delete a notification rule- Parameters:
ruleID- The notification rule ID. (required)zapTraceSpan- OpenTracing span context (optional)- Returns:
- Call<Void>
-
deleteNotificationRulesIDLabelsID
@DELETE("api/v2/notificationRules/{ruleID}/labels/{labelID}") retrofit2.Call<Void> deleteNotificationRulesIDLabelsID(@Path("ruleID") String ruleID, @Path("labelID") String labelID, @Header("Zap-Trace-Span") String zapTraceSpan) Delete label from a notification rule- Parameters:
ruleID- The notification rule ID. (required)labelID- The ID of the label to delete. (required)zapTraceSpan- OpenTracing span context (optional)- Returns:
- Call<Void>
-
getNotificationRules
@GET("api/v2/notificationRules") retrofit2.Call<NotificationRules> getNotificationRules(@Query("orgID") String orgID, @Header("Zap-Trace-Span") String zapTraceSpan, @Query("offset") Integer offset, @Query("limit") Integer limit, @Query("checkID") String checkID, @Query("tag") String tag) List all notification rules- Parameters:
orgID- Only show notification rules that belong to a specific organization ID. (required)zapTraceSpan- OpenTracing span context (optional)offset- (optional)limit- (optional, default to 20)checkID- Only show notifications that belong to the specific check ID. (optional)tag- Only return notification rules that \"would match\" statuses which contain the tag key value pairs provided. (optional)- Returns:
- Call<NotificationRules>
-
getNotificationRulesID
@GET("api/v2/notificationRules/{ruleID}") retrofit2.Call<NotificationRule> getNotificationRulesID(@Path("ruleID") String ruleID, @Header("Zap-Trace-Span") String zapTraceSpan) Retrieve a notification rule- Parameters:
ruleID- The notification rule ID. (required)zapTraceSpan- OpenTracing span context (optional)- Returns:
- Call<NotificationRule>
-
getNotificationRulesIDLabels
@GET("api/v2/notificationRules/{ruleID}/labels") retrofit2.Call<LabelsResponse> getNotificationRulesIDLabels(@Path("ruleID") String ruleID, @Header("Zap-Trace-Span") String zapTraceSpan) List all labels for a notification rule- Parameters:
ruleID- The notification rule ID. (required)zapTraceSpan- OpenTracing span context (optional)- Returns:
- Call<LabelsResponse>
-
patchNotificationRulesID
@Headers("Content-Type:application/json") @PATCH("api/v2/notificationRules/{ruleID}") retrofit2.Call<NotificationRule> patchNotificationRulesID(@Path("ruleID") String ruleID, @Body NotificationRuleUpdate notificationRuleUpdate, @Header("Zap-Trace-Span") String zapTraceSpan) Update a notification rule- Parameters:
ruleID- The notification rule ID. (required)notificationRuleUpdate- Notification rule update to apply (required)zapTraceSpan- OpenTracing span context (optional)- Returns:
- Call<NotificationRule>
-
postNotificationRuleIDLabels
@Headers("Content-Type:application/json") @POST("api/v2/notificationRules/{ruleID}/labels") retrofit2.Call<LabelResponse> postNotificationRuleIDLabels(@Path("ruleID") String ruleID, @Body LabelMapping labelMapping, @Header("Zap-Trace-Span") String zapTraceSpan) Add a label to a notification rule- Parameters:
ruleID- The notification rule ID. (required)labelMapping- Label to add (required)zapTraceSpan- OpenTracing span context (optional)- Returns:
- Call<LabelResponse>
-
putNotificationRulesID
@Headers("Content-Type:application/json") @PUT("api/v2/notificationRules/{ruleID}") retrofit2.Call<NotificationRule> putNotificationRulesID(@Path("ruleID") String ruleID, @Body NotificationRule notificationRule, @Header("Zap-Trace-Span") String zapTraceSpan) Update a notification rule- Parameters:
ruleID- The notification rule ID. (required)notificationRule- Notification rule update to apply (required)zapTraceSpan- OpenTracing span context (optional)- Returns:
- Call<NotificationRule>
-