a
    ªˆ
f‰  ã                   @   s*   d dl mZ d dlmZ G dd„ dƒZdS )é   )ÚEventbriteService)ÚShopifyServicec                   @   s   e Zd ZdZedd„ ƒZdS )ÚIntegrationsServicezÂService to handle interaction with external integrations.

    This service manages the interaction with external integrations, such as Shopify and Eventbrite.

    Attributes:
        None
    c                 C   sŒ   |st dƒ d S |s t dƒ d S | d¡rPt |d d |d d |d d ¡S | d¡r„t |d d |d d	 |d d | |¡S d S d S )
NzMissing offer integration data.z Missing client integration data.ÚshopifyÚ	storeNameÚaccessTokenZpriceRuleIDZ
eventbriteZorganizationIDZeventID)ÚprintÚgetr   Úcreate_single_use_discount_coder   Zcreate_event_discount_code)Zdiscount_valueÚdiscount_typeZoffer_integration_dataZclient_integration_data© r   úR/var/www/html/python-backend/backend/services/integrations/integrations_service.pyr
      s*    



ý



û	z3IntegrationsService.create_single_use_discount_codeN)Ú__name__Ú
__module__Ú__qualname__Ú__doc__Ústaticmethodr
   r   r   r   r   r      s   r   N)Zeventbrite_servicer   Úshopify_servicer   r   r   r   r   r   Ú<module>   s   