# Generated by ariadne-codegen
# Source: metasrht/graphql/

from typing import Literal, Optional, Union

from pydantic import Field

from .base_model import BaseModel


class CreateSetupIntent(BaseModel):
    intent: Union[
        "CreateSetupIntentIntentSetupIntent", "CreateSetupIntentIntentStripeSetupIntent"
    ] = Field(discriminator="typename__")


class CreateSetupIntentIntentSetupIntent(BaseModel):
    typename__: Literal["SetupIntent"] = Field(alias="__typename")
    id: str


class CreateSetupIntentIntentStripeSetupIntent(BaseModel):
    typename__: Literal["StripeSetupIntent"] = Field(alias="__typename")
    id: str
    public_key: Optional[str] = Field(alias="publicKey")
    client_secret: Optional[str] = Field(alias="clientSecret")


CreateSetupIntent.model_rebuild()
