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

from __future__ import annotations
from .merchantaccountupdate import MerchantAccountUpdate, MerchantAccountUpdateTypedDict
from gr4vy.types import BaseModel
from gr4vy.utils import (
    FieldMetadata,
    PathParamMetadata,
    QueryParamMetadata,
    RequestMetadata,
)
from typing import Optional
from typing_extensions import Annotated, NotRequired, TypedDict


class UpdateMerchantAccountRequestTypedDict(TypedDict):
    merchant_account_id: str
    r"""The ID of the merchant account"""
    merchant_account_update: MerchantAccountUpdateTypedDict
    timeout_in_seconds: NotRequired[float]


class UpdateMerchantAccountRequest(BaseModel):
    merchant_account_id: Annotated[
        str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False))
    ]
    r"""The ID of the merchant account"""

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

    timeout_in_seconds: Annotated[
        Optional[float],
        FieldMetadata(query=QueryParamMetadata(style="form", explode=True)),
    ] = 1
