<reponame>talon-one/talon_one.py
# coding: utf-8

"""
    Talon.One API

    The Talon.One API is used to manage applications and campaigns, as well as to integrate with your application. The operations in the _Integration API_ section are used to integrate with our platform, while the other operations are used to manage applications and campaigns.  ### Where is the API?  The API is available at the same hostname as these docs. For example, if you are reading this page at `https://mycompany.talon.one/docs/api/`, the URL for the [updateCustomerProfile][] operation is `https://mycompany.talon.one/v1/customer_profiles/id`  [updateCustomerProfile]: #operation--v1-customer_profiles--integrationId--put   # noqa: E501

    The version of the OpenAPI document: 1.0.0
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six

from talon_one.configuration import Configuration


class CustomerAnalytics(object):
    """NOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """

    """
    Attributes:
      openapi_types (dict): The key is attribute name
                            and the value is attribute type.
      attribute_map (dict): The key is attribute name
                            and the value is json key in definition.
    """
    openapi_types = {
        'accepted_coupons': 'int',
        'created_coupons': 'int',
        'free_items': 'int',
        'total_orders': 'int',
        'total_discounted_orders': 'int',
        'total_revenue': 'float',
        'total_discounts': 'float'
    }

    attribute_map = {
        'accepted_coupons': 'acceptedCoupons',
        'created_coupons': 'createdCoupons',
        'free_items': 'freeItems',
        'total_orders': 'totalOrders',
        'total_discounted_orders': 'totalDiscountedOrders',
        'total_revenue': 'totalRevenue',
        'total_discounts': 'totalDiscounts'
    }

    def __init__(self, accepted_coupons=None, created_coupons=None, free_items=None, total_orders=None, total_discounted_orders=None, total_revenue=None, total_discounts=None, local_vars_configuration=None):  # noqa: E501
        """CustomerAnalytics - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration()
        self.local_vars_configuration = local_vars_configuration

        self._accepted_coupons = None
        self._created_coupons = None
        self._free_items = None
        self._total_orders = None
        self._total_discounted_orders = None
        self._total_revenue = None
        self._total_discounts = None
        self.discriminator = None

        self.accepted_coupons = accepted_coupons
        self.created_coupons = created_coupons
        self.free_items = free_items
        self.total_orders = total_orders
        self.total_discounted_orders = total_discounted_orders
        self.total_revenue = total_revenue
        self.total_discounts = total_discounts

    @property
    def accepted_coupons(self):
        """Gets the accepted_coupons of this CustomerAnalytics.  # noqa: E501

        Total accepted coupons for this customer  # noqa: E501

        :return: The accepted_coupons of this CustomerAnalytics.  # noqa: E501
        :rtype: int
        """
        return self._accepted_coupons

    @accepted_coupons.setter
    def accepted_coupons(self, accepted_coupons):
        """Sets the accepted_coupons of this CustomerAnalytics.

        Total accepted coupons for this customer  # noqa: E501

        :param accepted_coupons: The accepted_coupons of this CustomerAnalytics.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and accepted_coupons is None:  # noqa: E501
            raise ValueError("Invalid value for `accepted_coupons`, must not be `None`")  # noqa: E501

        self._accepted_coupons = accepted_coupons

    @property
    def created_coupons(self):
        """Gets the created_coupons of this CustomerAnalytics.  # noqa: E501

        Total created coupons for this customer  # noqa: E501

        :return: The created_coupons of this CustomerAnalytics.  # noqa: E501
        :rtype: int
        """
        return self._created_coupons

    @created_coupons.setter
    def created_coupons(self, created_coupons):
        """Sets the created_coupons of this CustomerAnalytics.

        Total created coupons for this customer  # noqa: E501

        :param created_coupons: The created_coupons of this CustomerAnalytics.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and created_coupons is None:  # noqa: E501
            raise ValueError("Invalid value for `created_coupons`, must not be `None`")  # noqa: E501

        self._created_coupons = created_coupons

    @property
    def free_items(self):
        """Gets the free_items of this CustomerAnalytics.  # noqa: E501

        Total free items given to this customer  # noqa: E501

        :return: The free_items of this CustomerAnalytics.  # noqa: E501
        :rtype: int
        """
        return self._free_items

    @free_items.setter
    def free_items(self, free_items):
        """Sets the free_items of this CustomerAnalytics.

        Total free items given to this customer  # noqa: E501

        :param free_items: The free_items of this CustomerAnalytics.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and free_items is None:  # noqa: E501
            raise ValueError("Invalid value for `free_items`, must not be `None`")  # noqa: E501

        self._free_items = free_items

    @property
    def total_orders(self):
        """Gets the total_orders of this CustomerAnalytics.  # noqa: E501

        Total orders made by this customer  # noqa: E501

        :return: The total_orders of this CustomerAnalytics.  # noqa: E501
        :rtype: int
        """
        return self._total_orders

    @total_orders.setter
    def total_orders(self, total_orders):
        """Sets the total_orders of this CustomerAnalytics.

        Total orders made by this customer  # noqa: E501

        :param total_orders: The total_orders of this CustomerAnalytics.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and total_orders is None:  # noqa: E501
            raise ValueError("Invalid value for `total_orders`, must not be `None`")  # noqa: E501

        self._total_orders = total_orders

    @property
    def total_discounted_orders(self):
        """Gets the total_discounted_orders of this CustomerAnalytics.  # noqa: E501

        Total orders made by this customer that had a discount  # noqa: E501

        :return: The total_discounted_orders of this CustomerAnalytics.  # noqa: E501
        :rtype: int
        """
        return self._total_discounted_orders

    @total_discounted_orders.setter
    def total_discounted_orders(self, total_discounted_orders):
        """Sets the total_discounted_orders of this CustomerAnalytics.

        Total orders made by this customer that had a discount  # noqa: E501

        :param total_discounted_orders: The total_discounted_orders of this CustomerAnalytics.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and total_discounted_orders is None:  # noqa: E501
            raise ValueError("Invalid value for `total_discounted_orders`, must not be `None`")  # noqa: E501

        self._total_discounted_orders = total_discounted_orders

    @property
    def total_revenue(self):
        """Gets the total_revenue of this CustomerAnalytics.  # noqa: E501

        Total Revenue across all closed sessions  # noqa: E501

        :return: The total_revenue of this CustomerAnalytics.  # noqa: E501
        :rtype: float
        """
        return self._total_revenue

    @total_revenue.setter
    def total_revenue(self, total_revenue):
        """Sets the total_revenue of this CustomerAnalytics.

        Total Revenue across all closed sessions  # noqa: E501

        :param total_revenue: The total_revenue of this CustomerAnalytics.  # noqa: E501
        :type: float
        """
        if self.local_vars_configuration.client_side_validation and total_revenue is None:  # noqa: E501
            raise ValueError("Invalid value for `total_revenue`, must not be `None`")  # noqa: E501

        self._total_revenue = total_revenue

    @property
    def total_discounts(self):
        """Gets the total_discounts of this CustomerAnalytics.  # noqa: E501

        The sum of discounts that were given across all closed sessions  # noqa: E501

        :return: The total_discounts of this CustomerAnalytics.  # noqa: E501
        :rtype: float
        """
        return self._total_discounts

    @total_discounts.setter
    def total_discounts(self, total_discounts):
        """Sets the total_discounts of this CustomerAnalytics.

        The sum of discounts that were given across all closed sessions  # noqa: E501

        :param total_discounts: The total_discounts of this CustomerAnalytics.  # noqa: E501
        :type: float
        """
        if self.local_vars_configuration.client_side_validation and total_discounts is None:  # noqa: E501
            raise ValueError("Invalid value for `total_discounts`, must not be `None`")  # noqa: E501

        self._total_discounts = total_discounts

    def to_dict(self):
        """Returns the model properties as a dict"""
        result = {}

        for attr, _ in six.iteritems(self.openapi_types):
            value = getattr(self, attr)
            if isinstance(value, list):
                result[attr] = list(map(
                    lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
                    value
                ))
            elif hasattr(value, "to_dict"):
                result[attr] = value.to_dict()
            elif isinstance(value, dict):
                result[attr] = dict(map(
                    lambda item: (item[0], item[1].to_dict())
                    if hasattr(item[1], "to_dict") else item,
                    value.items()
                ))
            else:
                result[attr] = value

        return result

    def to_str(self):
        """Returns the string representation of the model"""
        return pprint.pformat(self.to_dict())

    def __repr__(self):
        """For `print` and `pprint`"""
        return self.to_str()

    def __eq__(self, other):
        """Returns true if both objects are equal"""
        if not isinstance(other, CustomerAnalytics):
            return False

        return self.to_dict() == other.to_dict()

    def __ne__(self, other):
        """Returns true if both objects are not equal"""
        if not isinstance(other, CustomerAnalytics):
            return True

        return self.to_dict() != other.to_dict()

# coding: utf-8

"""
    Talon.One API

    The Talon.One API is used to manage applications and campaigns, as well as to integrate with your application. The operations in the _Integration API_ section are used to integrate with our platform, while the other operations are used to manage applications and campaigns.  ### Where is the API?  The API is available at the same hostname as these docs. For example, if you are reading this page at `https://mycompany.talon.one/docs/api/`, the URL for the [updateCustomerProfile][] operation is `https://mycompany.talon.one/v1/customer_profiles/id`  [updateCustomerProfile]: #operation--v1-customer_profiles--integrationId--put   # noqa: E501

    The version of the OpenAPI document: 1.0.0
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six

