o
    BiD                     @   st   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 d dlmZmZmZmZ G dd ded Zd	S )
    )
ListObject)ListableAPIResource)RequestOptions)StripeObject)ClassVarListOptional)LiteralNotRequired	TypedDictUnpackc                   @   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ee ed< 	 eed< 	 ee	 ed< 	 ee
 ed< 	 eed< 	 ee ed< 	 eed< 	 ed ed< 	 ee ed< ee ed< 	 ee ed < 	 ed! ed"< 	 ee ed#< 	 ee ed$< 	 ed%ed& d'ed  fd(d)Zed%ed& d'ed  fd*d+Zeded%ed, d'd fd-d.Zeded%ed, d'd fd/d0Ze	e
eeeed1Zd2S )3VerificationReporta@  
    A VerificationReport is the result of an attempt to collect and verify data from a user.
    The collection of verification checks performed is determined from the `type` and `options`
    parameters used. You can find the result of each verification check performed in the
    appropriate sub-resource: `document`, `id_number`, `selfie`.

    Each VerificationReport contains a copy of any data collected by the user as well as
    reference IDs which can be used to access collected images through the [FileUpload](https://stripe.com/docs/api/files)
    API. To configure and create VerificationReports, use the
    [VerificationSession](https://stripe.com/docs/api/identity/verification_sessions) API.

    Related guide: [Accessing verification results](https://stripe.com/docs/identity/verification-sessions#results).
    zidentity.verification_reportOBJECT_NAMEc                   @   s  e Zd ZU 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  e
d< 	 e	e e
d< 	 e	e e
d< 	 e	e e
d< 	 e	e e
d< 	 e	e e
d< 	 ed e
d< 	 e	ed  e
d< 	 eeeeedZdS )zVerificationReport.Documentc                   @   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< dS )z#VerificationReport.Document.Addresscitycountryline1line2postal_codestateN)__name__
__module____qualname__r   str__annotations__ r   r   d/var/www/html/Trade-python/venv/lib/python3.10/site-packages/stripe/identity/_verification_report.pyAddress   s   
 r   c                   @   6   e Zd ZU ee ed< 	 ee ed< 	 ee ed< dS )zVerificationReport.Document.DobdaymonthyearNr   r   r   r   intr   r   r   r   r   Dob9      
 r#   c                   @   ,   e Zd ZU eed  ed< 	 ee ed< dS )z!VerificationReport.Document.Error)document_expireddocument_type_not_supporteddocument_unverified_othercodereasonNr   r   r   r   r	   r   r   r   r   r   r   ErrorG      
 r,   c                   @   r   )z*VerificationReport.Document.ExpirationDater   r   r    Nr!   r   r   r   r   ExpirationDateW   r$   r.   c                   @   r   )z&VerificationReport.Document.IssuedDater   r   r    Nr!   r   r   r   r   
IssuedDatee   r$   r/   addressdoberrorexpiration_datefiles
first_nameissued_dateissuing_country	last_namenumber
unverifiedverifiedstatusdriving_licenseid_cardpassporttype)r0   r1   r2   r3   r6   N)r   r   r   r   r   r#   r,   r.   r/   r   r   r   r   r	   _inner_class_typesr   r   r   r   Document   sH   
 
rD   c                   @   sP   e Zd ZU G dd deZee ed< 	 ee ed< 	 ed ed< 	 deiZ	dS )zVerificationReport.Emailc                   @   r%   )zVerificationReport.Email.Error)email_unverified_otheremail_verification_declinedr)   r*   Nr+   r   r   r   r   r,         
 r,   emailr2   r:   r=   N
r   r   r   r   r,   r   r   r   r	   rC   r   r   r   r   Email      
 rJ   c                   @   s   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d
< 	 ee ed< 	 e	d ed< 	 eedZ
dS )zVerificationReport.IdNumberc                   @   r   )zVerificationReport.IdNumber.Dobr   r   r    Nr!   r   r   r   r   r#      r$   r#   c                   @   r%   )z!VerificationReport.IdNumber.Error)$id_number_insufficient_document_dataid_number_mismatchid_number_unverified_otherr)   r*   Nr+   r   r   r   r   r,      r-   r,   r1   r2   r5   	id_number)br_cpfsg_nricus_ssnid_number_typer8   r:   r=   )r1   r2   N)r   r   r   r   r#   r,   r   r   r   r	   rC   r   r   r   r   IdNumber   s$   
 rT   c                   @   sP   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dZdS )	zVerificationReport.Optionsc                   @   sL   e Zd ZU eeed   ed< 	 ee ed< 	 ee ed< 	 ee ed< dS )z#VerificationReport.Options.Documentr>   allowed_typesrequire_id_numberrequire_live_capturerequire_matching_selfieN)r   r   r   r   r   r	   r   boolr   r   r   r   rD     s   
 
