
    Ai$!                         d dl mZ d dlmZ d dlmZmZ d dlmZ er0d dl	m
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 d dlmZ d dlmZ  G d de      Zy)    )StripeService)sanitize_id)Optionalcast)TYPE_CHECKING)
ListObject)RequestOptions)WebhookEndpoint)WebhookEndpointCreateParams)WebhookEndpointDeleteParams)WebhookEndpointListParams)WebhookEndpointRetrieveParams)WebhookEndpointUpdateParamsc            	          e Zd Z	 	 ddeded   ded   ddfd	Z	 	 ddeded   ded   ddfd
Z	 	 ddeded   ded   ddfdZ	 	 ddeded   ded   ddfdZ	 	 ddeded   ded   ddfdZ		 	 ddeded   ded   ddfdZ
	 	 dded   ded   ddfdZ	 	 dded   ded   ddfdZ	 dddded   ddfdZ	 dddded   ddfdZy)WebhookEndpointServiceNwebhook_endpointparamsr   optionsr	   returnr
   c                 t    t        d| j                  ddj                  t        |            d||            S )
        You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard.
        r
   delete(/v1/webhook_endpoints/{webhook_endpoint}r   apibase_addressr   r   r   _requestformatr   selfr   r   r   s       S/var/www/html/immo/lib/python3.12/site-packages/stripe/_webhook_endpoint_service.pyr   zWebhookEndpointService.delete   sP     MM:AA%01A%B B  #  
 	
    c                    K   t        d| j                  ddj                  t        |            d||       d{         S 7 w)r   r
   r   r   r   r   r   Nr   _request_asyncr    r   r!   s       r#   delete_asyncz#WebhookEndpointService.delete_async4   s`      %%:AA%01A%B B  # &  
 	
   9AA
	Ar   c                 t    t        d| j                  ddj                  t        |            d||            S )C
        Retrieves the webhook endpoint with the given ID.
        r
   getr   r   r   r   r   r!   s       r#   retrievezWebhookEndpointService.retrieveJ   sP     MM:AA%01A%B B  #  
 	
r$   c                    K   t        d| j                  ddj                  t        |            d||       d{         S 7 w)r+   r
   r,   r   r   r   r   Nr&   r!   s       r#   retrieve_asyncz%WebhookEndpointService.retrieve_async`   s`      %%:AA%01A%B B  # &  
 	
r)   r   c                 t    t        d| j                  ddj                  t        |            d||            S )
        Updates the webhook endpoint. You may edit the url, the list of enabled_events, and the status of your endpoint.
        r
   postr   r   r   r   r   r!   s       r#   updatezWebhookEndpointService.updatev   sP     MM:AA%01A%B B  #  
 	
r$   c                    K   t        d| j                  ddj                  t        |            d||       d{         S 7 w)r1   r
   r2   r   r   r   r   Nr&   r!   s       r#   update_asyncz#WebhookEndpointService.update_async   s`      %%:AA%01A%B B  # &  
 	
r)   r   ListObject[WebhookEndpoint]c           
      B    t        d| j                  ddd||            S );
        Returns a list of your webhook endpoints.
        r6   r,   /v1/webhook_endpointsr   r   r   r   r"   r   r   s      r#   listzWebhookEndpointService.list   s4     )MM'"  	
 		
r$   c           
      ^   K   t        d| j                  ddd||       d{         S 7 w)r8   r6   r,   r9   r   r   Nr   r'   r;   s      r#   
list_asyncz!WebhookEndpointService.list_async   sD      )%%'" &  	
 		
    -+
	-r   c           
      B    t        d| j                  ddd||            S )  
        A webhook endpoint must have a url and a list of enabled_events. You may optionally specify the Boolean connect parameter. If set to true, then a Connect webhook endpoint that notifies the specified url about events from all connected accounts is created; otherwise an account webhook endpoint that notifies the specified url only about events from your account is created. You can also create webhook endpoints in the [webhooks settings](https://dashboard.stripe.com/account/webhooks) section of the Dashboard.
        r
   r2   r9   r   r   r:   r;   s      r#   createzWebhookEndpointService.create   s4     MM'"  	
 		
r$   c           
      ^   K   t        d| j                  ddd||       d{         S 7 w)rB   r
   r2   r9   r   r   Nr>   r;   s      r#   create_asyncz#WebhookEndpointService.create_async   sD      %%'" &  	
 		
r@   )NN)N)__name__
__module____qualname__strr   r   r(   r-   r/   r3   r5   r<   r?   rC   rE    r$   r#   r   r      s@    ;?.2	

 67
 *+	

 

2 ;?.2	

 67
 *+	

 

2 =A.2	

 89
 *+	

 

2 =A.2	

 89
 *+	

 

2 ;?.2	

 67
 *+	

 

2 ;?.2	

 67
 *+	

 

0 9=.2
45
 *+
 
'	
* 9=.2
45
 *+
 
'	
, /3
-
 *+
 
	
, /3
-
 *+
 
	
r$   r   N)stripe._stripe_servicer   stripe._utilr   typingr   r   typing_extensionsr   stripe._list_objectr   stripe._request_optionsr	   stripe._webhook_endpointr
   -stripe.params._webhook_endpoint_create_paramsr   -stripe.params._webhook_endpoint_delete_paramsr   +stripe.params._webhook_endpoint_list_paramsr   /stripe.params._webhook_endpoint_retrieve_paramsr   -stripe.params._webhook_endpoint_update_paramsr   r   rJ   r$   r#   <module>rW      sF    1 $ ! +.68
O
] O
r$   