from talon_one.configuration import Configuration


class CustomerAnalytics(object):
    """NOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """

    """
    Attributes:
      openapi_types (dict): The key is attribute name
                            and the value is attribute type.
      attribute_map (dict): The key is attribute name
                            and the value is json key in definition.
    """
    openapi_types = {
        'accepted_coupons': 'int',
        'created_coupons': 'int',
        'free_items': 'int',
        'total_orders': 'int',
        'total_discounted_orders': 'int',
        'total_revenue': 'float',
        'total_discounts': 'float'
    }

    attribute_map = {
        'accepted_coupons': 'acceptedCoupons',
        'created_coupons': 'createdCoupons',
        'free_items': 'freeItems',
        'total_orders': 'totalOrders',
        'total_discounted_orders': 'totalDiscountedOrders',
        'total_revenue': 'totalRevenue',
        'total_discounts': 'totalDiscounts'
    }

    def __init__(self, accepted_coupons=None, created_coupons=None, free_items=None, total_orders=None, total_discounted_orders=None, total_revenue=None, total_discounts=None, local_vars_configuration=None):  # noqa: E501
        """CustomerAnalytics - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration()
        self.local_vars_configuration = local_vars_configuration

        self._accepted_coupons = None
        self._created_coupons = None
        self._free_items = None
        self._total_orders = None
        self._total_discounted_orders = None
        self._total_revenue = None
        self._total_discounts = None
        self.discriminator = None

        self.accepted_coupons = accepted_coupons
        self.created_coupons = created_coupons
        self.free_items = free_items
        self.total_orders = total_orders
        self.total_discounted_orders = total_discounted_orders
        self.total_revenue = total_revenue
        self.total_discounts = total_discounts

    @property
    def accepted_coupons(self):
        """Gets the accepted_coupons of this CustomerAnalytics.  # noqa: E501

        Total accepted coupons for this customer  # noqa: E501

        :return: The accepted_coupons of this CustomerAnalytics.  # noqa: E501
        :rtype: int
        """
        return self._accepted_coupons

    @accepted_coupons.setter
    def accepted_coupons(self, accepted_coupons):
        """Sets the accepted_coupons of this CustomerAnalytics.

        Total accepted coupons for this customer  # noqa: E501

        :param accepted_coupons: The accepted_coupons of this CustomerAnalytics.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and accepted_coupons is None:  # noqa: E501
            raise ValueError("Invalid value for `accepted_coupons`, must not be `None`")  # noqa: E501

        self._accepted_coupons = accepted_coupons

    @property
    def created_coupons(self):
        """Gets the created_coupons of this CustomerAnalytics.  # noqa: E501

        Total created coupons for this customer  # noqa: E501

        :return: The created_coupons of this CustomerAnalytics.  # noqa: E501
        :rtype: int
        """
        return self._created_coupons

    @created_coupons.setter
    def created_coupons(self, created_coupons):
        """Sets the created_coupons of this CustomerAnalytics.

        Total created coupons for this customer  # noqa: E501

        :param created_coupons: The created_coupons of this CustomerAnalytics.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and created_coupons is None:  # noqa: E501
            raise ValueError("Invalid value for `created_coupons`, must not be `None`")  # noqa: E501

        self._created_coupons = created_coupons

    @property
    def free_items(self):
        """Gets the free_items of this CustomerAnalytics.  # noqa: E501

        Total free items given to this customer  # noqa: E501

        :return: The free_items of this CustomerAnalytics.  # noqa: E501
        :rtype: int
        """
        return self._free_items

    @free_items.setter
    def free_items(self, free_items):
        """Sets the free_items of this CustomerAnalytics.

        Total free items given to this customer  # noqa: E501

        :param free_items: The free_items of this CustomerAnalytics.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and free_items is None:  # noqa: E501
            raise ValueError("Invalid value for `free_items`, must not be `None`")  # noqa: E501

        self._free_items = free_items

    @property
    def total_orders(self):
        """Gets the total_orders of this CustomerAnalytics.  # noqa: E501

        Total orders made by this customer  # noqa: E501

        :return: The total_orders of this CustomerAnalytics.  # noqa: E501
        :rtype: int
        """
        return self._total_orders

    @total_orders.setter
    def total_orders(self, total_orders):
        """Sets the total_orders of this CustomerAnalytics.

        Total orders made by this customer  # noqa: E501

        :param total_orders: The total_orders of this CustomerAnalytics.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and total_orders is None:  # noqa: E501
            raise ValueError("Invalid value for `total_orders`, must not be `None`")  # noqa: E501

        self._total_orders = total_orders

    @property
    def total_discounted_orders(self):
        """Gets the total_discounted_orders of this CustomerAnalytics.  # noqa: E501

        Total orders made by this customer that had a discount  # noqa: E501

        :return: The total_discounted_orders of this CustomerAnalytics.  # noqa: E501
        :rtype: int
        """
        return self._total_discounted_orders

    @total_discounted_orders.setter
    def total_discounted_orders(self, total_discounted_orders):
        """Sets the total_discounted_orders of this CustomerAnalytics.

        Total orders made by this customer that had a discount  # noqa: E501

        :param total_discounted_orders: The total_discounted_orders of this CustomerAnalytics.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and total_discounted_orders is None:  # noqa: E501
            raise ValueError("Invalid value for `total_discounted_orders`, must not be `None`")  # noqa: E501

        self._total_discounted_orders = total_discounted_orders

    @property
    def total_revenue(self):
        """Gets the total_revenue of this CustomerAnalytics.  # noqa: E501

        Total Revenue across all closed sessions  # noqa: E501

        :return: The total_revenue of this CustomerAnalytics.  # noqa: E501
        :rtype: float
        """
        return self._total_revenue

    @total_revenue.setter
    def total_revenue(self, total_revenue):
        """Sets the total_revenue of this CustomerAnalytics.

        Total Revenue across all closed sessions  # noqa: E501

        :param total_revenue: The total_revenue of this CustomerAnalytics.  # noqa: E501
        :type: float
        """
        if self.local_vars_configuration.client_side_validation and total_revenue is None:  # noqa: E501
            raise ValueError("Invalid value for `total_revenue`, must not be `None`")  # noqa: E501

        self._total_revenue = total_revenue

    @property
    def total_discounts(self):
        """Gets the total_discounts of this CustomerAnalytics.  # noqa: E501

        The sum of discounts that were given across all closed sessions  # noqa: E501

        :return: The total_discounts of this CustomerAnalytics.  # noqa: E501
        :rtype: float
        """
        return self._total_discounts

    @total_discounts.setter
    def total_discounts(self, total_discounts):
        """Sets the total_discounts of this CustomerAnalytics.

        The sum of discounts that were given across all closed sessions  # noqa: E501

        :param total_discounts: The total_discounts of this CustomerAnalytics.  # noqa: E501
        :type: float
        """
        if self.local_vars_configuration.client_side_validation and total_discounts is None:  # noqa: E501
            raise ValueError("Invalid value for `total_discounts`, must not be `None`")  # noqa: E501

        self._total_discounts = total_discounts

    def to_dict(self):
        """Returns the model properties as a dict"""
        result = {}

        for attr, _ in six.iteritems(self.openapi_types):
            value = getattr(self, attr)
            if isinstance(value, list):
                result[attr] = list(map(
                    lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
                    value
                ))
            elif hasattr(value, "to_dict"):
                result[attr] = value.to_dict()
            elif isinstance(value, dict):
                result[attr] = dict(map(
                    lambda item: (item[0], item[1].to_dict())
                    if hasattr(item[1], "to_dict") else item,
                    value.items()
                ))
            else:
                result[attr] = value

        return result

    def to_str(self):
        """Returns the string representation of the model"""
        return pprint.pformat(self.to_dict())

    def __repr__(self):
        """For `print` and `pprint`"""
        return self.to_str()

    def __eq__(self, other):
        """Returns true if both objects are equal"""
        if not isinstance(other, CustomerAnalytics):
            return False

        return self.to_dict() == other.to_dict()

    def __ne__(self, other):
        """Returns true if both objects are not equal"""
        if not isinstance(other, CustomerAnalytics):
            return True

        return self.to_dict() != other.to_dict()