rD   c                   @   s   e Zd ZdS )z#VerificationReport.Options.IdNumberN)r   r   r   r   r   r   r   rT     s    rT   documentrO   rZ   rO   N)	r   r   r   r   rD   rT   r   r   rC   r   r   r   r   Options  s   
 r\   c                   @   sP   e Zd ZU G dd deZee ed< 	 ee ed< 	 ed ed< 	 deiZ	dS )zVerificationReport.Phonec                   @   r%   )zVerificationReport.Phone.Error)phone_unverified_otherphone_verification_declinedr)   r*   Nr+   r   r   r   r   r,   "  rG   r,   r2   phoner:   r=   N)
r   r   r   r   r,   r   r   r   r	   rC   r   r   r   r   Phone!  rK   r`   c                   @   s^   e Zd ZU G dd deZee ed< 	 ee ed< 	 ee ed< 	 ed ed< 	 deiZ	dS )	zVerificationReport.Selfiec                   @   r%   )zVerificationReport.Selfie.Error)selfie_document_missing_photoselfie_face_mismatchselfie_manipulatedselfie_unverified_otherr)   r*   Nr+   r   r   r   r   r,   ?  s   
 r,   rZ   r2   selfier:   r=   NrI   r   r   r   r   Selfie>  s   
 rf   c                   @   s   e Zd ZU ee ed< 	 ed ed< 	 ee ed< 	 eee  ed< 	 ee ed< 	 ee ed< 	 eed  ed	< 	 ee ed
< dS )VerificationReport.ListParamsclient_reference_idz(VerificationReport.ListParamsCreated|intcreatedending_beforeexpandlimitstarting_afterr[   rB   verification_sessionN)	r   r   r   r
   r   r   r   r"   r	   r   r   r   r   
ListParamsb  s"   
 ro   c                   @   sD   e Zd ZU ee ed< 	 ee ed< 	 ee ed< 	 ee ed< dS )z$VerificationReport.ListParamsCreatedgtgteltlteN)r   r   r   r
   r"   r   r   r   r   r   ListParamsCreated  s   
 rt   c                   @   s   e Zd ZU eee  ed< dS )!VerificationReport.RetrieveParamsrk   N)r   r   r   r
   r   r   r   r   r   r   r   RetrieveParams  s   
 rv   rh   ri   rZ   rH   idrO   livemodeobjectoptionsr_   re   )rZ   rO   verification_flowrB   r{   rn   paramsrg   returnc                 K   s4   | j d|  |d}t|tstdt|j |S )0
        List all verification reports.
        getr|   %Expected list object from API, got %s)_static_request	class_url
isinstancer   	TypeErrorrB   r   clsr|   resultr   r   r   list  s   
zVerificationReport.listc                    s<   | j d|  |dI dH }t|tstdt|j |S )r~   r   r   Nr   )_static_request_asyncr   r   r   r   rB   r   r   r   r   r   
list_async  s   
zVerificationReport.list_asyncru   c                 K   s   | |fi |}|   |S ):
        Retrieves an existing VerificationReport
        )refreshr   rw   r|   instancer   r   r   retrieve  s   zVerificationReport.retrievec                    s$   | |fi |}|  I dH  |S )r   N)refresh_asyncr   r   r   r   retrieve_async  s   z!VerificationReport.retrieve_async)rZ   rH   rO   rz   r_   re   N) r   r   r   __doc__r   r   r	   r   r   rD   rJ   rT   r\   r`   rf   r   ro   r   rt   rv   r   r   r"   rY   classmethodr   r   r   r   r   r   rC   r   r   r   r   r      s   
  =$"

r   N)stripe._list_objectr   stripe._listable_api_resourcer   stripe._request_optionsr   stripe._stripe_objectr   typingr   r   r   typing_extensionsr	   r
   r   r   r   r   r   r   r   <module>   s   