o
    i                     @   s   d dl mZ d dlmZ d dlmZmZ d dlmZ erLd 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 deZdS )    )StripeService)sanitize_id)Optionalcast)TYPE_CHECKING)
ListObject)RequestOptions)LocationCreateParams)LocationDeleteParams)LocationListParams)LocationRetrieveParams)LocationUpdateParams)Locationc                	   @   s  e Zd Z		d"deded ded ddfd	d
Z		d"deded ded ddfddZ		d"deded ded ddfddZ		d"deded ded ddfddZ		d"deded ded ddfddZ			d"deded ded ddfddZ
		d"ded ded ddfddZ		d"ded ded ddfddZ		d"ded ded ddfddZ		d"ded ded ddfd d!ZdS )#LocationServiceNlocationparamsr
   optionsr   returnr   c              	   C   &   t d| jddjt|dd||dS ),
        Deletes a Location object.
        r   delete!/v1/terminal/locations/{location}r   apibase_addressr   r   r   _requestformatr   selfr   r   r    r!   /var/www/snowflake_co_dev_github/snow_flake_back_end_deploy/env/lib/python3.10/site-packages/stripe/terminal/_location_service.pyr         	zLocationService.deletec              	      .   t d| jddjt|dd||dI dH S )r   r   r   r   r   r   r   Nr   _request_asyncr   r   r   r!   r!   r"   delete_async2      	
zLocationService.delete_asyncr   c              	   C   r   ).
        Retrieves a Location object.
        r   getr   r   r   r   r   r   r!   r!   r"   retrieveH   r#   zLocationService.retrievec              	      r$   )r)   r   r*   r   r   r   r   Nr%   r   r!   r!   r"   retrieve_async^   r(   zLocationService.retrieve_asyncr   c              	   C   r   )
        Updates a Location object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
        r   postr   r   r   r   r   r   r!   r!   r"   updatet   r#   zLocationService.updatec              	      r$   )r-   r   r.   r   r   r   r   Nr%   r   r!   r!   r"   update_async   r(   zLocationService.update_asyncr   ListObject[Location]c              	   C      t d| jddd||dS )5
        Returns a list of Location objects.
        r1   r*   /v1/terminal/locationsr   r   r   r   r    r   r   r!   r!   r"   list   s   zLocationService.listc              	      "   t d| jddd||dI dH S )r3   r1   r*   r4   r   r   Nr   r&   r6   r!   r!   r"   
list_async   s   
zLocationService.list_asyncr	   c              	   C   r2   )
        Creates a new Location object.
        For further details, including which address fields are required in each country, see the [Manage locations](https://docs.stripe.com/docs/terminal/fleet/locations) guide.
        r   r.   r4   r   r   r5   r6   r!   r!   r"   create   s   	zLocationService.createc              	      r8   )r;   r   r.   r4   r   r   Nr9   r6   r!   r!   r"   create_async   s   	
zLocationService.create_async)NN)__name__
__module____qualname__strr   r   r'   r+   r,   r/   r0   r7   r:   r<   r=   r!   r!   r!   r"   r      s    








r   N)stripe._stripe_servicer   stripe._utilr   typingr   r   typing_extensionsr   stripe._list_objectr   stripe._request_optionsr   .stripe.params.terminal._location_create_paramsr	   .stripe.params.terminal._location_delete_paramsr
   ,stripe.params.terminal._location_list_paramsr   0stripe.params.terminal._location_retrieve_paramsr   .stripe.params.terminal._location_update_paramsr   stripe.terminal._locationr   r   r!   r!   r!   r"   <module>   s   