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

from __future__ import annotations
from .retirementdistributioncreate import (
    RetirementDistributionCreate,
    RetirementDistributionCreateTypedDict,
)
from .withdrawalscheduledetailscreate import (
    WithdrawalScheduleDetailsCreate,
    WithdrawalScheduleDetailsCreateTypedDict,
)
from ascend_sdk.types import BaseModel
from typing import Optional
from typing_extensions import NotRequired, TypedDict


class AchWithdrawalScheduleCreateTypedDict(TypedDict):
    r"""A withdrawal transfer schedule using the ACH mechanism"""

    bank_relationship: str
    r"""The name of the bank relationship to be used in the ACH transaction"""
    schedule_details: WithdrawalScheduleDetailsCreateTypedDict
    r"""Details of withdrawal schedule transfers"""
    ira_distribution: NotRequired[RetirementDistributionCreateTypedDict]
    r"""A distribution from a retirement account."""


class AchWithdrawalScheduleCreate(BaseModel):
    r"""A withdrawal transfer schedule using the ACH mechanism"""

    bank_relationship: str
    r"""The name of the bank relationship to be used in the ACH transaction"""

    schedule_details: WithdrawalScheduleDetailsCreate
    r"""Details of withdrawal schedule transfers"""

    ira_distribution: Optional[RetirementDistributionCreate] = None
    r"""A distribution from a retirement account."""
