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

from ...core.pydantic_utilities import UniversalBaseModel
from ...payment_method_types.types.payment_method_type import PaymentMethodType
import pydantic
import typing
from ...core.pydantic_utilities import IS_PYDANTIC_V2


class PaymentRailResponse(UniversalBaseModel):
    type: PaymentMethodType
    name: str = pydantic.Field()
    """
    For custom payment methods, this is the ID of the schema.
    """

    active: bool
    available: typing.Optional[bool] = pydantic.Field(default=None)
    """
    unused
    """

    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