# coding: utf-8 Talon.One API      The Talon.One API is used to manage applications and campaigns, as well as to integrate with your application. The operations in the _Integration API_ section are used to integrate with our platform, while the other operations are used to manage applications and campaigns.  ### Where is the API?  The API is available at the same hostname as these docs. For example, if you are reading this page at `https://mycompany.talon.one/docs/api/`, the URL for the [updateCustomerProfile][] operation is `https://mycompany.talon.one/v1/customer_profiles/id`  [updateCustomerProfile]: #operation--v1-customer_profiles--integrationId--put   # noqa: E501      The version of the OpenAPI document: 1.0.0     Generated by: https://openapi-generator.tech # noqa: F401 NOTE: This class is auto generated by OpenAPI Generator.     Ref: https://openapi-generator.tech      Do not edit the class manually. Attributes:       openapi_types (dict): The key is attribute name                             and the value is attribute type.       attribute_map (dict): The key is attribute name                             and the value is json key in definition. # noqa: E501 CustomerAnalytics - a model defined in OpenAPI # noqa: E501 Gets the accepted_coupons of this CustomerAnalytics.  # noqa: E501          Total accepted coupons for this customer  # noqa: E501          :return: The accepted_coupons of this CustomerAnalytics.  # noqa: E501         :rtype: int Sets the accepted_coupons of this CustomerAnalytics.          Total accepted coupons for this customer  # noqa: E501          :param accepted_coupons: The accepted_coupons of this CustomerAnalytics.  # noqa: E501         :type: int # noqa: E501 # noqa: E501 Gets the created_coupons of this CustomerAnalytics.  # noqa: E501          Total created coupons for this customer  # noqa: E501          :return: The created_coupons of this CustomerAnalytics.  # noqa: E501         :rtype: int Sets the created_coupons of this CustomerAnalytics.          Total created coupons for this customer  # noqa: E501          :param created_coupons: The created_coupons of this CustomerAnalytics.  # noqa: E501         :type: int # noqa: E501 # noqa: E501 Gets the free_items of this CustomerAnalytics.  # noqa: E501          Total free items given to this customer  # noqa: E501          :return: The free_items of this CustomerAnalytics.  # noqa: E501         :rtype: int Sets the free_items of this CustomerAnalytics.          Total free items given to this customer  # noqa: E501          :param free_items: The free_items of this CustomerAnalytics.  # noqa: E501         :type: int # noqa: E501 # noqa: E501 Gets the total_orders of this CustomerAnalytics.  # noqa: E501          Total orders made by this customer  # noqa: E501          :return: The total_orders of this CustomerAnalytics.  # noqa: E501         :rtype: int Sets the total_orders of this CustomerAnalytics.          Total orders made by this customer  # noqa: E501          :param total_orders: The total_orders of this CustomerAnalytics.  # noqa: E501         :type: int # noqa: E501 # noqa: E501 Gets the total_discounted_orders of this CustomerAnalytics.  # noqa: E501          Total orders made by this customer that had a discount  # noqa: E501          :return: The total_discounted_orders of this CustomerAnalytics.  # noqa: E501         :rtype: int Sets the total_discounted_orders of this CustomerAnalytics.          Total orders made by this customer that had a discount  # noqa: E501          :param total_discounted_orders: The total_discounted_orders of this CustomerAnalytics.  # noqa: E501         :type: int # noqa: E501 # noqa: E501 Gets the total_revenue of this CustomerAnalytics.  # noqa: E501          Total Revenue across all closed sessions  # noqa: E501          :return: The total_revenue of this CustomerAnalytics.  # noqa: E501         :rtype: float Sets the total_revenue of this CustomerAnalytics.          Total Revenue across all closed sessions  # noqa: E501          :param total_revenue: The total_revenue of this CustomerAnalytics.  # noqa: E501         :type: float # noqa: E501 # noqa: E501 Gets the total_discounts of this CustomerAnalytics.  # noqa: E501          The sum of discounts that were given across all closed sessions  # noqa: E501          :return: The total_discounts of this CustomerAnalytics.  # noqa: E501         :rtype: float Sets the total_discounts of this CustomerAnalytics.          The sum of discounts that were given across all closed sessions  # noqa: E501          :param total_discounts: The total_discounts of this CustomerAnalytics.  # noqa: E501         :type: float # noqa: E501 # noqa: E501 Returns the model properties as a dict Returns the string representation of the model For `print` and `pprint` Returns true if both objects are equal Returns true if both objects are not equal