# This file was auto-generated by Fern from our API Definition.

from __future__ import annotations

import typing

import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, update_forward_refs
from ..core.unchecked_base_model import UncheckedBaseModel
from .api_integration_webhook_overrides_output_request_headers_value import (
    ApiIntegrationWebhookOverridesOutputRequestHeadersValue,
)
from .literal_override import LiteralOverride
from .query_override import QueryOverride
from .response_filter_mode import ResponseFilterMode


class ApiIntegrationWebhookOverridesOutput(UncheckedBaseModel):
    """
    A whitelist of fields that can be overridden by users when
    configuring an API Integration Webhook Tool.
    """

    path_params_schema: typing.Optional[typing.Dict[str, typing.Optional[LiteralOverride]]] = None
    query_params_schema: typing.Optional[QueryOverride] = None
    request_body_schema: typing.Optional["ObjectOverrideOutput"] = None
    request_headers: typing.Optional[
        typing.Dict[str, typing.Optional[ApiIntegrationWebhookOverridesOutputRequestHeadersValue]]
    ] = None
    response_filter_mode: typing.Optional[ResponseFilterMode] = None
    response_filters: typing.Optional[typing.List[str]] = None

    if IS_PYDANTIC_V2:
        model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True)  # type: ignore # Pydantic v2
    else:

        class Config:
            frozen = True
            smart_union = True
            extra = pydantic.Extra.allow


from .object_override_output import ObjectOverrideOutput  # noqa: E402, I001

update_forward_refs(ApiIntegrationWebhookOverridesOutput)
