o
    éË·eŸ  ã                   @   s0   d Z ddlmZ ddlmZ G dd„ deƒZdS )zÕ
The List Growth History API endpoint

Documentation: http://developer.mailchimp.com/documentation/mailchimp/reference/lists/growth-history/
Schema: https://api.mailchimp.com/schema/3.0/Lists/Growth/Instance.json
é    )Úunicode_literals)ÚBaseApic                       s2   e Zd ZdZ‡ fdd„Zd	dd„Zdd„ Z‡  ZS )
ÚListGrowthHistoryzS
    View a summary of the month-by-month growth activity for a specific list.
    c                    s,   t t| ƒj|i |¤Ž d| _d| _d| _dS )z)
        Initialize the endpoint
        ÚlistsN)Úsuperr   Ú__init__ÚendpointÚlist_idÚmonth)ÚselfÚargsÚkwargs©Ú	__class__© ú\/var/www/ideatree/venv/lib/python3.10/site-packages/mailchimp3/entities/listgrowthhistory.pyr      s   
zListGrowthHistory.__init__Fc                 K   sJ   || _ d| _|r| jdd|  |d¡i|¤ŽS | jjdd|  |d¡i|¤ŽS )uè  
        Get a month-by-month summary of a specific listâ€™s growth activity.

        :param list_id: The unique id for the list.
        :type list_id: :py:class:`str`
        :param get_all: Should the query get all results
        :type get_all: :py:class:`bool`
        :param queryparams: The query string parameters
        queryparams['fields'] = []
        queryparams['exclude_fields'] = []
        queryparams['count'] = integer
        queryparams['offset'] = integer
        NÚurlúgrowth-historyr   )r	   r
   Ú_iterateÚ_build_pathÚ
_mc_clientÚ_get)r   r	   Úget_allÚqueryparamsr   r   r   Úall   s
   zListGrowthHistory.allc                 K   s,   || _ || _| jjdd|  |d|¡i|¤ŽS )u«  
        Get a summary of a specific listâ€™s growth activity for a specific month and year.

        :param list_id: The unique id for the list.
        :type list_id: :py:class:`str`
        :param month: A specific month of list growth history.
        :type month: :py:class:`str`
        :param queryparams: The query string parameters
        queryparams['fields'] = []
        queryparams['exclude_fields'] = []
        r   r   Nr   )r	   r
   r   r   r   )r   r	   r
   r   r   r   r   Úget1   s    zListGrowthHistory.get)F)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   r   Ú__classcell__r   r   r   r   r      s
    

r   N)r   Ú
__future__r   Úmailchimp3.baseapir   r   r   r   r   r   Ú<module>   s   