> For the complete documentation index, see [llms.txt](https://developers.incidents.cloud.solarwinds.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developers.incidents.cloud.solarwinds.com/api-reference/services-suppression-rules.md).

# Services/Suppression Rules

## GET /v3/services/{serviceID}/suppression-rules

> Get Suppression Rules

```json
{"openapi":"3.1.0","info":{"title":"Squadcast","version":"1.0.0"},"tags":[{"name":"Services/Suppression Rules"}],"servers":[{"url":"https://api.squadcast.com","description":"production US env","variables":{}},{"url":"https://api.eu.squadcast.com","description":"production EU env","variables":{}}],"security":[{"BearerAuth":[]}],"components":{"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer"}},"schemas":{"V3.Services.SuppressionRules.SuppressionRuleResponse":{"type":"object","allOf":[{"$ref":"#/components/schemas/V3.Services.SuppressionRules.SuppressionRule"}]},"V3.Services.SuppressionRules.SuppressionRule":{"type":"object","required":["rule_id","created_at","updated_at","created_by","updated_by","description","expression","is_basic","is_timebased","timeslots","basic_expression"],"properties":{"rule_id":{"type":"string"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"created_by":{"type":"string"},"updated_by":{"type":"string"},"description":{"type":"string"},"expression":{"type":"string"},"is_basic":{"type":"boolean"},"is_timebased":{"type":"boolean"},"timeslots":{"anyOf":[{"type":"array","items":{"$ref":"#/components/schemas/V3.Services.SuppressionRules.Timeslot"}},{"type":"null"}]},"basic_expression":{"type":"array","items":{"$ref":"#/components/schemas/V3.Services.SuppressionRules.BasicExpression"}}}},"V3.Services.SuppressionRules.Timeslot":{"type":"object","required":["time_zone","start_time","end_time","is_allday","repetition","is_custom","custom","ends_never","ends_on"],"properties":{"time_zone":{"type":"string"},"start_time":{"type":"string"},"end_time":{"type":"string"},"is_allday":{"type":"boolean"},"repetition":{"type":"string"},"is_custom":{"type":"boolean"},"custom":{"$ref":"#/components/schemas/V3.Services.SuppressionRules.CustomRepetition"},"ends_never":{"type":"boolean"},"ends_on":{"type":"string"}}},"V3.Services.SuppressionRules.CustomRepetition":{"type":"object","required":["repeats_count","repeats","repeats_on_weekdays","repeats_on_month"],"properties":{"repeats_count":{"type":"integer"},"repeats":{"type":"string"},"repeats_on_weekdays":{"type":"array","items":{"type":"integer"}},"repeats_on_month":{"type":"string"}}},"V3.Services.SuppressionRules.BasicExpression":{"type":"object","required":["lhs","op","rhs"],"properties":{"lhs":{"type":"string"},"op":{"type":"string"},"rhs":{"type":"string"}}},"Common.V3.ErrorMeta":{"type":"object","required":["status","error_message"],"properties":{"status":{"anyOf":[{"type":"string"},{"type":"integer"}]},"error_message":{"type":"string"}},"description":"Represents a single response containing data of type T."}}},"paths":{"/v3/services/{serviceID}/suppression-rules":{"get":{"operationId":"SuppressionRules_getSuppressionRules","summary":"Get Suppression Rules","parameters":[{"name":"serviceID","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The request has succeeded.","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"rules":{"type":"array","items":{"$ref":"#/components/schemas/V3.Services.SuppressionRules.SuppressionRuleResponse"}}},"required":["rules"]}},"required":["data"]}}}},"400":{"description":"The server could not understand the request due to invalid syntax.","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"401":{"description":"Access is unauthorized.","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"402":{"description":"Client error","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"403":{"description":"Access is forbidden.","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"404":{"description":"The server cannot find the requested resource.","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"409":{"description":"The request conflicts with the current state of the server.","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"422":{"description":"Client error","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"500":{"description":"Server error","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"502":{"description":"Server error","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"503":{"description":"Service unavailable.","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"504":{"description":"Server error","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}}},"tags":["Services/Suppression Rules"]}}}}
```

## POST /v3/services/{serviceID}/suppression-rules

> Create or Update Suppression Rules

```json
{"openapi":"3.1.0","info":{"title":"Squadcast","version":"1.0.0"},"tags":[{"name":"Services/Suppression Rules"}],"servers":[{"url":"https://api.squadcast.com","description":"production US env","variables":{}},{"url":"https://api.eu.squadcast.com","description":"production EU env","variables":{}}],"security":[{"BearerAuth":[]}],"components":{"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer"}},"schemas":{"V3.Services.SuppressionRules.SuppressionRulesContainerResponse":{"type":"object","allOf":[{"$ref":"#/components/schemas/V3.Services.SuppressionRules.SuppressionRulesContainer"}]},"V3.Services.SuppressionRules.SuppressionRulesContainer":{"type":"object","required":["id","created_at","updated_at","service_id","organization_id","rules"],"properties":{"id":{"type":"string"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"service_id":{"type":"string"},"organization_id":{"type":"string"},"rules":{"type":"array","items":{"$ref":"#/components/schemas/V3.Services.SuppressionRules.SuppressionRule"}}}},"V3.Services.SuppressionRules.SuppressionRule":{"type":"object","required":["rule_id","created_at","updated_at","created_by","updated_by","description","expression","is_basic","is_timebased","timeslots","basic_expression"],"properties":{"rule_id":{"type":"string"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"created_by":{"type":"string"},"updated_by":{"type":"string"},"description":{"type":"string"},"expression":{"type":"string"},"is_basic":{"type":"boolean"},"is_timebased":{"type":"boolean"},"timeslots":{"anyOf":[{"type":"array","items":{"$ref":"#/components/schemas/V3.Services.SuppressionRules.Timeslot"}},{"type":"null"}]},"basic_expression":{"type":"array","items":{"$ref":"#/components/schemas/V3.Services.SuppressionRules.BasicExpression"}}}},"V3.Services.SuppressionRules.Timeslot":{"type":"object","required":["time_zone","start_time","end_time","is_allday","repetition","is_custom","custom","ends_never","ends_on"],"properties":{"time_zone":{"type":"string"},"start_time":{"type":"string"},"end_time":{"type":"string"},"is_allday":{"type":"boolean"},"repetition":{"type":"string"},"is_custom":{"type":"boolean"},"custom":{"$ref":"#/components/schemas/V3.Services.SuppressionRules.CustomRepetition"},"ends_never":{"type":"boolean"},"ends_on":{"type":"string"}}},"V3.Services.SuppressionRules.CustomRepetition":{"type":"object","required":["repeats_count","repeats","repeats_on_weekdays","repeats_on_month"],"properties":{"repeats_count":{"type":"integer"},"repeats":{"type":"string"},"repeats_on_weekdays":{"type":"array","items":{"type":"integer"}},"repeats_on_month":{"type":"string"}}},"V3.Services.SuppressionRules.BasicExpression":{"type":"object","required":["lhs","op","rhs"],"properties":{"lhs":{"type":"string"},"op":{"type":"string"},"rhs":{"type":"string"}}},"Common.V3.ErrorMeta":{"type":"object","required":["status","error_message"],"properties":{"status":{"anyOf":[{"type":"string"},{"type":"integer"}]},"error_message":{"type":"string"}},"description":"Represents a single response containing data of type T."},"V3.Services.SuppressionRules.CreateOrUpdateSuppressionRulesRequest":{"type":"object","required":["rules"],"properties":{"rules":{"type":"array","items":{"$ref":"#/components/schemas/V3.Services.SuppressionRules.SuppressionRule"}}}}}},"paths":{"/v3/services/{serviceID}/suppression-rules":{"post":{"operationId":"SuppressionRules_createOrUpdateSuppressionRules","summary":"Create or Update Suppression Rules","parameters":[{"name":"serviceID","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The request has succeeded.","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"$ref":"#/components/schemas/V3.Services.SuppressionRules.SuppressionRulesContainerResponse"}}}}}},"400":{"description":"The server could not understand the request due to invalid syntax.","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"401":{"description":"Access is unauthorized.","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"402":{"description":"Client error","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"403":{"description":"Access is forbidden.","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"404":{"description":"The server cannot find the requested resource.","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"409":{"description":"The request conflicts with the current state of the server.","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"422":{"description":"Client error","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"500":{"description":"Server error","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"502":{"description":"Server error","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"503":{"description":"Service unavailable.","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}},"504":{"description":"Server error","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"$ref":"#/components/schemas/Common.V3.ErrorMeta"}},"required":["meta"]}}}}},"tags":["Services/Suppression Rules"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/V3.Services.SuppressionRules.CreateOrUpdateSuppressionRulesRequest"}}}}}}}}
```
