# coding: utf-8

"""
    The Selling Partner API for Invoices.

    Use the Selling Partner API for Invoices to retrieve and manage invoice-related operations, which can help selling partners manage their bookkeeping processes.

    The version of the OpenAPI document: 2024-06-19
    Generated by OpenAPI Generator (https://openapi-generator.tech)

    Do not edit the class manually.
"""  # noqa: E501


import pprint
import re  # noqa: F401

import six

from spapi.configuration import Configuration


class ExportInvoicesRequest(object):
    """NOTE: This class is auto generated by the swagger code generator program.

    Do not edit the class manually.
    """

    """
    Attributes:
      swagger_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.
    """
    swagger_types = {
        'date_end': 'date',
        'date_start': 'date',
        'external_invoice_id': 'str',
        'file_format': 'FileFormat',
        'invoice_type': 'str',
        'marketplace_id': 'str',
        'series': 'str',
        'statuses': 'List[str]',
        'transaction_identifier': 'TransactionIdentifier',
        'transaction_type': 'str',
    }

    attribute_map = {
        'date_end': 'dateEnd',
        'date_start': 'dateStart',
        'external_invoice_id': 'externalInvoiceId',
        'file_format': 'fileFormat',
        'invoice_type': 'invoiceType',
        'marketplace_id': 'marketplaceId',
        'series': 'series',
        'statuses': 'statuses',
        'transaction_identifier': 'transactionIdentifier',
        'transaction_type': 'transactionType',
    }

    def __init__(self, date_end=None, date_start=None, external_invoice_id=None, file_format=None, invoice_type=None, marketplace_id=None, series=None, statuses=None, transaction_identifier=None, transaction_type=None, _configuration=None):  # noqa: E501
        """ExportInvoicesRequest - a model defined in Swagger"""  # noqa: E501
        if _configuration is None:
            _configuration = Configuration()
        self._configuration = _configuration

        self._date_end = None
        self._date_start = None
        self._external_invoice_id = None
        self._file_format = None
        self._invoice_type = None
        self._marketplace_id = None
        self._series = None
        self._statuses = None
        self._transaction_identifier = None
        self._transaction_type = None
        self.discriminator = None

        if date_end is not None:
            self.date_end = date_end
        if date_start is not None:
            self.date_start = date_start
        if external_invoice_id is not None:
            self.external_invoice_id = external_invoice_id
        if file_format is not None:
            self.file_format = file_format
        if invoice_type is not None:
            self.invoice_type = invoice_type
        self.marketplace_id = marketplace_id
        if series is not None:
            self.series = series
        if statuses is not None:
            self.statuses = statuses
        if transaction_identifier is not None:
            self.transaction_identifier = transaction_identifier
        if transaction_type is not None:
            self.transaction_type = transaction_type

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

        The latest invoice creation date for invoices that you want to include in the response. Dates are in [ISO 8601](https://developer-docs.amazon.com/sp-api/docs/iso-8601) date-time format. The default is the time of the request.  # noqa: E501

        :return: The date_end of this ExportInvoicesRequest.  # noqa: E501
        :rtype: date
        """
        return self._date_end

    @date_end.setter
    def date_end(self, date_end):
        """Sets the date_end of this ExportInvoicesRequest.

        The latest invoice creation date for invoices that you want to include in the response. Dates are in [ISO 8601](https://developer-docs.amazon.com/sp-api/docs/iso-8601) date-time format. The default is the time of the request.  # noqa: E501

        :param date_end: The date_end of this ExportInvoicesRequest.  # noqa: E501
        :type: date
        """

        self._date_end = date_end

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

        The earliest invoice creation date for invoices that you want to include in the response. Dates are in [ISO 8601](https://developer-docs.amazon.com/sp-api/docs/iso-8601) date-time format. The default is 24 hours prior to the time of the request.  # noqa: E501

        :return: The date_start of this ExportInvoicesRequest.  # noqa: E501
        :rtype: date
        """
        return self._date_start

    @date_start.setter
    def date_start(self, date_start):
        """Sets the date_start of this ExportInvoicesRequest.

        The earliest invoice creation date for invoices that you want to include in the response. Dates are in [ISO 8601](https://developer-docs.amazon.com/sp-api/docs/iso-8601) date-time format. The default is 24 hours prior to the time of the request.  # noqa: E501

        :param date_start: The date_start of this ExportInvoicesRequest.  # noqa: E501
        :type: date
        """

        self._date_start = date_start

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

        The external ID of the invoices you want included in the response.  # noqa: E501

        :return: The external_invoice_id of this ExportInvoicesRequest.  # noqa: E501
        :rtype: str
        """
        return self._external_invoice_id

    @external_invoice_id.setter
    def external_invoice_id(self, external_invoice_id):
        """Sets the external_invoice_id of this ExportInvoicesRequest.

        The external ID of the invoices you want included in the response.  # noqa: E501

        :param external_invoice_id: The external_invoice_id of this ExportInvoicesRequest.  # noqa: E501
        :type: str
        """

        self._external_invoice_id = external_invoice_id

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


        :return: The file_format of this ExportInvoicesRequest.  # noqa: E501
        :rtype: FileFormat
        """
        return self._file_format

    @file_format.setter
    def file_format(self, file_format):
        """Sets the file_format of this ExportInvoicesRequest.


        :param file_format: The file_format of this ExportInvoicesRequest.  # noqa: E501
        :type: FileFormat
        """

        self._file_format = file_format

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

        The marketplace-specific classification of the invoice type. Use the `getInvoicesAttributes` operation to check `invoiceType` options.  # noqa: E501

        :return: The invoice_type of this ExportInvoicesRequest.  # noqa: E501
        :rtype: str
        """
        return self._invoice_type

    @invoice_type.setter
    def invoice_type(self, invoice_type):
        """Sets the invoice_type of this ExportInvoicesRequest.

        The marketplace-specific classification of the invoice type. Use the `getInvoicesAttributes` operation to check `invoiceType` options.  # noqa: E501

        :param invoice_type: The invoice_type of this ExportInvoicesRequest.  # noqa: E501
        :type: str
        """

        self._invoice_type = invoice_type

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

        The ID of the marketplace from which you want the invoices.  # noqa: E501

        :return: The marketplace_id of this ExportInvoicesRequest.  # noqa: E501
        :rtype: str
        """
        return self._marketplace_id

    @marketplace_id.setter
    def marketplace_id(self, marketplace_id):
        """Sets the marketplace_id of this ExportInvoicesRequest.

        The ID of the marketplace from which you want the invoices.  # noqa: E501

        :param marketplace_id: The marketplace_id of this ExportInvoicesRequest.  # noqa: E501
        :type: str
        """
        if self._configuration.client_side_validation and marketplace_id is None:
            raise ValueError("Invalid value for `marketplace_id`, must not be `None`")  # noqa: E501

        self._marketplace_id = marketplace_id

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

        The series number of the invoices you want included in the response.  # noqa: E501

        :return: The series of this ExportInvoicesRequest.  # noqa: E501
        :rtype: str
        """
        return self._series

    @series.setter
    def series(self, series):
        """Sets the series of this ExportInvoicesRequest.

        The series number of the invoices you want included in the response.  # noqa: E501

        :param series: The series of this ExportInvoicesRequest.  # noqa: E501
        :type: str
        """

        self._series = series

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

        A list of statuses that you can use to filter invoices. Use the `getInvoicesAttributes` operation to check invoice status options.  Min count: 1  # noqa: E501

        :return: The statuses of this ExportInvoicesRequest.  # noqa: E501
        :rtype: List[str]
        """
        return self._statuses

    @statuses.setter
    def statuses(self, statuses):
        """Sets the statuses of this ExportInvoicesRequest.

        A list of statuses that you can use to filter invoices. Use the `getInvoicesAttributes` operation to check invoice status options.  Min count: 1  # noqa: E501

        :param statuses: The statuses of this ExportInvoicesRequest.  # noqa: E501
        :type: List[str]
        """
        if (self._configuration.client_side_validation and
                statuses is not None and len(statuses) < 1):
            raise ValueError("Invalid value for `statuses`, number of items must be greater than or equal to `1`")  # noqa: E501

        self._statuses = statuses

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


        :return: The transaction_identifier of this ExportInvoicesRequest.  # noqa: E501
        :rtype: TransactionIdentifier
        """
        return self._transaction_identifier

    @transaction_identifier.setter
    def transaction_identifier(self, transaction_identifier):
        """Sets the transaction_identifier of this ExportInvoicesRequest.


        :param transaction_identifier: The transaction_identifier of this ExportInvoicesRequest.  # noqa: E501
        :type: TransactionIdentifier
        """

        self._transaction_identifier = transaction_identifier

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

        The marketplace-specific classification of the transaction type for which the invoice was created. Use the `getInvoicesAttributes` operation to check `transactionType` options  # noqa: E501

        :return: The transaction_type of this ExportInvoicesRequest.  # noqa: E501
        :rtype: str
        """
        return self._transaction_type

    @transaction_type.setter
    def transaction_type(self, transaction_type):
        """Sets the transaction_type of this ExportInvoicesRequest.

        The marketplace-specific classification of the transaction type for which the invoice was created. Use the `getInvoicesAttributes` operation to check `transactionType` options  # noqa: E501

        :param transaction_type: The transaction_type of this ExportInvoicesRequest.  # noqa: E501
        :type: str
        """

        self._transaction_type = transaction_type

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

        for attr, _ in six.iteritems(self.swagger_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
        if issubclass(ExportInvoicesRequest, dict):
            for key, value in self.items():
                result[key] = 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, ExportInvoicesRequest):
            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, ExportInvoicesRequest):
            return True

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