o
    iЌ                     @   s   d dl Z d dlmZ d dlmZ d dlmZ d dlmZ d dl	m
Z
mZmZmZ d dlmZmZ er8d dlmZ G d	d
 d
ed
 ZdS )    N)ExpandableField)StripeObject)UpdateableAPIResource)sanitize_id)ClassVarDictListOptional)LiteralTYPE_CHECKING)Filec                   @   s  e Zd ZU dZdZeed  ed< G dd deZ	G dd deZ
G dd	 d	eZG d
d deZG dd deZG dd deZG dd deZG dd deZG dd deZG dd deZG dd deZee ed< 	 ee	 ed< ee
 ed< ee ed< 	 ee ed< 	 eed< 	 eed   ed!< 	 ee ed"< ee ed#< 	 ee ed$< 	 ee ed%< 	 ee ed&< 	 eee  ed'< 	 ee ed(< 	 ee ed)< 	 eed*< 	 ee ed+< 	 ee ed,< 	 ee ed-< 	 ee ed.< 	 ee ed/< 	 ee ed0< 	 eeeef  ed1< 	 ee ed2< 	 ed ed3< 	 ee ed4< 	 eed5  ed6< 	 ee ed7< ee ed8< ee ed9< 	 ee ed:< 	 ee ed;< 	 ee ed<< d=d> Zed?d@ ZedAdB Ze	e
eeeeeeeeedCZdDS )EPersona@  
    This is an object representing a person associated with a Stripe account.

    A platform can only access a subset of data in a person for an account where [account.controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `stripe`, which includes Standard and Express accounts, after creating an Account Link or Account Session to start Connect onboarding.

    See the [Standard onboarding](https://docs.stripe.com/connect/standard-accounts) or [Express onboarding](https://docs.stripe.com/connect/express-accounts) documentation for information about prefilling information and account onboarding steps. Learn more about [handling identity verification with the API](https://docs.stripe.com/connect/handling-api-verification#person-information).
    personOBJECT_NAMEc                   @   s4   e Zd ZU G dd deZee ed< 	 deiZdS )zPerson.AdditionalTosAcceptancesc                   @   s6   e Zd ZU ee ed< 	 ee ed< 	 ee ed< dS )z'Person.AdditionalTosAcceptances.Accountdateip
