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

from __future__ import annotations
from .phonenumbercreate import PhoneNumberCreate, PhoneNumberCreateTypedDict
from .postaladdresscreate import PostalAddressCreate, PostalAddressCreateTypedDict
from ascend_sdk.types import BaseModel
from typing import Optional
from typing_extensions import NotRequired, TypedDict


class TrustedContactCreateTypedDict(TypedDict):
    r"""A Trusted Contact is a person designated to verify the well being of the account holder. Only one form of contact information is required; An account may contain zero, one, or many."""

    family_name: str
    r"""Family name of a natural person."""
    given_name: str
    r"""The given name of a natural person; Conventionally known as 'first name' in most English-speaking countries."""
    email_address: NotRequired[str]
    r"""An email address indicated for account communications."""
    mailing_address: NotRequired[PostalAddressCreateTypedDict]
    r"""Represents a postal address, e.g. for postal delivery or payments addresses. Given a postal address, a postal service can deliver items to a premise, P.O. Box or similar. It is not intended to model geographical locations (roads, towns, mountains).

    In typical usage an address would be created via user input or from importing existing data, depending on the type of process.

    Advice on address input / editing: - Use an i18n-ready address widget such as  https://github.com/google/libaddressinput) - Users should not be presented with UI elements for input or editing of  fields outside countries where that field is used.

    For more guidance on how to use this schema, please see: https://support.google.com/business/answer/6397478
    """
    middle_names: NotRequired[str]
    r"""Non-primary names representing a natural person; Name attributed to a person other than \"Given\" and \"Family\" names."""
    phone_number: NotRequired[PhoneNumberCreateTypedDict]
    r"""An object representing a phone number, suitable as an API wire format.

    This representation:

    - should not be used for locale-specific formatting of a phone number, such  as \"+1 (650) 253-0000 ext. 123\" 

    - is not designed for efficient storage - may not be suitable for dialing - specialized libraries (see references)  should be used to parse the number for that purpose

    To do something meaningful with this number, such as format it for various use-cases, convert it to an `i18n.phonenumbers.PhoneNumber` object first.

    For instance, in Java this would be:

    com.google.type.PhoneNumber wireProto =    com.google.type.PhoneNumber.newBuilder().build();  com.google.i18n.phonenumbers.Phonenumber.PhoneNumber phoneNumber =    PhoneNumberUtil.getInstance().parse(wireProto.getE164Number(), \"ZZ\");  if (!wireProto.getExtension().isEmpty()) {   phoneNumber.setExtension(wireProto.getExtension());  }

    Reference(s):
    - https://github.com/google/libphonenumber
    """


class TrustedContactCreate(BaseModel):
    r"""A Trusted Contact is a person designated to verify the well being of the account holder. Only one form of contact information is required; An account may contain zero, one, or many."""

    family_name: str
    r"""Family name of a natural person."""

    given_name: str
    r"""The given name of a natural person; Conventionally known as 'first name' in most English-speaking countries."""

    email_address: Optional[str] = None
    r"""An email address indicated for account communications."""

    mailing_address: Optional[PostalAddressCreate] = None
    r"""Represents a postal address, e.g. for postal delivery or payments addresses. Given a postal address, a postal service can deliver items to a premise, P.O. Box or similar. It is not intended to model geographical locations (roads, towns, mountains).

    In typical usage an address would be created via user input or from importing existing data, depending on the type of process.

    Advice on address input / editing: - Use an i18n-ready address widget such as  https://github.com/google/libaddressinput) - Users should not be presented with UI elements for input or editing of  fields outside countries where that field is used.

    For more guidance on how to use this schema, please see: https://support.google.com/business/answer/6397478
    """

    middle_names: Optional[str] = None
    r"""Non-primary names representing a natural person; Name attributed to a person other than \"Given\" and \"Family\" names."""

    phone_number: Optional[PhoneNumberCreate] = None
    r"""An object representing a phone number, suitable as an API wire format.

    This representation:

    - should not be used for locale-specific formatting of a phone number, such  as \"+1 (650) 253-0000 ext. 123\" 

    - is not designed for efficient storage - may not be suitable for dialing - specialized libraries (see references)  should be used to parse the number for that purpose

    To do something meaningful with this number, such as format it for various use-cases, convert it to an `i18n.phonenumbers.PhoneNumber` object first.

    For instance, in Java this would be:

    com.google.type.PhoneNumber wireProto =    com.google.type.PhoneNumber.newBuilder().build();  com.google.i18n.phonenumbers.Phonenumber.PhoneNumber phoneNumber =    PhoneNumberUtil.getInstance().parse(wireProto.getE164Number(), \"ZZ\");  if (!wireProto.getExtension().isEmpty()) {   phoneNumber.setExtension(wireProto.getExtension());  }

    Reference(s):
    - https://github.com/google/libphonenumber
    """
