"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""

from __future__ import annotations
from .v3_globaleventrules_rulesetruleresponse import (
    V3GlobalEventRulesRulesetRuleResponse,
    V3GlobalEventRulesRulesetRuleResponseTypedDict,
)
from .v3_globaleventrules_updaterulerequest import (
    V3GlobalEventRulesUpdateRuleRequest,
    V3GlobalEventRulesUpdateRuleRequestTypedDict,
)
from squadcast_sdk.types import BaseModel
from squadcast_sdk.utils import FieldMetadata, PathParamMetadata, RequestMetadata
from typing_extensions import Annotated, TypedDict


class GlobalEventRulesUpdateRuleByIDRequestTypedDict(TypedDict):
    ger_id: int
    alert_source_version: str
    alert_source_shortname: str
    rule_id: str
    v3_global_event_rules_update_rule_request: (
        V3GlobalEventRulesUpdateRuleRequestTypedDict
    )


class GlobalEventRulesUpdateRuleByIDRequest(BaseModel):
    ger_id: Annotated[
        int, FieldMetadata(path=PathParamMetadata(style="simple", explode=False))
    ]

    alert_source_version: Annotated[
        str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False))
    ]

    alert_source_shortname: Annotated[
        str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False))
    ]

    rule_id: Annotated[
        str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False))
    ]

    v3_global_event_rules_update_rule_request: Annotated[
        V3GlobalEventRulesUpdateRuleRequest,
        FieldMetadata(request=RequestMetadata(media_type="application/json")),
    ]


class GlobalEventRulesUpdateRuleByIDResponseTypedDict(TypedDict):
    r"""The request has succeeded."""

    data: V3GlobalEventRulesRulesetRuleResponseTypedDict


class GlobalEventRulesUpdateRuleByIDResponse(BaseModel):
    r"""The request has succeeded."""

    data: V3GlobalEventRulesRulesetRuleResponse