user_agentN)__name__
__module____qualname__r	   int__annotations__str r   r   n/var/www/snowflake_co_dev_github/snow_flake_back_end_deploy/env/lib/python3.10/site-packages/stripe/_person.pyAccount      
 r   accountN)r   r   r   r   r   r	   r   _inner_class_typesr   r   r   r   AdditionalTosAcceptances   s
   
 r   c                   @   `   e Zd ZU ee ed< 	 ee ed< 	 ee ed< 	 ee ed< 	 ee ed< 	 ee ed< dS )zPerson.Addresscitycountryline1line2postal_codestateNr   r   r   r	   r   r   r   r   r   r   Address/      
 r(   c                   @   n   e Zd ZU ee ed< 	 ee ed< 	 ee ed< 	 ee ed< 	 ee ed< 	 ee ed< 	 ee ed< dS )	zPerson.AddressKanar!   r"   r#   r$   r%   r&   townNr'   r   r   r   r   AddressKanaI      
 r,   c                   @   r*   )	zPerson.AddressKanjir!   r"   r#   r$   r%   r&   r+   Nr'   r   r   r   r   AddressKanjig   r-   r.   c                   @   s6   e Zd ZU ee ed< 	 ee ed< 	 ee ed< dS )z
Person.DobdaymonthyearN)r   r   r   r	   r   r   r   r   r   r   Dob   r   r2   c                   @      e Zd ZU G dd deZG dd deZeee  ed< 	 ee	 ed< 	 ee ed< 	 ee	 ed< 	 ee	 ed	< 	 ee	 ed
< 	 eedZ
dS )zPerson.FutureRequirementsc                   @   (   e Zd ZU ee ed< 	 ee ed< dS )z%Person.FutureRequirements.Alternativealternative_fields_dueoriginal_fields_dueNr   r   r   r   r   r   r   r   r   r   Alternative   
   
 r8   c                   @   .   e Zd ZU ed ed< 	 eed< 	 eed< dS )zPerson.FutureRequirements.Erroraexternal_requestinformation_missing&invalid_address_city_state_postal_code$invalid_address_highway_contract_boxinvalid_address_private_mailboxinvalid_business_profile_name(invalid_business_profile_name_denylistedinvalid_company_name_denylistedinvalid_dob_age_over_maximuminvalid_dob_age_under_18invalid_dob_age_under_minimum"invalid_product_description_length%invalid_product_description_url_matchinvalid_representative_countryinvalid_signator.invalid_statement_descriptor_business_mismatch'invalid_statement_descriptor_denylisted#invalid_statement_descriptor_length.invalid_statement_descriptor_prefix_denylisted,invalid_statement_descriptor_prefix_mismatchinvalid_street_addressinvalid_tax_idinvalid_tax_id_formatinvalid_tos_acceptanceinvalid_url_denylistedinvalid_url_formatinvalid_url_length!invalid_url_web_presence_detected1invalid_url_website_business_information_mismatchinvalid_url_website_empty invalid_url_website_inaccessible+invalid_url_website_inaccessible_geoblocked3invalid_url_website_inaccessible_password_protectedinvalid_url_website_incomplete2invalid_url_website_incomplete_cancellation_policy7invalid_url_website_incomplete_customer_service_details1invalid_url_website_incomplete_legal_restrictions,invalid_url_website_incomplete_refund_policy,invalid_url_website_incomplete_return_policy3invalid_url_website_incomplete_terms_and_conditions1invalid_url_website_incomplete_under_constructioninvalid_url_website_otherinvalid_value_otherunsupported_business_typeverification_directors_mismatch&verification_document_address_mismatch%verification_document_address_missingverification_document_corrupt+verification_document_country_not_supported(verification_document_directors_mismatch"verification_document_dob_mismatch$verification_document_duplicate_typeverification_document_expired!verification_document_failed_copy&verification_document_failed_greyscale"verification_document_failed_other&verification_document_failed_test_mode verification_document_fraudulent(verification_document_id_number_mismatch'verification_document_id_number_missing verification_document_incompleteverification_document_invalid2verification_document_issue_or_expiry_date_missing!verification_document_manipulated"verification_document_missing_back#verification_document_missing_front#verification_document_name_mismatch"verification_document_name_missing*verification_document_nationality_mismatch"verification_document_not_readable verification_document_not_signed"verification_document_not_uploaded$verification_document_photo_mismatchverification_document_too_large(verification_document_type_not_supported!verification_extraneous_directors!verification_failed_address_match(verification_failed_authorizer_authority'verification_failed_business_iec_number"verification_failed_document_match#verification_failed_id_number_match"verification_failed_keyed_identityverification_failed_keyed_matchverification_failed_name_matchverification_failed_other,verification_failed_representative_authority'verification_failed_residential_address verification_failed_tax_id_match%verification_failed_tax_id_not_issued,verification_legal_entity_structure_mismatchverification_missing_directorsverification_missing_executivesverification_missing_owners0verification_rejected_ownership_exemption_reason;verification_requires_additional_memorandum_of_associations6verification_requires_additional_proof_of_registrationverification_supportabilitycodereasonrequirementNr   r   r   r
   r   r   r   r   r   r   Error      
 cr   alternativescurrently_dueerrorseventually_duepast_duepending_verificationr   r   Nr   r   r   r   r8   r   r	   r   r   r   r   r   r   r   r   FutureRequirements       
 
pr   c                   @   r    )zPerson.RegisteredAddressr!   r"   r#   r$   r%   r&   Nr'   r   r   r   r   RegisteredAddress(  r)   r   c                   @   s|   e Zd ZU ee ed< 	 ee ed< 	 ee ed< 	 ee ed< 	 ee ed< 	 ee ed< 	 ee ed< 	 ee ed< d	S )
zPerson.Relationship
authorizerdirector	executivelegal_guardianownerpercent_ownershiprepresentativetitleN)r   r   r   r	   boolr   floatr   r   r   r   r   RelationshipB  s"   
 r   c                   @   r3   )zPerson.Requirementsc                   @   r4   )zPerson.Requirements.Alternativer5   r6   Nr7   r   r   r   r   r8   e  r9   r8   c                   @   r:   )zPerson.Requirements.Errorr;   r   r   r   Nr   r   r   r   r   r   o  r   r   r   r   r   r   r   r   r   Nr   r   r   r   r   Requirementsd  r   r   c                   @   sb   e Zd ZU G dd deZG dd deZee ed< 	 ee ed< 	 ee ed< 	 eedZ	d	S )
zPerson.UsCfpbDatac                   @   0   e Zd ZU eeed   ed< 	 ee ed< dS )z"Person.UsCfpbData.EthnicityDetails)cubanhispanic_or_latinomexicannot_hispanic_or_latinoother_hispanic_or_latinoprefer_not_to_answerpuerto_rican	ethnicityethnicity_otherNr   r   r   r	   r   r
   r   r   r   r   r   r   EthnicityDetails  s   
 r   c                   @   r   )zPerson.UsCfpbData.RaceDetails)african_american american_indian_or_alaska_nativeasianasian_indianblack_or_african_americanchinese	ethiopianfilipinoguamanian_or_chamorrohaitianjamaicanjapanesekoreannative_hawaiian)native_hawaiian_or_other_pacific_islandernigerianother_asianother_black_or_african_americanother_pacific_islanderr   samoansomali
vietnamesewhiterace
race_otherNr   r   r   r   r   RaceDetails  s   
 r   ethnicity_detailsrace_detailsself_identified_gender)r   r   N)
r   r   r   r   r   r   r	   r   r   r   r   r   r   r   
UsCfpbData  s   
 '
r   c                   @   sx   e Zd ZU G dd deZG dd deZee ed< 	 ee ed< 	 ee ed< 	 ee ed< eed	< 	 eed
Z	dS )zPerson.Verificationc                   @   L   e Zd ZU eed  ed< 	 ee ed< 	 ee ed< 	 eed  ed< dS )z&Person.Verification.AdditionalDocumentr   backdetailsdetails_codefrontNr   r   r   r	   r   r   r   r   r   r   r   AdditionalDocumentI     
 r   c                   @   r   )zPerson.Verification.Documentr   r   r   r   r   Nr   r   r   r   r   Document[  r   r   additional_documentr   r   documentstatus)r   r   N)
r   r   r   r   r   r   r	   r   r   r   r   r   r   r   VerificationH  s   
 
r   r   additional_tos_acceptancesaddressaddress_kanaaddress_kanjicreatedTdeleteddobemail
first_namefirst_name_kanafirst_name_kanjifull_name_aliasesfuture_requirementsgenderidid_number_providedid_number_secondary_provided	last_namelast_name_kanalast_name_kanjimaiden_namemetadatanationalityobjectphone)existingnonepolitical_exposureregistered_addressrelationshiprequirementsssn_last_4_providedus_cfpb_dataverificationc                 C   s@   | j }| j}tj }|d usJ t|}t|}d|||f S )Nz%s/%s/persons/%s)r   r   striper   	class_urlr   )selftokenr   base	acct_extnextnr   r   r   instance_url  s   
zPerson.instance_urlc                 K      t d)NzCan't modify a person without an account ID. Use stripe.Account.modify_person('account_id', 'person_id', ...) (see https://stripe.com/docs/api/persons/update).NotImplementedError)clssidparamsr   r   r   modify     zPerson.modifyc                 K   r  )NzCan't retrieve a person without an account ID. Use stripe.Account.retrieve_person('account_id', 'person_id') (see https://stripe.com/docs/api/persons/retrieve).r  )r  r   r   r   r   r   retrieve  r"  zPerson.retrieve)r   r   r   r   r   r   r  r  r  r  r  N)r   r   r   __doc__r   r   r
   r   r   r   r(   r,   r.   r2   r   r   r   r   r   r   r	   r   r   r   r   r   r  classmethodr!  r#  r   r   r   r   r   r      s   
  " O;	


r   )r  stripe._expandable_fieldr   stripe._stripe_objectr   stripe._updateable_api_resourcer   stripe._utilr   typingr   r   r   r	   typing_extensionsr
   r   stripe._filer   r   r   r   r   r   <module>   s   