> 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/python-sdk/docs/sdks/globaleventrulesrulesets.md).

# GlobalEventRules.Rulesets

## Overview

### Available Operations

* [create](#create) - Create Ruleset
* [delete](#delete) - Delete GER Ruleset
* [get](#get) - Get Ruleset
* [update](#update) - Update Ruleset

## create

Create a GER Ruleset.

### Example Usage

```python
from squadcast import SquadcastSDK


with SquadcastSDK(
    refresh_token_auth="<YOUR_REFRESH_TOKEN_AUTH_HERE>",
) as squadcast_sdk:

    res = squadcast_sdk.global_event_rules.rulesets.create(ger_id=216762, alert_source_shortname="<value>", alert_source_version="<value>")

    # Handle response
    print(res)

```

### Parameters

| Parameter                | Type                                                                                                                                                        | Required             | Description                                                         |
| ------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------- | ------------------------------------------------------------------- |
| `ger_id`                 | *int*                                                                                                                                                       | :heavy\_check\_mark: | N/A                                                                 |
| `alert_source_shortname` | *str*                                                                                                                                                       | :heavy\_check\_mark: | N/A                                                                 |
| `alert_source_version`   | *str*                                                                                                                                                       | :heavy\_check\_mark: | N/A                                                                 |
| `catch_all_action`       | [Optional\[models.V3GlobalEventRulesRuleAction\]](https://developers.incidents.cloud.solarwinds.com/python-sdk/docs/models/v3globaleventrulesruleaction.md) | :heavy\_minus\_sign: | N/A                                                                 |
| `retries`                | [Optional\[utils.RetryConfig\]](https://developers.incidents.cloud.solarwinds.com/python-sdk/docs/models/utils/retryconfig.md)                              | :heavy\_minus\_sign: | Configuration to override the default retry behavior of the client. |

### Response

[**models.GlobalEventRulesCreateRulesetResponse**](https://developers.incidents.cloud.solarwinds.com/python-sdk/docs/models/globaleventrulescreaterulesetresponse.md)

### Errors

| Error Type                      | Status Code | Content Type     |
| ------------------------------- | ----------- | ---------------- |
| errors.BadRequestError          | 400         | application/json |
| errors.UnauthorizedError        | 401         | application/json |
| errors.PaymentRequiredError     | 402         | application/json |
| errors.ForbiddenError           | 403         | application/json |
| errors.NotFoundError            | 404         | application/json |
| errors.ConflictError            | 409         | application/json |
| errors.UnprocessableEntityError | 422         | application/json |
| errors.InternalServerError      | 500         | application/json |
| errors.BadGatewayError          | 502         | application/json |
| errors.ServiceUnavailableError  | 503         | application/json |
| errors.GatewayTimeoutError      | 504         | application/json |
| errors.SDKDefaultError          | 4XX, 5XX    | \*/\*            |

## delete

Delete a GER Ruleset

### Example Usage

```python
from squadcast import SquadcastSDK


with SquadcastSDK(
    refresh_token_auth="<YOUR_REFRESH_TOKEN_AUTH_HERE>",
) as squadcast_sdk:

    res = squadcast_sdk.global_event_rules.rulesets.delete(ger_id=198518, alert_source_version="<value>", alert_source_shortname="<value>")

    # Handle response
    print(res)

```

### Parameters

| Parameter                | Type                                                                                                                           | Required             | Description                                                         |
| ------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | -------------------- | ------------------------------------------------------------------- |
| `ger_id`                 | *int*                                                                                                                          | :heavy\_check\_mark: | N/A                                                                 |
| `alert_source_version`   | *str*                                                                                                                          | :heavy\_check\_mark: | N/A                                                                 |
| `alert_source_shortname` | *str*                                                                                                                          | :heavy\_check\_mark: | N/A                                                                 |
| `retries`                | [Optional\[utils.RetryConfig\]](https://developers.incidents.cloud.solarwinds.com/python-sdk/docs/models/utils/retryconfig.md) | :heavy\_minus\_sign: | Configuration to override the default retry behavior of the client. |

### Response

[**bytes**](https://github.com/solarwinds/squadcast-sdk-python/tree/main/squadcastv1/docs/models/.md/README.md)

### Errors

| Error Type                      | Status Code | Content Type     |
| ------------------------------- | ----------- | ---------------- |
| errors.BadRequestError          | 400         | application/json |
| errors.UnauthorizedError        | 401         | application/json |
| errors.PaymentRequiredError     | 402         | application/json |
| errors.ForbiddenError           | 403         | application/json |
| errors.NotFoundError            | 404         | application/json |
| errors.ConflictError            | 409         | application/json |
| errors.UnprocessableEntityError | 422         | application/json |
| errors.InternalServerError      | 500         | application/json |
| errors.BadGatewayError          | 502         | application/json |
| errors.ServiceUnavailableError  | 503         | application/json |
| errors.GatewayTimeoutError      | 504         | application/json |
| errors.SDKDefaultError          | 4XX, 5XX    | \*/\*            |

## get

Get a GER Ruleset

### Example Usage

```python
from squadcast import SquadcastSDK


with SquadcastSDK(
    refresh_token_auth="<YOUR_REFRESH_TOKEN_AUTH_HERE>",
) as squadcast_sdk:

    res = squadcast_sdk.global_event_rules.rulesets.get(ger_id=294223, alert_source_version="<value>", alert_source_shortname="<value>")

    # Handle response
    print(res)

```

### Parameters

| Parameter                | Type                                                                                                                           | Required             | Description                                                         |
| ------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | -------------------- | ------------------------------------------------------------------- |
| `ger_id`                 | *int*                                                                                                                          | :heavy\_check\_mark: | N/A                                                                 |
| `alert_source_version`   | *str*                                                                                                                          | :heavy\_check\_mark: | N/A                                                                 |
| `alert_source_shortname` | *str*                                                                                                                          | :heavy\_check\_mark: | N/A                                                                 |
| `retries`                | [Optional\[utils.RetryConfig\]](https://developers.incidents.cloud.solarwinds.com/python-sdk/docs/models/utils/retryconfig.md) | :heavy\_minus\_sign: | Configuration to override the default retry behavior of the client. |

### Response

[**models.GlobalEventRulesGetRulesetResponse**](https://developers.incidents.cloud.solarwinds.com/python-sdk/docs/models/globaleventrulesgetrulesetresponse.md)

### Errors

| Error Type                      | Status Code | Content Type     |
| ------------------------------- | ----------- | ---------------- |
| errors.BadRequestError          | 400         | application/json |
| errors.UnauthorizedError        | 401         | application/json |
| errors.PaymentRequiredError     | 402         | application/json |
| errors.ForbiddenError           | 403         | application/json |
| errors.NotFoundError            | 404         | application/json |
| errors.ConflictError            | 409         | application/json |
| errors.UnprocessableEntityError | 422         | application/json |
| errors.InternalServerError      | 500         | application/json |
| errors.BadGatewayError          | 502         | application/json |
| errors.ServiceUnavailableError  | 503         | application/json |
| errors.GatewayTimeoutError      | 504         | application/json |
| errors.SDKDefaultError          | 4XX, 5XX    | \*/\*            |

## update

Update a GER Ruleset

### Example Usage

```python
from squadcast import SquadcastSDK


with SquadcastSDK(
    refresh_token_auth="<YOUR_REFRESH_TOKEN_AUTH_HERE>",
) as squadcast_sdk:

    res = squadcast_sdk.global_event_rules.rulesets.update(ger_id=489958, alert_source_version="<value>", alert_source_shortname="<value>")

    # Handle response
    print(res)

```

### Parameters

| Parameter                | Type                                                                                                                                                                    | Required             | Description                                                         |
| ------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------- | ------------------------------------------------------------------- |
| `ger_id`                 | *int*                                                                                                                                                                   | :heavy\_check\_mark: | N/A                                                                 |
| `alert_source_version`   | *str*                                                                                                                                                                   | :heavy\_check\_mark: | N/A                                                                 |
| `alert_source_shortname` | *str*                                                                                                                                                                   | :heavy\_check\_mark: | N/A                                                                 |
| `catch_all_action`       | [Optional\[models.V3GlobalEventRulesRuleActionUpdate\]](https://developers.incidents.cloud.solarwinds.com/python-sdk/docs/models/v3globaleventrulesruleactionupdate.md) | :heavy\_minus\_sign: | N/A                                                                 |
| `retries`                | [Optional\[utils.RetryConfig\]](https://developers.incidents.cloud.solarwinds.com/python-sdk/docs/models/utils/retryconfig.md)                                          | :heavy\_minus\_sign: | Configuration to override the default retry behavior of the client. |

### Response

[**models.GlobalEventRulesUpdateRulesetResponse**](https://developers.incidents.cloud.solarwinds.com/python-sdk/docs/models/globaleventrulesupdaterulesetresponse.md)

### Errors

| Error Type                      | Status Code | Content Type     |
| ------------------------------- | ----------- | ---------------- |
| errors.BadRequestError          | 400         | application/json |
| errors.UnauthorizedError        | 401         | application/json |
| errors.PaymentRequiredError     | 402         | application/json |
| errors.ForbiddenError           | 403         | application/json |
| errors.NotFoundError            | 404         | application/json |
| errors.ConflictError            | 409         | application/json |
| errors.UnprocessableEntityError | 422         | application/json |
| errors.InternalServerError      | 500         | application/json |
| errors.BadGatewayError          | 502         | application/json |
| errors.ServiceUnavailableError  | 503         | application/json |
| errors.GatewayTimeoutError      | 504         | application/json |
| errors.SDKDefaultError          | 4XX, 5XX    | \*/\*            |
