From 46ad1c101fad3feebf7ec92feb0d37d62cd7e889 Mon Sep 17 00:00:00 2001 From: Sergio Abad Date: Mon, 22 Nov 2021 20:14:29 +0100 Subject: [PATCH 1/7] Sphinx installed and removed old module --- amazon/README.md | 123 --- amazon/__init__.py | 4 - amazon/constant.py | 241 ------ amazon/exception.py | 11 - amazon/paapi.py | 457 ---------- amazon/paapi5_python_sdk/COPYING.txt | 202 ----- amazon/paapi5_python_sdk/LICENSE.txt | 202 ----- amazon/paapi5_python_sdk/NOTICE.txt | 2 - amazon/paapi5_python_sdk/__init__.py | 123 --- amazon/paapi5_python_sdk/api/__init__.py | 29 - amazon/paapi5_python_sdk/api/default_api.py | 428 --------- amazon/paapi5_python_sdk/api_client.py | 685 --------------- amazon/paapi5_python_sdk/auth/__init__.py | 29 - amazon/paapi5_python_sdk/auth/sig_v4.py | 149 ---- amazon/paapi5_python_sdk/availability.py | 104 --- amazon/paapi5_python_sdk/browse_node.py | 285 ------ .../paapi5_python_sdk/browse_node_ancestor.py | 204 ----- amazon/paapi5_python_sdk/browse_node_child.py | 178 ---- .../paapi5_python_sdk/browse_node_children.py | 100 --- amazon/paapi5_python_sdk/browse_node_info.py | 155 ---- .../paapi5_python_sdk/browse_nodes_result.py | 128 --- amazon/paapi5_python_sdk/by_line_info.py | 181 ---- amazon/paapi5_python_sdk/classifications.py | 154 ---- amazon/paapi5_python_sdk/condition.py | 107 --- amazon/paapi5_python_sdk/configuration.py | 230 ----- amazon/paapi5_python_sdk/content_info.py | 208 ----- amazon/paapi5_python_sdk/content_rating.py | 128 --- amazon/paapi5_python_sdk/contributor.py | 178 ---- amazon/paapi5_python_sdk/delivery_flag.py | 106 --- .../dimension_based_attribute.py | 206 ----- amazon/paapi5_python_sdk/duration_price.py | 155 ---- amazon/paapi5_python_sdk/error_data.py | 152 ---- amazon/paapi5_python_sdk/external_ids.py | 180 ---- .../get_browse_nodes_request.py | 262 ------ .../get_browse_nodes_resource.py | 104 --- .../get_browse_nodes_response.py | 155 ---- amazon/paapi5_python_sdk/get_items_request.py | 423 --------- .../paapi5_python_sdk/get_items_resource.py | 157 ---- .../paapi5_python_sdk/get_items_response.py | 155 ---- .../get_variations_request.py | 448 ---------- .../get_variations_resource.py | 160 ---- .../get_variations_response.py | 155 ---- amazon/paapi5_python_sdk/image_size.py | 178 ---- amazon/paapi5_python_sdk/image_type.py | 180 ---- amazon/paapi5_python_sdk/images.py | 154 ---- amazon/paapi5_python_sdk/item.py | 367 -------- amazon/paapi5_python_sdk/item_id_type.py | 103 --- amazon/paapi5_python_sdk/item_info.py | 398 --------- amazon/paapi5_python_sdk/items_result.py | 128 --- amazon/paapi5_python_sdk/language_type.py | 152 ---- amazon/paapi5_python_sdk/languages.py | 180 ---- amazon/paapi5_python_sdk/manufacture_info.py | 180 ---- amazon/paapi5_python_sdk/max_price.py | 98 --- amazon/paapi5_python_sdk/merchant.py | 104 --- amazon/paapi5_python_sdk/min_price.py | 98 --- .../paapi5_python_sdk/min_reviews_rating.py | 98 --- .../paapi5_python_sdk/min_saving_percent.py | 98 --- .../multi_valued_attribute.py | 178 ---- .../paapi5_python_sdk/offer_availability.py | 203 ----- amazon/paapi5_python_sdk/offer_condition.py | 232 ----- amazon/paapi5_python_sdk/offer_count.py | 98 --- .../paapi5_python_sdk/offer_delivery_info.py | 206 ----- amazon/paapi5_python_sdk/offer_listing.py | 421 --------- .../paapi5_python_sdk/offer_loyalty_points.py | 126 --- .../paapi5_python_sdk/offer_merchant_info.py | 178 ---- amazon/paapi5_python_sdk/offer_price.py | 232 ----- .../offer_program_eligibility.py | 152 ---- amazon/paapi5_python_sdk/offer_promotion.py | 255 ------ amazon/paapi5_python_sdk/offer_savings.py | 230 ----- .../offer_shipping_charge.py | 229 ----- .../paapi5_python_sdk/offer_sub_condition.py | 204 ----- amazon/paapi5_python_sdk/offer_summary.py | 207 ----- amazon/paapi5_python_sdk/offers.py | 155 ---- amazon/paapi5_python_sdk/partner_type.py | 103 --- amazon/paapi5_python_sdk/price.py | 154 ---- ...roduct_advertising_api_client_exception.py | 128 --- ...oduct_advertising_api_service_exception.py | 126 --- amazon/paapi5_python_sdk/product_info.py | 261 ------ amazon/paapi5_python_sdk/properties.py | 83 -- amazon/paapi5_python_sdk/refinement.py | 180 ---- amazon/paapi5_python_sdk/refinement_bin.py | 152 ---- .../paapi5_python_sdk/rental_offer_listing.py | 262 ------ amazon/paapi5_python_sdk/rental_offers.py | 128 --- amazon/paapi5_python_sdk/rest.py | 333 ------- .../paapi5_python_sdk/search_items_request.py | 818 ------------------ .../search_items_resource.py | 158 ---- .../search_items_response.py | 155 ---- .../paapi5_python_sdk/search_refinements.py | 180 ---- amazon/paapi5_python_sdk/search_result.py | 207 ----- .../single_boolean_valued_attribute.py | 178 ---- .../single_integer_valued_attribute.py | 178 ---- .../single_string_valued_attribute.py | 178 ---- amazon/paapi5_python_sdk/sort_by.py | 108 --- amazon/paapi5_python_sdk/technical_info.py | 128 --- amazon/paapi5_python_sdk/trade_in_info.py | 154 ---- amazon/paapi5_python_sdk/trade_in_price.py | 178 ---- .../paapi5_python_sdk/unit_based_attribute.py | 204 ----- .../paapi5_python_sdk/variation_attribute.py | 152 ---- .../paapi5_python_sdk/variation_dimension.py | 204 ----- amazon/paapi5_python_sdk/variation_summary.py | 207 ----- amazon/paapi5_python_sdk/variations_result.py | 155 ---- .../paapi5_python_sdk/website_sales_rank.py | 204 ----- amazon/parse.py | 550 ------------ amazon/serializer/dango_rest_framework.py | 156 ---- amazon/tools.py | 26 - docs/Makefile | 20 + docs/conf.py | 56 ++ docs/index.rst | 21 + docs/make.bat | 35 + docs/requirements.txt | 2 + 110 files changed, 134 insertions(+), 20053 deletions(-) delete mode 100644 amazon/README.md delete mode 100644 amazon/__init__.py delete mode 100644 amazon/constant.py delete mode 100644 amazon/exception.py delete mode 100644 amazon/paapi.py delete mode 100644 amazon/paapi5_python_sdk/COPYING.txt delete mode 100644 amazon/paapi5_python_sdk/LICENSE.txt delete mode 100644 amazon/paapi5_python_sdk/NOTICE.txt delete mode 100644 amazon/paapi5_python_sdk/__init__.py delete mode 100644 amazon/paapi5_python_sdk/api/__init__.py delete mode 100644 amazon/paapi5_python_sdk/api/default_api.py delete mode 100644 amazon/paapi5_python_sdk/api_client.py delete mode 100644 amazon/paapi5_python_sdk/auth/__init__.py delete mode 100644 amazon/paapi5_python_sdk/auth/sig_v4.py delete mode 100644 amazon/paapi5_python_sdk/availability.py delete mode 100644 amazon/paapi5_python_sdk/browse_node.py delete mode 100644 amazon/paapi5_python_sdk/browse_node_ancestor.py delete mode 100644 amazon/paapi5_python_sdk/browse_node_child.py delete mode 100644 amazon/paapi5_python_sdk/browse_node_children.py delete mode 100644 amazon/paapi5_python_sdk/browse_node_info.py delete mode 100644 amazon/paapi5_python_sdk/browse_nodes_result.py delete mode 100644 amazon/paapi5_python_sdk/by_line_info.py delete mode 100644 amazon/paapi5_python_sdk/classifications.py delete mode 100644 amazon/paapi5_python_sdk/condition.py delete mode 100644 amazon/paapi5_python_sdk/configuration.py delete mode 100644 amazon/paapi5_python_sdk/content_info.py delete mode 100644 amazon/paapi5_python_sdk/content_rating.py delete mode 100644 amazon/paapi5_python_sdk/contributor.py delete mode 100644 amazon/paapi5_python_sdk/delivery_flag.py delete mode 100644 amazon/paapi5_python_sdk/dimension_based_attribute.py delete mode 100644 amazon/paapi5_python_sdk/duration_price.py delete mode 100644 amazon/paapi5_python_sdk/error_data.py delete mode 100644 amazon/paapi5_python_sdk/external_ids.py delete mode 100644 amazon/paapi5_python_sdk/get_browse_nodes_request.py delete mode 100644 amazon/paapi5_python_sdk/get_browse_nodes_resource.py delete mode 100644 amazon/paapi5_python_sdk/get_browse_nodes_response.py delete mode 100644 amazon/paapi5_python_sdk/get_items_request.py delete mode 100644 amazon/paapi5_python_sdk/get_items_resource.py delete mode 100644 amazon/paapi5_python_sdk/get_items_response.py delete mode 100644 amazon/paapi5_python_sdk/get_variations_request.py delete mode 100644 amazon/paapi5_python_sdk/get_variations_resource.py delete mode 100644 amazon/paapi5_python_sdk/get_variations_response.py delete mode 100644 amazon/paapi5_python_sdk/image_size.py delete mode 100644 amazon/paapi5_python_sdk/image_type.py delete mode 100644 amazon/paapi5_python_sdk/images.py delete mode 100644 amazon/paapi5_python_sdk/item.py delete mode 100644 amazon/paapi5_python_sdk/item_id_type.py delete mode 100644 amazon/paapi5_python_sdk/item_info.py delete mode 100644 amazon/paapi5_python_sdk/items_result.py delete mode 100644 amazon/paapi5_python_sdk/language_type.py delete mode 100644 amazon/paapi5_python_sdk/languages.py delete mode 100644 amazon/paapi5_python_sdk/manufacture_info.py delete mode 100644 amazon/paapi5_python_sdk/max_price.py delete mode 100644 amazon/paapi5_python_sdk/merchant.py delete mode 100644 amazon/paapi5_python_sdk/min_price.py delete mode 100644 amazon/paapi5_python_sdk/min_reviews_rating.py delete mode 100644 amazon/paapi5_python_sdk/min_saving_percent.py delete mode 100644 amazon/paapi5_python_sdk/multi_valued_attribute.py delete mode 100644 amazon/paapi5_python_sdk/offer_availability.py delete mode 100644 amazon/paapi5_python_sdk/offer_condition.py delete mode 100644 amazon/paapi5_python_sdk/offer_count.py delete mode 100644 amazon/paapi5_python_sdk/offer_delivery_info.py delete mode 100644 amazon/paapi5_python_sdk/offer_listing.py delete mode 100644 amazon/paapi5_python_sdk/offer_loyalty_points.py delete mode 100644 amazon/paapi5_python_sdk/offer_merchant_info.py delete mode 100644 amazon/paapi5_python_sdk/offer_price.py delete mode 100644 amazon/paapi5_python_sdk/offer_program_eligibility.py delete mode 100644 amazon/paapi5_python_sdk/offer_promotion.py delete mode 100644 amazon/paapi5_python_sdk/offer_savings.py delete mode 100644 amazon/paapi5_python_sdk/offer_shipping_charge.py delete mode 100644 amazon/paapi5_python_sdk/offer_sub_condition.py delete mode 100644 amazon/paapi5_python_sdk/offer_summary.py delete mode 100644 amazon/paapi5_python_sdk/offers.py delete mode 100644 amazon/paapi5_python_sdk/partner_type.py delete mode 100644 amazon/paapi5_python_sdk/price.py delete mode 100644 amazon/paapi5_python_sdk/product_advertising_api_client_exception.py delete mode 100644 amazon/paapi5_python_sdk/product_advertising_api_service_exception.py delete mode 100644 amazon/paapi5_python_sdk/product_info.py delete mode 100644 amazon/paapi5_python_sdk/properties.py delete mode 100644 amazon/paapi5_python_sdk/refinement.py delete mode 100644 amazon/paapi5_python_sdk/refinement_bin.py delete mode 100644 amazon/paapi5_python_sdk/rental_offer_listing.py delete mode 100644 amazon/paapi5_python_sdk/rental_offers.py delete mode 100644 amazon/paapi5_python_sdk/rest.py delete mode 100644 amazon/paapi5_python_sdk/search_items_request.py delete mode 100644 amazon/paapi5_python_sdk/search_items_resource.py delete mode 100644 amazon/paapi5_python_sdk/search_items_response.py delete mode 100644 amazon/paapi5_python_sdk/search_refinements.py delete mode 100644 amazon/paapi5_python_sdk/search_result.py delete mode 100644 amazon/paapi5_python_sdk/single_boolean_valued_attribute.py delete mode 100644 amazon/paapi5_python_sdk/single_integer_valued_attribute.py delete mode 100644 amazon/paapi5_python_sdk/single_string_valued_attribute.py delete mode 100644 amazon/paapi5_python_sdk/sort_by.py delete mode 100644 amazon/paapi5_python_sdk/technical_info.py delete mode 100644 amazon/paapi5_python_sdk/trade_in_info.py delete mode 100644 amazon/paapi5_python_sdk/trade_in_price.py delete mode 100644 amazon/paapi5_python_sdk/unit_based_attribute.py delete mode 100644 amazon/paapi5_python_sdk/variation_attribute.py delete mode 100644 amazon/paapi5_python_sdk/variation_dimension.py delete mode 100644 amazon/paapi5_python_sdk/variation_summary.py delete mode 100644 amazon/paapi5_python_sdk/variations_result.py delete mode 100644 amazon/paapi5_python_sdk/website_sales_rank.py delete mode 100644 amazon/parse.py delete mode 100644 amazon/serializer/dango_rest_framework.py delete mode 100644 amazon/tools.py create mode 100644 docs/Makefile create mode 100644 docs/conf.py create mode 100644 docs/index.rst create mode 100644 docs/make.bat create mode 100644 docs/requirements.txt diff --git a/amazon/README.md b/amazon/README.md deleted file mode 100644 index 755db35..0000000 --- a/amazon/README.md +++ /dev/null @@ -1,123 +0,0 @@ -# Amazon Product Advertising API 5.0 wrapper for Python v3.3.4 - -> :warning: **This version is deprecated and it will be removed in the future. Please use [version 4.0.0 or higher](https://github.com/sergioteula/python-amazon-paapi).** - -A simple Python wrapper for the [last version of the Amazon Product Advertising API](https://webservices.amazon.com/paapi5/documentation/quick-start/using-sdk.html). This module allows to get product information from Amazon using the official API in an easier way. - -[![PyPI](https://img.shields.io/pypi/v/python-amazon-paapi?color=%231182C2&label=PyPI)](https://pypi.org/project/python-amazon-paapi/) -[![Python](https://img.shields.io/badge/Python-2.x%20%7C%203.x-%23FFD140)](https://www.python.org/) -[![License](https://img.shields.io/badge/License-MIT-%23e83633)](https://github.com/sergioteula/python-amazon-paapi/blob/master/LICENSE) -[![Support](https://img.shields.io/badge/Support-Good-brightgreen)](https://github.com/sergioteula/python-amazon-paapi/issues) -[![Amazon API](https://img.shields.io/badge/Amazon%20API-5.0-%23FD9B15)](https://webservices.amazon.com/paapi5/documentation/) - -## Features - -- Object oriented interface for simple usage. -- Get information about a product through its ASIN or URL. -- Get item variations or search for products on Amazon. -- Get browse nodes information. -- Get multiple results at once without the 10 items limitation from Amazon. -- Configurable throttling to avoid requests exceptions. -- Built-in serializer for Django REST framework. -- Support for [all available countries](https://github.com/sergioteula/python-amazon-paapi/blob/master/amazon/paapi.py#L31). -- Reorganized product information [structure](https://github.com/sergioteula/python-amazon-paapi/blob/master/PRODUCT.md) for simple use. -- Ask for new features through the [issues](https://github.com/sergioteula/python-amazon-paapi/issues) section. -- Join our [Telegram group](https://t.me/PythonAmazonPAAPI) for support or development. - -## Installation - -You can install this module version with: - - pip install python-amazon-paapi==3.3.4 - -If you get `ModuleNotFoundError`, try installing this: - - pip install amightygirl.paapi5-python-sdk - -## Usage guide - -**Basic usage:** - -```python -from amazon.paapi import AmazonApi -amazon = AmazonApi(KEY, SECRET, TAG, COUNTRY) -product = amazon.get_product('B01N5IB20Q') -print(product.title) -``` - -**Get multiple product information:** - -```python -product = amazon.get_products('B01N5IB20Q,B01F9G43WU') -print(product[0].images.large) -print(product[1].prices.price.value) -``` - -**Use URL insted of ASIN:** - -```python -product = amazon.get_product('https://www.amazon.com/dp/B01N5IB20Q') -``` - -**Get product variations:** - -```python -product = amazon.get_variations('B01N5IB20Q') -print(product[0].title) -``` - -**Search product:** - -```python -product = amazon.search_products(item_count=25, keywords='speaker') -print(product[14].url) -``` - -**Get browse node information:** - -```python -node = amazon.get_browsenodes(browse_nodes=browsenodes_list) -``` - -**Get the ASIN from a URL:** - -```python -from amazon.tools import get_asin -asin = get_asin('https://www.amazon.com/dp/B01N5IB20Q') -``` - -**Throttling:** - -Throttling value must be `greater than 0` or `False` to disable it. This value throttles requests to a maximum of one request every `1 / value` seconds. Note that this value is a per-worker throttling, so applications with multiple workers may make more requests per second. Throttling value is [set by default](https://github.com/sergioteula/python-amazon-paapi/blob/master/amazon/paapi.py#L36) to `0.8` or one request every 1.25 seconds. - -```python -amazon = AmazonApi(KEY, SECRET, TAG, COUNTRY, throttling=0.5) # Max one request every two seconds -amazon = AmazonApi(KEY, SECRET, TAG, COUNTRY, throttling=False) # Unlimited requests per second -``` - -**Serializer for Django:** - -We provide a serializer for Django REST framework, which speeds up your API -implementation. - -```python -from amazon.serializers import AmazonProductSerializer -from rest_framework import serializers - -serialized_product = AmazonProductSerializer(product) -serialized_product.data -``` - -If you want to serialize a list of products: - -```python -serialized_products = AmazonProductSerializer(products, many=True) -serialized_products.data -``` - -For more information on how to work with serializers, check the documentation for -[Django REST framework](https://www.django-rest-framework.org/api-guide/serializers/). - -## License - -Copyright © 2020 Sergio Abad. See [license](https://github.com/sergioteula/python-amazon-paapi/blob/master/LICENSE) for details. diff --git a/amazon/__init__.py b/amazon/__init__.py deleted file mode 100644 index 17c61a2..0000000 --- a/amazon/__init__.py +++ /dev/null @@ -1,4 +0,0 @@ -"""Amazon Product Advertising API wrapper for Python""" - -__version__ = '3.3.3' -__author__ = 'Sergio Abad' diff --git a/amazon/constant.py b/amazon/constant.py deleted file mode 100644 index c1fae32..0000000 --- a/amazon/constant.py +++ /dev/null @@ -1,241 +0,0 @@ -"""Module containing all the constants.""" - -from .paapi5_python_sdk.get_items_resource import GetItemsResource -from .paapi5_python_sdk.search_items_resource import SearchItemsResource -from .paapi5_python_sdk.get_variations_resource import GetVariationsResource -from .paapi5_python_sdk.get_browse_nodes_resource import GetBrowseNodesResource -from .paapi5_python_sdk.condition import Condition - -"""Available regions for the Amazon API.""" -REGIONS = { - 'AU': 'us-west-2', - 'BR': 'us-east-1', - 'CA': 'us-east-1', - 'FR': 'eu-west-1', - 'DE': 'eu-west-1', - 'NL': 'eu-west-1', - 'IN': 'eu-west-1', - 'IT': 'eu-west-1', - 'JP': 'us-west-2', - 'MX': 'us-east-1', - 'ES': 'eu-west-1', - 'TR': 'eu-west-1', - 'AE': 'eu-west-1', - 'UK': 'eu-west-1', - 'US': 'us-east-1', - 'SE': 'eu-west-1' -} - -"""Domains for each region on the Amazon API.""" -DOMAINS = { - 'AU': 'com.au', - 'BR': 'com.br', - 'CA': 'ca', - 'FR': 'fr', - 'DE': 'de', - 'NL': 'nl', - 'IN': 'in', - 'IT': 'it', - 'JP': 'co.jp', - 'MX': 'com.mx', - 'ES': 'es', - 'TR': 'com.tr', - 'AE': 'ae', - 'UK': 'co.uk', - 'US': 'com', - 'SE': 'se' -} - -"""Condition values.""" -CONDITION = { - 'Any': Condition.ANY, - 'Collectible': Condition.COLLECTIBLE, - 'New': Condition.NEW, - 'Refurbished': Condition.REFURBISHED, - 'Used': Condition.USED -} - -"""Product resources to get from Amazon API.""" -PRODUCT_RESOURCES = [ - GetItemsResource.BROWSENODEINFO_BROWSENODES, - GetItemsResource.BROWSENODEINFO_BROWSENODES_ANCESTOR, - GetItemsResource.BROWSENODEINFO_BROWSENODES_SALESRANK, - GetItemsResource.BROWSENODEINFO_WEBSITESALESRANK, - GetItemsResource.IMAGES_PRIMARY_SMALL, - GetItemsResource.IMAGES_PRIMARY_MEDIUM, - GetItemsResource.IMAGES_PRIMARY_LARGE, - GetItemsResource.IMAGES_VARIANTS_SMALL, - GetItemsResource.IMAGES_VARIANTS_MEDIUM, - GetItemsResource.IMAGES_VARIANTS_LARGE, - GetItemsResource.ITEMINFO_BYLINEINFO, - GetItemsResource.ITEMINFO_CONTENTINFO, - GetItemsResource.ITEMINFO_CONTENTRATING, - GetItemsResource.ITEMINFO_CLASSIFICATIONS, - GetItemsResource.ITEMINFO_EXTERNALIDS, - GetItemsResource.ITEMINFO_FEATURES, - GetItemsResource.ITEMINFO_MANUFACTUREINFO, - GetItemsResource.ITEMINFO_PRODUCTINFO, - GetItemsResource.ITEMINFO_TECHNICALINFO, - GetItemsResource.ITEMINFO_TITLE, - GetItemsResource.ITEMINFO_TRADEININFO, - GetItemsResource.OFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY, - GetItemsResource.OFFERS_LISTINGS_AVAILABILITY_MESSAGE, - GetItemsResource.OFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY, - GetItemsResource.OFFERS_LISTINGS_AVAILABILITY_TYPE, - GetItemsResource.OFFERS_LISTINGS_CONDITION, - GetItemsResource.OFFERS_LISTINGS_CONDITION_SUBCONDITION, - GetItemsResource.OFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED, - GetItemsResource.OFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE, - GetItemsResource.OFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE, - GetItemsResource.OFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES, - GetItemsResource.OFFERS_LISTINGS_ISBUYBOXWINNER, - GetItemsResource.OFFERS_LISTINGS_LOYALTYPOINTS_POINTS, - GetItemsResource.OFFERS_LISTINGS_MERCHANTINFO, - GetItemsResource.OFFERS_LISTINGS_PRICE, - GetItemsResource.OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEEXCLUSIVE, - GetItemsResource.OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEPANTRY, - GetItemsResource.OFFERS_LISTINGS_PROMOTIONS, - GetItemsResource.OFFERS_LISTINGS_SAVINGBASIS, - GetItemsResource.OFFERS_SUMMARIES_HIGHESTPRICE, - GetItemsResource.OFFERS_SUMMARIES_LOWESTPRICE, - GetItemsResource.OFFERS_SUMMARIES_OFFERCOUNT, - GetItemsResource.PARENTASIN, - GetItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY, - GetItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MESSAGE, - GetItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY, - GetItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_TYPE, - GetItemsResource.RENTALOFFERS_LISTINGS_BASEPRICE, - GetItemsResource.RENTALOFFERS_LISTINGS_CONDITION, - GetItemsResource.RENTALOFFERS_LISTINGS_CONDITION_SUBCONDITION, - GetItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED, - GetItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE, - GetItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE, - GetItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES, - GetItemsResource.RENTALOFFERS_LISTINGS_MERCHANTINFO] - -"""Search resources to get from Amazon API.""" -SEARCH_RESOURCES = [ - SearchItemsResource.BROWSENODEINFO_BROWSENODES, - SearchItemsResource.BROWSENODEINFO_BROWSENODES_ANCESTOR, - SearchItemsResource.BROWSENODEINFO_BROWSENODES_SALESRANK, - SearchItemsResource.BROWSENODEINFO_WEBSITESALESRANK, - SearchItemsResource.IMAGES_PRIMARY_SMALL, - SearchItemsResource.IMAGES_PRIMARY_MEDIUM, - SearchItemsResource.IMAGES_PRIMARY_LARGE, - SearchItemsResource.IMAGES_VARIANTS_SMALL, - SearchItemsResource.IMAGES_VARIANTS_MEDIUM, - SearchItemsResource.IMAGES_VARIANTS_LARGE, - SearchItemsResource.ITEMINFO_BYLINEINFO, - SearchItemsResource.ITEMINFO_CONTENTINFO, - SearchItemsResource.ITEMINFO_CONTENTRATING, - SearchItemsResource.ITEMINFO_CLASSIFICATIONS, - SearchItemsResource.ITEMINFO_EXTERNALIDS, - SearchItemsResource.ITEMINFO_FEATURES, - SearchItemsResource.ITEMINFO_MANUFACTUREINFO, - SearchItemsResource.ITEMINFO_PRODUCTINFO, - SearchItemsResource.ITEMINFO_TECHNICALINFO, - SearchItemsResource.ITEMINFO_TITLE, - SearchItemsResource.ITEMINFO_TRADEININFO, - SearchItemsResource.OFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY, - SearchItemsResource.OFFERS_LISTINGS_AVAILABILITY_MESSAGE, - SearchItemsResource.OFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY, - SearchItemsResource.OFFERS_LISTINGS_AVAILABILITY_TYPE, - SearchItemsResource.OFFERS_LISTINGS_CONDITION, - SearchItemsResource.OFFERS_LISTINGS_CONDITION_SUBCONDITION, - SearchItemsResource.OFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED, - SearchItemsResource.OFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE, - SearchItemsResource.OFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE, - SearchItemsResource.OFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES, - SearchItemsResource.OFFERS_LISTINGS_ISBUYBOXWINNER, - SearchItemsResource.OFFERS_LISTINGS_LOYALTYPOINTS_POINTS, - SearchItemsResource.OFFERS_LISTINGS_MERCHANTINFO, - SearchItemsResource.OFFERS_LISTINGS_PRICE, - SearchItemsResource.OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEEXCLUSIVE, - SearchItemsResource.OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEPANTRY, - SearchItemsResource.OFFERS_LISTINGS_PROMOTIONS, - SearchItemsResource.OFFERS_LISTINGS_SAVINGBASIS, - SearchItemsResource.OFFERS_SUMMARIES_HIGHESTPRICE, - SearchItemsResource.OFFERS_SUMMARIES_LOWESTPRICE, - SearchItemsResource.OFFERS_SUMMARIES_OFFERCOUNT, - SearchItemsResource.PARENTASIN, - SearchItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY, - SearchItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MESSAGE, - SearchItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY, - SearchItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_TYPE, - SearchItemsResource.RENTALOFFERS_LISTINGS_BASEPRICE, - SearchItemsResource.RENTALOFFERS_LISTINGS_CONDITION, - SearchItemsResource.RENTALOFFERS_LISTINGS_CONDITION_SUBCONDITION, - SearchItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED, - SearchItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE, - SearchItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE, - SearchItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES, - SearchItemsResource.RENTALOFFERS_LISTINGS_MERCHANTINFO, - SearchItemsResource.SEARCHREFINEMENTS] - -"""Variation resources to get from Amazon API.""" -VARIATION_RESOURCES = [ - GetVariationsResource.BROWSENODEINFO_BROWSENODES, - GetVariationsResource.BROWSENODEINFO_BROWSENODES_ANCESTOR, - GetVariationsResource.BROWSENODEINFO_BROWSENODES_SALESRANK, - GetVariationsResource.BROWSENODEINFO_WEBSITESALESRANK, - GetVariationsResource.IMAGES_PRIMARY_SMALL, - GetVariationsResource.IMAGES_PRIMARY_MEDIUM, - GetVariationsResource.IMAGES_PRIMARY_LARGE, - GetVariationsResource.IMAGES_VARIANTS_SMALL, - GetVariationsResource.IMAGES_VARIANTS_MEDIUM, - GetVariationsResource.IMAGES_VARIANTS_LARGE, - GetVariationsResource.ITEMINFO_BYLINEINFO, - GetVariationsResource.ITEMINFO_CONTENTINFO, - GetVariationsResource.ITEMINFO_CONTENTRATING, - GetVariationsResource.ITEMINFO_CLASSIFICATIONS, - GetVariationsResource.ITEMINFO_EXTERNALIDS, - GetVariationsResource.ITEMINFO_FEATURES, - GetVariationsResource.ITEMINFO_MANUFACTUREINFO, - GetVariationsResource.ITEMINFO_PRODUCTINFO, - GetVariationsResource.ITEMINFO_TECHNICALINFO, - GetVariationsResource.ITEMINFO_TITLE, - GetVariationsResource.ITEMINFO_TRADEININFO, - GetVariationsResource.OFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY, - GetVariationsResource.OFFERS_LISTINGS_AVAILABILITY_MESSAGE, - GetVariationsResource.OFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY, - GetVariationsResource.OFFERS_LISTINGS_AVAILABILITY_TYPE, - GetVariationsResource.OFFERS_LISTINGS_CONDITION, - GetVariationsResource.OFFERS_LISTINGS_CONDITION_SUBCONDITION, - GetVariationsResource.OFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED, - GetVariationsResource.OFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE, - GetVariationsResource.OFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE, - GetVariationsResource.OFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES, - GetVariationsResource.OFFERS_LISTINGS_ISBUYBOXWINNER, - GetVariationsResource.OFFERS_LISTINGS_LOYALTYPOINTS_POINTS, - GetVariationsResource.OFFERS_LISTINGS_MERCHANTINFO, - GetVariationsResource.OFFERS_LISTINGS_PRICE, - GetVariationsResource.OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEEXCLUSIVE, - GetVariationsResource.OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEPANTRY, - GetVariationsResource.OFFERS_LISTINGS_PROMOTIONS, - GetVariationsResource.OFFERS_LISTINGS_SAVINGBASIS, - GetVariationsResource.OFFERS_SUMMARIES_HIGHESTPRICE, - GetVariationsResource.OFFERS_SUMMARIES_LOWESTPRICE, - GetVariationsResource.OFFERS_SUMMARIES_OFFERCOUNT, - GetVariationsResource.PARENTASIN, - GetVariationsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY, - GetVariationsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MESSAGE, - GetVariationsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY, - GetVariationsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_TYPE, - GetVariationsResource.RENTALOFFERS_LISTINGS_BASEPRICE, - GetVariationsResource.RENTALOFFERS_LISTINGS_CONDITION, - GetVariationsResource.RENTALOFFERS_LISTINGS_CONDITION_SUBCONDITION, - GetVariationsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED, - GetVariationsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE, - GetVariationsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE, - GetVariationsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES, - GetVariationsResource.RENTALOFFERS_LISTINGS_MERCHANTINFO, - GetVariationsResource.VARIATIONSUMMARY_PRICE_HIGHESTPRICE, - GetVariationsResource.VARIATIONSUMMARY_PRICE_LOWESTPRICE, - GetVariationsResource.VARIATIONSUMMARY_VARIATIONDIMENSION -] - -"""Browse Node resources to get from Amazon API.""" -BROWSE_RESOURCES = [ - GetBrowseNodesResource.ANCESTOR, - GetBrowseNodesResource.CHILDREN -] diff --git a/amazon/exception.py b/amazon/exception.py deleted file mode 100644 index c9af2df..0000000 --- a/amazon/exception.py +++ /dev/null @@ -1,11 +0,0 @@ -"""Custom exception class.""" - - -class AmazonException(Exception): - """Custom exception class for Amazon Product Advertising API.""" - def __init__(self, status=None, reason=None): - self.status = status - self.reason = reason - - def __str__(self): - return '%s: %s' % (self.status, self.reason) diff --git a/amazon/paapi.py b/amazon/paapi.py deleted file mode 100644 index d29a79c..0000000 --- a/amazon/paapi.py +++ /dev/null @@ -1,457 +0,0 @@ -"""Amazon Product Advertising API wrapper for Python - -A simple Python wrapper for the last version of the Amazon Product Advertising API. -This module allows to get product information from Amazon using the official API in -an easier way. -""" - -from .paapi5_python_sdk.api.default_api import DefaultApi -from .paapi5_python_sdk.get_items_request import GetItemsRequest -from .paapi5_python_sdk.search_items_request import SearchItemsRequest -from .paapi5_python_sdk.get_variations_request import GetVariationsRequest -from .paapi5_python_sdk.get_browse_nodes_request import GetBrowseNodesRequest -from .paapi5_python_sdk.partner_type import PartnerType -from .paapi5_python_sdk.rest import ApiException - -from amazon.constant import DOMAINS, REGIONS, CONDITION -from amazon.constant import PRODUCT_RESOURCES, SEARCH_RESOURCES, VARIATION_RESOURCES -from amazon.constant import BROWSE_RESOURCES -from amazon.exception import AmazonException -from amazon.parse import parse_product, AmazonBrowseNode, parse_browsenode -from amazon.tools import get_asin, chunks - -import logging -import time - - -logger = logging.getLogger(__name__) - - -class AmazonAPI: - """Creates an instance containing your API credentials. - - Args: - key (str): Your API key. - secret (str): Your API secret. - tag (str): The tag you want to use for the URL. - country (str): Country code. Use one of the following: - AU, BR, CA, FR, DE, IN, NL, IT, JP, MX, ES, TR, AE, UK, US, SE. - throttling (float, optional): It should be greater than 0 or False to disable throttling. - This value determines wait time between API calls. - """ - def __init__(self, key, secret, tag, country, throttling=0.8): - logger.warning('This version of the module is deprecated and it will be removed in future updates. Please upgrade to version 4.0.0 or higher.') - self.key = key - self.secret = secret - self.tag = tag - try: - if throttling is True: - raise ValueError - elif throttling is False: - self.throttling = False - else: - self.throttling = float(throttling) - if self.throttling <= 0: - raise ValueError - except ValueError: - raise AmazonException('ValueError', 'Throttling should be False or greater than 0') - self.country = country - try: - self.host = 'webservices.amazon.' + DOMAINS[country] - self.region = REGIONS[country] - self.marketplace = 'www.amazon.' + DOMAINS[country] - except KeyError: - raise AmazonException('KeyError', 'Invalid country code') - self.last_query_time = time.time() - self.api = DefaultApi(access_key=self.key, secret_key=self.secret, host=self.host, - region=self.region) - - def _throttle(self): - if self.throttling: - wait_time = 1 / self.throttling - (time.time() - self.last_query_time) - if wait_time > 0: - time.sleep(wait_time) - self.last_query_time = time.time() - - def get_products(self, product_ids, condition='Any', merchant='All', - async_req=False): - """Find product information for multiple products on Amazon. - - Args: - product_ids (str|list): One or more item IDs like ASIN or product URL. - Use a string separated by comma or as a list. - condition (str, optional): Specify the product condition. - Allowed values: Any, Collectible, New, Refurbished, Used. - Defaults to Any. - merchant (str, optional): Filters search results to return items - having at least one offer sold by target merchant. Allowed values: - All, Amazon. Defaults to All. - async_req (bool, optional): Specify if a thread should be created to - run the request. Defaults to False. - - Returns: - list of instances: A list containing 1 instance for each product - or None if no results. - """ - - logger.warning('This version of the module is deprecated and it will be removed in future updates. Please upgrade to version 4.0.0 or higher.') - # Clean up input data and remove 10 items limit from Amazon API - if isinstance(product_ids, str): - product_ids = [x.strip() for x in product_ids.split(',')] - elif not isinstance(product_ids, list): - raise AmazonException('TypeError', 'Arg product_ids should be a list or string') - asin_full_list = list(set([get_asin(x) for x in product_ids])) - asin_full_list = list(chunks(asin_full_list, 10)) - - results = [] - for asin_list in asin_full_list: - try: - request = GetItemsRequest(partner_tag=self.tag, - partner_type=PartnerType.ASSOCIATES, - marketplace=self.marketplace, - merchant=merchant, - condition=CONDITION[condition], - item_ids=asin_list, - resources=PRODUCT_RESOURCES) - except KeyError: - raise AmazonException('KeyError', 'Invalid condition value') - except Exception as e: - raise AmazonException('GetItemsError', e) - - for x in range(3): - try: - # Send the request and create results - self._throttle() - if async_req: - thread = self.api.get_items(request, async_req=True) - response = thread.get() - else: - response = self.api.get_items(request) - break - except ApiException as e: - if x == 2: - raise AmazonException('ApiException', e) - try: - if response.items_result is not None: - if len(response.items_result.items) > 0: - for item in response.items_result.items: - results.append(parse_product(item)) - except Exception as e: - raise AmazonException('ResponseError', e) - - if results: - return results - else: - return None - - def get_product(self, product_id, condition='Any', merchant='All', - async_req=False): - """Find product information for a specific product on Amazon. - - Args: - product_id (str, list): One item ID like ASIN or product URL. - condition (str, optional): Specify the product condition. - Allowed values: Any, Collectible, New, Refurbished, Used. - Defaults to Any. - merchant (str, optional): Filters search results to return items - having at least one offer sold by target merchant. Allowed values: - All, Amazon. Defaults to All. - async_req (bool, optional): Specify if a thread should be created to - run the request. Defaults to False. - - Returns: - instance: An instance containing all the available information - for the product or None if no results. - """ - if isinstance(product_id, list): - product_id = product_id[0] - if isinstance(product_id, str): - product_id = product_id.split(',')[0] - - product = self.get_products(product_id, condition=condition, merchant=merchant, - async_req=async_req) - if product: - return product[0] - else: - return None - - def search_products(self, item_count=10, item_page=1, items_per_page=10, keywords=None, - actor=None, artist=None, author=None, brand=None, title=None, - availability='Available', browse_node=None, condition='Any', delivery=None, - max_price=None, min_price=None, min_rating=None, min_discount=None, - merchant='All', search_index='All', sort_by=None, async_req=False): - """Search products on Amazon using different parameters. At least one of the - following parameters should be used: keywords, actor, artist, author, brand, - title. - - Args: - item_count (int, optional): The total number of products to get. Should be between - 1 and 100. Defaults to 10. - item_page (int, optional): The page where the results start from. Should be between - 1 and 10. Defaults to 1. - items_per_page (int, optional): Products on each page. Should be between - 1 and 10. Defaults to 10. - keywords (str, optional): A word or phrase that describes an item. - actor (str, optional): Actor name associated with the item. - artist (str, optional): Artist name associated with the item. - author (str, optional): Author name associated with the item. - brand (str, optional): Brand name associated with the item. - title (str, optional): Title associated with the item. - availability (str, optional): Filters available items on Amazon. Allowed values: - Available, IncludeOutOfStock. Defaults to Available. - browse_node (str, optional): A unique ID assigned by Amazon that - identifies a product category or subcategory. - condition (str, optional): The condition parameter filters offers by - condition type. Allowed values: Any, Collectible, New, Refurbished, Used. - Defaults to Any. - delivery (list, optional): The delivery flag filters items which - satisfy a certain delivery program promoted by the specific - Amazon Marketplace. Allowed values: AmazonGlobal, FreeShipping, - FulfilledByAmazon, Prime. - max_price (int, optional): Filters search results to items with at - least one offer price below the specified value. - min_price (int, optional): Filters search results to items with at - least one offer price above the specified value. - min_rating (int, optional): Filters search results to items with - customer review ratings above specified value. - min_discount (int, optional): Filters search results to items with - at least one offer having saving percentage above the specified - value. - merchant (str, optional): Filters search results to return items - having at least one offer sold by target merchant. Allowed values: - All, Amazon. Defaults to All. - search_index (str, optional): Indicates the product category to - search. Defaults to All. - sort_by (str, optional): The way in which items in the response - are sorted. Allowed values: AvgCustomerReviews, Featured, - NewestArrivals, Price:HighToLow, Price:LowToHigh, Relevance. - async_req (bool, optional): Specify if a thread should be created to - run the request. Defaults to False. - - Returns: - list of instances: A list containing 1 instance for each product - or None if no results. - """ - - logger.warning('This version of the module is deprecated and it will be removed in future updates. Please upgrade to version 4.0.0 or higher.') - if items_per_page > 10 or items_per_page < 1: - raise AmazonException('ValueError', 'Arg items_per_page should be between 1 and 10') - if item_count > 100 or item_count < 1: - raise AmazonException('ValueError', 'Arg item_count should be between 1 and 100') - if item_page < 1: - raise AmazonException('ValueError', 'Arg item_page should be 1 or higher') - if not keywords and not actor and not artist and not author and not brand and not title and not browse_node and not search_index: - raise AmazonException('ValueError', 'At least one of the following args must be ' - 'provided: keywords, actor, artist, author, brand, ' - 'title, browse_node, search_index') - results = [] - while len(results) < item_count: - try: - request = SearchItemsRequest( - partner_tag=self.tag, - partner_type=PartnerType.ASSOCIATES, - actor=actor, - artist=artist, - author=author, - availability=availability, - brand=brand, - browse_node_id=browse_node, - condition=CONDITION[condition], - delivery_flags=delivery, - item_count=items_per_page, - item_page=item_page, - keywords=keywords, - max_price=max_price, - merchant=merchant, - min_price=min_price, - min_reviews_rating=min_rating, - min_saving_percent=min_discount, - offer_count=1, - resources=SEARCH_RESOURCES, - search_index=search_index, - sort_by=sort_by, - title=title) - except KeyError: - raise AmazonException('KeyError', 'Invalid condition value') - except Exception as e: - raise AmazonException('SearchItemsError', e) - - for x in range(3): - try: - # Send the request and create results - self._throttle() - if async_req: - thread = self.api.search_items(request, async_req=True) - response = thread.get() - else: - response = self.api.search_items(request) - break - except ApiException as e: - if x == 2: - raise AmazonException('ApiException', e) - try: - if response.search_result is not None: - if response.search_result.items is not None: - for item in response.search_result.items: - results.append(parse_product(item)) - if len(results) >= item_count: - break - if len(response.search_result.items) < items_per_page: - break - else: - break - if response.errors is not None: - raise AmazonException(response.errors[0].code, response.errors[0].message) - except Exception as e: - if e.status == "NoResults": - break - raise AmazonException('ResponseError', e) - item_page += 1 - - if results: - return results - else: - return None - - def get_variations(self, asin, item_count=10, item_page=1, items_per_page=10, condition='Any', - merchant='All', async_req=False): - """Returns a set of items that are the same product, but differ according to a - consistent theme, for example size and color. - - Args: - asin (str): One item ID like ASIN or product URL. - item_count (int, optional): The total number of products to get. Should be between - 1 and 100. Defaults to 10. - item_page (int, optional): The page where the results start from. Should be between - 1 and 10. Defaults to 1. - items_per_page (int, optional): Products on each page. Should be between - 1 and 10. Defaults to 10. - condition (str, optional): The condition parameter filters offers by - condition type. Allowed values: Any, Collectible, New, Refurbished, Used. - Defaults to Any. - merchant (str, optional): Filters search results to return items - having at least one offer sold by target merchant. Allowed values: - All, Amazon. Defaults to All. - async_req (bool, optional): Specify if a thread should be created to - run the request. Defaults to False. - - Returns: - list of instances: A list containing 1 instance for each product - or None if no results. - """ - - logger.warning('This version of the module is deprecated and it will be removed in future updates. Please upgrade to version 4.0.0 or higher.') - if items_per_page > 10 or items_per_page < 1: - raise AmazonException('ValueError', 'Arg items_per_page should be between 1 and 10') - if item_count > 100 or item_count < 1: - raise AmazonException('ValueError', 'Arg item_count should be between 1 and 100') - if item_page < 1: - raise AmazonException('ValueError', 'Arg item_page should be 1 or higher') - - results = [] - while len(results) < item_count: - try: - request = GetVariationsRequest( - partner_tag=self.tag, - partner_type=PartnerType.ASSOCIATES, - marketplace=self.marketplace, - asin=get_asin(asin), - condition=CONDITION[condition], - merchant=merchant, - offer_count=1, - variation_count=items_per_page, - variation_page=item_page, - resources=VARIATION_RESOURCES) - except KeyError: - raise AmazonException('KeyError', 'Invalid condition value') - except Exception as e: - raise AmazonException('GetVariationsError', e) - - for x in range(3): - try: - # Send the request and create results - self._throttle() - if async_req: - thread = self.api.get_variations(request, async_req=True) - response = thread.get() - else: - response = self.api.get_variations(request) - break - except ApiException as e: - if x == 2: - raise AmazonException('ApiException', e) - try: - if response.variations_result is not None: - if response.variations_result.items is not None: - for item in response.variations_result.items: - results.append(parse_product(item)) - if len(results) >= item_count: - break - if len(response.variations_result.items) < items_per_page: - break - else: - break - if response.errors is not None: - raise AmazonException(response.errors[0].code, response.errors[0].message) - except Exception as e: - raise AmazonException('ResponseError', e) - item_page += 1 - - if results: - return results - else: - return None - - def get_browsenodes(self, browse_nodes, async_req=False): - """Get browse nodes information from Amazon. - - Args: - browse_nodes (list): List of strings containing the browse node ids. - async_req (bool, optional): Specify if a thread should be created to - run the request. Defaults to False. - - Returns: - dict: A dictionary containing the browse node information. - """ - - logger.warning('This version of the module is deprecated and it will be removed in future updates. Please upgrade to version 4.0.0 or higher.') - if isinstance(browse_nodes, list) is False: - raise Exception('Browse nodes parameter should be a list') - elif not browse_nodes: - raise Exception('Browse nodes parameter can\'t be empty') - - try: - request = GetBrowseNodesRequest( - partner_tag=self.tag, - partner_type=PartnerType.ASSOCIATES, - marketplace=self.marketplace, - browse_node_ids=browse_nodes, - languages_of_preference=None, - resources=BROWSE_RESOURCES) - except ValueError as e: - raise AmazonException("ValueError", e) - - try: - self._throttle() - if async_req: - thread = self.api.get_browse_nodes(request, async_req=True) - response = thread.get() - else: - response = self.api.get_browse_nodes(request) - except ApiException as e: - raise AmazonException('ApiException', e) - - try: - if response.browse_nodes_result is not None: - res = [AmazonBrowseNode(item) for item in response.browse_nodes_result.browse_nodes] - return parse_browsenode(res) - if response.errors is not None: - raise AmazonException(response.errors[0].code, response.errors[0].message) - except TypeError as e: - raise AmazonException("TypeError", e) - except ValueError as e: - raise AmazonException(ValueError, e) - except AmazonException as e: - raise AmazonException(e.status, e.reason) - except Exception as e: - raise AmazonException("General", e) diff --git a/amazon/paapi5_python_sdk/COPYING.txt b/amazon/paapi5_python_sdk/COPYING.txt deleted file mode 100644 index d645695..0000000 --- a/amazon/paapi5_python_sdk/COPYING.txt +++ /dev/null @@ -1,202 +0,0 @@ - - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. diff --git a/amazon/paapi5_python_sdk/LICENSE.txt b/amazon/paapi5_python_sdk/LICENSE.txt deleted file mode 100644 index d645695..0000000 --- a/amazon/paapi5_python_sdk/LICENSE.txt +++ /dev/null @@ -1,202 +0,0 @@ - - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. diff --git a/amazon/paapi5_python_sdk/NOTICE.txt b/amazon/paapi5_python_sdk/NOTICE.txt deleted file mode 100644 index 526e5d9..0000000 --- a/amazon/paapi5_python_sdk/NOTICE.txt +++ /dev/null @@ -1,2 +0,0 @@ -Product Advertising API 5.0 SDK for Python -Copyright 2019-2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. \ No newline at end of file diff --git a/amazon/paapi5_python_sdk/__init__.py b/amazon/paapi5_python_sdk/__init__.py deleted file mode 100644 index 33fd32b..0000000 --- a/amazon/paapi5_python_sdk/__init__.py +++ /dev/null @@ -1,123 +0,0 @@ -# coding: utf-8 - -# flake8: noqa - -from __future__ import absolute_import - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -# import apis into sdk package -from .api.default_api import DefaultApi - -# import auth into sdk package -from .auth.sig_v4 import AWSV4Auth - -# import ApiClient -from .api_client import ApiClient -from .configuration import Configuration -# import models into sdk package -from .availability import Availability -from .browse_node import BrowseNode -from .browse_node_ancestor import BrowseNodeAncestor -from .browse_node_child import BrowseNodeChild -from .browse_node_children import BrowseNodeChildren -from .browse_node_info import BrowseNodeInfo -from .browse_nodes_result import BrowseNodesResult -from .by_line_info import ByLineInfo -from .classifications import Classifications -from .condition import Condition -from .content_info import ContentInfo -from .content_rating import ContentRating -from .contributor import Contributor -from .delivery_flag import DeliveryFlag -from .dimension_based_attribute import DimensionBasedAttribute -from .duration_price import DurationPrice -from .error_data import ErrorData -from .external_ids import ExternalIds -from .get_browse_nodes_request import GetBrowseNodesRequest -from .get_browse_nodes_resource import GetBrowseNodesResource -from .get_browse_nodes_response import GetBrowseNodesResponse -from .get_items_request import GetItemsRequest -from .get_items_resource import GetItemsResource -from .get_items_response import GetItemsResponse -from .get_variations_request import GetVariationsRequest -from .get_variations_resource import GetVariationsResource -from .get_variations_response import GetVariationsResponse -from .image_size import ImageSize -from .image_type import ImageType -from .images import Images -from .item import Item -from .item_id_type import ItemIdType -from .item_info import ItemInfo -from .items_result import ItemsResult -from .language_type import LanguageType -from .languages import Languages -from .manufacture_info import ManufactureInfo -from .max_price import MaxPrice -from .merchant import Merchant -from .min_price import MinPrice -from .min_reviews_rating import MinReviewsRating -from .min_saving_percent import MinSavingPercent -from .multi_valued_attribute import MultiValuedAttribute -from .offer_availability import OfferAvailability -from .offer_condition import OfferCondition -from .offer_count import OfferCount -from .offer_delivery_info import OfferDeliveryInfo -from .offer_listing import OfferListing -from .offer_loyalty_points import OfferLoyaltyPoints -from .offer_merchant_info import OfferMerchantInfo -from .offer_price import OfferPrice -from .offer_program_eligibility import OfferProgramEligibility -from .offer_promotion import OfferPromotion -from .offer_savings import OfferSavings -from .offer_shipping_charge import OfferShippingCharge -from .offer_sub_condition import OfferSubCondition -from .offer_summary import OfferSummary -from .offers import Offers -from .partner_type import PartnerType -from .price import Price -from .product_advertising_api_client_exception import ProductAdvertisingAPIClientException -from .product_advertising_api_service_exception import ProductAdvertisingAPIServiceException -from .product_info import ProductInfo -from .properties import Properties -from .refinement import Refinement -from .refinement_bin import RefinementBin -from .rental_offer_listing import RentalOfferListing -from .rental_offers import RentalOffers -from .search_items_request import SearchItemsRequest -from .search_items_resource import SearchItemsResource -from .search_items_response import SearchItemsResponse -from .search_refinements import SearchRefinements -from .search_result import SearchResult -from .single_boolean_valued_attribute import SingleBooleanValuedAttribute -from .single_integer_valued_attribute import SingleIntegerValuedAttribute -from .single_string_valued_attribute import SingleStringValuedAttribute -from .sort_by import SortBy -from .technical_info import TechnicalInfo -from .trade_in_info import TradeInInfo -from .trade_in_price import TradeInPrice -from .unit_based_attribute import UnitBasedAttribute -from .variation_attribute import VariationAttribute -from .variation_dimension import VariationDimension -from .variation_summary import VariationSummary -from .variations_result import VariationsResult -from .website_sales_rank import WebsiteSalesRank diff --git a/amazon/paapi5_python_sdk/api/__init__.py b/amazon/paapi5_python_sdk/api/__init__.py deleted file mode 100644 index 8fa4a5c..0000000 --- a/amazon/paapi5_python_sdk/api/__init__.py +++ /dev/null @@ -1,29 +0,0 @@ -# coding: utf-8 - -# flake8: noqa - -from __future__ import absolute_import - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -# import apis into api package -from .default_api import DefaultApi diff --git a/amazon/paapi5_python_sdk/api/default_api.py b/amazon/paapi5_python_sdk/api/default_api.py deleted file mode 100644 index 268c452..0000000 --- a/amazon/paapi5_python_sdk/api/default_api.py +++ /dev/null @@ -1,428 +0,0 @@ -# coding: utf-8 - -from __future__ import absolute_import - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from ..api_client import ApiClient - - -class DefaultApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, - access_key=None, - secret_key=None, - host=None, - region=None, - api_client=None): - if not host: - host = "webservices.amazon.com" - if not region: - region = "us-east-1" - if api_client is None: - api_client = ApiClient(access_key = access_key, - secret_key = secret_key, - host = host, - region = region) - self.api_client = api_client - - def get_browse_nodes(self, get_browse_nodes_request, **kwargs): # noqa: E501 - """get_browse_nodes # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_browse_nodes(get_browse_nodes_request, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GetBrowseNodesRequest get_browse_nodes_request: GetBrowseNodesRequest (required) - :return: GetBrowseNodesResponse - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - if kwargs.get('async_req'): - return self.get_browse_nodes_with_http_info(get_browse_nodes_request, **kwargs) # noqa: E501 - else: - (data) = self.get_browse_nodes_with_http_info(get_browse_nodes_request, **kwargs) # noqa: E501 - return data - - def get_browse_nodes_with_http_info(self, get_browse_nodes_request, **kwargs): # noqa: E501 - """get_browse_nodes # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_browse_nodes_with_http_info(get_browse_nodes_request, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GetBrowseNodesRequest get_browse_nodes_request: GetBrowseNodesRequest (required) - :return: GetBrowseNodesResponse - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['get_browse_nodes_request'] # noqa: E501 - all_params.append('async_req') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_browse_nodes" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'get_browse_nodes_request' is set - if ('get_browse_nodes_request' not in params or - params['get_browse_nodes_request'] is None): - raise ValueError("Missing the required parameter `get_browse_nodes_request` when calling `get_browse_nodes`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'get_browse_nodes_request' in params: - body_params = params['get_browse_nodes_request'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json']) # noqa: E501 - - # Authentication setting - auth_settings = [] # noqa: E501 - - return self.api_client.call_api( - '/paapi5/getbrowsenodes', 'POST', 'GetBrowseNodes', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GetBrowseNodesResponse', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_items(self, get_items_request, **kwargs): # noqa: E501 - """get_items # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_items(get_items_request, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GetItemsRequest get_items_request: GetItemsRequest (required) - :return: GetItemsResponse - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - if kwargs.get('async_req'): - return self.get_items_with_http_info(get_items_request, **kwargs) # noqa: E501 - else: - (data) = self.get_items_with_http_info(get_items_request, **kwargs) # noqa: E501 - return data - - def get_items_with_http_info(self, get_items_request, **kwargs): # noqa: E501 - """get_items # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_items_with_http_info(get_items_request, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GetItemsRequest get_items_request: GetItemsRequest (required) - :return: GetItemsResponse - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['get_items_request'] # noqa: E501 - all_params.append('async_req') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_items" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'get_items_request' is set - if ('get_items_request' not in params or - params['get_items_request'] is None): - raise ValueError("Missing the required parameter `get_items_request` when calling `get_items`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'get_items_request' in params: - body_params = params['get_items_request'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json']) # noqa: E501 - - # Authentication setting - auth_settings = [] # noqa: E501 - - return self.api_client.call_api( - '/paapi5/getitems', 'POST', 'GetItems', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GetItemsResponse', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_variations(self, get_variations_request, **kwargs): # noqa: E501 - """get_variations # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_variations(get_variations_request, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GetVariationsRequest get_variations_request: GetVariationsRequest (required) - :return: GetVariationsResponse - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - if kwargs.get('async_req'): - return self.get_variations_with_http_info(get_variations_request, **kwargs) # noqa: E501 - else: - (data) = self.get_variations_with_http_info(get_variations_request, **kwargs) # noqa: E501 - return data - - def get_variations_with_http_info(self, get_variations_request, **kwargs): # noqa: E501 - """get_variations # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_variations_with_http_info(get_variations_request, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GetVariationsRequest get_variations_request: GetVariationsRequest (required) - :return: GetVariationsResponse - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['get_variations_request'] # noqa: E501 - all_params.append('async_req') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_variations" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'get_variations_request' is set - if ('get_variations_request' not in params or - params['get_variations_request'] is None): - raise ValueError("Missing the required parameter `get_variations_request` when calling `get_variations`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'get_variations_request' in params: - body_params = params['get_variations_request'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json']) # noqa: E501 - - # Authentication setting - auth_settings = [] # noqa: E501 - - return self.api_client.call_api( - '/paapi5/getvariations', 'POST', 'GetVariations', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GetVariationsResponse', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def search_items(self, search_items_request, **kwargs): # noqa: E501 - """search_items # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.search_items(search_items_request, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param SearchItemsRequest search_items_request: SearchItemsRequest (required) - :return: SearchItemsResponse - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - if kwargs.get('async_req'): - return self.search_items_with_http_info(search_items_request, **kwargs) # noqa: E501 - else: - (data) = self.search_items_with_http_info(search_items_request, **kwargs) # noqa: E501 - return data - - def search_items_with_http_info(self, search_items_request, **kwargs): # noqa: E501 - """search_items # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.search_items_with_http_info(search_items_request, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param SearchItemsRequest search_items_request: SearchItemsRequest (required) - :return: SearchItemsResponse - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['search_items_request'] # noqa: E501 - all_params.append('async_req') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method search_items" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'search_items_request' is set - if ('search_items_request' not in params or - params['search_items_request'] is None): - raise ValueError("Missing the required parameter `search_items_request` when calling `search_items`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'search_items_request' in params: - body_params = params['search_items_request'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json']) # noqa: E501 - - # Authentication setting - auth_settings = [] # noqa: E501 - - return self.api_client.call_api( - '/paapi5/searchitems', 'POST', 'SearchItems', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='SearchItemsResponse', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/amazon/paapi5_python_sdk/api_client.py b/amazon/paapi5_python_sdk/api_client.py deleted file mode 100644 index 5f26b32..0000000 --- a/amazon/paapi5_python_sdk/api_client.py +++ /dev/null @@ -1,685 +0,0 @@ -# coding: utf-8 - -from __future__ import absolute_import - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - -import datetime -import json -import mimetypes -from multiprocessing.pool import ThreadPool -import os -import re -import tempfile - -# python 2 and python 3 compatibility library -import six -from six.moves.urllib.parse import quote - -from .configuration import Configuration -from .. import paapi5_python_sdk -from . import rest - -from .auth.sig_v4 import AWSV4Auth - -class ApiClient(object): - """Generic API client for Swagger client library builds. - - Swagger generic API client. This client handles the client- - server communication, and is invariant across implementations. Specifics of - the methods and models for each application are generated from the Swagger - templates. - - NOTE: This class is auto generated by the swagger code generator program. - Ref: https://github.com/swagger-api/swagger-codegen - Do not edit the class manually. - - :param configuration: .Configuration object for this client - :param header_name: a header to pass when making calls to the API. - :param header_value: a header value to pass when making calls to - the API. - :param cookie: a cookie to include in the header when making calls - to the API - """ - - PRIMITIVE_TYPES = (float, bool, bytes, six.text_type) + six.integer_types - NATIVE_TYPES_MAPPING = { - 'int': int, - 'long': int if six.PY3 else long, # noqa: F821 - 'float': float, - 'str': str, - 'bool': bool, - 'date': datetime.date, - 'datetime': datetime.datetime, - 'object': object, - } - - def __init__(self, - access_key, - secret_key, - host, - region, - configuration=None, - header_name=None, - header_value=None, - cookie=None): - if configuration is None: - configuration = Configuration() - self.configuration = configuration - - self.pool = None - self.rest_client = rest.RESTClientObject(configuration) - self.default_headers = {} - if header_name is not None: - self.default_headers[header_name] = header_value - self.cookie = cookie - # Set default User-Agent. - self.user_agent = 'paapi5-python-sdk/1.0.0' - - self.access_key = access_key - self.secret_key = secret_key - self.host = host - self.region = region - - def __del__(self): - if self.pool is not None: - self.pool.close() - self.pool.join() - - @property - def user_agent(self): - """User agent for this API client""" - return self.default_headers['User-Agent'] - - @user_agent.setter - def user_agent(self, value): - self.default_headers['User-Agent'] = value - - def set_default_header(self, header_name, header_value): - self.default_headers[header_name] = header_value - - def __call_api( - self, resource_path, method, api_name, path_params=None, - query_params=None, header_params=None, body=None, post_params=None, - files=None, response_type=None, auth_settings=None, - _return_http_data_only=None, collection_formats=None, - _preload_content=True, _request_timeout=None): - - if self.access_key is None or self.secret_key is None: - raise ValueError("Missing Credentials (Access Key and SecretKey). Please specify credentials.") - - config = self.configuration - - # header parameters - header_params = header_params or {} - header_params.update(self.default_headers) - if self.cookie: - header_params['Cookie'] = self.cookie - if header_params: - header_params = self.sanitize_for_serialization(header_params) - header_params = dict(self.parameters_to_tuples(header_params, - collection_formats)) - - # path parameters - if path_params: - path_params = self.sanitize_for_serialization(path_params) - path_params = self.parameters_to_tuples(path_params, - collection_formats) - for k, v in path_params: - # specified safe chars, encode everything - resource_path = resource_path.replace( - '{%s}' % k, - quote(str(v), safe=config.safe_chars_for_path_param) - ) - - # query parameters - if query_params: - query_params = self.sanitize_for_serialization(query_params) - query_params = self.parameters_to_tuples(query_params, - collection_formats) - - # post parameters - if post_params or files: - post_params = self.prepare_post_parameters(post_params, files) - post_params = self.sanitize_for_serialization(post_params) - post_params = self.parameters_to_tuples(post_params, - collection_formats) - - # auth setting - self.update_params_for_auth(header_params, query_params, auth_settings, api_name, method, body, resource_path) - - # body - if body: - body = self.sanitize_for_serialization(body) - - # request url - url = "https://" + self.host + resource_path - - # perform request and return response - response_data = self.request( - method, url, query_params=query_params, headers=header_params, - post_params=post_params, body=body, - _preload_content=_preload_content, - _request_timeout=_request_timeout) - - self.last_response = response_data - - return_data = response_data - if _preload_content: - # deserialize response data - if response_type: - return_data = self.deserialize(response_data, response_type) - else: - return_data = None - - if _return_http_data_only: - return (return_data) - else: - return (return_data, response_data.status, - response_data.getheaders()) - - def sanitize_for_serialization(self, obj): - """Builds a JSON POST object. - - If obj is None, return None. - If obj is str, int, long, float, bool, return directly. - If obj is datetime.datetime, datetime.date - convert to string in iso8601 format. - If obj is list, sanitize each element in the list. - If obj is dict, return the dict. - If obj is swagger model, return the properties dict. - - :param obj: The data to serialize. - :return: The serialized form of data. - """ - if obj is None: - return None - elif isinstance(obj, self.PRIMITIVE_TYPES): - return obj - elif isinstance(obj, list): - return [self.sanitize_for_serialization(sub_obj) - for sub_obj in obj] - elif isinstance(obj, tuple): - return tuple(self.sanitize_for_serialization(sub_obj) - for sub_obj in obj) - elif isinstance(obj, (datetime.datetime, datetime.date)): - return obj.isoformat() - - if isinstance(obj, dict): - obj_dict = obj - else: - # Convert model obj to dict except - # attributes `swagger_types`, `attribute_map` - # and attributes which value is not None. - # Convert attribute name to json key in - # model definition for request. - obj_dict = {obj.attribute_map[attr]: getattr(obj, attr) - for attr, _ in six.iteritems(obj.swagger_types) - if getattr(obj, attr) is not None} - - return {key: self.sanitize_for_serialization(val) - for key, val in six.iteritems(obj_dict)} - - def deserialize(self, response, response_type): - """Deserializes response into an object. - - :param response: RESTResponse object to be deserialized. - :param response_type: class literal for - deserialized object, or string of class name. - - :return: deserialized object. - """ - # handle file downloading - # save response body into a tmp file and return the instance - if response_type == "file": - return self.__deserialize_file(response) - - # fetch data from response object - try: - data = json.loads(response.data) - except ValueError: - data = response.data - - return self.__deserialize(data, response_type) - - def __deserialize(self, data, klass): - """Deserializes dict, list, str into an object. - - :param data: dict, list or str. - :param klass: class literal, or string of class name. - - :return: object. - """ - if data is None: - return None - - if type(klass) == str: - if klass.startswith('list['): - sub_kls = re.match(r'list\[(.*)\]', klass).group(1) - return [self.__deserialize(sub_data, sub_kls) - for sub_data in data] - - if klass.startswith('dict('): - sub_kls = re.match(r'dict\(([^,]*), (.*)\)', klass).group(2) - return {k: self.__deserialize(v, sub_kls) - for k, v in six.iteritems(data)} - - # convert str to class - if klass in self.NATIVE_TYPES_MAPPING: - klass = self.NATIVE_TYPES_MAPPING[klass] - else: - klass = getattr(paapi5_python_sdk, klass) - - if klass in self.PRIMITIVE_TYPES: - return self.__deserialize_primitive(data, klass) - elif klass == object: - return self.__deserialize_object(data) - elif klass == datetime.date: - return self.__deserialize_date(data) - elif klass == datetime.datetime: - return self.__deserialize_datatime(data) - else: - return self.__deserialize_model(data, klass) - - def call_api(self, resource_path, method, api_name, - path_params=None, query_params=None, header_params=None, - body=None, post_params=None, files=None, - response_type=None, auth_settings=None, async_req=None, - _return_http_data_only=None, collection_formats=None, - _preload_content=True, _request_timeout=None): - """Makes the HTTP request (synchronous) and returns deserialized data. - - To make an async request, set the async_req parameter. - - :param resource_path: Path to method endpoint. - :param method: Method to call. - :param path_params: Path parameters in the url. - :param query_params: Query parameters in the url. - :param header_params: Header parameters to be - placed in the request header. - :param body: Request body. - :param post_params dict: Request post form parameters, - for `application/x-www-form-urlencoded`, `multipart/form-data`. - :param auth_settings list: Auth Settings names for the request. - :param response: Response data type. - :param files dict: key -> filename, value -> filepath, - for `multipart/form-data`. - :param async_req bool: execute request asynchronously - :param _return_http_data_only: response data without head status code - and headers - :param collection_formats: dict of collection formats for path, query, - header, and post parameters. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: - If async_req parameter is True, - the request will be called asynchronously. - The method will return the request thread. - If parameter async_req is False or missing, - then the method will return the response directly. - """ - if not async_req: - return self.__call_api(resource_path, method, api_name, - path_params, query_params, header_params, - body, post_params, files, - response_type, auth_settings, - _return_http_data_only, collection_formats, - _preload_content, _request_timeout) - else: - if self.pool is None: - self.pool = ThreadPool() - thread = self.pool.apply_async(self.__call_api, (resource_path, - method, api_name, path_params, query_params, - header_params, body, - post_params, files, - response_type, auth_settings, - _return_http_data_only, - collection_formats, - _preload_content, _request_timeout)) - return thread - - def request(self, method, url, query_params=None, headers=None, - post_params=None, body=None, _preload_content=True, - _request_timeout=None): - """Makes the HTTP request using RESTClient.""" - if method == "GET": - return self.rest_client.GET(url, - query_params=query_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - headers=headers) - elif method == "HEAD": - return self.rest_client.HEAD(url, - query_params=query_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - headers=headers) - elif method == "OPTIONS": - return self.rest_client.OPTIONS(url, - query_params=query_params, - headers=headers, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - elif method == "POST": - return self.rest_client.POST(url, - query_params=query_params, - headers=headers, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - elif method == "PUT": - return self.rest_client.PUT(url, - query_params=query_params, - headers=headers, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - elif method == "PATCH": - return self.rest_client.PATCH(url, - query_params=query_params, - headers=headers, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - elif method == "DELETE": - return self.rest_client.DELETE(url, - query_params=query_params, - headers=headers, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - else: - raise ValueError( - "http method must be `GET`, `HEAD`, `OPTIONS`," - " `POST`, `PATCH`, `PUT` or `DELETE`." - ) - - def parameters_to_tuples(self, params, collection_formats): - """Get parameters as list of tuples, formatting collections. - - :param params: Parameters as dict or list of two-tuples - :param dict collection_formats: Parameter collection formats - :return: Parameters as list of tuples, collections formatted - """ - new_params = [] - if collection_formats is None: - collection_formats = {} - for k, v in six.iteritems(params) if isinstance(params, dict) else params: # noqa: E501 - if k in collection_formats: - collection_format = collection_formats[k] - if collection_format == 'multi': - new_params.extend((k, value) for value in v) - else: - if collection_format == 'ssv': - delimiter = ' ' - elif collection_format == 'tsv': - delimiter = '\t' - elif collection_format == 'pipes': - delimiter = '|' - else: # csv is the default - delimiter = ',' - new_params.append( - (k, delimiter.join(str(value) for value in v))) - else: - new_params.append((k, v)) - return new_params - - def prepare_post_parameters(self, post_params=None, files=None): - """Builds form parameters. - - :param post_params: Normal form parameters. - :param files: File parameters. - :return: Form parameters with files. - """ - params = [] - - if post_params: - params = post_params - - if files: - for k, v in six.iteritems(files): - if not v: - continue - file_names = v if type(v) is list else [v] - for n in file_names: - with open(n, 'rb') as f: - filename = os.path.basename(f.name) - filedata = f.read() - mimetype = (mimetypes.guess_type(filename)[0] or - 'application/octet-stream') - params.append( - tuple([k, tuple([filename, filedata, mimetype])])) - - return params - - def select_header_accept(self, accepts): - """Returns `Accept` based on an array of accepts provided. - - :param accepts: List of headers. - :return: Accept (e.g. application/json). - """ - if not accepts: - return - - accepts = [x.lower() for x in accepts] - - if 'application/json' in accepts: - return 'application/json' - else: - return ', '.join(accepts) - - def select_header_content_type(self, content_types): - """Returns `Content-Type` based on an array of content_types provided. - - :param content_types: List of content-types. - :return: Content-Type (e.g. application/json). - """ - if not content_types: - return 'application/json' - - content_types = [x.lower() for x in content_types] - - if 'application/json' in content_types or '*/*' in content_types: - return 'application/json' - else: - return content_types[0] - - def get_amz_date(self, utc_timestamp): - return utc_timestamp.strftime('%Y%m%dT%H%M%SZ') - - def update_params_for_auth(self, headers, querys, auth_settings, api_name, method, body, resource_path): - """Updates header and query params based on authentication setting. - - :param headers: Header parameters dict to be updated. - :param querys: Query parameters tuple list to be updated. - :param auth_settings: Authentication setting identifiers list. - """ - if not auth_settings: - service = 'ProductAdvertisingAPI' - utc_timestamp = datetime.datetime.utcnow() - headers['x-amz-target'] = 'com.amazon.paapi5.v1.ProductAdvertisingAPIv1.' + api_name - headers['content-encoding'] = 'amz-1.0' - headers['Content-Type'] = 'application/json; charset=utf-8' - headers['host'] = self.host - headers['x-amz-date'] = self.get_amz_date(utc_timestamp) - awsv4Auth = AWSV4Auth(access_key=self.access_key, - secret_key=self.secret_key, - host=self.host, - region=self.region, - service=service, - method_name=method, - timestamp=utc_timestamp, - headers=headers, - payload=self.sanitize_for_serialization(body), - path=resource_path) - authHeaders = awsv4Auth.getHeaders() - - return - - for auth in auth_settings: - auth_setting = self.configuration.auth_settings().get(auth) - if auth_setting: - if not auth_setting['value']: - continue - elif auth_setting['in'] == 'header': - headers[auth_setting['key']] = auth_setting['value'] - elif auth_setting['in'] == 'query': - querys.append((auth_setting['key'], auth_setting['value'])) - else: - raise ValueError( - 'Authentication token must be in `query` or `header`' - ) - - def __deserialize_file(self, response): - """Deserializes body to file - - Saves response body into a file in a temporary folder, - using the filename from the `Content-Disposition` header if provided. - - :param response: RESTResponse. - :return: file path. - """ - fd, path = tempfile.mkstemp(dir=self.configuration.temp_folder_path) - os.close(fd) - os.remove(path) - - content_disposition = response.getheader("Content-Disposition") - if content_disposition: - filename = re.search(r'filename=[\'"]?([^\'"\s]+)[\'"]?', - content_disposition).group(1) - path = os.path.join(os.path.dirname(path), filename) - - with open(path, "wb") as f: - f.write(response.data) - - return path - - def __deserialize_primitive(self, data, klass): - """Deserializes string to primitive type. - - :param data: str. - :param klass: class literal. - - :return: int, long, float, str, bool. - """ - try: - return klass(data) - except UnicodeEncodeError: - return six.text_type(data) - #try: - #return unicode(data.replace(r'\\', r'\\\\'), "unicode_escape") - #except TypeError as e: - #if "decoding Unicode is not supported" in str(e): - #return unicode(data.replace(r'\\', r'\\\\')) - except TypeError: - return data - - def __deserialize_object(self, value): - """Return a original value. - - :return: object. - """ - return value - - def __deserialize_date(self, string): - """Deserializes string to date. - - :param string: str. - :return: date. - """ - try: - from dateutil.parser import parse - return parse(string).date() - except ImportError: - return string - except ValueError: - raise rest.ApiException( - status=0, - reason="Failed to parse `{0}` as date object".format(string) - ) - - def __deserialize_datatime(self, string): - """Deserializes string to datetime. - - The string should be in iso8601 datetime format. - - :param string: str. - :return: datetime. - """ - try: - from dateutil.parser import parse - return parse(string) - except ImportError: - return string - except ValueError: - raise rest.ApiException( - status=0, - reason=( - "Failed to parse `{0}` as datetime object" - .format(string) - ) - ) - - def __deserialize_model(self, data, klass): - """Deserializes list or dict to model. - - :param data: dict, list. - :param klass: class literal. - :return: model object. - """ - - if not klass.swagger_types and not hasattr(klass, - 'get_real_child_model'): - return data - - kwargs = {} - if klass.swagger_types is not None: - for attr, attr_type in six.iteritems(klass.swagger_types): - if (data is not None and - klass.attribute_map[attr] in data and - isinstance(data, (list, dict))): - value = data[klass.attribute_map[attr]] - kwargs[attr] = self.__deserialize(value, attr_type) - - instance = klass(**kwargs) - - if (isinstance(instance, dict) and - klass.swagger_types is not None and - isinstance(data, dict)): - for key, value in data.items(): - if key not in klass.swagger_types: - instance[key] = value - if hasattr(instance, 'get_real_child_model'): - klass_name = instance.get_real_child_model(data) - if klass_name: - instance = self.__deserialize(data, klass_name) - return instance diff --git a/amazon/paapi5_python_sdk/auth/__init__.py b/amazon/paapi5_python_sdk/auth/__init__.py deleted file mode 100644 index fe07328..0000000 --- a/amazon/paapi5_python_sdk/auth/__init__.py +++ /dev/null @@ -1,29 +0,0 @@ -# coding: utf-8 - -# flake8: noqa - -from __future__ import absolute_import - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -# import auth into sdk package -from .sig_v4 import AWSV4Auth diff --git a/amazon/paapi5_python_sdk/auth/sig_v4.py b/amazon/paapi5_python_sdk/auth/sig_v4.py deleted file mode 100644 index 6fc4bdc..0000000 --- a/amazon/paapi5_python_sdk/auth/sig_v4.py +++ /dev/null @@ -1,149 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" -ProductAdvertisingAPI - -https://webservices.amazon.com/paapi5/documentation/index.html - -""" - -import hashlib -import hmac -import json - - -class AWSV4Auth: - def __init__( - self, - access_key, - secret_key, - host, - region, - service, - method_name, - timestamp, - headers={}, - path="", - payload="", - ): - self.access_key = access_key - self.secret_key = secret_key - self.host = host - self.region = region - self.service = service - self.method_name = method_name - self.headers = headers - self.timestamp = timestamp - self.payload = payload - self.path = path - - self.xAmzDateTime = self.timestamp.strftime("%Y%m%dT%H%M%SZ") - self.xAmzDate = self.timestamp.strftime("%Y%m%d") - - def getHeaders(self): - canonical_request = self.prepareCanonicalURL() - string_to_sign = self.prepareStringToSign(canonical_request=canonical_request) - signing_key = self.getSignatureKey( - self.secret_key, self.xAmzDate, self.region, self.service - ) - signature = self.getSignature( - signing_key=signing_key, string_to_sign=string_to_sign - ) - - authorization_header = ( - self.algorithm - + " " - + "Credential=" - + self.access_key - + "/" - + self.credential_scope - + ", " - + "SignedHeaders=" - + self.signed_header - + ", " - + "Signature=" - + signature - ) - self.headers["Authorization"] = authorization_header - return self.headers - - def prepareCanonicalURL(self): - canonical_uri = self.method_name + "\n" + self.path - canonical_querystring = "" - canonical_header = "" - self.signed_header = "" - sortedkeys = sorted(self.headers, key=str.lower) - for key in sortedkeys: - self.signed_header = self.signed_header + key.lower() + ";" - canonical_header = ( - canonical_header + key.lower() + ":" + self.headers[key] + "\n" - ) - self.signed_header = self.signed_header[:-1] - payload_hash = hashlib.sha256( - json.dumps(self.payload).encode("utf-8") - ).hexdigest() - canonical_request = ( - canonical_uri - + "\n" - + canonical_querystring - + "\n" - + canonical_header - + "\n" - + self.signed_header - + "\n" - + payload_hash - ) - return canonical_request - - def prepareStringToSign(self, canonical_request): - self.algorithm = "AWS4-HMAC-SHA256" - self.credential_scope = ( - self.xAmzDate - + "/" - + self.region - + "/" - + self.service - + "/" - + "aws4_request" - ) - string_to_sign = ( - self.algorithm - + "\n" - + self.xAmzDateTime - + "\n" - + self.credential_scope - + "\n" - + hashlib.sha256(canonical_request.encode("utf-8")).hexdigest() - ) - return string_to_sign - - def sign(self, key, msg): - return hmac.new(key, msg.encode("utf-8"), hashlib.sha256).digest() - - def getSignatureKey(self, key, dateStamp, regionName, serviceName): - kDate = self.sign(("AWS4" + key).encode("utf-8"), dateStamp) - kRegion = self.sign(kDate, regionName) - kService = self.sign(kRegion, serviceName) - kSigning = self.sign(kService, "aws4_request") - return kSigning - - def getSignature(self, signing_key, string_to_sign): - signature = hmac.new( - signing_key, (string_to_sign).encode("utf-8"), hashlib.sha256 - ).hexdigest() - return signature diff --git a/amazon/paapi5_python_sdk/availability.py b/amazon/paapi5_python_sdk/availability.py deleted file mode 100644 index ff22efa..0000000 --- a/amazon/paapi5_python_sdk/availability.py +++ /dev/null @@ -1,104 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class Availability(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - - """ - allowed enum values - """ - AVAILABLE = "Available" - INCLUDEOUTOFSTOCK = "IncludeOutOfStock" - - """ - 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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """Availability - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(Availability, 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, Availability): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/browse_node.py b/amazon/paapi5_python_sdk/browse_node.py deleted file mode 100644 index 09e8242..0000000 --- a/amazon/paapi5_python_sdk/browse_node.py +++ /dev/null @@ -1,285 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .browse_node_ancestor import BrowseNodeAncestor # noqa: F401,E501 -from .browse_node_children import BrowseNodeChildren # noqa: F401,E501 - - -class BrowseNode(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 = { - 'ancestor': 'BrowseNodeAncestor', - 'children': 'BrowseNodeChildren', - 'context_free_name': 'str', - 'display_name': 'str', - 'id': 'str', - 'is_root': 'bool', - 'sales_rank': 'int' - } - - attribute_map = { - 'ancestor': 'Ancestor', - 'children': 'Children', - 'context_free_name': 'ContextFreeName', - 'display_name': 'DisplayName', - 'id': 'Id', - 'is_root': 'IsRoot', - 'sales_rank': 'SalesRank' - } - - def __init__(self, ancestor=None, children=None, context_free_name=None, display_name=None, id=None, is_root=None, sales_rank=None): # noqa: E501 - """BrowseNode - a model defined in Swagger""" # noqa: E501 - - self._ancestor = None - self._children = None - self._context_free_name = None - self._display_name = None - self._id = None - self._is_root = None - self._sales_rank = None - self.discriminator = None - - if ancestor is not None: - self.ancestor = ancestor - if children is not None: - self.children = children - if context_free_name is not None: - self.context_free_name = context_free_name - if display_name is not None: - self.display_name = display_name - if id is not None: - self.id = id - if is_root is not None: - self.is_root = is_root - if sales_rank is not None: - self.sales_rank = sales_rank - - @property - def ancestor(self): - """Gets the ancestor of this BrowseNode. # noqa: E501 - - - :return: The ancestor of this BrowseNode. # noqa: E501 - :rtype: BrowseNodeAncestor - """ - return self._ancestor - - @ancestor.setter - def ancestor(self, ancestor): - """Sets the ancestor of this BrowseNode. - - - :param ancestor: The ancestor of this BrowseNode. # noqa: E501 - :type: BrowseNodeAncestor - """ - - self._ancestor = ancestor - - @property - def children(self): - """Gets the children of this BrowseNode. # noqa: E501 - - - :return: The children of this BrowseNode. # noqa: E501 - :rtype: BrowseNodeChildren - """ - return self._children - - @children.setter - def children(self, children): - """Sets the children of this BrowseNode. - - - :param children: The children of this BrowseNode. # noqa: E501 - :type: BrowseNodeChildren - """ - - self._children = children - - @property - def context_free_name(self): - """Gets the context_free_name of this BrowseNode. # noqa: E501 - - - :return: The context_free_name of this BrowseNode. # noqa: E501 - :rtype: str - """ - return self._context_free_name - - @context_free_name.setter - def context_free_name(self, context_free_name): - """Sets the context_free_name of this BrowseNode. - - - :param context_free_name: The context_free_name of this BrowseNode. # noqa: E501 - :type: str - """ - - self._context_free_name = context_free_name - - @property - def display_name(self): - """Gets the display_name of this BrowseNode. # noqa: E501 - - - :return: The display_name of this BrowseNode. # noqa: E501 - :rtype: str - """ - return self._display_name - - @display_name.setter - def display_name(self, display_name): - """Sets the display_name of this BrowseNode. - - - :param display_name: The display_name of this BrowseNode. # noqa: E501 - :type: str - """ - - self._display_name = display_name - - @property - def id(self): - """Gets the id of this BrowseNode. # noqa: E501 - - - :return: The id of this BrowseNode. # noqa: E501 - :rtype: str - """ - return self._id - - @id.setter - def id(self, id): - """Sets the id of this BrowseNode. - - - :param id: The id of this BrowseNode. # noqa: E501 - :type: str - """ - - self._id = id - - @property - def is_root(self): - """Gets the is_root of this BrowseNode. # noqa: E501 - - - :return: The is_root of this BrowseNode. # noqa: E501 - :rtype: bool - """ - return self._is_root - - @is_root.setter - def is_root(self, is_root): - """Sets the is_root of this BrowseNode. - - - :param is_root: The is_root of this BrowseNode. # noqa: E501 - :type: bool - """ - - self._is_root = is_root - - @property - def sales_rank(self): - """Gets the sales_rank of this BrowseNode. # noqa: E501 - - - :return: The sales_rank of this BrowseNode. # noqa: E501 - :rtype: int - """ - return self._sales_rank - - @sales_rank.setter - def sales_rank(self, sales_rank): - """Sets the sales_rank of this BrowseNode. - - - :param sales_rank: The sales_rank of this BrowseNode. # noqa: E501 - :type: int - """ - - self._sales_rank = sales_rank - - 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(BrowseNode, 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, BrowseNode): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/browse_node_ancestor.py b/amazon/paapi5_python_sdk/browse_node_ancestor.py deleted file mode 100644 index 72c6514..0000000 --- a/amazon/paapi5_python_sdk/browse_node_ancestor.py +++ /dev/null @@ -1,204 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class BrowseNodeAncestor(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 = { - 'ancestor': 'BrowseNodeAncestor', - 'context_free_name': 'str', - 'display_name': 'str', - 'id': 'str' - } - - attribute_map = { - 'ancestor': 'Ancestor', - 'context_free_name': 'ContextFreeName', - 'display_name': 'DisplayName', - 'id': 'Id' - } - - def __init__(self, ancestor=None, context_free_name=None, display_name=None, id=None): # noqa: E501 - """BrowseNodeAncestor - a model defined in Swagger""" # noqa: E501 - - self._ancestor = None - self._context_free_name = None - self._display_name = None - self._id = None - self.discriminator = None - - if ancestor is not None: - self.ancestor = ancestor - if context_free_name is not None: - self.context_free_name = context_free_name - if display_name is not None: - self.display_name = display_name - if id is not None: - self.id = id - - @property - def ancestor(self): - """Gets the ancestor of this BrowseNodeAncestor. # noqa: E501 - - - :return: The ancestor of this BrowseNodeAncestor. # noqa: E501 - :rtype: BrowseNodeAncestor - """ - return self._ancestor - - @ancestor.setter - def ancestor(self, ancestor): - """Sets the ancestor of this BrowseNodeAncestor. - - - :param ancestor: The ancestor of this BrowseNodeAncestor. # noqa: E501 - :type: BrowseNodeAncestor - """ - - self._ancestor = ancestor - - @property - def context_free_name(self): - """Gets the context_free_name of this BrowseNodeAncestor. # noqa: E501 - - - :return: The context_free_name of this BrowseNodeAncestor. # noqa: E501 - :rtype: str - """ - return self._context_free_name - - @context_free_name.setter - def context_free_name(self, context_free_name): - """Sets the context_free_name of this BrowseNodeAncestor. - - - :param context_free_name: The context_free_name of this BrowseNodeAncestor. # noqa: E501 - :type: str - """ - - self._context_free_name = context_free_name - - @property - def display_name(self): - """Gets the display_name of this BrowseNodeAncestor. # noqa: E501 - - - :return: The display_name of this BrowseNodeAncestor. # noqa: E501 - :rtype: str - """ - return self._display_name - - @display_name.setter - def display_name(self, display_name): - """Sets the display_name of this BrowseNodeAncestor. - - - :param display_name: The display_name of this BrowseNodeAncestor. # noqa: E501 - :type: str - """ - - self._display_name = display_name - - @property - def id(self): - """Gets the id of this BrowseNodeAncestor. # noqa: E501 - - - :return: The id of this BrowseNodeAncestor. # noqa: E501 - :rtype: str - """ - return self._id - - @id.setter - def id(self, id): - """Sets the id of this BrowseNodeAncestor. - - - :param id: The id of this BrowseNodeAncestor. # noqa: E501 - :type: str - """ - - self._id = id - - 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(BrowseNodeAncestor, 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, BrowseNodeAncestor): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/browse_node_child.py b/amazon/paapi5_python_sdk/browse_node_child.py deleted file mode 100644 index 47c2d9d..0000000 --- a/amazon/paapi5_python_sdk/browse_node_child.py +++ /dev/null @@ -1,178 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class BrowseNodeChild(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 = { - 'context_free_name': 'str', - 'display_name': 'str', - 'id': 'str' - } - - attribute_map = { - 'context_free_name': 'ContextFreeName', - 'display_name': 'DisplayName', - 'id': 'Id' - } - - def __init__(self, context_free_name=None, display_name=None, id=None): # noqa: E501 - """BrowseNodeChild - a model defined in Swagger""" # noqa: E501 - - self._context_free_name = None - self._display_name = None - self._id = None - self.discriminator = None - - if context_free_name is not None: - self.context_free_name = context_free_name - if display_name is not None: - self.display_name = display_name - if id is not None: - self.id = id - - @property - def context_free_name(self): - """Gets the context_free_name of this BrowseNodeChild. # noqa: E501 - - - :return: The context_free_name of this BrowseNodeChild. # noqa: E501 - :rtype: str - """ - return self._context_free_name - - @context_free_name.setter - def context_free_name(self, context_free_name): - """Sets the context_free_name of this BrowseNodeChild. - - - :param context_free_name: The context_free_name of this BrowseNodeChild. # noqa: E501 - :type: str - """ - - self._context_free_name = context_free_name - - @property - def display_name(self): - """Gets the display_name of this BrowseNodeChild. # noqa: E501 - - - :return: The display_name of this BrowseNodeChild. # noqa: E501 - :rtype: str - """ - return self._display_name - - @display_name.setter - def display_name(self, display_name): - """Sets the display_name of this BrowseNodeChild. - - - :param display_name: The display_name of this BrowseNodeChild. # noqa: E501 - :type: str - """ - - self._display_name = display_name - - @property - def id(self): - """Gets the id of this BrowseNodeChild. # noqa: E501 - - - :return: The id of this BrowseNodeChild. # noqa: E501 - :rtype: str - """ - return self._id - - @id.setter - def id(self, id): - """Sets the id of this BrowseNodeChild. - - - :param id: The id of this BrowseNodeChild. # noqa: E501 - :type: str - """ - - self._id = id - - 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(BrowseNodeChild, 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, BrowseNodeChild): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/browse_node_children.py b/amazon/paapi5_python_sdk/browse_node_children.py deleted file mode 100644 index 9b9772a..0000000 --- a/amazon/paapi5_python_sdk/browse_node_children.py +++ /dev/null @@ -1,100 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .browse_node_child import BrowseNodeChild # noqa: F401,E501 - - -class BrowseNodeChildren(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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """BrowseNodeChildren - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(BrowseNodeChildren, 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, BrowseNodeChildren): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/browse_node_info.py b/amazon/paapi5_python_sdk/browse_node_info.py deleted file mode 100644 index 52d8de7..0000000 --- a/amazon/paapi5_python_sdk/browse_node_info.py +++ /dev/null @@ -1,155 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .browse_node import BrowseNode # noqa: F401,E501 -from .website_sales_rank import WebsiteSalesRank # noqa: F401,E501 - - -class BrowseNodeInfo(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 = { - 'browse_nodes': 'list[BrowseNode]', - 'website_sales_rank': 'WebsiteSalesRank' - } - - attribute_map = { - 'browse_nodes': 'BrowseNodes', - 'website_sales_rank': 'WebsiteSalesRank' - } - - def __init__(self, browse_nodes=None, website_sales_rank=None): # noqa: E501 - """BrowseNodeInfo - a model defined in Swagger""" # noqa: E501 - - self._browse_nodes = None - self._website_sales_rank = None - self.discriminator = None - - if browse_nodes is not None: - self.browse_nodes = browse_nodes - if website_sales_rank is not None: - self.website_sales_rank = website_sales_rank - - @property - def browse_nodes(self): - """Gets the browse_nodes of this BrowseNodeInfo. # noqa: E501 - - - :return: The browse_nodes of this BrowseNodeInfo. # noqa: E501 - :rtype: list[BrowseNode] - """ - return self._browse_nodes - - @browse_nodes.setter - def browse_nodes(self, browse_nodes): - """Sets the browse_nodes of this BrowseNodeInfo. - - - :param browse_nodes: The browse_nodes of this BrowseNodeInfo. # noqa: E501 - :type: list[BrowseNode] - """ - - self._browse_nodes = browse_nodes - - @property - def website_sales_rank(self): - """Gets the website_sales_rank of this BrowseNodeInfo. # noqa: E501 - - - :return: The website_sales_rank of this BrowseNodeInfo. # noqa: E501 - :rtype: WebsiteSalesRank - """ - return self._website_sales_rank - - @website_sales_rank.setter - def website_sales_rank(self, website_sales_rank): - """Sets the website_sales_rank of this BrowseNodeInfo. - - - :param website_sales_rank: The website_sales_rank of this BrowseNodeInfo. # noqa: E501 - :type: WebsiteSalesRank - """ - - self._website_sales_rank = website_sales_rank - - 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(BrowseNodeInfo, 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, BrowseNodeInfo): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/browse_nodes_result.py b/amazon/paapi5_python_sdk/browse_nodes_result.py deleted file mode 100644 index 0bccd5d..0000000 --- a/amazon/paapi5_python_sdk/browse_nodes_result.py +++ /dev/null @@ -1,128 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .browse_node import BrowseNode # noqa: F401,E501 - - -class BrowseNodesResult(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 = { - 'browse_nodes': 'list[BrowseNode]' - } - - attribute_map = { - 'browse_nodes': 'BrowseNodes' - } - - def __init__(self, browse_nodes=None): # noqa: E501 - """BrowseNodesResult - a model defined in Swagger""" # noqa: E501 - - self._browse_nodes = None - self.discriminator = None - - if browse_nodes is not None: - self.browse_nodes = browse_nodes - - @property - def browse_nodes(self): - """Gets the browse_nodes of this BrowseNodesResult. # noqa: E501 - - - :return: The browse_nodes of this BrowseNodesResult. # noqa: E501 - :rtype: list[BrowseNode] - """ - return self._browse_nodes - - @browse_nodes.setter - def browse_nodes(self, browse_nodes): - """Sets the browse_nodes of this BrowseNodesResult. - - - :param browse_nodes: The browse_nodes of this BrowseNodesResult. # noqa: E501 - :type: list[BrowseNode] - """ - - self._browse_nodes = browse_nodes - - 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(BrowseNodesResult, 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, BrowseNodesResult): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/by_line_info.py b/amazon/paapi5_python_sdk/by_line_info.py deleted file mode 100644 index 9b3052b..0000000 --- a/amazon/paapi5_python_sdk/by_line_info.py +++ /dev/null @@ -1,181 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .contributor import Contributor # noqa: F401,E501 -from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 - - -class ByLineInfo(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 = { - 'brand': 'SingleStringValuedAttribute', - 'contributors': 'list[Contributor]', - 'manufacturer': 'SingleStringValuedAttribute' - } - - attribute_map = { - 'brand': 'Brand', - 'contributors': 'Contributors', - 'manufacturer': 'Manufacturer' - } - - def __init__(self, brand=None, contributors=None, manufacturer=None): # noqa: E501 - """ByLineInfo - a model defined in Swagger""" # noqa: E501 - - self._brand = None - self._contributors = None - self._manufacturer = None - self.discriminator = None - - if brand is not None: - self.brand = brand - if contributors is not None: - self.contributors = contributors - if manufacturer is not None: - self.manufacturer = manufacturer - - @property - def brand(self): - """Gets the brand of this ByLineInfo. # noqa: E501 - - - :return: The brand of this ByLineInfo. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._brand - - @brand.setter - def brand(self, brand): - """Sets the brand of this ByLineInfo. - - - :param brand: The brand of this ByLineInfo. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._brand = brand - - @property - def contributors(self): - """Gets the contributors of this ByLineInfo. # noqa: E501 - - - :return: The contributors of this ByLineInfo. # noqa: E501 - :rtype: list[Contributor] - """ - return self._contributors - - @contributors.setter - def contributors(self, contributors): - """Sets the contributors of this ByLineInfo. - - - :param contributors: The contributors of this ByLineInfo. # noqa: E501 - :type: list[Contributor] - """ - - self._contributors = contributors - - @property - def manufacturer(self): - """Gets the manufacturer of this ByLineInfo. # noqa: E501 - - - :return: The manufacturer of this ByLineInfo. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._manufacturer - - @manufacturer.setter - def manufacturer(self, manufacturer): - """Sets the manufacturer of this ByLineInfo. - - - :param manufacturer: The manufacturer of this ByLineInfo. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._manufacturer = manufacturer - - 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(ByLineInfo, 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, ByLineInfo): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/classifications.py b/amazon/paapi5_python_sdk/classifications.py deleted file mode 100644 index 86e2e25..0000000 --- a/amazon/paapi5_python_sdk/classifications.py +++ /dev/null @@ -1,154 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 - - -class Classifications(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 = { - 'binding': 'SingleStringValuedAttribute', - 'product_group': 'SingleStringValuedAttribute' - } - - attribute_map = { - 'binding': 'Binding', - 'product_group': 'ProductGroup' - } - - def __init__(self, binding=None, product_group=None): # noqa: E501 - """Classifications - a model defined in Swagger""" # noqa: E501 - - self._binding = None - self._product_group = None - self.discriminator = None - - if binding is not None: - self.binding = binding - if product_group is not None: - self.product_group = product_group - - @property - def binding(self): - """Gets the binding of this Classifications. # noqa: E501 - - - :return: The binding of this Classifications. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._binding - - @binding.setter - def binding(self, binding): - """Sets the binding of this Classifications. - - - :param binding: The binding of this Classifications. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._binding = binding - - @property - def product_group(self): - """Gets the product_group of this Classifications. # noqa: E501 - - - :return: The product_group of this Classifications. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._product_group - - @product_group.setter - def product_group(self, product_group): - """Sets the product_group of this Classifications. - - - :param product_group: The product_group of this Classifications. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._product_group = product_group - - 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(Classifications, 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, Classifications): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/condition.py b/amazon/paapi5_python_sdk/condition.py deleted file mode 100644 index 0f554dc..0000000 --- a/amazon/paapi5_python_sdk/condition.py +++ /dev/null @@ -1,107 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class Condition(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - - """ - allowed enum values - """ - ANY = "Any" - COLLECTIBLE = "Collectible" - NEW = "New" - REFURBISHED = "Refurbished" - USED = "Used" - - """ - 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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """Condition - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(Condition, 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, Condition): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/configuration.py b/amazon/paapi5_python_sdk/configuration.py deleted file mode 100644 index 562a9c6..0000000 --- a/amazon/paapi5_python_sdk/configuration.py +++ /dev/null @@ -1,230 +0,0 @@ -# coding: utf-8 - -from __future__ import absolute_import - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - -import copy -import logging -import multiprocessing -import sys -import urllib3 - -import six -from six.moves import http_client as httplib - - -class TypeWithDefault(type): - def __init__(cls, name, bases, dct): - super(TypeWithDefault, cls).__init__(name, bases, dct) - cls._default = None - - def __call__(cls): - if cls._default is None: - cls._default = type.__call__(cls) - return copy.copy(cls._default) - - def set_default(cls, default): - cls._default = copy.copy(default) - - -class Configuration(six.with_metaclass(TypeWithDefault, object)): - """NOTE: This class is auto generated by the swagger code generator program. - - Ref: https://github.com/swagger-api/swagger-codegen - Do not edit the class manually. - """ - - def __init__(self, connection_pool_maxsize=None): - """Constructor""" - # Default Base url - self.host = "https://webservices.amazon.com" - - # Logging Settings - self.logger = {} - self.logger["package_logger"] = logging.getLogger("") - self.logger["urllib3_logger"] = logging.getLogger("urllib3") - # Log format - self.logger_format = '%(asctime)s %(levelname)s %(message)s' - # Log stream handler - self.logger_stream_handler = None - # Log file handler - self.logger_file_handler = None - # Debug file location - self.logger_file = None - # Debug switch - self.debug = False - - # SSL/TLS verification - # Set this to false to skip verifying SSL certificate when calling API - # from https server. - self.verify_ssl = True - # Set this to customize the certificate file to verify the peer. - self.ssl_ca_cert = None - # client certificate file - self.cert_file = None - # client key file - self.key_file = None - # Set this to True/False to enable/disable SSL hostname verification. - self.assert_hostname = None - - # urllib3 connection pool's maximum number of connections saved - # per pool. urllib3 uses 1 connection as default value, but this is - # not the best value when you are making a lot of possibly parallel - # requests to the same host, which is often the case here. - # cpu_count * 5 is used as default value to increase performance. - if connection_pool_maxsize is None: - connection_pool_maxsize = multiprocessing.cpu_count() * 5 - self.connection_pool_maxsize = connection_pool_maxsize - # Proxy URL - self.proxy = None - # Safe chars for path_param - self.safe_chars_for_path_param = '' - - @property - def logger_file(self): - """The logger file. - - If the logger_file is None, then add stream handler and remove file - handler. Otherwise, add file handler and remove stream handler. - - :param value: The logger_file path. - :type: str - """ - return self.__logger_file - - @logger_file.setter - def logger_file(self, value): - """The logger file. - - If the logger_file is None, then add stream handler and remove file - handler. Otherwise, add file handler and remove stream handler. - - :param value: The logger_file path. - :type: str - """ - self.__logger_file = value - if self.__logger_file: - # If set logging file, - # then add file handler and remove stream handler. - self.logger_file_handler = logging.FileHandler(self.__logger_file) - self.logger_file_handler.setFormatter(self.logger_formatter) - for _, logger in six.iteritems(self.logger): - logger.addHandler(self.logger_file_handler) - if self.logger_stream_handler: - logger.removeHandler(self.logger_stream_handler) - else: - # If not set logging file, - # then add stream handler and remove file handler. - self.logger_stream_handler = logging.StreamHandler() - self.logger_stream_handler.setFormatter(self.logger_formatter) - for _, logger in six.iteritems(self.logger): - logger.addHandler(self.logger_stream_handler) - if self.logger_file_handler: - logger.removeHandler(self.logger_file_handler) - - @property - def debug(self): - """Debug status - - :param value: The debug status, True or False. - :type: bool - """ - return self.__debug - - @debug.setter - def debug(self, value): - """Debug status - - :param value: The debug status, True or False. - :type: bool - """ - self.__debug = value - if self.__debug: - # if debug status is True, turn on debug logging - for _, logger in six.iteritems(self.logger): - logger.setLevel(logging.DEBUG) - # turn on httplib debug - httplib.HTTPConnection.debuglevel = 1 - else: - # if debug status is False, turn off debug logging, - # setting log level to default `logging.WARNING` - for _, logger in six.iteritems(self.logger): - logger.setLevel(logging.WARNING) - # turn off httplib debug - httplib.HTTPConnection.debuglevel = 0 - - @property - def logger_format(self): - """The logger format. - - The logger_formatter will be updated when sets logger_format. - - :param value: The format string. - :type: str - """ - return self.__logger_format - - @logger_format.setter - def logger_format(self, value): - """The logger format. - - The logger_formatter will be updated when sets logger_format. - - :param value: The format string. - :type: str - """ - self.__logger_format = value - self.logger_formatter = logging.Formatter(self.__logger_format) - - def get_api_key_with_prefix(self, identifier): - """Gets API key (with prefix if set). - - :param identifier: The identifier of apiKey. - :return: The token for api key authentication. - """ - if (self.api_key.get(identifier) and - self.api_key_prefix.get(identifier)): - return self.api_key_prefix[identifier] + ' ' + self.api_key[identifier] # noqa: E501 - elif self.api_key.get(identifier): - return self.api_key[identifier] - - def auth_settings(self): - """Gets Auth Settings dict for api client. - - :return: The Auth Settings information dict. - """ - return { - - } - - def to_debug_report(self): - """Gets the essential information for debugging. - - :return: The report for debugging. - """ - return "Python SDK Debug Report:\n"\ - "OS: {env}\n"\ - "Python Version: {pyversion}\n"\ - "Version of the API: 1.0.0\n"\ - "SDK Package Version: 1.0.0".\ - format(env=sys.platform, pyversion=sys.version) diff --git a/amazon/paapi5_python_sdk/content_info.py b/amazon/paapi5_python_sdk/content_info.py deleted file mode 100644 index b46e244..0000000 --- a/amazon/paapi5_python_sdk/content_info.py +++ /dev/null @@ -1,208 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .languages import Languages # noqa: F401,E501 -from .single_integer_valued_attribute import SingleIntegerValuedAttribute # noqa: F401,E501 -from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 - - -class ContentInfo(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 = { - 'edition': 'SingleStringValuedAttribute', - 'languages': 'Languages', - 'pages_count': 'SingleIntegerValuedAttribute', - 'publication_date': 'SingleStringValuedAttribute' - } - - attribute_map = { - 'edition': 'Edition', - 'languages': 'Languages', - 'pages_count': 'PagesCount', - 'publication_date': 'PublicationDate' - } - - def __init__(self, edition=None, languages=None, pages_count=None, publication_date=None): # noqa: E501 - """ContentInfo - a model defined in Swagger""" # noqa: E501 - - self._edition = None - self._languages = None - self._pages_count = None - self._publication_date = None - self.discriminator = None - - if edition is not None: - self.edition = edition - if languages is not None: - self.languages = languages - if pages_count is not None: - self.pages_count = pages_count - if publication_date is not None: - self.publication_date = publication_date - - @property - def edition(self): - """Gets the edition of this ContentInfo. # noqa: E501 - - - :return: The edition of this ContentInfo. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._edition - - @edition.setter - def edition(self, edition): - """Sets the edition of this ContentInfo. - - - :param edition: The edition of this ContentInfo. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._edition = edition - - @property - def languages(self): - """Gets the languages of this ContentInfo. # noqa: E501 - - - :return: The languages of this ContentInfo. # noqa: E501 - :rtype: Languages - """ - return self._languages - - @languages.setter - def languages(self, languages): - """Sets the languages of this ContentInfo. - - - :param languages: The languages of this ContentInfo. # noqa: E501 - :type: Languages - """ - - self._languages = languages - - @property - def pages_count(self): - """Gets the pages_count of this ContentInfo. # noqa: E501 - - - :return: The pages_count of this ContentInfo. # noqa: E501 - :rtype: SingleIntegerValuedAttribute - """ - return self._pages_count - - @pages_count.setter - def pages_count(self, pages_count): - """Sets the pages_count of this ContentInfo. - - - :param pages_count: The pages_count of this ContentInfo. # noqa: E501 - :type: SingleIntegerValuedAttribute - """ - - self._pages_count = pages_count - - @property - def publication_date(self): - """Gets the publication_date of this ContentInfo. # noqa: E501 - - - :return: The publication_date of this ContentInfo. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._publication_date - - @publication_date.setter - def publication_date(self, publication_date): - """Sets the publication_date of this ContentInfo. - - - :param publication_date: The publication_date of this ContentInfo. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._publication_date = publication_date - - 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(ContentInfo, 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, ContentInfo): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/content_rating.py b/amazon/paapi5_python_sdk/content_rating.py deleted file mode 100644 index 10ac8f0..0000000 --- a/amazon/paapi5_python_sdk/content_rating.py +++ /dev/null @@ -1,128 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 - - -class ContentRating(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 = { - 'audience_rating': 'SingleStringValuedAttribute' - } - - attribute_map = { - 'audience_rating': 'AudienceRating' - } - - def __init__(self, audience_rating=None): # noqa: E501 - """ContentRating - a model defined in Swagger""" # noqa: E501 - - self._audience_rating = None - self.discriminator = None - - if audience_rating is not None: - self.audience_rating = audience_rating - - @property - def audience_rating(self): - """Gets the audience_rating of this ContentRating. # noqa: E501 - - - :return: The audience_rating of this ContentRating. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._audience_rating - - @audience_rating.setter - def audience_rating(self, audience_rating): - """Sets the audience_rating of this ContentRating. - - - :param audience_rating: The audience_rating of this ContentRating. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._audience_rating = audience_rating - - 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(ContentRating, 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, ContentRating): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/contributor.py b/amazon/paapi5_python_sdk/contributor.py deleted file mode 100644 index 1b1f30e..0000000 --- a/amazon/paapi5_python_sdk/contributor.py +++ /dev/null @@ -1,178 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class Contributor(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 = { - 'locale': 'str', - 'name': 'str', - 'role': 'str' - } - - attribute_map = { - 'locale': 'Locale', - 'name': 'Name', - 'role': 'Role' - } - - def __init__(self, locale=None, name=None, role=None): # noqa: E501 - """Contributor - a model defined in Swagger""" # noqa: E501 - - self._locale = None - self._name = None - self._role = None - self.discriminator = None - - if locale is not None: - self.locale = locale - if name is not None: - self.name = name - if role is not None: - self.role = role - - @property - def locale(self): - """Gets the locale of this Contributor. # noqa: E501 - - - :return: The locale of this Contributor. # noqa: E501 - :rtype: str - """ - return self._locale - - @locale.setter - def locale(self, locale): - """Sets the locale of this Contributor. - - - :param locale: The locale of this Contributor. # noqa: E501 - :type: str - """ - - self._locale = locale - - @property - def name(self): - """Gets the name of this Contributor. # noqa: E501 - - - :return: The name of this Contributor. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this Contributor. - - - :param name: The name of this Contributor. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def role(self): - """Gets the role of this Contributor. # noqa: E501 - - - :return: The role of this Contributor. # noqa: E501 - :rtype: str - """ - return self._role - - @role.setter - def role(self, role): - """Sets the role of this Contributor. - - - :param role: The role of this Contributor. # noqa: E501 - :type: str - """ - - self._role = role - - 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(Contributor, 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, Contributor): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/delivery_flag.py b/amazon/paapi5_python_sdk/delivery_flag.py deleted file mode 100644 index 1f0c469..0000000 --- a/amazon/paapi5_python_sdk/delivery_flag.py +++ /dev/null @@ -1,106 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class DeliveryFlag(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - - """ - allowed enum values - """ - AMAZONGLOBAL = "AmazonGlobal" - FREESHIPPING = "FreeShipping" - FULFILLEDBYAMAZON = "FulfilledByAmazon" - PRIME = "Prime" - - """ - 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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """DeliveryFlag - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(DeliveryFlag, 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, DeliveryFlag): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/dimension_based_attribute.py b/amazon/paapi5_python_sdk/dimension_based_attribute.py deleted file mode 100644 index 04cc4f7..0000000 --- a/amazon/paapi5_python_sdk/dimension_based_attribute.py +++ /dev/null @@ -1,206 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .unit_based_attribute import UnitBasedAttribute # noqa: F401,E501 - - -class DimensionBasedAttribute(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 = { - 'height': 'UnitBasedAttribute', - 'length': 'UnitBasedAttribute', - 'weight': 'UnitBasedAttribute', - 'width': 'UnitBasedAttribute' - } - - attribute_map = { - 'height': 'Height', - 'length': 'Length', - 'weight': 'Weight', - 'width': 'Width' - } - - def __init__(self, height=None, length=None, weight=None, width=None): # noqa: E501 - """DimensionBasedAttribute - a model defined in Swagger""" # noqa: E501 - - self._height = None - self._length = None - self._weight = None - self._width = None - self.discriminator = None - - if height is not None: - self.height = height - if length is not None: - self.length = length - if weight is not None: - self.weight = weight - if width is not None: - self.width = width - - @property - def height(self): - """Gets the height of this DimensionBasedAttribute. # noqa: E501 - - - :return: The height of this DimensionBasedAttribute. # noqa: E501 - :rtype: UnitBasedAttribute - """ - return self._height - - @height.setter - def height(self, height): - """Sets the height of this DimensionBasedAttribute. - - - :param height: The height of this DimensionBasedAttribute. # noqa: E501 - :type: UnitBasedAttribute - """ - - self._height = height - - @property - def length(self): - """Gets the length of this DimensionBasedAttribute. # noqa: E501 - - - :return: The length of this DimensionBasedAttribute. # noqa: E501 - :rtype: UnitBasedAttribute - """ - return self._length - - @length.setter - def length(self, length): - """Sets the length of this DimensionBasedAttribute. - - - :param length: The length of this DimensionBasedAttribute. # noqa: E501 - :type: UnitBasedAttribute - """ - - self._length = length - - @property - def weight(self): - """Gets the weight of this DimensionBasedAttribute. # noqa: E501 - - - :return: The weight of this DimensionBasedAttribute. # noqa: E501 - :rtype: UnitBasedAttribute - """ - return self._weight - - @weight.setter - def weight(self, weight): - """Sets the weight of this DimensionBasedAttribute. - - - :param weight: The weight of this DimensionBasedAttribute. # noqa: E501 - :type: UnitBasedAttribute - """ - - self._weight = weight - - @property - def width(self): - """Gets the width of this DimensionBasedAttribute. # noqa: E501 - - - :return: The width of this DimensionBasedAttribute. # noqa: E501 - :rtype: UnitBasedAttribute - """ - return self._width - - @width.setter - def width(self, width): - """Sets the width of this DimensionBasedAttribute. - - - :param width: The width of this DimensionBasedAttribute. # noqa: E501 - :type: UnitBasedAttribute - """ - - self._width = width - - 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(DimensionBasedAttribute, 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, DimensionBasedAttribute): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/duration_price.py b/amazon/paapi5_python_sdk/duration_price.py deleted file mode 100644 index 724fe4b..0000000 --- a/amazon/paapi5_python_sdk/duration_price.py +++ /dev/null @@ -1,155 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .offer_price import OfferPrice # noqa: F401,E501 -from .unit_based_attribute import UnitBasedAttribute # noqa: F401,E501 - - -class DurationPrice(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 = { - 'price': 'OfferPrice', - 'duration': 'UnitBasedAttribute' - } - - attribute_map = { - 'price': 'Price', - 'duration': 'Duration' - } - - def __init__(self, price=None, duration=None): # noqa: E501 - """DurationPrice - a model defined in Swagger""" # noqa: E501 - - self._price = None - self._duration = None - self.discriminator = None - - if price is not None: - self.price = price - if duration is not None: - self.duration = duration - - @property - def price(self): - """Gets the price of this DurationPrice. # noqa: E501 - - - :return: The price of this DurationPrice. # noqa: E501 - :rtype: OfferPrice - """ - return self._price - - @price.setter - def price(self, price): - """Sets the price of this DurationPrice. - - - :param price: The price of this DurationPrice. # noqa: E501 - :type: OfferPrice - """ - - self._price = price - - @property - def duration(self): - """Gets the duration of this DurationPrice. # noqa: E501 - - - :return: The duration of this DurationPrice. # noqa: E501 - :rtype: UnitBasedAttribute - """ - return self._duration - - @duration.setter - def duration(self, duration): - """Sets the duration of this DurationPrice. - - - :param duration: The duration of this DurationPrice. # noqa: E501 - :type: UnitBasedAttribute - """ - - self._duration = duration - - 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(DurationPrice, 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, DurationPrice): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/error_data.py b/amazon/paapi5_python_sdk/error_data.py deleted file mode 100644 index 3d6b106..0000000 --- a/amazon/paapi5_python_sdk/error_data.py +++ /dev/null @@ -1,152 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class ErrorData(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 = { - 'code': 'str', - 'message': 'str' - } - - attribute_map = { - 'code': 'Code', - 'message': 'Message' - } - - def __init__(self, code=None, message=None): # noqa: E501 - """ErrorData - a model defined in Swagger""" # noqa: E501 - - self._code = None - self._message = None - self.discriminator = None - - if code is not None: - self.code = code - if message is not None: - self.message = message - - @property - def code(self): - """Gets the code of this ErrorData. # noqa: E501 - - - :return: The code of this ErrorData. # noqa: E501 - :rtype: str - """ - return self._code - - @code.setter - def code(self, code): - """Sets the code of this ErrorData. - - - :param code: The code of this ErrorData. # noqa: E501 - :type: str - """ - - self._code = code - - @property - def message(self): - """Gets the message of this ErrorData. # noqa: E501 - - - :return: The message of this ErrorData. # noqa: E501 - :rtype: str - """ - return self._message - - @message.setter - def message(self, message): - """Sets the message of this ErrorData. - - - :param message: The message of this ErrorData. # noqa: E501 - :type: str - """ - - self._message = message - - 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(ErrorData, 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, ErrorData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/external_ids.py b/amazon/paapi5_python_sdk/external_ids.py deleted file mode 100644 index ff545a7..0000000 --- a/amazon/paapi5_python_sdk/external_ids.py +++ /dev/null @@ -1,180 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .multi_valued_attribute import MultiValuedAttribute # noqa: F401,E501 - - -class ExternalIds(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 = { - 'ea_ns': 'MultiValuedAttribute', - 'isb_ns': 'MultiValuedAttribute', - 'up_cs': 'MultiValuedAttribute' - } - - attribute_map = { - 'ea_ns': 'EANs', - 'isb_ns': 'ISBNs', - 'up_cs': 'UPCs' - } - - def __init__(self, ea_ns=None, isb_ns=None, up_cs=None): # noqa: E501 - """ExternalIds - a model defined in Swagger""" # noqa: E501 - - self._ea_ns = None - self._isb_ns = None - self._up_cs = None - self.discriminator = None - - if ea_ns is not None: - self.ea_ns = ea_ns - if isb_ns is not None: - self.isb_ns = isb_ns - if up_cs is not None: - self.up_cs = up_cs - - @property - def ea_ns(self): - """Gets the ea_ns of this ExternalIds. # noqa: E501 - - - :return: The ea_ns of this ExternalIds. # noqa: E501 - :rtype: MultiValuedAttribute - """ - return self._ea_ns - - @ea_ns.setter - def ea_ns(self, ea_ns): - """Sets the ea_ns of this ExternalIds. - - - :param ea_ns: The ea_ns of this ExternalIds. # noqa: E501 - :type: MultiValuedAttribute - """ - - self._ea_ns = ea_ns - - @property - def isb_ns(self): - """Gets the isb_ns of this ExternalIds. # noqa: E501 - - - :return: The isb_ns of this ExternalIds. # noqa: E501 - :rtype: MultiValuedAttribute - """ - return self._isb_ns - - @isb_ns.setter - def isb_ns(self, isb_ns): - """Sets the isb_ns of this ExternalIds. - - - :param isb_ns: The isb_ns of this ExternalIds. # noqa: E501 - :type: MultiValuedAttribute - """ - - self._isb_ns = isb_ns - - @property - def up_cs(self): - """Gets the up_cs of this ExternalIds. # noqa: E501 - - - :return: The up_cs of this ExternalIds. # noqa: E501 - :rtype: MultiValuedAttribute - """ - return self._up_cs - - @up_cs.setter - def up_cs(self, up_cs): - """Sets the up_cs of this ExternalIds. - - - :param up_cs: The up_cs of this ExternalIds. # noqa: E501 - :type: MultiValuedAttribute - """ - - self._up_cs = up_cs - - 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(ExternalIds, 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, ExternalIds): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/get_browse_nodes_request.py b/amazon/paapi5_python_sdk/get_browse_nodes_request.py deleted file mode 100644 index 6d5d57b..0000000 --- a/amazon/paapi5_python_sdk/get_browse_nodes_request.py +++ /dev/null @@ -1,262 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .get_browse_nodes_resource import GetBrowseNodesResource # noqa: F401,E501 -from .partner_type import PartnerType # noqa: F401,E501 - - -class GetBrowseNodesRequest(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 = { - 'browse_node_ids': 'list[str]', - 'languages_of_preference': 'list[str]', - 'marketplace': 'str', - 'partner_tag': 'str', - 'partner_type': 'PartnerType', - 'resources': 'list[GetBrowseNodesResource]' - } - - attribute_map = { - 'browse_node_ids': 'BrowseNodeIds', - 'languages_of_preference': 'LanguagesOfPreference', - 'marketplace': 'Marketplace', - 'partner_tag': 'PartnerTag', - 'partner_type': 'PartnerType', - 'resources': 'Resources' - } - - def __init__(self, browse_node_ids=None, languages_of_preference=None, marketplace=None, partner_tag=None, partner_type=None, resources=None): # noqa: E501 - """GetBrowseNodesRequest - a model defined in Swagger""" # noqa: E501 - - self._browse_node_ids = None - self._languages_of_preference = None - self._marketplace = None - self._partner_tag = None - self._partner_type = None - self._resources = None - self.discriminator = None - - self.browse_node_ids = browse_node_ids - if languages_of_preference is not None: - self.languages_of_preference = languages_of_preference - if marketplace is not None: - self.marketplace = marketplace - self.partner_tag = partner_tag - self.partner_type = partner_type - if resources is not None: - self.resources = resources - - @property - def browse_node_ids(self): - """Gets the browse_node_ids of this GetBrowseNodesRequest. # noqa: E501 - - - :return: The browse_node_ids of this GetBrowseNodesRequest. # noqa: E501 - :rtype: list[str] - """ - return self._browse_node_ids - - @browse_node_ids.setter - def browse_node_ids(self, browse_node_ids): - """Sets the browse_node_ids of this GetBrowseNodesRequest. - - - :param browse_node_ids: The browse_node_ids of this GetBrowseNodesRequest. # noqa: E501 - :type: list[str] - """ - if browse_node_ids is None: - raise ValueError("Invalid value for `browse_node_ids`, must not be `None`") # noqa: E501 - - self._browse_node_ids = browse_node_ids - - @property - def languages_of_preference(self): - """Gets the languages_of_preference of this GetBrowseNodesRequest. # noqa: E501 - - - :return: The languages_of_preference of this GetBrowseNodesRequest. # noqa: E501 - :rtype: list[str] - """ - return self._languages_of_preference - - @languages_of_preference.setter - def languages_of_preference(self, languages_of_preference): - """Sets the languages_of_preference of this GetBrowseNodesRequest. - - - :param languages_of_preference: The languages_of_preference of this GetBrowseNodesRequest. # noqa: E501 - :type: list[str] - """ - - self._languages_of_preference = languages_of_preference - - @property - def marketplace(self): - """Gets the marketplace of this GetBrowseNodesRequest. # noqa: E501 - - - :return: The marketplace of this GetBrowseNodesRequest. # noqa: E501 - :rtype: str - """ - return self._marketplace - - @marketplace.setter - def marketplace(self, marketplace): - """Sets the marketplace of this GetBrowseNodesRequest. - - - :param marketplace: The marketplace of this GetBrowseNodesRequest. # noqa: E501 - :type: str - """ - - self._marketplace = marketplace - - @property - def partner_tag(self): - """Gets the partner_tag of this GetBrowseNodesRequest. # noqa: E501 - - - :return: The partner_tag of this GetBrowseNodesRequest. # noqa: E501 - :rtype: str - """ - return self._partner_tag - - @partner_tag.setter - def partner_tag(self, partner_tag): - """Sets the partner_tag of this GetBrowseNodesRequest. - - - :param partner_tag: The partner_tag of this GetBrowseNodesRequest. # noqa: E501 - :type: str - """ - if partner_tag is None: - raise ValueError("Invalid value for `partner_tag`, must not be `None`") # noqa: E501 - - self._partner_tag = partner_tag - - @property - def partner_type(self): - """Gets the partner_type of this GetBrowseNodesRequest. # noqa: E501 - - - :return: The partner_type of this GetBrowseNodesRequest. # noqa: E501 - :rtype: PartnerType - """ - return self._partner_type - - @partner_type.setter - def partner_type(self, partner_type): - """Sets the partner_type of this GetBrowseNodesRequest. - - - :param partner_type: The partner_type of this GetBrowseNodesRequest. # noqa: E501 - :type: PartnerType - """ - if partner_type is None: - raise ValueError("Invalid value for `partner_type`, must not be `None`") # noqa: E501 - - self._partner_type = partner_type - - @property - def resources(self): - """Gets the resources of this GetBrowseNodesRequest. # noqa: E501 - - - :return: The resources of this GetBrowseNodesRequest. # noqa: E501 - :rtype: list[GetBrowseNodesResource] - """ - return self._resources - - @resources.setter - def resources(self, resources): - """Sets the resources of this GetBrowseNodesRequest. - - - :param resources: The resources of this GetBrowseNodesRequest. # noqa: E501 - :type: list[GetBrowseNodesResource] - """ - - self._resources = resources - - 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(GetBrowseNodesRequest, 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, GetBrowseNodesRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/get_browse_nodes_resource.py b/amazon/paapi5_python_sdk/get_browse_nodes_resource.py deleted file mode 100644 index 4e7ff94..0000000 --- a/amazon/paapi5_python_sdk/get_browse_nodes_resource.py +++ /dev/null @@ -1,104 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class GetBrowseNodesResource(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - - """ - allowed enum values - """ - ANCESTOR = "BrowseNodes.Ancestor" - CHILDREN = "BrowseNodes.Children" - - """ - 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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """GetBrowseNodesResource - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(GetBrowseNodesResource, 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, GetBrowseNodesResource): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/get_browse_nodes_response.py b/amazon/paapi5_python_sdk/get_browse_nodes_response.py deleted file mode 100644 index 10e0a21..0000000 --- a/amazon/paapi5_python_sdk/get_browse_nodes_response.py +++ /dev/null @@ -1,155 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .browse_nodes_result import BrowseNodesResult # noqa: F401,E501 -from .error_data import ErrorData # noqa: F401,E501 - - -class GetBrowseNodesResponse(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 = { - 'browse_nodes_result': 'BrowseNodesResult', - 'errors': 'list[ErrorData]' - } - - attribute_map = { - 'browse_nodes_result': 'BrowseNodesResult', - 'errors': 'Errors' - } - - def __init__(self, browse_nodes_result=None, errors=None): # noqa: E501 - """GetBrowseNodesResponse - a model defined in Swagger""" # noqa: E501 - - self._browse_nodes_result = None - self._errors = None - self.discriminator = None - - if browse_nodes_result is not None: - self.browse_nodes_result = browse_nodes_result - if errors is not None: - self.errors = errors - - @property - def browse_nodes_result(self): - """Gets the browse_nodes_result of this GetBrowseNodesResponse. # noqa: E501 - - - :return: The browse_nodes_result of this GetBrowseNodesResponse. # noqa: E501 - :rtype: BrowseNodesResult - """ - return self._browse_nodes_result - - @browse_nodes_result.setter - def browse_nodes_result(self, browse_nodes_result): - """Sets the browse_nodes_result of this GetBrowseNodesResponse. - - - :param browse_nodes_result: The browse_nodes_result of this GetBrowseNodesResponse. # noqa: E501 - :type: BrowseNodesResult - """ - - self._browse_nodes_result = browse_nodes_result - - @property - def errors(self): - """Gets the errors of this GetBrowseNodesResponse. # noqa: E501 - - - :return: The errors of this GetBrowseNodesResponse. # noqa: E501 - :rtype: list[ErrorData] - """ - return self._errors - - @errors.setter - def errors(self, errors): - """Sets the errors of this GetBrowseNodesResponse. - - - :param errors: The errors of this GetBrowseNodesResponse. # noqa: E501 - :type: list[ErrorData] - """ - - self._errors = errors - - 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(GetBrowseNodesResponse, 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, GetBrowseNodesResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/get_items_request.py b/amazon/paapi5_python_sdk/get_items_request.py deleted file mode 100644 index 567ba65..0000000 --- a/amazon/paapi5_python_sdk/get_items_request.py +++ /dev/null @@ -1,423 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .condition import Condition # noqa: F401,E501 -from .get_items_resource import GetItemsResource # noqa: F401,E501 -from .item_id_type import ItemIdType # noqa: F401,E501 -from .merchant import Merchant # noqa: F401,E501 -from .offer_count import OfferCount # noqa: F401,E501 -from .partner_type import PartnerType # noqa: F401,E501 -from .properties import Properties # noqa: F401,E501 - - -class GetItemsRequest(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 = { - 'condition': 'Condition', - 'currency_of_preference': 'str', - 'item_ids': 'list[str]', - 'item_id_type': 'ItemIdType', - 'languages_of_preference': 'list[str]', - 'marketplace': 'str', - 'merchant': 'Merchant', - 'offer_count': 'OfferCount', - 'partner_tag': 'str', - 'partner_type': 'PartnerType', - 'properties': 'Properties', - 'resources': 'list[GetItemsResource]' - } - - attribute_map = { - 'condition': 'Condition', - 'currency_of_preference': 'CurrencyOfPreference', - 'item_ids': 'ItemIds', - 'item_id_type': 'ItemIdType', - 'languages_of_preference': 'LanguagesOfPreference', - 'marketplace': 'Marketplace', - 'merchant': 'Merchant', - 'offer_count': 'OfferCount', - 'partner_tag': 'PartnerTag', - 'partner_type': 'PartnerType', - 'properties': 'Properties', - 'resources': 'Resources' - } - - def __init__(self, condition=None, currency_of_preference=None, item_ids=None, item_id_type=None, languages_of_preference=None, marketplace=None, merchant=None, offer_count=None, partner_tag=None, partner_type=None, properties=None, resources=None): # noqa: E501 - """GetItemsRequest - a model defined in Swagger""" # noqa: E501 - - self._condition = None - self._currency_of_preference = None - self._item_ids = None - self._item_id_type = None - self._languages_of_preference = None - self._marketplace = None - self._merchant = None - self._offer_count = None - self._partner_tag = None - self._partner_type = None - self._properties = None - self._resources = None - self.discriminator = None - - if condition is not None: - self.condition = condition - if currency_of_preference is not None: - self.currency_of_preference = currency_of_preference - self.item_ids = item_ids - if item_id_type is not None: - self.item_id_type = item_id_type - if languages_of_preference is not None: - self.languages_of_preference = languages_of_preference - if marketplace is not None: - self.marketplace = marketplace - if merchant is not None: - self.merchant = merchant - if offer_count is not None: - self.offer_count = offer_count - self.partner_tag = partner_tag - self.partner_type = partner_type - if properties is not None: - self.properties = properties - if resources is not None: - self.resources = resources - - @property - def condition(self): - """Gets the condition of this GetItemsRequest. # noqa: E501 - - - :return: The condition of this GetItemsRequest. # noqa: E501 - :rtype: Condition - """ - return self._condition - - @condition.setter - def condition(self, condition): - """Sets the condition of this GetItemsRequest. - - - :param condition: The condition of this GetItemsRequest. # noqa: E501 - :type: Condition - """ - - self._condition = condition - - @property - def currency_of_preference(self): - """Gets the currency_of_preference of this GetItemsRequest. # noqa: E501 - - - :return: The currency_of_preference of this GetItemsRequest. # noqa: E501 - :rtype: str - """ - return self._currency_of_preference - - @currency_of_preference.setter - def currency_of_preference(self, currency_of_preference): - """Sets the currency_of_preference of this GetItemsRequest. - - - :param currency_of_preference: The currency_of_preference of this GetItemsRequest. # noqa: E501 - :type: str - """ - - self._currency_of_preference = currency_of_preference - - @property - def item_ids(self): - """Gets the item_ids of this GetItemsRequest. # noqa: E501 - - - :return: The item_ids of this GetItemsRequest. # noqa: E501 - :rtype: list[str] - """ - return self._item_ids - - @item_ids.setter - def item_ids(self, item_ids): - """Sets the item_ids of this GetItemsRequest. - - - :param item_ids: The item_ids of this GetItemsRequest. # noqa: E501 - :type: list[str] - """ - if item_ids is None: - raise ValueError("Invalid value for `item_ids`, must not be `None`") # noqa: E501 - - self._item_ids = item_ids - - @property - def item_id_type(self): - """Gets the item_id_type of this GetItemsRequest. # noqa: E501 - - - :return: The item_id_type of this GetItemsRequest. # noqa: E501 - :rtype: ItemIdType - """ - return self._item_id_type - - @item_id_type.setter - def item_id_type(self, item_id_type): - """Sets the item_id_type of this GetItemsRequest. - - - :param item_id_type: The item_id_type of this GetItemsRequest. # noqa: E501 - :type: ItemIdType - """ - - self._item_id_type = item_id_type - - @property - def languages_of_preference(self): - """Gets the languages_of_preference of this GetItemsRequest. # noqa: E501 - - - :return: The languages_of_preference of this GetItemsRequest. # noqa: E501 - :rtype: list[str] - """ - return self._languages_of_preference - - @languages_of_preference.setter - def languages_of_preference(self, languages_of_preference): - """Sets the languages_of_preference of this GetItemsRequest. - - - :param languages_of_preference: The languages_of_preference of this GetItemsRequest. # noqa: E501 - :type: list[str] - """ - - self._languages_of_preference = languages_of_preference - - @property - def marketplace(self): - """Gets the marketplace of this GetItemsRequest. # noqa: E501 - - - :return: The marketplace of this GetItemsRequest. # noqa: E501 - :rtype: str - """ - return self._marketplace - - @marketplace.setter - def marketplace(self, marketplace): - """Sets the marketplace of this GetItemsRequest. - - - :param marketplace: The marketplace of this GetItemsRequest. # noqa: E501 - :type: str - """ - - self._marketplace = marketplace - - @property - def merchant(self): - """Gets the merchant of this GetItemsRequest. # noqa: E501 - - - :return: The merchant of this GetItemsRequest. # noqa: E501 - :rtype: Merchant - """ - return self._merchant - - @merchant.setter - def merchant(self, merchant): - """Sets the merchant of this GetItemsRequest. - - - :param merchant: The merchant of this GetItemsRequest. # noqa: E501 - :type: Merchant - """ - - self._merchant = merchant - - @property - def offer_count(self): - """Gets the offer_count of this GetItemsRequest. # noqa: E501 - - - :return: The offer_count of this GetItemsRequest. # noqa: E501 - :rtype: OfferCount - """ - return self._offer_count - - @offer_count.setter - def offer_count(self, offer_count): - """Sets the offer_count of this GetItemsRequest. - - - :param offer_count: The offer_count of this GetItemsRequest. # noqa: E501 - :type: OfferCount - """ - - self._offer_count = offer_count - - @property - def partner_tag(self): - """Gets the partner_tag of this GetItemsRequest. # noqa: E501 - - - :return: The partner_tag of this GetItemsRequest. # noqa: E501 - :rtype: str - """ - return self._partner_tag - - @partner_tag.setter - def partner_tag(self, partner_tag): - """Sets the partner_tag of this GetItemsRequest. - - - :param partner_tag: The partner_tag of this GetItemsRequest. # noqa: E501 - :type: str - """ - if partner_tag is None: - raise ValueError("Invalid value for `partner_tag`, must not be `None`") # noqa: E501 - - self._partner_tag = partner_tag - - @property - def partner_type(self): - """Gets the partner_type of this GetItemsRequest. # noqa: E501 - - - :return: The partner_type of this GetItemsRequest. # noqa: E501 - :rtype: PartnerType - """ - return self._partner_type - - @partner_type.setter - def partner_type(self, partner_type): - """Sets the partner_type of this GetItemsRequest. - - - :param partner_type: The partner_type of this GetItemsRequest. # noqa: E501 - :type: PartnerType - """ - if partner_type is None: - raise ValueError("Invalid value for `partner_type`, must not be `None`") # noqa: E501 - - self._partner_type = partner_type - - @property - def properties(self): - """Gets the properties of this GetItemsRequest. # noqa: E501 - - - :return: The properties of this GetItemsRequest. # noqa: E501 - :rtype: Properties - """ - return self._properties - - @properties.setter - def properties(self, properties): - """Sets the properties of this GetItemsRequest. - - - :param properties: The properties of this GetItemsRequest. # noqa: E501 - :type: Properties - """ - - self._properties = properties - - @property - def resources(self): - """Gets the resources of this GetItemsRequest. # noqa: E501 - - - :return: The resources of this GetItemsRequest. # noqa: E501 - :rtype: list[GetItemsResource] - """ - return self._resources - - @resources.setter - def resources(self, resources): - """Sets the resources of this GetItemsRequest. - - - :param resources: The resources of this GetItemsRequest. # noqa: E501 - :type: list[GetItemsResource] - """ - - self._resources = resources - - 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(GetItemsRequest, 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, GetItemsRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/get_items_resource.py b/amazon/paapi5_python_sdk/get_items_resource.py deleted file mode 100644 index b0ddcc5..0000000 --- a/amazon/paapi5_python_sdk/get_items_resource.py +++ /dev/null @@ -1,157 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class GetItemsResource(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - - """ - allowed enum values - """ - BROWSENODEINFO_BROWSENODES = "BrowseNodeInfo.BrowseNodes" - BROWSENODEINFO_BROWSENODES_ANCESTOR = "BrowseNodeInfo.BrowseNodes.Ancestor" - BROWSENODEINFO_BROWSENODES_SALESRANK = "BrowseNodeInfo.BrowseNodes.SalesRank" - BROWSENODEINFO_WEBSITESALESRANK = "BrowseNodeInfo.WebsiteSalesRank" - IMAGES_PRIMARY_SMALL = "Images.Primary.Small" - IMAGES_PRIMARY_MEDIUM = "Images.Primary.Medium" - IMAGES_PRIMARY_LARGE = "Images.Primary.Large" - IMAGES_VARIANTS_SMALL = "Images.Variants.Small" - IMAGES_VARIANTS_MEDIUM = "Images.Variants.Medium" - IMAGES_VARIANTS_LARGE = "Images.Variants.Large" - ITEMINFO_BYLINEINFO = "ItemInfo.ByLineInfo" - ITEMINFO_CONTENTINFO = "ItemInfo.ContentInfo" - ITEMINFO_CONTENTRATING = "ItemInfo.ContentRating" - ITEMINFO_CLASSIFICATIONS = "ItemInfo.Classifications" - ITEMINFO_EXTERNALIDS = "ItemInfo.ExternalIds" - ITEMINFO_FEATURES = "ItemInfo.Features" - ITEMINFO_MANUFACTUREINFO = "ItemInfo.ManufactureInfo" - ITEMINFO_PRODUCTINFO = "ItemInfo.ProductInfo" - ITEMINFO_TECHNICALINFO = "ItemInfo.TechnicalInfo" - ITEMINFO_TITLE = "ItemInfo.Title" - ITEMINFO_TRADEININFO = "ItemInfo.TradeInInfo" - OFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY = "Offers.Listings.Availability.MaxOrderQuantity" - OFFERS_LISTINGS_AVAILABILITY_MESSAGE = "Offers.Listings.Availability.Message" - OFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY = "Offers.Listings.Availability.MinOrderQuantity" - OFFERS_LISTINGS_AVAILABILITY_TYPE = "Offers.Listings.Availability.Type" - OFFERS_LISTINGS_CONDITION = "Offers.Listings.Condition" - OFFERS_LISTINGS_CONDITION_SUBCONDITION = "Offers.Listings.Condition.SubCondition" - OFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED = "Offers.Listings.DeliveryInfo.IsAmazonFulfilled" - OFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE = "Offers.Listings.DeliveryInfo.IsFreeShippingEligible" - OFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE = "Offers.Listings.DeliveryInfo.IsPrimeEligible" - OFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES = "Offers.Listings.DeliveryInfo.ShippingCharges" - OFFERS_LISTINGS_ISBUYBOXWINNER = "Offers.Listings.IsBuyBoxWinner" - OFFERS_LISTINGS_LOYALTYPOINTS_POINTS = "Offers.Listings.LoyaltyPoints.Points" - OFFERS_LISTINGS_MERCHANTINFO = "Offers.Listings.MerchantInfo" - OFFERS_LISTINGS_PRICE = "Offers.Listings.Price" - OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEEXCLUSIVE = "Offers.Listings.ProgramEligibility.IsPrimeExclusive" - OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEPANTRY = "Offers.Listings.ProgramEligibility.IsPrimePantry" - OFFERS_LISTINGS_PROMOTIONS = "Offers.Listings.Promotions" - OFFERS_LISTINGS_SAVINGBASIS = "Offers.Listings.SavingBasis" - OFFERS_SUMMARIES_HIGHESTPRICE = "Offers.Summaries.HighestPrice" - OFFERS_SUMMARIES_LOWESTPRICE = "Offers.Summaries.LowestPrice" - OFFERS_SUMMARIES_OFFERCOUNT = "Offers.Summaries.OfferCount" - PARENTASIN = "ParentASIN" - RENTALOFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY = "RentalOffers.Listings.Availability.MaxOrderQuantity" - RENTALOFFERS_LISTINGS_AVAILABILITY_MESSAGE = "RentalOffers.Listings.Availability.Message" - RENTALOFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY = "RentalOffers.Listings.Availability.MinOrderQuantity" - RENTALOFFERS_LISTINGS_AVAILABILITY_TYPE = "RentalOffers.Listings.Availability.Type" - RENTALOFFERS_LISTINGS_BASEPRICE = "RentalOffers.Listings.BasePrice" - RENTALOFFERS_LISTINGS_CONDITION = "RentalOffers.Listings.Condition" - RENTALOFFERS_LISTINGS_CONDITION_SUBCONDITION = "RentalOffers.Listings.Condition.SubCondition" - RENTALOFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED = "RentalOffers.Listings.DeliveryInfo.IsAmazonFulfilled" - RENTALOFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE = "RentalOffers.Listings.DeliveryInfo.IsFreeShippingEligible" - RENTALOFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE = "RentalOffers.Listings.DeliveryInfo.IsPrimeEligible" - RENTALOFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES = "RentalOffers.Listings.DeliveryInfo.ShippingCharges" - RENTALOFFERS_LISTINGS_MERCHANTINFO = "RentalOffers.Listings.MerchantInfo" - - """ - 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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """GetItemsResource - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(GetItemsResource, 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, GetItemsResource): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/get_items_response.py b/amazon/paapi5_python_sdk/get_items_response.py deleted file mode 100644 index fa22753..0000000 --- a/amazon/paapi5_python_sdk/get_items_response.py +++ /dev/null @@ -1,155 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .error_data import ErrorData # noqa: F401,E501 -from .items_result import ItemsResult # noqa: F401,E501 - - -class GetItemsResponse(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 = { - 'errors': 'list[ErrorData]', - 'items_result': 'ItemsResult' - } - - attribute_map = { - 'errors': 'Errors', - 'items_result': 'ItemsResult' - } - - def __init__(self, errors=None, items_result=None): # noqa: E501 - """GetItemsResponse - a model defined in Swagger""" # noqa: E501 - - self._errors = None - self._items_result = None - self.discriminator = None - - if errors is not None: - self.errors = errors - if items_result is not None: - self.items_result = items_result - - @property - def errors(self): - """Gets the errors of this GetItemsResponse. # noqa: E501 - - - :return: The errors of this GetItemsResponse. # noqa: E501 - :rtype: list[ErrorData] - """ - return self._errors - - @errors.setter - def errors(self, errors): - """Sets the errors of this GetItemsResponse. - - - :param errors: The errors of this GetItemsResponse. # noqa: E501 - :type: list[ErrorData] - """ - - self._errors = errors - - @property - def items_result(self): - """Gets the items_result of this GetItemsResponse. # noqa: E501 - - - :return: The items_result of this GetItemsResponse. # noqa: E501 - :rtype: ItemsResult - """ - return self._items_result - - @items_result.setter - def items_result(self, items_result): - """Sets the items_result of this GetItemsResponse. - - - :param items_result: The items_result of this GetItemsResponse. # noqa: E501 - :type: ItemsResult - """ - - self._items_result = items_result - - 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(GetItemsResponse, 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, GetItemsResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/get_variations_request.py b/amazon/paapi5_python_sdk/get_variations_request.py deleted file mode 100644 index 0b1ea3a..0000000 --- a/amazon/paapi5_python_sdk/get_variations_request.py +++ /dev/null @@ -1,448 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .condition import Condition # noqa: F401,E501 -from .get_variations_resource import GetVariationsResource # noqa: F401,E501 -from .merchant import Merchant # noqa: F401,E501 -from .offer_count import OfferCount # noqa: F401,E501 -from .partner_type import PartnerType # noqa: F401,E501 -from .properties import Properties # noqa: F401,E501 - - -class GetVariationsRequest(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 = { - 'asin': 'str', - 'condition': 'Condition', - 'currency_of_preference': 'str', - 'languages_of_preference': 'list[str]', - 'marketplace': 'str', - 'merchant': 'Merchant', - 'offer_count': 'OfferCount', - 'partner_tag': 'str', - 'partner_type': 'PartnerType', - 'properties': 'Properties', - 'resources': 'list[GetVariationsResource]', - 'variation_count': 'int', - 'variation_page': 'int' - } - - attribute_map = { - 'asin': 'ASIN', - 'condition': 'Condition', - 'currency_of_preference': 'CurrencyOfPreference', - 'languages_of_preference': 'LanguagesOfPreference', - 'marketplace': 'Marketplace', - 'merchant': 'Merchant', - 'offer_count': 'OfferCount', - 'partner_tag': 'PartnerTag', - 'partner_type': 'PartnerType', - 'properties': 'Properties', - 'resources': 'Resources', - 'variation_count': 'VariationCount', - 'variation_page': 'VariationPage' - } - - def __init__(self, asin=None, condition=None, currency_of_preference=None, languages_of_preference=None, marketplace=None, merchant=None, offer_count=None, partner_tag=None, partner_type=None, properties=None, resources=None, variation_count=None, variation_page=None): # noqa: E501 - """GetVariationsRequest - a model defined in Swagger""" # noqa: E501 - - self._asin = None - self._condition = None - self._currency_of_preference = None - self._languages_of_preference = None - self._marketplace = None - self._merchant = None - self._offer_count = None - self._partner_tag = None - self._partner_type = None - self._properties = None - self._resources = None - self._variation_count = None - self._variation_page = None - self.discriminator = None - - self.asin = asin - if condition is not None: - self.condition = condition - if currency_of_preference is not None: - self.currency_of_preference = currency_of_preference - if languages_of_preference is not None: - self.languages_of_preference = languages_of_preference - if marketplace is not None: - self.marketplace = marketplace - if merchant is not None: - self.merchant = merchant - if offer_count is not None: - self.offer_count = offer_count - self.partner_tag = partner_tag - self.partner_type = partner_type - if properties is not None: - self.properties = properties - if resources is not None: - self.resources = resources - if variation_count is not None: - self.variation_count = variation_count - if variation_page is not None: - self.variation_page = variation_page - - @property - def asin(self): - """Gets the asin of this GetVariationsRequest. # noqa: E501 - - - :return: The asin of this GetVariationsRequest. # noqa: E501 - :rtype: str - """ - return self._asin - - @asin.setter - def asin(self, asin): - """Sets the asin of this GetVariationsRequest. - - - :param asin: The asin of this GetVariationsRequest. # noqa: E501 - :type: str - """ - if asin is None: - raise ValueError("Invalid value for `asin`, must not be `None`") # noqa: E501 - - self._asin = asin - - @property - def condition(self): - """Gets the condition of this GetVariationsRequest. # noqa: E501 - - - :return: The condition of this GetVariationsRequest. # noqa: E501 - :rtype: Condition - """ - return self._condition - - @condition.setter - def condition(self, condition): - """Sets the condition of this GetVariationsRequest. - - - :param condition: The condition of this GetVariationsRequest. # noqa: E501 - :type: Condition - """ - - self._condition = condition - - @property - def currency_of_preference(self): - """Gets the currency_of_preference of this GetVariationsRequest. # noqa: E501 - - - :return: The currency_of_preference of this GetVariationsRequest. # noqa: E501 - :rtype: str - """ - return self._currency_of_preference - - @currency_of_preference.setter - def currency_of_preference(self, currency_of_preference): - """Sets the currency_of_preference of this GetVariationsRequest. - - - :param currency_of_preference: The currency_of_preference of this GetVariationsRequest. # noqa: E501 - :type: str - """ - - self._currency_of_preference = currency_of_preference - - @property - def languages_of_preference(self): - """Gets the languages_of_preference of this GetVariationsRequest. # noqa: E501 - - - :return: The languages_of_preference of this GetVariationsRequest. # noqa: E501 - :rtype: list[str] - """ - return self._languages_of_preference - - @languages_of_preference.setter - def languages_of_preference(self, languages_of_preference): - """Sets the languages_of_preference of this GetVariationsRequest. - - - :param languages_of_preference: The languages_of_preference of this GetVariationsRequest. # noqa: E501 - :type: list[str] - """ - - self._languages_of_preference = languages_of_preference - - @property - def marketplace(self): - """Gets the marketplace of this GetVariationsRequest. # noqa: E501 - - - :return: The marketplace of this GetVariationsRequest. # noqa: E501 - :rtype: str - """ - return self._marketplace - - @marketplace.setter - def marketplace(self, marketplace): - """Sets the marketplace of this GetVariationsRequest. - - - :param marketplace: The marketplace of this GetVariationsRequest. # noqa: E501 - :type: str - """ - - self._marketplace = marketplace - - @property - def merchant(self): - """Gets the merchant of this GetVariationsRequest. # noqa: E501 - - - :return: The merchant of this GetVariationsRequest. # noqa: E501 - :rtype: Merchant - """ - return self._merchant - - @merchant.setter - def merchant(self, merchant): - """Sets the merchant of this GetVariationsRequest. - - - :param merchant: The merchant of this GetVariationsRequest. # noqa: E501 - :type: Merchant - """ - - self._merchant = merchant - - @property - def offer_count(self): - """Gets the offer_count of this GetVariationsRequest. # noqa: E501 - - - :return: The offer_count of this GetVariationsRequest. # noqa: E501 - :rtype: OfferCount - """ - return self._offer_count - - @offer_count.setter - def offer_count(self, offer_count): - """Sets the offer_count of this GetVariationsRequest. - - - :param offer_count: The offer_count of this GetVariationsRequest. # noqa: E501 - :type: OfferCount - """ - - self._offer_count = offer_count - - @property - def partner_tag(self): - """Gets the partner_tag of this GetVariationsRequest. # noqa: E501 - - - :return: The partner_tag of this GetVariationsRequest. # noqa: E501 - :rtype: str - """ - return self._partner_tag - - @partner_tag.setter - def partner_tag(self, partner_tag): - """Sets the partner_tag of this GetVariationsRequest. - - - :param partner_tag: The partner_tag of this GetVariationsRequest. # noqa: E501 - :type: str - """ - if partner_tag is None: - raise ValueError("Invalid value for `partner_tag`, must not be `None`") # noqa: E501 - - self._partner_tag = partner_tag - - @property - def partner_type(self): - """Gets the partner_type of this GetVariationsRequest. # noqa: E501 - - - :return: The partner_type of this GetVariationsRequest. # noqa: E501 - :rtype: PartnerType - """ - return self._partner_type - - @partner_type.setter - def partner_type(self, partner_type): - """Sets the partner_type of this GetVariationsRequest. - - - :param partner_type: The partner_type of this GetVariationsRequest. # noqa: E501 - :type: PartnerType - """ - if partner_type is None: - raise ValueError("Invalid value for `partner_type`, must not be `None`") # noqa: E501 - - self._partner_type = partner_type - - @property - def properties(self): - """Gets the properties of this GetVariationsRequest. # noqa: E501 - - - :return: The properties of this GetVariationsRequest. # noqa: E501 - :rtype: Properties - """ - return self._properties - - @properties.setter - def properties(self, properties): - """Sets the properties of this GetVariationsRequest. - - - :param properties: The properties of this GetVariationsRequest. # noqa: E501 - :type: Properties - """ - - self._properties = properties - - @property - def resources(self): - """Gets the resources of this GetVariationsRequest. # noqa: E501 - - - :return: The resources of this GetVariationsRequest. # noqa: E501 - :rtype: list[GetVariationsResource] - """ - return self._resources - - @resources.setter - def resources(self, resources): - """Sets the resources of this GetVariationsRequest. - - - :param resources: The resources of this GetVariationsRequest. # noqa: E501 - :type: list[GetVariationsResource] - """ - - self._resources = resources - - @property - def variation_count(self): - """Gets the variation_count of this GetVariationsRequest. # noqa: E501 - - - :return: The variation_count of this GetVariationsRequest. # noqa: E501 - :rtype: int - """ - return self._variation_count - - @variation_count.setter - def variation_count(self, variation_count): - """Sets the variation_count of this GetVariationsRequest. - - - :param variation_count: The variation_count of this GetVariationsRequest. # noqa: E501 - :type: int - """ - - self._variation_count = variation_count - - @property - def variation_page(self): - """Gets the variation_page of this GetVariationsRequest. # noqa: E501 - - - :return: The variation_page of this GetVariationsRequest. # noqa: E501 - :rtype: int - """ - return self._variation_page - - @variation_page.setter - def variation_page(self, variation_page): - """Sets the variation_page of this GetVariationsRequest. - - - :param variation_page: The variation_page of this GetVariationsRequest. # noqa: E501 - :type: int - """ - - self._variation_page = variation_page - - 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(GetVariationsRequest, 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, GetVariationsRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/get_variations_resource.py b/amazon/paapi5_python_sdk/get_variations_resource.py deleted file mode 100644 index bf5018e..0000000 --- a/amazon/paapi5_python_sdk/get_variations_resource.py +++ /dev/null @@ -1,160 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class GetVariationsResource(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - - """ - allowed enum values - """ - BROWSENODEINFO_BROWSENODES = "BrowseNodeInfo.BrowseNodes" - BROWSENODEINFO_BROWSENODES_ANCESTOR = "BrowseNodeInfo.BrowseNodes.Ancestor" - BROWSENODEINFO_BROWSENODES_SALESRANK = "BrowseNodeInfo.BrowseNodes.SalesRank" - BROWSENODEINFO_WEBSITESALESRANK = "BrowseNodeInfo.WebsiteSalesRank" - IMAGES_PRIMARY_SMALL = "Images.Primary.Small" - IMAGES_PRIMARY_MEDIUM = "Images.Primary.Medium" - IMAGES_PRIMARY_LARGE = "Images.Primary.Large" - IMAGES_VARIANTS_SMALL = "Images.Variants.Small" - IMAGES_VARIANTS_MEDIUM = "Images.Variants.Medium" - IMAGES_VARIANTS_LARGE = "Images.Variants.Large" - ITEMINFO_BYLINEINFO = "ItemInfo.ByLineInfo" - ITEMINFO_CONTENTINFO = "ItemInfo.ContentInfo" - ITEMINFO_CONTENTRATING = "ItemInfo.ContentRating" - ITEMINFO_CLASSIFICATIONS = "ItemInfo.Classifications" - ITEMINFO_EXTERNALIDS = "ItemInfo.ExternalIds" - ITEMINFO_FEATURES = "ItemInfo.Features" - ITEMINFO_MANUFACTUREINFO = "ItemInfo.ManufactureInfo" - ITEMINFO_PRODUCTINFO = "ItemInfo.ProductInfo" - ITEMINFO_TECHNICALINFO = "ItemInfo.TechnicalInfo" - ITEMINFO_TITLE = "ItemInfo.Title" - ITEMINFO_TRADEININFO = "ItemInfo.TradeInInfo" - OFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY = "Offers.Listings.Availability.MaxOrderQuantity" - OFFERS_LISTINGS_AVAILABILITY_MESSAGE = "Offers.Listings.Availability.Message" - OFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY = "Offers.Listings.Availability.MinOrderQuantity" - OFFERS_LISTINGS_AVAILABILITY_TYPE = "Offers.Listings.Availability.Type" - OFFERS_LISTINGS_CONDITION = "Offers.Listings.Condition" - OFFERS_LISTINGS_CONDITION_SUBCONDITION = "Offers.Listings.Condition.SubCondition" - OFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED = "Offers.Listings.DeliveryInfo.IsAmazonFulfilled" - OFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE = "Offers.Listings.DeliveryInfo.IsFreeShippingEligible" - OFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE = "Offers.Listings.DeliveryInfo.IsPrimeEligible" - OFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES = "Offers.Listings.DeliveryInfo.ShippingCharges" - OFFERS_LISTINGS_ISBUYBOXWINNER = "Offers.Listings.IsBuyBoxWinner" - OFFERS_LISTINGS_LOYALTYPOINTS_POINTS = "Offers.Listings.LoyaltyPoints.Points" - OFFERS_LISTINGS_MERCHANTINFO = "Offers.Listings.MerchantInfo" - OFFERS_LISTINGS_PRICE = "Offers.Listings.Price" - OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEEXCLUSIVE = "Offers.Listings.ProgramEligibility.IsPrimeExclusive" - OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEPANTRY = "Offers.Listings.ProgramEligibility.IsPrimePantry" - OFFERS_LISTINGS_PROMOTIONS = "Offers.Listings.Promotions" - OFFERS_LISTINGS_SAVINGBASIS = "Offers.Listings.SavingBasis" - OFFERS_SUMMARIES_HIGHESTPRICE = "Offers.Summaries.HighestPrice" - OFFERS_SUMMARIES_LOWESTPRICE = "Offers.Summaries.LowestPrice" - OFFERS_SUMMARIES_OFFERCOUNT = "Offers.Summaries.OfferCount" - PARENTASIN = "ParentASIN" - RENTALOFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY = "RentalOffers.Listings.Availability.MaxOrderQuantity" - RENTALOFFERS_LISTINGS_AVAILABILITY_MESSAGE = "RentalOffers.Listings.Availability.Message" - RENTALOFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY = "RentalOffers.Listings.Availability.MinOrderQuantity" - RENTALOFFERS_LISTINGS_AVAILABILITY_TYPE = "RentalOffers.Listings.Availability.Type" - RENTALOFFERS_LISTINGS_BASEPRICE = "RentalOffers.Listings.BasePrice" - RENTALOFFERS_LISTINGS_CONDITION = "RentalOffers.Listings.Condition" - RENTALOFFERS_LISTINGS_CONDITION_SUBCONDITION = "RentalOffers.Listings.Condition.SubCondition" - RENTALOFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED = "RentalOffers.Listings.DeliveryInfo.IsAmazonFulfilled" - RENTALOFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE = "RentalOffers.Listings.DeliveryInfo.IsFreeShippingEligible" - RENTALOFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE = "RentalOffers.Listings.DeliveryInfo.IsPrimeEligible" - RENTALOFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES = "RentalOffers.Listings.DeliveryInfo.ShippingCharges" - RENTALOFFERS_LISTINGS_MERCHANTINFO = "RentalOffers.Listings.MerchantInfo" - VARIATIONSUMMARY_PRICE_HIGHESTPRICE = "VariationSummary.Price.HighestPrice" - VARIATIONSUMMARY_PRICE_LOWESTPRICE = "VariationSummary.Price.LowestPrice" - VARIATIONSUMMARY_VARIATIONDIMENSION = "VariationSummary.VariationDimension" - - """ - 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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """GetVariationsResource - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(GetVariationsResource, 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, GetVariationsResource): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/get_variations_response.py b/amazon/paapi5_python_sdk/get_variations_response.py deleted file mode 100644 index 287ee5e..0000000 --- a/amazon/paapi5_python_sdk/get_variations_response.py +++ /dev/null @@ -1,155 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .error_data import ErrorData # noqa: F401,E501 -from .variations_result import VariationsResult # noqa: F401,E501 - - -class GetVariationsResponse(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 = { - 'errors': 'list[ErrorData]', - 'variations_result': 'VariationsResult' - } - - attribute_map = { - 'errors': 'Errors', - 'variations_result': 'VariationsResult' - } - - def __init__(self, errors=None, variations_result=None): # noqa: E501 - """GetVariationsResponse - a model defined in Swagger""" # noqa: E501 - - self._errors = None - self._variations_result = None - self.discriminator = None - - if errors is not None: - self.errors = errors - if variations_result is not None: - self.variations_result = variations_result - - @property - def errors(self): - """Gets the errors of this GetVariationsResponse. # noqa: E501 - - - :return: The errors of this GetVariationsResponse. # noqa: E501 - :rtype: list[ErrorData] - """ - return self._errors - - @errors.setter - def errors(self, errors): - """Sets the errors of this GetVariationsResponse. - - - :param errors: The errors of this GetVariationsResponse. # noqa: E501 - :type: list[ErrorData] - """ - - self._errors = errors - - @property - def variations_result(self): - """Gets the variations_result of this GetVariationsResponse. # noqa: E501 - - - :return: The variations_result of this GetVariationsResponse. # noqa: E501 - :rtype: VariationsResult - """ - return self._variations_result - - @variations_result.setter - def variations_result(self, variations_result): - """Sets the variations_result of this GetVariationsResponse. - - - :param variations_result: The variations_result of this GetVariationsResponse. # noqa: E501 - :type: VariationsResult - """ - - self._variations_result = variations_result - - 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(GetVariationsResponse, 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, GetVariationsResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/image_size.py b/amazon/paapi5_python_sdk/image_size.py deleted file mode 100644 index cb56660..0000000 --- a/amazon/paapi5_python_sdk/image_size.py +++ /dev/null @@ -1,178 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class ImageSize(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 = { - 'url': 'str', - 'height': 'int', - 'width': 'int' - } - - attribute_map = { - 'url': 'URL', - 'height': 'Height', - 'width': 'Width' - } - - def __init__(self, url=None, height=None, width=None): # noqa: E501 - """ImageSize - a model defined in Swagger""" # noqa: E501 - - self._url = None - self._height = None - self._width = None - self.discriminator = None - - if url is not None: - self.url = url - if height is not None: - self.height = height - if width is not None: - self.width = width - - @property - def url(self): - """Gets the url of this ImageSize. # noqa: E501 - - - :return: The url of this ImageSize. # noqa: E501 - :rtype: str - """ - return self._url - - @url.setter - def url(self, url): - """Sets the url of this ImageSize. - - - :param url: The url of this ImageSize. # noqa: E501 - :type: str - """ - - self._url = url - - @property - def height(self): - """Gets the height of this ImageSize. # noqa: E501 - - - :return: The height of this ImageSize. # noqa: E501 - :rtype: int - """ - return self._height - - @height.setter - def height(self, height): - """Sets the height of this ImageSize. - - - :param height: The height of this ImageSize. # noqa: E501 - :type: int - """ - - self._height = height - - @property - def width(self): - """Gets the width of this ImageSize. # noqa: E501 - - - :return: The width of this ImageSize. # noqa: E501 - :rtype: int - """ - return self._width - - @width.setter - def width(self, width): - """Sets the width of this ImageSize. - - - :param width: The width of this ImageSize. # noqa: E501 - :type: int - """ - - self._width = width - - 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(ImageSize, 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, ImageSize): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/image_type.py b/amazon/paapi5_python_sdk/image_type.py deleted file mode 100644 index 1abf7eb..0000000 --- a/amazon/paapi5_python_sdk/image_type.py +++ /dev/null @@ -1,180 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .image_size import ImageSize # noqa: F401,E501 - - -class ImageType(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 = { - 'small': 'ImageSize', - 'medium': 'ImageSize', - 'large': 'ImageSize' - } - - attribute_map = { - 'small': 'Small', - 'medium': 'Medium', - 'large': 'Large' - } - - def __init__(self, small=None, medium=None, large=None): # noqa: E501 - """ImageType - a model defined in Swagger""" # noqa: E501 - - self._small = None - self._medium = None - self._large = None - self.discriminator = None - - if small is not None: - self.small = small - if medium is not None: - self.medium = medium - if large is not None: - self.large = large - - @property - def small(self): - """Gets the small of this ImageType. # noqa: E501 - - - :return: The small of this ImageType. # noqa: E501 - :rtype: ImageSize - """ - return self._small - - @small.setter - def small(self, small): - """Sets the small of this ImageType. - - - :param small: The small of this ImageType. # noqa: E501 - :type: ImageSize - """ - - self._small = small - - @property - def medium(self): - """Gets the medium of this ImageType. # noqa: E501 - - - :return: The medium of this ImageType. # noqa: E501 - :rtype: ImageSize - """ - return self._medium - - @medium.setter - def medium(self, medium): - """Sets the medium of this ImageType. - - - :param medium: The medium of this ImageType. # noqa: E501 - :type: ImageSize - """ - - self._medium = medium - - @property - def large(self): - """Gets the large of this ImageType. # noqa: E501 - - - :return: The large of this ImageType. # noqa: E501 - :rtype: ImageSize - """ - return self._large - - @large.setter - def large(self, large): - """Sets the large of this ImageType. - - - :param large: The large of this ImageType. # noqa: E501 - :type: ImageSize - """ - - self._large = large - - 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(ImageType, 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, ImageType): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/images.py b/amazon/paapi5_python_sdk/images.py deleted file mode 100644 index cf46148..0000000 --- a/amazon/paapi5_python_sdk/images.py +++ /dev/null @@ -1,154 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .image_type import ImageType # noqa: F401,E501 - - -class Images(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 = { - 'primary': 'ImageType', - 'variants': 'list[ImageType]' - } - - attribute_map = { - 'primary': 'Primary', - 'variants': 'Variants' - } - - def __init__(self, primary=None, variants=None): # noqa: E501 - """Images - a model defined in Swagger""" # noqa: E501 - - self._primary = None - self._variants = None - self.discriminator = None - - if primary is not None: - self.primary = primary - if variants is not None: - self.variants = variants - - @property - def primary(self): - """Gets the primary of this Images. # noqa: E501 - - - :return: The primary of this Images. # noqa: E501 - :rtype: ImageType - """ - return self._primary - - @primary.setter - def primary(self, primary): - """Sets the primary of this Images. - - - :param primary: The primary of this Images. # noqa: E501 - :type: ImageType - """ - - self._primary = primary - - @property - def variants(self): - """Gets the variants of this Images. # noqa: E501 - - - :return: The variants of this Images. # noqa: E501 - :rtype: list[ImageType] - """ - return self._variants - - @variants.setter - def variants(self, variants): - """Sets the variants of this Images. - - - :param variants: The variants of this Images. # noqa: E501 - :type: list[ImageType] - """ - - self._variants = variants - - 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(Images, 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, Images): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/item.py b/amazon/paapi5_python_sdk/item.py deleted file mode 100644 index 6583aed..0000000 --- a/amazon/paapi5_python_sdk/item.py +++ /dev/null @@ -1,367 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .browse_node_info import BrowseNodeInfo # noqa: F401,E501 -from .images import Images # noqa: F401,E501 -from .item_info import ItemInfo # noqa: F401,E501 -from .offers import Offers # noqa: F401,E501 -from .rental_offers import RentalOffers # noqa: F401,E501 -from .variation_attribute import VariationAttribute # noqa: F401,E501 - - -class Item(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 = { - 'asin': 'str', - 'browse_node_info': 'BrowseNodeInfo', - 'detail_page_url': 'str', - 'images': 'Images', - 'item_info': 'ItemInfo', - 'offers': 'Offers', - 'parent_asin': 'str', - 'rental_offers': 'RentalOffers', - 'score': 'float', - 'variation_attributes': 'list[VariationAttribute]' - } - - attribute_map = { - 'asin': 'ASIN', - 'browse_node_info': 'BrowseNodeInfo', - 'detail_page_url': 'DetailPageURL', - 'images': 'Images', - 'item_info': 'ItemInfo', - 'offers': 'Offers', - 'parent_asin': 'ParentASIN', - 'rental_offers': 'RentalOffers', - 'score': 'Score', - 'variation_attributes': 'VariationAttributes' - } - - def __init__(self, asin=None, browse_node_info=None, detail_page_url=None, images=None, item_info=None, offers=None, parent_asin=None, rental_offers=None, score=None, variation_attributes=None): # noqa: E501 - """Item - a model defined in Swagger""" # noqa: E501 - - self._asin = None - self._browse_node_info = None - self._detail_page_url = None - self._images = None - self._item_info = None - self._offers = None - self._parent_asin = None - self._rental_offers = None - self._score = None - self._variation_attributes = None - self.discriminator = None - - if asin is not None: - self.asin = asin - if browse_node_info is not None: - self.browse_node_info = browse_node_info - if detail_page_url is not None: - self.detail_page_url = detail_page_url - if images is not None: - self.images = images - if item_info is not None: - self.item_info = item_info - if offers is not None: - self.offers = offers - if parent_asin is not None: - self.parent_asin = parent_asin - if rental_offers is not None: - self.rental_offers = rental_offers - if score is not None: - self.score = score - if variation_attributes is not None: - self.variation_attributes = variation_attributes - - @property - def asin(self): - """Gets the asin of this Item. # noqa: E501 - - - :return: The asin of this Item. # noqa: E501 - :rtype: str - """ - return self._asin - - @asin.setter - def asin(self, asin): - """Sets the asin of this Item. - - - :param asin: The asin of this Item. # noqa: E501 - :type: str - """ - - self._asin = asin - - @property - def browse_node_info(self): - """Gets the browse_node_info of this Item. # noqa: E501 - - - :return: The browse_node_info of this Item. # noqa: E501 - :rtype: BrowseNodeInfo - """ - return self._browse_node_info - - @browse_node_info.setter - def browse_node_info(self, browse_node_info): - """Sets the browse_node_info of this Item. - - - :param browse_node_info: The browse_node_info of this Item. # noqa: E501 - :type: BrowseNodeInfo - """ - - self._browse_node_info = browse_node_info - - @property - def detail_page_url(self): - """Gets the detail_page_url of this Item. # noqa: E501 - - - :return: The detail_page_url of this Item. # noqa: E501 - :rtype: str - """ - return self._detail_page_url - - @detail_page_url.setter - def detail_page_url(self, detail_page_url): - """Sets the detail_page_url of this Item. - - - :param detail_page_url: The detail_page_url of this Item. # noqa: E501 - :type: str - """ - - self._detail_page_url = detail_page_url - - @property - def images(self): - """Gets the images of this Item. # noqa: E501 - - - :return: The images of this Item. # noqa: E501 - :rtype: Images - """ - return self._images - - @images.setter - def images(self, images): - """Sets the images of this Item. - - - :param images: The images of this Item. # noqa: E501 - :type: Images - """ - - self._images = images - - @property - def item_info(self): - """Gets the item_info of this Item. # noqa: E501 - - - :return: The item_info of this Item. # noqa: E501 - :rtype: ItemInfo - """ - return self._item_info - - @item_info.setter - def item_info(self, item_info): - """Sets the item_info of this Item. - - - :param item_info: The item_info of this Item. # noqa: E501 - :type: ItemInfo - """ - - self._item_info = item_info - - @property - def offers(self): - """Gets the offers of this Item. # noqa: E501 - - - :return: The offers of this Item. # noqa: E501 - :rtype: Offers - """ - return self._offers - - @offers.setter - def offers(self, offers): - """Sets the offers of this Item. - - - :param offers: The offers of this Item. # noqa: E501 - :type: Offers - """ - - self._offers = offers - - @property - def parent_asin(self): - """Gets the parent_asin of this Item. # noqa: E501 - - - :return: The parent_asin of this Item. # noqa: E501 - :rtype: str - """ - return self._parent_asin - - @parent_asin.setter - def parent_asin(self, parent_asin): - """Sets the parent_asin of this Item. - - - :param parent_asin: The parent_asin of this Item. # noqa: E501 - :type: str - """ - - self._parent_asin = parent_asin - - @property - def rental_offers(self): - """Gets the rental_offers of this Item. # noqa: E501 - - - :return: The rental_offers of this Item. # noqa: E501 - :rtype: RentalOffers - """ - return self._rental_offers - - @rental_offers.setter - def rental_offers(self, rental_offers): - """Sets the rental_offers of this Item. - - - :param rental_offers: The rental_offers of this Item. # noqa: E501 - :type: RentalOffers - """ - - self._rental_offers = rental_offers - - @property - def score(self): - """Gets the score of this Item. # noqa: E501 - - - :return: The score of this Item. # noqa: E501 - :rtype: float - """ - return self._score - - @score.setter - def score(self, score): - """Sets the score of this Item. - - - :param score: The score of this Item. # noqa: E501 - :type: float - """ - - self._score = score - - @property - def variation_attributes(self): - """Gets the variation_attributes of this Item. # noqa: E501 - - - :return: The variation_attributes of this Item. # noqa: E501 - :rtype: list[VariationAttribute] - """ - return self._variation_attributes - - @variation_attributes.setter - def variation_attributes(self, variation_attributes): - """Sets the variation_attributes of this Item. - - - :param variation_attributes: The variation_attributes of this Item. # noqa: E501 - :type: list[VariationAttribute] - """ - - self._variation_attributes = variation_attributes - - 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(Item, 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, Item): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/item_id_type.py b/amazon/paapi5_python_sdk/item_id_type.py deleted file mode 100644 index 0d3b36a..0000000 --- a/amazon/paapi5_python_sdk/item_id_type.py +++ /dev/null @@ -1,103 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class ItemIdType(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - - """ - allowed enum values - """ - ASIN = "ASIN" - - """ - 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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """ItemIdType - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(ItemIdType, 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, ItemIdType): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/item_info.py b/amazon/paapi5_python_sdk/item_info.py deleted file mode 100644 index c03de48..0000000 --- a/amazon/paapi5_python_sdk/item_info.py +++ /dev/null @@ -1,398 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .by_line_info import ByLineInfo # noqa: F401,E501 -from .classifications import Classifications # noqa: F401,E501 -from .content_info import ContentInfo # noqa: F401,E501 -from .content_rating import ContentRating # noqa: F401,E501 -from .external_ids import ExternalIds # noqa: F401,E501 -from .manufacture_info import ManufactureInfo # noqa: F401,E501 -from .multi_valued_attribute import MultiValuedAttribute # noqa: F401,E501 -from .product_info import ProductInfo # noqa: F401,E501 -from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 -from .technical_info import TechnicalInfo # noqa: F401,E501 -from .trade_in_info import TradeInInfo # noqa: F401,E501 - - -class ItemInfo(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 = { - 'by_line_info': 'ByLineInfo', - 'classifications': 'Classifications', - 'content_info': 'ContentInfo', - 'content_rating': 'ContentRating', - 'external_ids': 'ExternalIds', - 'features': 'MultiValuedAttribute', - 'manufacture_info': 'ManufactureInfo', - 'product_info': 'ProductInfo', - 'technical_info': 'TechnicalInfo', - 'title': 'SingleStringValuedAttribute', - 'trade_in_info': 'TradeInInfo' - } - - attribute_map = { - 'by_line_info': 'ByLineInfo', - 'classifications': 'Classifications', - 'content_info': 'ContentInfo', - 'content_rating': 'ContentRating', - 'external_ids': 'ExternalIds', - 'features': 'Features', - 'manufacture_info': 'ManufactureInfo', - 'product_info': 'ProductInfo', - 'technical_info': 'TechnicalInfo', - 'title': 'Title', - 'trade_in_info': 'TradeInInfo' - } - - def __init__(self, by_line_info=None, classifications=None, content_info=None, content_rating=None, external_ids=None, features=None, manufacture_info=None, product_info=None, technical_info=None, title=None, trade_in_info=None): # noqa: E501 - """ItemInfo - a model defined in Swagger""" # noqa: E501 - - self._by_line_info = None - self._classifications = None - self._content_info = None - self._content_rating = None - self._external_ids = None - self._features = None - self._manufacture_info = None - self._product_info = None - self._technical_info = None - self._title = None - self._trade_in_info = None - self.discriminator = None - - if by_line_info is not None: - self.by_line_info = by_line_info - if classifications is not None: - self.classifications = classifications - if content_info is not None: - self.content_info = content_info - if content_rating is not None: - self.content_rating = content_rating - if external_ids is not None: - self.external_ids = external_ids - if features is not None: - self.features = features - if manufacture_info is not None: - self.manufacture_info = manufacture_info - if product_info is not None: - self.product_info = product_info - if technical_info is not None: - self.technical_info = technical_info - if title is not None: - self.title = title - if trade_in_info is not None: - self.trade_in_info = trade_in_info - - @property - def by_line_info(self): - """Gets the by_line_info of this ItemInfo. # noqa: E501 - - - :return: The by_line_info of this ItemInfo. # noqa: E501 - :rtype: ByLineInfo - """ - return self._by_line_info - - @by_line_info.setter - def by_line_info(self, by_line_info): - """Sets the by_line_info of this ItemInfo. - - - :param by_line_info: The by_line_info of this ItemInfo. # noqa: E501 - :type: ByLineInfo - """ - - self._by_line_info = by_line_info - - @property - def classifications(self): - """Gets the classifications of this ItemInfo. # noqa: E501 - - - :return: The classifications of this ItemInfo. # noqa: E501 - :rtype: Classifications - """ - return self._classifications - - @classifications.setter - def classifications(self, classifications): - """Sets the classifications of this ItemInfo. - - - :param classifications: The classifications of this ItemInfo. # noqa: E501 - :type: Classifications - """ - - self._classifications = classifications - - @property - def content_info(self): - """Gets the content_info of this ItemInfo. # noqa: E501 - - - :return: The content_info of this ItemInfo. # noqa: E501 - :rtype: ContentInfo - """ - return self._content_info - - @content_info.setter - def content_info(self, content_info): - """Sets the content_info of this ItemInfo. - - - :param content_info: The content_info of this ItemInfo. # noqa: E501 - :type: ContentInfo - """ - - self._content_info = content_info - - @property - def content_rating(self): - """Gets the content_rating of this ItemInfo. # noqa: E501 - - - :return: The content_rating of this ItemInfo. # noqa: E501 - :rtype: ContentRating - """ - return self._content_rating - - @content_rating.setter - def content_rating(self, content_rating): - """Sets the content_rating of this ItemInfo. - - - :param content_rating: The content_rating of this ItemInfo. # noqa: E501 - :type: ContentRating - """ - - self._content_rating = content_rating - - @property - def external_ids(self): - """Gets the external_ids of this ItemInfo. # noqa: E501 - - - :return: The external_ids of this ItemInfo. # noqa: E501 - :rtype: ExternalIds - """ - return self._external_ids - - @external_ids.setter - def external_ids(self, external_ids): - """Sets the external_ids of this ItemInfo. - - - :param external_ids: The external_ids of this ItemInfo. # noqa: E501 - :type: ExternalIds - """ - - self._external_ids = external_ids - - @property - def features(self): - """Gets the features of this ItemInfo. # noqa: E501 - - - :return: The features of this ItemInfo. # noqa: E501 - :rtype: MultiValuedAttribute - """ - return self._features - - @features.setter - def features(self, features): - """Sets the features of this ItemInfo. - - - :param features: The features of this ItemInfo. # noqa: E501 - :type: MultiValuedAttribute - """ - - self._features = features - - @property - def manufacture_info(self): - """Gets the manufacture_info of this ItemInfo. # noqa: E501 - - - :return: The manufacture_info of this ItemInfo. # noqa: E501 - :rtype: ManufactureInfo - """ - return self._manufacture_info - - @manufacture_info.setter - def manufacture_info(self, manufacture_info): - """Sets the manufacture_info of this ItemInfo. - - - :param manufacture_info: The manufacture_info of this ItemInfo. # noqa: E501 - :type: ManufactureInfo - """ - - self._manufacture_info = manufacture_info - - @property - def product_info(self): - """Gets the product_info of this ItemInfo. # noqa: E501 - - - :return: The product_info of this ItemInfo. # noqa: E501 - :rtype: ProductInfo - """ - return self._product_info - - @product_info.setter - def product_info(self, product_info): - """Sets the product_info of this ItemInfo. - - - :param product_info: The product_info of this ItemInfo. # noqa: E501 - :type: ProductInfo - """ - - self._product_info = product_info - - @property - def technical_info(self): - """Gets the technical_info of this ItemInfo. # noqa: E501 - - - :return: The technical_info of this ItemInfo. # noqa: E501 - :rtype: TechnicalInfo - """ - return self._technical_info - - @technical_info.setter - def technical_info(self, technical_info): - """Sets the technical_info of this ItemInfo. - - - :param technical_info: The technical_info of this ItemInfo. # noqa: E501 - :type: TechnicalInfo - """ - - self._technical_info = technical_info - - @property - def title(self): - """Gets the title of this ItemInfo. # noqa: E501 - - - :return: The title of this ItemInfo. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this ItemInfo. - - - :param title: The title of this ItemInfo. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._title = title - - @property - def trade_in_info(self): - """Gets the trade_in_info of this ItemInfo. # noqa: E501 - - - :return: The trade_in_info of this ItemInfo. # noqa: E501 - :rtype: TradeInInfo - """ - return self._trade_in_info - - @trade_in_info.setter - def trade_in_info(self, trade_in_info): - """Sets the trade_in_info of this ItemInfo. - - - :param trade_in_info: The trade_in_info of this ItemInfo. # noqa: E501 - :type: TradeInInfo - """ - - self._trade_in_info = trade_in_info - - 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(ItemInfo, 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, ItemInfo): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/items_result.py b/amazon/paapi5_python_sdk/items_result.py deleted file mode 100644 index 4c4192a..0000000 --- a/amazon/paapi5_python_sdk/items_result.py +++ /dev/null @@ -1,128 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .item import Item # noqa: F401,E501 - - -class ItemsResult(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 = { - 'items': 'list[Item]' - } - - attribute_map = { - 'items': 'Items' - } - - def __init__(self, items=None): # noqa: E501 - """ItemsResult - a model defined in Swagger""" # noqa: E501 - - self._items = None - self.discriminator = None - - if items is not None: - self.items = items - - @property - def items(self): - """Gets the items of this ItemsResult. # noqa: E501 - - - :return: The items of this ItemsResult. # noqa: E501 - :rtype: list[Item] - """ - return self._items - - @items.setter - def items(self, items): - """Sets the items of this ItemsResult. - - - :param items: The items of this ItemsResult. # noqa: E501 - :type: list[Item] - """ - - self._items = items - - 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(ItemsResult, 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, ItemsResult): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/language_type.py b/amazon/paapi5_python_sdk/language_type.py deleted file mode 100644 index c5a038c..0000000 --- a/amazon/paapi5_python_sdk/language_type.py +++ /dev/null @@ -1,152 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class LanguageType(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 = { - 'display_value': 'str', - 'type': 'str' - } - - attribute_map = { - 'display_value': 'DisplayValue', - 'type': 'Type' - } - - def __init__(self, display_value=None, type=None): # noqa: E501 - """LanguageType - a model defined in Swagger""" # noqa: E501 - - self._display_value = None - self._type = None - self.discriminator = None - - if display_value is not None: - self.display_value = display_value - if type is not None: - self.type = type - - @property - def display_value(self): - """Gets the display_value of this LanguageType. # noqa: E501 - - - :return: The display_value of this LanguageType. # noqa: E501 - :rtype: str - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this LanguageType. - - - :param display_value: The display_value of this LanguageType. # noqa: E501 - :type: str - """ - - self._display_value = display_value - - @property - def type(self): - """Gets the type of this LanguageType. # noqa: E501 - - - :return: The type of this LanguageType. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this LanguageType. - - - :param type: The type of this LanguageType. # noqa: E501 - :type: str - """ - - self._type = 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(LanguageType, 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, LanguageType): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/languages.py b/amazon/paapi5_python_sdk/languages.py deleted file mode 100644 index f1f8db0..0000000 --- a/amazon/paapi5_python_sdk/languages.py +++ /dev/null @@ -1,180 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .language_type import LanguageType # noqa: F401,E501 - - -class Languages(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 = { - 'display_values': 'list[LanguageType]', - 'label': 'str', - 'locale': 'str' - } - - attribute_map = { - 'display_values': 'DisplayValues', - 'label': 'Label', - 'locale': 'Locale' - } - - def __init__(self, display_values=None, label=None, locale=None): # noqa: E501 - """Languages - a model defined in Swagger""" # noqa: E501 - - self._display_values = None - self._label = None - self._locale = None - self.discriminator = None - - if display_values is not None: - self.display_values = display_values - if label is not None: - self.label = label - if locale is not None: - self.locale = locale - - @property - def display_values(self): - """Gets the display_values of this Languages. # noqa: E501 - - - :return: The display_values of this Languages. # noqa: E501 - :rtype: list[LanguageType] - """ - return self._display_values - - @display_values.setter - def display_values(self, display_values): - """Sets the display_values of this Languages. - - - :param display_values: The display_values of this Languages. # noqa: E501 - :type: list[LanguageType] - """ - - self._display_values = display_values - - @property - def label(self): - """Gets the label of this Languages. # noqa: E501 - - - :return: The label of this Languages. # noqa: E501 - :rtype: str - """ - return self._label - - @label.setter - def label(self, label): - """Sets the label of this Languages. - - - :param label: The label of this Languages. # noqa: E501 - :type: str - """ - - self._label = label - - @property - def locale(self): - """Gets the locale of this Languages. # noqa: E501 - - - :return: The locale of this Languages. # noqa: E501 - :rtype: str - """ - return self._locale - - @locale.setter - def locale(self, locale): - """Sets the locale of this Languages. - - - :param locale: The locale of this Languages. # noqa: E501 - :type: str - """ - - self._locale = locale - - 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(Languages, 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, Languages): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/manufacture_info.py b/amazon/paapi5_python_sdk/manufacture_info.py deleted file mode 100644 index ccc9fe7..0000000 --- a/amazon/paapi5_python_sdk/manufacture_info.py +++ /dev/null @@ -1,180 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 - - -class ManufactureInfo(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 = { - 'item_part_number': 'SingleStringValuedAttribute', - 'model': 'SingleStringValuedAttribute', - 'warranty': 'SingleStringValuedAttribute' - } - - attribute_map = { - 'item_part_number': 'ItemPartNumber', - 'model': 'Model', - 'warranty': 'Warranty' - } - - def __init__(self, item_part_number=None, model=None, warranty=None): # noqa: E501 - """ManufactureInfo - a model defined in Swagger""" # noqa: E501 - - self._item_part_number = None - self._model = None - self._warranty = None - self.discriminator = None - - if item_part_number is not None: - self.item_part_number = item_part_number - if model is not None: - self.model = model - if warranty is not None: - self.warranty = warranty - - @property - def item_part_number(self): - """Gets the item_part_number of this ManufactureInfo. # noqa: E501 - - - :return: The item_part_number of this ManufactureInfo. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._item_part_number - - @item_part_number.setter - def item_part_number(self, item_part_number): - """Sets the item_part_number of this ManufactureInfo. - - - :param item_part_number: The item_part_number of this ManufactureInfo. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._item_part_number = item_part_number - - @property - def model(self): - """Gets the model of this ManufactureInfo. # noqa: E501 - - - :return: The model of this ManufactureInfo. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._model - - @model.setter - def model(self, model): - """Sets the model of this ManufactureInfo. - - - :param model: The model of this ManufactureInfo. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._model = model - - @property - def warranty(self): - """Gets the warranty of this ManufactureInfo. # noqa: E501 - - - :return: The warranty of this ManufactureInfo. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._warranty - - @warranty.setter - def warranty(self, warranty): - """Sets the warranty of this ManufactureInfo. - - - :param warranty: The warranty of this ManufactureInfo. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._warranty = warranty - - 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(ManufactureInfo, 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, ManufactureInfo): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/max_price.py b/amazon/paapi5_python_sdk/max_price.py deleted file mode 100644 index 651f4da..0000000 --- a/amazon/paapi5_python_sdk/max_price.py +++ /dev/null @@ -1,98 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class MaxPrice(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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """MaxPrice - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(MaxPrice, 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, MaxPrice): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/merchant.py b/amazon/paapi5_python_sdk/merchant.py deleted file mode 100644 index f5a6ad9..0000000 --- a/amazon/paapi5_python_sdk/merchant.py +++ /dev/null @@ -1,104 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class Merchant(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - - """ - allowed enum values - """ - ALL = "All" - AMAZON = "Amazon" - - """ - 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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """Merchant - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(Merchant, 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, Merchant): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/min_price.py b/amazon/paapi5_python_sdk/min_price.py deleted file mode 100644 index b4b2aa4..0000000 --- a/amazon/paapi5_python_sdk/min_price.py +++ /dev/null @@ -1,98 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class MinPrice(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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """MinPrice - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(MinPrice, 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, MinPrice): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/min_reviews_rating.py b/amazon/paapi5_python_sdk/min_reviews_rating.py deleted file mode 100644 index a4d1bbb..0000000 --- a/amazon/paapi5_python_sdk/min_reviews_rating.py +++ /dev/null @@ -1,98 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class MinReviewsRating(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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """MinReviewsRating - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(MinReviewsRating, 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, MinReviewsRating): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/min_saving_percent.py b/amazon/paapi5_python_sdk/min_saving_percent.py deleted file mode 100644 index a3ec1ad..0000000 --- a/amazon/paapi5_python_sdk/min_saving_percent.py +++ /dev/null @@ -1,98 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class MinSavingPercent(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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """MinSavingPercent - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(MinSavingPercent, 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, MinSavingPercent): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/multi_valued_attribute.py b/amazon/paapi5_python_sdk/multi_valued_attribute.py deleted file mode 100644 index 0d1e6b5..0000000 --- a/amazon/paapi5_python_sdk/multi_valued_attribute.py +++ /dev/null @@ -1,178 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class MultiValuedAttribute(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 = { - 'display_values': 'list[str]', - 'label': 'str', - 'locale': 'str' - } - - attribute_map = { - 'display_values': 'DisplayValues', - 'label': 'Label', - 'locale': 'Locale' - } - - def __init__(self, display_values=None, label=None, locale=None): # noqa: E501 - """MultiValuedAttribute - a model defined in Swagger""" # noqa: E501 - - self._display_values = None - self._label = None - self._locale = None - self.discriminator = None - - if display_values is not None: - self.display_values = display_values - if label is not None: - self.label = label - if locale is not None: - self.locale = locale - - @property - def display_values(self): - """Gets the display_values of this MultiValuedAttribute. # noqa: E501 - - - :return: The display_values of this MultiValuedAttribute. # noqa: E501 - :rtype: list[str] - """ - return self._display_values - - @display_values.setter - def display_values(self, display_values): - """Sets the display_values of this MultiValuedAttribute. - - - :param display_values: The display_values of this MultiValuedAttribute. # noqa: E501 - :type: list[str] - """ - - self._display_values = display_values - - @property - def label(self): - """Gets the label of this MultiValuedAttribute. # noqa: E501 - - - :return: The label of this MultiValuedAttribute. # noqa: E501 - :rtype: str - """ - return self._label - - @label.setter - def label(self, label): - """Sets the label of this MultiValuedAttribute. - - - :param label: The label of this MultiValuedAttribute. # noqa: E501 - :type: str - """ - - self._label = label - - @property - def locale(self): - """Gets the locale of this MultiValuedAttribute. # noqa: E501 - - - :return: The locale of this MultiValuedAttribute. # noqa: E501 - :rtype: str - """ - return self._locale - - @locale.setter - def locale(self, locale): - """Sets the locale of this MultiValuedAttribute. - - - :param locale: The locale of this MultiValuedAttribute. # noqa: E501 - :type: str - """ - - self._locale = locale - - 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(MultiValuedAttribute, 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, MultiValuedAttribute): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_availability.py b/amazon/paapi5_python_sdk/offer_availability.py deleted file mode 100644 index 2da4ef6..0000000 --- a/amazon/paapi5_python_sdk/offer_availability.py +++ /dev/null @@ -1,203 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -class OfferAvailability(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 = { - 'max_order_quantity': 'int', - 'message': 'str', - 'min_order_quantity': 'int', - 'type': 'str' - } - - attribute_map = { - 'max_order_quantity': 'MaxOrderQuantity', - 'message': 'Message', - 'min_order_quantity': 'MinOrderQuantity', - 'type': 'Type' - } - - def __init__(self, max_order_quantity=None, message=None, min_order_quantity=None, type=None): # noqa: E501 - """OfferAvailability - a model defined in Swagger""" # noqa: E501 - - self._max_order_quantity = None - self._message = None - self._min_order_quantity = None - self._type = None - self.discriminator = None - - if max_order_quantity is not None: - self.max_order_quantity = max_order_quantity - if message is not None: - self.message = message - if min_order_quantity is not None: - self.min_order_quantity = min_order_quantity - if type is not None: - self.type = type - - @property - def max_order_quantity(self): - """Gets the max_order_quantity of this OfferAvailability. # noqa: E501 - - - :return: The max_order_quantity of this OfferAvailability. # noqa: E501 - :rtype: int - """ - return self._max_order_quantity - - @max_order_quantity.setter - def max_order_quantity(self, max_order_quantity): - """Sets the max_order_quantity of this OfferAvailability. - - - :param max_order_quantity: The max_order_quantity of this OfferAvailability. # noqa: E501 - :type: int - """ - - self._max_order_quantity = max_order_quantity - - @property - def message(self): - """Gets the message of this OfferAvailability. # noqa: E501 - - - :return: The message of this OfferAvailability. # noqa: E501 - :rtype: str - """ - return self._message - - @message.setter - def message(self, message): - """Sets the message of this OfferAvailability. - - - :param message: The message of this OfferAvailability. # noqa: E501 - :type: str - """ - - self._message = message - - @property - def min_order_quantity(self): - """Gets the min_order_quantity of this OfferAvailability. # noqa: E501 - - - :return: The min_order_quantity of this OfferAvailability. # noqa: E501 - :rtype: int - """ - return self._min_order_quantity - - @min_order_quantity.setter - def min_order_quantity(self, min_order_quantity): - """Sets the min_order_quantity of this OfferAvailability. - - - :param min_order_quantity: The min_order_quantity of this OfferAvailability. # noqa: E501 - :type: int - """ - - self._min_order_quantity = min_order_quantity - - @property - def type(self): - """Gets the type of this OfferAvailability. # noqa: E501 - - - :return: The type of this OfferAvailability. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this OfferAvailability. - - - :param type: The type of this OfferAvailability. # noqa: E501 - :type: str - """ - - self._type = 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(OfferAvailability, 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, OfferAvailability): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_condition.py b/amazon/paapi5_python_sdk/offer_condition.py deleted file mode 100644 index 056091f..0000000 --- a/amazon/paapi5_python_sdk/offer_condition.py +++ /dev/null @@ -1,232 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .offer_sub_condition import OfferSubCondition # noqa: F401,E501 - - -class OfferCondition(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 = { - 'display_value': 'str', - 'label': 'str', - 'locale': 'str', - 'value': 'str', - 'sub_condition': 'OfferSubCondition' - } - - attribute_map = { - 'display_value': 'DisplayValue', - 'label': 'Label', - 'locale': 'Locale', - 'value': 'Value', - 'sub_condition': 'SubCondition' - } - - def __init__(self, display_value=None, label=None, locale=None, value=None, sub_condition=None): # noqa: E501 - """OfferCondition - a model defined in Swagger""" # noqa: E501 - - self._display_value = None - self._label = None - self._locale = None - self._value = None - self._sub_condition = None - self.discriminator = None - - if display_value is not None: - self.display_value = display_value - if label is not None: - self.label = label - if locale is not None: - self.locale = locale - if value is not None: - self.value = value - if sub_condition is not None: - self.sub_condition = sub_condition - - @property - def display_value(self): - """Gets the display_value of this OfferCondition. # noqa: E501 - - - :return: The display_value of this OfferCondition. # noqa: E501 - :rtype: str - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this OfferCondition. - - - :param display_value: The display_value of this OfferCondition. # noqa: E501 - :type: str - """ - - self._display_value = display_value - - @property - def label(self): - """Gets the label of this OfferCondition. # noqa: E501 - - - :return: The label of this OfferCondition. # noqa: E501 - :rtype: str - """ - return self._label - - @label.setter - def label(self, label): - """Sets the label of this OfferCondition. - - - :param label: The label of this OfferCondition. # noqa: E501 - :type: str - """ - - self._label = label - - @property - def locale(self): - """Gets the locale of this OfferCondition. # noqa: E501 - - - :return: The locale of this OfferCondition. # noqa: E501 - :rtype: str - """ - return self._locale - - @locale.setter - def locale(self, locale): - """Sets the locale of this OfferCondition. - - - :param locale: The locale of this OfferCondition. # noqa: E501 - :type: str - """ - - self._locale = locale - - @property - def value(self): - """Gets the value of this OfferCondition. # noqa: E501 - - - :return: The value of this OfferCondition. # noqa: E501 - :rtype: str - """ - return self._value - - @value.setter - def value(self, value): - """Sets the value of this OfferCondition. - - - :param value: The value of this OfferCondition. # noqa: E501 - :type: str - """ - - self._value = value - - @property - def sub_condition(self): - """Gets the sub_condition of this OfferCondition. # noqa: E501 - - - :return: The sub_condition of this OfferCondition. # noqa: E501 - :rtype: OfferSubCondition - """ - return self._sub_condition - - @sub_condition.setter - def sub_condition(self, sub_condition): - """Sets the sub_condition of this OfferCondition. - - - :param sub_condition: The sub_condition of this OfferCondition. # noqa: E501 - :type: OfferSubCondition - """ - - self._sub_condition = sub_condition - - 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(OfferCondition, 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, OfferCondition): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_count.py b/amazon/paapi5_python_sdk/offer_count.py deleted file mode 100644 index 951020b..0000000 --- a/amazon/paapi5_python_sdk/offer_count.py +++ /dev/null @@ -1,98 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class OfferCount(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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """OfferCount - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(OfferCount, 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, OfferCount): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_delivery_info.py b/amazon/paapi5_python_sdk/offer_delivery_info.py deleted file mode 100644 index 69ad748..0000000 --- a/amazon/paapi5_python_sdk/offer_delivery_info.py +++ /dev/null @@ -1,206 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .offer_shipping_charge import OfferShippingCharge # noqa: F401,E501 - - -class OfferDeliveryInfo(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 = { - 'is_amazon_fulfilled': 'bool', - 'is_free_shipping_eligible': 'bool', - 'is_prime_eligible': 'bool', - 'shipping_charges': 'list[OfferShippingCharge]' - } - - attribute_map = { - 'is_amazon_fulfilled': 'IsAmazonFulfilled', - 'is_free_shipping_eligible': 'IsFreeShippingEligible', - 'is_prime_eligible': 'IsPrimeEligible', - 'shipping_charges': 'ShippingCharges' - } - - def __init__(self, is_amazon_fulfilled=None, is_free_shipping_eligible=None, is_prime_eligible=None, shipping_charges=None): # noqa: E501 - """OfferDeliveryInfo - a model defined in Swagger""" # noqa: E501 - - self._is_amazon_fulfilled = None - self._is_free_shipping_eligible = None - self._is_prime_eligible = None - self._shipping_charges = None - self.discriminator = None - - if is_amazon_fulfilled is not None: - self.is_amazon_fulfilled = is_amazon_fulfilled - if is_free_shipping_eligible is not None: - self.is_free_shipping_eligible = is_free_shipping_eligible - if is_prime_eligible is not None: - self.is_prime_eligible = is_prime_eligible - if shipping_charges is not None: - self.shipping_charges = shipping_charges - - @property - def is_amazon_fulfilled(self): - """Gets the is_amazon_fulfilled of this OfferDeliveryInfo. # noqa: E501 - - - :return: The is_amazon_fulfilled of this OfferDeliveryInfo. # noqa: E501 - :rtype: bool - """ - return self._is_amazon_fulfilled - - @is_amazon_fulfilled.setter - def is_amazon_fulfilled(self, is_amazon_fulfilled): - """Sets the is_amazon_fulfilled of this OfferDeliveryInfo. - - - :param is_amazon_fulfilled: The is_amazon_fulfilled of this OfferDeliveryInfo. # noqa: E501 - :type: bool - """ - - self._is_amazon_fulfilled = is_amazon_fulfilled - - @property - def is_free_shipping_eligible(self): - """Gets the is_free_shipping_eligible of this OfferDeliveryInfo. # noqa: E501 - - - :return: The is_free_shipping_eligible of this OfferDeliveryInfo. # noqa: E501 - :rtype: bool - """ - return self._is_free_shipping_eligible - - @is_free_shipping_eligible.setter - def is_free_shipping_eligible(self, is_free_shipping_eligible): - """Sets the is_free_shipping_eligible of this OfferDeliveryInfo. - - - :param is_free_shipping_eligible: The is_free_shipping_eligible of this OfferDeliveryInfo. # noqa: E501 - :type: bool - """ - - self._is_free_shipping_eligible = is_free_shipping_eligible - - @property - def is_prime_eligible(self): - """Gets the is_prime_eligible of this OfferDeliveryInfo. # noqa: E501 - - - :return: The is_prime_eligible of this OfferDeliveryInfo. # noqa: E501 - :rtype: bool - """ - return self._is_prime_eligible - - @is_prime_eligible.setter - def is_prime_eligible(self, is_prime_eligible): - """Sets the is_prime_eligible of this OfferDeliveryInfo. - - - :param is_prime_eligible: The is_prime_eligible of this OfferDeliveryInfo. # noqa: E501 - :type: bool - """ - - self._is_prime_eligible = is_prime_eligible - - @property - def shipping_charges(self): - """Gets the shipping_charges of this OfferDeliveryInfo. # noqa: E501 - - - :return: The shipping_charges of this OfferDeliveryInfo. # noqa: E501 - :rtype: list[OfferShippingCharge] - """ - return self._shipping_charges - - @shipping_charges.setter - def shipping_charges(self, shipping_charges): - """Sets the shipping_charges of this OfferDeliveryInfo. - - - :param shipping_charges: The shipping_charges of this OfferDeliveryInfo. # noqa: E501 - :type: list[OfferShippingCharge] - """ - - self._shipping_charges = shipping_charges - - 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(OfferDeliveryInfo, 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, OfferDeliveryInfo): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_listing.py b/amazon/paapi5_python_sdk/offer_listing.py deleted file mode 100644 index 0cb3be6..0000000 --- a/amazon/paapi5_python_sdk/offer_listing.py +++ /dev/null @@ -1,421 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .offer_availability import OfferAvailability # noqa: F401,E501 -from .offer_condition import OfferCondition # noqa: F401,E501 -from .offer_delivery_info import OfferDeliveryInfo # noqa: F401,E501 -from .offer_loyalty_points import OfferLoyaltyPoints # noqa: F401,E501 -from .offer_merchant_info import OfferMerchantInfo # noqa: F401,E501 -from .offer_price import OfferPrice # noqa: F401,E501 -from .offer_program_eligibility import OfferProgramEligibility # noqa: F401,E501 -from .offer_promotion import OfferPromotion # noqa: F401,E501 - - -class OfferListing(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 = { - 'availability': 'OfferAvailability', - 'condition': 'OfferCondition', - 'delivery_info': 'OfferDeliveryInfo', - 'id': 'str', - 'is_buy_box_winner': 'bool', - 'loyalty_points': 'OfferLoyaltyPoints', - 'merchant_info': 'OfferMerchantInfo', - 'price': 'OfferPrice', - 'program_eligibility': 'OfferProgramEligibility', - 'promotions': 'list[OfferPromotion]', - 'saving_basis': 'OfferPrice', - 'violates_map': 'bool' - } - - attribute_map = { - 'availability': 'Availability', - 'condition': 'Condition', - 'delivery_info': 'DeliveryInfo', - 'id': 'Id', - 'is_buy_box_winner': 'IsBuyBoxWinner', - 'loyalty_points': 'LoyaltyPoints', - 'merchant_info': 'MerchantInfo', - 'price': 'Price', - 'program_eligibility': 'ProgramEligibility', - 'promotions': 'Promotions', - 'saving_basis': 'SavingBasis', - 'violates_map': 'ViolatesMAP' - } - - def __init__(self, availability=None, condition=None, delivery_info=None, id=None, is_buy_box_winner=None, loyalty_points=None, merchant_info=None, price=None, program_eligibility=None, promotions=None, saving_basis=None, violates_map=None): # noqa: E501 - """OfferListing - a model defined in Swagger""" # noqa: E501 - - self._availability = None - self._condition = None - self._delivery_info = None - self._id = None - self._is_buy_box_winner = None - self._loyalty_points = None - self._merchant_info = None - self._price = None - self._program_eligibility = None - self._promotions = None - self._saving_basis = None - self._violates_map = None - self.discriminator = None - - if availability is not None: - self.availability = availability - if condition is not None: - self.condition = condition - if delivery_info is not None: - self.delivery_info = delivery_info - if id is not None: - self.id = id - if is_buy_box_winner is not None: - self.is_buy_box_winner = is_buy_box_winner - if loyalty_points is not None: - self.loyalty_points = loyalty_points - if merchant_info is not None: - self.merchant_info = merchant_info - if price is not None: - self.price = price - if program_eligibility is not None: - self.program_eligibility = program_eligibility - if promotions is not None: - self.promotions = promotions - if saving_basis is not None: - self.saving_basis = saving_basis - if violates_map is not None: - self.violates_map = violates_map - - @property - def availability(self): - """Gets the availability of this OfferListing. # noqa: E501 - - - :return: The availability of this OfferListing. # noqa: E501 - :rtype: OfferAvailability - """ - return self._availability - - @availability.setter - def availability(self, availability): - """Sets the availability of this OfferListing. - - - :param availability: The availability of this OfferListing. # noqa: E501 - :type: OfferAvailability - """ - - self._availability = availability - - @property - def condition(self): - """Gets the condition of this OfferListing. # noqa: E501 - - - :return: The condition of this OfferListing. # noqa: E501 - :rtype: OfferCondition - """ - return self._condition - - @condition.setter - def condition(self, condition): - """Sets the condition of this OfferListing. - - - :param condition: The condition of this OfferListing. # noqa: E501 - :type: OfferCondition - """ - - self._condition = condition - - @property - def delivery_info(self): - """Gets the delivery_info of this OfferListing. # noqa: E501 - - - :return: The delivery_info of this OfferListing. # noqa: E501 - :rtype: OfferDeliveryInfo - """ - return self._delivery_info - - @delivery_info.setter - def delivery_info(self, delivery_info): - """Sets the delivery_info of this OfferListing. - - - :param delivery_info: The delivery_info of this OfferListing. # noqa: E501 - :type: OfferDeliveryInfo - """ - - self._delivery_info = delivery_info - - @property - def id(self): - """Gets the id of this OfferListing. # noqa: E501 - - - :return: The id of this OfferListing. # noqa: E501 - :rtype: str - """ - return self._id - - @id.setter - def id(self, id): - """Sets the id of this OfferListing. - - - :param id: The id of this OfferListing. # noqa: E501 - :type: str - """ - - self._id = id - - @property - def is_buy_box_winner(self): - """Gets the is_buy_box_winner of this OfferListing. # noqa: E501 - - - :return: The is_buy_box_winner of this OfferListing. # noqa: E501 - :rtype: bool - """ - return self._is_buy_box_winner - - @is_buy_box_winner.setter - def is_buy_box_winner(self, is_buy_box_winner): - """Sets the is_buy_box_winner of this OfferListing. - - - :param is_buy_box_winner: The is_buy_box_winner of this OfferListing. # noqa: E501 - :type: bool - """ - - self._is_buy_box_winner = is_buy_box_winner - - @property - def loyalty_points(self): - """Gets the loyalty_points of this OfferListing. # noqa: E501 - - - :return: The loyalty_points of this OfferListing. # noqa: E501 - :rtype: OfferLoyaltyPoints - """ - return self._loyalty_points - - @loyalty_points.setter - def loyalty_points(self, loyalty_points): - """Sets the loyalty_points of this OfferListing. - - - :param loyalty_points: The loyalty_points of this OfferListing. # noqa: E501 - :type: OfferLoyaltyPoints - """ - - self._loyalty_points = loyalty_points - - @property - def merchant_info(self): - """Gets the merchant_info of this OfferListing. # noqa: E501 - - - :return: The merchant_info of this OfferListing. # noqa: E501 - :rtype: OfferMerchantInfo - """ - return self._merchant_info - - @merchant_info.setter - def merchant_info(self, merchant_info): - """Sets the merchant_info of this OfferListing. - - - :param merchant_info: The merchant_info of this OfferListing. # noqa: E501 - :type: OfferMerchantInfo - """ - - self._merchant_info = merchant_info - - @property - def price(self): - """Gets the price of this OfferListing. # noqa: E501 - - - :return: The price of this OfferListing. # noqa: E501 - :rtype: OfferPrice - """ - return self._price - - @price.setter - def price(self, price): - """Sets the price of this OfferListing. - - - :param price: The price of this OfferListing. # noqa: E501 - :type: OfferPrice - """ - - self._price = price - - @property - def program_eligibility(self): - """Gets the program_eligibility of this OfferListing. # noqa: E501 - - - :return: The program_eligibility of this OfferListing. # noqa: E501 - :rtype: OfferProgramEligibility - """ - return self._program_eligibility - - @program_eligibility.setter - def program_eligibility(self, program_eligibility): - """Sets the program_eligibility of this OfferListing. - - - :param program_eligibility: The program_eligibility of this OfferListing. # noqa: E501 - :type: OfferProgramEligibility - """ - - self._program_eligibility = program_eligibility - - @property - def promotions(self): - """Gets the promotions of this OfferListing. # noqa: E501 - - - :return: The promotions of this OfferListing. # noqa: E501 - :rtype: list[OfferPromotion] - """ - return self._promotions - - @promotions.setter - def promotions(self, promotions): - """Sets the promotions of this OfferListing. - - - :param promotions: The promotions of this OfferListing. # noqa: E501 - :type: list[OfferPromotion] - """ - - self._promotions = promotions - - @property - def saving_basis(self): - """Gets the saving_basis of this OfferListing. # noqa: E501 - - - :return: The saving_basis of this OfferListing. # noqa: E501 - :rtype: OfferPrice - """ - return self._saving_basis - - @saving_basis.setter - def saving_basis(self, saving_basis): - """Sets the saving_basis of this OfferListing. - - - :param saving_basis: The saving_basis of this OfferListing. # noqa: E501 - :type: OfferPrice - """ - - self._saving_basis = saving_basis - - @property - def violates_map(self): - """Gets the violates_map of this OfferListing. # noqa: E501 - - - :return: The violates_map of this OfferListing. # noqa: E501 - :rtype: bool - """ - return self._violates_map - - @violates_map.setter - def violates_map(self, violates_map): - """Sets the violates_map of this OfferListing. - - - :param violates_map: The violates_map of this OfferListing. # noqa: E501 - :type: bool - """ - - self._violates_map = violates_map - - 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(OfferListing, 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, OfferListing): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_loyalty_points.py b/amazon/paapi5_python_sdk/offer_loyalty_points.py deleted file mode 100644 index 08b86e9..0000000 --- a/amazon/paapi5_python_sdk/offer_loyalty_points.py +++ /dev/null @@ -1,126 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class OfferLoyaltyPoints(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 = { - 'points': 'int' - } - - attribute_map = { - 'points': 'Points' - } - - def __init__(self, points=None): # noqa: E501 - """OfferLoyaltyPoints - a model defined in Swagger""" # noqa: E501 - - self._points = None - self.discriminator = None - - if points is not None: - self.points = points - - @property - def points(self): - """Gets the points of this OfferLoyaltyPoints. # noqa: E501 - - - :return: The points of this OfferLoyaltyPoints. # noqa: E501 - :rtype: int - """ - return self._points - - @points.setter - def points(self, points): - """Sets the points of this OfferLoyaltyPoints. - - - :param points: The points of this OfferLoyaltyPoints. # noqa: E501 - :type: int - """ - - self._points = points - - 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(OfferLoyaltyPoints, 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, OfferLoyaltyPoints): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_merchant_info.py b/amazon/paapi5_python_sdk/offer_merchant_info.py deleted file mode 100644 index b0ec576..0000000 --- a/amazon/paapi5_python_sdk/offer_merchant_info.py +++ /dev/null @@ -1,178 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class OfferMerchantInfo(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 = { - 'default_shipping_country': 'str', - 'id': 'str', - 'name': 'str' - } - - attribute_map = { - 'default_shipping_country': 'DefaultShippingCountry', - 'id': 'Id', - 'name': 'Name' - } - - def __init__(self, default_shipping_country=None, id=None, name=None): # noqa: E501 - """OfferMerchantInfo - a model defined in Swagger""" # noqa: E501 - - self._default_shipping_country = None - self._id = None - self._name = None - self.discriminator = None - - if default_shipping_country is not None: - self.default_shipping_country = default_shipping_country - if id is not None: - self.id = id - if name is not None: - self.name = name - - @property - def default_shipping_country(self): - """Gets the default_shipping_country of this OfferMerchantInfo. # noqa: E501 - - - :return: The default_shipping_country of this OfferMerchantInfo. # noqa: E501 - :rtype: str - """ - return self._default_shipping_country - - @default_shipping_country.setter - def default_shipping_country(self, default_shipping_country): - """Sets the default_shipping_country of this OfferMerchantInfo. - - - :param default_shipping_country: The default_shipping_country of this OfferMerchantInfo. # noqa: E501 - :type: str - """ - - self._default_shipping_country = default_shipping_country - - @property - def id(self): - """Gets the id of this OfferMerchantInfo. # noqa: E501 - - - :return: The id of this OfferMerchantInfo. # noqa: E501 - :rtype: str - """ - return self._id - - @id.setter - def id(self, id): - """Sets the id of this OfferMerchantInfo. - - - :param id: The id of this OfferMerchantInfo. # noqa: E501 - :type: str - """ - - self._id = id - - @property - def name(self): - """Gets the name of this OfferMerchantInfo. # noqa: E501 - - - :return: The name of this OfferMerchantInfo. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this OfferMerchantInfo. - - - :param name: The name of this OfferMerchantInfo. # noqa: E501 - :type: str - """ - - self._name = name - - 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(OfferMerchantInfo, 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, OfferMerchantInfo): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_price.py b/amazon/paapi5_python_sdk/offer_price.py deleted file mode 100644 index 343c9b5..0000000 --- a/amazon/paapi5_python_sdk/offer_price.py +++ /dev/null @@ -1,232 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .offer_savings import OfferSavings # noqa: F401,E501 - - -class OfferPrice(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 = { - 'amount': 'float', - 'currency': 'str', - 'display_amount': 'str', - 'price_per_unit': 'float', - 'savings': 'OfferSavings' - } - - attribute_map = { - 'amount': 'Amount', - 'currency': 'Currency', - 'display_amount': 'DisplayAmount', - 'price_per_unit': 'PricePerUnit', - 'savings': 'Savings' - } - - def __init__(self, amount=None, currency=None, display_amount=None, price_per_unit=None, savings=None): # noqa: E501 - """OfferPrice - a model defined in Swagger""" # noqa: E501 - - self._amount = None - self._currency = None - self._display_amount = None - self._price_per_unit = None - self._savings = None - self.discriminator = None - - if amount is not None: - self.amount = amount - if currency is not None: - self.currency = currency - if display_amount is not None: - self.display_amount = display_amount - if price_per_unit is not None: - self.price_per_unit = price_per_unit - if savings is not None: - self.savings = savings - - @property - def amount(self): - """Gets the amount of this OfferPrice. # noqa: E501 - - - :return: The amount of this OfferPrice. # noqa: E501 - :rtype: float - """ - return self._amount - - @amount.setter - def amount(self, amount): - """Sets the amount of this OfferPrice. - - - :param amount: The amount of this OfferPrice. # noqa: E501 - :type: float - """ - - self._amount = amount - - @property - def currency(self): - """Gets the currency of this OfferPrice. # noqa: E501 - - - :return: The currency of this OfferPrice. # noqa: E501 - :rtype: str - """ - return self._currency - - @currency.setter - def currency(self, currency): - """Sets the currency of this OfferPrice. - - - :param currency: The currency of this OfferPrice. # noqa: E501 - :type: str - """ - - self._currency = currency - - @property - def display_amount(self): - """Gets the display_amount of this OfferPrice. # noqa: E501 - - - :return: The display_amount of this OfferPrice. # noqa: E501 - :rtype: str - """ - return self._display_amount - - @display_amount.setter - def display_amount(self, display_amount): - """Sets the display_amount of this OfferPrice. - - - :param display_amount: The display_amount of this OfferPrice. # noqa: E501 - :type: str - """ - - self._display_amount = display_amount - - @property - def price_per_unit(self): - """Gets the price_per_unit of this OfferPrice. # noqa: E501 - - - :return: The price_per_unit of this OfferPrice. # noqa: E501 - :rtype: float - """ - return self._price_per_unit - - @price_per_unit.setter - def price_per_unit(self, price_per_unit): - """Sets the price_per_unit of this OfferPrice. - - - :param price_per_unit: The price_per_unit of this OfferPrice. # noqa: E501 - :type: float - """ - - self._price_per_unit = price_per_unit - - @property - def savings(self): - """Gets the savings of this OfferPrice. # noqa: E501 - - - :return: The savings of this OfferPrice. # noqa: E501 - :rtype: OfferSavings - """ - return self._savings - - @savings.setter - def savings(self, savings): - """Sets the savings of this OfferPrice. - - - :param savings: The savings of this OfferPrice. # noqa: E501 - :type: OfferSavings - """ - - self._savings = savings - - 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(OfferPrice, 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, OfferPrice): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_program_eligibility.py b/amazon/paapi5_python_sdk/offer_program_eligibility.py deleted file mode 100644 index ffeaa6c..0000000 --- a/amazon/paapi5_python_sdk/offer_program_eligibility.py +++ /dev/null @@ -1,152 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class OfferProgramEligibility(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 = { - 'is_prime_exclusive': 'bool', - 'is_prime_pantry': 'bool' - } - - attribute_map = { - 'is_prime_exclusive': 'IsPrimeExclusive', - 'is_prime_pantry': 'IsPrimePantry' - } - - def __init__(self, is_prime_exclusive=None, is_prime_pantry=None): # noqa: E501 - """OfferProgramEligibility - a model defined in Swagger""" # noqa: E501 - - self._is_prime_exclusive = None - self._is_prime_pantry = None - self.discriminator = None - - if is_prime_exclusive is not None: - self.is_prime_exclusive = is_prime_exclusive - if is_prime_pantry is not None: - self.is_prime_pantry = is_prime_pantry - - @property - def is_prime_exclusive(self): - """Gets the is_prime_exclusive of this OfferProgramEligibility. # noqa: E501 - - - :return: The is_prime_exclusive of this OfferProgramEligibility. # noqa: E501 - :rtype: bool - """ - return self._is_prime_exclusive - - @is_prime_exclusive.setter - def is_prime_exclusive(self, is_prime_exclusive): - """Sets the is_prime_exclusive of this OfferProgramEligibility. - - - :param is_prime_exclusive: The is_prime_exclusive of this OfferProgramEligibility. # noqa: E501 - :type: bool - """ - - self._is_prime_exclusive = is_prime_exclusive - - @property - def is_prime_pantry(self): - """Gets the is_prime_pantry of this OfferProgramEligibility. # noqa: E501 - - - :return: The is_prime_pantry of this OfferProgramEligibility. # noqa: E501 - :rtype: bool - """ - return self._is_prime_pantry - - @is_prime_pantry.setter - def is_prime_pantry(self, is_prime_pantry): - """Sets the is_prime_pantry of this OfferProgramEligibility. - - - :param is_prime_pantry: The is_prime_pantry of this OfferProgramEligibility. # noqa: E501 - :type: bool - """ - - self._is_prime_pantry = is_prime_pantry - - 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(OfferProgramEligibility, 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, OfferProgramEligibility): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_promotion.py b/amazon/paapi5_python_sdk/offer_promotion.py deleted file mode 100644 index d161a4b..0000000 --- a/amazon/paapi5_python_sdk/offer_promotion.py +++ /dev/null @@ -1,255 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -class OfferPromotion(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 = { - 'amount': 'float', - 'currency': 'str', - 'discount_percent': 'int', - 'display_amount': 'str', - 'price_per_unit': 'float', - 'type': 'str' - } - - attribute_map = { - 'amount': 'Amount', - 'currency': 'Currency', - 'discount_percent': 'DiscountPercent', - 'display_amount': 'DisplayAmount', - 'price_per_unit': 'PricePerUnit', - 'type': 'Type' - } - - def __init__(self, amount=None, currency=None, discount_percent=None, display_amount=None, price_per_unit=None, type=None): # noqa: E501 - """OfferPromotion - a model defined in Swagger""" # noqa: E501 - - self._amount = None - self._currency = None - self._discount_percent = None - self._display_amount = None - self._price_per_unit = None - self._type = None - self.discriminator = None - - if amount is not None: - self.amount = amount - if currency is not None: - self.currency = currency - if discount_percent is not None: - self.discount_percent = discount_percent - if display_amount is not None: - self.display_amount = display_amount - if price_per_unit is not None: - self.price_per_unit = price_per_unit - if type is not None: - self.type = type - - @property - def amount(self): - """Gets the amount of this OfferPromotion. # noqa: E501 - - - :return: The amount of this OfferPromotion. # noqa: E501 - :rtype: float - """ - return self._amount - - @amount.setter - def amount(self, amount): - """Sets the amount of this OfferPromotion. - - - :param amount: The amount of this OfferPromotion. # noqa: E501 - :type: float - """ - - self._amount = amount - - @property - def currency(self): - """Gets the currency of this OfferPromotion. # noqa: E501 - - - :return: The currency of this OfferPromotion. # noqa: E501 - :rtype: str - """ - return self._currency - - @currency.setter - def currency(self, currency): - """Sets the currency of this OfferPromotion. - - - :param currency: The currency of this OfferPromotion. # noqa: E501 - :type: str - """ - - self._currency = currency - - @property - def discount_percent(self): - """Gets the discount_percent of this OfferPromotion. # noqa: E501 - - - :return: The discount_percent of this OfferPromotion. # noqa: E501 - :rtype: int - """ - return self._discount_percent - - @discount_percent.setter - def discount_percent(self, discount_percent): - """Sets the discount_percent of this OfferPromotion. - - - :param discount_percent: The discount_percent of this OfferPromotion. # noqa: E501 - :type: int - """ - - self._discount_percent = discount_percent - - @property - def display_amount(self): - """Gets the display_amount of this OfferPromotion. # noqa: E501 - - - :return: The display_amount of this OfferPromotion. # noqa: E501 - :rtype: str - """ - return self._display_amount - - @display_amount.setter - def display_amount(self, display_amount): - """Sets the display_amount of this OfferPromotion. - - - :param display_amount: The display_amount of this OfferPromotion. # noqa: E501 - :type: str - """ - - self._display_amount = display_amount - - @property - def price_per_unit(self): - """Gets the price_per_unit of this OfferPromotion. # noqa: E501 - - - :return: The price_per_unit of this OfferPromotion. # noqa: E501 - :rtype: float - """ - return self._price_per_unit - - @price_per_unit.setter - def price_per_unit(self, price_per_unit): - """Sets the price_per_unit of this OfferPromotion. - - - :param price_per_unit: The price_per_unit of this OfferPromotion. # noqa: E501 - :type: float - """ - - self._price_per_unit = price_per_unit - - @property - def type(self): - """Gets the type of this OfferPromotion. # noqa: E501 - - - :return: The type of this OfferPromotion. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this OfferPromotion. - - - :param type: The type of this OfferPromotion. # noqa: E501 - :type: str - """ - - self._type = 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(OfferPromotion, 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, OfferPromotion): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_savings.py b/amazon/paapi5_python_sdk/offer_savings.py deleted file mode 100644 index 42c5eb9..0000000 --- a/amazon/paapi5_python_sdk/offer_savings.py +++ /dev/null @@ -1,230 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class OfferSavings(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 = { - 'amount': 'float', - 'currency': 'str', - 'display_amount': 'str', - 'percentage': 'int', - 'price_per_unit': 'float' - } - - attribute_map = { - 'amount': 'Amount', - 'currency': 'Currency', - 'display_amount': 'DisplayAmount', - 'percentage': 'Percentage', - 'price_per_unit': 'PricePerUnit' - } - - def __init__(self, amount=None, currency=None, display_amount=None, percentage=None, price_per_unit=None): # noqa: E501 - """OfferSavings - a model defined in Swagger""" # noqa: E501 - - self._amount = None - self._currency = None - self._display_amount = None - self._percentage = None - self._price_per_unit = None - self.discriminator = None - - if amount is not None: - self.amount = amount - if currency is not None: - self.currency = currency - if display_amount is not None: - self.display_amount = display_amount - if percentage is not None: - self.percentage = percentage - if price_per_unit is not None: - self.price_per_unit = price_per_unit - - @property - def amount(self): - """Gets the amount of this OfferSavings. # noqa: E501 - - - :return: The amount of this OfferSavings. # noqa: E501 - :rtype: float - """ - return self._amount - - @amount.setter - def amount(self, amount): - """Sets the amount of this OfferSavings. - - - :param amount: The amount of this OfferSavings. # noqa: E501 - :type: float - """ - - self._amount = amount - - @property - def currency(self): - """Gets the currency of this OfferSavings. # noqa: E501 - - - :return: The currency of this OfferSavings. # noqa: E501 - :rtype: str - """ - return self._currency - - @currency.setter - def currency(self, currency): - """Sets the currency of this OfferSavings. - - - :param currency: The currency of this OfferSavings. # noqa: E501 - :type: str - """ - - self._currency = currency - - @property - def display_amount(self): - """Gets the display_amount of this OfferSavings. # noqa: E501 - - - :return: The display_amount of this OfferSavings. # noqa: E501 - :rtype: str - """ - return self._display_amount - - @display_amount.setter - def display_amount(self, display_amount): - """Sets the display_amount of this OfferSavings. - - - :param display_amount: The display_amount of this OfferSavings. # noqa: E501 - :type: str - """ - - self._display_amount = display_amount - - @property - def percentage(self): - """Gets the percentage of this OfferSavings. # noqa: E501 - - - :return: The percentage of this OfferSavings. # noqa: E501 - :rtype: int - """ - return self._percentage - - @percentage.setter - def percentage(self, percentage): - """Sets the percentage of this OfferSavings. - - - :param percentage: The percentage of this OfferSavings. # noqa: E501 - :type: int - """ - - self._percentage = percentage - - @property - def price_per_unit(self): - """Gets the price_per_unit of this OfferSavings. # noqa: E501 - - - :return: The price_per_unit of this OfferSavings. # noqa: E501 - :rtype: float - """ - return self._price_per_unit - - @price_per_unit.setter - def price_per_unit(self, price_per_unit): - """Sets the price_per_unit of this OfferSavings. - - - :param price_per_unit: The price_per_unit of this OfferSavings. # noqa: E501 - :type: float - """ - - self._price_per_unit = price_per_unit - - 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(OfferSavings, 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, OfferSavings): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_shipping_charge.py b/amazon/paapi5_python_sdk/offer_shipping_charge.py deleted file mode 100644 index 5674f19..0000000 --- a/amazon/paapi5_python_sdk/offer_shipping_charge.py +++ /dev/null @@ -1,229 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -class OfferShippingCharge(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 = { - 'amount': 'float', - 'currency': 'str', - 'display_amount': 'str', - 'is_rate_tax_inclusive': 'bool', - 'type': 'str' - } - - attribute_map = { - 'amount': 'Amount', - 'currency': 'Currency', - 'display_amount': 'DisplayAmount', - 'is_rate_tax_inclusive': 'IsRateTaxInclusive', - 'type': 'Type' - } - - def __init__(self, amount=None, currency=None, display_amount=None, is_rate_tax_inclusive=None, type=None): # noqa: E501 - """OfferShippingCharge - a model defined in Swagger""" # noqa: E501 - - self._amount = None - self._currency = None - self._display_amount = None - self._is_rate_tax_inclusive = None - self._type = None - self.discriminator = None - - if amount is not None: - self.amount = amount - if currency is not None: - self.currency = currency - if display_amount is not None: - self.display_amount = display_amount - if is_rate_tax_inclusive is not None: - self.is_rate_tax_inclusive = is_rate_tax_inclusive - if type is not None: - self.type = type - - @property - def amount(self): - """Gets the amount of this OfferShippingCharge. # noqa: E501 - - - :return: The amount of this OfferShippingCharge. # noqa: E501 - :rtype: float - """ - return self._amount - - @amount.setter - def amount(self, amount): - """Sets the amount of this OfferShippingCharge. - - - :param amount: The amount of this OfferShippingCharge. # noqa: E501 - :type: float - """ - - self._amount = amount - - @property - def currency(self): - """Gets the currency of this OfferShippingCharge. # noqa: E501 - - - :return: The currency of this OfferShippingCharge. # noqa: E501 - :rtype: str - """ - return self._currency - - @currency.setter - def currency(self, currency): - """Sets the currency of this OfferShippingCharge. - - - :param currency: The currency of this OfferShippingCharge. # noqa: E501 - :type: str - """ - - self._currency = currency - - @property - def display_amount(self): - """Gets the display_amount of this OfferShippingCharge. # noqa: E501 - - - :return: The display_amount of this OfferShippingCharge. # noqa: E501 - :rtype: str - """ - return self._display_amount - - @display_amount.setter - def display_amount(self, display_amount): - """Sets the display_amount of this OfferShippingCharge. - - - :param display_amount: The display_amount of this OfferShippingCharge. # noqa: E501 - :type: str - """ - - self._display_amount = display_amount - - @property - def is_rate_tax_inclusive(self): - """Gets the is_rate_tax_inclusive of this OfferShippingCharge. # noqa: E501 - - - :return: The is_rate_tax_inclusive of this OfferShippingCharge. # noqa: E501 - :rtype: bool - """ - return self._is_rate_tax_inclusive - - @is_rate_tax_inclusive.setter - def is_rate_tax_inclusive(self, is_rate_tax_inclusive): - """Sets the is_rate_tax_inclusive of this OfferShippingCharge. - - - :param is_rate_tax_inclusive: The is_rate_tax_inclusive of this OfferShippingCharge. # noqa: E501 - :type: bool - """ - - self._is_rate_tax_inclusive = is_rate_tax_inclusive - - @property - def type(self): - """Gets the type of this OfferShippingCharge. # noqa: E501 - - - :return: The type of this OfferShippingCharge. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this OfferShippingCharge. - - - :param type: The type of this OfferShippingCharge. # noqa: E501 - :type: str - """ - - self._type = 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(OfferShippingCharge, 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, OfferShippingCharge): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_sub_condition.py b/amazon/paapi5_python_sdk/offer_sub_condition.py deleted file mode 100644 index bb5be69..0000000 --- a/amazon/paapi5_python_sdk/offer_sub_condition.py +++ /dev/null @@ -1,204 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class OfferSubCondition(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 = { - 'display_value': 'str', - 'label': 'str', - 'locale': 'str', - 'value': 'str' - } - - attribute_map = { - 'display_value': 'DisplayValue', - 'label': 'Label', - 'locale': 'Locale', - 'value': 'Value' - } - - def __init__(self, display_value=None, label=None, locale=None, value=None): # noqa: E501 - """OfferSubCondition - a model defined in Swagger""" # noqa: E501 - - self._display_value = None - self._label = None - self._locale = None - self._value = None - self.discriminator = None - - if display_value is not None: - self.display_value = display_value - if label is not None: - self.label = label - if locale is not None: - self.locale = locale - if value is not None: - self.value = value - - @property - def display_value(self): - """Gets the display_value of this OfferSubCondition. # noqa: E501 - - - :return: The display_value of this OfferSubCondition. # noqa: E501 - :rtype: str - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this OfferSubCondition. - - - :param display_value: The display_value of this OfferSubCondition. # noqa: E501 - :type: str - """ - - self._display_value = display_value - - @property - def label(self): - """Gets the label of this OfferSubCondition. # noqa: E501 - - - :return: The label of this OfferSubCondition. # noqa: E501 - :rtype: str - """ - return self._label - - @label.setter - def label(self, label): - """Sets the label of this OfferSubCondition. - - - :param label: The label of this OfferSubCondition. # noqa: E501 - :type: str - """ - - self._label = label - - @property - def locale(self): - """Gets the locale of this OfferSubCondition. # noqa: E501 - - - :return: The locale of this OfferSubCondition. # noqa: E501 - :rtype: str - """ - return self._locale - - @locale.setter - def locale(self, locale): - """Sets the locale of this OfferSubCondition. - - - :param locale: The locale of this OfferSubCondition. # noqa: E501 - :type: str - """ - - self._locale = locale - - @property - def value(self): - """Gets the value of this OfferSubCondition. # noqa: E501 - - - :return: The value of this OfferSubCondition. # noqa: E501 - :rtype: str - """ - return self._value - - @value.setter - def value(self, value): - """Sets the value of this OfferSubCondition. - - - :param value: The value of this OfferSubCondition. # noqa: E501 - :type: str - """ - - self._value = value - - 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(OfferSubCondition, 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, OfferSubCondition): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offer_summary.py b/amazon/paapi5_python_sdk/offer_summary.py deleted file mode 100644 index f2363b2..0000000 --- a/amazon/paapi5_python_sdk/offer_summary.py +++ /dev/null @@ -1,207 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .offer_condition import OfferCondition # noqa: F401,E501 -from .offer_price import OfferPrice # noqa: F401,E501 - - -class OfferSummary(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 = { - 'condition': 'OfferCondition', - 'highest_price': 'OfferPrice', - 'lowest_price': 'OfferPrice', - 'offer_count': 'int' - } - - attribute_map = { - 'condition': 'Condition', - 'highest_price': 'HighestPrice', - 'lowest_price': 'LowestPrice', - 'offer_count': 'OfferCount' - } - - def __init__(self, condition=None, highest_price=None, lowest_price=None, offer_count=None): # noqa: E501 - """OfferSummary - a model defined in Swagger""" # noqa: E501 - - self._condition = None - self._highest_price = None - self._lowest_price = None - self._offer_count = None - self.discriminator = None - - if condition is not None: - self.condition = condition - if highest_price is not None: - self.highest_price = highest_price - if lowest_price is not None: - self.lowest_price = lowest_price - if offer_count is not None: - self.offer_count = offer_count - - @property - def condition(self): - """Gets the condition of this OfferSummary. # noqa: E501 - - - :return: The condition of this OfferSummary. # noqa: E501 - :rtype: OfferCondition - """ - return self._condition - - @condition.setter - def condition(self, condition): - """Sets the condition of this OfferSummary. - - - :param condition: The condition of this OfferSummary. # noqa: E501 - :type: OfferCondition - """ - - self._condition = condition - - @property - def highest_price(self): - """Gets the highest_price of this OfferSummary. # noqa: E501 - - - :return: The highest_price of this OfferSummary. # noqa: E501 - :rtype: OfferPrice - """ - return self._highest_price - - @highest_price.setter - def highest_price(self, highest_price): - """Sets the highest_price of this OfferSummary. - - - :param highest_price: The highest_price of this OfferSummary. # noqa: E501 - :type: OfferPrice - """ - - self._highest_price = highest_price - - @property - def lowest_price(self): - """Gets the lowest_price of this OfferSummary. # noqa: E501 - - - :return: The lowest_price of this OfferSummary. # noqa: E501 - :rtype: OfferPrice - """ - return self._lowest_price - - @lowest_price.setter - def lowest_price(self, lowest_price): - """Sets the lowest_price of this OfferSummary. - - - :param lowest_price: The lowest_price of this OfferSummary. # noqa: E501 - :type: OfferPrice - """ - - self._lowest_price = lowest_price - - @property - def offer_count(self): - """Gets the offer_count of this OfferSummary. # noqa: E501 - - - :return: The offer_count of this OfferSummary. # noqa: E501 - :rtype: int - """ - return self._offer_count - - @offer_count.setter - def offer_count(self, offer_count): - """Sets the offer_count of this OfferSummary. - - - :param offer_count: The offer_count of this OfferSummary. # noqa: E501 - :type: int - """ - - self._offer_count = offer_count - - 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(OfferSummary, 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, OfferSummary): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/offers.py b/amazon/paapi5_python_sdk/offers.py deleted file mode 100644 index 4565b7b..0000000 --- a/amazon/paapi5_python_sdk/offers.py +++ /dev/null @@ -1,155 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .offer_listing import OfferListing # noqa: F401,E501 -from .offer_summary import OfferSummary # noqa: F401,E501 - - -class Offers(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 = { - 'listings': 'list[OfferListing]', - 'summaries': 'list[OfferSummary]' - } - - attribute_map = { - 'listings': 'Listings', - 'summaries': 'Summaries' - } - - def __init__(self, listings=None, summaries=None): # noqa: E501 - """Offers - a model defined in Swagger""" # noqa: E501 - - self._listings = None - self._summaries = None - self.discriminator = None - - if listings is not None: - self.listings = listings - if summaries is not None: - self.summaries = summaries - - @property - def listings(self): - """Gets the listings of this Offers. # noqa: E501 - - - :return: The listings of this Offers. # noqa: E501 - :rtype: list[OfferListing] - """ - return self._listings - - @listings.setter - def listings(self, listings): - """Sets the listings of this Offers. - - - :param listings: The listings of this Offers. # noqa: E501 - :type: list[OfferListing] - """ - - self._listings = listings - - @property - def summaries(self): - """Gets the summaries of this Offers. # noqa: E501 - - - :return: The summaries of this Offers. # noqa: E501 - :rtype: list[OfferSummary] - """ - return self._summaries - - @summaries.setter - def summaries(self, summaries): - """Sets the summaries of this Offers. - - - :param summaries: The summaries of this Offers. # noqa: E501 - :type: list[OfferSummary] - """ - - self._summaries = summaries - - 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(Offers, 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, Offers): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/partner_type.py b/amazon/paapi5_python_sdk/partner_type.py deleted file mode 100644 index 37f9a39..0000000 --- a/amazon/paapi5_python_sdk/partner_type.py +++ /dev/null @@ -1,103 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class PartnerType(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - - """ - allowed enum values - """ - ASSOCIATES = "Associates" - - """ - 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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """PartnerType - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(PartnerType, 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, PartnerType): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/price.py b/amazon/paapi5_python_sdk/price.py deleted file mode 100644 index 9fa403c..0000000 --- a/amazon/paapi5_python_sdk/price.py +++ /dev/null @@ -1,154 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .offer_price import OfferPrice # noqa: F401,E501 - - -class Price(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 = { - 'highest_price': 'OfferPrice', - 'lowest_price': 'OfferPrice' - } - - attribute_map = { - 'highest_price': 'HighestPrice', - 'lowest_price': 'LowestPrice' - } - - def __init__(self, highest_price=None, lowest_price=None): # noqa: E501 - """Price - a model defined in Swagger""" # noqa: E501 - - self._highest_price = None - self._lowest_price = None - self.discriminator = None - - if highest_price is not None: - self.highest_price = highest_price - if lowest_price is not None: - self.lowest_price = lowest_price - - @property - def highest_price(self): - """Gets the highest_price of this Price. # noqa: E501 - - - :return: The highest_price of this Price. # noqa: E501 - :rtype: OfferPrice - """ - return self._highest_price - - @highest_price.setter - def highest_price(self, highest_price): - """Sets the highest_price of this Price. - - - :param highest_price: The highest_price of this Price. # noqa: E501 - :type: OfferPrice - """ - - self._highest_price = highest_price - - @property - def lowest_price(self): - """Gets the lowest_price of this Price. # noqa: E501 - - - :return: The lowest_price of this Price. # noqa: E501 - :rtype: OfferPrice - """ - return self._lowest_price - - @lowest_price.setter - def lowest_price(self, lowest_price): - """Sets the lowest_price of this Price. - - - :param lowest_price: The lowest_price of this Price. # noqa: E501 - :type: OfferPrice - """ - - self._lowest_price = lowest_price - - 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(Price, 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, Price): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/product_advertising_api_client_exception.py b/amazon/paapi5_python_sdk/product_advertising_api_client_exception.py deleted file mode 100644 index 2e5cd35..0000000 --- a/amazon/paapi5_python_sdk/product_advertising_api_client_exception.py +++ /dev/null @@ -1,128 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .error_data import ErrorData # noqa: F401,E501 - - -class ProductAdvertisingAPIClientException(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 = { - 'errors': 'list[ErrorData]' - } - - attribute_map = { - 'errors': 'Errors' - } - - def __init__(self, errors=None): # noqa: E501 - """ProductAdvertisingAPIClientException - a model defined in Swagger""" # noqa: E501 - - self._errors = None - self.discriminator = None - - if errors is not None: - self.errors = errors - - @property - def errors(self): - """Gets the errors of this ProductAdvertisingAPIClientException. # noqa: E501 - - - :return: The errors of this ProductAdvertisingAPIClientException. # noqa: E501 - :rtype: list[ErrorData] - """ - return self._errors - - @errors.setter - def errors(self, errors): - """Sets the errors of this ProductAdvertisingAPIClientException. - - - :param errors: The errors of this ProductAdvertisingAPIClientException. # noqa: E501 - :type: list[ErrorData] - """ - - self._errors = errors - - 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(ProductAdvertisingAPIClientException, 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, ProductAdvertisingAPIClientException): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/product_advertising_api_service_exception.py b/amazon/paapi5_python_sdk/product_advertising_api_service_exception.py deleted file mode 100644 index 957d9d4..0000000 --- a/amazon/paapi5_python_sdk/product_advertising_api_service_exception.py +++ /dev/null @@ -1,126 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class ProductAdvertisingAPIServiceException(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 = { - 'message': 'str' - } - - attribute_map = { - 'message': 'message' - } - - def __init__(self, message=None): # noqa: E501 - """ProductAdvertisingAPIServiceException - a model defined in Swagger""" # noqa: E501 - - self._message = None - self.discriminator = None - - if message is not None: - self.message = message - - @property - def message(self): - """Gets the message of this ProductAdvertisingAPIServiceException. # noqa: E501 - - - :return: The message of this ProductAdvertisingAPIServiceException. # noqa: E501 - :rtype: str - """ - return self._message - - @message.setter - def message(self, message): - """Sets the message of this ProductAdvertisingAPIServiceException. - - - :param message: The message of this ProductAdvertisingAPIServiceException. # noqa: E501 - :type: str - """ - - self._message = message - - 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(ProductAdvertisingAPIServiceException, 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, ProductAdvertisingAPIServiceException): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/product_info.py b/amazon/paapi5_python_sdk/product_info.py deleted file mode 100644 index d0558d1..0000000 --- a/amazon/paapi5_python_sdk/product_info.py +++ /dev/null @@ -1,261 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .dimension_based_attribute import DimensionBasedAttribute # noqa: F401,E501 -from .single_boolean_valued_attribute import SingleBooleanValuedAttribute # noqa: F401,E501 -from .single_integer_valued_attribute import SingleIntegerValuedAttribute # noqa: F401,E501 -from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 - - -class ProductInfo(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 = { - 'color': 'SingleStringValuedAttribute', - 'is_adult_product': 'SingleBooleanValuedAttribute', - 'item_dimensions': 'DimensionBasedAttribute', - 'release_date': 'SingleStringValuedAttribute', - 'size': 'SingleStringValuedAttribute', - 'unit_count': 'SingleIntegerValuedAttribute' - } - - attribute_map = { - 'color': 'Color', - 'is_adult_product': 'IsAdultProduct', - 'item_dimensions': 'ItemDimensions', - 'release_date': 'ReleaseDate', - 'size': 'Size', - 'unit_count': 'UnitCount' - } - - def __init__(self, color=None, is_adult_product=None, item_dimensions=None, release_date=None, size=None, unit_count=None): # noqa: E501 - """ProductInfo - a model defined in Swagger""" # noqa: E501 - - self._color = None - self._is_adult_product = None - self._item_dimensions = None - self._release_date = None - self._size = None - self._unit_count = None - self.discriminator = None - - if color is not None: - self.color = color - if is_adult_product is not None: - self.is_adult_product = is_adult_product - if item_dimensions is not None: - self.item_dimensions = item_dimensions - if release_date is not None: - self.release_date = release_date - if size is not None: - self.size = size - if unit_count is not None: - self.unit_count = unit_count - - @property - def color(self): - """Gets the color of this ProductInfo. # noqa: E501 - - - :return: The color of this ProductInfo. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this ProductInfo. - - - :param color: The color of this ProductInfo. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._color = color - - @property - def is_adult_product(self): - """Gets the is_adult_product of this ProductInfo. # noqa: E501 - - - :return: The is_adult_product of this ProductInfo. # noqa: E501 - :rtype: SingleBooleanValuedAttribute - """ - return self._is_adult_product - - @is_adult_product.setter - def is_adult_product(self, is_adult_product): - """Sets the is_adult_product of this ProductInfo. - - - :param is_adult_product: The is_adult_product of this ProductInfo. # noqa: E501 - :type: SingleBooleanValuedAttribute - """ - - self._is_adult_product = is_adult_product - - @property - def item_dimensions(self): - """Gets the item_dimensions of this ProductInfo. # noqa: E501 - - - :return: The item_dimensions of this ProductInfo. # noqa: E501 - :rtype: DimensionBasedAttribute - """ - return self._item_dimensions - - @item_dimensions.setter - def item_dimensions(self, item_dimensions): - """Sets the item_dimensions of this ProductInfo. - - - :param item_dimensions: The item_dimensions of this ProductInfo. # noqa: E501 - :type: DimensionBasedAttribute - """ - - self._item_dimensions = item_dimensions - - @property - def release_date(self): - """Gets the release_date of this ProductInfo. # noqa: E501 - - - :return: The release_date of this ProductInfo. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._release_date - - @release_date.setter - def release_date(self, release_date): - """Sets the release_date of this ProductInfo. - - - :param release_date: The release_date of this ProductInfo. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._release_date = release_date - - @property - def size(self): - """Gets the size of this ProductInfo. # noqa: E501 - - - :return: The size of this ProductInfo. # noqa: E501 - :rtype: SingleStringValuedAttribute - """ - return self._size - - @size.setter - def size(self, size): - """Sets the size of this ProductInfo. - - - :param size: The size of this ProductInfo. # noqa: E501 - :type: SingleStringValuedAttribute - """ - - self._size = size - - @property - def unit_count(self): - """Gets the unit_count of this ProductInfo. # noqa: E501 - - - :return: The unit_count of this ProductInfo. # noqa: E501 - :rtype: SingleIntegerValuedAttribute - """ - return self._unit_count - - @unit_count.setter - def unit_count(self, unit_count): - """Sets the unit_count of this ProductInfo. - - - :param unit_count: The unit_count of this ProductInfo. # noqa: E501 - :type: SingleIntegerValuedAttribute - """ - - self._unit_count = unit_count - - 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(ProductInfo, 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, ProductInfo): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/properties.py b/amazon/paapi5_python_sdk/properties.py deleted file mode 100644 index ea72b0a..0000000 --- a/amazon/paapi5_python_sdk/properties.py +++ /dev/null @@ -1,83 +0,0 @@ -# coding: utf-8 - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class Properties(dict): - """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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """Properties - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(Properties, 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, Properties): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/refinement.py b/amazon/paapi5_python_sdk/refinement.py deleted file mode 100644 index cce4c59..0000000 --- a/amazon/paapi5_python_sdk/refinement.py +++ /dev/null @@ -1,180 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .refinement_bin import RefinementBin # noqa: F401,E501 - - -class Refinement(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 = { - 'bins': 'list[RefinementBin]', - 'display_name': 'str', - 'id': 'str' - } - - attribute_map = { - 'bins': 'Bins', - 'display_name': 'DisplayName', - 'id': 'Id' - } - - def __init__(self, bins=None, display_name=None, id=None): # noqa: E501 - """Refinement - a model defined in Swagger""" # noqa: E501 - - self._bins = None - self._display_name = None - self._id = None - self.discriminator = None - - if bins is not None: - self.bins = bins - if display_name is not None: - self.display_name = display_name - if id is not None: - self.id = id - - @property - def bins(self): - """Gets the bins of this Refinement. # noqa: E501 - - - :return: The bins of this Refinement. # noqa: E501 - :rtype: list[RefinementBin] - """ - return self._bins - - @bins.setter - def bins(self, bins): - """Sets the bins of this Refinement. - - - :param bins: The bins of this Refinement. # noqa: E501 - :type: list[RefinementBin] - """ - - self._bins = bins - - @property - def display_name(self): - """Gets the display_name of this Refinement. # noqa: E501 - - - :return: The display_name of this Refinement. # noqa: E501 - :rtype: str - """ - return self._display_name - - @display_name.setter - def display_name(self, display_name): - """Sets the display_name of this Refinement. - - - :param display_name: The display_name of this Refinement. # noqa: E501 - :type: str - """ - - self._display_name = display_name - - @property - def id(self): - """Gets the id of this Refinement. # noqa: E501 - - - :return: The id of this Refinement. # noqa: E501 - :rtype: str - """ - return self._id - - @id.setter - def id(self, id): - """Sets the id of this Refinement. - - - :param id: The id of this Refinement. # noqa: E501 - :type: str - """ - - self._id = id - - 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(Refinement, 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, Refinement): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/refinement_bin.py b/amazon/paapi5_python_sdk/refinement_bin.py deleted file mode 100644 index 9b44ba6..0000000 --- a/amazon/paapi5_python_sdk/refinement_bin.py +++ /dev/null @@ -1,152 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class RefinementBin(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 = { - 'display_name': 'str', - 'id': 'str' - } - - attribute_map = { - 'display_name': 'DisplayName', - 'id': 'Id' - } - - def __init__(self, display_name=None, id=None): # noqa: E501 - """RefinementBin - a model defined in Swagger""" # noqa: E501 - - self._display_name = None - self._id = None - self.discriminator = None - - if display_name is not None: - self.display_name = display_name - if id is not None: - self.id = id - - @property - def display_name(self): - """Gets the display_name of this RefinementBin. # noqa: E501 - - - :return: The display_name of this RefinementBin. # noqa: E501 - :rtype: str - """ - return self._display_name - - @display_name.setter - def display_name(self, display_name): - """Sets the display_name of this RefinementBin. - - - :param display_name: The display_name of this RefinementBin. # noqa: E501 - :type: str - """ - - self._display_name = display_name - - @property - def id(self): - """Gets the id of this RefinementBin. # noqa: E501 - - - :return: The id of this RefinementBin. # noqa: E501 - :rtype: str - """ - return self._id - - @id.setter - def id(self, id): - """Sets the id of this RefinementBin. - - - :param id: The id of this RefinementBin. # noqa: E501 - :type: str - """ - - self._id = id - - 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(RefinementBin, 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, RefinementBin): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/rental_offer_listing.py b/amazon/paapi5_python_sdk/rental_offer_listing.py deleted file mode 100644 index 95936a6..0000000 --- a/amazon/paapi5_python_sdk/rental_offer_listing.py +++ /dev/null @@ -1,262 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .duration_price import DurationPrice # noqa: F401,E501 -from .offer_availability import OfferAvailability # noqa: F401,E501 -from .offer_condition import OfferCondition # noqa: F401,E501 -from .offer_delivery_info import OfferDeliveryInfo # noqa: F401,E501 -from .offer_merchant_info import OfferMerchantInfo # noqa: F401,E501 - - -class RentalOfferListing(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 = { - 'availability': 'OfferAvailability', - 'base_price': 'DurationPrice', - 'condition': 'OfferCondition', - 'delivery_info': 'OfferDeliveryInfo', - 'id': 'str', - 'merchant_info': 'OfferMerchantInfo' - } - - attribute_map = { - 'availability': 'Availability', - 'base_price': 'BasePrice', - 'condition': 'Condition', - 'delivery_info': 'DeliveryInfo', - 'id': 'Id', - 'merchant_info': 'MerchantInfo' - } - - def __init__(self, availability=None, base_price=None, condition=None, delivery_info=None, id=None, merchant_info=None): # noqa: E501 - """RentalOfferListing - a model defined in Swagger""" # noqa: E501 - - self._availability = None - self._base_price = None - self._condition = None - self._delivery_info = None - self._id = None - self._merchant_info = None - self.discriminator = None - - if availability is not None: - self.availability = availability - if base_price is not None: - self.base_price = base_price - if condition is not None: - self.condition = condition - if delivery_info is not None: - self.delivery_info = delivery_info - if id is not None: - self.id = id - if merchant_info is not None: - self.merchant_info = merchant_info - - @property - def availability(self): - """Gets the availability of this RentalOfferListing. # noqa: E501 - - - :return: The availability of this RentalOfferListing. # noqa: E501 - :rtype: OfferAvailability - """ - return self._availability - - @availability.setter - def availability(self, availability): - """Sets the availability of this RentalOfferListing. - - - :param availability: The availability of this RentalOfferListing. # noqa: E501 - :type: OfferAvailability - """ - - self._availability = availability - - @property - def base_price(self): - """Gets the base_price of this RentalOfferListing. # noqa: E501 - - - :return: The base_price of this RentalOfferListing. # noqa: E501 - :rtype: DurationPrice - """ - return self._base_price - - @base_price.setter - def base_price(self, base_price): - """Sets the base_price of this RentalOfferListing. - - - :param base_price: The base_price of this RentalOfferListing. # noqa: E501 - :type: DurationPrice - """ - - self._base_price = base_price - - @property - def condition(self): - """Gets the condition of this RentalOfferListing. # noqa: E501 - - - :return: The condition of this RentalOfferListing. # noqa: E501 - :rtype: OfferCondition - """ - return self._condition - - @condition.setter - def condition(self, condition): - """Sets the condition of this RentalOfferListing. - - - :param condition: The condition of this RentalOfferListing. # noqa: E501 - :type: OfferCondition - """ - - self._condition = condition - - @property - def delivery_info(self): - """Gets the delivery_info of this RentalOfferListing. # noqa: E501 - - - :return: The delivery_info of this RentalOfferListing. # noqa: E501 - :rtype: OfferDeliveryInfo - """ - return self._delivery_info - - @delivery_info.setter - def delivery_info(self, delivery_info): - """Sets the delivery_info of this RentalOfferListing. - - - :param delivery_info: The delivery_info of this RentalOfferListing. # noqa: E501 - :type: OfferDeliveryInfo - """ - - self._delivery_info = delivery_info - - @property - def id(self): - """Gets the id of this RentalOfferListing. # noqa: E501 - - - :return: The id of this RentalOfferListing. # noqa: E501 - :rtype: str - """ - return self._id - - @id.setter - def id(self, id): - """Sets the id of this RentalOfferListing. - - - :param id: The id of this RentalOfferListing. # noqa: E501 - :type: str - """ - - self._id = id - - @property - def merchant_info(self): - """Gets the merchant_info of this RentalOfferListing. # noqa: E501 - - - :return: The merchant_info of this RentalOfferListing. # noqa: E501 - :rtype: OfferMerchantInfo - """ - return self._merchant_info - - @merchant_info.setter - def merchant_info(self, merchant_info): - """Sets the merchant_info of this RentalOfferListing. - - - :param merchant_info: The merchant_info of this RentalOfferListing. # noqa: E501 - :type: OfferMerchantInfo - """ - - self._merchant_info = merchant_info - - 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(RentalOfferListing, 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, RentalOfferListing): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/rental_offers.py b/amazon/paapi5_python_sdk/rental_offers.py deleted file mode 100644 index 6fb4e09..0000000 --- a/amazon/paapi5_python_sdk/rental_offers.py +++ /dev/null @@ -1,128 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .rental_offer_listing import RentalOfferListing # noqa: F401,E501 - - -class RentalOffers(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 = { - 'listings': 'list[RentalOfferListing]' - } - - attribute_map = { - 'listings': 'Listings' - } - - def __init__(self, listings=None): # noqa: E501 - """RentalOffers - a model defined in Swagger""" # noqa: E501 - - self._listings = None - self.discriminator = None - - if listings is not None: - self.listings = listings - - @property - def listings(self): - """Gets the listings of this RentalOffers. # noqa: E501 - - - :return: The listings of this RentalOffers. # noqa: E501 - :rtype: list[RentalOfferListing] - """ - return self._listings - - @listings.setter - def listings(self, listings): - """Sets the listings of this RentalOffers. - - - :param listings: The listings of this RentalOffers. # noqa: E501 - :type: list[RentalOfferListing] - """ - - self._listings = listings - - 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(RentalOffers, 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, RentalOffers): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/rest.py b/amazon/paapi5_python_sdk/rest.py deleted file mode 100644 index a4e74fa..0000000 --- a/amazon/paapi5_python_sdk/rest.py +++ /dev/null @@ -1,333 +0,0 @@ -# coding: utf-8 - -from __future__ import absolute_import - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - -import io -import json -import logging -import re -import ssl - -import certifi -# python 2 and python 3 compatibility library -import six -from six.moves.urllib.parse import urlencode - -try: - import urllib3 -except ImportError: - raise ImportError('Swagger python client requires urllib3.') - - -logger = logging.getLogger(__name__) - - -class RESTResponse(io.IOBase): - - def __init__(self, resp): - self.urllib3_response = resp - self.status = resp.status - self.reason = resp.reason - self.data = resp.data - - def getheaders(self): - """Returns a dictionary of the response headers.""" - return self.urllib3_response.getheaders() - - def getheader(self, name, default=None): - """Returns a given response header.""" - return self.urllib3_response.getheader(name, default) - - -class RESTClientObject(object): - - def __init__(self, configuration, pools_size=4, maxsize=None): - # urllib3.PoolManager will pass all kw parameters to connectionpool - # https://github.com/shazow/urllib3/blob/f9409436f83aeb79fbaf090181cd81b784f1b8ce/urllib3/poolmanager.py#L75 # noqa: E501 - # https://github.com/shazow/urllib3/blob/f9409436f83aeb79fbaf090181cd81b784f1b8ce/urllib3/connectionpool.py#L680 # noqa: E501 - # maxsize is the number of requests to host that are allowed in parallel # noqa: E501 - # Custom SSL certificates and client certificates: http://urllib3.readthedocs.io/en/latest/advanced-usage.html # noqa: E501 - - # cert_reqs - if configuration.verify_ssl: - cert_reqs = ssl.CERT_REQUIRED - else: - cert_reqs = ssl.CERT_NONE - - # ca_certs - if configuration.ssl_ca_cert: - ca_certs = configuration.ssl_ca_cert - else: - # if not set certificate file, use Mozilla's root certificates. - ca_certs = certifi.where() - - addition_pool_args = {} - if configuration.assert_hostname is not None: - addition_pool_args['assert_hostname'] = configuration.assert_hostname # noqa: E501 - - if maxsize is None: - if configuration.connection_pool_maxsize is not None: - maxsize = configuration.connection_pool_maxsize - else: - maxsize = 4 - - # https pool manager - if configuration.proxy: - self.pool_manager = urllib3.ProxyManager( - num_pools=pools_size, - maxsize=maxsize, - cert_reqs=cert_reqs, - ca_certs=ca_certs, - cert_file=configuration.cert_file, - key_file=configuration.key_file, - proxy_url=configuration.proxy, - **addition_pool_args - ) - else: - self.pool_manager = urllib3.PoolManager( - num_pools=pools_size, - maxsize=maxsize, - cert_reqs=cert_reqs, - ca_certs=ca_certs, - cert_file=configuration.cert_file, - key_file=configuration.key_file, - **addition_pool_args - ) - - def request(self, method, url, query_params=None, headers=None, - body=None, post_params=None, _preload_content=True, - _request_timeout=None): - """Perform requests. - - :param method: http request method - :param url: http request url - :param query_params: query parameters in the url - :param headers: http request headers - :param body: request json body, for `application/json` - :param post_params: request post parameters, - `application/x-www-form-urlencoded` - and `multipart/form-data` - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - """ - method = method.upper() - assert method in ['GET', 'HEAD', 'DELETE', 'POST', 'PUT', - 'PATCH', 'OPTIONS'] - - if post_params and body: - raise ValueError( - "body parameter cannot be used with post_params parameter." - ) - - post_params = post_params or {} - headers = headers or {} - - timeout = None - if _request_timeout: - if isinstance(_request_timeout, (int, ) if six.PY3 else (int, long)): # noqa: E501,F821 - timeout = urllib3.Timeout(total=_request_timeout) - elif (isinstance(_request_timeout, tuple) and - len(_request_timeout) == 2): - timeout = urllib3.Timeout( - connect=_request_timeout[0], read=_request_timeout[1]) - - if 'Content-Type' not in headers: - headers['Content-Type'] = 'application/json' - - try: - # For `POST`, `PUT`, `PATCH`, `OPTIONS`, `DELETE` - if method in ['POST', 'PUT', 'PATCH', 'OPTIONS', 'DELETE']: - if query_params: - url += '?' + urlencode(query_params) - if re.search('json', headers['Content-Type'], re.IGNORECASE): - request_body = None - if body is not None: - request_body = json.dumps(body) - r = self.pool_manager.request( - method, url, - body=request_body, - preload_content=_preload_content, - timeout=timeout, - headers=headers) - elif headers['Content-Type'] == 'application/x-www-form-urlencoded': # noqa: E501 - r = self.pool_manager.request( - method, url, - fields=post_params, - encode_multipart=False, - preload_content=_preload_content, - timeout=timeout, - headers=headers) - elif headers['Content-Type'] == 'multipart/form-data': - # must del headers['Content-Type'], or the correct - # Content-Type which generated by urllib3 will be - # overwritten. - del headers['Content-Type'] - r = self.pool_manager.request( - method, url, - fields=post_params, - encode_multipart=True, - preload_content=_preload_content, - timeout=timeout, - headers=headers) - # Pass a `string` parameter directly in the body to support - # other content types than Json when `body` argument is - # provided in serialized form - elif isinstance(body, str): - request_body = body - r = self.pool_manager.request( - method, url, - body=request_body, - preload_content=_preload_content, - timeout=timeout, - headers=headers) - else: - # Cannot generate the request from given parameters - msg = """Cannot prepare a request message for provided - arguments. Please check that your arguments match - declared content type.""" - raise ApiException(status=0, reason=msg) - # For `GET`, `HEAD` - else: - r = self.pool_manager.request(method, url, - fields=query_params, - preload_content=_preload_content, - timeout=timeout, - headers=headers) - except urllib3.exceptions.SSLError as e: - msg = "{0}\n{1}".format(type(e).__name__, str(e)) - raise ApiException(status=0, reason=msg) - - if _preload_content: - r = RESTResponse(r) - - # In the python 3, the response.data is bytes. - # we need to decode it to string. - if six.PY3: - r.data = r.data.decode('utf8') - - # log response body - logger.debug("response body: %s", r.data) - - if not 200 <= r.status <= 299: - raise ApiException(http_resp=r) - - return r - - def GET(self, url, headers=None, query_params=None, _preload_content=True, - _request_timeout=None): - return self.request("GET", url, - headers=headers, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - query_params=query_params) - - def HEAD(self, url, headers=None, query_params=None, _preload_content=True, - _request_timeout=None): - return self.request("HEAD", url, - headers=headers, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - query_params=query_params) - - def OPTIONS(self, url, headers=None, query_params=None, post_params=None, - body=None, _preload_content=True, _request_timeout=None): - return self.request("OPTIONS", url, - headers=headers, - query_params=query_params, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - - def DELETE(self, url, headers=None, query_params=None, body=None, - _preload_content=True, _request_timeout=None): - return self.request("DELETE", url, - headers=headers, - query_params=query_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - - def POST(self, url, headers=None, query_params=None, post_params=None, - body=None, _preload_content=True, _request_timeout=None): - return self.request("POST", url, - headers=headers, - query_params=query_params, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - - def PUT(self, url, headers=None, query_params=None, post_params=None, - body=None, _preload_content=True, _request_timeout=None): - return self.request("PUT", url, - headers=headers, - query_params=query_params, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - - def PATCH(self, url, headers=None, query_params=None, post_params=None, - body=None, _preload_content=True, _request_timeout=None): - return self.request("PATCH", url, - headers=headers, - query_params=query_params, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - - -class ApiException(Exception): - - def __init__(self, status=None, reason=None, http_resp=None): - if http_resp: - self.status = http_resp.status - self.reason = http_resp.reason - self.body = http_resp.data - self.headers = http_resp.getheaders() - else: - self.status = status - self.reason = reason - self.body = None - self.headers = None - - def __str__(self): - """Custom error messages for exception""" - error_message = "({0})\n"\ - "Reason: {1}\n".format(self.status, self.reason) - if self.headers: - error_message += "HTTP response headers: {0}\n".format( - self.headers) - - if self.body: - error_message += "HTTP response body: {0}\n".format(self.body) - - return error_message diff --git a/amazon/paapi5_python_sdk/search_items_request.py b/amazon/paapi5_python_sdk/search_items_request.py deleted file mode 100644 index 4d1107a..0000000 --- a/amazon/paapi5_python_sdk/search_items_request.py +++ /dev/null @@ -1,818 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .availability import Availability # noqa: F401,E501 -from .condition import Condition # noqa: F401,E501 -from .delivery_flag import DeliveryFlag # noqa: F401,E501 -from .max_price import MaxPrice # noqa: F401,E501 -from .merchant import Merchant # noqa: F401,E501 -from .min_price import MinPrice # noqa: F401,E501 -from .min_reviews_rating import MinReviewsRating # noqa: F401,E501 -from .min_saving_percent import MinSavingPercent # noqa: F401,E501 -from .offer_count import OfferCount # noqa: F401,E501 -from .partner_type import PartnerType # noqa: F401,E501 -from .properties import Properties # noqa: F401,E501 -from .search_items_resource import SearchItemsResource # noqa: F401,E501 -from .sort_by import SortBy # noqa: F401,E501 - - -class SearchItemsRequest(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 = { - 'actor': 'str', - 'artist': 'str', - 'author': 'str', - 'availability': 'Availability', - 'brand': 'str', - 'browse_node_id': 'str', - 'condition': 'Condition', - 'currency_of_preference': 'str', - 'delivery_flags': 'list[DeliveryFlag]', - 'item_count': 'int', - 'item_page': 'int', - 'keywords': 'str', - 'languages_of_preference': 'list[str]', - 'marketplace': 'str', - 'max_price': 'MaxPrice', - 'merchant': 'Merchant', - 'min_price': 'MinPrice', - 'min_reviews_rating': 'MinReviewsRating', - 'min_saving_percent': 'MinSavingPercent', - 'offer_count': 'OfferCount', - 'partner_tag': 'str', - 'partner_type': 'PartnerType', - 'properties': 'Properties', - 'resources': 'list[SearchItemsResource]', - 'search_index': 'str', - 'sort_by': 'SortBy', - 'title': 'str' - } - - attribute_map = { - 'actor': 'Actor', - 'artist': 'Artist', - 'author': 'Author', - 'availability': 'Availability', - 'brand': 'Brand', - 'browse_node_id': 'BrowseNodeId', - 'condition': 'Condition', - 'currency_of_preference': 'CurrencyOfPreference', - 'delivery_flags': 'DeliveryFlags', - 'item_count': 'ItemCount', - 'item_page': 'ItemPage', - 'keywords': 'Keywords', - 'languages_of_preference': 'LanguagesOfPreference', - 'marketplace': 'Marketplace', - 'max_price': 'MaxPrice', - 'merchant': 'Merchant', - 'min_price': 'MinPrice', - 'min_reviews_rating': 'MinReviewsRating', - 'min_saving_percent': 'MinSavingPercent', - 'offer_count': 'OfferCount', - 'partner_tag': 'PartnerTag', - 'partner_type': 'PartnerType', - 'properties': 'Properties', - 'resources': 'Resources', - 'search_index': 'SearchIndex', - 'sort_by': 'SortBy', - 'title': 'Title' - } - - def __init__(self, actor=None, artist=None, author=None, availability=None, brand=None, browse_node_id=None, condition=None, currency_of_preference=None, delivery_flags=None, item_count=None, item_page=None, keywords=None, languages_of_preference=None, marketplace=None, max_price=None, merchant=None, min_price=None, min_reviews_rating=None, min_saving_percent=None, offer_count=None, partner_tag=None, partner_type=None, properties=None, resources=None, search_index=None, sort_by=None, title=None): # noqa: E501 - """SearchItemsRequest - a model defined in Swagger""" # noqa: E501 - - self._actor = None - self._artist = None - self._author = None - self._availability = None - self._brand = None - self._browse_node_id = None - self._condition = None - self._currency_of_preference = None - self._delivery_flags = None - self._item_count = None - self._item_page = None - self._keywords = None - self._languages_of_preference = None - self._marketplace = None - self._max_price = None - self._merchant = None - self._min_price = None - self._min_reviews_rating = None - self._min_saving_percent = None - self._offer_count = None - self._partner_tag = None - self._partner_type = None - self._properties = None - self._resources = None - self._search_index = None - self._sort_by = None - self._title = None - self.discriminator = None - - if actor is not None: - self.actor = actor - if artist is not None: - self.artist = artist - if author is not None: - self.author = author - if availability is not None: - self.availability = availability - if brand is not None: - self.brand = brand - if browse_node_id is not None: - self.browse_node_id = browse_node_id - if condition is not None: - self.condition = condition - if currency_of_preference is not None: - self.currency_of_preference = currency_of_preference - if delivery_flags is not None: - self.delivery_flags = delivery_flags - if item_count is not None: - self.item_count = item_count - if item_page is not None: - self.item_page = item_page - if keywords is not None: - self.keywords = keywords - if languages_of_preference is not None: - self.languages_of_preference = languages_of_preference - if marketplace is not None: - self.marketplace = marketplace - if max_price is not None: - self.max_price = max_price - if merchant is not None: - self.merchant = merchant - if min_price is not None: - self.min_price = min_price - if min_reviews_rating is not None: - self.min_reviews_rating = min_reviews_rating - if min_saving_percent is not None: - self.min_saving_percent = min_saving_percent - if offer_count is not None: - self.offer_count = offer_count - self.partner_tag = partner_tag - self.partner_type = partner_type - if properties is not None: - self.properties = properties - if resources is not None: - self.resources = resources - if search_index is not None: - self.search_index = search_index - if sort_by is not None: - self.sort_by = sort_by - if title is not None: - self.title = title - - @property - def actor(self): - """Gets the actor of this SearchItemsRequest. # noqa: E501 - - - :return: The actor of this SearchItemsRequest. # noqa: E501 - :rtype: str - """ - return self._actor - - @actor.setter - def actor(self, actor): - """Sets the actor of this SearchItemsRequest. - - - :param actor: The actor of this SearchItemsRequest. # noqa: E501 - :type: str - """ - - self._actor = actor - - @property - def artist(self): - """Gets the artist of this SearchItemsRequest. # noqa: E501 - - - :return: The artist of this SearchItemsRequest. # noqa: E501 - :rtype: str - """ - return self._artist - - @artist.setter - def artist(self, artist): - """Sets the artist of this SearchItemsRequest. - - - :param artist: The artist of this SearchItemsRequest. # noqa: E501 - :type: str - """ - - self._artist = artist - - @property - def author(self): - """Gets the author of this SearchItemsRequest. # noqa: E501 - - - :return: The author of this SearchItemsRequest. # noqa: E501 - :rtype: str - """ - return self._author - - @author.setter - def author(self, author): - """Sets the author of this SearchItemsRequest. - - - :param author: The author of this SearchItemsRequest. # noqa: E501 - :type: str - """ - - self._author = author - - @property - def availability(self): - """Gets the availability of this SearchItemsRequest. # noqa: E501 - - - :return: The availability of this SearchItemsRequest. # noqa: E501 - :rtype: Availability - """ - return self._availability - - @availability.setter - def availability(self, availability): - """Sets the availability of this SearchItemsRequest. - - - :param availability: The availability of this SearchItemsRequest. # noqa: E501 - :type: Availability - """ - - self._availability = availability - - @property - def brand(self): - """Gets the brand of this SearchItemsRequest. # noqa: E501 - - - :return: The brand of this SearchItemsRequest. # noqa: E501 - :rtype: str - """ - return self._brand - - @brand.setter - def brand(self, brand): - """Sets the brand of this SearchItemsRequest. - - - :param brand: The brand of this SearchItemsRequest. # noqa: E501 - :type: str - """ - - self._brand = brand - - @property - def browse_node_id(self): - """Gets the browse_node_id of this SearchItemsRequest. # noqa: E501 - - - :return: The browse_node_id of this SearchItemsRequest. # noqa: E501 - :rtype: str - """ - return self._browse_node_id - - @browse_node_id.setter - def browse_node_id(self, browse_node_id): - """Sets the browse_node_id of this SearchItemsRequest. - - - :param browse_node_id: The browse_node_id of this SearchItemsRequest. # noqa: E501 - :type: str - """ - - self._browse_node_id = browse_node_id - - @property - def condition(self): - """Gets the condition of this SearchItemsRequest. # noqa: E501 - - - :return: The condition of this SearchItemsRequest. # noqa: E501 - :rtype: Condition - """ - return self._condition - - @condition.setter - def condition(self, condition): - """Sets the condition of this SearchItemsRequest. - - - :param condition: The condition of this SearchItemsRequest. # noqa: E501 - :type: Condition - """ - - self._condition = condition - - @property - def currency_of_preference(self): - """Gets the currency_of_preference of this SearchItemsRequest. # noqa: E501 - - - :return: The currency_of_preference of this SearchItemsRequest. # noqa: E501 - :rtype: str - """ - return self._currency_of_preference - - @currency_of_preference.setter - def currency_of_preference(self, currency_of_preference): - """Sets the currency_of_preference of this SearchItemsRequest. - - - :param currency_of_preference: The currency_of_preference of this SearchItemsRequest. # noqa: E501 - :type: str - """ - - self._currency_of_preference = currency_of_preference - - @property - def delivery_flags(self): - """Gets the delivery_flags of this SearchItemsRequest. # noqa: E501 - - - :return: The delivery_flags of this SearchItemsRequest. # noqa: E501 - :rtype: list[DeliveryFlag] - """ - return self._delivery_flags - - @delivery_flags.setter - def delivery_flags(self, delivery_flags): - """Sets the delivery_flags of this SearchItemsRequest. - - - :param delivery_flags: The delivery_flags of this SearchItemsRequest. # noqa: E501 - :type: list[DeliveryFlag] - """ - - self._delivery_flags = delivery_flags - - @property - def item_count(self): - """Gets the item_count of this SearchItemsRequest. # noqa: E501 - - - :return: The item_count of this SearchItemsRequest. # noqa: E501 - :rtype: int - """ - return self._item_count - - @item_count.setter - def item_count(self, item_count): - """Sets the item_count of this SearchItemsRequest. - - - :param item_count: The item_count of this SearchItemsRequest. # noqa: E501 - :type: int - """ - - self._item_count = item_count - - @property - def item_page(self): - """Gets the item_page of this SearchItemsRequest. # noqa: E501 - - - :return: The item_page of this SearchItemsRequest. # noqa: E501 - :rtype: int - """ - return self._item_page - - @item_page.setter - def item_page(self, item_page): - """Sets the item_page of this SearchItemsRequest. - - - :param item_page: The item_page of this SearchItemsRequest. # noqa: E501 - :type: int - """ - - self._item_page = item_page - - @property - def keywords(self): - """Gets the keywords of this SearchItemsRequest. # noqa: E501 - - - :return: The keywords of this SearchItemsRequest. # noqa: E501 - :rtype: str - """ - return self._keywords - - @keywords.setter - def keywords(self, keywords): - """Sets the keywords of this SearchItemsRequest. - - - :param keywords: The keywords of this SearchItemsRequest. # noqa: E501 - :type: str - """ - - self._keywords = keywords - - @property - def languages_of_preference(self): - """Gets the languages_of_preference of this SearchItemsRequest. # noqa: E501 - - - :return: The languages_of_preference of this SearchItemsRequest. # noqa: E501 - :rtype: list[str] - """ - return self._languages_of_preference - - @languages_of_preference.setter - def languages_of_preference(self, languages_of_preference): - """Sets the languages_of_preference of this SearchItemsRequest. - - - :param languages_of_preference: The languages_of_preference of this SearchItemsRequest. # noqa: E501 - :type: list[str] - """ - - self._languages_of_preference = languages_of_preference - - @property - def marketplace(self): - """Gets the marketplace of this SearchItemsRequest. # noqa: E501 - - - :return: The marketplace of this SearchItemsRequest. # noqa: E501 - :rtype: str - """ - return self._marketplace - - @marketplace.setter - def marketplace(self, marketplace): - """Sets the marketplace of this SearchItemsRequest. - - - :param marketplace: The marketplace of this SearchItemsRequest. # noqa: E501 - :type: str - """ - - self._marketplace = marketplace - - @property - def max_price(self): - """Gets the max_price of this SearchItemsRequest. # noqa: E501 - - - :return: The max_price of this SearchItemsRequest. # noqa: E501 - :rtype: MaxPrice - """ - return self._max_price - - @max_price.setter - def max_price(self, max_price): - """Sets the max_price of this SearchItemsRequest. - - - :param max_price: The max_price of this SearchItemsRequest. # noqa: E501 - :type: MaxPrice - """ - - self._max_price = max_price - - @property - def merchant(self): - """Gets the merchant of this SearchItemsRequest. # noqa: E501 - - - :return: The merchant of this SearchItemsRequest. # noqa: E501 - :rtype: Merchant - """ - return self._merchant - - @merchant.setter - def merchant(self, merchant): - """Sets the merchant of this SearchItemsRequest. - - - :param merchant: The merchant of this SearchItemsRequest. # noqa: E501 - :type: Merchant - """ - - self._merchant = merchant - - @property - def min_price(self): - """Gets the min_price of this SearchItemsRequest. # noqa: E501 - - - :return: The min_price of this SearchItemsRequest. # noqa: E501 - :rtype: MinPrice - """ - return self._min_price - - @min_price.setter - def min_price(self, min_price): - """Sets the min_price of this SearchItemsRequest. - - - :param min_price: The min_price of this SearchItemsRequest. # noqa: E501 - :type: MinPrice - """ - - self._min_price = min_price - - @property - def min_reviews_rating(self): - """Gets the min_reviews_rating of this SearchItemsRequest. # noqa: E501 - - - :return: The min_reviews_rating of this SearchItemsRequest. # noqa: E501 - :rtype: MinReviewsRating - """ - return self._min_reviews_rating - - @min_reviews_rating.setter - def min_reviews_rating(self, min_reviews_rating): - """Sets the min_reviews_rating of this SearchItemsRequest. - - - :param min_reviews_rating: The min_reviews_rating of this SearchItemsRequest. # noqa: E501 - :type: MinReviewsRating - """ - - self._min_reviews_rating = min_reviews_rating - - @property - def min_saving_percent(self): - """Gets the min_saving_percent of this SearchItemsRequest. # noqa: E501 - - - :return: The min_saving_percent of this SearchItemsRequest. # noqa: E501 - :rtype: MinSavingPercent - """ - return self._min_saving_percent - - @min_saving_percent.setter - def min_saving_percent(self, min_saving_percent): - """Sets the min_saving_percent of this SearchItemsRequest. - - - :param min_saving_percent: The min_saving_percent of this SearchItemsRequest. # noqa: E501 - :type: MinSavingPercent - """ - - self._min_saving_percent = min_saving_percent - - @property - def offer_count(self): - """Gets the offer_count of this SearchItemsRequest. # noqa: E501 - - - :return: The offer_count of this SearchItemsRequest. # noqa: E501 - :rtype: OfferCount - """ - return self._offer_count - - @offer_count.setter - def offer_count(self, offer_count): - """Sets the offer_count of this SearchItemsRequest. - - - :param offer_count: The offer_count of this SearchItemsRequest. # noqa: E501 - :type: OfferCount - """ - - self._offer_count = offer_count - - @property - def partner_tag(self): - """Gets the partner_tag of this SearchItemsRequest. # noqa: E501 - - - :return: The partner_tag of this SearchItemsRequest. # noqa: E501 - :rtype: str - """ - return self._partner_tag - - @partner_tag.setter - def partner_tag(self, partner_tag): - """Sets the partner_tag of this SearchItemsRequest. - - - :param partner_tag: The partner_tag of this SearchItemsRequest. # noqa: E501 - :type: str - """ - if partner_tag is None: - raise ValueError("Invalid value for `partner_tag`, must not be `None`") # noqa: E501 - - self._partner_tag = partner_tag - - @property - def partner_type(self): - """Gets the partner_type of this SearchItemsRequest. # noqa: E501 - - - :return: The partner_type of this SearchItemsRequest. # noqa: E501 - :rtype: PartnerType - """ - return self._partner_type - - @partner_type.setter - def partner_type(self, partner_type): - """Sets the partner_type of this SearchItemsRequest. - - - :param partner_type: The partner_type of this SearchItemsRequest. # noqa: E501 - :type: PartnerType - """ - if partner_type is None: - raise ValueError("Invalid value for `partner_type`, must not be `None`") # noqa: E501 - - self._partner_type = partner_type - - @property - def properties(self): - """Gets the properties of this SearchItemsRequest. # noqa: E501 - - - :return: The properties of this SearchItemsRequest. # noqa: E501 - :rtype: Properties - """ - return self._properties - - @properties.setter - def properties(self, properties): - """Sets the properties of this SearchItemsRequest. - - - :param properties: The properties of this SearchItemsRequest. # noqa: E501 - :type: Properties - """ - - self._properties = properties - - @property - def resources(self): - """Gets the resources of this SearchItemsRequest. # noqa: E501 - - - :return: The resources of this SearchItemsRequest. # noqa: E501 - :rtype: list[SearchItemsResource] - """ - return self._resources - - @resources.setter - def resources(self, resources): - """Sets the resources of this SearchItemsRequest. - - - :param resources: The resources of this SearchItemsRequest. # noqa: E501 - :type: list[SearchItemsResource] - """ - - self._resources = resources - - @property - def search_index(self): - """Gets the search_index of this SearchItemsRequest. # noqa: E501 - - - :return: The search_index of this SearchItemsRequest. # noqa: E501 - :rtype: str - """ - return self._search_index - - @search_index.setter - def search_index(self, search_index): - """Sets the search_index of this SearchItemsRequest. - - - :param search_index: The search_index of this SearchItemsRequest. # noqa: E501 - :type: str - """ - - self._search_index = search_index - - @property - def sort_by(self): - """Gets the sort_by of this SearchItemsRequest. # noqa: E501 - - - :return: The sort_by of this SearchItemsRequest. # noqa: E501 - :rtype: SortBy - """ - return self._sort_by - - @sort_by.setter - def sort_by(self, sort_by): - """Sets the sort_by of this SearchItemsRequest. - - - :param sort_by: The sort_by of this SearchItemsRequest. # noqa: E501 - :type: SortBy - """ - - self._sort_by = sort_by - - @property - def title(self): - """Gets the title of this SearchItemsRequest. # noqa: E501 - - - :return: The title of this SearchItemsRequest. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this SearchItemsRequest. - - - :param title: The title of this SearchItemsRequest. # noqa: E501 - :type: str - """ - - self._title = title - - 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(SearchItemsRequest, 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, SearchItemsRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/search_items_resource.py b/amazon/paapi5_python_sdk/search_items_resource.py deleted file mode 100644 index a55a559..0000000 --- a/amazon/paapi5_python_sdk/search_items_resource.py +++ /dev/null @@ -1,158 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class SearchItemsResource(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - - """ - allowed enum values - """ - BROWSENODEINFO_BROWSENODES = "BrowseNodeInfo.BrowseNodes" - BROWSENODEINFO_BROWSENODES_ANCESTOR = "BrowseNodeInfo.BrowseNodes.Ancestor" - BROWSENODEINFO_BROWSENODES_SALESRANK = "BrowseNodeInfo.BrowseNodes.SalesRank" - BROWSENODEINFO_WEBSITESALESRANK = "BrowseNodeInfo.WebsiteSalesRank" - IMAGES_PRIMARY_SMALL = "Images.Primary.Small" - IMAGES_PRIMARY_MEDIUM = "Images.Primary.Medium" - IMAGES_PRIMARY_LARGE = "Images.Primary.Large" - IMAGES_VARIANTS_SMALL = "Images.Variants.Small" - IMAGES_VARIANTS_MEDIUM = "Images.Variants.Medium" - IMAGES_VARIANTS_LARGE = "Images.Variants.Large" - ITEMINFO_BYLINEINFO = "ItemInfo.ByLineInfo" - ITEMINFO_CONTENTINFO = "ItemInfo.ContentInfo" - ITEMINFO_CONTENTRATING = "ItemInfo.ContentRating" - ITEMINFO_CLASSIFICATIONS = "ItemInfo.Classifications" - ITEMINFO_EXTERNALIDS = "ItemInfo.ExternalIds" - ITEMINFO_FEATURES = "ItemInfo.Features" - ITEMINFO_MANUFACTUREINFO = "ItemInfo.ManufactureInfo" - ITEMINFO_PRODUCTINFO = "ItemInfo.ProductInfo" - ITEMINFO_TECHNICALINFO = "ItemInfo.TechnicalInfo" - ITEMINFO_TITLE = "ItemInfo.Title" - ITEMINFO_TRADEININFO = "ItemInfo.TradeInInfo" - OFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY = "Offers.Listings.Availability.MaxOrderQuantity" - OFFERS_LISTINGS_AVAILABILITY_MESSAGE = "Offers.Listings.Availability.Message" - OFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY = "Offers.Listings.Availability.MinOrderQuantity" - OFFERS_LISTINGS_AVAILABILITY_TYPE = "Offers.Listings.Availability.Type" - OFFERS_LISTINGS_CONDITION = "Offers.Listings.Condition" - OFFERS_LISTINGS_CONDITION_SUBCONDITION = "Offers.Listings.Condition.SubCondition" - OFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED = "Offers.Listings.DeliveryInfo.IsAmazonFulfilled" - OFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE = "Offers.Listings.DeliveryInfo.IsFreeShippingEligible" - OFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE = "Offers.Listings.DeliveryInfo.IsPrimeEligible" - OFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES = "Offers.Listings.DeliveryInfo.ShippingCharges" - OFFERS_LISTINGS_ISBUYBOXWINNER = "Offers.Listings.IsBuyBoxWinner" - OFFERS_LISTINGS_LOYALTYPOINTS_POINTS = "Offers.Listings.LoyaltyPoints.Points" - OFFERS_LISTINGS_MERCHANTINFO = "Offers.Listings.MerchantInfo" - OFFERS_LISTINGS_PRICE = "Offers.Listings.Price" - OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEEXCLUSIVE = "Offers.Listings.ProgramEligibility.IsPrimeExclusive" - OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEPANTRY = "Offers.Listings.ProgramEligibility.IsPrimePantry" - OFFERS_LISTINGS_PROMOTIONS = "Offers.Listings.Promotions" - OFFERS_LISTINGS_SAVINGBASIS = "Offers.Listings.SavingBasis" - OFFERS_SUMMARIES_HIGHESTPRICE = "Offers.Summaries.HighestPrice" - OFFERS_SUMMARIES_LOWESTPRICE = "Offers.Summaries.LowestPrice" - OFFERS_SUMMARIES_OFFERCOUNT = "Offers.Summaries.OfferCount" - PARENTASIN = "ParentASIN" - RENTALOFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY = "RentalOffers.Listings.Availability.MaxOrderQuantity" - RENTALOFFERS_LISTINGS_AVAILABILITY_MESSAGE = "RentalOffers.Listings.Availability.Message" - RENTALOFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY = "RentalOffers.Listings.Availability.MinOrderQuantity" - RENTALOFFERS_LISTINGS_AVAILABILITY_TYPE = "RentalOffers.Listings.Availability.Type" - RENTALOFFERS_LISTINGS_BASEPRICE = "RentalOffers.Listings.BasePrice" - RENTALOFFERS_LISTINGS_CONDITION = "RentalOffers.Listings.Condition" - RENTALOFFERS_LISTINGS_CONDITION_SUBCONDITION = "RentalOffers.Listings.Condition.SubCondition" - RENTALOFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED = "RentalOffers.Listings.DeliveryInfo.IsAmazonFulfilled" - RENTALOFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE = "RentalOffers.Listings.DeliveryInfo.IsFreeShippingEligible" - RENTALOFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE = "RentalOffers.Listings.DeliveryInfo.IsPrimeEligible" - RENTALOFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES = "RentalOffers.Listings.DeliveryInfo.ShippingCharges" - RENTALOFFERS_LISTINGS_MERCHANTINFO = "RentalOffers.Listings.MerchantInfo" - SEARCHREFINEMENTS = "SearchRefinements" - - """ - 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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """SearchItemsResource - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(SearchItemsResource, 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, SearchItemsResource): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/search_items_response.py b/amazon/paapi5_python_sdk/search_items_response.py deleted file mode 100644 index 8c66fc7..0000000 --- a/amazon/paapi5_python_sdk/search_items_response.py +++ /dev/null @@ -1,155 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .error_data import ErrorData # noqa: F401,E501 -from .search_result import SearchResult # noqa: F401,E501 - - -class SearchItemsResponse(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 = { - 'search_result': 'SearchResult', - 'errors': 'list[ErrorData]' - } - - attribute_map = { - 'search_result': 'SearchResult', - 'errors': 'Errors' - } - - def __init__(self, search_result=None, errors=None): # noqa: E501 - """SearchItemsResponse - a model defined in Swagger""" # noqa: E501 - - self._search_result = None - self._errors = None - self.discriminator = None - - if search_result is not None: - self.search_result = search_result - if errors is not None: - self.errors = errors - - @property - def search_result(self): - """Gets the search_result of this SearchItemsResponse. # noqa: E501 - - - :return: The search_result of this SearchItemsResponse. # noqa: E501 - :rtype: SearchResult - """ - return self._search_result - - @search_result.setter - def search_result(self, search_result): - """Sets the search_result of this SearchItemsResponse. - - - :param search_result: The search_result of this SearchItemsResponse. # noqa: E501 - :type: SearchResult - """ - - self._search_result = search_result - - @property - def errors(self): - """Gets the errors of this SearchItemsResponse. # noqa: E501 - - - :return: The errors of this SearchItemsResponse. # noqa: E501 - :rtype: list[ErrorData] - """ - return self._errors - - @errors.setter - def errors(self, errors): - """Sets the errors of this SearchItemsResponse. - - - :param errors: The errors of this SearchItemsResponse. # noqa: E501 - :type: list[ErrorData] - """ - - self._errors = errors - - 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(SearchItemsResponse, 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, SearchItemsResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/search_refinements.py b/amazon/paapi5_python_sdk/search_refinements.py deleted file mode 100644 index 2741661..0000000 --- a/amazon/paapi5_python_sdk/search_refinements.py +++ /dev/null @@ -1,180 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .refinement import Refinement # noqa: F401,E501 - - -class SearchRefinements(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 = { - 'browse_node': 'Refinement', - 'other_refinements': 'list[Refinement]', - 'search_index': 'Refinement' - } - - attribute_map = { - 'browse_node': 'BrowseNode', - 'other_refinements': 'OtherRefinements', - 'search_index': 'SearchIndex' - } - - def __init__(self, browse_node=None, other_refinements=None, search_index=None): # noqa: E501 - """SearchRefinements - a model defined in Swagger""" # noqa: E501 - - self._browse_node = None - self._other_refinements = None - self._search_index = None - self.discriminator = None - - if browse_node is not None: - self.browse_node = browse_node - if other_refinements is not None: - self.other_refinements = other_refinements - if search_index is not None: - self.search_index = search_index - - @property - def browse_node(self): - """Gets the browse_node of this SearchRefinements. # noqa: E501 - - - :return: The browse_node of this SearchRefinements. # noqa: E501 - :rtype: Refinement - """ - return self._browse_node - - @browse_node.setter - def browse_node(self, browse_node): - """Sets the browse_node of this SearchRefinements. - - - :param browse_node: The browse_node of this SearchRefinements. # noqa: E501 - :type: Refinement - """ - - self._browse_node = browse_node - - @property - def other_refinements(self): - """Gets the other_refinements of this SearchRefinements. # noqa: E501 - - - :return: The other_refinements of this SearchRefinements. # noqa: E501 - :rtype: list[Refinement] - """ - return self._other_refinements - - @other_refinements.setter - def other_refinements(self, other_refinements): - """Sets the other_refinements of this SearchRefinements. - - - :param other_refinements: The other_refinements of this SearchRefinements. # noqa: E501 - :type: list[Refinement] - """ - - self._other_refinements = other_refinements - - @property - def search_index(self): - """Gets the search_index of this SearchRefinements. # noqa: E501 - - - :return: The search_index of this SearchRefinements. # noqa: E501 - :rtype: Refinement - """ - return self._search_index - - @search_index.setter - def search_index(self, search_index): - """Sets the search_index of this SearchRefinements. - - - :param search_index: The search_index of this SearchRefinements. # noqa: E501 - :type: Refinement - """ - - self._search_index = search_index - - 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(SearchRefinements, 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, SearchRefinements): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/search_result.py b/amazon/paapi5_python_sdk/search_result.py deleted file mode 100644 index 6ba2d5e..0000000 --- a/amazon/paapi5_python_sdk/search_result.py +++ /dev/null @@ -1,207 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .item import Item # noqa: F401,E501 -from .search_refinements import SearchRefinements # noqa: F401,E501 - - -class SearchResult(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 = { - 'total_result_count': 'int', - 'search_url': 'str', - 'items': 'list[Item]', - 'search_refinements': 'SearchRefinements' - } - - attribute_map = { - 'total_result_count': 'TotalResultCount', - 'search_url': 'SearchURL', - 'items': 'Items', - 'search_refinements': 'SearchRefinements' - } - - def __init__(self, total_result_count=None, search_url=None, items=None, search_refinements=None): # noqa: E501 - """SearchResult - a model defined in Swagger""" # noqa: E501 - - self._total_result_count = None - self._search_url = None - self._items = None - self._search_refinements = None - self.discriminator = None - - if total_result_count is not None: - self.total_result_count = total_result_count - if search_url is not None: - self.search_url = search_url - if items is not None: - self.items = items - if search_refinements is not None: - self.search_refinements = search_refinements - - @property - def total_result_count(self): - """Gets the total_result_count of this SearchResult. # noqa: E501 - - - :return: The total_result_count of this SearchResult. # noqa: E501 - :rtype: int - """ - return self._total_result_count - - @total_result_count.setter - def total_result_count(self, total_result_count): - """Sets the total_result_count of this SearchResult. - - - :param total_result_count: The total_result_count of this SearchResult. # noqa: E501 - :type: int - """ - - self._total_result_count = total_result_count - - @property - def search_url(self): - """Gets the search_url of this SearchResult. # noqa: E501 - - - :return: The search_url of this SearchResult. # noqa: E501 - :rtype: str - """ - return self._search_url - - @search_url.setter - def search_url(self, search_url): - """Sets the search_url of this SearchResult. - - - :param search_url: The search_url of this SearchResult. # noqa: E501 - :type: str - """ - - self._search_url = search_url - - @property - def items(self): - """Gets the items of this SearchResult. # noqa: E501 - - - :return: The items of this SearchResult. # noqa: E501 - :rtype: list[Item] - """ - return self._items - - @items.setter - def items(self, items): - """Sets the items of this SearchResult. - - - :param items: The items of this SearchResult. # noqa: E501 - :type: list[Item] - """ - - self._items = items - - @property - def search_refinements(self): - """Gets the search_refinements of this SearchResult. # noqa: E501 - - - :return: The search_refinements of this SearchResult. # noqa: E501 - :rtype: SearchRefinements - """ - return self._search_refinements - - @search_refinements.setter - def search_refinements(self, search_refinements): - """Sets the search_refinements of this SearchResult. - - - :param search_refinements: The search_refinements of this SearchResult. # noqa: E501 - :type: SearchRefinements - """ - - self._search_refinements = search_refinements - - 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(SearchResult, 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, SearchResult): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/single_boolean_valued_attribute.py b/amazon/paapi5_python_sdk/single_boolean_valued_attribute.py deleted file mode 100644 index df043f6..0000000 --- a/amazon/paapi5_python_sdk/single_boolean_valued_attribute.py +++ /dev/null @@ -1,178 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class SingleBooleanValuedAttribute(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 = { - 'display_value': 'bool', - 'label': 'str', - 'locale': 'str' - } - - attribute_map = { - 'display_value': 'DisplayValue', - 'label': 'Label', - 'locale': 'Locale' - } - - def __init__(self, display_value=None, label=None, locale=None): # noqa: E501 - """SingleBooleanValuedAttribute - a model defined in Swagger""" # noqa: E501 - - self._display_value = None - self._label = None - self._locale = None - self.discriminator = None - - if display_value is not None: - self.display_value = display_value - if label is not None: - self.label = label - if locale is not None: - self.locale = locale - - @property - def display_value(self): - """Gets the display_value of this SingleBooleanValuedAttribute. # noqa: E501 - - - :return: The display_value of this SingleBooleanValuedAttribute. # noqa: E501 - :rtype: bool - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this SingleBooleanValuedAttribute. - - - :param display_value: The display_value of this SingleBooleanValuedAttribute. # noqa: E501 - :type: bool - """ - - self._display_value = display_value - - @property - def label(self): - """Gets the label of this SingleBooleanValuedAttribute. # noqa: E501 - - - :return: The label of this SingleBooleanValuedAttribute. # noqa: E501 - :rtype: str - """ - return self._label - - @label.setter - def label(self, label): - """Sets the label of this SingleBooleanValuedAttribute. - - - :param label: The label of this SingleBooleanValuedAttribute. # noqa: E501 - :type: str - """ - - self._label = label - - @property - def locale(self): - """Gets the locale of this SingleBooleanValuedAttribute. # noqa: E501 - - - :return: The locale of this SingleBooleanValuedAttribute. # noqa: E501 - :rtype: str - """ - return self._locale - - @locale.setter - def locale(self, locale): - """Sets the locale of this SingleBooleanValuedAttribute. - - - :param locale: The locale of this SingleBooleanValuedAttribute. # noqa: E501 - :type: str - """ - - self._locale = locale - - 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(SingleBooleanValuedAttribute, 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, SingleBooleanValuedAttribute): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/single_integer_valued_attribute.py b/amazon/paapi5_python_sdk/single_integer_valued_attribute.py deleted file mode 100644 index 63b93e3..0000000 --- a/amazon/paapi5_python_sdk/single_integer_valued_attribute.py +++ /dev/null @@ -1,178 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class SingleIntegerValuedAttribute(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 = { - 'display_value': 'int', - 'label': 'str', - 'locale': 'str' - } - - attribute_map = { - 'display_value': 'DisplayValue', - 'label': 'Label', - 'locale': 'Locale' - } - - def __init__(self, display_value=None, label=None, locale=None): # noqa: E501 - """SingleIntegerValuedAttribute - a model defined in Swagger""" # noqa: E501 - - self._display_value = None - self._label = None - self._locale = None - self.discriminator = None - - if display_value is not None: - self.display_value = display_value - if label is not None: - self.label = label - if locale is not None: - self.locale = locale - - @property - def display_value(self): - """Gets the display_value of this SingleIntegerValuedAttribute. # noqa: E501 - - - :return: The display_value of this SingleIntegerValuedAttribute. # noqa: E501 - :rtype: int - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this SingleIntegerValuedAttribute. - - - :param display_value: The display_value of this SingleIntegerValuedAttribute. # noqa: E501 - :type: int - """ - - self._display_value = display_value - - @property - def label(self): - """Gets the label of this SingleIntegerValuedAttribute. # noqa: E501 - - - :return: The label of this SingleIntegerValuedAttribute. # noqa: E501 - :rtype: str - """ - return self._label - - @label.setter - def label(self, label): - """Sets the label of this SingleIntegerValuedAttribute. - - - :param label: The label of this SingleIntegerValuedAttribute. # noqa: E501 - :type: str - """ - - self._label = label - - @property - def locale(self): - """Gets the locale of this SingleIntegerValuedAttribute. # noqa: E501 - - - :return: The locale of this SingleIntegerValuedAttribute. # noqa: E501 - :rtype: str - """ - return self._locale - - @locale.setter - def locale(self, locale): - """Sets the locale of this SingleIntegerValuedAttribute. - - - :param locale: The locale of this SingleIntegerValuedAttribute. # noqa: E501 - :type: str - """ - - self._locale = locale - - 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(SingleIntegerValuedAttribute, 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, SingleIntegerValuedAttribute): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/single_string_valued_attribute.py b/amazon/paapi5_python_sdk/single_string_valued_attribute.py deleted file mode 100644 index e217d62..0000000 --- a/amazon/paapi5_python_sdk/single_string_valued_attribute.py +++ /dev/null @@ -1,178 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class SingleStringValuedAttribute(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 = { - 'display_value': 'str', - 'label': 'str', - 'locale': 'str' - } - - attribute_map = { - 'display_value': 'DisplayValue', - 'label': 'Label', - 'locale': 'Locale' - } - - def __init__(self, display_value=None, label=None, locale=None): # noqa: E501 - """SingleStringValuedAttribute - a model defined in Swagger""" # noqa: E501 - - self._display_value = None - self._label = None - self._locale = None - self.discriminator = None - - if display_value is not None: - self.display_value = display_value - if label is not None: - self.label = label - if locale is not None: - self.locale = locale - - @property - def display_value(self): - """Gets the display_value of this SingleStringValuedAttribute. # noqa: E501 - - - :return: The display_value of this SingleStringValuedAttribute. # noqa: E501 - :rtype: str - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this SingleStringValuedAttribute. - - - :param display_value: The display_value of this SingleStringValuedAttribute. # noqa: E501 - :type: str - """ - - self._display_value = display_value - - @property - def label(self): - """Gets the label of this SingleStringValuedAttribute. # noqa: E501 - - - :return: The label of this SingleStringValuedAttribute. # noqa: E501 - :rtype: str - """ - return self._label - - @label.setter - def label(self, label): - """Sets the label of this SingleStringValuedAttribute. - - - :param label: The label of this SingleStringValuedAttribute. # noqa: E501 - :type: str - """ - - self._label = label - - @property - def locale(self): - """Gets the locale of this SingleStringValuedAttribute. # noqa: E501 - - - :return: The locale of this SingleStringValuedAttribute. # noqa: E501 - :rtype: str - """ - return self._locale - - @locale.setter - def locale(self, locale): - """Sets the locale of this SingleStringValuedAttribute. - - - :param locale: The locale of this SingleStringValuedAttribute. # noqa: E501 - :type: str - """ - - self._locale = locale - - 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(SingleStringValuedAttribute, 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, SingleStringValuedAttribute): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/sort_by.py b/amazon/paapi5_python_sdk/sort_by.py deleted file mode 100644 index 33f8312..0000000 --- a/amazon/paapi5_python_sdk/sort_by.py +++ /dev/null @@ -1,108 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class SortBy(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - - """ - allowed enum values - """ - AVGCUSTOMERREVIEWS = "AvgCustomerReviews" - FEATURED = "Featured" - NEWESTARRIVALS = "NewestArrivals" - PRICE_HIGHTOLOW = "Price:HighToLow" - PRICE_LOWTOHIGH = "Price:LowToHigh" - RELEVANCE = "Relevance" - - """ - 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 = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """SortBy - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - 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(SortBy, 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, SortBy): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/technical_info.py b/amazon/paapi5_python_sdk/technical_info.py deleted file mode 100644 index 508af10..0000000 --- a/amazon/paapi5_python_sdk/technical_info.py +++ /dev/null @@ -1,128 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .multi_valued_attribute import MultiValuedAttribute # noqa: F401,E501 - - -class TechnicalInfo(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 = { - 'formats': 'MultiValuedAttribute' - } - - attribute_map = { - 'formats': 'Formats' - } - - def __init__(self, formats=None): # noqa: E501 - """TechnicalInfo - a model defined in Swagger""" # noqa: E501 - - self._formats = None - self.discriminator = None - - if formats is not None: - self.formats = formats - - @property - def formats(self): - """Gets the formats of this TechnicalInfo. # noqa: E501 - - - :return: The formats of this TechnicalInfo. # noqa: E501 - :rtype: MultiValuedAttribute - """ - return self._formats - - @formats.setter - def formats(self, formats): - """Sets the formats of this TechnicalInfo. - - - :param formats: The formats of this TechnicalInfo. # noqa: E501 - :type: MultiValuedAttribute - """ - - self._formats = formats - - 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(TechnicalInfo, 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, TechnicalInfo): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/trade_in_info.py b/amazon/paapi5_python_sdk/trade_in_info.py deleted file mode 100644 index 248b4e1..0000000 --- a/amazon/paapi5_python_sdk/trade_in_info.py +++ /dev/null @@ -1,154 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .trade_in_price import TradeInPrice # noqa: F401,E501 - - -class TradeInInfo(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 = { - 'is_eligible_for_trade_in': 'bool', - 'price': 'TradeInPrice' - } - - attribute_map = { - 'is_eligible_for_trade_in': 'IsEligibleForTradeIn', - 'price': 'Price' - } - - def __init__(self, is_eligible_for_trade_in=None, price=None): # noqa: E501 - """TradeInInfo - a model defined in Swagger""" # noqa: E501 - - self._is_eligible_for_trade_in = None - self._price = None - self.discriminator = None - - if is_eligible_for_trade_in is not None: - self.is_eligible_for_trade_in = is_eligible_for_trade_in - if price is not None: - self.price = price - - @property - def is_eligible_for_trade_in(self): - """Gets the is_eligible_for_trade_in of this TradeInInfo. # noqa: E501 - - - :return: The is_eligible_for_trade_in of this TradeInInfo. # noqa: E501 - :rtype: bool - """ - return self._is_eligible_for_trade_in - - @is_eligible_for_trade_in.setter - def is_eligible_for_trade_in(self, is_eligible_for_trade_in): - """Sets the is_eligible_for_trade_in of this TradeInInfo. - - - :param is_eligible_for_trade_in: The is_eligible_for_trade_in of this TradeInInfo. # noqa: E501 - :type: bool - """ - - self._is_eligible_for_trade_in = is_eligible_for_trade_in - - @property - def price(self): - """Gets the price of this TradeInInfo. # noqa: E501 - - - :return: The price of this TradeInInfo. # noqa: E501 - :rtype: TradeInPrice - """ - return self._price - - @price.setter - def price(self, price): - """Sets the price of this TradeInInfo. - - - :param price: The price of this TradeInInfo. # noqa: E501 - :type: TradeInPrice - """ - - self._price = price - - 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(TradeInInfo, 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, TradeInInfo): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/trade_in_price.py b/amazon/paapi5_python_sdk/trade_in_price.py deleted file mode 100644 index 3e968e5..0000000 --- a/amazon/paapi5_python_sdk/trade_in_price.py +++ /dev/null @@ -1,178 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class TradeInPrice(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 = { - 'amount': 'float', - 'currency': 'str', - 'display_amount': 'str' - } - - attribute_map = { - 'amount': 'Amount', - 'currency': 'Currency', - 'display_amount': 'DisplayAmount' - } - - def __init__(self, amount=None, currency=None, display_amount=None): # noqa: E501 - """TradeInPrice - a model defined in Swagger""" # noqa: E501 - - self._amount = None - self._currency = None - self._display_amount = None - self.discriminator = None - - if amount is not None: - self.amount = amount - if currency is not None: - self.currency = currency - if display_amount is not None: - self.display_amount = display_amount - - @property - def amount(self): - """Gets the amount of this TradeInPrice. # noqa: E501 - - - :return: The amount of this TradeInPrice. # noqa: E501 - :rtype: float - """ - return self._amount - - @amount.setter - def amount(self, amount): - """Sets the amount of this TradeInPrice. - - - :param amount: The amount of this TradeInPrice. # noqa: E501 - :type: float - """ - - self._amount = amount - - @property - def currency(self): - """Gets the currency of this TradeInPrice. # noqa: E501 - - - :return: The currency of this TradeInPrice. # noqa: E501 - :rtype: str - """ - return self._currency - - @currency.setter - def currency(self, currency): - """Sets the currency of this TradeInPrice. - - - :param currency: The currency of this TradeInPrice. # noqa: E501 - :type: str - """ - - self._currency = currency - - @property - def display_amount(self): - """Gets the display_amount of this TradeInPrice. # noqa: E501 - - - :return: The display_amount of this TradeInPrice. # noqa: E501 - :rtype: str - """ - return self._display_amount - - @display_amount.setter - def display_amount(self, display_amount): - """Sets the display_amount of this TradeInPrice. - - - :param display_amount: The display_amount of this TradeInPrice. # noqa: E501 - :type: str - """ - - self._display_amount = display_amount - - 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(TradeInPrice, 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, TradeInPrice): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/unit_based_attribute.py b/amazon/paapi5_python_sdk/unit_based_attribute.py deleted file mode 100644 index 19e5f31..0000000 --- a/amazon/paapi5_python_sdk/unit_based_attribute.py +++ /dev/null @@ -1,204 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class UnitBasedAttribute(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 = { - 'display_value': 'float', - 'label': 'str', - 'locale': 'str', - 'unit': 'str' - } - - attribute_map = { - 'display_value': 'DisplayValue', - 'label': 'Label', - 'locale': 'Locale', - 'unit': 'Unit' - } - - def __init__(self, display_value=None, label=None, locale=None, unit=None): # noqa: E501 - """UnitBasedAttribute - a model defined in Swagger""" # noqa: E501 - - self._display_value = None - self._label = None - self._locale = None - self._unit = None - self.discriminator = None - - if display_value is not None: - self.display_value = display_value - if label is not None: - self.label = label - if locale is not None: - self.locale = locale - if unit is not None: - self.unit = unit - - @property - def display_value(self): - """Gets the display_value of this UnitBasedAttribute. # noqa: E501 - - - :return: The display_value of this UnitBasedAttribute. # noqa: E501 - :rtype: float - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this UnitBasedAttribute. - - - :param display_value: The display_value of this UnitBasedAttribute. # noqa: E501 - :type: float - """ - - self._display_value = display_value - - @property - def label(self): - """Gets the label of this UnitBasedAttribute. # noqa: E501 - - - :return: The label of this UnitBasedAttribute. # noqa: E501 - :rtype: str - """ - return self._label - - @label.setter - def label(self, label): - """Sets the label of this UnitBasedAttribute. - - - :param label: The label of this UnitBasedAttribute. # noqa: E501 - :type: str - """ - - self._label = label - - @property - def locale(self): - """Gets the locale of this UnitBasedAttribute. # noqa: E501 - - - :return: The locale of this UnitBasedAttribute. # noqa: E501 - :rtype: str - """ - return self._locale - - @locale.setter - def locale(self, locale): - """Sets the locale of this UnitBasedAttribute. - - - :param locale: The locale of this UnitBasedAttribute. # noqa: E501 - :type: str - """ - - self._locale = locale - - @property - def unit(self): - """Gets the unit of this UnitBasedAttribute. # noqa: E501 - - - :return: The unit of this UnitBasedAttribute. # noqa: E501 - :rtype: str - """ - return self._unit - - @unit.setter - def unit(self, unit): - """Sets the unit of this UnitBasedAttribute. - - - :param unit: The unit of this UnitBasedAttribute. # noqa: E501 - :type: str - """ - - self._unit = unit - - 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(UnitBasedAttribute, 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, UnitBasedAttribute): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/variation_attribute.py b/amazon/paapi5_python_sdk/variation_attribute.py deleted file mode 100644 index 1173e3d..0000000 --- a/amazon/paapi5_python_sdk/variation_attribute.py +++ /dev/null @@ -1,152 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class VariationAttribute(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 = { - 'name': 'str', - 'value': 'str' - } - - attribute_map = { - 'name': 'Name', - 'value': 'Value' - } - - def __init__(self, name=None, value=None): # noqa: E501 - """VariationAttribute - a model defined in Swagger""" # noqa: E501 - - self._name = None - self._value = None - self.discriminator = None - - if name is not None: - self.name = name - if value is not None: - self.value = value - - @property - def name(self): - """Gets the name of this VariationAttribute. # noqa: E501 - - - :return: The name of this VariationAttribute. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this VariationAttribute. - - - :param name: The name of this VariationAttribute. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def value(self): - """Gets the value of this VariationAttribute. # noqa: E501 - - - :return: The value of this VariationAttribute. # noqa: E501 - :rtype: str - """ - return self._value - - @value.setter - def value(self, value): - """Sets the value of this VariationAttribute. - - - :param value: The value of this VariationAttribute. # noqa: E501 - :type: str - """ - - self._value = value - - 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(VariationAttribute, 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, VariationAttribute): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/variation_dimension.py b/amazon/paapi5_python_sdk/variation_dimension.py deleted file mode 100644 index 8ff9e86..0000000 --- a/amazon/paapi5_python_sdk/variation_dimension.py +++ /dev/null @@ -1,204 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class VariationDimension(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 = { - 'display_name': 'str', - 'locale': 'str', - 'name': 'str', - 'values': 'list[str]' - } - - attribute_map = { - 'display_name': 'DisplayName', - 'locale': 'Locale', - 'name': 'Name', - 'values': 'Values' - } - - def __init__(self, display_name=None, locale=None, name=None, values=None): # noqa: E501 - """VariationDimension - a model defined in Swagger""" # noqa: E501 - - self._display_name = None - self._locale = None - self._name = None - self._values = None - self.discriminator = None - - if display_name is not None: - self.display_name = display_name - if locale is not None: - self.locale = locale - if name is not None: - self.name = name - if values is not None: - self.values = values - - @property - def display_name(self): - """Gets the display_name of this VariationDimension. # noqa: E501 - - - :return: The display_name of this VariationDimension. # noqa: E501 - :rtype: str - """ - return self._display_name - - @display_name.setter - def display_name(self, display_name): - """Sets the display_name of this VariationDimension. - - - :param display_name: The display_name of this VariationDimension. # noqa: E501 - :type: str - """ - - self._display_name = display_name - - @property - def locale(self): - """Gets the locale of this VariationDimension. # noqa: E501 - - - :return: The locale of this VariationDimension. # noqa: E501 - :rtype: str - """ - return self._locale - - @locale.setter - def locale(self, locale): - """Sets the locale of this VariationDimension. - - - :param locale: The locale of this VariationDimension. # noqa: E501 - :type: str - """ - - self._locale = locale - - @property - def name(self): - """Gets the name of this VariationDimension. # noqa: E501 - - - :return: The name of this VariationDimension. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this VariationDimension. - - - :param name: The name of this VariationDimension. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def values(self): - """Gets the values of this VariationDimension. # noqa: E501 - - - :return: The values of this VariationDimension. # noqa: E501 - :rtype: list[str] - """ - return self._values - - @values.setter - def values(self, values): - """Sets the values of this VariationDimension. - - - :param values: The values of this VariationDimension. # noqa: E501 - :type: list[str] - """ - - self._values = values - - 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(VariationDimension, 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, VariationDimension): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/variation_summary.py b/amazon/paapi5_python_sdk/variation_summary.py deleted file mode 100644 index e8aeea4..0000000 --- a/amazon/paapi5_python_sdk/variation_summary.py +++ /dev/null @@ -1,207 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .price import Price # noqa: F401,E501 -from .variation_dimension import VariationDimension # noqa: F401,E501 - - -class VariationSummary(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 = { - 'page_count': 'int', - 'price': 'Price', - 'variation_count': 'int', - 'variation_dimensions': 'list[VariationDimension]' - } - - attribute_map = { - 'page_count': 'PageCount', - 'price': 'Price', - 'variation_count': 'VariationCount', - 'variation_dimensions': 'VariationDimensions' - } - - def __init__(self, page_count=None, price=None, variation_count=None, variation_dimensions=None): # noqa: E501 - """VariationSummary - a model defined in Swagger""" # noqa: E501 - - self._page_count = None - self._price = None - self._variation_count = None - self._variation_dimensions = None - self.discriminator = None - - if page_count is not None: - self.page_count = page_count - if price is not None: - self.price = price - if variation_count is not None: - self.variation_count = variation_count - if variation_dimensions is not None: - self.variation_dimensions = variation_dimensions - - @property - def page_count(self): - """Gets the page_count of this VariationSummary. # noqa: E501 - - - :return: The page_count of this VariationSummary. # noqa: E501 - :rtype: int - """ - return self._page_count - - @page_count.setter - def page_count(self, page_count): - """Sets the page_count of this VariationSummary. - - - :param page_count: The page_count of this VariationSummary. # noqa: E501 - :type: int - """ - - self._page_count = page_count - - @property - def price(self): - """Gets the price of this VariationSummary. # noqa: E501 - - - :return: The price of this VariationSummary. # noqa: E501 - :rtype: Price - """ - return self._price - - @price.setter - def price(self, price): - """Sets the price of this VariationSummary. - - - :param price: The price of this VariationSummary. # noqa: E501 - :type: Price - """ - - self._price = price - - @property - def variation_count(self): - """Gets the variation_count of this VariationSummary. # noqa: E501 - - - :return: The variation_count of this VariationSummary. # noqa: E501 - :rtype: int - """ - return self._variation_count - - @variation_count.setter - def variation_count(self, variation_count): - """Sets the variation_count of this VariationSummary. - - - :param variation_count: The variation_count of this VariationSummary. # noqa: E501 - :type: int - """ - - self._variation_count = variation_count - - @property - def variation_dimensions(self): - """Gets the variation_dimensions of this VariationSummary. # noqa: E501 - - - :return: The variation_dimensions of this VariationSummary. # noqa: E501 - :rtype: list[VariationDimension] - """ - return self._variation_dimensions - - @variation_dimensions.setter - def variation_dimensions(self, variation_dimensions): - """Sets the variation_dimensions of this VariationSummary. - - - :param variation_dimensions: The variation_dimensions of this VariationSummary. # noqa: E501 - :type: list[VariationDimension] - """ - - self._variation_dimensions = variation_dimensions - - 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(VariationSummary, 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, VariationSummary): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/variations_result.py b/amazon/paapi5_python_sdk/variations_result.py deleted file mode 100644 index 9ce3c66..0000000 --- a/amazon/paapi5_python_sdk/variations_result.py +++ /dev/null @@ -1,155 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - -from .item import Item # noqa: F401,E501 -from .variation_summary import VariationSummary # noqa: F401,E501 - - -class VariationsResult(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 = { - 'items': 'list[Item]', - 'variation_summary': 'VariationSummary' - } - - attribute_map = { - 'items': 'Items', - 'variation_summary': 'VariationSummary' - } - - def __init__(self, items=None, variation_summary=None): # noqa: E501 - """VariationsResult - a model defined in Swagger""" # noqa: E501 - - self._items = None - self._variation_summary = None - self.discriminator = None - - if items is not None: - self.items = items - if variation_summary is not None: - self.variation_summary = variation_summary - - @property - def items(self): - """Gets the items of this VariationsResult. # noqa: E501 - - - :return: The items of this VariationsResult. # noqa: E501 - :rtype: list[Item] - """ - return self._items - - @items.setter - def items(self, items): - """Sets the items of this VariationsResult. - - - :param items: The items of this VariationsResult. # noqa: E501 - :type: list[Item] - """ - - self._items = items - - @property - def variation_summary(self): - """Gets the variation_summary of this VariationsResult. # noqa: E501 - - - :return: The variation_summary of this VariationsResult. # noqa: E501 - :rtype: VariationSummary - """ - return self._variation_summary - - @variation_summary.setter - def variation_summary(self, variation_summary): - """Sets the variation_summary of this VariationsResult. - - - :param variation_summary: The variation_summary of this VariationsResult. # noqa: E501 - :type: VariationSummary - """ - - self._variation_summary = variation_summary - - 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(VariationsResult, 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, VariationsResult): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/paapi5_python_sdk/website_sales_rank.py b/amazon/paapi5_python_sdk/website_sales_rank.py deleted file mode 100644 index da92d28..0000000 --- a/amazon/paapi5_python_sdk/website_sales_rank.py +++ /dev/null @@ -1,204 +0,0 @@ -# coding: utf-8 - -""" - Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - A copy of the License is located at - - http://www.apache.org/licenses/LICENSE-2.0 - - or in the "license" file accompanying this file. This file is distributed - on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - express or implied. See the License for the specific language governing - permissions and limitations under the License. -""" - -""" - ProductAdvertisingAPI - - https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 -""" - - -import pprint -import re # noqa: F401 - -import six - - -class WebsiteSalesRank(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 = { - 'context_free_name': 'str', - 'display_name': 'str', - 'id': 'str', - 'sales_rank': 'int' - } - - attribute_map = { - 'context_free_name': 'ContextFreeName', - 'display_name': 'DisplayName', - 'id': 'Id', - 'sales_rank': 'SalesRank' - } - - def __init__(self, context_free_name=None, display_name=None, id=None, sales_rank=None): # noqa: E501 - """WebsiteSalesRank - a model defined in Swagger""" # noqa: E501 - - self._context_free_name = None - self._display_name = None - self._id = None - self._sales_rank = None - self.discriminator = None - - if context_free_name is not None: - self.context_free_name = context_free_name - if display_name is not None: - self.display_name = display_name - if id is not None: - self.id = id - if sales_rank is not None: - self.sales_rank = sales_rank - - @property - def context_free_name(self): - """Gets the context_free_name of this WebsiteSalesRank. # noqa: E501 - - - :return: The context_free_name of this WebsiteSalesRank. # noqa: E501 - :rtype: str - """ - return self._context_free_name - - @context_free_name.setter - def context_free_name(self, context_free_name): - """Sets the context_free_name of this WebsiteSalesRank. - - - :param context_free_name: The context_free_name of this WebsiteSalesRank. # noqa: E501 - :type: str - """ - - self._context_free_name = context_free_name - - @property - def display_name(self): - """Gets the display_name of this WebsiteSalesRank. # noqa: E501 - - - :return: The display_name of this WebsiteSalesRank. # noqa: E501 - :rtype: str - """ - return self._display_name - - @display_name.setter - def display_name(self, display_name): - """Sets the display_name of this WebsiteSalesRank. - - - :param display_name: The display_name of this WebsiteSalesRank. # noqa: E501 - :type: str - """ - - self._display_name = display_name - - @property - def id(self): - """Gets the id of this WebsiteSalesRank. # noqa: E501 - - - :return: The id of this WebsiteSalesRank. # noqa: E501 - :rtype: str - """ - return self._id - - @id.setter - def id(self, id): - """Sets the id of this WebsiteSalesRank. - - - :param id: The id of this WebsiteSalesRank. # noqa: E501 - :type: str - """ - - self._id = id - - @property - def sales_rank(self): - """Gets the sales_rank of this WebsiteSalesRank. # noqa: E501 - - - :return: The sales_rank of this WebsiteSalesRank. # noqa: E501 - :rtype: int - """ - return self._sales_rank - - @sales_rank.setter - def sales_rank(self, sales_rank): - """Sets the sales_rank of this WebsiteSalesRank. - - - :param sales_rank: The sales_rank of this WebsiteSalesRank. # noqa: E501 - :type: int - """ - - self._sales_rank = sales_rank - - 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(WebsiteSalesRank, 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, WebsiteSalesRank): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/amazon/parse.py b/amazon/parse.py deleted file mode 100644 index 1f65cf3..0000000 --- a/amazon/parse.py +++ /dev/null @@ -1,550 +0,0 @@ -"""Data parser for instance creation.""" -import pprint - -import six - -class Class: - """Base class for creating the product instance.""" - pass - - -class AmazonBrowseNode(): - swagger_types = { - 'ancestor': 'BrowseNodeAncestor', - 'children': 'BrowseNodeChildren', - 'context_free_name': 'str', - 'display_name': 'str', - 'id': 'str', - 'is_root': 'bool', - 'sales_rank': 'int' - } - - def __init__(self, node): - self.ancestor = node.ancestor - self.children = node.children - self.context_free_name = node.context_free_name - self.display_name = node.display_name - self.id = node.id - self.is_root = node.is_root - self.sales_rank = node.sales_rank - - def to_dict(self): - 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(AmazonBrowseNode, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - return pprint.pformat(self.to_dict()) - - def __repr__(self): - return self.to_str() - - def __eq__(self, other): - if not isinstance(other, AmazonBrowseNode): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - return not self == other - - -def parse_browsenode(browse_nodes_response): - """Parse browse node data and creates a dict. - - Args: - browse_nodes_response (list): List of browse nodes responses. - - Returns: - dict: Dict with browse node information. - """ - mapped_response = {} - for browse_node in browse_nodes_response: - mapped_response[browse_node.id] = browse_node - return mapped_response - - -def parse_product(item): - """Parse item data and creates product instance. - - Args: - item (instance): The instance with the data from Amazon API. - - Returns: - instance: Product instance with parsed data. - """ - product = Class() - product.raw_info = item - - # Main - product.asin = item.asin - try: - product.url = item.detail_page_url - except Exception: - product.url = None - try: - product.title = item.item_info.title.display_value - except Exception: - product.title = None - try: - product.parent_asin = item.parent_asin - except Exception: - product.parent_asin = None - - # Info - product.info = Class() - try: - product.info.contributors = [] - for x in item.item_info.by_line_info.contributors: - contributor = Class() - contributor.name = x.name - contributor.role = x.role - product.info.contributors.append(contributor) - except Exception: - product.info.contributors = None - try: - product.info.manufacturer = item.item_info.by_line_info.manufacturer.display_value - except Exception: - product.info.manufacturer = None - try: - product.info.brand = item.item_info.by_line_info.brand.display_value - except Exception: - product.info.brand = None - try: - product.info.product_group = item.item_info.classifications.product_group.display_value - except Exception: - product.info.product_group = None - try: - product.info.binding = item.item_info.classifications.binding.display_value - except Exception: - product.info.binding = None - try: - product.info.is_adult = item.item_info.product_info.is_adult_product.display_value - except Exception: - product.info.is_adult = None - try: - product.info.edition = item.item_info.content_info.edition.display_value - except Exception: - product.info.edition = None - try: - product.info.warranty = item.item_info.manufacture_info.warranty.display_value - except Exception: - product.info.warranty = None - try: - product.info.audience_rating = item.item_info.content_rating.audience_rating.display_value - except Exception: - product.info.audience_rating = None - try: - product.info.part_number = item.item_info.manufacture_info.item_part_number.display_value - except Exception: - product.info.part_number = None - try: - product.info.model = item.item_info.manufacture_info.model.display_value - except Exception: - product.info.model = None - try: - product.info.publication_date = item.item_info.content_info.publication_date.display_value - except Exception: - product.info.publication_date = None - try: - product.info.release_date = item.item_info.product_info.release_date.display_value - except Exception: - product.info.release_date = None - product.info.external_ids = Class() - try: - product.info.external_ids.ean = item.item_info.external_ids.ea_ns.display_values - except Exception: - product.info.external_ids.ean = None - try: - product.info.external_ids.isbn = item.item_info.external_ids.isb_ns.display_values - except Exception: - product.info.external_ids.isbn = None - try: - product.info.external_ids.upc = item.item_info.external_ids.up_cs.display_values - except Exception: - product.info.external_ids.upc = None - - # Product - product.product = Class() - try: - product.product.features = item.item_info.features.display_values - except Exception: - product.product.features = None - try: - product.product.languages = [] - for x in item.item_info.content_info.languages.display_values: - product.product.languages.append(x.display_value + ' ' + x.type) - except Exception: - product.product.languages = None - try: - product.product.pages_count = item.item_info.content_info.pages_count.display_value - except Exception: - product.product.pages_count = None - try: - product.product.formats = item.item_info.technical_info.formats.display_values - except Exception: - product.product.formats = None - try: - product.product.color = item.item_info.product_info.color.display_value - except Exception: - product.product.color = None - try: - product.product.unit_count = item.item_info.product_info.unit_count.display_value - except Exception: - product.product.unit_count = None - product.product.dimensions = Class() - try: - product.product.size = item.item_info.product_info.size.display_value - except Exception: - product.product.size = None - product.product.dimensions.height = Class() - try: - product.product.dimensions.height.value = item.item_info.product_info.item_dimensions.height.display_value - except Exception: - product.product.dimensions.height.value = None - try: - product.product.dimensions.height.unit = item.item_info.product_info.item_dimensions.height.unit - except Exception: - product.product.dimensions.height.unit = None - product.product.dimensions.length = Class() - try: - product.product.dimensions.length.value = item.item_info.product_info.item_dimensions.length.display_value - except Exception: - product.product.dimensions.length.value = None - try: - product.product.dimensions.length.unit = item.item_info.product_info.item_dimensions.length.unit - except Exception: - product.product.dimensions.length.unit = None - product.product.dimensions.width = Class() - try: - product.product.dimensions.width.value = item.item_info.product_info.item_dimensions.width.display_value - except Exception: - product.product.dimensions.width.value = None - try: - product.product.dimensions.width.unit = item.item_info.product_info.item_dimensions.width.unit - except Exception: - product.product.dimensions.width.unit = None - product.product.weight = Class() - try: - product.product.weight.value = item.item_info.product_info.item_dimensions.weight.display_value - except Exception: - product.product.weight.value = None - try: - product.product.weight.unit = item.item_info.product_info.item_dimensions.weight.unit - except Exception: - product.product.weight.unit = None - - # Images - product.images = Class() - try: - product.images.large = item.images.primary.large.url - except Exception: - product.images.large = None - try: - product.images.medium = item.images.primary.medium.url - except Exception: - product.images.medium = None - try: - product.images.small = item.images.primary.small.url - except Exception: - product.images.small = None - try: - product.images.variants = Class() - product.images.variants.small = [] - product.images.variants.medium = [] - product.images.variants.large = [] - for variant in item.images.variants: - try: - product.images.variants.large.append(variant.large.url) - product.images.variants.medium.append(variant.medium.url) - product.images.variants.small.append(variant.small.url) - except Exception: - pass - if not product.images.variants.small and not product.images.variants.medium and not product.images.variants.large: - product.images.variants = None - except Exception: - product.images.variants = None - product.images.cropped = Class() - product.images.cropped.small = [] - product.images.cropped.medium = [] - product.images.cropped.large = [] - try: - product.images.cropped.small.append(product.images.small.replace('_SL', '_AC')) - except Exception: - pass - try: - product.images.cropped.medium.append(product.images.medium.replace('_SL', '_AC')) - except Exception: - pass - try: - product.images.cropped.large.append(product.images.large.replace('.jpg', '._AC_.jpg')) - except Exception: - pass - try: - for x in product.images.variants.small: - product.images.cropped.small.append(x.replace('_SL', '_AC')) - except Exception: - pass - try: - for x in product.images.variants.medium: - product.images.cropped.medium.append(x.replace('_SL', '_AC')) - except Exception: - pass - try: - for x in product.images.variants.large: - product.images.cropped.large.append(x.replace('.jpg', '._AC_.jpg')) - except Exception: - pass - - # Trade In - product.trade_in = Class() - try: - product.trade_in.eligible = item.item_info.trade_in_info.is_eligible_for_trade_in - except Exception: - product.trade_in.eligible = None - try: - product.trade_in.price = item.item_info.trade_in_info.price.amount - except Exception: - product.trade_in.price = None - try: - product.trade_in.currency = item.item_info.trade_in_info.price.currency - except Exception: - product.trade_in.currency = None - if not product.trade_in.eligible and not product.trade_in.price and not product.trade_in.currency: - product.trade_in = None - - # Prices - try: - listings = item.offers.listings[0] - except Exception: - listings = None - product.prices = Class() - product.prices.price = Class() - try: - product.prices.price.value = listings.price.amount - except Exception: - product.prices.price.value = None - try: - product.prices.price.currency = listings.price.currency - except Exception: - product.prices.price.currency = None - try: - product.prices.price.per_unit = listings.price.price_per_unit - except Exception: - product.prices.price.per_unit = None - try: - product.prices.price.display = listings.price.display_amount - except Exception: - product.prices.price.display = None - product.prices.price.savings = Class() - try: - product.prices.price.savings.value = listings.price.savings.amount - except Exception: - product.prices.price.savings.value = None - try: - product.prices.price.savings.currency = listings.price.savings.currency - except Exception: - product.prices.price.savings.currency = None - try: - product.prices.price.savings.per_unit = listings.price.savings.price_per_unit - except Exception: - product.prices.price.savings.per_unit = None - try: - product.prices.price.savings.display = listings.price.savings.display_amount - except Exception: - product.prices.price.savings.display = None - try: - product.prices.price.savings.percentage = listings.price.savings.percentage - except Exception: - product.prices.price.savings.percentage = None - product.prices.pvp = Class() - try: - product.prices.pvp.value = listings.saving_basis.amount - except Exception: - product.prices.pvp.value = None - try: - product.prices.pvp.currency = listings.saving_basis.currency - except Exception: - product.prices.pvp.currency = None - try: - product.prices.pvp.per_unit = listings.saving_basis.price_per_unit - except Exception: - product.prices.pvp.per_unit = None - try: - product.prices.pvp.display = listings.saving_basis.display_amount - except Exception: - product.prices.pvp.display = None - product.prices.availability = Class() - try: - product.prices.availability.message = listings.availability.message - except Exception: - product.prices.availability.message = None - try: - product.prices.availability.type = listings.availability.type - except Exception: - product.prices.availability.type = None - try: - product.prices.availability.max_order_quantity = listings.availability.max_order_quantity - except Exception: - product.prices.availability.max_order_quantity = None - try: - product.prices.availability.min_order_quantity = listings.availability.min_order_quantity - except Exception: - product.prices.availability.min_order_quantity = None - product.prices.condition = Class() - try: - product.prices.condition.condition = listings.condition.value - except Exception: - product.prices.condition = None - try: - product.prices.condition.condition_display = listings.condition.display_value - except Exception: - product.prices.condition_display = None - try: - product.prices.condition.sub_condition = listings.condition.sub_condition.value - except Exception: - product.prices.sub_condition = None - try: - product.prices.condition.sub_condition_display = listings.condition.sub_condition.display_value - except Exception: - product.prices.sub_condition_display = None - product.prices.merchant = Class() - try: - product.prices.merchant.default_shipping_country = listings.merchant_info.default_shipping_country - except Exception: - product.prices.merchant.default_shipping_country = None - try: - product.prices.merchant.merchant_id = listings.merchant_info.id - except Exception: - product.prices.merchant.merchant_id = None - try: - product.prices.merchant.name = listings.merchant_info.name - except Exception: - product.prices.merchant.name = None - product.prices.other = Class() - try: - product.prices.other.buybox_winner = listings.is_buy_box_winner - except Exception: - product.prices.other.buybox_winner = None - try: - product.prices.other.loyalty_points = listings.loyalty_points - except Exception: - product.prices.other.loyalty_points = None - try: - product.prices.other.amazon_fulfilled = listings.delivery_info.is_amazon_fulfilled - except Exception: - product.prices.other.amazon_fulfilled = None - try: - product.prices.other.free_shipping_eligible = listings.delivery_info.is_free_shipping_eligible - except Exception: - product.prices.other.free_shipping_eligible = None - try: - product.prices.other.prime_eligible = listings.delivery_info.is_prime_eligible - except Exception: - product.prices.other.prime_eligible = None - try: - product.prices.other.prime_exclusive = listings.program_eligibility.is_prime_exclusive - except Exception: - product.prices.other.prime_exclusive = None - try: - product.prices.other.prime_pantry = listings.program_eligibility.is_prime_pantry - except Exception: - product.prices.other.prime_pantry = None - try: - product.prices.other.violates_map = listings.violates_map - except Exception: - product.prices.other.violates_map = None - try: - product.prices.other.offer_id = listings.id - except Exception: - product.prices.other.offer_id = None - - # Offers Summary - try: - summaries = item.offers.summaries - product.offers_summary = [] - except Exception: - summaries = None - product.offers_summary = None - if summaries: - for x in summaries: - offer = Class() - offer.highest_price = Class() - offer.lowest_price = Class() - try: - offer.highest_price.value = x.highest_price.amount - except Exception: - offer.highest_price.value = None - try: - offer.highest_price.currency = x.highest_price.currency - except Exception: - offer.highest_price.currency = None - try: - offer.highest_price.per_unit = x.highest_price.price_per_unit - except Exception: - offer.highest_price.per_unit = None - try: - offer.highest_price.display = x.highest_price.display_amount - except Exception: - offer.highest_price.display = None - try: - offer.lowest_price.value = x.lowest_price.amount - except Exception: - offer.lowest_price.value = None - try: - offer.lowest_price.currency = x.lowest_price.currency - except Exception: - offer.lowest_price.currency = None - try: - offer.lowest_price.per_unit = x.lowest_price.price_per_unit - except Exception: - offer.lowest_price.per_unit = None - try: - offer.lowest_price.display = x.lowest_price.display_amount - except Exception: - offer.lowest_price.display = None - offer.condition = Class() - try: - offer.condition.condition = x.condition.value - except Exception: - offer.condition.condition = None - try: - offer.condition.condition.condition_display = x.condition.display_value - except Exception: - offer.condition.condition_display = None - try: - offer.condition.condition.sub_condition = x.condition.sub_condition.value - except Exception: - offer.condition.sub_condition = None - try: - offer.condition.condition.sub_condition_display = x.condition.sub_condition.display_value - except Exception: - offer.condition.sub_condition_display = None - try: - offer.offer_count = x.offer_count - except Exception: - offer.offer_count = None - product.offers_summary.append(offer) - - return product diff --git a/amazon/serializer/dango_rest_framework.py b/amazon/serializer/dango_rest_framework.py deleted file mode 100644 index 8988c15..0000000 --- a/amazon/serializer/dango_rest_framework.py +++ /dev/null @@ -1,156 +0,0 @@ -from rest_framework import serializers - - -class _AmazonValueUnitSerializer(serializers.Serializer): - value = serializers.FloatField() - unit = serializers.CharField() - - -class _AmazonDimensionsSerializer(serializers.Serializer): - height = _AmazonValueUnitSerializer() - length = _AmazonValueUnitSerializer() - width = _AmazonValueUnitSerializer() - - -class _AmazonProductSerializer(serializers.Serializer): - features = serializers.ListField() - languages = serializers.ListField() - formats = serializers.ListField() - pages_count = serializers.ListField() - color = serializers.CharField() - unit_count = serializers.IntegerField() - size = serializers.CharField() - dimensions = _AmazonDimensionsSerializer() - weight = _AmazonValueUnitSerializer() - - -class _AmazonContributorsSerializer(serializers.Serializer): - name = serializers.CharField() - role = serializers.CharField() - - -class _AmazonExternalIdsSerializer(serializers.Serializer): - ean = serializers.ListField() - isbn = serializers.ListField() - upc = serializers.ListField() - - -class _AmazonInfoSerializer(serializers.Serializer): - contributors = _AmazonContributorsSerializer(many=True) - manufacturer = serializers.CharField() - brand = serializers.CharField() - model = serializers.CharField() - part_number = serializers.CharField() - product_group = serializers.CharField() - binding = serializers.CharField() - is_adult = serializers.BooleanField() - audience_rating = serializers.CharField() - edition = serializers.CharField() - warranty = serializers.CharField() - publication_date = serializers.CharField() - release_date = serializers.CharField() - external_ids = _AmazonExternalIdsSerializer() - - -class _AmazonImageVariantsSerializer(serializers.Serializer): - small = serializers.ListField() - medium = serializers.ListField() - large = serializers.ListField() - - -class _AmazonImagesSerializer(serializers.Serializer): - small = serializers.CharField() - medium = serializers.CharField() - large = serializers.CharField() - cropped = _AmazonImageVariantsSerializer() - variants = _AmazonImageVariantsSerializer() - - -class _AmazonTradeInSerializer(serializers.Serializer): - elegible = serializers.BooleanField() - price = serializers.FloatField() - currency = serializers.CharField() - - -class _AmazonSavingsSerializer(serializers.Serializer): - value = serializers.FloatField() - currency = serializers.CharField() - per_unit = serializers.FloatField() - display = serializers.CharField() - percentage = serializers.FloatField() - - -class _AmazonPriceSerializer(serializers.Serializer): - value = serializers.FloatField() - currency = serializers.CharField() - per_unit = serializers.FloatField() - display = serializers.CharField() - savings = _AmazonSavingsSerializer() - - -class _AmazonPvpSerializer(serializers.Serializer): - value = serializers.FloatField() - currency = serializers.CharField() - per_unit = serializers.FloatField() - display = serializers.CharField() - - -class _AmazonAvailabilitySerializer(serializers.Serializer): - max_order_quantity = serializers.IntegerField() - min_order_quantity = serializers.IntegerField() - type = serializers.CharField() - message = serializers.CharField() - - -class _AmazonConditionSerializer(serializers.Serializer): - condition = serializers.CharField() - condition_display = serializers.CharField() - sub_condition = serializers.CharField() - sub_condition_display = serializers.CharField() - - -class _AmazonMerchantSerializer(serializers.Serializer): - default_shipping_country = serializers.CharField() - merchant_id = serializers.CharField() - name = serializers.CharField() - - -class _AmazonOtherSerializer(serializers.Serializer): - buybox_winner = serializers.BooleanField() - loyalty_points = serializers.IntegerField() - amazon_fulfilled = serializers.BooleanField() - free_shipping_eligible = serializers.BooleanField() - prime_eligible = serializers.BooleanField() - prime_exclusive = serializers.BooleanField() - prime_pantry = serializers.BooleanField() - violates_map = serializers.BooleanField() - offer_id = serializers.CharField() - - -class _AmazonPricesSerializer(serializers.Serializer): - price = _AmazonPriceSerializer() - pvp = _AmazonPvpSerializer() - availability = _AmazonAvailabilitySerializer() - condition = _AmazonConditionSerializer() - merchant = _AmazonMerchantSerializer() - other = _AmazonOtherSerializer() - - -class _AmazonOffersSummarySerializer(serializers.Serializer): - highest_price = _AmazonPvpSerializer() - lowest_price = _AmazonPvpSerializer() - condition = _AmazonConditionSerializer() - offer_count = serializers.IntegerField() - - -class AmazonProductSerializer(serializers.Serializer): - asin = serializers.CharField(max_length=10) - parent_asin = serializers.CharField(max_length=10) - title = serializers.CharField() - url = serializers.CharField() - product = _AmazonProductSerializer() - info = _AmazonInfoSerializer() - images = _AmazonImagesSerializer() - trade_in = _AmazonTradeInSerializer() - prices = _AmazonPricesSerializer() - offers_summary = _AmazonOffersSummarySerializer(many=True) diff --git a/amazon/tools.py b/amazon/tools.py deleted file mode 100644 index c67e29f..0000000 --- a/amazon/tools.py +++ /dev/null @@ -1,26 +0,0 @@ -"""Some useful tools.""" - -import re - - -def get_asin(url: str): - """Find the ASIN from a given URL. - - Args: - url (str): The URL containing the product ASIN. - - Returns: - str: Product ASIN. None if ASIN not found. - """ - # Return if url parameter already is the ASIN - if re.search(r'^[A-Z0-9]{10}$', url): - return url - # Extract ASIN from URL searching for alphanumeric and 10 digits - have_asin = re.search(r'(dp|gp/product|gp/aw/d|dp/product)/([a-zA-Z0-9]{10})', url) - return have_asin.group(2) if have_asin else None - - -def chunks(lst, n): - """Yield successive n-sized chunks from lst.""" - for i in range(0, len(lst), n): - yield lst[i:i + n] diff --git a/docs/Makefile b/docs/Makefile new file mode 100644 index 0000000..d4bb2cb --- /dev/null +++ b/docs/Makefile @@ -0,0 +1,20 @@ +# Minimal makefile for Sphinx documentation +# + +# You can set these variables from the command line, and also +# from the environment for the first two. +SPHINXOPTS ?= +SPHINXBUILD ?= sphinx-build +SOURCEDIR = . +BUILDDIR = _build + +# Put it first so that "make" without argument is like "make help". +help: + @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) + +.PHONY: help Makefile + +# Catch-all target: route all unknown targets to Sphinx using the new +# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). +%: Makefile + @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/docs/conf.py b/docs/conf.py new file mode 100644 index 0000000..32e7211 --- /dev/null +++ b/docs/conf.py @@ -0,0 +1,56 @@ +# Configuration file for the Sphinx documentation builder. +# +# This file only contains a selection of the most common options. For a full +# list see the documentation: +# https://www.sphinx-doc.org/en/master/usage/configuration.html + +# -- Path setup -------------------------------------------------------------- + +# If extensions (or modules to document with autodoc) are in another directory, +# add these directories to sys.path here. If the directory is relative to the +# documentation root, use os.path.abspath to make it absolute, like shown here. +# +import os +import sys +sys.path.insert(0, os.path.abspath('..')) + + +# -- Project information ----------------------------------------------------- + +project = 'python-amazon-paapi' +copyright = '2021, Sergio Abad' +author = 'Sergio Abad' + +# The full version, including alpha/beta/rc tags +release = '4.2.0' + + +# -- General configuration --------------------------------------------------- + +# Add any Sphinx extension module names here, as strings. They can be +# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom +# ones. +extensions = [ + 'sphinx.ext.autodoc' +] + +# Add any paths that contain templates here, relative to this directory. +templates_path = ['_templates'] + +# List of patterns, relative to source directory, that match files and +# directories to ignore when looking for source files. +# This pattern also affects html_static_path and html_extra_path. +exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] + + +# -- Options for HTML output ------------------------------------------------- + +# The theme to use for HTML and HTML Help pages. See the documentation for +# a list of builtin themes. +# +html_theme = 'sphinx_rtd_theme' + +# Add any paths that contain custom static files (such as style sheets) here, +# relative to this directory. They are copied after the builtin static files, +# so a file named "default.css" will overwrite the builtin "default.css". +html_static_path = ['_static'] diff --git a/docs/index.rst b/docs/index.rst new file mode 100644 index 0000000..dc95697 --- /dev/null +++ b/docs/index.rst @@ -0,0 +1,21 @@ +.. python-amazon-paapi documentation master file, created by + sphinx-quickstart on Mon Nov 22 18:33:43 2021. + You can adapt this file completely to your liking, but it should at least + contain the root `toctree` directive. + +Welcome to python-amazon-paapi's documentation! +=============================================== + +.. toctree:: + :maxdepth: 2 + :caption: Contents: + + modules + + +Indices and tables +================== + +* :ref:`genindex` +* :ref:`modindex` +* :ref:`search` diff --git a/docs/make.bat b/docs/make.bat new file mode 100644 index 0000000..8084272 --- /dev/null +++ b/docs/make.bat @@ -0,0 +1,35 @@ +@ECHO OFF + +pushd %~dp0 + +REM Command file for Sphinx documentation + +if "%SPHINXBUILD%" == "" ( + set SPHINXBUILD=sphinx-build +) +set SOURCEDIR=. +set BUILDDIR=_build + +if "%1" == "" goto help + +%SPHINXBUILD% >NUL 2>NUL +if errorlevel 9009 ( + echo. + echo.The 'sphinx-build' command was not found. Make sure you have Sphinx + echo.installed, then set the SPHINXBUILD environment variable to point + echo.to the full path of the 'sphinx-build' executable. Alternatively you + echo.may add the Sphinx directory to PATH. + echo. + echo.If you don't have Sphinx installed, grab it from + echo.https://www.sphinx-doc.org/ + exit /b 1 +) + +%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% +goto end + +:help +%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% + +:end +popd diff --git a/docs/requirements.txt b/docs/requirements.txt new file mode 100644 index 0000000..87ebd21 --- /dev/null +++ b/docs/requirements.txt @@ -0,0 +1,2 @@ +sphinx==4.3.0 +sphinx_rtd_theme==1.0.0 From c8961249ae77c825d65b62adc3be40cce7b93f14 Mon Sep 17 00:00:00 2001 From: Sergio Abad Date: Mon, 22 Nov 2021 22:49:45 +0100 Subject: [PATCH 2/7] First documentation version working --- docs/_static/dark.css | 3461 ++++++++++++++++++++++++++++++ docs/amazon_paapi.errors.rst | 21 + docs/amazon_paapi.helpers.rst | 45 + docs/amazon_paapi.models.rst | 53 + docs/amazon_paapi.rst | 33 + docs/amazon_paapi.sdk.api.rst | 21 + docs/amazon_paapi.sdk.auth.rst | 21 + docs/amazon_paapi.sdk.models.rst | 717 +++++++ docs/amazon_paapi.sdk.rst | 47 + docs/amazon_paapi.tools.rst | 21 + docs/conf.py | 37 +- docs/modules.rst | 7 + docs/pa-paapi-icon.ico | Bin 0 -> 48712 bytes docs/pa-paapi-logo.png | Bin 0 -> 40655 bytes 14 files changed, 4483 insertions(+), 1 deletion(-) create mode 100644 docs/_static/dark.css create mode 100644 docs/amazon_paapi.errors.rst create mode 100644 docs/amazon_paapi.helpers.rst create mode 100644 docs/amazon_paapi.models.rst create mode 100644 docs/amazon_paapi.rst create mode 100644 docs/amazon_paapi.sdk.api.rst create mode 100644 docs/amazon_paapi.sdk.auth.rst create mode 100644 docs/amazon_paapi.sdk.models.rst create mode 100644 docs/amazon_paapi.sdk.rst create mode 100644 docs/amazon_paapi.tools.rst create mode 100644 docs/modules.rst create mode 100644 docs/pa-paapi-icon.ico create mode 100644 docs/pa-paapi-logo.png diff --git a/docs/_static/dark.css b/docs/_static/dark.css new file mode 100644 index 0000000..395c53d --- /dev/null +++ b/docs/_static/dark.css @@ -0,0 +1,3461 @@ +@media (prefers-color-scheme: dark) { + /* + Generated by https://darkreader.org + Instructions: Install the extension on a Chromium-based browser + Then do this to export the CSS: https://git.io/JOM6t and drop it here + Some color values where manually changed - just search for "/*" in this file and insert them in the new css + */ + /* User-Agent Style */ + html { + background-color: #181a1b !important; + } + html, body, input, textarea, select, button { + background-color: #181a1b; + } + html, body, input, textarea, select, button { + border-color: #736b5e; + color: #e8e6e3; + } + a { + color: #3391ff; + } + table { + border-color: #545b5e; + } + ::placeholder { + color: #b2aba1; + } + input:-webkit-autofill, + textarea:-webkit-autofill, + select:-webkit-autofill { + background-color: #555b00 !important; + color: #e8e6e3 !important; + } + ::-webkit-scrollbar { + background-color: #202324; + color: #aba499; + } + ::-webkit-scrollbar-thumb { + background-color: #454a4d; + } + ::-webkit-scrollbar-thumb:hover { + background-color: #575e62; + } + ::-webkit-scrollbar-thumb:active { + background-color: #484e51; + } + ::-webkit-scrollbar-corner { + background-color: #181a1b; + } + ::selection { + background-color: #004daa !important; + color: #e8e6e3 !important; + } + ::-moz-selection { + background-color: #004daa !important; + color: #e8e6e3 !important; + } + + /* Invert Style */ + .jfk-bubble.gtx-bubble, .captcheck_answer_label > input + img, span#closed_text > img[src^="https://www.gstatic.com/images/branding/googlelogo"], span[data-href^="https://www.hcaptcha.com/"] > #icon, #bit-notification-bar-iframe, embed[type="application/pdf"] { + filter: invert(100%) hue-rotate(180deg) contrast(90%) !important; + } + + /* Variables Style */ + :root { + --darkreader-neutral-background: #131516; + --darkreader-neutral-text: #d8d4cf; + --darkreader-selection-background: #004daa; + --darkreader-selection-text: #e8e6e3; + } + + /* Modified CSS */ + a:active, + a:hover { + outline-color: initial; + } + abbr[title] { + border-bottom-color: initial; + } + ins { + background-image: initial; + background-color: rgb(112, 112, 0); + text-decoration-color: initial; + } + ins, + mark { + color: rgb(232, 230, 227); + } + mark { + background-image: initial; + background-color: rgb(204, 204, 0); + } + dl, + ol, + ul { + list-style-image: none; + } + li { + list-style-image: initial; + } + img { + border-color: initial; + } + .chromeframe { + background-image: initial; + background-color: rgb(53, 57, 59); + color: rgb(232, 230, 227); + } + .ir { + border-color: initial; + background-color: transparent; + } + .visuallyhidden { + border-color: initial; + } + .fa-border { + border-color: rgb(53, 57, 59); + } + .fa-inverse { + color: rgb(232, 230, 227); + } + .sr-only { + border-color: initial; + } + .fa::before, + .icon::before, + .rst-content .admonition-title::before, + .rst-content .code-block-caption .headerlink::before, + .rst-content code.download span:first-child::before, + .rst-content dl dt .headerlink::before, + .rst-content h1 .headerlink::before, + .rst-content h2 .headerlink::before, + .rst-content h3 .headerlink::before, + .rst-content h4 .headerlink::before, + .rst-content h5 .headerlink::before, + .rst-content h6 .headerlink::before, + .rst-content p.caption .headerlink::before, + .rst-content table > caption .headerlink::before, + .rst-content tt.download span:first-child::before, + .wy-dropdown .caret::before, + .wy-inline-validate.wy-inline-validate-danger .wy-input-context::before, + .wy-inline-validate.wy-inline-validate-info .wy-input-context::before, + .wy-inline-validate.wy-inline-validate-success .wy-input-context::before, + .wy-inline-validate.wy-inline-validate-warning .wy-input-context::before, + .wy-menu-vertical li.current > a span.toctree-expand::before, + .wy-menu-vertical li.on a span.toctree-expand::before, + .wy-menu-vertical li span.toctree-expand::before { + text-decoration-color: inherit; + } + .rst-content .code-block-caption a .headerlink, + .rst-content a .admonition-title, + .rst-content code.download a span:first-child, + .rst-content dl dt a .headerlink, + .rst-content h1 a .headerlink, + .rst-content h2 a .headerlink, + .rst-content h3 a .headerlink, + .rst-content h4 a .headerlink, + .rst-content h5 a .headerlink, + .rst-content h6 a .headerlink, + .rst-content p.caption a .headerlink, + .rst-content table > caption a .headerlink, + .rst-content tt.download a span:first-child, + .wy-menu-vertical li.current > a span.toctree-expand, + .wy-menu-vertical li.on a span.toctree-expand, + .wy-menu-vertical li a span.toctree-expand, + a .fa, + a .icon, + a .rst-content .admonition-title, + a .rst-content .code-block-caption .headerlink, + a .rst-content code.download span:first-child, + a .rst-content dl dt .headerlink, + a .rst-content h1 .headerlink, + a .rst-content h2 .headerlink, + a .rst-content h3 .headerlink, + a .rst-content h4 .headerlink, + a .rst-content h5 .headerlink, + a .rst-content h6 .headerlink, + a .rst-content p.caption .headerlink, + a .rst-content table > caption .headerlink, + a .rst-content tt.download span:first-child, + a .wy-menu-vertical li span.toctree-expand { + text-decoration-color: inherit; + } + .rst-content .admonition, + .rst-content .admonition-todo, + .rst-content .attention, + .rst-content .caution, + .rst-content .danger, + .rst-content .error, + .rst-content .hint, + .rst-content .important, + .rst-content .note, + .rst-content .seealso, + .rst-content .tip, + .rst-content .warning, + .wy-alert { + background-image: initial; + background-color: rgb(32, 35, 36); + } + .rst-content .admonition-title, + .wy-alert-title { + color: rgb(232, 230, 227); + background-image: initial; + background-color: rgb(29, 91, 131); + } + .rst-content .danger, + .rst-content .error, + .rst-content .wy-alert-danger.admonition, + .rst-content .wy-alert-danger.admonition-todo, + .rst-content .wy-alert-danger.attention, + .rst-content .wy-alert-danger.caution, + .rst-content .wy-alert-danger.hint, + .rst-content .wy-alert-danger.important, + .rst-content .wy-alert-danger.note, + .rst-content .wy-alert-danger.seealso, + .rst-content .wy-alert-danger.tip, + .rst-content .wy-alert-danger.warning, + .wy-alert.wy-alert-danger { + background-image: initial; + background-color: rgb(52, 12, 8); + } + .rst-content .danger .admonition-title, + .rst-content .danger .wy-alert-title, + .rst-content .error .admonition-title, + .rst-content .error .wy-alert-title, + .rst-content .wy-alert-danger.admonition-todo .admonition-title, + .rst-content .wy-alert-danger.admonition-todo .wy-alert-title, + .rst-content .wy-alert-danger.admonition .admonition-title, + .rst-content .wy-alert-danger.admonition .wy-alert-title, + .rst-content .wy-alert-danger.attention .admonition-title, + .rst-content .wy-alert-danger.attention .wy-alert-title, + .rst-content .wy-alert-danger.caution .admonition-title, + .rst-content .wy-alert-danger.caution .wy-alert-title, + .rst-content .wy-alert-danger.hint .admonition-title, + .rst-content .wy-alert-danger.hint .wy-alert-title, + .rst-content .wy-alert-danger.important .admonition-title, + .rst-content .wy-alert-danger.important .wy-alert-title, + .rst-content .wy-alert-danger.note .admonition-title, + .rst-content .wy-alert-danger.note .wy-alert-title, + .rst-content .wy-alert-danger.seealso .admonition-title, + .rst-content .wy-alert-danger.seealso .wy-alert-title, + .rst-content .wy-alert-danger.tip .admonition-title, + .rst-content .wy-alert-danger.tip .wy-alert-title, + .rst-content .wy-alert-danger.warning .admonition-title, + .rst-content .wy-alert-danger.warning .wy-alert-title, + .rst-content .wy-alert.wy-alert-danger .admonition-title, + .wy-alert.wy-alert-danger .rst-content .admonition-title, + .wy-alert.wy-alert-danger .wy-alert-title { + background-image: initial; + background-color: rgb(108, 22, 13); + } + .rst-content .admonition-todo, + .rst-content .attention, + .rst-content .caution, + .rst-content .warning, + .rst-content .wy-alert-warning.admonition, + .rst-content .wy-alert-warning.danger, + .rst-content .wy-alert-warning.error, + .rst-content .wy-alert-warning.hint, + .rst-content .wy-alert-warning.important, + .rst-content .wy-alert-warning.note, + .rst-content .wy-alert-warning.seealso, + .rst-content .wy-alert-warning.tip, + .wy-alert.wy-alert-warning { + background-image: initial; + /* Manually overridden */ + background-color: rgb(37, 33, 30); + /*background-color: rgb(82, 53, 0);*/ + } + .rst-content .admonition-todo .admonition-title, + .rst-content .admonition-todo .wy-alert-title, + .rst-content .attention .admonition-title, + .rst-content .attention .wy-alert-title, + .rst-content .caution .admonition-title, + .rst-content .caution .wy-alert-title, + .rst-content .warning .admonition-title, + .rst-content .warning .wy-alert-title, + .rst-content .wy-alert-warning.admonition .admonition-title, + .rst-content .wy-alert-warning.admonition .wy-alert-title, + .rst-content .wy-alert-warning.danger .admonition-title, + .rst-content .wy-alert-warning.danger .wy-alert-title, + .rst-content .wy-alert-warning.error .admonition-title, + .rst-content .wy-alert-warning.error .wy-alert-title, + .rst-content .wy-alert-warning.hint .admonition-title, + .rst-content .wy-alert-warning.hint .wy-alert-title, + .rst-content .wy-alert-warning.important .admonition-title, + .rst-content .wy-alert-warning.important .wy-alert-title, + .rst-content .wy-alert-warning.note .admonition-title, + .rst-content .wy-alert-warning.note .wy-alert-title, + .rst-content .wy-alert-warning.seealso .admonition-title, + .rst-content .wy-alert-warning.seealso .wy-alert-title, + .rst-content .wy-alert-warning.tip .admonition-title, + .rst-content .wy-alert-warning.tip .wy-alert-title, + .rst-content .wy-alert.wy-alert-warning .admonition-title, + .wy-alert.wy-alert-warning .rst-content .admonition-title, + .wy-alert.wy-alert-warning .wy-alert-title { + background-image: initial; + background-color: rgb(123, 65, 14); + } + .rst-content .note, + .rst-content .seealso, + .rst-content .wy-alert-info.admonition, + .rst-content .wy-alert-info.admonition-todo, + .rst-content .wy-alert-info.attention, + .rst-content .wy-alert-info.caution, + .rst-content .wy-alert-info.danger, + .rst-content .wy-alert-info.error, + .rst-content .wy-alert-info.hint, + .rst-content .wy-alert-info.important, + .rst-content .wy-alert-info.tip, + .rst-content .wy-alert-info.warning, + .wy-alert.wy-alert-info { + background-image: initial; + background-color: rgb(32, 35, 36); + } + .rst-content .note .admonition-title, + .rst-content .note .wy-alert-title, + .rst-content .seealso .admonition-title, + .rst-content .seealso .wy-alert-title, + .rst-content .wy-alert-info.admonition-todo .admonition-title, + .rst-content .wy-alert-info.admonition-todo .wy-alert-title, + .rst-content .wy-alert-info.admonition .admonition-title, + .rst-content .wy-alert-info.admonition .wy-alert-title, + .rst-content .wy-alert-info.attention .admonition-title, + .rst-content .wy-alert-info.attention .wy-alert-title, + .rst-content .wy-alert-info.caution .admonition-title, + .rst-content .wy-alert-info.caution .wy-alert-title, + .rst-content .wy-alert-info.danger .admonition-title, + .rst-content .wy-alert-info.danger .wy-alert-title, + .rst-content .wy-alert-info.error .admonition-title, + .rst-content .wy-alert-info.error .wy-alert-title, + .rst-content .wy-alert-info.hint .admonition-title, + .rst-content .wy-alert-info.hint .wy-alert-title, + .rst-content .wy-alert-info.important .admonition-title, + .rst-content .wy-alert-info.important .wy-alert-title, + .rst-content .wy-alert-info.tip .admonition-title, + .rst-content .wy-alert-info.tip .wy-alert-title, + .rst-content .wy-alert-info.warning .admonition-title, + .rst-content .wy-alert-info.warning .wy-alert-title, + .rst-content .wy-alert.wy-alert-info .admonition-title, + .wy-alert.wy-alert-info .rst-content .admonition-title, + .wy-alert.wy-alert-info .wy-alert-title { + background-image: initial; + background-color: rgb(29, 91, 131); + } + .rst-content .hint, + .rst-content .important, + .rst-content .tip, + .rst-content .wy-alert-success.admonition, + .rst-content .wy-alert-success.admonition-todo, + .rst-content .wy-alert-success.attention, + .rst-content .wy-alert-success.caution, + .rst-content .wy-alert-success.danger, + .rst-content .wy-alert-success.error, + .rst-content .wy-alert-success.note, + .rst-content .wy-alert-success.seealso, + .rst-content .wy-alert-success.warning, + .wy-alert.wy-alert-success { + background-image: initial; + background-color: rgb(9, 66, 58); + } + .rst-content .hint .admonition-title, + .rst-content .hint .wy-alert-title, + .rst-content .important .admonition-title, + .rst-content .important .wy-alert-title, + .rst-content .tip .admonition-title, + .rst-content .tip .wy-alert-title, + .rst-content .wy-alert-success.admonition-todo .admonition-title, + .rst-content .wy-alert-success.admonition-todo .wy-alert-title, + .rst-content .wy-alert-success.admonition .admonition-title, + .rst-content .wy-alert-success.admonition .wy-alert-title, + .rst-content .wy-alert-success.attention .admonition-title, + .rst-content .wy-alert-success.attention .wy-alert-title, + .rst-content .wy-alert-success.caution .admonition-title, + .rst-content .wy-alert-success.caution .wy-alert-title, + .rst-content .wy-alert-success.danger .admonition-title, + .rst-content .wy-alert-success.danger .wy-alert-title, + .rst-content .wy-alert-success.error .admonition-title, + .rst-content .wy-alert-success.error .wy-alert-title, + .rst-content .wy-alert-success.note .admonition-title, + .rst-content .wy-alert-success.note .wy-alert-title, + .rst-content .wy-alert-success.seealso .admonition-title, + .rst-content .wy-alert-success.seealso .wy-alert-title, + .rst-content .wy-alert-success.warning .admonition-title, + .rst-content .wy-alert-success.warning .wy-alert-title, + .rst-content .wy-alert.wy-alert-success .admonition-title, + .wy-alert.wy-alert-success .rst-content .admonition-title, + .wy-alert.wy-alert-success .wy-alert-title { + background-image: initial; + background-color: rgb(21, 150, 125); + } + .rst-content .wy-alert-neutral.admonition, + .rst-content .wy-alert-neutral.admonition-todo, + .rst-content .wy-alert-neutral.attention, + .rst-content .wy-alert-neutral.caution, + .rst-content .wy-alert-neutral.danger, + .rst-content .wy-alert-neutral.error, + .rst-content .wy-alert-neutral.hint, + .rst-content .wy-alert-neutral.important, + .rst-content .wy-alert-neutral.note, + .rst-content .wy-alert-neutral.seealso, + .rst-content .wy-alert-neutral.tip, + .rst-content .wy-alert-neutral.warning, + .wy-alert.wy-alert-neutral { + background-image: initial; + background-color: rgb(27, 36, 36); + } + .rst-content .wy-alert-neutral.admonition-todo .admonition-title, + .rst-content .wy-alert-neutral.admonition-todo .wy-alert-title, + .rst-content .wy-alert-neutral.admonition .admonition-title, + .rst-content .wy-alert-neutral.admonition .wy-alert-title, + .rst-content .wy-alert-neutral.attention .admonition-title, + .rst-content .wy-alert-neutral.attention .wy-alert-title, + .rst-content .wy-alert-neutral.caution .admonition-title, + .rst-content .wy-alert-neutral.caution .wy-alert-title, + .rst-content .wy-alert-neutral.danger .admonition-title, + .rst-content .wy-alert-neutral.danger .wy-alert-title, + .rst-content .wy-alert-neutral.error .admonition-title, + .rst-content .wy-alert-neutral.error .wy-alert-title, + .rst-content .wy-alert-neutral.hint .admonition-title, + .rst-content .wy-alert-neutral.hint .wy-alert-title, + .rst-content .wy-alert-neutral.important .admonition-title, + .rst-content .wy-alert-neutral.important .wy-alert-title, + .rst-content .wy-alert-neutral.note .admonition-title, + .rst-content .wy-alert-neutral.note .wy-alert-title, + .rst-content .wy-alert-neutral.seealso .admonition-title, + .rst-content .wy-alert-neutral.seealso .wy-alert-title, + .rst-content .wy-alert-neutral.tip .admonition-title, + .rst-content .wy-alert-neutral.tip .wy-alert-title, + .rst-content .wy-alert-neutral.warning .admonition-title, + .rst-content .wy-alert-neutral.warning .wy-alert-title, + .rst-content .wy-alert.wy-alert-neutral .admonition-title, + .wy-alert.wy-alert-neutral .rst-content .admonition-title, + .wy-alert.wy-alert-neutral .wy-alert-title { + color: rgb(192, 186, 178); + background-image: initial; + background-color: rgb(40, 43, 45); + } + .rst-content .wy-alert-neutral.admonition-todo a, + .rst-content .wy-alert-neutral.admonition a, + .rst-content .wy-alert-neutral.attention a, + .rst-content .wy-alert-neutral.caution a, + .rst-content .wy-alert-neutral.danger a, + .rst-content .wy-alert-neutral.error a, + .rst-content .wy-alert-neutral.hint a, + .rst-content .wy-alert-neutral.important a, + .rst-content .wy-alert-neutral.note a, + .rst-content .wy-alert-neutral.seealso a, + .rst-content .wy-alert-neutral.tip a, + .rst-content .wy-alert-neutral.warning a, + .wy-alert.wy-alert-neutral a { + color: rgb(84, 164, 217); + } + .wy-tray-container li { + background-image: initial; + background-color: transparent; + color: rgb(232, 230, 227); + box-shadow: rgba(0, 0, 0, 0.1) 0px 5px 5px 0px; + } + .wy-tray-container li.wy-tray-item-success { + background-image: initial; + background-color: rgb(31, 139, 77); + } + .wy-tray-container li.wy-tray-item-info { + background-image: initial; + background-color: rgb(33, 102, 148); + } + .wy-tray-container li.wy-tray-item-warning { + background-image: initial; + background-color: rgb(178, 94, 20); + } + .wy-tray-container li.wy-tray-item-danger { + background-image: initial; + background-color: rgb(162, 33, 20); + } + .btn { + color: rgb(232, 230, 227); + border-color: rgba(140, 130, 115, 0.1); + background-color: rgb(31, 139, 77); + text-decoration-color: initial; + box-shadow: rgba(24, 26, 27, 0.5) 0px 1px 2px -1px inset, + rgba(0, 0, 0, 0.1) 0px -2px 0px 0px inset; + } + .btn-hover { + background-image: initial; + background-color: rgb(37, 114, 165); + color: rgb(232, 230, 227); + } + .btn:hover { + background-image: initial; + background-color: rgb(35, 156, 86); + color: rgb(232, 230, 227); + } + .btn:focus { + background-image: initial; + background-color: rgb(35, 156, 86); + outline-color: initial; + } + .btn:active { + box-shadow: rgba(0, 0, 0, 0.05) 0px -1px 0px 0px inset, + rgba(0, 0, 0, 0.1) 0px 2px 0px 0px inset; + } + .btn:visited { + color: rgb(232, 230, 227); + } + .btn-disabled, + .btn-disabled:active, + .btn-disabled:focus, + .btn-disabled:hover, + .btn:disabled { + background-image: none; + box-shadow: none; + } + .btn-info { + background-color: rgb(33, 102, 148) !important; + } + .btn-info:hover { + background-color: rgb(37, 114, 165) !important; + } + .btn-neutral { + background-color: rgb(27, 36, 36) !important; + color: rgb(192, 186, 178) !important; + } + .btn-neutral:hover { + color: rgb(192, 186, 178); + background-color: rgb(34, 44, 44) !important; + } + .btn-neutral:visited { + color: rgb(192, 186, 178) !important; + } + .btn-success { + background-color: rgb(31, 139, 77) !important; + } + .btn-success:hover { + background-color: rgb(27, 122, 68) !important; + } + .btn-danger { + background-color: rgb(162, 33, 20) !important; + } + .btn-danger:hover { + background-color: rgb(149, 30, 18) !important; + } + .btn-warning { + background-color: rgb(178, 94, 20) !important; + } + .btn-warning:hover { + background-color: rgb(165, 87, 18) !important; + } + .btn-invert { + background-color: rgb(26, 28, 29); + } + .btn-invert:hover { + background-color: rgb(35, 38, 40) !important; + } + .btn-link { + color: rgb(84, 164, 217); + box-shadow: none; + background-color: transparent !important; + border-color: transparent !important; + } + .btn-link:active, + .btn-link:hover { + box-shadow: none; + background-color: transparent !important; + color: rgb(79, 162, 216) !important; + } + .btn-link:visited { + color: rgb(164, 103, 188); + } + .wy-dropdown-menu { + background-image: initial; + background-color: rgb(26, 28, 29); + border-color: rgb(60, 65, 67); + box-shadow: rgba(0, 0, 0, 0.1) 0px 2px 2px 0px; + } + .wy-dropdown-menu > dd > a { + color: rgb(192, 186, 178); + } + .wy-dropdown-menu > dd > a:hover { + background-image: initial; + background-color: rgb(33, 102, 148); + color: rgb(232, 230, 227); + } + .wy-dropdown-menu > dd.divider { + border-top-color: rgb(60, 65, 67); + } + .wy-dropdown-menu > dd.call-to-action { + background-image: initial; + background-color: rgb(40, 43, 45); + } + .wy-dropdown-menu > dd.call-to-action:hover { + background-image: initial; + background-color: rgb(40, 43, 45); + } + .wy-dropdown-menu > dd.call-to-action .btn { + color: rgb(232, 230, 227); + } + .wy-dropdown.wy-dropdown-bubble .wy-dropdown-menu { + background-image: initial; + background-color: rgb(26, 28, 29); + } + .wy-dropdown.wy-dropdown-bubble .wy-dropdown-menu a:hover { + background-image: initial; + background-color: rgb(33, 102, 148); + color: rgb(232, 230, 227); + } + .wy-dropdown-arrow::before { + border-bottom-color: rgb(51, 55, 57); + border-left-color: transparent; + border-right-color: transparent; + } + fieldset, + legend { + border-color: initial; + } + label { + color: rgb(200, 195, 188); + } + .wy-control-group.wy-control-group-required > label::after { + color: rgb(233, 88, 73); + } + .wy-form-message-inline { + color: rgb(168, 160, 149); + } + .wy-form-message { + color: rgb(168, 160, 149); + } + input[type="color"], input[type="date"], input[type="datetime-local"], input[type="datetime"], input[type="email"], input[type="month"], input[type="number"], input[type="password"], input[type="search"], input[type="tel"], input[type="text"], input[type="time"], input[type="url"], input[type="week"] { + border-color: rgb(62, 68, 70); + box-shadow: rgb(43, 47, 49) 0px 1px 3px inset; + } + input[type="color"]:focus, input[type="date"]:focus, input[type="datetime-local"]:focus, input[type="datetime"]:focus, input[type="email"]:focus, input[type="month"]:focus, input[type="number"]:focus, input[type="password"]:focus, input[type="search"]:focus, input[type="tel"]:focus, input[type="text"]:focus, input[type="time"]:focus, input[type="url"]:focus, input[type="week"]:focus { + outline-color: initial; + border-color: rgb(123, 114, 101); + } + input.no-focus:focus { + border-color: rgb(62, 68, 70) !important; + } + input[type="checkbox"]:focus, input[type="file"]:focus, input[type="radio"]:focus { + outline-color: rgb(13, 113, 167); + } + input[type="color"][disabled], input[type="date"][disabled], input[type="datetime-local"][disabled], input[type="datetime"][disabled], input[type="email"][disabled], input[type="month"][disabled], input[type="number"][disabled], input[type="password"][disabled], input[type="search"][disabled], input[type="tel"][disabled], input[type="text"][disabled], input[type="time"][disabled], input[type="url"][disabled], input[type="week"][disabled] { + background-color: rgb(27, 29, 30); + } + input:focus:invalid, + select:focus:invalid, + textarea:focus:invalid { + color: rgb(233, 88, 73); + border-color: rgb(149, 31, 18); + } + input:focus:invalid:focus, + select:focus:invalid:focus, + textarea:focus:invalid:focus { + border-color: rgb(149, 31, 18); + } + input[type="checkbox"]:focus:invalid:focus, input[type="file"]:focus:invalid:focus, input[type="radio"]:focus:invalid:focus { + outline-color: rgb(149, 31, 18); + } + select, + textarea { + border-color: rgb(62, 68, 70); + box-shadow: rgb(43, 47, 49) 0px 1px 3px inset; + } + select { + border-color: rgb(62, 68, 70); + background-color: rgb(24, 26, 27); + } + select:focus, + textarea:focus { + outline-color: initial; + } + input[readonly], + select[disabled], + select[readonly], + textarea[disabled], + textarea[readonly] { + background-color: rgb(27, 29, 30); + } + .wy-checkbox, + .wy-radio { + color: rgb(192, 186, 178); + } + .wy-input-prefix .wy-input-context, + .wy-input-suffix .wy-input-context { + background-color: rgb(27, 36, 36); + border-color: rgb(62, 68, 70); + color: rgb(168, 160, 149); + } + .wy-input-suffix .wy-input-context { + border-left-color: initial; + } + .wy-input-prefix .wy-input-context { + border-right-color: initial; + } + .wy-switch::before { + background-image: initial; + background-color: rgb(53, 57, 59); + } + .wy-switch::after { + background-image: initial; + background-color: rgb(82, 88, 92); + } + .wy-switch span { + color: rgb(200, 195, 188); + } + .wy-switch.active::before { + background-image: initial; + background-color: rgb(24, 106, 58); + } + .wy-switch.active::after { + background-image: initial; + background-color: rgb(31, 139, 77); + } + .wy-control-group.wy-control-group-error .wy-form-message, + .wy-control-group.wy-control-group-error > label { + color: rgb(233, 88, 73); + } + .wy-control-group.wy-control-group-error input[type="color"], .wy-control-group.wy-control-group-error input[type="date"], .wy-control-group.wy-control-group-error input[type="datetime-local"], .wy-control-group.wy-control-group-error input[type="datetime"], .wy-control-group.wy-control-group-error input[type="email"], .wy-control-group.wy-control-group-error input[type="month"], .wy-control-group.wy-control-group-error input[type="number"], .wy-control-group.wy-control-group-error input[type="password"], .wy-control-group.wy-control-group-error input[type="search"], .wy-control-group.wy-control-group-error input[type="tel"], .wy-control-group.wy-control-group-error input[type="text"], .wy-control-group.wy-control-group-error input[type="time"], .wy-control-group.wy-control-group-error input[type="url"], .wy-control-group.wy-control-group-error input[type="week"], + .wy-control-group.wy-control-group-error textarea { + border-color: rgb(149, 31, 18); + } + .wy-inline-validate.wy-inline-validate-success .wy-input-context { + color: rgb(92, 218, 145); + } + .wy-inline-validate.wy-inline-validate-danger .wy-input-context { + color: rgb(233, 88, 73); + } + .wy-inline-validate.wy-inline-validate-warning .wy-input-context { + color: rgb(232, 138, 54); + } + .wy-inline-validate.wy-inline-validate-info .wy-input-context { + color: rgb(84, 164, 217); + } + .rst-content table.docutils caption, + .rst-content table.field-list caption, + .wy-table caption { + color: rgb(232, 230, 227); + } + .rst-content table.docutils thead, + .rst-content table.field-list thead, + .wy-table thead { + color: rgb(232, 230, 227); + } + .rst-content table.docutils thead th, + .rst-content table.field-list thead th, + .wy-table thead th { + border-bottom-color: rgb(56, 61, 63); + } + .rst-content table.docutils td, + .rst-content table.field-list td, + .wy-table td { + background-color: transparent; + } + .wy-table-secondary { + color: rgb(152, 143, 129); + } + .wy-table-tertiary { + color: rgb(152, 143, 129); + } + .rst-content table.docutils:not(.field-list) tr:nth-child(2n-1) td, + .wy-table-backed, + .wy-table-odd td, + .wy-table-striped tr:nth-child(2n-1) td { + background-color: rgb(27, 36, 36); + } + .rst-content table.docutils, + .wy-table-bordered-all { + border-color: rgb(56, 61, 63); + } + .rst-content table.docutils td, + .wy-table-bordered-all td { + border-bottom-color: rgb(56, 61, 63); + border-left-color: rgb(56, 61, 63); + } + .wy-table-bordered { + border-color: rgb(56, 61, 63); + } + .wy-table-bordered-rows td { + border-bottom-color: rgb(56, 61, 63); + } + .wy-table-horizontal td, + .wy-table-horizontal th { + border-bottom-color: rgb(56, 61, 63); + } + a { + color: rgb(84, 164, 217); + text-decoration-color: initial; + } + a:hover { + color: rgb(68, 156, 214); + } + a:visited { + color: rgb(164, 103, 188); + } + body { + color: rgb(192, 186, 178); + background-image: initial; + background-color: rgb(33, 35, 37); + } + .wy-text-strike { + text-decoration-color: initial; + } + .wy-text-warning { + color: rgb(232, 138, 54) !important; + } + a.wy-text-warning:hover { + color: rgb(236, 157, 87) !important; + } + .wy-text-info { + color: rgb(84, 164, 217) !important; + } + a.wy-text-info:hover { + color: rgb(79, 162, 216) !important; + } + .wy-text-success { + color: rgb(92, 218, 145) !important; + } + a.wy-text-success:hover { + color: rgb(73, 214, 133) !important; + } + .wy-text-danger { + color: rgb(233, 88, 73) !important; + } + a.wy-text-danger:hover { + color: rgb(237, 118, 104) !important; + } + .wy-text-neutral { + color: rgb(192, 186, 178) !important; + } + a.wy-text-neutral:hover { + color: rgb(176, 169, 159) !important; + } + hr { + border-right-color: initial; + border-bottom-color: initial; + border-left-color: initial; + border-top-color: rgb(56, 61, 63); + } + .rst-content code, + .rst-content tt, + code { + background-image: initial; + background-color: rgb(24, 26, 27); + border-color: rgb(56, 61, 63); + color: rgb(233, 88, 73); + } + .rst-content .section ul, + .rst-content .toctree-wrapper ul, + .wy-plain-list-disc, + article ul { + list-style-image: initial; + } + .rst-content .section ul li, + .rst-content .toctree-wrapper ul li, + .wy-plain-list-disc li, + article ul li { + list-style-image: initial; + } + .rst-content .section ul li li, + .rst-content .toctree-wrapper ul li li, + .wy-plain-list-disc li li, + article ul li li { + list-style-image: initial; + } + .rst-content .section ul li li li, + .rst-content .toctree-wrapper ul li li li, + .wy-plain-list-disc li li li, + article ul li li li { + list-style-image: initial; + } + .rst-content .section ul li ol li, + .rst-content .toctree-wrapper ul li ol li, + .wy-plain-list-disc li ol li, + article ul li ol li { + list-style-image: initial; + } + .rst-content .section ol, + .rst-content ol.arabic, + .wy-plain-list-decimal, + article ol { + list-style-image: initial; + } + .rst-content .section ol li, + .rst-content ol.arabic li, + .wy-plain-list-decimal li, + article ol li { + list-style-image: initial; + } + .rst-content .section ol li ul li, + .rst-content ol.arabic li ul li, + .wy-plain-list-decimal li ul li, + article ol li ul li { + list-style-image: initial; + } + .rst-content .wy-breadcrumbs li tt, + .wy-breadcrumbs li .rst-content tt, + .wy-breadcrumbs li code { + border-color: initial; + background-image: none; + background-color: initial; + } + .rst-content .wy-breadcrumbs li tt.literal, + .wy-breadcrumbs li .rst-content tt.literal, + .wy-breadcrumbs li code.literal { + color: rgb(192, 186, 178); + } + .wy-breadcrumbs-extra { + color: rgb(184, 178, 169); + } + .wy-menu a:hover { + text-decoration-color: initial; + } + .wy-menu-horiz li:hover { + background-image: initial; + background-color: rgba(24, 26, 27, 0.1); + } + .wy-menu-horiz li.divide-left { + border-left-color: rgb(119, 110, 98); + } + .wy-menu-horiz li.divide-right { + border-right-color: rgb(119, 110, 98); + } + .wy-menu-vertical header, + .wy-menu-vertical p.caption { + color: rgb(94, 170, 219); + } + .wy-menu-vertical li.divide-top { + border-top-color: rgb(119, 110, 98); + } + .wy-menu-vertical li.divide-bottom { + border-bottom-color: rgb(119, 110, 98); + } + .wy-menu-vertical li.current { + background-image: initial; + background-color: rgb(40, 43, 45); + } + .wy-menu-vertical li.current a { + color: rgb(152, 143, 129); + border-right-color: rgb(63, 69, 71); + } + .wy-menu-vertical li.current a:hover { + background-image: initial; + background-color: rgb(47, 51, 53); + } + .rst-content .wy-menu-vertical li tt, + .wy-menu-vertical li .rst-content tt, + .wy-menu-vertical li code { + border-color: initial; + background-image: inherit; + background-color: inherit; + color: inherit; + } + .wy-menu-vertical li span.toctree-expand { + color: rgb(183, 177, 168); + } + .wy-menu-vertical li.current > a, + .wy-menu-vertical li.on a { + color: rgb(192, 186, 178); + background-image: initial; + background-color: rgb(26, 28, 29); + border-color: initial; + } + .wy-menu-vertical li.current > a:hover, + .wy-menu-vertical li.on a:hover { + background-image: initial; + background-color: rgb(26, 28, 29); + } + .wy-menu-vertical li.current > a:hover span.toctree-expand, + .wy-menu-vertical li.on a:hover span.toctree-expand { + color: rgb(152, 143, 129); + } + .wy-menu-vertical li.current > a span.toctree-expand, + .wy-menu-vertical li.on a span.toctree-expand { + color: rgb(200, 195, 188); + } + .wy-menu-vertical li.toctree-l1.current > a { + border-bottom-color: rgb(63, 69, 71); + border-top-color: rgb(63, 69, 71); + } + .wy-menu-vertical li.toctree-l2 a, + .wy-menu-vertical li.toctree-l3 a, + .wy-menu-vertical li.toctree-l4 a, + .wy-menu-vertical li.toctree-l5 a, + .wy-menu-vertical li.toctree-l6 a, + .wy-menu-vertical li.toctree-l7 a, + .wy-menu-vertical li.toctree-l8 a, + .wy-menu-vertical li.toctree-l9 a, + .wy-menu-vertical li.toctree-l10 a { + color: rgb(192, 186, 178); + } + .wy-menu-vertical li.toctree-l2 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l3 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l4 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l5 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l6 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l7 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l8 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l9 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l10 a:hover span.toctree-expand { + color: rgb(152, 143, 129); + } + .wy-menu-vertical li.toctree-l2.current > a, + .wy-menu-vertical li.toctree-l2.current li.toctree-l3 > a { + background-image: initial; + background-color: rgb(54, 59, 61); + } + .wy-menu-vertical li.toctree-l2 span.toctree-expand { + color: rgb(174, 167, 156); + } + .wy-menu-vertical li.toctree-l3.current > a, + .wy-menu-vertical li.toctree-l3.current li.toctree-l4 > a { + background-image: initial; + background-color: rgb(61, 66, 69); + } + .wy-menu-vertical li.toctree-l3 span.toctree-expand { + color: rgb(166, 158, 146); + } + .wy-menu-vertical li ul li a { + color: rgb(208, 204, 198); + } + .wy-menu-vertical a { + color: rgb(208, 204, 198); + } + .wy-menu-vertical a:hover { + background-color: rgb(57, 62, 64); + } + .wy-menu-vertical a:hover span.toctree-expand { + color: rgb(208, 204, 198); + } + .wy-menu-vertical a:active { + background-color: rgb(33, 102, 148); + color: rgb(232, 230, 227); + } + .wy-menu-vertical a:active span.toctree-expand { + color: rgb(232, 230, 227); + } + .wy-side-nav-search { + background-color: rgb(33, 102, 148); + color: rgb(230, 228, 225); + } + .wy-side-nav-search input[type="text"] { + border-color: rgb(35, 111, 160); + } + .wy-side-nav-search img { + background-color: rgb(33, 102, 148); + } + .wy-side-nav-search .wy-dropdown > a, + .wy-side-nav-search > a { + color: rgb(230, 228, 225); + } + .wy-side-nav-search .wy-dropdown > a:hover, + .wy-side-nav-search > a:hover { + background-image: initial; + background-color: rgba(24, 26, 27, 0.1); + } + .wy-side-nav-search .wy-dropdown > a img.logo, + .wy-side-nav-search > a img.logo { + background-image: initial; + background-color: transparent; + } + .wy-side-nav-search > div.version { + color: rgba(232, 230, 227, 0.3); + } + .wy-nav .wy-menu-vertical header { + color: rgb(84, 164, 217); + } + .wy-nav .wy-menu-vertical a { + color: rgb(184, 178, 169); + } + .wy-nav .wy-menu-vertical a:hover { + background-color: rgb(33, 102, 148); + color: rgb(232, 230, 227); + } + .wy-body-for-nav { + background-image: initial; + background-color: rgb(26, 28, 29); + } + .wy-nav-side { + color: rgb(169, 161, 150); + background-image: initial; + background-color: rgb(38, 41, 43); + } + .wy-nav-top { + background-image: initial; + background-color: rgb(33, 102, 148); + color: rgb(232, 230, 227); + } + .wy-nav-top a { + color: rgb(232, 230, 227); + } + .wy-nav-top img { + background-color: rgb(33, 102, 148); + } + .wy-nav-content-wrap { + background-image: initial; + background-color: rgb(26, 28, 29); + } + .wy-body-mask { + background-image: initial; + background-color: rgba(0, 0, 0, 0.2); + } + footer { + color: rgb(152, 143, 129); + } + .rst-content footer span.commit tt, + footer span.commit .rst-content tt, + footer span.commit code { + background-image: none; + background-color: initial; + border-color: initial; + color: rgb(152, 143, 129); + } + #search-results .search li { + border-bottom-color: rgb(56, 61, 63); + } + #search-results .search li:first-child { + border-top-color: rgb(56, 61, 63); + } + #search-results .context { + color: rgb(152, 143, 129); + } + .wy-body-for-nav { + background-image: initial; + background-color: rgb(26, 28, 29); + } + @media screen and (min-width: 1100px) { + .wy-nav-content-wrap { + background-image: initial; + background-color: rgba(0, 0, 0, 0.05); + } + .wy-nav-content { + background-image: initial; + background-color: rgb(26, 28, 29); + } + } + .rst-versions { + color: rgb(230, 228, 225); + background-image: initial; + background-color: rgb(23, 24, 25); + } + .rst-versions a { + color: rgb(84, 164, 217); + text-decoration-color: initial; + } + .rst-versions .rst-current-version { + background-color: rgb(29, 31, 32); + color: rgb(92, 218, 145); + } + .rst-content .code-block-caption .rst-versions .rst-current-version .headerlink, + .rst-content .rst-versions .rst-current-version .admonition-title, + .rst-content code.download .rst-versions .rst-current-version span:first-child, + .rst-content dl dt .rst-versions .rst-current-version .headerlink, + .rst-content h1 .rst-versions .rst-current-version .headerlink, + .rst-content h2 .rst-versions .rst-current-version .headerlink, + .rst-content h3 .rst-versions .rst-current-version .headerlink, + .rst-content h4 .rst-versions .rst-current-version .headerlink, + .rst-content h5 .rst-versions .rst-current-version .headerlink, + .rst-content h6 .rst-versions .rst-current-version .headerlink, + .rst-content p.caption .rst-versions .rst-current-version .headerlink, + .rst-content table > caption .rst-versions .rst-current-version .headerlink, + .rst-content tt.download .rst-versions .rst-current-version span:first-child, + .rst-versions .rst-current-version .fa, + .rst-versions .rst-current-version .icon, + .rst-versions .rst-current-version .rst-content .admonition-title, + .rst-versions .rst-current-version .rst-content .code-block-caption .headerlink, + .rst-versions .rst-current-version .rst-content code.download span:first-child, + .rst-versions .rst-current-version .rst-content dl dt .headerlink, + .rst-versions .rst-current-version .rst-content h1 .headerlink, + .rst-versions .rst-current-version .rst-content h2 .headerlink, + .rst-versions .rst-current-version .rst-content h3 .headerlink, + .rst-versions .rst-current-version .rst-content h4 .headerlink, + .rst-versions .rst-current-version .rst-content h5 .headerlink, + .rst-versions .rst-current-version .rst-content h6 .headerlink, + .rst-versions .rst-current-version .rst-content p.caption .headerlink, + .rst-versions .rst-current-version .rst-content table > caption .headerlink, + .rst-versions .rst-current-version .rst-content tt.download span:first-child, + .rst-versions .rst-current-version .wy-menu-vertical li span.toctree-expand, + .wy-menu-vertical li .rst-versions .rst-current-version span.toctree-expand { + color: rgb(230, 228, 225); + } + .rst-versions .rst-current-version.rst-out-of-date { + background-color: rgb(162, 33, 20); + color: rgb(232, 230, 227); + } + .rst-versions .rst-current-version.rst-active-old-version { + background-color: rgb(192, 156, 11); + color: rgb(232, 230, 227); + } + .rst-versions .rst-other-versions { + color: rgb(152, 143, 129); + } + .rst-versions .rst-other-versions hr { + border-right-color: initial; + border-bottom-color: initial; + border-left-color: initial; + border-top-color: rgb(119, 111, 98); + } + .rst-versions .rst-other-versions dd a { + color: rgb(230, 228, 225); + } + .rst-versions.rst-badge { + border-color: initial; + } + .rst-content abbr[title] { + text-decoration-color: initial; + } + .rst-content.style-external-links a.reference.external::after { + color: rgb(184, 178, 169); + } + .rst-content div[class^="highlight"], + .rst-content pre.literal-block { + border-color: rgb(56, 61, 63); + } + .rst-content div[class^="highlight"] div[class^="highlight"], .rst-content pre.literal-block div[class^="highlight"] { + border-color: initial; + } + .rst-content .linenodiv pre { + border-right-color: rgb(54, 59, 61); + } + .rst-content .admonition table { + border-color: rgba(140, 130, 115, 0.1); + } + .rst-content .admonition table td, + .rst-content .admonition table th { + background-image: initial !important; + background-color: transparent !important; + border-color: rgba(140, 130, 115, 0.1) !important; + } + .rst-content .section ol.loweralpha, + .rst-content .section ol.loweralpha > li { + list-style-image: initial; + } + .rst-content .section ol.upperalpha, + .rst-content .section ol.upperalpha > li { + list-style-image: initial; + } + .rst-content .toc-backref { + color: rgb(192, 186, 178); + } + .rst-content .sidebar { + background-image: initial; + background-color: rgb(27, 36, 36); + border-color: rgb(56, 61, 63); + } + .rst-content .sidebar .sidebar-title { + background-image: initial; + background-color: rgb(40, 43, 45); + } + .rst-content .highlighted { + background-image: initial; + background-color: rgb(192, 156, 11); + box-shadow: rgb(192, 156, 11) 0px 0px 0px 2px; + } + html.writer-html4 .rst-content table.docutils.citation, + html.writer-html4 .rst-content table.docutils.footnote { + background-image: none; + background-color: initial; + border-color: initial; + } + html.writer-html4 .rst-content table.docutils.citation td, + html.writer-html4 .rst-content table.docutils.citation tr, + html.writer-html4 .rst-content table.docutils.footnote td, + html.writer-html4 .rst-content table.docutils.footnote tr { + border-color: initial; + background-color: transparent !important; + } + .rst-content table.docutils.footnote, + html.writer-html4 .rst-content table.docutils.citation, + html.writer-html5 .rst-content dl.footnote { + color: rgb(152, 143, 129); + } + .rst-content table.docutils.footnote code, + .rst-content table.docutils.footnote tt, + html.writer-html4 .rst-content table.docutils.citation code, + html.writer-html4 .rst-content table.docutils.citation tt, + html.writer-html5 .rst-content dl.footnote code, + html.writer-html5 .rst-content dl.footnote tt { + color: rgb(178, 172, 162); + } + .rst-content table.docutils th { + border-color: rgb(56, 61, 63); + } + html.writer-html5 .rst-content table.docutils th { + border-color: rgb(56, 61, 63); + } + .rst-content table.field-list, + .rst-content table.field-list td { + border-color: initial; + } + .rst-content code, + .rst-content tt { + color: rgb(232, 230, 227); + } + .rst-content code.literal, + .rst-content tt.literal { + /* Manually overridden */ + color: rgb(228, 138, 128); + /*color: rgb(233, 88, 73);*/ + } + .rst-content code.xref, + .rst-content tt.xref, + a .rst-content code, + a .rst-content tt { + color: rgb(192, 186, 178); + } + .rst-content a code, + .rst-content a tt { + color: rgb(84, 164, 217); + } + html.writer-html4 .rst-content dl:not(.docutils) > dt, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) > dt { + background-image: initial; + background-color: rgb(32, 35, 36); + color: rgb(84, 164, 217); + border-top-color: rgb(28, 89, 128); + } + html.writer-html4 .rst-content dl:not(.docutils) > dt::before, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) > dt::before { + color: rgb(109, 178, 223); + } + html.writer-html4 .rst-content dl:not(.docutils) > dt .headerlink, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) > dt .headerlink { + color: rgb(192, 186, 178); + } + html.writer-html4 .rst-content dl:not(.docutils) dl:not(.field-list) > dt, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) dl:not(.field-list) > dt { + border-top-color: initial; + border-right-color: initial; + border-bottom-color: initial; + border-left-color: rgb(62, 68, 70); + background-image: initial; + background-color: rgb(32, 35, 37); + color: rgb(178, 172, 162); + } + html.writer-html4 .rst-content dl:not(.docutils) dl:not(.field-list) > dt .headerlink, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) dl:not(.field-list) > dt .headerlink { + color: rgb(192, 186, 178); + } + html.writer-html4 .rst-content dl:not(.docutils) code.descclassname, + html.writer-html4 .rst-content dl:not(.docutils) code.descname, + html.writer-html4 .rst-content dl:not(.docutils) tt.descclassname, + html.writer-html4 .rst-content dl:not(.docutils) tt.descname, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) code.descclassname, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) code.descname, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) tt.descclassname, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) tt.descname { + background-color: transparent; + border-color: initial; + } + html.writer-html4 .rst-content dl:not(.docutils) .optional, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) .optional { + color: rgb(232, 230, 227); + } + .rst-content .viewcode-back, + .rst-content .viewcode-link { + color: rgb(92, 218, 145); + } + .rst-content code.download, + .rst-content tt.download { + background-image: inherit; + background-color: inherit; + color: inherit; + border-color: inherit; + } + .rst-content .guilabel { + border-color: rgb(27, 84, 122); + background-image: initial; + background-color: rgb(32, 35, 36); + } + span[id*="MathJax-Span"] { + color: rgb(192, 186, 178); + } + td.linenos pre { + color: rgb(232, 230, 227); + background-color: rgb(32, 35, 37); + } + span.linenos { + color: rgb(232, 230, 227); + background-color: rgb(32, 35, 37); + } + td.linenos pre.special { + color: rgb(232, 230, 227); + background-color: rgb(89, 89, 0); + } + span.linenos.special { + color: rgb(232, 230, 227); + background-color: rgb(89, 89, 0); + } + .highlight .hll { + background-color: rgb(82, 82, 0); + } + .highlight { + background-image: initial; + /* Manually overridden */ + background-color: rgb(44 47 37); + /*background-color: rgb(61, 82, 0);*/ + } + .highlight .c { + color: rgb(119, 179, 195); + } + .highlight .err { + border-color: rgb(179, 0, 0); + } + .highlight .k { + color: rgb(126, 255, 163); + } + .highlight .o { + color: rgb(168, 160, 149); + } + .highlight .ch { + color: rgb(119, 179, 195); + } + .highlight .cm { + color: rgb(119, 179, 195); + } + .highlight .cp { + color: rgb(126, 255, 163); + } + .highlight .cpf { + color: rgb(119, 179, 195); + } + .highlight .c1 { + color: rgb(119, 179, 195); + } + .highlight .cs { + color: rgb(119, 179, 195); + background-color: rgb(60, 0, 0); + } + .highlight .gd { + color: rgb(255, 92, 92); + } + .highlight .gr { + color: rgb(255, 26, 26); + } + .highlight .gh { + color: rgb(127, 174, 255); + } + .highlight .gi { + color: rgb(92, 255, 92); + } + .highlight .go { + color: rgb(200, 195, 188); + } + .highlight .gp { + color: rgb(246, 147, 68); + } + .highlight .gu { + color: rgb(255, 114, 255); + } + .highlight .gt { + color: rgb(71, 160, 255); + } + .highlight .kc { + color: rgb(126, 255, 163); + } + .highlight .kd { + color: rgb(126, 255, 163); + } + .highlight .kn { + color: rgb(126, 255, 163); + } + .highlight .kp { + color: rgb(126, 255, 163); + } + .highlight .kr { + color: rgb(126, 255, 163); + } + .highlight .kt { + color: rgb(255, 137, 103); + } + .highlight .m { + color: rgb(125, 222, 174); + } + .highlight .s { + color: rgb(123, 166, 202); + } + .highlight .na { + color: rgb(123, 166, 202); + } + .highlight .nb { + color: rgb(126, 255, 163); + } + .highlight .nc { + color: rgb(81, 194, 242); + } + .highlight .no { + color: rgb(103, 177, 215); + } + .highlight .nd { + color: rgb(178, 172, 162); + } + .highlight .ni { + color: rgb(217, 100, 73); + } + .highlight .ne { + color: rgb(126, 255, 163); + } + .highlight .nf { + color: rgb(131, 186, 249); + } + .highlight .nl { + color: rgb(137, 193, 255); + } + .highlight .nn { + color: rgb(81, 194, 242); + } + .highlight .nt { + color: rgb(138, 191, 249); + } + .highlight .nv { + color: rgb(190, 103, 215); + } + .highlight .ow { + color: rgb(126, 255, 163); + } + .highlight .w { + color: rgb(189, 183, 175); + } + .highlight .mb { + color: rgb(125, 222, 174); + } + .highlight .mf { + color: rgb(125, 222, 174); + } + .highlight .mh { + color: rgb(125, 222, 174); + } + .highlight .mi { + color: rgb(125, 222, 174); + } + .highlight .mo { + color: rgb(125, 222, 174); + } + .highlight .sa { + color: rgb(123, 166, 202); + } + .highlight .sb { + color: rgb(123, 166, 202); + } + .highlight .sc { + color: rgb(123, 166, 202); + } + .highlight .dl { + color: rgb(123, 166, 202); + } + .highlight .sd { + color: rgb(123, 166, 202); + } + .highlight .s2 { + color: rgb(123, 166, 202); + } + .highlight .se { + color: rgb(123, 166, 202); + } + .highlight .sh { + color: rgb(123, 166, 202); + } + .highlight .si { + color: rgb(117, 168, 209); + } + .highlight .sx { + color: rgb(246, 147, 68); + } + .highlight .sr { + color: rgb(133, 182, 224); + } + .highlight .s1 { + color: rgb(123, 166, 202); + } + .highlight .ss { + color: rgb(188, 230, 128); + } + .highlight .bp { + color: rgb(126, 255, 163); + } + .highlight .fm { + color: rgb(131, 186, 249); + } + .highlight .vc { + color: rgb(190, 103, 215); + } + .highlight .vg { + color: rgb(190, 103, 215); + } + .highlight .vi { + color: rgb(190, 103, 215); + } + .highlight .vm { + color: rgb(190, 103, 215); + } + .highlight .il { + color: rgb(125, 222, 174); + } + @media (prefers-color-scheme: dark) { + html { + background-color: rgb(19, 21, 22) !important; + } + html, + body, + input, + textarea, + select, + button { + background-color: rgb(19, 21, 22); + } + html, + body, + input, + textarea, + select, + button { + border-color: rgb(106, 98, 87); + color: rgb(216, 212, 207); + } + a { + color: rgb(61, 165, 255); + } + table { + border-color: rgb(111, 103, 91); + } + ::placeholder { + color: rgb(178, 171, 161); + } + input:-webkit-autofill, + textarea:-webkit-autofill, + select:-webkit-autofill { + background-color: rgb(68, 73, 0) !important; + color: rgb(216, 212, 207) !important; + } + ::-webkit-scrollbar { + background-color: rgb(26, 28, 29); + color: rgb(173, 166, 156); + } + ::-webkit-scrollbar-thumb { + background-color: rgb(55, 60, 62); + } + ::-webkit-scrollbar-thumb:hover { + background-color: rgb(70, 75, 78); + } + ::-webkit-scrollbar-thumb:active { + background-color: rgb(58, 62, 65); + } + ::-webkit-scrollbar-corner { + background-color: rgb(19, 21, 22); + } + ::selection { + background-color: rgb(0, 62, 136) !important; + color: rgb(216, 212, 207) !important; + } + :root { + --darkreader-neutral-background: #131516; + --darkreader-text--darkreader-neutral-text: #cdc8c2; + --darkreader-selection-background: #004daa; + --darkreader-selection-text: #e8e6e3; + } + a:active, + a:hover { + outline-color: currentcolor; + } + abbr[title] { + border-bottom-color: currentcolor; + } + ins { + background-color: rgb(90, 90, 0); + background-image: none; + text-decoration-color: currentcolor; + } + ins, + mark { + color: rgb(216, 212, 207); + } + mark { + background-color: rgb(163, 163, 0); + background-image: none; + } + dl, + ol, + ul { + list-style-image: none; + } + li { + list-style-image: none; + } + img { + border-color: currentcolor; + } + .chromeframe { + background-color: rgb(42, 46, 47); + background-image: none; + color: rgb(216, 212, 207); + } + .ir { + border-color: currentcolor; + background-color: transparent; + } + .visuallyhidden { + border-color: currentcolor; + } + .fa-border { + border-color: rgb(122, 113, 100); + } + .fa-inverse { + color: rgb(216, 212, 207); + } + .sr-only { + border-color: currentcolor; + } + .fa::before, + .icon::before, + .rst-content .admonition-title::before, + .rst-content .code-block-caption .headerlink::before, + .rst-content code.download span:first-child::before, + .rst-content dl dt .headerlink::before, + .rst-content h1 .headerlink::before, + .rst-content h2 .headerlink::before, + .rst-content h3 .headerlink::before, + .rst-content h4 .headerlink::before, + .rst-content h5 .headerlink::before, + .rst-content h6 .headerlink::before, + .rst-content p.caption .headerlink::before, + .rst-content table > caption .headerlink::before, + .rst-content tt.download span:first-child::before, + .wy-dropdown .caret::before, + .wy-inline-validate.wy-inline-validate-danger .wy-input-context::before, + .wy-inline-validate.wy-inline-validate-info .wy-input-context::before, + .wy-inline-validate.wy-inline-validate-success .wy-input-context::before, + .wy-inline-validate.wy-inline-validate-warning .wy-input-context::before, + .wy-menu-vertical li.current > a span.toctree-expand::before, + .wy-menu-vertical li.on a span.toctree-expand::before, + .wy-menu-vertical li span.toctree-expand::before { + text-decoration-color: inherit; + } + .rst-content .code-block-caption a .headerlink, + .rst-content a .admonition-title, + .rst-content code.download a span:first-child, + .rst-content dl dt a .headerlink, + .rst-content h1 a .headerlink, + .rst-content h2 a .headerlink, + .rst-content h3 a .headerlink, + .rst-content h4 a .headerlink, + .rst-content h5 a .headerlink, + .rst-content h6 a .headerlink, + .rst-content p.caption a .headerlink, + .rst-content table > caption a .headerlink, + .rst-content tt.download a span:first-child, + .wy-menu-vertical li.current > a span.toctree-expand, + .wy-menu-vertical li.on a span.toctree-expand, + .wy-menu-vertical li a span.toctree-expand, + a .fa, + a .icon, + a .rst-content .admonition-title, + a .rst-content .code-block-caption .headerlink, + a .rst-content code.download span:first-child, + a .rst-content dl dt .headerlink, + a .rst-content h1 .headerlink, + a .rst-content h2 .headerlink, + a .rst-content h3 .headerlink, + a .rst-content h4 .headerlink, + a .rst-content h5 .headerlink, + a .rst-content h6 .headerlink, + a .rst-content p.caption .headerlink, + a .rst-content table > caption .headerlink, + a .rst-content tt.download span:first-child, + a .wy-menu-vertical li span.toctree-expand { + text-decoration-color: inherit; + } + .rst-content .admonition, + .rst-content .admonition-todo, + .rst-content .attention, + .rst-content .caution, + .rst-content .danger, + .rst-content .error, + .rst-content .hint, + .rst-content .important, + .rst-content .note, + .rst-content .seealso, + .rst-content .tip, + .rst-content .warning, + .wy-alert { + background-color: rgb(26, 28, 29); + background-image: none; + } + .rst-content .admonition-title, + .wy-alert-title { + color: rgb(216, 212, 207); + background-color: rgb(23, 73, 105); + background-image: none; + } + .rst-content .danger, + .rst-content .error, + .rst-content .wy-alert-danger.admonition, + .rst-content .wy-alert-danger.admonition-todo, + .rst-content .wy-alert-danger.attention, + .rst-content .wy-alert-danger.caution, + .rst-content .wy-alert-danger.hint, + .rst-content .wy-alert-danger.important, + .rst-content .wy-alert-danger.note, + .rst-content .wy-alert-danger.seealso, + .rst-content .wy-alert-danger.tip, + .rst-content .wy-alert-danger.warning, + .wy-alert.wy-alert-danger { + background-color: rgb(42, 10, 6); + background-image: none; + } + .rst-content .danger .admonition-title, + .rst-content .danger .wy-alert-title, + .rst-content .error .admonition-title, + .rst-content .error .wy-alert-title, + .rst-content .wy-alert-danger.admonition-todo .admonition-title, + .rst-content .wy-alert-danger.admonition-todo .wy-alert-title, + .rst-content .wy-alert-danger.admonition .admonition-title, + .rst-content .wy-alert-danger.admonition .wy-alert-title, + .rst-content .wy-alert-danger.attention .admonition-title, + .rst-content .wy-alert-danger.attention .wy-alert-title, + .rst-content .wy-alert-danger.caution .admonition-title, + .rst-content .wy-alert-danger.caution .wy-alert-title, + .rst-content .wy-alert-danger.hint .admonition-title, + .rst-content .wy-alert-danger.hint .wy-alert-title, + .rst-content .wy-alert-danger.important .admonition-title, + .rst-content .wy-alert-danger.important .wy-alert-title, + .rst-content .wy-alert-danger.note .admonition-title, + .rst-content .wy-alert-danger.note .wy-alert-title, + .rst-content .wy-alert-danger.seealso .admonition-title, + .rst-content .wy-alert-danger.seealso .wy-alert-title, + .rst-content .wy-alert-danger.tip .admonition-title, + .rst-content .wy-alert-danger.tip .wy-alert-title, + .rst-content .wy-alert-danger.warning .admonition-title, + .rst-content .wy-alert-danger.warning .wy-alert-title, + .rst-content .wy-alert.wy-alert-danger .admonition-title, + .wy-alert.wy-alert-danger .rst-content .admonition-title, + .wy-alert.wy-alert-danger .wy-alert-title { + background-color: rgb(86, 18, 10); + background-image: none; + } + .rst-content .admonition-todo, + .rst-content .attention, + .rst-content .caution, + .rst-content .warning, + .rst-content .wy-alert-warning.admonition, + .rst-content .wy-alert-warning.danger, + .rst-content .wy-alert-warning.error, + .rst-content .wy-alert-warning.hint, + .rst-content .wy-alert-warning.important, + .rst-content .wy-alert-warning.note, + .rst-content .wy-alert-warning.seealso, + .rst-content .wy-alert-warning.tip, + .wy-alert.wy-alert-warning { + background-color: rgb(25, 27, 28); + background-image: none; + } + .rst-content .admonition-todo .admonition-title, + .rst-content .admonition-todo .wy-alert-title, + .rst-content .attention .admonition-title, + .rst-content .attention .wy-alert-title, + .rst-content .caution .admonition-title, + .rst-content .caution .wy-alert-title, + .rst-content .warning .admonition-title, + .rst-content .warning .wy-alert-title, + .rst-content .wy-alert-warning.admonition .admonition-title, + .rst-content .wy-alert-warning.admonition .wy-alert-title, + .rst-content .wy-alert-warning.danger .admonition-title, + .rst-content .wy-alert-warning.danger .wy-alert-title, + .rst-content .wy-alert-warning.error .admonition-title, + .rst-content .wy-alert-warning.error .wy-alert-title, + .rst-content .wy-alert-warning.hint .admonition-title, + .rst-content .wy-alert-warning.hint .wy-alert-title, + .rst-content .wy-alert-warning.important .admonition-title, + .rst-content .wy-alert-warning.important .wy-alert-title, + .rst-content .wy-alert-warning.note .admonition-title, + .rst-content .wy-alert-warning.note .wy-alert-title, + .rst-content .wy-alert-warning.seealso .admonition-title, + .rst-content .wy-alert-warning.seealso .wy-alert-title, + .rst-content .wy-alert-warning.tip .admonition-title, + .rst-content .wy-alert-warning.tip .wy-alert-title, + .rst-content .wy-alert.wy-alert-warning .admonition-title, + .wy-alert.wy-alert-warning .rst-content .admonition-title, + .wy-alert.wy-alert-warning .wy-alert-title { + background-color: rgb(98, 52, 11); + background-image: none; + } + .rst-content .note, + .rst-content .seealso, + .rst-content .wy-alert-info.admonition, + .rst-content .wy-alert-info.admonition-todo, + .rst-content .wy-alert-info.attention, + .rst-content .wy-alert-info.caution, + .rst-content .wy-alert-info.danger, + .rst-content .wy-alert-info.error, + .rst-content .wy-alert-info.hint, + .rst-content .wy-alert-info.important, + .rst-content .wy-alert-info.tip, + .rst-content .wy-alert-info.warning, + .wy-alert.wy-alert-info { + background-color: rgb(26, 28, 29); + background-image: none; + } + .rst-content .note .admonition-title, + .rst-content .note .wy-alert-title, + .rst-content .seealso .admonition-title, + .rst-content .seealso .wy-alert-title, + .rst-content .wy-alert-info.admonition-todo .admonition-title, + .rst-content .wy-alert-info.admonition-todo .wy-alert-title, + .rst-content .wy-alert-info.admonition .admonition-title, + .rst-content .wy-alert-info.admonition .wy-alert-title, + .rst-content .wy-alert-info.attention .admonition-title, + .rst-content .wy-alert-info.attention .wy-alert-title, + .rst-content .wy-alert-info.caution .admonition-title, + .rst-content .wy-alert-info.caution .wy-alert-title, + .rst-content .wy-alert-info.danger .admonition-title, + .rst-content .wy-alert-info.danger .wy-alert-title, + .rst-content .wy-alert-info.error .admonition-title, + .rst-content .wy-alert-info.error .wy-alert-title, + .rst-content .wy-alert-info.hint .admonition-title, + .rst-content .wy-alert-info.hint .wy-alert-title, + .rst-content .wy-alert-info.important .admonition-title, + .rst-content .wy-alert-info.important .wy-alert-title, + .rst-content .wy-alert-info.tip .admonition-title, + .rst-content .wy-alert-info.tip .wy-alert-title, + .rst-content .wy-alert-info.warning .admonition-title, + .rst-content .wy-alert-info.warning .wy-alert-title, + .rst-content .wy-alert.wy-alert-info .admonition-title, + .wy-alert.wy-alert-info .rst-content .admonition-title, + .wy-alert.wy-alert-info .wy-alert-title { + background-color: rgb(23, 73, 105); + background-image: none; + } + .rst-content .hint, + .rst-content .important, + .rst-content .tip, + .rst-content .wy-alert-success.admonition, + .rst-content .wy-alert-success.admonition-todo, + .rst-content .wy-alert-success.attention, + .rst-content .wy-alert-success.caution, + .rst-content .wy-alert-success.danger, + .rst-content .wy-alert-success.error, + .rst-content .wy-alert-success.note, + .rst-content .wy-alert-success.seealso, + .rst-content .wy-alert-success.warning, + .wy-alert.wy-alert-success { + background-color: rgb(7, 53, 46); + background-image: none; + } + .rst-content .hint .admonition-title, + .rst-content .hint .wy-alert-title, + .rst-content .important .admonition-title, + .rst-content .important .wy-alert-title, + .rst-content .tip .admonition-title, + .rst-content .tip .wy-alert-title, + .rst-content .wy-alert-success.admonition-todo .admonition-title, + .rst-content .wy-alert-success.admonition-todo .wy-alert-title, + .rst-content .wy-alert-success.admonition .admonition-title, + .rst-content .wy-alert-success.admonition .wy-alert-title, + .rst-content .wy-alert-success.attention .admonition-title, + .rst-content .wy-alert-success.attention .wy-alert-title, + .rst-content .wy-alert-success.caution .admonition-title, + .rst-content .wy-alert-success.caution .wy-alert-title, + .rst-content .wy-alert-success.danger .admonition-title, + .rst-content .wy-alert-success.danger .wy-alert-title, + .rst-content .wy-alert-success.error .admonition-title, + .rst-content .wy-alert-success.error .wy-alert-title, + .rst-content .wy-alert-success.note .admonition-title, + .rst-content .wy-alert-success.note .wy-alert-title, + .rst-content .wy-alert-success.seealso .admonition-title, + .rst-content .wy-alert-success.seealso .wy-alert-title, + .rst-content .wy-alert-success.warning .admonition-title, + .rst-content .wy-alert-success.warning .wy-alert-title, + .rst-content .wy-alert.wy-alert-success .admonition-title, + .wy-alert.wy-alert-success .rst-content .admonition-title, + .wy-alert.wy-alert-success .wy-alert-title { + background-color: rgb(17, 120, 100); + background-image: none; + } + .rst-content .wy-alert-neutral.admonition, + .rst-content .wy-alert-neutral.admonition-todo, + .rst-content .wy-alert-neutral.attention, + .rst-content .wy-alert-neutral.caution, + .rst-content .wy-alert-neutral.danger, + .rst-content .wy-alert-neutral.error, + .rst-content .wy-alert-neutral.hint, + .rst-content .wy-alert-neutral.important, + .rst-content .wy-alert-neutral.note, + .rst-content .wy-alert-neutral.seealso, + .rst-content .wy-alert-neutral.tip, + .rst-content .wy-alert-neutral.warning, + .wy-alert.wy-alert-neutral { + background-color: rgb(22, 29, 29); + background-image: none; + } + .rst-content .wy-alert-neutral.admonition-todo .admonition-title, + .rst-content .wy-alert-neutral.admonition-todo .wy-alert-title, + .rst-content .wy-alert-neutral.admonition .admonition-title, + .rst-content .wy-alert-neutral.admonition .wy-alert-title, + .rst-content .wy-alert-neutral.attention .admonition-title, + .rst-content .wy-alert-neutral.attention .wy-alert-title, + .rst-content .wy-alert-neutral.caution .admonition-title, + .rst-content .wy-alert-neutral.caution .wy-alert-title, + .rst-content .wy-alert-neutral.danger .admonition-title, + .rst-content .wy-alert-neutral.danger .wy-alert-title, + .rst-content .wy-alert-neutral.error .admonition-title, + .rst-content .wy-alert-neutral.error .wy-alert-title, + .rst-content .wy-alert-neutral.hint .admonition-title, + .rst-content .wy-alert-neutral.hint .wy-alert-title, + .rst-content .wy-alert-neutral.important .admonition-title, + .rst-content .wy-alert-neutral.important .wy-alert-title, + .rst-content .wy-alert-neutral.note .admonition-title, + .rst-content .wy-alert-neutral.note .wy-alert-title, + .rst-content .wy-alert-neutral.seealso .admonition-title, + .rst-content .wy-alert-neutral.seealso .wy-alert-title, + .rst-content .wy-alert-neutral.tip .admonition-title, + .rst-content .wy-alert-neutral.tip .wy-alert-title, + .rst-content .wy-alert-neutral.warning .admonition-title, + .rst-content .wy-alert-neutral.warning .wy-alert-title, + .rst-content .wy-alert.wy-alert-neutral .admonition-title, + .wy-alert.wy-alert-neutral .rst-content .admonition-title, + .wy-alert.wy-alert-neutral .wy-alert-title { + color: rgb(188, 182, 173); + background-color: rgb(32, 35, 36); + background-image: none; + } + .rst-content .wy-alert-neutral.admonition-todo a, + .rst-content .wy-alert-neutral.admonition a, + .rst-content .wy-alert-neutral.attention a, + .rst-content .wy-alert-neutral.caution a, + .rst-content .wy-alert-neutral.danger a, + .rst-content .wy-alert-neutral.error a, + .rst-content .wy-alert-neutral.hint a, + .rst-content .wy-alert-neutral.important a, + .rst-content .wy-alert-neutral.note a, + .rst-content .wy-alert-neutral.seealso a, + .rst-content .wy-alert-neutral.tip a, + .rst-content .wy-alert-neutral.warning a, + .wy-alert.wy-alert-neutral a { + color: rgb(94, 169, 219); + } + .wy-tray-container li { + background-color: transparent; + background-image: none; + color: rgb(216, 212, 207); + box-shadow: rgba(0, 0, 0, 0.1) 0px 5px 5px 0px; + } + .wy-tray-container li.wy-tray-item-success { + background-color: rgb(25, 111, 62); + background-image: none; + } + .wy-tray-container li.wy-tray-item-info { + background-color: rgb(26, 82, 118); + background-image: none; + } + .wy-tray-container li.wy-tray-item-warning { + background-color: rgb(142, 75, 16); + background-image: none; + } + .wy-tray-container li.wy-tray-item-danger { + background-color: rgb(130, 26, 16); + background-image: none; + } + .btn { + color: rgb(216, 212, 207); + border-color: rgba(84, 91, 95, 0.1); + background-color: rgb(25, 111, 62); + text-decoration-color: currentcolor; + box-shadow: rgba(19, 21, 22, 0.5) 0px 1px 2px -1px inset, + rgba(0, 0, 0, 0.1) 0px -2px 0px 0px inset; + } + .btn-hover { + background-color: rgb(30, 91, 132); + background-image: none; + color: rgb(216, 212, 207); + } + .btn:hover { + background-color: rgb(28, 125, 69); + background-image: none; + color: rgb(216, 212, 207); + } + .btn:focus { + background-color: rgb(28, 125, 69); + background-image: none; + outline-color: currentcolor; + } + .btn:active { + box-shadow: rgba(0, 0, 0, 0.05) 0px -1px 0px 0px inset, + rgba(0, 0, 0, 0.1) 0px 2px 0px 0px inset; + } + .btn:visited { + color: rgb(216, 212, 207); + } + .btn-disabled, + .btn-disabled:active, + .btn-disabled:focus, + .btn-disabled:hover, + .btn:disabled { + background-image: none; + box-shadow: none; + } + .btn-info { + background-color: rgb(26, 82, 118) !important; + } + .btn-info:hover { + background-color: rgb(30, 91, 132) !important; + } + .btn-neutral { + background-color: rgb(22, 29, 29) !important; + color: rgb(188, 182, 173) !important; + } + .btn-neutral:hover { + color: rgb(188, 182, 173); + background-color: rgb(27, 35, 35) !important; + } + .btn-neutral:visited { + color: rgb(188, 182, 173) !important; + } + .btn-success { + background-color: rgb(25, 111, 62) !important; + } + .btn-success:hover { + background-color: rgb(22, 98, 54) !important; + } + .btn-danger { + background-color: rgb(130, 26, 16) !important; + } + .btn-danger:hover { + background-color: rgb(119, 24, 14) !important; + } + .btn-warning { + background-color: rgb(142, 75, 16) !important; + } + .btn-warning:hover { + background-color: rgb(132, 70, 14) !important; + } + .btn-invert { + background-color: rgb(21, 22, 23); + } + .btn-invert:hover { + background-color: rgb(28, 31, 32) !important; + } + .btn-link { + color: rgb(94, 169, 219); + box-shadow: none; + background-color: transparent !important; + border-color: transparent !important; + } + .btn-link:active, + .btn-link:hover { + box-shadow: none; + background-color: transparent !important; + color: rgb(90, 168, 218) !important; + } + .btn-link:visited { + color: rgb(170, 113, 192); + } + .wy-dropdown-menu { + background-color: rgb(21, 22, 23); + background-image: none; + border-color: rgb(119, 111, 98); + box-shadow: rgba(0, 0, 0, 0.1) 0px 2px 2px 0px; + } + .wy-dropdown-menu > dd > a { + color: rgb(188, 182, 173); + } + .wy-dropdown-menu > dd > a:hover { + background-color: rgb(26, 82, 118); + background-image: none; + color: rgb(216, 212, 207); + } + .wy-dropdown-menu > dd.divider { + border-top-color: rgb(119, 111, 98); + } + .wy-dropdown-menu > dd.call-to-action { + background-color: rgb(32, 35, 36); + background-image: none; + } + .wy-dropdown-menu > dd.call-to-action:hover { + background-color: rgb(32, 35, 36); + background-image: none; + } + .wy-dropdown-menu > dd.call-to-action .btn { + color: rgb(216, 212, 207); + } + .wy-dropdown.wy-dropdown-bubble .wy-dropdown-menu { + background-color: rgb(21, 22, 23); + background-image: none; + } + .wy-dropdown.wy-dropdown-bubble .wy-dropdown-menu a:hover { + background-color: rgb(26, 82, 118); + background-image: none; + color: rgb(216, 212, 207); + } + .wy-dropdown-arrow::before { + border-bottom-color: rgb(122, 113, 100); + border-left-color: transparent; + border-right-color: transparent; + } + fieldset, + legend { + border-color: currentcolor; + } + label { + color: rgb(193, 188, 180); + } + .wy-control-group.wy-control-group-required > label::after { + color: rgb(234, 96, 82); + } + .wy-form-message-inline { + color: rgb(171, 164, 153); + } + .wy-form-message { + color: rgb(171, 164, 153); + } + input[type="color"], input[type="date"], input[type="datetime-local"], input[type="datetime"], input[type="email"], input[type="month"], input[type="number"], input[type="password"], input[type="search"], input[type="tel"], input[type="text"], input[type="time"], input[type="url"], input[type="week"] { + border-color: rgb(118, 110, 97); + box-shadow: rgb(35, 38, 39) 0px 1px 3px inset; + } + input[type="color"]:focus, input[type="date"]:focus, input[type="datetime-local"]:focus, input[type="datetime"]:focus, input[type="email"]:focus, input[type="month"]:focus, input[type="number"]:focus, input[type="password"]:focus, input[type="search"]:focus, input[type="tel"]:focus, input[type="text"]:focus, input[type="time"]:focus, input[type="url"]:focus, input[type="week"]:focus { + outline-color: currentcolor; + border-color: rgb(103, 96, 85); + } + input.no-focus:focus { + border-color: rgb(118, 110, 97) !important; + } + input[type="checkbox"]:focus, input[type="file"]:focus, input[type="radio"]:focus { + outline-color: rgb(15, 126, 186); + } + input[type="color"][disabled], input[type="date"][disabled], input[type="datetime-local"][disabled], input[type="datetime"][disabled], input[type="email"][disabled], input[type="month"][disabled], input[type="number"][disabled], input[type="password"][disabled], input[type="search"][disabled], input[type="tel"][disabled], input[type="text"][disabled], input[type="time"][disabled], input[type="url"][disabled], input[type="week"][disabled] { + background-color: rgb(21, 23, 24); + } + input:focus:invalid, + select:focus:invalid, + textarea:focus:invalid { + color: rgb(234, 96, 82); + border-color: rgb(183, 38, 22); + } + input:focus:invalid:focus, + select:focus:invalid:focus, + textarea:focus:invalid:focus { + border-color: rgb(183, 38, 22); + } + input[type="checkbox"]:focus:invalid:focus, input[type="file"]:focus:invalid:focus, input[type="radio"]:focus:invalid:focus { + outline-color: rgb(183, 38, 22); + } + select, + textarea { + border-color: rgb(118, 110, 97); + box-shadow: rgb(35, 38, 39) 0px 1px 3px inset; + } + select { + border-color: rgb(118, 110, 97); + background-color: rgb(19, 21, 22); + } + select:focus, + textarea:focus { + outline-color: currentcolor; + } + input[readonly], + select[disabled], + select[readonly], + textarea[disabled], + textarea[readonly] { + background-color: rgb(21, 23, 24); + } + .wy-checkbox, + .wy-radio { + color: rgb(188, 182, 173); + } + .wy-input-prefix .wy-input-context, + .wy-input-suffix .wy-input-context { + background-color: rgb(22, 29, 29); + border-color: rgb(118, 110, 97); + color: rgb(171, 164, 153); + } + .wy-input-suffix .wy-input-context { + border-left-color: currentcolor; + } + .wy-input-prefix .wy-input-context { + border-right-color: currentcolor; + } + .wy-switch::before { + background-color: rgb(42, 46, 47); + background-image: none; + } + .wy-switch::after { + background-color: rgb(66, 71, 74); + background-image: none; + } + .wy-switch span { + color: rgb(193, 188, 180); + } + .wy-switch.active::before { + background-color: rgb(19, 85, 46); + background-image: none; + } + .wy-switch.active::after { + background-color: rgb(25, 111, 62); + background-image: none; + } + .wy-control-group.wy-control-group-error .wy-form-message, + .wy-control-group.wy-control-group-error > label { + color: rgb(234, 96, 82); + } + .wy-control-group.wy-control-group-error input[type="color"], .wy-control-group.wy-control-group-error input[type="date"], .wy-control-group.wy-control-group-error input[type="datetime-local"], .wy-control-group.wy-control-group-error input[type="datetime"], .wy-control-group.wy-control-group-error input[type="email"], .wy-control-group.wy-control-group-error input[type="month"], .wy-control-group.wy-control-group-error input[type="number"], .wy-control-group.wy-control-group-error input[type="password"], .wy-control-group.wy-control-group-error input[type="search"], .wy-control-group.wy-control-group-error input[type="tel"], .wy-control-group.wy-control-group-error input[type="text"], .wy-control-group.wy-control-group-error input[type="time"], .wy-control-group.wy-control-group-error input[type="url"], .wy-control-group.wy-control-group-error input[type="week"], + .wy-control-group.wy-control-group-error textarea { + border-color: rgb(183, 38, 22); + } + .wy-inline-validate.wy-inline-validate-success .wy-input-context { + color: rgb(99, 220, 150); + } + .wy-inline-validate.wy-inline-validate-danger .wy-input-context { + color: rgb(234, 96, 82); + } + .wy-inline-validate.wy-inline-validate-warning .wy-input-context { + color: rgb(234, 146, 69); + } + .wy-inline-validate.wy-inline-validate-info .wy-input-context { + color: rgb(94, 169, 219); + } + .rst-content table.docutils caption, + .rst-content table.field-list caption, + .wy-table caption { + color: rgb(216, 212, 207); + } + .rst-content table.docutils thead, + .rst-content table.field-list thead, + .wy-table thead { + color: rgb(216, 212, 207); + } + .rst-content table.docutils thead th, + .rst-content table.field-list thead th, + .wy-table thead th { + border-bottom-color: rgb(120, 112, 99); + } + .rst-content table.docutils td, + .rst-content table.field-list td, + .wy-table td { + background-color: transparent; + } + .wy-table-secondary { + color: rgb(160, 151, 139); + } + .wy-table-tertiary { + color: rgb(160, 151, 139); + } + .rst-content table.docutils:not(.field-list) tr:nth-child(2n-1) td, + .wy-table-backed, + .wy-table-odd td, + .wy-table-striped tr:nth-child(2n-1) td { + background-color: rgb(22, 29, 29); + } + .rst-content table.docutils, + .wy-table-bordered-all { + border-color: rgb(120, 112, 99); + } + .rst-content table.docutils td, + .wy-table-bordered-all td { + border-bottom-color: rgb(120, 112, 99); + border-left-color: rgb(120, 112, 99); + } + .wy-table-bordered { + border-color: rgb(120, 112, 99); + } + .wy-table-bordered-rows td { + border-bottom-color: rgb(120, 112, 99); + } + .wy-table-horizontal td, + .wy-table-horizontal th { + border-bottom-color: rgb(120, 112, 99); + } + a { + color: rgb(94, 169, 219); + text-decoration-color: currentcolor; + } + a:hover { + color: rgb(82, 164, 217); + } + a:visited { + color: rgb(170, 113, 192); + } + body { + color: rgb(188, 182, 173); + background-color: rgb(26, 29, 30); + background-image: none; + } + .wy-text-strike { + text-decoration-color: currentcolor; + } + .wy-text-warning { + color: rgb(234, 146, 69) !important; + } + a.wy-text-warning:hover { + color: rgb(237, 160, 92) !important; + } + .wy-text-info { + color: rgb(94, 169, 219) !important; + } + a.wy-text-info:hover { + color: rgb(90, 168, 218) !important; + } + .wy-text-success { + color: rgb(99, 220, 150) !important; + } + a.wy-text-success:hover { + color: rgb(86, 217, 142) !important; + } + .wy-text-danger { + color: rgb(234, 96, 82) !important; + } + a.wy-text-danger:hover { + color: rgb(237, 118, 104) !important; + } + .wy-text-neutral { + color: rgb(188, 182, 173) !important; + } + a.wy-text-neutral:hover { + color: rgb(177, 170, 160) !important; + } + hr { + border-color: rgb(120, 112, 99) currentcolor currentcolor; + } + .rst-content code, + .rst-content tt, + code { + background-color: rgb(19, 21, 22); + background-image: none; + border-color: rgb(120, 112, 99); + color: rgb(234, 96, 82); + } + .rst-content .section ul, + .rst-content .toctree-wrapper ul, + .wy-plain-list-disc, + article ul { + list-style-image: none; + } + .rst-content .section ul li, + .rst-content .toctree-wrapper ul li, + .wy-plain-list-disc li, + article ul li { + list-style-image: none; + } + .rst-content .section ul li li, + .rst-content .toctree-wrapper ul li li, + .wy-plain-list-disc li li, + article ul li li { + list-style-image: none; + } + .rst-content .section ul li li li, + .rst-content .toctree-wrapper ul li li li, + .wy-plain-list-disc li li li, + article ul li li li { + list-style-image: none; + } + .rst-content .section ul li ol li, + .rst-content .toctree-wrapper ul li ol li, + .wy-plain-list-disc li ol li, + article ul li ol li { + list-style-image: none; + } + .rst-content .section ol, + .rst-content ol.arabic, + .wy-plain-list-decimal, + article ol { + list-style-image: none; + } + .rst-content .section ol li, + .rst-content ol.arabic li, + .wy-plain-list-decimal li, + article ol li { + list-style-image: none; + } + .rst-content .section ol li ul li, + .rst-content ol.arabic li ul li, + .wy-plain-list-decimal li ul li, + article ol li ul li { + list-style-image: none; + } + .rst-content .wy-breadcrumbs li tt, + .wy-breadcrumbs li .rst-content tt, + .wy-breadcrumbs li code { + border-color: currentcolor; + background-color: rgba(0, 0, 0, 0); + background-image: none; + } + .rst-content .wy-breadcrumbs li tt.literal, + .wy-breadcrumbs li .rst-content tt.literal, + .wy-breadcrumbs li code.literal { + color: rgb(188, 182, 173); + } + .wy-breadcrumbs-extra { + color: rgb(182, 176, 167); + } + .wy-menu a:hover { + text-decoration-color: currentcolor; + } + .wy-menu-horiz li:hover { + background-color: rgba(19, 21, 22, 0.1); + background-image: none; + } + .wy-menu-horiz li.divide-left { + border-left-color: rgb(104, 97, 86); + } + .wy-menu-horiz li.divide-right { + border-right-color: rgb(104, 97, 86); + } + .wy-menu-vertical header, + .wy-menu-vertical p.caption { + color: rgb(101, 173, 220); + } + .wy-menu-vertical li.divide-top { + border-top-color: rgb(104, 97, 86); + } + .wy-menu-vertical li.divide-bottom { + border-bottom-color: rgb(104, 97, 86); + } + .wy-menu-vertical li.current { + background-color: rgb(32, 35, 36); + background-image: none; + } + .wy-menu-vertical li.current a { + color: rgb(160, 151, 139); + border-right-color: rgb(118, 110, 97); + } + .wy-menu-vertical li.current a:hover { + background-color: rgb(38, 41, 42); + background-image: none; + } + .rst-content .wy-menu-vertical li tt, + .wy-menu-vertical li .rst-content tt, + .wy-menu-vertical li code { + border-color: currentcolor; + background-color: inherit; + background-image: inherit; + color: inherit; + } + .wy-menu-vertical li span.toctree-expand { + color: rgb(182, 175, 166); + } + .wy-menu-vertical li.current > a, + .wy-menu-vertical li.on a { + color: rgb(188, 182, 173); + background-color: rgb(21, 22, 23); + background-image: none; + border-color: currentcolor; + } + .wy-menu-vertical li.current > a:hover, + .wy-menu-vertical li.on a:hover { + background-color: rgb(21, 22, 23); + background-image: none; + } + .wy-menu-vertical li.current > a:hover span.toctree-expand, + .wy-menu-vertical li.on a:hover span.toctree-expand { + color: rgb(160, 151, 139); + } + .wy-menu-vertical li.current > a span.toctree-expand, + .wy-menu-vertical li.on a span.toctree-expand { + color: rgb(193, 188, 180); + } + .wy-menu-vertical li.toctree-l1.current > a { + border-bottom-color: rgb(118, 110, 97); + border-top-color: rgb(118, 110, 97); + } + .wy-menu-vertical li.toctree-l2 a, + .wy-menu-vertical li.toctree-l3 a, + .wy-menu-vertical li.toctree-l4 a, + .wy-menu-vertical li.toctree-l5 a, + .wy-menu-vertical li.toctree-l6 a, + .wy-menu-vertical li.toctree-l7 a, + .wy-menu-vertical li.toctree-l8 a, + .wy-menu-vertical li.toctree-l9 a, + .wy-menu-vertical li.toctree-l10 a { + color: rgb(188, 182, 173); + } + .wy-menu-vertical li.toctree-l2 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l3 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l4 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l5 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l6 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l7 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l8 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l9 a:hover span.toctree-expand, + .wy-menu-vertical li.toctree-l10 a:hover span.toctree-expand { + color: rgb(160, 151, 139); + } + .wy-menu-vertical li.toctree-l2.current > a, + .wy-menu-vertical li.toctree-l2.current li.toctree-l3 > a { + background-color: rgb(43, 47, 49); + background-image: none; + } + .wy-menu-vertical li.toctree-l2 span.toctree-expand { + color: rgb(175, 168, 158); + } + .wy-menu-vertical li.toctree-l3.current > a, + .wy-menu-vertical li.toctree-l3.current li.toctree-l4 > a { + background-color: rgb(49, 53, 55); + background-image: none; + } + .wy-menu-vertical li.toctree-l3 span.toctree-expand { + color: rgb(169, 162, 151); + } + .wy-menu-vertical li ul li a { + color: rgb(199, 194, 187); + } + .wy-menu-vertical a { + color: rgb(199, 194, 187); + } + .wy-menu-vertical a:hover { + background-color: rgb(46, 49, 51); + } + .wy-menu-vertical a:hover span.toctree-expand { + color: rgb(199, 194, 187); + } + .wy-menu-vertical a:active { + background-color: rgb(26, 82, 118); + color: rgb(216, 212, 207); + } + .wy-menu-vertical a:active span.toctree-expand { + color: rgb(216, 212, 207); + } + .wy-side-nav-search { + background-color: rgb(26, 82, 118); + color: rgb(215, 211, 206); + } + .wy-side-nav-search input[type="text"] { + border-color: rgb(35, 112, 161); + } + .wy-side-nav-search img { + background-color: rgb(26, 82, 118); + } + .wy-side-nav-search .wy-dropdown > a, + .wy-side-nav-search > a { + color: rgb(215, 211, 206); + } + .wy-side-nav-search .wy-dropdown > a:hover, + .wy-side-nav-search > a:hover { + background-color: rgba(19, 21, 22, 0.1); + background-image: none; + } + .wy-side-nav-search .wy-dropdown > a img.logo, + .wy-side-nav-search > a img.logo { + background-color: transparent; + background-image: none; + } + .wy-side-nav-search > div.version { + color: rgba(216, 212, 207, 0.3); + } + .wy-nav .wy-menu-vertical header { + color: rgb(94, 169, 219); + } + .wy-nav .wy-menu-vertical a { + color: rgb(182, 176, 167); + } + .wy-nav .wy-menu-vertical a:hover { + background-color: rgb(26, 82, 118); + color: rgb(216, 212, 207); + } + .wy-body-for-nav { + background-color: rgb(21, 22, 23); + background-image: none; + } + .wy-nav-side { + color: rgb(172, 164, 154); + background-color: rgb(30, 33, 34); + background-image: none; + } + .wy-nav-top { + background-color: rgb(26, 82, 118); + background-image: none; + color: rgb(216, 212, 207); + } + .wy-nav-top a { + color: rgb(216, 212, 207); + } + .wy-nav-top img { + background-color: rgb(26, 82, 118); + } + .wy-nav-content-wrap { + background-color: rgb(21, 22, 23); + background-image: none; + } + .wy-body-mask { + background-color: rgba(0, 0, 0, 0.2); + background-image: none; + } + footer { + color: rgb(160, 151, 139); + } + .rst-content footer span.commit tt, + footer span.commit .rst-content tt, + footer span.commit code { + background-color: rgba(0, 0, 0, 0); + background-image: none; + border-color: currentcolor; + color: rgb(160, 151, 139); + } + #search-results .search li { + border-bottom-color: rgb(120, 112, 99); + } + #search-results .search li:first-child { + border-top-color: rgb(120, 112, 99); + } + #search-results .context { + color: rgb(160, 151, 139); + } + .wy-body-for-nav { + background-color: rgb(21, 22, 23); + background-image: none; + } + @media screen and (min-width: 1100px) { + .wy-nav-content-wrap { + background-color: rgba(0, 0, 0, 0.05); + background-image: none; + } + .wy-nav-content { + background-color: rgb(21, 22, 23); + background-image: none; + } + } + .rst-versions { + color: rgb(215, 211, 206); + background-color: rgb(18, 20, 20); + background-image: none; + } + .rst-versions a { + color: rgb(94, 169, 219); + text-decoration-color: currentcolor; + } + .rst-versions .rst-current-version { + background-color: rgb(23, 25, 26); + color: rgb(99, 220, 150); + } + .rst-content .code-block-caption .rst-versions .rst-current-version .headerlink, + .rst-content .rst-versions .rst-current-version .admonition-title, + .rst-content code.download .rst-versions .rst-current-version span:first-child, + .rst-content dl dt .rst-versions .rst-current-version .headerlink, + .rst-content h1 .rst-versions .rst-current-version .headerlink, + .rst-content h2 .rst-versions .rst-current-version .headerlink, + .rst-content h3 .rst-versions .rst-current-version .headerlink, + .rst-content h4 .rst-versions .rst-current-version .headerlink, + .rst-content h5 .rst-versions .rst-current-version .headerlink, + .rst-content h6 .rst-versions .rst-current-version .headerlink, + .rst-content p.caption .rst-versions .rst-current-version .headerlink, + .rst-content table > caption .rst-versions .rst-current-version .headerlink, + .rst-content tt.download .rst-versions .rst-current-version span:first-child, + .rst-versions .rst-current-version .fa, + .rst-versions .rst-current-version .icon, + .rst-versions .rst-current-version .rst-content .admonition-title, + .rst-versions .rst-current-version .rst-content .code-block-caption .headerlink, + .rst-versions .rst-current-version .rst-content code.download span:first-child, + .rst-versions .rst-current-version .rst-content dl dt .headerlink, + .rst-versions .rst-current-version .rst-content h1 .headerlink, + .rst-versions .rst-current-version .rst-content h2 .headerlink, + .rst-versions .rst-current-version .rst-content h3 .headerlink, + .rst-versions .rst-current-version .rst-content h4 .headerlink, + .rst-versions .rst-current-version .rst-content h5 .headerlink, + .rst-versions .rst-current-version .rst-content h6 .headerlink, + .rst-versions .rst-current-version .rst-content p.caption .headerlink, + .rst-versions .rst-current-version .rst-content table > caption .headerlink, + .rst-versions .rst-current-version .rst-content tt.download span:first-child, + .rst-versions .rst-current-version .wy-menu-vertical li span.toctree-expand, + .wy-menu-vertical li .rst-versions .rst-current-version span.toctree-expand { + color: rgb(215, 211, 206); + } + .rst-versions .rst-current-version.rst-out-of-date { + background-color: rgb(130, 26, 16); + color: rgb(216, 212, 207); + } + .rst-versions .rst-current-version.rst-active-old-version { + background-color: rgb(154, 125, 9); + color: rgb(216, 212, 207); + } + .rst-versions .rst-other-versions { + color: rgb(160, 151, 139); + } + .rst-versions .rst-other-versions hr { + border-color: rgb(104, 97, 86) currentcolor currentcolor; + } + .rst-versions .rst-other-versions dd a { + color: rgb(215, 211, 206); + } + .rst-versions.rst-badge { + border-color: currentcolor; + } + .rst-content abbr[title] { + text-decoration-color: currentcolor; + } + .rst-content.style-external-links a.reference.external::after { + color: rgb(182, 176, 167); + } + .rst-content div[class^="highlight"], + .rst-content pre.literal-block { + border-color: rgb(120, 112, 99); + } + .rst-content div[class^="highlight"] div[class^="highlight"], .rst-content pre.literal-block div[class^="highlight"] { + border-color: currentcolor; + } + .rst-content .linenodiv pre { + border-right-color: rgb(121, 112, 99); + } + .rst-content .admonition table { + border-color: rgba(84, 91, 95, 0.1); + } + .rst-content .admonition table td, + .rst-content .admonition table th { + background-color: transparent !important; + background-image: none !important; + border-color: rgba(84, 91, 95, 0.1) !important; + } + .rst-content .section ol.loweralpha, + .rst-content .section ol.loweralpha > li { + list-style-image: none; + } + .rst-content .section ol.upperalpha, + .rst-content .section ol.upperalpha > li { + list-style-image: none; + } + .rst-content .toc-backref { + color: rgb(188, 182, 173); + } + .rst-content .sidebar { + background-color: rgb(22, 29, 29); + background-image: none; + border-color: rgb(120, 112, 99); + } + .rst-content .sidebar .sidebar-title { + background-color: rgb(32, 35, 36); + background-image: none; + } + .rst-content .highlighted { + background-color: rgb(154, 125, 9); + background-image: none; + box-shadow: rgb(154, 125, 9) 0px 0px 0px 2px; + } + html.writer-html4 .rst-content table.docutils.citation, + html.writer-html4 .rst-content table.docutils.footnote { + background-color: rgba(0, 0, 0, 0); + background-image: none; + border-color: currentcolor; + } + html.writer-html4 .rst-content table.docutils.citation td, + html.writer-html4 .rst-content table.docutils.citation tr, + html.writer-html4 .rst-content table.docutils.footnote td, + html.writer-html4 .rst-content table.docutils.footnote tr { + border-color: currentcolor; + background-color: transparent !important; + } + .rst-content table.docutils.footnote, + html.writer-html4 .rst-content table.docutils.citation, + html.writer-html5 .rst-content dl.footnote { + color: rgb(160, 151, 139); + } + .rst-content table.docutils.footnote code, + .rst-content table.docutils.footnote tt, + html.writer-html4 .rst-content table.docutils.citation code, + html.writer-html4 .rst-content table.docutils.citation tt, + html.writer-html5 .rst-content dl.footnote code, + html.writer-html5 .rst-content dl.footnote tt { + color: rgb(178, 172, 162); + } + .rst-content table.docutils th { + border-color: rgb(120, 112, 99); + } + html.writer-html5 .rst-content table.docutils th { + border-color: rgb(120, 112, 99); + } + .rst-content table.field-list, + .rst-content table.field-list td { + border-color: currentcolor; + } + .rst-content code, + .rst-content tt { + color: rgb(216, 212, 207); + } + .rst-content code.literal, + .rst-content tt.literal { + color: rgb(227, 134, 124); + } + .rst-content code.xref, + .rst-content tt.xref, + a .rst-content code, + a .rst-content tt { + color: rgb(188, 182, 173); + } + .rst-content a code, + .rst-content a tt { + color: rgb(94, 169, 219); + } + html.writer-html4 .rst-content dl:not(.docutils) > dt, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) > dt { + background-color: rgb(26, 28, 29); + background-image: none; + color: rgb(94, 169, 219); + border-top-color: rgb(37, 119, 171); + } + html.writer-html4 .rst-content dl:not(.docutils) > dt::before, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) > dt::before { + color: rgb(111, 179, 223); + } + html.writer-html4 .rst-content dl:not(.docutils) > dt .headerlink, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) > dt .headerlink { + color: rgb(188, 182, 173); + } + html.writer-html4 .rst-content dl:not(.docutils) dl:not(.field-list) > dt, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) dl:not(.field-list) > dt { + border-color: currentcolor currentcolor currentcolor rgb(118, 110, 97); + background-color: rgb(26, 28, 29); + background-image: none; + color: rgb(178, 172, 162); + } + html.writer-html4 .rst-content dl:not(.docutils) dl:not(.field-list) > dt .headerlink, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) dl:not(.field-list) > dt .headerlink { + color: rgb(188, 182, 173); + } + html.writer-html4 .rst-content dl:not(.docutils) code.descclassname, + html.writer-html4 .rst-content dl:not(.docutils) code.descname, + html.writer-html4 .rst-content dl:not(.docutils) tt.descclassname, + html.writer-html4 .rst-content dl:not(.docutils) tt.descname, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) code.descclassname, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) code.descname, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) tt.descclassname, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) tt.descname { + background-color: transparent; + border-color: currentcolor; + } + html.writer-html4 .rst-content dl:not(.docutils) .optional, + html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) .optional { + color: rgb(216, 212, 207); + } + .rst-content .viewcode-back, + .rst-content .viewcode-link { + color: rgb(99, 220, 150); + } + .rst-content code.download, + .rst-content tt.download { + background-color: inherit; + background-image: inherit; + color: inherit; + border-color: inherit; + } + .rst-content .guilabel { + border-color: rgb(38, 119, 172); + background-color: rgb(26, 28, 29); background-image: none; + } + span[id*="MathJax-Span"] { + color: rgb(188, 182, 173); + } + td.linenos .normal { + color: inherit; + background-color: transparent; + } + span.linenos { + color: inherit; + background-color: transparent; + } + td.linenos .special { + color: rgb(216, 212, 207); + background-color: rgb(71, 71, 0); + } + span.linenos.special { + color: rgb(216, 212, 207); + background-color: rgb(71, 71, 0); + } + .highlight .hll { + background-color: rgb(66, 66, 0); + } + .highlight { + background-color: rgb(32, 34, 36); + background-image: none; + } + .highlight .c { + color: rgb(124, 182, 197); + } + .highlight .err { + border-color: rgb(201, 0, 0); + } + .highlight .k { + color: rgb(114, 255, 154); + } + .highlight .o { + color: rgb(171, 164, 153); + } + .highlight .ch { + color: rgb(124, 182, 197); + } + .highlight .cm { + color: rgb(124, 182, 197); + } + .highlight .cp { + color: rgb(114, 255, 154); + } + .highlight .cpf { + color: rgb(124, 182, 197); + } + .highlight .c1 { + color: rgb(124, 182, 197); + } + .highlight .cs { + color: rgb(124, 182, 197); + background-color: rgb(48, 0, 0); + } + .highlight .gd { + color: rgb(255, 90, 90); + } + .highlight .gr { + color: rgb(255, 44, 44); + } + .highlight .gh { + color: rgb(114, 185, 255); + } + .highlight .gi { + color: rgb(90, 255, 90); + } + .highlight .go { + color: rgb(193, 188, 180); + } + .highlight .gp { + color: rgb(246, 151, 75); + } + .highlight .gu { + color: rgb(255, 105, 255); + } + .highlight .gt { + color: rgb(75, 173, 255); + } + .highlight .kc { + color: rgb(114, 255, 154); + } + .highlight .kd { + color: rgb(114, 255, 154); + } + .highlight .kn { + color: rgb(114, 255, 154); + } + .highlight .kp { + color: rgb(114, 255, 154); + } + .highlight .kr { + color: rgb(114, 255, 154); + } + .highlight .kt { + color: rgb(255, 133, 98); + } + .highlight .m { + color: rgb(123, 222, 173); + } + .highlight .s { + color: rgb(126, 170, 203); + } + .highlight .na { + color: rgb(126, 170, 203); + } + .highlight .nb { + color: rgb(114, 255, 154); + } + .highlight .nc { + color: rgb(86, 196, 242); + } + .highlight .no { + color: rgb(108, 180, 216); + } + .highlight .nd { + color: rgb(178, 172, 162); + } + .highlight .ni { + color: rgb(220, 111, 85); + } + .highlight .ne { + color: rgb(114, 255, 154); + } + .highlight .nf { + color: rgb(120, 189, 248); + } + .highlight .nl { + color: rgb(121, 194, 255); + } + .highlight .nn { + color: rgb(86, 196, 242); + } + .highlight .nt { + color: rgb(125, 192, 248); + } + .highlight .nv { + color: rgb(192, 108, 216); + } + .highlight .ow { + color: rgb(114, 255, 154); + } + .highlight .w { + color: rgb(186, 180, 171); + } + .highlight .mb { + color: rgb(123, 222, 173); + } + .highlight .mf { + color: rgb(123, 222, 173); + } + .highlight .mh { + color: rgb(123, 222, 173); + } + .highlight .mi { + color: rgb(123, 222, 173); + } + .highlight .mo { + color: rgb(123, 222, 173); + } + .highlight .sa { + color: rgb(126, 170, 203); + } + .highlight .sb { + color: rgb(126, 170, 203); + } + .highlight .sc { + color: rgb(126, 170, 203); + } + .highlight .dl { + color: rgb(126, 170, 203); + } + .highlight .sd { + color: rgb(126, 170, 203); + } + .highlight .s2 { + color: rgb(126, 170, 203); + } + .highlight .se { + color: rgb(126, 170, 203); + } + .highlight .sh { + color: rgb(126, 170, 203); + } + .highlight .si { + color: rgb(120, 172, 210); + } + .highlight .sx { + color: rgb(246, 151, 75); + } + .highlight .sr { + color: rgb(129, 182, 223); + } + .highlight .s1 { + color: rgb(126, 170, 203); + } + .highlight .ss { + color: rgb(186, 229, 123); + } + .highlight .bp { + color: rgb(114, 255, 154); + } + .highlight .fm { + color: rgb(120, 189, 248); + } + .highlight .vc { + color: rgb(192, 108, 216); + } + .highlight .vg { + color: rgb(192, 108, 216); + } + .highlight .vi { + color: rgb(192, 108, 216); + } + .highlight .vm { + color: rgb(192, 108, 216); + } + .highlight .il { + color: rgb(123, 222, 173); + } + .rst-other-versions a { + border-color: currentcolor; + } + .ethical-sidebar .ethical-image-link, + .ethical-footer .ethical-image-link { + border-color: currentcolor; + } + .ethical-sidebar, + .ethical-footer { + background-color: rgb(27, 29, 30); + border-color: rgb(118, 110, 97); + color: rgb(211, 208, 202); + } + .ethical-sidebar ul { + list-style-image: none; + } + .ethical-sidebar ul li { + background-color: rgb(4, 62, 97); + color: rgb(216, 212, 207); + } + .ethical-sidebar a, + .ethical-sidebar a:visited, + .ethical-sidebar a:hover, + .ethical-sidebar a:active, + .ethical-footer a, + .ethical-footer a:visited, + .ethical-footer a:hover, + .ethical-footer a:active { + color: rgb(211, 208, 202); + text-decoration-color: currentcolor !important; + border-bottom-color: currentcolor !important; + } + .ethical-callout a { + color: rgb(166, 159, 147) !important; + text-decoration-color: currentcolor !important; + } + .ethical-fixedfooter { + background-color: rgb(27, 29, 30); + border-top-color: rgb(117, 109, 96); + color: rgb(188, 182, 173); + } + .ethical-fixedfooter .ethical-text::before { + background-color: rgb(49, 112, 51); + color: rgb(216, 212, 207); + } + .ethical-fixedfooter .ethical-callout { + color: rgb(171, 164, 153); + } + .ethical-fixedfooter a, + .ethical-fixedfooter a:hover, + .ethical-fixedfooter a:active, + .ethical-fixedfooter a:visited { + color: rgb(188, 182, 173); + text-decoration-color: currentcolor; + } + .ethical-rtd .ethical-sidebar { + color: rgb(182, 176, 167); + } + .ethical-alabaster a.ethical-image-link { + border-color: currentcolor !important; + } + .ethical-dark-theme .ethical-sidebar { + background-color: rgb(46, 50, 52); + border-color: rgb(114, 106, 93); + color: rgb(189, 183, 174) !important; + } + .ethical-dark-theme a, + .ethical-dark-theme a:visited { + color: rgb(205, 200, 194) !important; + border-bottom-color: currentcolor !important; + } + .ethical-dark-theme .ethical-callout a { + color: rgb(182, 176, 167) !important; + } + .keep-us-sustainable { + border-color: rgb(104, 158, 45); + } + .keep-us-sustainable a, + .keep-us-sustainable a:hover, + .keep-us-sustainable a:visited { + text-decoration-color: currentcolor; + } + .wy-nav-side .keep-us-sustainable { + color: rgb(182, 176, 167); + } + .wy-nav-side .keep-us-sustainable a { + color: rgb(209, 205, 199); + } + [data-ea-publisher].loaded a, + [data-ea-type].loaded a { + text-decoration-color: currentcolor; + } + [data-ea-publisher].loaded .ea-content, + [data-ea-type].loaded .ea-content { + background-color: rgba(0, 0, 0, 0.03); + background-image: none; + color: rgb(181, 174, 164); + } + [data-ea-publisher].loaded .ea-content a:link, + [data-ea-type].loaded .ea-content a:link { + color: rgb(181, 174, 164); + } + [data-ea-publisher].loaded .ea-content a:visited, + [data-ea-type].loaded .ea-content a:visited { + color: rgb(181, 174, 164); + } + [data-ea-publisher].loaded .ea-content a:hover, + [data-ea-type].loaded .ea-content a:hover { + color: rgb(192, 186, 178); + } + [data-ea-publisher].loaded .ea-content a:active, + [data-ea-type].loaded .ea-content a:active { + color: rgb(192, 186, 178); + } + [data-ea-publisher].loaded .ea-content a strong, + [data-ea-publisher].loaded .ea-content a b, + [data-ea-type].loaded .ea-content a strong, + [data-ea-type].loaded .ea-content a b { + color: rgb(64, 180, 248); + } + [data-ea-publisher].loaded .ea-callout a:link, + [data-ea-type].loaded .ea-callout a:link { + color: rgb(169, 162, 151); + } + [data-ea-publisher].loaded .ea-callout a:visited, + [data-ea-type].loaded .ea-callout a:visited { + color: rgb(169, 162, 151); + } + [data-ea-publisher].loaded .ea-callout a:hover, + [data-ea-type].loaded .ea-callout a:hover { + color: rgb(181, 174, 164); + } + [data-ea-publisher].loaded .ea-callout a:active, + [data-ea-type].loaded .ea-callout a:active { + color: rgb(181, 174, 164); + } + [data-ea-publisher].loaded .ea-callout a strong, + [data-ea-publisher].loaded .ea-callout a b, + [data-ea-type].loaded .ea-callout a strong, + [data-ea-type].loaded .ea-callout a b { + color: rgb(64, 180, 248); + } + [data-ea-publisher].loaded.dark .ea-content, + [data-ea-type].loaded.dark .ea-content { + background-color: rgba(19, 21, 22, 0.05); + background-image: none; + color: rgb(200, 196, 189); + } + [data-ea-publisher].loaded.dark .ea-content a:link, + [data-ea-type].loaded.dark .ea-content a:link { + color: rgb(200, 196, 189); + } + [data-ea-publisher].loaded.dark .ea-content a:visited, + [data-ea-type].loaded.dark .ea-content a:visited { + color: rgb(200, 196, 189); + } + [data-ea-publisher].loaded.dark .ea-content a:hover, + [data-ea-type].loaded.dark .ea-content a:hover { + color: rgb(212, 208, 202); + } + [data-ea-publisher].loaded.dark .ea-content a:active, + [data-ea-type].loaded.dark .ea-content a:active { + color: rgb(212, 208, 202); + } + [data-ea-publisher].loaded.dark .ea-content a strong, + [data-ea-publisher].loaded.dark .ea-content a b, + [data-ea-type].loaded.dark .ea-content a strong, + [data-ea-type].loaded.dark .ea-content a b { + color: rgb(85, 188, 249); + } + [data-ea-publisher].loaded.dark .ea-callout a:link, + [data-ea-type].loaded.dark .ea-callout a:link { + color: rgb(189, 184, 175); + } + [data-ea-publisher].loaded.dark .ea-callout a:visited, + [data-ea-type].loaded.dark .ea-callout a:visited { + color: rgb(189, 184, 175); + } + [data-ea-publisher].loaded.dark .ea-callout a:hover, + [data-ea-type].loaded.dark .ea-callout a:hover { + color: rgb(200, 196, 189); + } + [data-ea-publisher].loaded.dark .ea-callout a:active, + [data-ea-type].loaded.dark .ea-callout a:active { + color: rgb(200, 196, 189); + } + [data-ea-publisher].loaded.dark .ea-callout a strong, + [data-ea-publisher].loaded.dark .ea-callout a b, + [data-ea-type].loaded.dark .ea-callout a strong, + [data-ea-type].loaded.dark .ea-callout a b { + color: rgb(85, 188, 249); + } + @media (prefers-color-scheme: dark) { + [data-ea-publisher].loaded.adaptive .ea-content, + [data-ea-type].loaded.adaptive .ea-content { + background-color: rgba(19, 21, 22, 0.05); + background-image: none; + color: rgb(200, 196, 189); + } + [data-ea-publisher].loaded.adaptive .ea-content a:link, + [data-ea-type].loaded.adaptive .ea-content a:link { + color: rgb(200, 196, 189); + } + [data-ea-publisher].loaded.adaptive .ea-content a:visited, + [data-ea-type].loaded.adaptive .ea-content a:visited { + color: rgb(200, 196, 189); + } + [data-ea-publisher].loaded.adaptive .ea-content a:hover, + [data-ea-type].loaded.adaptive .ea-content a:hover { + color: rgb(212, 208, 202); + } + [data-ea-publisher].loaded.adaptive .ea-content a:active, + [data-ea-type].loaded.adaptive .ea-content a:active { + color: rgb(212, 208, 202); + } + [data-ea-publisher].loaded.adaptive .ea-content a strong, + [data-ea-publisher].loaded.adaptive .ea-content a b, + [data-ea-type].loaded.adaptive .ea-content a strong, + [data-ea-type].loaded.adaptive .ea-content a b { + color: rgb(85, 188, 249); + } + [data-ea-publisher].loaded.adaptive .ea-callout a:link, + [data-ea-type].loaded.adaptive .ea-callout a:link { + color: rgb(189, 184, 175); + } + [data-ea-publisher].loaded.adaptive .ea-callout a:visited, + [data-ea-type].loaded.adaptive .ea-callout a:visited { + color: rgb(189, 184, 175); + } + [data-ea-publisher].loaded.adaptive .ea-callout a:hover, + [data-ea-type].loaded.adaptive .ea-callout a:hover { + color: rgb(200, 196, 189); + } + [data-ea-publisher].loaded.adaptive .ea-callout a:active, + [data-ea-type].loaded.adaptive .ea-callout a:active { + color: rgb(200, 196, 189); + } + [data-ea-publisher].loaded.adaptive .ea-callout a strong, + [data-ea-publisher].loaded.adaptive .ea-callout a b, + [data-ea-type].loaded.adaptive .ea-callout a strong, + [data-ea-type].loaded.adaptive .ea-callout a b { + color: rgb(85, 188, 249); + } + } + [data-ea-publisher].loaded .ea-content, + [data-ea-type].loaded .ea-content { + border-color: currentcolor; + box-shadow: rgba(0, 0, 0, 0.15) 0px 2px 3px; + } + [data-ea-publisher].loaded.raised .ea-content, + [data-ea-type].loaded.raised .ea-content { + border-color: currentcolor; + box-shadow: rgba(0, 0, 0, 0.15) 0px 2px 3px; + } + [data-ea-publisher].loaded.bordered .ea-content, + [data-ea-type].loaded.bordered .ea-content { + border-color: rgba(84, 91, 95, 0.04); + box-shadow: none; + } + [data-ea-publisher].loaded.bordered.dark .ea-content, + [data-ea-type].loaded.bordered.dark .ea-content { + border-color: rgba(123, 114, 101, 0.07); + } + @media (prefers-color-scheme: dark) { + [data-ea-publisher].loaded.bordered.adaptive .ea-content, + [data-ea-type].loaded.bordered.adaptive .ea-content { + border-color: rgba(123, 114, 101, 0.07); + } + } + [data-ea-publisher].loaded.flat .ea-content, + [data-ea-type].loaded.flat .ea-content { + border-color: currentcolor; + box-shadow: none; + } + .vimvixen-hint { + background-color: rgb(98, 66, 0) !important; + border-color: rgb(170, 138, 15) !important; + color: rgb(237, 221, 175) !important; + } + #edge-translate-panel-body { + color: var(--darkreader-text--darkreader-neutral-text) !important; + } + } + + /* Override Style */ + .vimvixen-hint { + background-color: #7b5300 !important; + border-color: #d8b013 !important; + color: #f3e8c8 !important; + } + ::placeholder { + opacity: 0.5 !important; + } + a[href="https://coinmarketcap.com/"] > svg[width="94"][height="16"] > path { + fill: var(--darkreader-neutral-text) !important; + } + #edge-translate-panel-body { + color: var(--darkreader-neutral-text) !important; + } + +} diff --git a/docs/amazon_paapi.errors.rst b/docs/amazon_paapi.errors.rst new file mode 100644 index 0000000..d1e0f39 --- /dev/null +++ b/docs/amazon_paapi.errors.rst @@ -0,0 +1,21 @@ +amazon\_paapi.errors package +============================ + +Submodules +---------- + +amazon\_paapi.errors.exceptions module +-------------------------------------- + +.. automodule:: amazon_paapi.errors.exceptions + :members: + :undoc-members: + :show-inheritance: + +Module contents +--------------- + +.. automodule:: amazon_paapi.errors + :members: + :undoc-members: + :show-inheritance: diff --git a/docs/amazon_paapi.helpers.rst b/docs/amazon_paapi.helpers.rst new file mode 100644 index 0000000..35af616 --- /dev/null +++ b/docs/amazon_paapi.helpers.rst @@ -0,0 +1,45 @@ +amazon\_paapi.helpers package +============================= + +Submodules +---------- + +amazon\_paapi.helpers.arguments module +-------------------------------------- + +.. automodule:: amazon_paapi.helpers.arguments + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.helpers.generators module +--------------------------------------- + +.. automodule:: amazon_paapi.helpers.generators + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.helpers.items module +---------------------------------- + +.. automodule:: amazon_paapi.helpers.items + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.helpers.requests module +------------------------------------- + +.. automodule:: amazon_paapi.helpers.requests + :members: + :undoc-members: + :show-inheritance: + +Module contents +--------------- + +.. automodule:: amazon_paapi.helpers + :members: + :undoc-members: + :show-inheritance: diff --git a/docs/amazon_paapi.models.rst b/docs/amazon_paapi.models.rst new file mode 100644 index 0000000..ccc3bdc --- /dev/null +++ b/docs/amazon_paapi.models.rst @@ -0,0 +1,53 @@ +amazon\_paapi.models package +============================ + +Submodules +---------- + +amazon\_paapi.models.browse\_nodes\_result module +------------------------------------------------- + +.. automodule:: amazon_paapi.models.browse_nodes_result + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.models.item\_result module +---------------------------------------- + +.. automodule:: amazon_paapi.models.item_result + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.models.regions module +----------------------------------- + +.. automodule:: amazon_paapi.models.regions + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.models.search\_result module +------------------------------------------ + +.. automodule:: amazon_paapi.models.search_result + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.models.variations\_result module +---------------------------------------------- + +.. automodule:: amazon_paapi.models.variations_result + :members: + :undoc-members: + :show-inheritance: + +Module contents +--------------- + +.. automodule:: amazon_paapi.models + :members: + :undoc-members: + :show-inheritance: diff --git a/docs/amazon_paapi.rst b/docs/amazon_paapi.rst new file mode 100644 index 0000000..3d06cae --- /dev/null +++ b/docs/amazon_paapi.rst @@ -0,0 +1,33 @@ +amazon\_paapi package +===================== + +Subpackages +----------- + +.. toctree:: + :maxdepth: 4 + + amazon_paapi.errors + amazon_paapi.helpers + amazon_paapi.models + amazon_paapi.sdk + amazon_paapi.tools + +Submodules +---------- + +amazon\_paapi.api module +------------------------ + +.. automodule:: amazon_paapi.api + :members: + :undoc-members: + :show-inheritance: + +Module contents +--------------- + +.. automodule:: amazon_paapi + :members: + :undoc-members: + :show-inheritance: diff --git a/docs/amazon_paapi.sdk.api.rst b/docs/amazon_paapi.sdk.api.rst new file mode 100644 index 0000000..9780972 --- /dev/null +++ b/docs/amazon_paapi.sdk.api.rst @@ -0,0 +1,21 @@ +amazon\_paapi.sdk.api package +============================= + +Submodules +---------- + +amazon\_paapi.sdk.api.default\_api module +----------------------------------------- + +.. automodule:: amazon_paapi.sdk.api.default_api + :members: + :undoc-members: + :show-inheritance: + +Module contents +--------------- + +.. automodule:: amazon_paapi.sdk.api + :members: + :undoc-members: + :show-inheritance: diff --git a/docs/amazon_paapi.sdk.auth.rst b/docs/amazon_paapi.sdk.auth.rst new file mode 100644 index 0000000..0e158c5 --- /dev/null +++ b/docs/amazon_paapi.sdk.auth.rst @@ -0,0 +1,21 @@ +amazon\_paapi.sdk.auth package +============================== + +Submodules +---------- + +amazon\_paapi.sdk.auth.sign\_helper module +------------------------------------------ + +.. automodule:: amazon_paapi.sdk.auth.sign_helper + :members: + :undoc-members: + :show-inheritance: + +Module contents +--------------- + +.. automodule:: amazon_paapi.sdk.auth + :members: + :undoc-members: + :show-inheritance: diff --git a/docs/amazon_paapi.sdk.models.rst b/docs/amazon_paapi.sdk.models.rst new file mode 100644 index 0000000..b62db90 --- /dev/null +++ b/docs/amazon_paapi.sdk.models.rst @@ -0,0 +1,717 @@ +amazon\_paapi.sdk.models package +================================ + +Submodules +---------- + +amazon\_paapi.sdk.models.availability module +-------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.availability + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.browse\_node module +-------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.browse_node + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.browse\_node\_ancestor module +------------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.browse_node_ancestor + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.browse\_node\_child module +--------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.browse_node_child + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.browse\_node\_info module +-------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.browse_node_info + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.browse\_nodes\_result module +----------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.browse_nodes_result + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.by\_line\_info module +---------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.by_line_info + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.classifications module +----------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.classifications + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.condition module +----------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.condition + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.content\_info module +--------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.content_info + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.content\_rating module +----------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.content_rating + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.contributor module +------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.contributor + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.customer\_reviews module +------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.customer_reviews + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.delivery\_flag module +---------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.delivery_flag + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.dimension\_based\_attribute module +----------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.dimension_based_attribute + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.duration\_price module +----------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.duration_price + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.error\_data module +------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.error_data + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.external\_ids module +--------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.external_ids + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.get\_browse\_nodes\_request module +----------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.get_browse_nodes_request + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.get\_browse\_nodes\_resource module +------------------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.get_browse_nodes_resource + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.get\_browse\_nodes\_response module +------------------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.get_browse_nodes_response + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.get\_items\_request module +--------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.get_items_request + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.get\_items\_resource module +---------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.get_items_resource + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.get\_items\_response module +---------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.get_items_response + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.get\_variations\_request module +-------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.get_variations_request + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.get\_variations\_resource module +--------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.get_variations_resource + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.get\_variations\_response module +--------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.get_variations_response + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.image\_size module +------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.image_size + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.image\_type module +------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.image_type + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.images module +-------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.images + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.item module +------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.item + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.item\_id\_type module +---------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.item_id_type + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.item\_info module +------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.item_info + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.items\_result module +--------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.items_result + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.language\_type module +---------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.language_type + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.languages module +----------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.languages + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.manufacture\_info module +------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.manufacture_info + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.max\_price module +------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.max_price + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.merchant module +---------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.merchant + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.min\_price module +------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.min_price + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.min\_reviews\_rating module +---------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.min_reviews_rating + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.min\_saving\_percent module +---------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.min_saving_percent + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.multi\_valued\_attribute module +-------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.multi_valued_attribute + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_availability module +--------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.offer_availability + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_condition module +------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.offer_condition + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_condition\_note module +------------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.offer_condition_note + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_count module +-------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.offer_count + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_delivery\_info module +----------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.offer_delivery_info + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_listing module +---------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.offer_listing + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_loyalty\_points module +------------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.offer_loyalty_points + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_merchant\_info module +----------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.offer_merchant_info + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_price module +-------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.offer_price + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_program\_eligibility module +----------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.offer_program_eligibility + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_promotion module +------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.offer_promotion + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_savings module +---------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.offer_savings + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_shipping\_charge module +------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.offer_shipping_charge + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_sub\_condition module +----------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.offer_sub_condition + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offer\_summary module +---------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.offer_summary + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.offers module +-------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.offers + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.partner\_type module +--------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.partner_type + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.price module +------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.price + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.product\_advertising\_api\_client\_exception module +---------------------------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.product_advertising_api_client_exception + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.product\_advertising\_api\_service\_exception module +----------------------------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.product_advertising_api_service_exception + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.product\_info module +--------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.product_info + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.properties module +------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.properties + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.rating module +-------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.rating + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.refinement module +------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.refinement + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.refinement\_bin module +----------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.refinement_bin + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.rental\_offer\_listing module +------------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.rental_offer_listing + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.rental\_offers module +---------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.rental_offers + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.search\_items\_request module +------------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.search_items_request + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.search\_items\_resource module +------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.search_items_resource + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.search\_items\_response module +------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.search_items_response + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.search\_refinements module +--------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.search_refinements + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.search\_result module +---------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.search_result + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.single\_boolean\_valued\_attribute module +------------------------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.single_boolean_valued_attribute + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.single\_integer\_valued\_attribute module +------------------------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.single_integer_valued_attribute + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.single\_string\_valued\_attribute module +----------------------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.single_string_valued_attribute + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.sort\_by module +---------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.sort_by + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.technical\_info module +----------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.technical_info + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.trade\_in\_info module +----------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.trade_in_info + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.trade\_in\_price module +------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.trade_in_price + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.unit\_based\_attribute module +------------------------------------------------------ + +.. automodule:: amazon_paapi.sdk.models.unit_based_attribute + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.variation\_attribute module +---------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.variation_attribute + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.variation\_dimension module +---------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.variation_dimension + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.variation\_summary module +-------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.variation_summary + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.variations\_result module +-------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.variations_result + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.models.website\_sales\_rank module +---------------------------------------------------- + +.. automodule:: amazon_paapi.sdk.models.website_sales_rank + :members: + :undoc-members: + :show-inheritance: + +Module contents +--------------- + +.. automodule:: amazon_paapi.sdk.models + :members: + :undoc-members: + :show-inheritance: diff --git a/docs/amazon_paapi.sdk.rst b/docs/amazon_paapi.sdk.rst new file mode 100644 index 0000000..9e2e401 --- /dev/null +++ b/docs/amazon_paapi.sdk.rst @@ -0,0 +1,47 @@ +amazon\_paapi.sdk package +========================= + +Subpackages +----------- + +.. toctree:: + :maxdepth: 4 + + amazon_paapi.sdk.api + amazon_paapi.sdk.auth + amazon_paapi.sdk.models + +Submodules +---------- + +amazon\_paapi.sdk.api\_client module +------------------------------------ + +.. automodule:: amazon_paapi.sdk.api_client + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.configuration module +-------------------------------------- + +.. automodule:: amazon_paapi.sdk.configuration + :members: + :undoc-members: + :show-inheritance: + +amazon\_paapi.sdk.rest module +----------------------------- + +.. automodule:: amazon_paapi.sdk.rest + :members: + :undoc-members: + :show-inheritance: + +Module contents +--------------- + +.. automodule:: amazon_paapi.sdk + :members: + :undoc-members: + :show-inheritance: diff --git a/docs/amazon_paapi.tools.rst b/docs/amazon_paapi.tools.rst new file mode 100644 index 0000000..ec825a5 --- /dev/null +++ b/docs/amazon_paapi.tools.rst @@ -0,0 +1,21 @@ +amazon\_paapi.tools package +=========================== + +Submodules +---------- + +amazon\_paapi.tools.asin module +------------------------------- + +.. automodule:: amazon_paapi.tools.asin + :members: + :undoc-members: + :show-inheritance: + +Module contents +--------------- + +.. automodule:: amazon_paapi.tools + :members: + :undoc-members: + :show-inheritance: diff --git a/docs/conf.py b/docs/conf.py index 32e7211..0f46e07 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -31,9 +31,14 @@ # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. extensions = [ - 'sphinx.ext.autodoc' + 'sphinx.ext.autodoc', + 'sphinx.ext.napoleon' ] +# Don't show type hints in the signature - that just makes it hardly readable +# and we document the types anyway +autodoc_typehints = 'none' + # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] @@ -42,6 +47,12 @@ # This pattern also affects html_static_path and html_extra_path. exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] +# The name of the Pygments (syntax highlighting) style to use. +pygments_style = 'sphinx' + +# If true, `todo` and `todoList` produce output, else they produce nothing. +todo_include_todos = False + # -- Options for HTML output ------------------------------------------------- @@ -50,7 +61,31 @@ # html_theme = 'sphinx_rtd_theme' +html_theme_options = { + 'style_external_links': True, +} + # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, # so a file named "default.css" will overwrite the builtin "default.css". html_static_path = ['_static'] + +# The name of an image file (relative to this directory) to place at the top +# of the sidebar. +html_logo = 'pa-paapi-logo.png' + +# The name of an image file (within the static path) to use as favicon of the +# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32 +# pixels large. +html_favicon = 'pa-paapi-icon.ico' + + +# -- script stuff -------------------------------------------------------- + +def autodoc_skip_member(app, what, name, obj, skip, options): + pass + + +def setup(app): + app.add_css_file("dark.css") + app.connect('autodoc-skip-member', autodoc_skip_member) diff --git a/docs/modules.rst b/docs/modules.rst new file mode 100644 index 0000000..40b7a42 --- /dev/null +++ b/docs/modules.rst @@ -0,0 +1,7 @@ +amazon_paapi +============ + +.. toctree:: + :maxdepth: 4 + + amazon_paapi diff --git a/docs/pa-paapi-icon.ico b/docs/pa-paapi-icon.ico new file mode 100644 index 0000000000000000000000000000000000000000..96c8f63980862d9945de9a4ddc4d6bc5e113fe00 GIT binary patch literal 48712 zcmcG#2RzmN`#*lnl!~Tkk5mZTvq8HH42N2QQ)?3q<~ z{jb;IbgR2Q_x<_&f8TeH%ln+udB3jb^%~bc1Of$thQP>3fIBO}gqlE5ClCm0*37>5 zUq~S2!DpHWMv(WU}~C=&r{xQoV`3B<*n7I>F%T3|52Twoy4T%h)ng+Nr2rNG|gGXhj_ z|M6sm5kDcqm_#cgO$7Yl`L0+~K9pd_ixN)rp^HG5PV=Hm=5V(V=zwS4lPv`pfe4p@ z!r}RFL;jT)jQFob8uQIuFx`V3ZB8OJ_YfrIa}~+>q#;c=f8=3z3|+JkM3*cDrr_CR z@)!ZeBGh4q{DBt?`DQ#Ul#zmG0uuClK)N4y@kJ+G{gAR(0uuGRjZV7zA(yk-DAY!N zI>my|J>`r5rTVR>Qs-?{x;;(h&`}qEWNvGMf=&0K1WOTg(NYM-nQ)_cQyvs$A&M*= z&5^oi7_vNPjZ!Rl+dvi}sTW--W)}jGpV2-PV7w2(9HN420jQ&~5~vEjxEX>T#8{)6 z{A(z|^AtL3uZx1L6=5#;@q9!|Jn#B^@NOycv6Mq0x?Jdnzdo869Y#~%CQ(yWA?p3o zfF`~UA$*l($DxZRTrj8n=%Tp*O0*EDktiTeN)~n^-HVrypW$BgAoeWjyTs;t6ykIQ zUAh*7#=lRYv1x>Y^YW1YIW<@tSfA4Zc#HvweBvaGfusuB(DBO|DDZL|8XBKKgI`CG zN9j9cTHb+rCa2KQ_i1EY+lNj(EJC4<2gqX#isuoVVGM-F09laC^9~gFegJ(Q{f>we z)9B;Z@95ji3>y44jZCV0km8#zWS*9YVowXAc-UiN&xq+T1|p9k`<#eQz3xV5s(MKj z-Z+GYfj55MxT*&!yy`?pp4X!Q7c~@b!V|YYmna8g^x`qZ0EgPkZuEZS8~Ox%Eny7T zx_FE|CVt2!}Bc9zzP`NNE~D6Vo%K=SJaK zc!?f#j-mrEJCVXmB2p|R&Kxdm@GIIypn~TKKx<%(J9rE+7(*7;!=bt#U2Yyh*IU0L zzxRXaaA_BkD<&d^65){N&k=@2A%aMJwy8cxj!+Wb3k8E z#h3|jg3hr8opT@d#0S`$y`Xn`V1G8i9?ybvVgbYfx`%SU?wLQ<{MS)1ZlVcEpKXEh zLx4{cj6VhA<2^^(`*{BY5Ar$s4>vAuydCW2nV`ssJqtghpuiZB*X1ASMI&pYry zzyrnMa|L?uq8SfLBoQx41pNp46Q5Ol-e+L^3K&~4)lz`sS011P31LS3RB$&1J_Eo5 z^a($TG2ulQ%!HAfwHh*YvPGv{y^*%7CpzP3iF|Ahp*V}ZD9IdjEbvGIO19+hg0WA| z=K(sBfX4@2dkl2$0K7(#M!YD*R21nsIU&yABE%Tgg%-#3BZlZ65-pAHLo1`&5ns?V zWZ`Uu;w^+w?3sNi)@nbQhaz4NEJvsTA0bSiX9w_k4?IwWAul>>bqw(YJVoon>yenx z4W#enh#YNCB2TMB$jkaLa<)5#jLtbCX`ghoHM9)L`&>q@4yTa5n+Hm?+=F23w=nib z%!7asm93wBREVJ<0v_nJttsO3e}vRr0+6@4JV}-)LoS3V+L#-~n)0G}(t7Za^moV^ z8D!w%f@~d4kc@9S^0z&Rl0gT<*ypc13J}Cfhxv}&dC}%)E`@xJ#gLYx6LL3KMv;a* zAPbCPErD)_nxLFGdz2YufG*ldplDc^1WRFb!%Gdtg1xYCvP7!qW06q61LSLa2-bpR z^F9C%4yosz9x?^3Gj`|Cpin(t6l%ba!VUOPm;oR+Sp-zLz^%rxoV+VC3P z4$?;@nc--3um_c9MW6(0F%)Jgi6Ski?K_U8l zBpw%x_n`XH9Fk4Ie=v{1?pE||a-1|Swl(;g{yvHFFMFUkn70J5FLU;Rv~OYW-UeMl z1Rh8_zZF^eIie6f9uy2b;_c+oKxYeS4E*O!P7+GAl}1l4I)U99{PB7J$Pl^`cA7N) z{4+?hW99<&p#Q&N8zKodMCoBQayqArf_1skMLPvF)YDEHX9_T8T(Csm)(Xfm&;h+_ zYWgvLLC+}CeDV^x2cAJco%7i<-c25VJ`eL?59D|DDEjoiVs;#u`|B0eNabk_k}hgT zX{{qa#(&T?ij=^19Vz;NJOj*0duyH?J)pC@$Tn=2M<
_Cc-YS8)0Rl>q__M!;5LPGll8!1xvM_^)SqSS3Y)z5<;!s}t{o-SH*cz+ZWgZIDVyCo-+*MPBs- zDC*M?ssMiE3)@F*Ta_`7H=Rg5zZwNQs=|8nVZCb$c1Z}vCt~|JUk*H1&Ncn$4$R5p zt}&!r-h;%zhrpEf<*)hA#^ZzS1-m)R18lf`v^V%?yq`h0bAs)|c03WwFrNqZ36j8` zldoLhp$|OFK#sbhzwoESTFaG?Y&(gE(wlCiefKd6x0VVn+)JRCv#;E6Z<@~okALb_ zH~I|z2EOpT4}h;S1T?$ii1ga7rjIoKod1B7V4hTqo8DO@MROQkzlQBUL1NYq&<7r0 z$!h_29APpo??olO6C_`VJnkeoCfLsk{4j_Vz_*YG{NNXmeUyHfD>dw6z?zUu8RoGM z<_Yc&zw*Fx$irST0zU3_1IP!~*d8#ezXG4Gh~#@9@I7Y7FCh+q9Ht-x6&`>7g?Rws zwa^1_HG4a^g4`T%q2f}e6>4E_8-}qs(U!MINb6S7^L;+`N4V>G9Kp~*#a={+d z19gDU)DAkk4t$zNU>AJB_9y_YOtS|+;LPuRrupOl={5G*B25J-z?a$rzLXpIgyn$Y z>zsc2lixN2yoZ5Gz{c7FZ2%%*`nOkvi68;|I82P-%h>>qM!+xw{1Nac(LZ1y`CWiv z8u-=%8Gz41kA0$lx*|<}#Lip6*UJJ7-^u;G8_OaO)y;J+SYNcjT}9JgbC5QrCi&DTH(`^t9r(Y& zzUVA}@JRtjH1IxesSL5Z58@8YN2?-R(ZbjfL>)JYXyPWoM;$~g5shds_*sT7=TNAX zEaVpe$81aueizBFBV!=V1Ng!}AYlGL%Yp7=UlsGm6lKJNd{4_D6^|&i5_nR?&ye`C zTxdkwLS7;6pgf>_c>NkNM|>jvA65K!v@YTU(sJ`gF_z#PgCFSV2>ziZ_~e$@7boQ^ ze(Z;sW9$S3NWfoq2L97Ph~zID@gWO4W5gO(jp$|7H6l@@X&RVJ=e`8T}!GH(Bz61<> za1QpMtS~cF`RqFSTv>=3-#$a-k5f=qh!Ny2U>)FWTy|DMukXjATYj1-;g5u_RK#Q#lU~1R3T9Ze6|UN+z-h0>~T^o5T?%yaR7NOfWNUID$0yN zljC1WKE?b$lVc;O{82LSRz{8GPf7pPPi#Wj5oRR)kO(@0L~t&#ZkVSZhCoNigUw0> z3`p`t7t%|(2tGVN3V~Pz6OKtj^m)+DKtnV>mvbWXo`D?B^wg}6gYUgz0T>__ zCe48W#7hr<8osIe1&V^abf`RsPMN{vW@|dRvChduq?+wfKK)udv+&|A7?e zkTJl1MB0~9ke|u^AM;RKeE+BMYhGkQoGy&K9o3Lc$T{Tu^cfn1ycGEw2S3ohz8|R; zH6q)KAt)MjP&~wN^Wqb7uA?3Je<%4#cn;>~0q=(sS8hY>eGCP_eki;VN*D_&Xl=D9zIq<=?!FTS4oFMtaIWnu-UZe;1M|m(gMF-3HYBX??#;yzu^x)^#O=I4wg0}w;*fK z3!ocj;~R3$rylrM1I@-!WDIye0^wK+bOTTqDaPrWgrw=*g>!(!@hSAWe*zWvjsG+F zN&IViXX7v6k1^nRu#FGG@fSJ9!*dY~{EdOW{e%J5fV>}P=K-Hj?4x&(@{U?%-K0Ef zG{k&2+PRJ8}5B^7}9He90xJsWKI!G9q6 zU~@4dGu-okhXM0ffSkt7)~}>I{Cr-&zOEnsh78{JkaO##*!M?_J-ZgS6<-q>$uTen z05LEr-Uj}79qRvtK?d^p=O8!ntZN*7f%U+$>}wZL@%Y0ynaUUnhfH$4!a_aH6csS3Fm zydTN2`CRNgKL_vzFz^BqF#q3O7=zd>20RZ1a3*F*d-6B>3F`-Od`7XZg!4&?+voUW z`7!@F3{$WV?gMSd@jK@KpDw%>cpiXo4aFBQbpALKf7H{naXm@?pD}!a8jBOG!*U$o zLq6m`vHt1*NEn_HsenH}@Q(y)1l>f^lRw$3AGYELhDnJ1>tPN8fp*Fl5h-CFej59~ zc?0}$&VdT}bHH9O1`OALY5+q&ticoz&O7u1Rf3&Jh5UvN@Mi;}1o}r-$b$;aKsJ4f zKoFZC5H=1H2n@{x!h!+T13(|< z1O6vKCx94${;Ryszmah+@3RncF2^D7^BV9^kz?GyV$9hb`Tr;bIsV3S$U!cE=GR=v zzrp$IcOr}h2~no}IA_HUlmht2aNY=H_$f~R*D}C9BG*Fa_R{=yAmuRte?L$l;Ag@z z{I7CAJP-XMe7I*s0`g7eINyYcgdgsB{>g;#|38*t8gM@W+Wo)C068K;s6IahU_T1< z1?Wf4>~}KYn(%CXf(Io)4+)M1VsP%jTnNRO?|9@jVm-_`&Y^M# zK0^mQV~~NNQfq~aBec%jdLDY6-IypxCkV=RpO z3bp#HD8xz*rJUwQPLBF$U(h`iWhL<=#|!H)1NZ|V&rJ>YpF{}N=Ou(1;@$*)L!e2F zf4&S6xc|XK7#(&CK}%x#NIaK9?}MO!HZpLuha9vLih#UNtO?H?@siFnKGV3@1Lqyd z{T?_s9|va}=OL}2PfQlh1q_7Z7&2BKtgzXt3htXl!Q z9NY=>^V9|x;|RJ*Nv!^-#cOb$6l9po*TUX`z5!n|DJ0~Zg{Tsy(DJAbB?hniLO#_lW>h8R*P0wURIya?c%6AnHqC&)f;J7?!(J(ug9%`t`pb}utov@589 zljjHr2at!u3Fw(2 z^=FV}z}6Fw(=C<4|6pBJoSv3>Y;9b#Zlk$P8P9U?6EBMr|G=!;23M?Ei~gXd!q zdw4ah_jh#0`3&qK9#VcAd_D4cehl~*V;LYWz@!WPiBkt2Re>H?K%u0b5I*E-3hQcr z1_eT&2r1|Ni%ufxSCHq@Sq1bk!HLwJR;hn(xi=Q(svC(YMOFEYYOILLVabjNbkKF=ieB0afu zj+7@SfA`z?C`q1+pmWGMNQis>jo)1g_*X)Fc?xKPgdb#(DfogMJWQcS75Dx8Tr(ic z5DIH@-A@;djr5aY{No+>JAJ8pi3YpA{O!BbQ{PZ^KGcz{MPV&|$!B9(evW_0J}Zua zL?E{v0r=q_gh%F zmXv?hA0^mGqPR2S=yr%PB7Um=?RUu^;`uMS9so6PQvQ~N{crexzYehy1sxx8&gjP) z;I)8y%Yg@Pkq77mTyG(*0a*s9`&@KTLc_g8GW(zI4X+-Nd~K{#vCk21z>U(qG!UNO zKV9{0Ehyx?Hs~io()|By8|IybUuA%t0OVWxF#f;GFxzA2YbK6@$uht>4hH;*jw)!R zzw5Vfo@a!iFnw+kcHC2lYn&mbLa6ZRpZ8l#^B_`%{H@v5R1|{y!G6x=|8<%joE%H%O`I3z9E|ye*J!MGu-^=OI6Ud#jx40YB6d z4!i*Z8II+>MgDHb|4|0eOCKR;H%P+&A7$u5ijV7%VN4WqanwXUref&vjqsmx`(!-b zkaM=E89>s-oj-ECxZms7S{V8J7{4PKKdBxxE5oUWg(%!kj?`QDAI?L$cwWb6km08~ z+3(JS6y)ipK)1@}eMTzTZ;;NDx2S$-f(+xQdlTf)eW34A?R6KaRv=T{fsRAJBXM3W zkNf}$|GPfu_Xpe<{|_0u(CI5lq#8WN{|6bK0QTn?|G$y}+i0l$NkQFD0_3r&?)#~} zM8<^g7}uw--$=ci*P#}6v;8ZnCvX0D$lr6s_;J4?89zye+4`iXpBbrE{s$RwPg^`0 zKdy)T(_SLk2W%t2SHiEc4DX;u@%NMYE7IS;$8w$p{PGz8ym}g52W6;3X=mr6NGmat zZ}E!^)1ZrN0ly*8k2>S;Wcby-&6fe!7}Vf56S(GB1AUt0zSiHP{rji$@&8&A#OGP% zO$Ry`=18s${)m6TzTteU6kz88Y6tpJr~Geaz%>#qhYI{|1oxZbKFzDpXNv2IZwDqx zy_?;z_vhEy$ddfP4|ODr|5q9C8fZPpLy-`NVf#EUhN}ep%uqw12gpGQh$_T&ey~7f(GbyL#UJ4!5Q#t7(}5k@3@au z8gS!U6`7!3f=+-g!u8W%FVg(a;V0Eoe*DrnMRHe**fc z&iW@Aa9`|csCl=JeJAM@jDdW9@i~xyo@g?5e8>280Yg97hF>rI`z1U0y%xEr`L{Aa zkHC@V4Jgq0@N8bgOrQj?UHE!h~N3 z!f&H~^L5gBKMnm4B>b?4F#f;EfOQe{8Q4diN3q7dQxJ#Z`U9?^kn%utb;TWU|NM_K zz}(~drV{A?s(F3wWI3=zWzhTKJlBt)4f7rV*gJl+cknYUu!hG08>uH7$A8g9Pm2=P5&DiaJ|^Keh__w_5a<4_Y|&QW1r_c_-KE+Nd5ft z`pHT4?BB>h>M?lUFm^83_PEB=*FS3f^JM@zRsuZ%8PGq;fOV`a*y4NbKleEN3Fq%V z$GstDl|4xIuYUEv`U2);AnT+#y_&38-nCHSZ4Vjtk2_w2Iob>N=6@@La#1JBY#T+m zH|xK-x&XTe{FVcs?;rgHe^`e(8OlJ0%|Jge|M~*s2i#bW6F`H%%J4fs1Fr+_J8*&i zhtj?Y((gb2Bnkc;?`f`1=E>Pf)AN0=j0U&!xe_yRIWz`6cgf5h)(0POhpmX<)n z|3(Jvuj2C{2m8qodU~*~x%TBNde}LJ@}aNl5!|n}entN9xgOXH{QFF-m&m;g`2By7 zp%ZW)mAn7v{)#`yfPa5s3HbljI*@&CY#a6i;XAg?*v?^piEN`u{TTCX+ds(A2IpA~ zh~l66GyWh0UWXGP!_Vho&fg~OCz$tNeb!(7jQRc^wq+#xXBnztKgj@5;Qo^ThL({*O zVa`{=eV=#@{$U+v0BK9|ZpDXQ1hS^jZH&h9cq= z=+HW#b3hxlV9xQp|6g5zogn%Q`s$t$Hv@iipd63^_q%@olfO4VH#WBplW?wEKnLA| zv!DZdbRF0*3c&w=1^aK~0&c<_(F1;Nz-|O|5vUN(Lle*loP%i~+>10QSI?%Pj-gwAiRJtt@MBxPgdX2v)2 z?E7lB(vmx}bfk2dgCKoObQ;z6JMCY`m)|kJqxN22y_zlM)N?&k+nruVd`f89WHtsC zT>Eavd)t)yU~p=txl??`m5zuA=5Of+^i~@O<2c$jEIgl}BhM5}@5yiH8Ktvk`KbkL z)Re_V{0Ddzv5A{R87)5OE40pM58YzjH2SsinuBSJ3sg-Wt8Nes-)h1+{%VDAe|zCaEj^$qX|o#@EYH5DiswE!iD_11Vk6bmYPOYS+N|6JvO|JYH+Cp zPb!uCon56ytdYyE+^?x#D|DdquvfSuyD++{su+xMHXQERY2TJCt#Z@qXz<8sZ_IyY?0M7KQQ z;I^-{FJAezQSdpp&6ux?wj8r0&lL}u^ZUk1&Gx(01<}PFS3b3?{}AoLMJ$T1+q5^w zvrpV&jrLLQ*H=>8%rz>l;@ov#b7cWbvwgt=M*i}d_iU>rhc#5E+6P}ZE{Iw-{IWn* zpzsCV;YrEK(J1j9^t?xM`xT|asg(_b`9n_D`+W2>=9CJjboOg_V#u5|(f>x_1PkZK zm#>Z~`iQAMO~Dnp$;nd*kjYy5hwf*j_GPlo~)8%O3v9)Z*1*<;{haHo*l)7jM>STO-*& zDaO7e=&<+z>%~1>t%kABynYKUqH>UBCB#-@@EZW+=za?OSB48_puTJ~?N2gM5B+W3qzTWV})OFDeQt9lbP z#fs+=bn!wRhXyUz4VAHOoqTvk^SKh&IT{5eeKnQgij!ZA1*sTUTCip=-h9~WsCsz0 zijvc*BfjacDf8%r2lbk3wyEV0A5%mxbe~Oz&x~xD6kRZBQgF^TIkP~+Q~QV{=eC=> z0-2vgh0AZhs?(A5%v5~y^&EN`SwHp==C-jZRf|)?K@&(&-| z?$nSACXLc&2=7OzmcW(X*-wT~Rra@e^WK(_dGp3{}wY8y-u$I^vPrvhmVzq|EpwqhZ z5xb37xu43iZqvHjDf8`VUyZRv>Q_~!_Wha%7q@Uc6kYwq+G3%8B=<6=P8MlN#wDxQ zFxv94(KDovo%xvXapWUQhOkYMw(ffY@F?M1%bI4{X6xovWnWA7N^5y^CM=p@ z2`WrIw1#DcatU>{q;*iYPw?5cQ?8n^HZACs;t8|R&F&lIVrawZd+*#2SEl1QBD8Ab zXt+!GSPG>>-jc+8R@+-W+wz|r{(hTn!$YPvxkY&noHh8k62A4^^YxI z%)4IupptAj`;5iMn4#){+z9V>^9r#Qqt9qci_cz*^lIS=kbp)ktma&TzGWI^7- zbtyZCM5ODe)!hBgDZaDbIoZ>ujQB%o`YCVIymLP0y{U~R{Oa}>Ed_BpI?{|`^fFVl z4^p||=zHwajJ0kt%(64+;}Y>>S)3)@wk7YNr|@}w7QYgoMPEvHJ-X(yF#VkK3U0dG zYn>k>WS;R4xF6EK+V^4ep|EpqFVAmRBkI-WG&ddei@GVP#mQ}Fc%CJ}V`f>QL9nTa z=f9S)Zk_K?Kq9f= z%{x}(zNTzLX5!31M(NSiF(y4-W{*_61OrKZt41B}tC6p~QkC)-ZfriRL-)ww9ao+F z_2Ww(?{cPQbQiGSadUd4d4s(=(T@6}M;Ij=!=)&1^#ZyQj#T%fj6n-;?L4CSDX>&- zLiBN>#!RzbrA17R^3elR2kB{9*T?O*-!gP$d&rAcTEDG!5zO57U9q}ZjG3&KG`Afz zGF7Bpo?T}7lBJLmrdj@4X=75i3yppEAT`6KXdjN+?b6$I_tN^6P_Kv-(r-DbNwq!2 z*uPIRcKB@5)2L(bbewvqkAK`Kc_W0D)zDNng{bBl;>i=~87J{!Ikg%45XEOYy)}-y z@0V+7XPY&;YIQrlJKXr>yUW+n?@tD@T3DDu)I4m~?x&m**`eymRl1Rjp)GMBEz-*B zDEEdH@)zH0p3lt~xUuD=)%y&20|E61VUwFCN8*xqdEB-!NRJRwbFXH#@Jv-$oXPRF znxk2fQ7rj>t;-5j8ziV5;Z70IWU*eu_1&WT!f5Xfw-mG37G-6NB{p}d{cJR;LzKJB3jad%JT~Kl4{eCsz)lkoHi@6Ot05=ZPOlTWRuKe%x9{-pVeeB zI_W=<%*AB>Uf7sYl@d`;HA)2CPFYB&;hNpuQ0Ro%>)5PQ-3ofFoUZSu5UP}QN`t(@C(-3zyt zHL?^f7qltsxKy85o>XP@&Mvt9`8l78<&-UNWpS;sy zx>T9}owOiMd_ zVS0~%@Zxo<7a3KChxK!Kk``~0w(vHwSmVK=U_i~Rlu|GI?ez6xbmN<`&%--;OW_GCQeD@D{erMvX{Z6m7^IGER3bUd$9wS9L_w3qp`WCq2G!DI@$g4IQb zWizk1uX#lCU_xza_VWrgrJTt@(_O4X-`xat^8A}LuDa~D+Ir_ht67xH&Q(`Zc}kvE zI1(81Xwb^bw7V2JYFJ(=AGm__bhx@_a@XyUchlD5XKGB@v8qPj=gH<7=jbWRfTpVZ z+J3@HgOm)B+vrc-XWn4ZF;yqB_whLE0uC0}ddew70%dr({Ar=nSF`pmZIHR}L@h1W zh)vRkcyS`*#*wNz4dXnwEc?b)XXI#>JgZjATqJL}#E$*NX+cYl=(@Y<`QGhZRHd3T zd( zWpc}NPvV^b`ggs};pq9ay(Yy+2TiMOYR*#Ch$^QecP8Y znTuT7`5&K*u<1TioDu%8<7kbH^{3>N=l-q|`}8+?DQLNssh1p?ai(_Jr*?3~8esNpQC7QEx=yyRo7n@!pob~_=QyjX*6CXv$uqy;bZ_FR zuT^76HlI9aXj#bx2bORl8W~n;LaN^~XS!6ss%%yh4#_r#%k%}ZuW#Kvz2&YUrO0}@ z6AD)cik8#qZVHy=XJ7Pun~;HDP=61vQ+FCmTJ-&!12PsgpXF9D1s%9T_4NV62-mfJ zWlxb6Th1*l&#WYhwsdz{ougdST*XXZ&IUO}tge%vIo$MSXSJf9rnP|sC8LR_;MYOD z;L^jv2N|B5%kr^QmT~Z>E!3n7_AZE z^DR@+F)q0iF>TQL^i|2Yj*8@++`Vgr@@SDpH!BKA)kw6ss2(Y#whFl|=S@>^RGmz^DIQ`mj&vD5b* ztM`Ox7&2TBr7(#&dV*c^Svy+S+#$63ZL#Wz#MFrH;2RM$fjc$FUcERXz0pJ{;2`lm z^~bkG{ySy(T*WT;n|q(|5U-)7Jh0Y(x7!kVdQJgxqb~}}sUAkGdvd<4P0*Wr6(2W? z?Ts&qxtt@*oP;(OiDi6d@?2PJ$bUO^;j6Y|E4Z}BSBklRbsP)ZQ?)GM+&jvf`h>%b zN@jJRJ?s__5^XZtm)f(m6Im2pb28VA8HhbMVXd`a>KPMBmy;x!(tgEh&G`j%>qTqN zZ|G*Lbz17+9M@L4{>sY@TX+UFcvomvp1)*b#CfD7t$K-2Z&t$Hw@gE^w+6+oU%c+t zYDkxMgEdHa!KB}c4XtVJ!m*+9jU&8{#)O2;(N*#WH-!h9{GMc$zq+h8(G}0we$DIV ztu}&#!(#S(!JYT^)ZFPkU|2Wk?7P~8z4{!_h0j5zCr0<{opYDCjGTERKQ42oa=!l5 zTlOH)bHA2I!Y5+Z!H=KwA6claSkAej!|Baf<;T5+1|^&IjP`|8K4m^6zJvYdW5V5q z(NE8mtm%*%e%fiQb$N=KZV9JTcv(a1nhV9*$x{~2T2}O#FWp-FH_ybwZcR|n3+g9+ z7XQ95R#!Ua0&|o1B^JVkJ>qZuo@NF5b5!hZs8;fNy}eoZX*hwlb=fZ_$E9rgewhHneaJ5v!I?t(Nxt zDDI|drqh$#-B6zG*Sh)s=P0K$#uRq`>2|y^gWcZ|i`9jURb%D#1B`iod2e^7d1fo9 znoD)+o(MxbP8rW6lwMY1Oz67X%DzCdQ~LYv^qyetn%s`_4e{3ZhCc0>D1A@)q_5I- zz3M3;j+uS$QX@iqKOK;>alCwiFQ&IWG5YD=y;aSo4xjl6+vN?1ZaU;Hn-B*Pg*37H zKD?1FPjXGe4T|a&s+D(omwZihUAyGX=UyB0ip6xhq({2PYo-%3c+xoK!$gw1DGPCq7AJge=xd%(m~{Ymm!(ag1I`Z(JVXQBV?E8m6cD<2K7H{eJvc^gd3_FR`F zWaj>O>3+K0@^TgNn$3}SWwq{oGZl1LZ^XU9T2y9y^G+S!?RU)UPk)qD(9W+JjURcl zNTyq-g3InoG%Md-ANi&?UBV+QUKYlW28i*CQ)}+^w`Si$i$P^^@+l6jVz6J)qcCq+*bK2$1En~aImONT*IC(b5ir(STOZP8K z&kIx-E`;=@7``wz6>EPA!Z6r6Iiy&3iB-Ez?YSGV;LiOt8ZF9)$2>&y)1F*z)DZ5b zHqUDP?BgB$>OJRJWi@NjL*Z9qE3&B8DFqt5OG#xb5z27jjbG|P zub*POMEtz+>gC%jFP%0xaDC`SHc{WL3fRF#eT5?}SMSr2bu~hzj@6SP9dDUE zJfszM6f}-Z?q}R?R#Y!AoRL)V-7Qr=eSyRYyTor)l;vwhmkw?tB&g>``lg@Rw6^K^ z2hlh=0dR+|%MMo@*XS&0-!;_Xz&e4k`K99EoMZM{cz_ofAE_aa41PJEZx6y$PX8M@_b z#9y5|roZFJg-g3{m}g@CJWE@32NY?3~v2 zd)=w&RF!ndb3cpvFr$$jbKh2%7l$I{S~gV4WO00UXRl6>?!5h+7{rr*$gM6$n~D2Y zSP}2HtxHvD-*7ZtIDAJ^)mnDI?e-#bR!$mcpG*&S+He&qVR~mn*VHBUcM4lwPAg9d z9Q}S_IjHQb0s}G(QepAywj#`xbSXl;km@eZ}4)H@5P_bO-Ew z;_cgx+U};MSp}9}*5G;XE?TYlSd90St!iYfC~D-kr~g>}NMEk$;Rc}w>vsn?MeWph zcaMhR)8#a^%RP^84cMmKqtziUcRyM}@A0rK`NII^gQzKw>(iRsCxV(&o|X2g=L1e@1g~BR=r-&dr^e` zv3i#VXT}(EE{>SWiXFWnWL7@pqav6WYgI8xeM04!$HM(0%lh-IzI~?JdVTUK(P!e) zlGlq39vPoyI48T-pPCQtP8CU(&+L8qns@!)_R*al9tO1cqBGGzQs@aA5sd{bFI?m% zA8*@zzjaNE41cC||LsgB`FM%fy^;(sRy@DNRbsx6R)kOM@txCOm}*c)JYiXT{_Y6{ zrsX?B{21(@s!+PR_SyONbBrtvF?y7Gmdmpq(a0N1r$5d;SupEx)5_0 zu_bR11^c}+nc_(qqbY^zySo~0u-$5-xOYRUv@C9u8-*l&+5!=t=Rs9cu5n9FFXXR( zD452)ggQahh}U6D!uzAH=Z_2)IuAs)Euf1(zEsus{r(0?Db~n*s^(n<4?X?f)JMH0 zuofjM9(JM)w?&4Tf&KYmb;|iSOFD^R!+@17!bE)CNzVdiPt zc~*kf;a2sJy@iuBigjFlv)42YxfhLTc}DN^H{!p%K!mM9O*fQAO#WhRC)H+J6u9iT z?3*X5;2NAsH5R0owOb__*0%Z7gYmXWov$N8>yEGR*!}pN21D8_LV3&4mI@+)Yk`~Q zZ3$CDMp^E9M^o8@Zgt*=QJ)Y4@(+7@>1es?SULR=)%Doj_a>H)yVlXYDiqmkSN~?s z$1yc=9l={t45KaGJ4HPzE2VV zNxHA`X)5tqX%s;-7i9Yz-b?X^Z&&MW68BbQnee8~3CYeBTH@HwToCm=tCzU4R;#G^ zirLP|XM)YCf!PtAg}W)sU#f}dXfu8sv8CPMxFUXHciGht6Iphddbijufi_~-pEzHq z7rhrebg4;y@WR=Hs>tz03J|FR(m6_^Vz)#Z;840N(DRFN>H^1RyW-}fxBLCd)6^9URd-iO83vDfux zC|w&@h>2I;k$)-G`0(jPD;*V$z8%!=8YdK(?dj`2O)^M&d#I|Fyl^x8Eo>2#t;h5PTDec|#jy38D+-2Z*m=)G0klCCDQ zRQDu{G~Yk2XB$#V*%i^|`Ro*CH70*g=YbN-hI|5lnWf6nY^o@=K|b~Ohb*tuPPUnC z&eu4btnp=>nnyrggikTWlwH>G)xNKqEY*s^_a?>$bw4 z)pj#A`U~5$H|}BaxM^-647zw%C;{{kl~ZKf*m)dm5v4i1_dX^pm0t)w*Pymm)u zApFDMX@98*YWBTSV7U zD!!huyV^U0T$7k?>n+>3A#^}Zkug7;(OLSEj5ez>r2W56=);*X>MNdB|E@H>$qt+! z!T0%?(P~luO0T8-gpHS{Tow=Q(vVxR+%8B=^g&$eD^^{05sjhviN$ob>iY=XhMRY( z6BM}##~n};ZLWTQ;ojP;Fn{rlJaVF4TJ2w##ov9&xQY9sQvJcc(HfcLd^C z0=Ta|BiM%2*B#z_`0=U5)sqY%sr={s5*``$@UnRET^UQ%XY|+`a#$lsA-*PD(Ujn` zj_u{r*N@Ol>Lad~_Y>0^_AyUQZFWm#&%E-a*ugXWKyUeakL`|Kr*DqMYWbP#jeBKE zwCwdZD!VZGoPOx(sZb&BxFF)Dbk^kx!#(6Sq$E>SG_u z9Cm8bP?R?yx$VSnw&&S5y;ePX>l%%S{{UL@{?&Rlt^iE~j+}@9(GYHy)3xXC)2ui_ z;1uN^7~$Hp`uJh0L5aRBGo607O7Fup15NcZAF8j~BB8Br9(xF!#;Yy}re|L{zL@pW zA=(0FmVz6$VXpgk&Wx=1(sL!rGDpu?R>-9yBd*cbho0%^sQkJ-W)aaVW6x|u>w})Y zaB@mraEC9gv~l5c8lP?H6lHS$Sz-}lVKG*L>-|nVw*S6K__D&5>1WSgWL6KTH7 zbfSSqf@w4-s?MM4^mNE=vZGgb4hOZ=ehb+u_&L$#y|(bVa_RN@U0Qqnj|&o#U8a*3 zv}K0r>@DBeuUV1vV%IH`ji4bX1Z!#1UNusBW{2m5RE}PLu)~NTXux|vu4qy7z&@@I z7o?{wSuOa}m@`wEMffCb2GzGLF^t*Xlfn4 z0uuiR7>;y*P0FrWEcVUq-Ycpdlm6MOk7d@?uIXk=3*VM|$6-IEtG8cr#|CBbhYH4v zXP)RUyK2eio!B>H`}s3(vr|EGP~L-G++~}zOjkZI=3HA4JdJvo1dARzoLZ?id{i~_ zijkn#`(wj{N(VB^?&j^yok#Qp$4`mJ!PKwHqiBq%NueIYLSJ_G1#EkHY?{6kQ zheo%`gx|M4dNJ_L)b#fxow)usHI7B~N6-MfYO9k*^I}!; zsv0GxkG2UO56{I%U6ZI+N(qZp$)$}tdaEbj`o>LRnF{HsspETdcje@ShZ;scY`6M; za@}H%aof$|Y#Zop-{frJryg10ev;wNqg!zw-X$%)mGEu9aoAyltVPOv1R>62CYO37 z9JkDvb(aO*t-Kc7$T`F%eaS4Y(M2kz;w0a>-2Il?87|{jygN)HG;?;foO$Zp<MDx51)VHQ+_J2q??r>t5=}V@}lJW-aHIq;H#t_?8l^Lg@ zQIU=JiL@QXU&OSfJI1b^c&cOAPf$=V7HlxJ5Ae^nK@acp>C0zaQ^_T$tnmn=J-N|e zTT$Yie&W{eA02hhFnwCGuy@mF)1JO=rvgal3)N?Cvl>0X=drV4?CA2!6%@}pAf>hS z#KYC@8(m-L>G_UoDQ*@zAAYGM=ZL%r4e#0dByPqNYsyW;8M0I3%Xg?tFl6kdVGlIQ z(eaLDE$i?}N_;b^as2awFAG+UXE6)rI~xd0uUMuYWj`&nuBTD0g2s*4f-dUF&6%U? zJPb3AcnGQ177J{dNw8|V$#lbIs{s29i;}xYn*T?|>lfYcsGam$UFzx;7=FHQ$0nWz zpVhrZbYm$rAF908@35&dv8z9GO1A~lHjAV#Nn{^VqW>6}5yaaUwPULt|9u6YwSM0qPUhaE zwDQ8*19a?x+-s}K9r*7Tw|=P=Y2+RLpyWo_F5nfiaAvA=$5^P~yk#?zEvS-^yqry!5{A zCB;yum9@o5`O53J(^OsEo1fe2xS`==G0&$L@?C;)uU`mKXf0}7veJpNcD4BGEflVq zBW^^tN}@dPgxV3~cQLO^R2Xy(OBg%XR7Fcaeal|!wi6LEbCVxU$lL!{~*XmqmpHU&7wN$IbU;J07?Qow(o?Q?ge>G&do? zuQUB2Ps`!aapft(T95rY$<>6Y)jA%5gzTf-Y9c$PW8H()%k!E9Iye*FTJYH}%U{%d zr{=}6E{WjEO`AlSmUW$5l{zN;#38r8g?;Gz&dCvfT3%%iuc^V$qw>^OEh`46HB26T z)36uycipj?wSwUNgtjcFuu>>}_)15>1aV7Iy@jaQmV830Zu{Z ztNjxqiMJ52-X{3nPzC)PEuj%Lycq}YbsmvW6- zT-U?ke z=O&)GCn2}rFRgQL@`w7j_k`ClbsMwzTY|qZ)8L2UzPkHa`GL-LcFo@|RTjJrztkAA zy8E)>G|}|rH`Utm3m=RryNl|z=`AQ>ghIZJ$norekldLO_MyatBdd4wUMrd zL{-DBu5eM=wLkMpApHW z`i`Xd*@NrYG2BFJq+GJke50NT+DqB4{2!XFYycge8n62hU!TG}9U7OE+P@3UY@zFn ztJEbPN3j5KOHdB$2xoO{Dd=jBaqqUp{C3kSmbZ;#*%h>rni&1cmR*(qLlYVZSnj&< zg$VJjCeX+Cu+ZWkg)qp(p27$%qU$-={CCbkyICU!t4J$o}Fq&vP{%h)_-Vq2X zv)HM_*x51cY#eFDv9mGk>=-gTsctW_6JVvWtx1Ftp?T%|(CR9Ju?C(i7fni_u_?i? z?_0+mJ9}BtHZh0vuO;!%S^nhw&qme)TXK@&q|K@Zx`;9Y+s#(!Bhg zKs_;lGN@6YPtkfxL3d-EeTQ23+FwtiIh@AO$^`w?O!7M_d%~0(PzW>-C%S99UPF9+ z;{I-$kv7@nKAP8jfKbO-E-EezQlk%$9K0PXv4>227n%5Oq!m~B0gVQP9#VhnVL&T* zQHvMFwqodkwmJ%9o6xarZ=T=DQ)mbXrnj`v@XJ^w5;1C79_k+BF-OC4@r z+ei@6u(K14@BA*4`+kX?9#VM%L%pCG6cc=%T=3x;^C9`m z!j@p zi#MLZBL~`9-7#L8_-hy6?_q&tE3nHzsRI$;+O4YY0;~NwV%Ier)37l#n}A_~6lel6 zmWE+i=;(}%??ZN+Mzrr0RVdpDz~)13JlfyJ)`1qb4>U0l4>Ohwkj&_$Ej=giG@jl$ z$g3}SIq&Z~#YxBWg7~2u7=G;i2(yVmc&WO>uW0H%6TkBUM+RIHzm$TIVG(Sa;GUhmJg~2m#|}61 z#DPu@PliZaDm>EEY(hpBAs}LA$=|Ej)R^H7=N{u_vNb_+_)dl%dmnnB4L#6VO#JQ^ z*Il(-LesiHSuddfl3$gOw6(;z_WpHT{pc!|w@qNzyV_seL?3`5)J;Go+OF3SU-#>f zm-tQLG|^Csf$=DRdU_Fm*u0FpclU5O7Dfn3Qz%7aD2*X(G)*F;Ab*dl1cVUmIW)?J z&soF8&#MmxkWK7ic+-c_j3%@|$86&FN}v_1NhgKo2fo@iDmP}?f<+zUZ0&F7gTFhA zkYUZR`q#1K&o?1i1k*Nv8Ero^0(~R`q@W>~rm-o`$XElH-@SpW9$U@Ufo8H&qdA;n zNz25P5hTB(l~PRqo$K4S!ICy_y5Llgll32?TfT^u8o+E^5A#O+1?|^OAdrWNcqIPL z#stZ<$%lXUTqe^dE854aApUud3z%-A8x#ZRD*oY_5#no0LD;ZqZJuNz9^|KYZ{XLD zt>(e~9R!RlZIL7aLn^HvXZGw^GR5M~7EV28iTgFG0pbUKOLFKA%;>85Cw?UA2Kjou zoycEbKPcjF4yOr3lf3837jgU3eXQ#mJrao@@1T1devV`y6 zy^+7}=p|@a^fgUlY7$!t7Y1yB&;$dcG2U?gDRj3k{AHWciZj0RI|x0h0(%N>cdb3~ z1JXulCPKJBMN)hC8{!Mf*%3A^8lnll`KMF3;=y$+ZyyICb60yGQN$0>4(eWjHqV{Z znXliLf`D$*(K5l{c$6>Qcm`KKx*7>AYn{N%9n5fkA;a`|ZQDlIG%k8heI)ph<9{Y( zZzmmEhn>IJK`=kW4><-9uEWg6KAi_CoGQwA+}1tH@9$sBXKp&3#Vs*HhBf^z9a+Q= z&;&{YXnLj)e_JF;D4OEB$5!#>znsid1I=_d#%Ty-u%-y#J@EsK#u98?*~<$~T;-yE zZ6JY7Pu@pMCc@ITI0BnQ+8~h$kg@csXvNw=AZ50WjsX|nc|XUnoqk!|vJ~`mk8sBm z%lPo`&!V#-L1XTnIszqs{)Z4K1`u)FSXJYy+HYAB`3Kb95GO5lzI^j(eEZIgShiqA z`xrn$B1Uh-4=@@_^76C#hy=~*=HUaL+B?8oe`vD0>tdd}a+D3-!>nkVpsOKCb0kI9 z)`+J~G8vspIcUAwZ=}qkne}p6sawYGeDcy3^tH!$y1$+G{N@FW#sjSC7$a+IPMdJm z-~2!T(gZL-xYOb4$k(6W!}qq2Gcpn3U#@;3H*8zXvgQezL+R;<)l%|%DetuU)DK4fKhDj#brj`i zOLe|n3)elljGl%#YdXf*&@;lu-XV_Z9HXZxj;ULuGdhX1Nh)hp)(*-&h}@rg zu-jD&3j&X7zqAF5I!8G;+Q2_tejdAqn^@L1PS&oq+V7>j)9OV(XrLH?v-e=$h`(}S zI~Ru8)-=hVpIE_ru6;iJ6Jgf0t2@_|oh=O}pH1>^0*)iP2%}*_%Eu3Oa#~3H{4YIL!h?N}^^fkt5Ye*o0MA{&gF)HM% zpSeU5Ax!jOm$N!`1qbt#g1*)mgA)dsi>V_6&PG_E0x_{+VCcpcp_32vpy5 znGSt6`b`mk+Zfk8w2rr5{X)Wl4C^|^a@^U`YPedwSR%#RC7rBV)b9T>dBDhc9Me#W zTj8lQO-Le!MZ~bMQ7UXIt8xFnPVU~*McA22Phm%zj|J)BXp31PKyA@qq z_^7v3Cd=?doSweloyo!RC~G>$ux&9F3ho?rx#ypWBq#z+$r(1wGDpLa5yA(gSv9mn8LpM<19 zkOd8!pkX6}%AcLKG@c%A!boG0F2M<mLOJcno?LvtwYgWB)Bye2e4br1jq5HbydroqHy(#a$pFHN2yXhNb1S!6p%TN+Of zHL`V}nV;O*$V*Rq0askKZlRZA3PyA#dY~0)XAoK;qb_43k%IPUl3*ysUpFu1-~V(f z4ec&-@ z_BWz}|>=IF<&v@dW zs-kQFLX;<+h=J1d{?&7J+m@s=meWRRj`L4j%P~tkIXn`httsMiJzUIOfT8O=wQrD9*7oty*S&C| zr#>eV;S2fH4VySPxss=byEq&RVdyq3;S`;@3tmcJ)m_WOJ#|R@>d!#{O(G|On5#x= zz$qmVF)h$-zH-}%Y#V5%uW51~iN8z>LSRctJel@?(jL(e4)XHnZD43TjwlQW^7FX} zHTUs&3Qg1a#2e08=xJ9(SLZr*W?#=$_e9A^oxbKtdKwc1b-O6ZYpJ=qT9}%YbqkMe zPgN5mplmxy95Vp7{W_QaNN8<|@x!|}^7Dt*u(o5YgxX(A$v;P731g1@?(>J2K4(3l zph+^7nYz2s3(8d$LSWmHCwCpQ)s-KYxumx~_3> zXxz=@YmVbr_44;GJb~>8hR}6yuF^?MHeOo@`%m4BcHZ1RE$H8F?k4#|JbcMSAVAGC%UUl~IeEYo@FZ48BXsF~>}xoP072oylZ|2e$6z ztuH-|pMCr_3q3{8_{^JMMAotyolMOR;(Erb{RQPqRg-MXuYqP7plduid#~h0jhRuW zLUmgTx*C!kIMm9w@7zdNLjqH`3sir%@%=s)E|^L<7~tUGI8W^xaJe3}$Jr;Wz54P?d;NZ|W-~Z4n`S!mad6K^nC$8${Ki~cm4h~I_$yx=r zuUZj*E!BRvsA#NzAa5Mea<}5_^nFea>KU5E2&ehR-;U#v{T*~i6UDLEes}1xtf6a+ z#S%QZ>yXFAs4dPuVI?>J=RdP%aR-k)eSq=FlzMa(T-^e7)VY6nf+u$kaN4>h{QgV- z$UndI^o5?1FZibmPU4cY*0Xi*pt6(Hv*e$%OW()6DSxG#p#hrUP_YJ3yFGs%maWm# zKEXq~ySe(Yl`L(U@J{@GKUgultkBfOp!JGV*DdC6-+m`w|Ml&B@A~`LwtojrvUgyd#huMqwv&La zBQ?s;sheItm3JQ-LNUgaEg2BdIUmF?5i|xfBvS_ee(OoZvj&}0hQInFet>Y$%p4iPJ+YfSRc!GE`jcrQ;rcPgbGb@j4c-fij zdD)rkkrMic#~GeTVA+yL(4?=UsV*)!nJ=8RaTyN*v*8zw@$>7uM5Y zDz)_1+7f>bQV?mH~lZgUxhClkTtT_Oq2gg+5{pz|;k( zivq52HF}5peo#p@x*HN~?Qi90kFB61l5#icnn`}g6G2KzPkR$Tx$yz^4vaY;`%x@7 zp4fGm+aKFSXLJ5C>?4)<-Bg=Z;4xq*ci;m64Q=Xgfa@JM=7RY1e~WO6-)~*YzR^Zn zLTM-JhKB{J4e{s8wlqZ8abSp_|M5W=^`1Q#nMjaKXRB|>M{LZz5uf2)i|LqAzClW5|Kl8Eo@E8|=`WM`{b>Bh{WeR_NY!~N#_{SU= znqYBf6PA_tI5|bV5Wm}MB@5kwB&SX1H2|q>077FbQ)u;roKeRX1e+(h`pM;N?r)<# zl5{BjYkg$XeOU=~wlwhM?n8X)hc|gxn`b75#^b#1i&t{T1KarbU))Nn4l*cx=lc7( z_|umYG!0hvwvx#n$;9u<*I(|3CsmefZOZVcGyn~B4WuLq+)}n751mU1&CwKthugSm z^D^2UOMka}{^|mK+$^RoZC3QP@yowF!flW4aM9K?6Z;0nIQK(8WXs+G&N^icw?49i zFJE!%f{y7!-}@u)zwAa9cQ(=8){x8Tcq9_PTeW{K;%Cp422dCWfXFcbRq$6O8}it> z&>#{{@vBGH@aTbdI->~((%)ybzi4RHzXTEp2Mj`{&ZmEP6BCL0Nf$QXcxvAe7k=y~ z>>nIw?cxs7S&OxcJNUs35AxSXcUIqlOJuSZulv$f{LgRiX2Y^B8pFY7yV{?}p8-qR z0HzN{Y3k}5(DnQ!3f$@!@dHEy8Af7ZuHCwbu$e^@mB`;`wckOMpR0CrUt6|hX?H7k zKe3ySTz0+lW}iWLaN7aS{m>5>7@K76q7Jf_jg*qcND$kWeE2&z&2fK$|L7lyaprr! z&rSC~#VKq0Fm#pAao&mFx3+ze{CWIN70dhmbH{=6ziLxzf!GahQ-zoA+(yvYkmTOI z-8|XfMn|NQ-@gWGzw-sETz1CSS!OinBo=2YU=iCqfn7xO`IA&QVwvZ( zmwfID21X}Y-Pe{=`JuMb+zl3#_yO($MwI#wqM*(+11QcWbz@aQH_D|*dt;nixA$@V z=B4yB#^*5piFrHL>vcZm%38LhDH3E!R|{|a;xC`^OyKQbzm|9X&+k~hsGY8sD4AI* zem?L^9X(#s-OOiy@+Y3$?cx3z2e|w%k8$BAevT#tYZkW`Fr#`2^jUD?hrIfq*NB8* z))v6fb4)-<{d+vmxN!W2#hCY~}0>T}#>=eMhGo`^pW%a$}pL-e*c@y>5t!%uE} zz-7Pnk4-!KdH#F9%Wv;^f)iHt5(=1D_Dp+DalD8vC7sPtV#y5u@YSmskEdMqSqWdd z;&$Htjo-1dx0SAzhMb#k#yBdX8a2046SX9MH_eJ0mG3{d{}*D$7Qj{vK-VGnOhsRyjtM2eR zkh;T9{`e3t`RI??vUiYGi`vjNQ6i~E>BY)gHYxBTaCeH+vN`_}b*;qt$- zs;`}7#yZT2i2B4G%piRdD%VXXiB!hLIO+?#4~_DYkNt#q{`a*s zN5iaH)Q)XSW~Gm-;5EuxHtUvj@P~W1^3Pwprm8W;l4<_#Q#M z8KCz29`!1I222}iL|)BT(A0)qkUth&@NgfUqt!XTiUcgiCc^w-^D?4lnYi$p9_w|z zN)EfL+;%?g*2!xYapOH(Iptrz$**sH%;lIC79$f0KKqkD@xu3ipNF>X=lGSqG)98X zE=Vo2MADWVzoLgLZ+)D%e(hRM2k4ji%+@d~o=OeLQ}!RM_v4zvr(6Db*?- zv#g6lBQf6m+@qP(V zXL~kJe=iVPv6P=)eF>(a7(_wn#AQq|0B6La2??6bZ9DpiXAHU;oJ9UrSfHAqmi}Q? zKAW=(bhJdd`TlME{>~?P<=MyazE_>aNvr#6I5&6LH!#NKe}04?-S{B8`bSvN+s5%L zd$DZW7veAU3}~9h`lVg`_HR!x5l`{!&-{JG6lFKu_Y|-D(ywW02(fN)M@hG%bCe&b zjlhyR8EKG~2A0&Z3oaEEsQ25@vIImHLu4_8jlgZNQN;zTviwxppQGIRisOM{UZbnofB5|a^V@r@b@n|o}RWwmwi-^14HBd{;tj3{J>Le+R@LzSe(B0 zCYl>U1%7mgYvO?TXTs1mHt!i=d3P(1c}hBKh+K z8?!@fd?QD%bv^_@^O$aiU#o$<+q47A&x?4Esq*ZKO(ZkBVc1~Hli1wz4v+f)sm9f~o z`!HMf9OlsIB%5~jbLZo`**`c&QzS@7Qv<<(Q6XJ+nf0h*?F?OG$H5U=8$x{MP3LgI zX{%{#3$lJ6*N?1ZRr|OK{jDO%$C4T;+vMWTdpWIX8+VKz%aw;;fJCq?bQoJ|`J|@a z7t z<$koK#I_}|M2fM=6l0S~4h)X7Z(xj_{Uhu=ILw|yqbfDHlte=&oh?y90TZO7JaDDg z!w2bQ=o-W03HnE3tX|yC%HCEc;%PSRI7Bj&Wkqi*x+paExqCL6u*ujad(+*3WKC!v z8zQ@Samxdo-*g`>kr)(a36m(bt@&^R_sx;BN_J;K8wVd~yFja(C=lmIh|t zB;`i(JD+0-;sH^QbI>Vik+hk zy!n^sFq#O^7|c*Dx7(5E;XRA5=W{1sp&m>Ywh#C6o~PcEA$%KDYfeY_i~ilG5Pz=n@+dj~%rxQL~}JQJu9@k1#AyBjzj zn7-3q+K4~|VFZg9K(Pr{KnbI)4g4GM+quRhguo1B_~X_k>=@4bcJ4xde0ngm2aXSFAOP`N#)i9eqP zOw*b978H}atr$Q)AgG}2+biw$LWafoWQbdyT1-H*3Zo6Hns9qyf?E!s$a|JvM_V`s z2_OchY4PTDf8p=C?&DKWzlkdkzkr~YVM%B(=Y|t=x9vCad*lP{KFb3D%rI5v@&g*i^tplDX9)POxyI5QO7rwcBijd?Xp5w)-*~`Cd`hUuykJ{f-Bb2o9t>ct`i|xaFh|u(4x@lE`t?3$5oqCJ;cqOQ9K`V8N&GJHy?0HL3gn zQ*_=veu!Y2hxT`+HnKjnn@=9|b49cX6anWACKlM1U^vypP^Ouo zY!jna1EbkSCaf?iJAfsXokSNlAuUb2F~;KHVK#(z(-fUlA~Ok8NHS!hV@nMoc1oX-x*gINRDgR z&G!zzgwDVipFZ|VHNY%+{|-z7CcJjd?L5Ej3BI=bmHg`P^GT--R)*9~KC)q&*q z)Zjc4zu&IX8k7%cS<;x?e((g^jBy4tEevIwIGAo{Alt$~x`lyk3&Yta#;pjGR+yA+ zVxi@{NxA-}x|CClpvN5H%*H2pRoksRzx~lEgLJv!C1rq=G|`36*OAX%^nNIDl2-_X z&`T0!u@?Y9hj;>p$BR4xc|0Guedb7d8sq$RM;~wb%?oJ^rU_I^{NZ%c1%W;qlB8|2 zHL;lgUh_TPvF1j_;b&_462M4(KD_;{{AJ_>7KMiB4vduW7SsXp*OlaVJI{re z{Q0uFuu0k`1DRF;vQj52b!-HhunCGRA(1Air7?wtE-W-*=QcXBWS0_wEj8kHh=ZAS z#;qv-w&VwVYWYvgdk_Nf@aS4zz3q!M>Tyg_>7InD+YKqzpv=DqT8`m+4d2j_LqVtZ1kxZeg9yi5!I3e zv@8Remh!`tuqCmatkmZigKuho9^XSb%4dv4A~b`->%WTDs$7QwqwGHZ9$+fpb8|S& z=7APA9c-gDoT{+o?$rKLu%t$dF-dn|l(%hp4_7{YHiRk71O!S=n}DWJoR4j|ihED~ z0I%=5ja|uZwkLXXc25VHik&|Q7pPOUzhd=T21!-nrSOWf`?A?TNCX;o`FAGw&TWdX zB%&pK8e7FV?xftko{D}p#d|+J)c-K_9K$g3A_pooQfv7oGbcGw@pBt9c zXf`Zn~sf@EL z`Vi$;>I>JBe;y^SZ^VyF8lCR|EQt`3!E7_zlZ)AsSW17Uz1Su&0}_EDEP`5@BsT`^ zOLnm}v6L1gR~9!JT`$ z0njvAX8&Kk@EDa6t-lyJ9+zRrq>wZ5??B$wC0va6CxsM;UeuG!G-^us; zU&3EUk0-39=nD*EXxZY3Lf_+NYAN}v9HF1YKhFg16dIB&I{le8#;pi1XnKs(8=j;| zk8}6LMjo16OPeuXvaTgHf+9_WmMAT3ba*hfj=kw_Rs;{=8P19SY09SWlL*}ep}S`Q z0Yl{n$YhHS22HI4@VRI(bKTyF2DTh(r74v5f%x6Qk~+=CBrC%fAAI_s8Ok*A`D1@E z?W-*}oSc0C9bUTZK3>{)A2%F0jsM>N3LczTLqN;2G&F#eat_y_$7ww)B!4Z{elO(} zG;Ffy>`wI{h2W&4pnBA#vbYXK| z%Y(eH=hr;1b(13e3`$@~pb=I#?&G@Q=ap=0%xd7YhAp&(Ci1B^iic*w*5pzmdeTKS z?9AyouJ;6p@0D*WzyB`}V=e+QO=ydxhz6`#S$%a)+Jw^|xp!~Z{qc-Jr{>|frf1LCfg%21?{9fo%UwLT?Qvxcx$O%q-~x?GN6)tNZtj!Su^Z%*4TD-A=fC`Mh=Z#D*RG zY4jw{y8o-(aN_6aZ5~z+*@;KULLD?REMB@?Z4GYjKbgx8zKr`O))BXYEDs$bpk>Qm zaV8vp>3)vh+N#jNf=T|`G^`0p*4EjV?j$R9)`j=*hOV1=XZN-AG!LsnDT)an)cX;H zn+~19jl<8OFEBW(?Tj>NHDa9AxT&=Iufq)^&t*@ln`6T}b6J6E7Wi~0GY|a~%|{{( zGw1&=ADCC30SJi}&hnL8&*G1p`&imKIje{*g*1eGe|t3b@@XbBf0BRZ*Ajsx1skKg z*puwy)cgO3pRE5nFJAVr+Vjs5x>?kgh4QHCaQ>o)IKTTLwv8_4zYbi=ZwH=7%nGw8 zI7o*%p3500%8$-HS9keS6>a-%@LM3spSRc#W?Se_w-MD7oYVXeZ|l0Ab6OrmgmOoy z6J;8ZKo};|VLrR-t(aN{L(ER=HJWW?V`K-XHf)}KoH*zHyDN4aO>@r8Mv1SpQfFys5KTzl zy!k_XXY)mh)#VR{IPK16D%^N&$3DKh@tgeR_>b{#%YRO%ImV;0l^jU7laV@lsi2~Q zd)TX*qc7#%5Wic@Kk?^@K5mEDnd)V8Vi_w#2l(RBA8_L_ALhyppX1!V2UISJBueU+ zLN0XN%4ob}%ZJ#N?ximiBJYX83~ydM#evo(MKY?)lf6R{Pvo8!*s>5ce*3*0t$ zF`*2A6%OUhos&7Man6SQTz1zQbRo;e_)GW?;B7!l<*}Fihm%P={u%^XDOemFWHcM) zo!j2SmiQ9>d;NDIN@csiOym^*c4mNXtsf+!NWA@ zN!JELN9*Bdh;PNJwG8pCZcRkag?BLBPQnhcEZEPv%@1*D+ihIhc^i7zR?jOJ_c7<# zB+3XV;q6;L!sSEfb9%#*Ww&=(bdHa1FD*6&{QU4s*qiQRePp*ITao*<2Gp%xpQfx2 zf&%~l>;xdQdY4bUxcslW4Z#er{_eTl`E)mnn&+gPR|CIxHrLt`fAPO05{=FAB^(#o z$uExmPgZpvR0Qp0OHc~=7smur@Z|V1es<_wem8U`dy-v5j1+yr5yD!k!gc5l*W(#O z{NBbbkff!_p`72oNuT8OhRwXX{Z?MqdN<9Xn0gi&rjLnNLQd_svx3(=@df@oehO_wgdV*7aZ1OXJw?F#@Jl>H32VY8$Y{<;>hIkPG6^BX1mB9X`NNris@) z`AObC{#(9&%=grmAVI|h4`q?J699`E2YG$#t-Rj4l|5r!Tz>c*?ik<5u2c_O5{qfj zl60731T>Xv-o2mrNF;veu%t%94skf!ij;!o!G2aZY~y*2o4BOycGfiRn-2G$>B4h@ zT*4c|uz#$Ri#LCTClkv#A-cWDm^*VlY@wkcIk)-#;taw70oXg<#ZL~sl)k{AGvfE| z75W@7Jog-x@voBmZ>nYa#QAfV2&Wkvi|~@~oWoEoL~}S@sm)KLl89EZ=Py&<1M$y< zauXRmo$O^zWIsPx``?_cWxAH z+iu=}I&a03mqC<_~klzy%x|*@0Cl zJGJ+G2tNn@fl8bD`~@JPhKdZ}p08Z$fB^t>PVj-BJf9!jv5xgUqm}lxLEugVr<9q9 zn@Kxp!aZXVLLCCxo9rYlP2Sgc4WC$bC0a--+kjVXpcFKeo|W5f?2dP{HL;k#jUC7B zW5=;Iv6x9KOh`-9sK;qCCJAWSveL-Y`uQ2?Qw8y7q`|lqC1!<5+5t>0%hJFhPHEW2 z^P3*y*vL*+1`p60o|sPCZQ-5h3lRn~@VT9D;p+!qOQ$(Pw^<=Uj8NgjTa(LpQ|C>5 zbL}^jkjSSPi@8aIj((+d>2*h(H8vYtEwgeC1Lq z-^`d}A}?8gfXnY)g=LFM^GE^jK&2TlhZxUB$x4lObDVXdJ*)^Fq}v?fgy?q8YJ80L z$oTYe?)-k?EwED-u7D(@Z9Lb;n<(W9oC-L_8Vd zV>{o8jUb{W=a&A}odNkGPKZCR{u_ZggMW&8aijqRvScldmt1xpI|dqQkESZufscUr z504YB__gOP#VqYuqUE%Kk!%B>TzVy+T=mQ8q>`40uACyT835QI(}GR072F?N$0L&~ zc_O}o{&X90JH(_FA|o}zTAD^ZL0C&+YF6&vx)N*Rx7uH#ibRl=Iw{*EZik3jAuM!4 zB1=S1(4Z&iGl$p^*~JNw?VJ>Siesa@&`ewHrE|eEzFy8TJvbHjp}{r#UckTX{0KUd z6`=zq_WR}6ZXnabits^h-tayQtZD5q44>NicD{D-^_(2tI`_pi)dhq76nG0x^dQ?p zm?1>Cp`!E$xaZ4GGys6Kfzc7;_`VVD+u22DgCqCW|Darhr@EN=9P8ldhq=p^sFpVn zE)EXR5g6w`_Pv@v44=klmtM{Viyu^l+!~vlVutlv=#t~xcW`{?4zM7Z46rZN$#Axj zed$iN#22$YxrklK9{SU545XS#$pAJQIuc!2=-3#Vjj3fZP`B5r+;tAFDzK=`cs>G)7qz z7(@%^2;RnD3112lWhe~7p|Mszw(Fhze&j4V%rV-G@!|~86n)NMj} z?_LCcy!&PR-=Ry{5Z+lq^3Q0rB8tjB27D4Xn;^Z?4Ozu-#sDNBY|cOCAV0fz4VDy6 zrj!ES3~XYy?R2h5*9H~3uu}PkxSfjb6uxm;8p_mSOe6*79PBT-xfX z6J`QJfi$Z_`$53z+LkF5Ih78uC)LUBR5yE4T^vrgGGRrS%xMafc1Yb^YloS%LL}?} zDcdAt>)06BvRH4>a)~i?Y)p~G6c!;ZP1Hyd)l)PXaT>HZ5j{mzOVXexXfwv?H3wN9 zI>gezA=(4uitx08`PfXSaIa`P_6cFNM!(&2HlNu0b`GRFSQFZdsb%LN{?Z!GxD{n( zXg_c2ylMKrz%V>Ew3^TFc`Gf(1VJrRzTN7G-vT}Y>~~hz+2NmAJv!O~00dOj%te=- z$KwZD>27o^7T*B;!oh?qe(jgqUkRG9$x5B=@kKQ12|ls(O5U~fI;B$9dRyRRN;-U!+3mLjaB32P}D^#l!i97DH? zFTyNTBl7+FWvugp0t^5C(N5mA6M9Fv^u*oV^>i0K zjR~jQwkuE;%(uE&4JQlath@(8wWad=Ziwz-JR9L7JO7!>55I^HE&dIcEWS%If+P#W z2=a!qxt2$OX4o`|I87o>NxfgpXme&CGe6cGDThp!3#;*CMQOp z0&s9?Y-!jC3@lD*+B$VJ(4zyZdGk}BB_j=%2K(nA{;FNxHvyk@*MtBw=&A}h-2#9L z3d-ml(=$rIRQUlMX4RFb8->mWR?ji%Ili7h;xBB$k{S(qf{l@#>`ry_#%&+v(xJO} zZ{IbX+P-aJ8Np1*GJii)p#uTPCUvgc{XG8Tz#DjIavf{Kd+7_rEARCyydwfIG>g$> z15Cj6!_VXWyWY!~)xet2-V(6`%-LSWaZF=7@P6E!Sdn%v_(yl8{sRd4q{A%$fMJ1Q zbIEtk$B|PxyX7%HwCE~M@7g*Q`RDnN(NUB}fn}c*T(kFVzIFIg9+_NC zgP!Ds$kS?Pbkmkh~EvJ#Z|*EB1Gz8UGqxNq>NQ zzI=&G4FDi%673r2gr$Q#w5x-Th9s8lit4@$oCTayel6Uh`bONgU?b3l#oF+GQnty} zgU{#ZhhEG%{g3dT-fKCp^G|d0WqobT*Hw0%?wF1?3=6(mrJxMaMsiVnPLpjEHjazO>9C+bl7B1ka$uY5HOpW88EMAFmE2Rf=gXHM zehWi+0>2fAA+5brkwL6W+D}0Ja9E#RbRi;}`d=o<1bu4x53C zQRpttd8tgQEU0L?F$t| zvk=G~(7}RaBEZ8VYq)yoh1@W5Cc9ESH0hJ{28LLq4@{-js*3m*T=JKM4SW=@#GgO- zV+LJI{-UXP(f|NL8Innpv%h%(2gjoHG{qfU3tkeh0CA0np%?wnW9<@O`fzl4#!vYK zmc!X*4rN;DG)7q+-p})!H}T50J6PYmM-c?n?r_XPLPrt32G|f!1o_M8DO^ALTpo$7 zVRyQllx@;y4$+{;u|Tq(RG?*bO%OB+XlCf9mn;<&%qQ~R)!98dgB(J-?WL7 z8=hiuV33HJR911p^nszmFx`bf;h6xPDPkuB$#jtZOdFfy%eX7Hk^3gr^JIKEV^#wJ zk)hof0jv*G@MB$g&(wNM{oikoP<;~r4}p(S4e{q)e@4)=^v}aP0|1Bz>F6Bi;$!#m zwZCknJ(?ox&LvoguL8}$$4mcQBgqdgW4FB%|4i6YT{Ybo7-A8FNCYt}!mkHj$S)6{ zLswvoj=(5=<`5?}Z0CgN(`=0FVrlS@dUAQ<%iCb`j3Iw02)r?f!tJ(T`XEq=lYZH( z&aTN`HYb*{X>t{t;ww3j?oivEbSoKj+HyYozQABH!8?069wy+lS}misO1AwA;63

0fGr?t@}ct|<1br#>5qkJa~~L#hXg)>dd)ssw$y_9aQ!3x*^^h))sRc1 z0g%RIFw@MgWDhrwo=QMu=?x6AGXaToM~fUx{Je^7P7WZR8JDslLSSY zWubmFWI?mFJpEbslK)CnrmX6+OV~CTW>ul>T!Xl_;h-yie2aAb4kBSP&f=K>aHdwO!uTUAYC*8GGriVZnb?Z;{ ze&p&H04Q6)M3^_7ypx~axsH)|faXx9nysmg+9L&lf3017e|<>)l4VPLC3AYdI;)?a zRUs=iGE!%Ms)HTLUNX`kV;k7$icz~5hbH7yVvvBy5Y#d>=m}bk*c9_9HBi^j+&AKP z^NzR;@vVA7R|5Znx`@6y*cRvkgdV7R@1KYBd;oJ{Ji^ko{ru~>kMpT(PopI~>eVGU zHC5ofASQrMF6^G)Z70=Be)m603}ImitAIJwh$#G;r*G}nV4lKd`SN9dfl~W@k^BH6 z5W>lwe@@{c0H+ir#Dcu~l$|VUon$oOkAVXCG=fk2)fnIxSNExLr-m?(5048Gu(io`NE+j>WJjO zdKpsbFMSO3sfrG2Mf`5ZR!hRDT@y8FYpT7f-;u8a?_xTQX!Ve?AmfjJzF(g-fZUiS zgM8@4n>cy#5Qk$S- z*EmD*px@8w&!}7iTOB=;sV{3O`Q4zF#P24O?%5#uT@>`>>o3AqRQBs1RMSXF*f!`n zzrPP|znSn)1IS}6!lKpvyyrzv(mxtTI7=Mr23vqLnQ@A0Vbp#%a6|lVQOCsZ=Nugm zr`BqJQTf|}R{(#k&AcUAFpTig@?Qx589**L=v620WJ&uZBmQdv03)a*3jYPqM77`L z3wgv@``xx(qX|~89sUw{6-p@ikG$pI3?hB<`_DuT7yu9p(b+f3Yfjn0{?Q1UzqWup zlE8-qypx%!HT+cjt14Tfysy@Nw~~LJiOz50_ubd;d5#t;wcS4f1Kt;CZb(pverl+N z`Og6IBcBZNq4OT+q(#Gidjw|UJHY9veCjoJ_0^f$Uz4&v4Rqd#zm{r$QTgq_-=jj- zYnScOw$O|K!VDpOi1{yv+AshCOoWK`j`E6AcQQB@a(an~S3Cqf2f;OUw`VQ$&x++M zm96JJzn{ckb-YEXWsU+_J@ z0QDZd61UfNxrJ?kr4oJU(Pp$rWA2CAW_&flDauG>T!O!QD= z?kJ;BR?XTmf=7Ypp+YiC!0C(NLxi87QGQ2>-&@<>iT@YCg~0EsU!c;EwgtA0Fhgk3 zX7oriTK=qmZ8c`VZw4R*m|19vaougF@aA8gPr$Hf4=1p)HbT?TLlN{)BU% z=?f`R+uW%AZcs03{{o=yiQn~vwgPVi-V7Y5c6my|wm{lwW)LmXgdS-^%enh%$zUlNC8e5NSjNBem2B5+L3KoD4iT>({CSecV*7C*rRX zbx-`R7~F#({toyDV1M`E(F5UWji7dn;9=mosN=<>rHfRtfA*F5-4>tcJ%TU9@3vY^<~Ry` z3B-B8_4qCIbE>{Df@t9;v~VNn0kEZSS$(QOb%%kZ28IoNgZ$>UQ+V|+E@DYbjLvA1 ztnGrgNV`}gm|_IfVr!5_9WOox!ByS^eQF$8=V!{Ys>|1S9DWnObEDsHfwMt;in0R1 z3uLjXA8u9`c$k6d@9X5|7w;NC-r(0Y%oTq)i+5jBp!R!B3R<)^h~|ui5zz7)fv-N% zL%?fLF2g&jR{MRm_SZ6u*@r#9DEEWghMZROo%rtrUW$qv@#Zcr1u3TmRv?TPX+{e- zfnnwdzy5A_@x}nA)cy&sbF20{YCp#aG#xDvMh_}RAap}90e=_rArR-FUWO-}RjH-q zuT|lCaw9Al@jrn&J90j71Ad8NX)6NPG=v#es(z?J0%Hx@|z`X&544BSZUysNKofZyD5 zI{)wLb6D0oPIIUVwclCCQd&uQu9juQ;>jds|}nGxm3v@Yzt{+kang(Jrf{2k8uL{0f?WW5|DfZ zIL%k-UsG#;tx&hbe?RbJR1nX2RZ}b^dQAr{fM({Ty$~gAQT6g{+`)K!`yzxCbEfXn zgrp;yTxd_xh|*ue>htNj_-XC;yKFJ>{{grRm6pr9D3*5aJwXW#BcxP(%>X^umu=UJ z2hSH6pS|TYnu2NcIkNWX!e%%T=Dz*ibVd{Nu;=#(S#V#rrXw^RVFZy@7O+$pvXw2k zSiv;21I|O;0`oGQcvkA&;OBRUuYa%++zjFusHnX$*DVxjjJh%$Yx=aL z*K*^|Z8K{>rGI@dsAUr6Y6e zkdK<4`^6XnzK^m%FGXnv??6Qx;_h(I0&ElfB>w8>`5@{tnBSxF@Hud*=Lmf!!Rsa> zC+&r%PpkGYZ|Cmo6-IL?UB;%7kN02bA=VO7as1p=)m9-l`}}snwv_8J|DqIX6Xk6P zHn0ojgZ?3~9K`tuUIDxab@jQAs59dCRz8Ia(Y*ncdv7yNu7Z;VMmbI7B)X;uU7Jbp z;u*c4_X5Mv?a~a;&nvW#1V|`)-vml>=mGVbN;{XV(aPm*v!_maO;?~mOAv)E??muj zR6t52D&p{!C=Fpl@j#An$?v$D0C*C(8@L9zhjPI>d8uA#u*(KR}^sU+Bdtd@n^#vTHfXE|kGmh`e;qcba1mQs%a9)i2L8 z9mZ_>Ke}qAQLw+vL(>#P$U#h%o7NQa>Xn>g3UazV_3|G;Z~(+@pnU>pLotLkz-g$1 zD*YC>CH`%|-%x7(7LeP4!z$=(2BA;!SS@Fj*K&%KnBKQf8S7@uyO3!dg=-iK zJ%A$`rCz?Aw90D=Q(xyb24q1LnJi!ocD}7)B=-XMg8W6U`6z-uU=3&|0H=dog%C@D zW=~`HNAiy$*@KX~5Ih3%VI*6DeaKuS-V|{cZjrPpf)@EmO-)nx-{n6uhmx1-#j1gC zkMh}yqYR)HC?}OPjj3y%bO50k!;F_(=CuUd1|gBso)`LZAnc973t-2T^IV`VsU4gTOe5 z6hc_j#H~;H(S?>HVolG@GhZg>QPB#vR(XiL3ZL7v9~JC1hmg-=7syc@#j_p%ALew- Uc4C}dc%Sj@}G)Z7;AMr8)Jf;foKd~WNYp@LY5(CF|e1C^Z~fUO~NJ}zKQ9~CWgA6s() z3mP#|bYU++m;rmRn<}tC+uQj zDX1YO^N;3WB@r5HH#a9i4h~OGPj*jkc1IU04o(390S+J+2NxF`>$N9H|8DfIZW`dfyz_6E zf<6AXhTI^Q|H969$-jgE_JaHiweOPO)qa~(zq?u(22JpR3)s}n(M8MA(N6UD>8kdJ zFQ^_o_&z=PsF-vh4i=7{uFS$5w^ja{IDc6KOPRWXMY(`nKsF#Z8xW+$DImznBM1Vr ze4pXKAB_C|}sCvT<^Az*= z$7g@AV_`06>F8o_>Lv=YH?;zDI5}7ebNp5L!;^nbPr(O{c8)HvZh=L)g*pDN`fs(Q z9L?RouMY_abFeGS8LmG#3FfNbB7mf+)j!w%A+Upp{vLlU9L*sXf`2t?&IK~(H|4Tm z;{k&}Fp6MPHd9M8OEv*MAdp8u0L*W0#w*P6Jqo}~{ME1Tc7Ln==N5k)&d>V$eHth$ z3(7mVx|za;BQGTit6+z~dIsbY;I}X{<7cz91e&p#@_{VaOhJ5{Y#@H184r&cKZw)9 z^tZY3&+32m>>sB8XdPzy?*}db;>d%l5 zd-Ttj@NaQW(A4~U>=!lvzUsji!W{op`&YMat3m#&JO4cdzuW&o{a?4?X$^MxS=9L5 z)NfDyYa_0XmTsP=E?@~O*n0YR0^09Z|5@#}`M+N!Fh;+vOgqSb;s{3v53tLB#}zP# zo5J!8Ff2+~x;WZX{TZC7+#IP)ot*3-=BD3$%;Di+@sC~m&zSIszkjgt|KnI)O+Egz zDQ98E!*3w~1hWa4^P01n@`8BT1k5;LtBxON4z%Rs2J`WO{utu_+bPEd6a@1AvB~`J zO}X!r>-W~ptxX-Qz!st$e~j#pivOED2ebt8^8k5F+4y*Qx!L%6L1t`bT;^a{%F7Mp zaz^cmCzMKc>wef&M>^FaL*-@;&PO8G`iY3 z{yP!ohhCchfr;w3nEHRunE&IL%ExDJ3bZhVrD2>P*m~p!@vxZzO@VA&7GQo;eptH3 z$puT6eyz+uGos(${O3FWf9$z`FQ5L;JoisWuHQ}lZzN#?{S#>wn8{MLC5z{!85t z)_#-eem@i0x&LzUv04m4p`l3-C@9v*HUVUF9?w>8utUSK<2DG2QD!1ep7j*AC&==@FTw&ZU$_5P*i z50Zaq{=RU2xIX;NHNV%wE+=94q8xu-jQ-%YTT%0WviR4K{wJ;8vh}NxTR?tZ{Dtf1 zd~Qj9;kpIn=fz*Re$MBX^cSvMKz?5Qh3n^hZb^UPx&`Ft#b3C7&gYi&7p_}CeqQ{A z>*suKNq^zG1?1<&U$}nG=a%#ru3JEUUi^jY=X`ESf8n|X*suKNq^zG1?1<&U$}nG=a%#ru3JEUUi^jY=X`ESf8n|XCr|Ldbh zzz(p_7x9FBkO&`N6bSYqBvj^d8p;5G4?O@77yiZ?wmdV# zQ_*Jmc82i1t%r`GIATJ6e*T9$@Z6zy)3Zxm+aGH_%sGjBvA>fEUgyhn4>JtJw1 z?``bA$&8c=4;Bi*?>bWhq`CwwA==PL;ZEx^e3J}E&X;Chw3ikd$7+CcJ}E^;r9lOd znjqYzLZS=AJt@WJr$R(2Sp$R{A%$f2;RH|AqTy-8OY)zTU@ZH(@2?<(FpG6f9!bT% zXZUhghjT1%>#PdLJ6A)?uBj=H^;|?K9=DVdKi9K7UM>L#jw}dAPQih7IjX}-ZpRC~ra>P!`0;?5<8WlGf?dSpHoC9P^>GrliF3LCqUy zPky9R;x)ZBU+9%MU;J@toGKvdp?=UtRm9C$F7@+b7S*%h4%Dv9Gu4QCVQ;K(*X0gF zgi8Xe64Pq296xwnRu`@V__@``L8T__bRTuNl#TMUfS)}r{SJsutXK|c=k9wEFh1;p z&Ab;X?8ru#uW&y;!nu2vc}MwPX@! ze=P(AhQkNaDY!dTNr)wEl@JMwV!gulLOEbu<6XOGmtMmc2TL6aB2vN|q4p@0-!1oV zsUEl(N?}FhKf|j=Hd;^YM9K6>JsHV0`vq__kmhbO@%pfxQ% z(F5)^yMUc@M78J!0A=T(@y!;}<>XN2)mg4E$4FjWmUsj-&-2v>HfRo%*hw4L?+}fO z!#m4X!zf5oHBaoccOAVJ(IJ>B00`652o$4?-a2xUy+?+0O@4}bfPE_AmW}8q6zr1QpHD2-+ED$sT2b3i5rO5eP+nq}$}wt97qiIv2MqFy zCx1*89*r5enNNF9hkHeqVz==gUwlUXY5BJR)QX|EpvwH&ktG^jdiV~eFYQA(ni<<+ z?k}B#+MLki{owigHfEqXR4a&x!f-a!n=@%NL8Ts3Rijz7eQupyPWj`*TF6=z&3gJ-@s> zPdq}T>-+Lw2X}>#WG)qxHgr_xcCPqYkT{Of);^{+3vd`*&b&&}BzOUF$8em@xr`DT3xbP^Mo2-Al96I0P~l$+0%3KVXVZ+YLQ$@bE#1?x6gdk-|!z| zSi7Hn9V-gQisy}>BD>(FlEj@C-jOfv$v;K`pr5*=>9_ULnq`TM!TvDCUMZzmjU#y= zvQ{Jtr`7QaqcpyhJ%F-3*%HFc`ra??+~sxH!KR)<PycYd`R?4u|Q*{)>2x^sBu;{K4==>=L5v^20n6_ApK4ZoUkCQPxJr(+1IPDcY!XTNSqiKwe*5<(b~VV**2 z7MH^;j*W){v4sI`;(Z7To`@skN_vV&KG9$pQV8J*0>>28(az5zK4(?XGg%sK3B{6p zFaVGwp>jJR@PPDFJ03*QRB@JD^Dm{#XMd=RhBeA_(V>2B#axh=;aM2RUtBOkr|m(I zylvwZG+k(&z#g61_;G^pV*%0lJ*c8c*tl&%kbdYLY73KNGBxxPuK7)V5080jIPRdj zzS_yh=@Et&GJK}=Cni?1k8E|R8gM3`BbmM=3VXqNs(AjQ_i2#&nj-6D>W8Qtz{N5i8xl+AK55YX$%kn9DERtM1wdE z+c^I&wTB0Rs~O5d4_3toBd(&XfoS_KrG12w@n|2Z{1tkFa;^|Yg-o{+xIDN?)a#>o zN;*GyrjS>67_HhEO3}1-hT1i%k1)vh2xfbX#0#WT&3m+QZQA2a-a@Psz^HmFsi%|A z>2btT#4ojo-^335Y|Tyi5;FOt1xCV79qJ8Cn_?Y zHv}xT2yFAQ<3;D-MVnL>hP2=SxApq;EPUzKk6QJW1J+)`N6aaxgSqI-Y_P=;^kV!{AcQg-zAz6iZQahw=&=TR4si$320BsM?Aa22wYY87Kj7NKDVbKuin%pWSdvHI9S_aLlMyW9w3rz|d3k=sX$H~t`TYFfwYAoKC<%i%;599n^ zO41rO7B$`&tIJTesi=cq`XDtS_g&GbJB=nKzHd_!CJoG=RYl^V6eXK4J%I;bWz~nIwAedVr&`SAzICE$ULPuYW*33o|+^l91vbb93Nxk7lt#Db(dU2)mg`*1+h6phD7{Ntu6TcIoh%LIs|>hU@h-dw^KM zCdOl}E$#;WaO-|Dc}!tc?Zxegc%5%1Xm1e{ZU#fuLfw)KuMVS5?#%cB)wmBaMNG7( zF`pB`KSvQoE^K3agQRqnE^<-J_E?JzdEBbOVq#HdWD_J2H$^vABqN*6&d-=@vX_Q zAPj8$c(ASs+UIc-efYS8X8O|X9m~yKwrPC5EjLsFwwhlS&Sjpa9I(*!B zVuXfjkq=ikM=?~HSI;>}Eht_su>fH>UKO`Iz}=Y(h%o7HNudVdQmJ{O54MXHX^~RH z$0`t(06I{PjP8k&QIXcn^WkhIh>Y|EFKj0S1l7NtuY~F@n6na2UlYSQR;F)q+&x9o zWex>q$BG^iHYAHzeDFu+y{4sI>WI1nDtsb@%k`0gQotZ&B%Cr3$|22>wA0d33p zcE%Oi7dQJuXORgTsCQjb5fq=DSqT^sp!fqy=q8*ZOIvs61#lQCMomUg-$f)jahV9D zqORfBW6jZ&@8->1j>Q%{(dV>LVcHGM9K8DKca#K z)R0aqQEAJs8ACmA!IcBz_e$zwMGRvb{UcF2xTE3A7KE3k#AlN~c8O-2A|8w>+1vPj z#fKVm7PV~oAuuT*UTYwRW{aE?+zpPgDtaO`#G5~)!ufU2Y9QK9s#*lMCN?^ic%Dz9 z45V+t>|q(0V82>55SkDKo4ZT!BM-K`c*o|>T~Rt>iW!nko#^@ymV};TT5T?Bc+m%+ zkh6%uiFHL28GkTdNOM#c`><-uZaig-nk*880~Z{#)poI;A}iy08UGdfnxu9{WvD^} zByMF1@YY#RU0U}{Ub`og4U2QHHUkvt#8HYLYHY9@T3K+6C+YKv) z-D`rpm|`@{cy+n~D;N#;J`q9b`5#{ke>qc3f0yMMFQ32H@LuTYF!AMZtjO5uN_o!l zVp6+*f_{Lur#MC-4&AY#W)OrnUIr6BJ z7pN`0B%tbMZ)CNdUxy%)6p0ov+Va{Fu3eD@p)2tP|Gj zsW&ga*bzI@pX9$$?|-6I0=%*kc$(9xw9h667rsXAS6JC2yJsPJcp*0fchR{*Gv-x1++4j`10&v61vq%2 z`qxsGXKr5+I>FtUt7j)ZJwiJlxh&EMmIHRL)B@u^+cG@QdbhlvQg#(DQ8s3Y3)2G=YE&$`pY&NbU&>=T{u4FJ`unF&G#J0eks zs)rES$zXtJLq@EF7%Xa#M8-q!@X#WBL%o~JlLuAWGxHjrQ`2y*z^dS)a>`t{&XR?% z{V+GjRPi_#g-DHJND*~I>-v+UWp|KFS6Bqjkm1eP*~+3JpUDJ%Ao8n;w=9*2qL38p zYuadWvNG9Dr%7k>`fuZLb=>o1q7_zhD+ULJWexl*gIjiV=BG9<0zutJgu<9pXKLN_}ZDOU) zm??`>eKP?y?<6||gs;NmM`ZwZa9jzlydaek8i`Ms-e{yNo#UKWkXQEN!j)|!nwnbq zs51{!DILk{GB9To5v#C@Cs7rK6M$9V@;BFvy=o}S;9D8){~0>{lWT2oQ~< zcZms4d5ReNB^`(!bxe6!rX|${aqu-GG&tYY)fY38x?qP39#)VC)ZKC1HK+e}Azh}< zrl9p8cUZnOZC6lUMpMi+v!jG&j@HsAHbRyn>i)rkLd6-QYLQ}ZD1A#nKOP7UZX~n! zWNg>xGm>Of3P9f(J`h9fCI95u8$<3C&Iv|habImus)1^q!l#PGX8taf;nzA%+~!Ay zZ5$IWtLu~t=r#`^6f5navL{WGcv;W}3%DYNXKBKoYkR;~OlWHwUsjwdr6#T=p~m40 zpY>=W`@!SVdiUuoWZ7Kj^Z8SAZ)nl1TSwegD=p{W6YrZdL=$!fcz!HvW4~Szq?HE(U&fA* zTA@fyE@?FO%@5-7Rn?N9It&UKfuH=8!*KN9K$wZF#Yx;pxr&Kg64Rsg;U{<=S|TNT zR^A-MfeKKOm8yJg=tazNTX*`t+_@gHWom}!K-@P_LOjsGQO*tSxR)um^*NdAMtF5A z{Sh?|*7&DngLn&7i02bbe&%kCD5_`@$vCRU=Tr8K)9)DQcmxLJWe{k_11+c7;9Waj z*}5*q@mA59G#W!``VLn`9j)$ygg8wD zP$LdEy0Y`Ro@)L+-B-1zNy^Wqb9@lkpcC|GjhjP`u^+Jfmr|$u6Te1Fot-_{MI&X< zVA2|$xX#XN#Mi~zt5AUFuMpq8$4Lyws-M@9EP5%4uN6#y^>GRzUmV#0mB&!-`TD)+ zkE9kgxNP&$AX0vYUhZKw&jS`>=(<|iQj^=EpK3y_xLecs6WqP3oVaH-G;UQ`P! zkP0uqsS68qz@6T^=b9qb-jC?y1G#p5h!>a+x!df^HC`B<^gNj_k@%F}M4(r4!4xM^ z+>X3pHVxn2m#{0GHgvR>rBJGLAfQnpjki`U)0VH|-F405%o#h zb?0UPn@H51N5&=mV(lON15zOV)Dp~gEJ1Z)xF18ajFjxQHxS>Iu0=g{PAOz(d6cGu zgKi-|pSUX82v3bT5x9+ex+QEvUUO&ukvpPE3t^dtQ(bcQCg!-pbVo;VKQX*N>~^G9 z0|h5jqWBXREG=eK^URDp3tshRPAq%Ib4d`X%hZjjTDcZv_z5JXDUg0G&6r-<3#rt3 zj0jX#NngLwaV1`jJS%zn<}o$s&9uK2%VAR*?k7L|^=DCjPC5vuz00!>K$8UZL}THm z*oHEE?AWAQ3+7HSW|ndxWU7x$sHYpivm*l!X1}@(msj!mcCf3S3CYUoigV(^{@0c8 zn7pwJ2fok0ZIw0G;7m&;T{^s1$Q2%clX%MijO|s9t1D$QdZ{4rp&{bhB|3(#K2fDA zPhf}m2puRnr%!30e%S@h-Bv7uLT?kHO~2x`H`I|O9Hssay`F=FNMr)V!QCA@Ymw(3;%mj=E7)3k5PIfvU1H>jI~6!Co(eo?Bf3mQk%mG+)0d zN4(q^zihe3;{Ik@G!$qpe1=YWIb%t{dO%)+DDhS%uJ~*N-*%pxpollQQ`D^s8uN?GcR&>}+Ir-_6IqqkHjs69urLCn~S0J3*vACW_s%?vW;~%#h3eo zJPrN$uGMF0qRM_H<*z>NPy@)Q>4&ZC0}NOX6m5>T9uPeVG=^Om%v&b*X?CvtFhp+AB3wvYh$Myy|7^U({iH<9-_luZAs?OiA zwk1btWL!PHxw6O(ZaaKI9cUfyMAPe|%mP?9Fualrzz1y*~EakCW)z;1*a({hn!9=fQYU1=8_5VCc*deZlFsoc(eEgEufp~nZ~=~Vg6B;im0&k;krBAerXGF03x+>D_ z`2|yrtCK`!J6LPdmU{wwd-+0f?gV($&)f+!XHnGTMj-cTV$cg;y}}fKH$l)QOXIh- zk~C4GOlM-Yuwl*1IS1+CO8#Q8JZ>c$h%L22~_1p4u}`a+{YF_b4_=O&ckV{pi!V!70W=@$s7Y%y+(? zd40zPq^UD;=9F0e)I%u#vY`B?7pPRW__#QgkFra(+^<|ItDjwS3t)%V>&1@OPKBU~ z$b8xfkoY)(PP0nK-I_7+R*Zhe6NL$bZ9W*+u&+z`ct$utN2@vfU1=m9Xj;kXWLBlh z-w$(S0u*Lxx;SZ@)E;lX`yvv6IQ_hZ7sw<#KIW<{Ds;+7+mTt5!v}eF_zYyt5PQ zn=MB%4CUrB?9u@WtZRkF&<78R;nqOxUoGEh=@pIbX^FuGj&Z4{-zSr)Z=SGCM4KMb325rXoe{WQ*p) zxTLxvh`|LBI0mg`^DC5ATPBz&eMNVopOVNU)h1hjOgVXZhloYL&Q)N8bP$OLSC;Pj z9cwbNNKiEq(T5`VbC?5%I1^aHZVG9yT~DtR0`Wk6n9kk!g6K*Y!sYGx_PLj}g7Dm7e zA4GtzEV;VI|7oP0-`O6V=|y+(*=#K%j`m3`g~9IE3mt9K5aHGJ!b~WKu#ge6b%k_fyae@*Dn0U7=FskjHndYmaq)v7<0yHYn1SN z`XK!FtsG4e{kBbJS0G{ zX2w1}5_s%zlAkQD@Ep?;HEe2+Jlgf!RryQrDX!zVo^kiAMU${h6J%yf55K(j69Yl> z$r=6r@-YMBYxx2tnI?a7A?|PrgZ1>wsm8`Ra~8TN%K+#jXfr_7-Ud_Q)E{Vt_Qj?zkK@rncQzFH(Q*2xn z0b+4syMMMVrEz!jzG%iX-N-=87Pz(hTvyog?nrPLSPELtbJ8jiC7JZ!q0t@eVwRt- zhcJH8@R}uak84*#TZ6k_X91}y#nG?v z2{IPX&ToN)qBOaEapcRBwDDyPx5N5o;n zJbnETCzUN6N$FiJU9*Ex-L=+YEORzl9C;gp26@DP4K!@qE1e8ZmX`hrUl_a zWfnG9&5a$q2l}N+EV->d&T$E}=1?oif3}2NzkX#RZn|WlMgiFVYTru8Fikv1Ut?gINb| zT)r(f^uoPWX+(iWVSM`IbJ^LCC2YI-Y47H!E<3?>c-zp&B+&76vZAkRdqxDy$uk4* z#B6+u0p}h0UdYH<_CaFr26pBakT#w4pS?da1j!~|f`11lTxt-BbK zX5_(`O7u1MoYLqm8}jlNH6@WjVmHgRtn#jg@EE60S04@J7zpVt0?{Q+S@g(7Z@P?= zW{~xVT{~dMj5m4n)QAl;F}0p_L$dxSG!CnEp@guh;m-0j=h0?IDo(tD6{IrC`Q4YM zy0NR;2+(|_xEd~}Qdes|xBYDD9i`BhzOuCy|ZTbhJgIz7eK&T73!$m`=}@e&Ot_%kd=7H4p5-`*G7b@n^*=dIf5_6|M6rL$Q~ zG;RzI=tJ>n#1$ufe)tuMNN=%xSuVh!n`G={?#s!X;hUlheg1ZD5`I7I<}NNGq~Jq~ zOnjY&sf9=W#3pnJT@Cgi<<^C>QB2ZF29gH#f;*{f@&<`9Z)1d;s-MJLP8p?{JYK>n z<=Ec%5DS;e8?8?KMvaAym3}ZYF}W;>lgH{_iLWI%$nn|Qn@ zGqvqtR0DOu=~ntZ_{44295#13z3V|ve!(D({1*F+I5ph;o;VUB_3oY~p1P)dU*R`Z z$~>2cEh?m45W!u%>}k;ffqwV;D*O0Z>qsyD5Wr-r%;fYyCi1fkI-Gqe?8b+HoAp7! ze8H-~o`mT_aG=A~BeA}wAW~76Prb_>&_rzAW#ZWHMQb=sa6QH6hW}Z&>&& z@huv(8g)}Zg}F3c z8dVyqh8P3#V0zG(7;WXwOJQdMyO^m8un}OZB`D97;V-Js;}-JOn-G?K%pbzQhSx2k zd#FRz@TF8x@ii8+dq4Uh=bDv%qAr!9VK+avone=3fG^zAQ?m*iQVC+B)X5j_IROPn z%35S_cYNL*ZTar88rQSQyS`@DS`8BQj{@VqW$Nb%2!qjJ*FL`nOqVe0ZDx$Gy6?F0^n}-SrIq`%gE&Vo!D{Bgr;i0#T=+}r!z&p| zpRu-yzBQWfQAQqS7^u8o#4L|M7L}ksvB|`^QTD-mt4O|0CTHzl zGo}4lieCIv#HJXY<3mXR3I-XsBdPbI0uE++4~=~LLBH$ir}|-Cb+JeWEjY!;Eh}kD z%)~f#TodbInLrIx)+yxo2jV8{;EJhoavtWp6nQ2P#qZC##B>5H=4aQFPMIy-Z^d!`p^=9^T1Cd$+N~W)Sm&05Rwb>A<=-!@HEBVX~ zXyQkD*$40D=?*u47K@m*PKGniO)M~obrYE!jDTSN>H=)# z)HOL9De6e&A*@j?U4Z(Lcfuq!-qh@V=jOf-EDvUDb`Xtimr952;<~^P@L&d!N$>fo zx4S4@_zn#~xkxN$ghym>i6QqH8>F1<{X#CXsO!>#6oTGP_ckpVe=3yJnX0tLzKtf( z+VMH{y-Do0_Jcc@t?YM6vhv#*x|WRm?uS)9Oa{QNEofr4G_qRm;#!ybf_m_mQV&Ym z442y;qoK%jOWjF&PuhpWUk)gtKCVN)wDfJhdbkN6zOpPh;$tx7xDXsB7g?(nuX?%f z7p4K1Iu}PY-rC~Sp~gI5Q5gv^Q?|mls@{E9#n_~dkJUov@8c_tooL&B7z?5%^x#o@8Suz4BS4rrm|yqOk=Fvh6oEAK!10pTaq!Lc8Av z%{&jZ6R2c(g5MG=HR<=cGwG$LtdQbvUky6?IiZJUk}n+H)Iww+waLdRUy=Svk$PrX8gi2rh6gi_Zfga>Z=|ZST`vXYPB7LaRfPcr7fji!66safV^UgGbKdS>X6Bx#I{#~5hFs+~-vo_(!Wz~x`Je*G-Y%J` zmvC>uc&UCD2%3D>Ti@mz5qih}bYkvsUs1I*v!s@{t8~SKIy3oB4E=;fJMPU3 zm9M6wfh}hE;TG<_06N|p!!kV@c>(TP-SM~D3TpTY-07%?jbb_57B^40s6%%Fh0WgM42Wk7kedswj@JqYLFDs^p9LEf_Ge*GiJ%4HXC? z4Mn=`7Wkmjr4?(7H(o;3LIEOC5=PFmHlmlUuJdzzl7hB^*Ki^Wq!8m8sLg_= zmLX?+NEw9|H7Rei$OQpa2@UCp)3*nV2L~&btvh&Uuj#6TC8r$qP?d(w`hz+n5egd% z!t(qszrET+vTb>{=cxPb`^uyp|Cg{rCwM7Fn)Q7cYS^|2NcdNW+(E9D!LEw zUx(Xf_4_DM-8b4cB9U__%4CAz^kOa@A&5a78+^7<)L&mDHrl#L-JF(ZgBxzH|$t0t^}F1;M8-{9a~B6t4(QETfwZ; zIL}8tjQ%b{P2e&0EcG($j?z!PQ&g>o))NbD&7b#PETWhtHAfJSI;Y}IOD738)#qg8 z8p_Cida1djk})ZSbmZVmghjG9zdB~9>QFA|gi4Ky3`%X9as3j>tD-xrpegJ!9T=do z;?)`P%EXW{#XoquSo9DL?qyrADxmE(?-e0VJg-LcSpaqp)Pze8 zmbv8AZyTTI*gXMskC!I`VhM5Kwb>zb2}Ac*S{o4;7Zv>n2{GXBVJy{K*Uupa2IoGZ z)c(NZl*$IFkpBWrW#3<#P_eS7=^qhtF?=#WzbJO&tbq<&xN#!Qr8Z`8{e}GUYK4Ky zHj22Ph+B*`Sqa3_&kww*^xR?hsk}+HnPynfh7>xAH}PCN?H31vtn_F*9#}yulV_Lp zc=^Fj;#+G_l8*LWX37Y{cvw~*=eVFMj3>1K{&FUw`bF>HfvU0+#}QzhPHqr6+kL3; z&GjHcGTZYA*bi}3F|a>DikK7oG>jIGR$zdF!&JtBr{Bm`>)u15oJj3jeRSsfgl*Se z_lNua{m91lc1qfLqlX0Kvta4s%nUS3VG^%IzqQB9QQe%SIU1G4`SF~nUxSuA6ZvQnIF}==Yk-K zTq_sPQq`7*X@Gt2+Zv^+<>>&n!}`t=#nx^|Yg%r>VV%)U!pMc!C#&ksAghy_XZ5(u zQn5mpT6mX8tE&_yuLRLdo(Th@iMW9Z5_HMbNoY>p?`>;w5Z!Izx<^9-jaQ!CyfIfA zepVtXb7LL+dF3E*s_B9$B|$2(<7RZ^@=FsV|5a$o-rn7JM;({k+8M31Z@;d&zSLJxlr{8eL+vf11mgBg-R2jW zr`@USW->(fMn|hfC8Fw=SxqTsdIlnMZ(j%Hz5Vi09qoF*)A@RHch2=nWX!3nP8+AD zp)q&&^V^>4&pyvS%-vj%#C^GDagYSCERq40g|H8F?hjW#AO4I?@j@S-zsCU{r<>}S z2;IK~G0c=2)N4QH$(cDDj`T)g=&^|YPF8D-FnXjVEk9gSB`VS#{TSi2D%*;gb$K*QkU(Tgadvkzm}Qkue& zR<7Afv#ggng!ac<&V~sXSewEo#1tq1#cg=NGG;NxT~}&?guq_d$##E!QNE{UbM`uy z9o1`#*itDfwUtBz_4;s$uNI;+rVe*4o3}Ka)!~Mz>L3C=->{csex{$Gms(iT9(Hv_ z>-UARnKN6?`<|oR(U{oF6c+y@!0^(}^Oz^gM$v>0(+R`Qy`D5HfwDsIX;Fad&;jsC zB5mXIX}e&VRNK5qgQ?g2F$rJy7CR7A9wX&AHW@rH$>bgR#wml(ymFRe{P5MImn7;6 z&NF#@2VrBzBWv@B!;3rOoFl7w*&icgH}&@yUnWtmT!vfCt%?Er4BGw3b*{W=%iBmJ z5bv-KKjX5!qK`YKWbcONDI6M!7$avN*Jotc!N*-%iEG{g-?@HOiEp@w2rBnNK7O+` zCQ?=4v>X)sOdks?+W9QNsK0w`U(aog@?O^3d$Dr_%BxPc9!ZHsQX93Q2={xUs7)HM zEk-fZ=Iq@4#P#j#-hPDK#f9#y_5)iAZwC(BR1og?H^>E5^86kL`eklO{s~pj6*s&+ z1&=kGJI}xkr`6jpd*T}CHeC>k#fecE3$|Li&5FeibWlJQCniCE<7{oSRk)}B2C4ta z+NLzZwQt@^uR*&Prr7yaksD|RFAk}eSa$))mbGXd-nWQKc{5?ZeDbxbu3x+pCb}Rek2x|3$Dr?_%q{8TO?a>$zX`7rZ?WmL6EG9vcDv18i!3e| zvZ+U+Wtg0{d43!&SdrH|79i^g|I`#OG^Hqr7*^4$vMa;McWmeOnf^$_~ zy2gtnmBlxzDP#s3NVaYqm6~uWo2&9~CgJxc96L%so>ZoJiRwX5f+#l->F80BxtH6@ zV>&Iu!QYCIK3wV8R5vZtB{h~sAnB3Ym<_kXt=z<{x*WHvh<;sk^*+QVm`mlWJFt*yL|Kw(y=hfyD+bs&psdxBd zEjf8tht8>>84XGdVkG|{NmQN^lR5>)@;h7#-P%u&?+^qM@WMgN;-!g+H27!3G-#d< z1t)^xjh@P0-P|{Y1Gudh14qkw?C77PS;*-NrWt$U8u;uke+*b(T$SO+Uz5{jYugli z^Z=DQUJ{tA#0|=oQs}%}o(4;6%FlL*a|RMO7ZXGL-DrCAC|3Jm+x}MV)=7P-RjAxR zJ}({}0kFp2*Hk&(+$EZU{&n~J=+ZjB!?$S%*E%`gJ$yb-@%{E>o1KqBvIMFsV|53h z4O$Xw#NyhJI~hFD3%GQ=a0&EMW97=%)7(o)l}7 zl}b=b=RX^J2Hy}M@t9={{+esaG^!IG@DcftWv%i^Mv$PVka^$7lAa6;R9np8Y@HM* ztaN{SHs~ApJzXW0#{Bd)e$Q7rn(E3f>2>}w(_p5Onq(SMbR0BN82eIB57$-hw$ts( zIG1(iVF6PJOFxJGMlzv&=mX@iX97YuAE=u&bW>v>3wL5l=3ib>wfR1scXkSY%KOQ3 zx7{DURmPr9Nmi3BY}2}TVagi=L2Um_f47k2J@fU|R)FR3wg2^Tiq*uzqbPe8SojM0 zynFy8^K`3sk*5u-QeN6oVg=R>A-z(Oxl308e6O93Y#!=ro3~#4(PJ@Mg7lmEB0K_U zo3^JBQ6d9rPEZ_ea>(RO^tkP;D{yKc|KV__5v6=HIG%9imrJZXFO07yW$n6OOLm_}TUyGgd6{WF!0>Ja_R6~YI%_%hI`q9y)BowL>BK&>r?YPI^VrrT_Lvsr_873Lv z9u#p>Y`#oAznc}g)WSQ(Y7(wwpiYT_i-GiVXN;`nY<){_MO&681$@yiL1P;7kUVC- zDQC)I82$-CWHGtPa%6l>R|9FtBZ7cnO`E2}$W~ch`~@M`R8^vig{kXLqN>Ssn4RjW zkq(T)q5?p@myiR$_V$}kUoCdZ=K9fHp1KHG^f~LKPF|kOBYAE6Q8vT=p_fXA{XJHL zNdm>mygOg2j19Yj5>R2k5$)IfDN%AFr>eA@WbK^TKP7ga$|9dpy??8zJ%!9??17xL zfk}A$8lujS2WmPH} zuq3Z^Y|#hZ13gDWi3r66ZJ#y_jg~fA7}=K-%?fAAaM^NY%9(y7J(R;??q%)ObagYy zZ20=d2TwbEqch~utecplO-oct!IjGCU8?Rkmo1N0Lj;wS!%TPO7##zS>!at@cN(0h zzeZQmm7Rf}NBQ4Fm+xQVr9MKP^b1C@nGM%V+Kut}zgf zAafPBd#M1Yf6u)`c_x+VMrkcn9a>B(nn*(7x37r~Q^_VmxW`vl@0 z)@;Xac*F$0`AQ)$Gd`gKa6lHI8HbgZmaE==R%5naHhy3qzG>h$N`#p6gV>#+6 z9Ez6R?pq!2XpFWK=hnMN+M?e>_E7Kne`-0)zb47$LBbY^DPlXdc8w$ z{Rn|Nk;zw^a2dELzl_2DIuWuks~-eHo#$y-Qa|1FLS#Q)2^a{D+!#|NsWSEOt!Z)e zeZs05JKt6e7Qu6t1Yg`Ctijadh_IZPW{H&&t$RtEDtvwQOMeOdDehCOxS9btyH!07 zVL(LAAa+wnSrcrYp!M*RXcGFZkjK_)N$JJ$VaD-?L%r?cC&-v!Bl{Qb1t9eJq?q66 zO)I=mL0m&O$$hOGX$@j&`dpE?zeyr!gSXsrzxbwP)>j07JdB)U)7od@H%;>v(w~>A zv1%Sq5_s$r(S!n&gGeUSkZTW$wz{bFpksBP3!b4#S~y#pIbO8pGQoGUAA1t+3Xteb z2}fj)s>{#MNm!{X8X z78O8touAZW$r|f(r}Lr^fdnZKpoPK(y2hBgWceBR!O?W>_g2PdnsH5`cz zW~(%fF5@JUBR9qHXQ>x)m>_c>{?rzvZD3itwC5!U&(OS_0GqA~AhlqKE=fR+DO)nu z4zh_gxNp7DMyE^GR3z6La^@Gdc*BNsIWTK&!Nu|;Jb^m$L+?2?NjK)oFv2G+cgwEJ zi9t_fyH&g&(SX9Mvit{_e)M0|Z`N^K7 z3Ow2+PCl?$Bb4p;B_tgFNyFvvs_jF0o7hGVmbl27`+8HS#IrklpB4t_uck?`mzNHS|i#R0uVSX6S`a0-pgjamj zEcY;1UqwAAUX0@wW)-q)_Qqj~;LK&s-M~Mo$shFdtZ8Pup*QjUI9YW&n^_ByX{@jy zZ?2@xMhVE^R`y!Pz#I~MBwTW}9%wHfi?~yGX5s1WS(gr!ICKUh``G3|RwfY1UB;kT zD7qANKiZjHAVR)Lgg1TKm9%uz;=~p&C^0gr9gZ36*nAOc4UDm-t+ou$Xp-1)#M`MeN(p3>s-YmlmY3mX>M=-{k=3GLf zuXGLhKz4$kB_Rquy&;wp#RtN-j0%%mN@LI1M8avaLHwbs7w10xzSU7EVI;1bYwPS2cHt z$lXH9vC22m8NYE+1w-N<+7k)eRT~3Ej&y5YRMp+@7}x*Q($lJ_I8v}I6XgdAVb**I zjH_vYnV?Qu$sgs?N3R&Kv_JPnShzoL(@AN3oE`s&((d$v^T_rN`&#{=&Bn7(C+hYz zuO$#WpZMrP#&Uo0fgvX5#^t1tpxSXnL(qRf1~I^53gmb|{yQ`M?BY}=19j!QSux3= z!-%$R`exlWzE*iSQM zF0bn7W9dulI>6Mox%~g8WaO;jI$it3inhzAKf0qo2#Cv3{W-HkDEm}pj9uXLi;c?- zXh;K358hVW@mP*XL$1lXjs8ts9-W;UI;UGqR3I=_#etZ%e`35u&F&kH6NqCzD_)2oj?1@YGktajbt|{;&h9i$1Ej4tMK~cr`#lxF@b;TOSb4?rd?DKFk}BrM zEuHkSAAu5GPGj=7Ydeho@>yRg7PbdNT}CfKyu3Q4PCfG881M|YBbU1OEVQ`6m|K&aT@U)jzV-#3SSww2S4*nwX7gwZqup#=axIm;PXxs)Da_|+ zs*bNa9;<(jvsmA@*#71OVaJwd{K7FFT#k9MWB|L=gH* zn+z&|tQ@t1mtAV)?>@XDDxjdCAFi?JEwE5G%Jd@+mMz_6eYp|<-Wtr$V?})o%O0MG z^H?>WKds_!d0%CF)Bt)o_(HE7;4Aa%nUpVQqJ9=hR~vg$fg@ZeI2`L@GEIKjHlFI;b~YfoXJP*?W3 zrPPnT7DBv$A3i+GqA2D3=Vh3GxvyJSHhaIgF>Q23ZD{OgFLv059(f9ww+u> z`1rIH0;is0tkL%9hLnp$dr?n1VIsW<0?Hv7o4E^9DFpZ6%x@f+YVwhG;TMkgC=n@f zztkzWChz&_&Ai*1U(kDHXjtJ<6B|`(Fu$s~b5c*u}GAFJ7v~g83!Hj&V&Y{JBtjJH=4kmF*oAvdR@UvN_;nD z7AWxSz1Hir)E;>Y=B57fJ#O@m`K?Ew%}-BoMX|~&m5>*1s!z&z%-mrVHcRJ_HZ{dx zP>1^LqoyQ6&FBxSiQG>WzsnAu77iZob!JS^ZrjYBje902tv*oLphqbyAf{d0>>nhy)t|pvfjzDGu>Z+|T~3l> z6g2Rh^JL}``ml2fn{jZ9O3)`6)DHM;H%=b*jy{r2$|1DoK+7$XOc31H$m4OSl)pec zZl_Z-Lx34i%Ksxd@Rj_y;{LV;?8>0}@ID;vOd}=~v>H4+s!h&LmGf=K`Dp;Ws|=QA zSk;E~{~PjgIJ*QBNA5o~qv2AfA^V!m-Ozs`Bep)I0}&EqXzyG1fvY~eh_SB^>hX!< z)q@(wB#Y*s2QQjSg zV!_}Dat0mwCrk*-gj*S*o+^LlXo4N*mw$iFur|0sDJb>jwRvm5vJScvz8r|i+1&gh z()IQYqXnR+Ud4nMOX|fvk$L+zhy*tbNJkV2%?`FOZfYh^j&2#I5r7mF|!H zE)z^FMaJA&^0r$q2a}lOrw~>gu!uE2#W6)9TMf;NvjlLR^uqTzbU0tPvU)T;F@y+L zI8Bt9Hj3(M4eu6T(5SzaE%)mY@7={H5&w9h)c99%aULdRV|A8? zBoqc7rqn}lA*IeRYPG{u_X%0XiFJy4_YIor9#3~4`cd3u1=9s2k;!ZPq!#yx$*fV= zpH;=bMHN451Yy*XU4DC;RJpc}mAO3bj_-F8_Gp=)_<2U|Z7y|T{_{@+!eCAwE`1uR zqW42*pI%(-+?*dkZ$%j}F?yup7Li9sZ#h>MZ=La~=@g_4v>OA3dC!VzUy-~UUdZwA zCDoO4#qLy%U=L7H6{MV*-ZeKK!SAT0K%#d|!Omm2RZh*eK@X__x7=AsPl&Hhu>V=DiJtfpz*D)-PKNK^ z9|YPlEkc|oUEn}Zh4_&c>A0^@1=*JD#DmL_JV?c7{t4~&JRd1-Sv3c4=(Nr!nM^nI z;=D^s0kqJ!nispGSiL$DvNHP9R@yF0>BK53@)j%;;|zp@%pDFUoIJ5d5y35 zXK8#kr`s2F*t_;TFTS=z>npXapLhIi32`Mw$i7g>pNsC1OEKSuhsg4A`{W9ADdGg^lt}UNmdq5ojo|(0P4;b>~m|5W@XpQcBVV{ z6r@O0JR0hD?YQL>YPS*s1^+WCG+6J1{^&V{vSY{|Jln6wQ)g_YG5670Jf_+2VSgU) zH>I%j*c-TVD>^IYFaMQZ6!)S&a=Vcb^Mu8>d951R8)Y>$=BM9blB0fLp4kAv5R4ry z4NG|}hj864T6birQxOJjJC^_ppIM1;*N0`pbB7@Cbw<&Wwbz#T~8;V)KbR+_>yA<#cp}D zu_2OZ%*~cBZ?lxq8ZKr#qrnc_mX8q%u^C7mo^IGt_anS|`1-Aus$u7mDKnFU={sOO zH9ewA1Fwqh-B(!E$21rc)`M&u9?-f5)}>pLyc`+_cSgLdhDsB^@$MzYl^lR85J#GByA$8Tm@_6{B2sNYz^|it6bd04J%>W?G2Gu=2DQ!Lan`!;0mGp;i)iERwvPJ_IcQmu^68N{GL5y)B6pLO8MoCR%O^j#CZ zH&CaVR}CK*V#YSRYw24(*B#w?U8yOj823MZS84Fot*>}CxXPcvPNZZ?jWPQ~VI=j2 zCJ2nt<9X?ZVJ_u$E?Ff9+Wn`z%23Ajl5XEt542{*Qdhp&V}+i($Aa4x2ZchvqDHx}9$c0+q>vf%FghaIwx!2$4U(lYLtpu=@X8vfsZVn~x;e{+azE#O&gq%z2r# z>Yp`v*5fX3d;%dnzY+R~5-!Sp&a z*nvTB$l|HTH|p)+x;KMXTR9buH&10bTOB5eGDUCK+JH76Z)H0quM}Nf6c6~PtUW!* zD5uz1?0d*-1(&{`hlsB2;xZ;G!1Yoc86S4@SJT>FK0eFlu`0J2|r{yX&oe zPyY#6&SiM~xo{L*awb47ys}|tLR_-YR(h7r4)qlhvpanZsDHU%dU&l@OX~E<5^%_{ zu2;o%d8fZ&>HOVd+}@h>Ts9?7)!i>s^s~B2bp%BR0Cqvs6KtPbov!*|3I9V>8-`0x zjiB!@*^7AI1d6|PecOf8EIz?o25vi6gAT!QwN%g%TOQ8RnF<%1wpfBWXX3iX_-tBy zNHCYZyKY+&-XJ~^b?}RdJSP*$Cp?vqQ|PRe;{t569}P1;BfOA>Z0us~i6-m?0bZt4 zcowAbt=t*{`F33C2;#<%vd*U-rsNe_b2T)JoY#Hmtli>y<|xh&EUnQdQ{z*w%quYF zF24Uz?VA$ho03+gl&XdyEgdT*6mpQV=jzyOkn#GVT?|WoPkiPht;&1q&hg>yBK*!& zWb$gJWJQ)f?oUQU$RK*674uLOp|6BI`DO4eEGEa_fRjS4=seXnn5vY0TM_dMm$ouGZH(s6QlUQUYb{o+21 zm!p0Og+DSObVR<-6WEkeqLFQQKH{4s#DEbBa=sSBjDO&~)}{x-Qz56-JOWmMsC!`S zG0XLZ{_kD{=inbOX-)yMSj#u(HAOnNYuf2i?-eM0vRZT%lR|P67GM8cIY1J=>BH}0YGVU%{HlsdYYEnr2-^%i>Yc0oF2@G+`EMJ6Ogq(*;%&!SaOq32?(tOun1v*a+A$>%<+(c> z18)X(ZQQGxQeYwl*pgsoP>C*7F^udOA*q&)4e!r{Dre8GGIG4g+1B=~F}EA8Bm=c- zfYi>#7_S$SRGZbjWfJqsy%Ard3v7(>s4h&(vwsMn8Q`dYM?2OKpq(*`f&o3%F=q`2 z9_0BtFWslD8L*mM!@4iIGWN_)I}Rgawp{;hoq6=1oxTPxgRdz*6r|#@m;J-9tMo8? zagkl-e>cAVKA-9RIQ~5(Xnv6Bae}6AcmIdK+>yX^OPcUE;6A3P~lTU#d7CW<8 zURDvz(L=zAZlG z>NiVpvRM&?_pC$F`EX_e*gf;Tkms~!|JFKAnNA3lU&3!aa^;f1z(lOcoFH7SpYRZL z%!Frgm6|`4UUZ*wRvFczQBm0+R1Xc2 zmm2=?E@6BdDCb5BqX41LWL`^)0AHB|*iGK>4q4L491OvB-LeBgf<8g-#v}{^D_n6A z-Cbl@1jS_}?(B@Lz)C!!p0)25a0EJ*Lu)So(Fy{q89s((b;H)ZVcy{|s=+6J5)1*; z_X#}ghsEG#d_jzu%?QEPFVEP#L~YK4`F}@%!kSx9T?DgxhRS$QsU~r_kT=_tYr+=N zAnA$ckBzUzS*h*y zRFnupf&`V{d!Sr6e}yH3TUR-qwNPA#$dWhBosgk2)P~TIa}qQmS^@1?(0lW3_ulqe zGxIFK9t;WoYh#7ETE(MhryNtS2xtg@g9ZtNtoCfFFd&}QufsMKoB3~C$%B3#uS|Q; zEWls$NL}GN@NC<4QD|;kWa%P|1Rh*Ku;8ISL2du|y@@JkB8}cjSbo3eRsB6`p6LK1 zc4IsbS9>T@1q|8vcrUqk|(CEx?b8Acz_z{r6BT3uBm27{_MOle-YdQ~#`I@6 rJiB&NvBBd~QOy58>sO_VTLM6o4|4aNgo!8~_6*R`glJT$*+%>iWYkzf literal 0 HcmV?d00001 From b5924e13e21abcfbde33fac8f0b26b9c96ee56df Mon Sep 17 00:00:00 2001 From: Sergio Abad Date: Mon, 22 Nov 2021 23:33:21 +0100 Subject: [PATCH 3/7] Solved dark styles --- docs/_static/dark.css | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/_static/dark.css b/docs/_static/dark.css index 395c53d..4f069b6 100644 --- a/docs/_static/dark.css +++ b/docs/_static/dark.css @@ -16,6 +16,9 @@ border-color: #736b5e; color: #e8e6e3; } + html.writer-html4 .rst-content dl:not(.docutils) .descclassname, html.writer-html4 .rst-content dl:not(.docutils) .descname, html.writer-html4 .rst-content dl:not(.docutils) .sig-name, html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) .descclassname, html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) .descname, html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.glossary):not(.simple) .sig-name { + color: rgb(216, 212, 207);; + } a { color: #3391ff; } From 106636bcec7d46d35278998fa3512983a4cf4a9b Mon Sep 17 00:00:00 2001 From: Sergio Abad Date: Mon, 22 Nov 2021 23:47:05 +0100 Subject: [PATCH 4/7] Improved structure and format --- docs/amazon_paapi.errors.rst | 14 - docs/amazon_paapi.helpers.rst | 45 -- docs/amazon_paapi.models.rst | 53 --- docs/amazon_paapi.rst | 26 -- docs/amazon_paapi.sdk.api.rst | 21 - docs/amazon_paapi.sdk.auth.rst | 21 - docs/amazon_paapi.sdk.models.rst | 717 ------------------------------- docs/amazon_paapi.sdk.rst | 47 -- docs/amazon_paapi.tools.rst | 14 - docs/index.rst | 20 +- 10 files changed, 9 insertions(+), 969 deletions(-) delete mode 100644 docs/amazon_paapi.helpers.rst delete mode 100644 docs/amazon_paapi.models.rst delete mode 100644 docs/amazon_paapi.sdk.api.rst delete mode 100644 docs/amazon_paapi.sdk.auth.rst delete mode 100644 docs/amazon_paapi.sdk.models.rst delete mode 100644 docs/amazon_paapi.sdk.rst diff --git a/docs/amazon_paapi.errors.rst b/docs/amazon_paapi.errors.rst index d1e0f39..34e5cac 100644 --- a/docs/amazon_paapi.errors.rst +++ b/docs/amazon_paapi.errors.rst @@ -1,21 +1,7 @@ amazon\_paapi.errors package ============================ -Submodules ----------- - -amazon\_paapi.errors.exceptions module --------------------------------------- - .. automodule:: amazon_paapi.errors.exceptions :members: :undoc-members: :show-inheritance: - -Module contents ---------------- - -.. automodule:: amazon_paapi.errors - :members: - :undoc-members: - :show-inheritance: diff --git a/docs/amazon_paapi.helpers.rst b/docs/amazon_paapi.helpers.rst deleted file mode 100644 index 35af616..0000000 --- a/docs/amazon_paapi.helpers.rst +++ /dev/null @@ -1,45 +0,0 @@ -amazon\_paapi.helpers package -============================= - -Submodules ----------- - -amazon\_paapi.helpers.arguments module --------------------------------------- - -.. automodule:: amazon_paapi.helpers.arguments - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.helpers.generators module ---------------------------------------- - -.. automodule:: amazon_paapi.helpers.generators - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.helpers.items module ----------------------------------- - -.. automodule:: amazon_paapi.helpers.items - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.helpers.requests module -------------------------------------- - -.. automodule:: amazon_paapi.helpers.requests - :members: - :undoc-members: - :show-inheritance: - -Module contents ---------------- - -.. automodule:: amazon_paapi.helpers - :members: - :undoc-members: - :show-inheritance: diff --git a/docs/amazon_paapi.models.rst b/docs/amazon_paapi.models.rst deleted file mode 100644 index ccc3bdc..0000000 --- a/docs/amazon_paapi.models.rst +++ /dev/null @@ -1,53 +0,0 @@ -amazon\_paapi.models package -============================ - -Submodules ----------- - -amazon\_paapi.models.browse\_nodes\_result module -------------------------------------------------- - -.. automodule:: amazon_paapi.models.browse_nodes_result - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.models.item\_result module ----------------------------------------- - -.. automodule:: amazon_paapi.models.item_result - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.models.regions module ------------------------------------ - -.. automodule:: amazon_paapi.models.regions - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.models.search\_result module ------------------------------------------- - -.. automodule:: amazon_paapi.models.search_result - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.models.variations\_result module ----------------------------------------------- - -.. automodule:: amazon_paapi.models.variations_result - :members: - :undoc-members: - :show-inheritance: - -Module contents ---------------- - -.. automodule:: amazon_paapi.models - :members: - :undoc-members: - :show-inheritance: diff --git a/docs/amazon_paapi.rst b/docs/amazon_paapi.rst index 3d06cae..89cc611 100644 --- a/docs/amazon_paapi.rst +++ b/docs/amazon_paapi.rst @@ -1,33 +1,7 @@ amazon\_paapi package ===================== -Subpackages ------------ - -.. toctree:: - :maxdepth: 4 - - amazon_paapi.errors - amazon_paapi.helpers - amazon_paapi.models - amazon_paapi.sdk - amazon_paapi.tools - -Submodules ----------- - -amazon\_paapi.api module ------------------------- - .. automodule:: amazon_paapi.api :members: :undoc-members: :show-inheritance: - -Module contents ---------------- - -.. automodule:: amazon_paapi - :members: - :undoc-members: - :show-inheritance: diff --git a/docs/amazon_paapi.sdk.api.rst b/docs/amazon_paapi.sdk.api.rst deleted file mode 100644 index 9780972..0000000 --- a/docs/amazon_paapi.sdk.api.rst +++ /dev/null @@ -1,21 +0,0 @@ -amazon\_paapi.sdk.api package -============================= - -Submodules ----------- - -amazon\_paapi.sdk.api.default\_api module ------------------------------------------ - -.. automodule:: amazon_paapi.sdk.api.default_api - :members: - :undoc-members: - :show-inheritance: - -Module contents ---------------- - -.. automodule:: amazon_paapi.sdk.api - :members: - :undoc-members: - :show-inheritance: diff --git a/docs/amazon_paapi.sdk.auth.rst b/docs/amazon_paapi.sdk.auth.rst deleted file mode 100644 index 0e158c5..0000000 --- a/docs/amazon_paapi.sdk.auth.rst +++ /dev/null @@ -1,21 +0,0 @@ -amazon\_paapi.sdk.auth package -============================== - -Submodules ----------- - -amazon\_paapi.sdk.auth.sign\_helper module ------------------------------------------- - -.. automodule:: amazon_paapi.sdk.auth.sign_helper - :members: - :undoc-members: - :show-inheritance: - -Module contents ---------------- - -.. automodule:: amazon_paapi.sdk.auth - :members: - :undoc-members: - :show-inheritance: diff --git a/docs/amazon_paapi.sdk.models.rst b/docs/amazon_paapi.sdk.models.rst deleted file mode 100644 index b62db90..0000000 --- a/docs/amazon_paapi.sdk.models.rst +++ /dev/null @@ -1,717 +0,0 @@ -amazon\_paapi.sdk.models package -================================ - -Submodules ----------- - -amazon\_paapi.sdk.models.availability module --------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.availability - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.browse\_node module --------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.browse_node - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.browse\_node\_ancestor module ------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.browse_node_ancestor - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.browse\_node\_child module ---------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.browse_node_child - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.browse\_node\_info module --------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.browse_node_info - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.browse\_nodes\_result module ------------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.browse_nodes_result - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.by\_line\_info module ----------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.by_line_info - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.classifications module ------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.classifications - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.condition module ------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.condition - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.content\_info module ---------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.content_info - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.content\_rating module ------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.content_rating - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.contributor module -------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.contributor - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.customer\_reviews module -------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.customer_reviews - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.delivery\_flag module ----------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.delivery_flag - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.dimension\_based\_attribute module ------------------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.dimension_based_attribute - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.duration\_price module ------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.duration_price - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.error\_data module -------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.error_data - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.external\_ids module ---------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.external_ids - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.get\_browse\_nodes\_request module ------------------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.get_browse_nodes_request - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.get\_browse\_nodes\_resource module ------------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.get_browse_nodes_resource - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.get\_browse\_nodes\_response module ------------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.get_browse_nodes_response - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.get\_items\_request module ---------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.get_items_request - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.get\_items\_resource module ----------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.get_items_resource - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.get\_items\_response module ----------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.get_items_response - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.get\_variations\_request module --------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.get_variations_request - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.get\_variations\_resource module ---------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.get_variations_resource - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.get\_variations\_response module ---------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.get_variations_response - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.image\_size module -------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.image_size - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.image\_type module -------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.image_type - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.images module --------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.images - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.item module ------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.item - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.item\_id\_type module ----------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.item_id_type - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.item\_info module ------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.item_info - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.items\_result module ---------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.items_result - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.language\_type module ----------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.language_type - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.languages module ------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.languages - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.manufacture\_info module -------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.manufacture_info - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.max\_price module ------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.max_price - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.merchant module ----------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.merchant - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.min\_price module ------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.min_price - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.min\_reviews\_rating module ----------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.min_reviews_rating - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.min\_saving\_percent module ----------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.min_saving_percent - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.multi\_valued\_attribute module --------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.multi_valued_attribute - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_availability module ---------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.offer_availability - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_condition module ------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.offer_condition - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_condition\_note module ------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.offer_condition_note - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_count module --------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.offer_count - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_delivery\_info module ------------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.offer_delivery_info - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_listing module ----------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.offer_listing - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_loyalty\_points module ------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.offer_loyalty_points - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_merchant\_info module ------------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.offer_merchant_info - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_price module --------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.offer_price - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_program\_eligibility module ------------------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.offer_program_eligibility - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_promotion module ------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.offer_promotion - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_savings module ----------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.offer_savings - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_shipping\_charge module -------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.offer_shipping_charge - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_sub\_condition module ------------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.offer_sub_condition - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offer\_summary module ----------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.offer_summary - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.offers module --------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.offers - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.partner\_type module ---------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.partner_type - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.price module -------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.price - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.product\_advertising\_api\_client\_exception module ----------------------------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.product_advertising_api_client_exception - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.product\_advertising\_api\_service\_exception module ------------------------------------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.product_advertising_api_service_exception - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.product\_info module ---------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.product_info - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.properties module ------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.properties - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.rating module --------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.rating - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.refinement module ------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.refinement - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.refinement\_bin module ------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.refinement_bin - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.rental\_offer\_listing module ------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.rental_offer_listing - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.rental\_offers module ----------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.rental_offers - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.search\_items\_request module ------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.search_items_request - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.search\_items\_resource module -------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.search_items_resource - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.search\_items\_response module -------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.search_items_response - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.search\_refinements module ---------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.search_refinements - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.search\_result module ----------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.search_result - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.single\_boolean\_valued\_attribute module ------------------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.single_boolean_valued_attribute - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.single\_integer\_valued\_attribute module ------------------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.single_integer_valued_attribute - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.single\_string\_valued\_attribute module ------------------------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.single_string_valued_attribute - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.sort\_by module ----------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.sort_by - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.technical\_info module ------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.technical_info - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.trade\_in\_info module ------------------------------------------------ - -.. automodule:: amazon_paapi.sdk.models.trade_in_info - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.trade\_in\_price module ------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.trade_in_price - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.unit\_based\_attribute module ------------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.unit_based_attribute - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.variation\_attribute module ----------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.variation_attribute - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.variation\_dimension module ----------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.variation_dimension - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.variation\_summary module --------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.variation_summary - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.variations\_result module --------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.variations_result - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.models.website\_sales\_rank module ----------------------------------------------------- - -.. automodule:: amazon_paapi.sdk.models.website_sales_rank - :members: - :undoc-members: - :show-inheritance: - -Module contents ---------------- - -.. automodule:: amazon_paapi.sdk.models - :members: - :undoc-members: - :show-inheritance: diff --git a/docs/amazon_paapi.sdk.rst b/docs/amazon_paapi.sdk.rst deleted file mode 100644 index 9e2e401..0000000 --- a/docs/amazon_paapi.sdk.rst +++ /dev/null @@ -1,47 +0,0 @@ -amazon\_paapi.sdk package -========================= - -Subpackages ------------ - -.. toctree:: - :maxdepth: 4 - - amazon_paapi.sdk.api - amazon_paapi.sdk.auth - amazon_paapi.sdk.models - -Submodules ----------- - -amazon\_paapi.sdk.api\_client module ------------------------------------- - -.. automodule:: amazon_paapi.sdk.api_client - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.configuration module --------------------------------------- - -.. automodule:: amazon_paapi.sdk.configuration - :members: - :undoc-members: - :show-inheritance: - -amazon\_paapi.sdk.rest module ------------------------------ - -.. automodule:: amazon_paapi.sdk.rest - :members: - :undoc-members: - :show-inheritance: - -Module contents ---------------- - -.. automodule:: amazon_paapi.sdk - :members: - :undoc-members: - :show-inheritance: diff --git a/docs/amazon_paapi.tools.rst b/docs/amazon_paapi.tools.rst index ec825a5..ebd8be4 100644 --- a/docs/amazon_paapi.tools.rst +++ b/docs/amazon_paapi.tools.rst @@ -1,21 +1,7 @@ amazon\_paapi.tools package =========================== -Submodules ----------- - -amazon\_paapi.tools.asin module -------------------------------- - .. automodule:: amazon_paapi.tools.asin :members: :undoc-members: :show-inheritance: - -Module contents ---------------- - -.. automodule:: amazon_paapi.tools - :members: - :undoc-members: - :show-inheritance: diff --git a/docs/index.rst b/docs/index.rst index dc95697..81a9372 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -3,19 +3,17 @@ You can adapt this file completely to your liking, but it should at least contain the root `toctree` directive. -Welcome to python-amazon-paapi's documentation! +Welcome to Python Amazon PAAPI's documentation! =============================================== -.. toctree:: - :maxdepth: 2 - :caption: Contents: - - modules +Reference +========= +Below you can find a reference of all the classes and methods in python-telegram-bot. +Apart from the `telegram.ext` package the objects should reflect the types defined in the `official Telegram Bot API documentation `_. -Indices and tables -================== +.. toctree:: -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` + amazon_paapi + amazon_paapi.errors + amazon_paapi.tools From 9b61ea942e786db44c32cbb53719eafb63ea219b Mon Sep 17 00:00:00 2001 From: Sergio Abad Date: Mon, 22 Nov 2021 23:55:18 +0100 Subject: [PATCH 5/7] Updated index --- docs/index.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/index.rst b/docs/index.rst index 81a9372..d6ff840 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -9,8 +9,8 @@ Welcome to Python Amazon PAAPI's documentation! Reference ========= -Below you can find a reference of all the classes and methods in python-telegram-bot. -Apart from the `telegram.ext` package the objects should reflect the types defined in the `official Telegram Bot API documentation `_. +Below you can access the documentation for the main class, as well as errors and tools. To check some +usage examples please go to the `readme `_ on GitHub. .. toctree:: From 97ec4b76b4c9b66e09b434ba0d1fba7375c79d6e Mon Sep 17 00:00:00 2001 From: Sergio Abad Date: Mon, 22 Nov 2021 23:58:16 +0100 Subject: [PATCH 6/7] Moved images to static and deleted modules --- docs/{ => _static}/pa-paapi-icon.ico | Bin docs/{ => _static}/pa-paapi-logo.png | Bin docs/conf.py | 4 ++-- docs/modules.rst | 7 ------- 4 files changed, 2 insertions(+), 9 deletions(-) rename docs/{ => _static}/pa-paapi-icon.ico (100%) rename docs/{ => _static}/pa-paapi-logo.png (100%) delete mode 100644 docs/modules.rst diff --git a/docs/pa-paapi-icon.ico b/docs/_static/pa-paapi-icon.ico similarity index 100% rename from docs/pa-paapi-icon.ico rename to docs/_static/pa-paapi-icon.ico diff --git a/docs/pa-paapi-logo.png b/docs/_static/pa-paapi-logo.png similarity index 100% rename from docs/pa-paapi-logo.png rename to docs/_static/pa-paapi-logo.png diff --git a/docs/conf.py b/docs/conf.py index 0f46e07..9c4d64a 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -72,12 +72,12 @@ # The name of an image file (relative to this directory) to place at the top # of the sidebar. -html_logo = 'pa-paapi-logo.png' +html_logo = '_static/pa-paapi-logo.png' # The name of an image file (within the static path) to use as favicon of the # docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32 # pixels large. -html_favicon = 'pa-paapi-icon.ico' +html_favicon = '_static/pa-paapi-icon.ico' # -- script stuff -------------------------------------------------------- diff --git a/docs/modules.rst b/docs/modules.rst deleted file mode 100644 index 40b7a42..0000000 --- a/docs/modules.rst +++ /dev/null @@ -1,7 +0,0 @@ -amazon_paapi -============ - -.. toctree:: - :maxdepth: 4 - - amazon_paapi From 71f4c905e60fb1da3976722aa7320a540c7167fe Mon Sep 17 00:00:00 2001 From: Sergio Abad Date: Tue, 23 Nov 2021 00:00:00 +0100 Subject: [PATCH 7/7] Added old amazon folder again --- amazon/README.md | 123 +++ amazon/__init__.py | 4 + amazon/constant.py | 241 ++++++ amazon/exception.py | 11 + amazon/paapi.py | 457 ++++++++++ amazon/paapi5_python_sdk/COPYING.txt | 202 +++++ amazon/paapi5_python_sdk/LICENSE.txt | 202 +++++ amazon/paapi5_python_sdk/NOTICE.txt | 2 + amazon/paapi5_python_sdk/__init__.py | 123 +++ amazon/paapi5_python_sdk/api/__init__.py | 29 + amazon/paapi5_python_sdk/api/default_api.py | 428 +++++++++ amazon/paapi5_python_sdk/api_client.py | 685 +++++++++++++++ amazon/paapi5_python_sdk/auth/__init__.py | 29 + amazon/paapi5_python_sdk/auth/sig_v4.py | 149 ++++ amazon/paapi5_python_sdk/availability.py | 104 +++ amazon/paapi5_python_sdk/browse_node.py | 285 ++++++ .../paapi5_python_sdk/browse_node_ancestor.py | 204 +++++ amazon/paapi5_python_sdk/browse_node_child.py | 178 ++++ .../paapi5_python_sdk/browse_node_children.py | 100 +++ amazon/paapi5_python_sdk/browse_node_info.py | 155 ++++ .../paapi5_python_sdk/browse_nodes_result.py | 128 +++ amazon/paapi5_python_sdk/by_line_info.py | 181 ++++ amazon/paapi5_python_sdk/classifications.py | 154 ++++ amazon/paapi5_python_sdk/condition.py | 107 +++ amazon/paapi5_python_sdk/configuration.py | 230 +++++ amazon/paapi5_python_sdk/content_info.py | 208 +++++ amazon/paapi5_python_sdk/content_rating.py | 128 +++ amazon/paapi5_python_sdk/contributor.py | 178 ++++ amazon/paapi5_python_sdk/delivery_flag.py | 106 +++ .../dimension_based_attribute.py | 206 +++++ amazon/paapi5_python_sdk/duration_price.py | 155 ++++ amazon/paapi5_python_sdk/error_data.py | 152 ++++ amazon/paapi5_python_sdk/external_ids.py | 180 ++++ .../get_browse_nodes_request.py | 262 ++++++ .../get_browse_nodes_resource.py | 104 +++ .../get_browse_nodes_response.py | 155 ++++ amazon/paapi5_python_sdk/get_items_request.py | 423 +++++++++ .../paapi5_python_sdk/get_items_resource.py | 157 ++++ .../paapi5_python_sdk/get_items_response.py | 155 ++++ .../get_variations_request.py | 448 ++++++++++ .../get_variations_resource.py | 160 ++++ .../get_variations_response.py | 155 ++++ amazon/paapi5_python_sdk/image_size.py | 178 ++++ amazon/paapi5_python_sdk/image_type.py | 180 ++++ amazon/paapi5_python_sdk/images.py | 154 ++++ amazon/paapi5_python_sdk/item.py | 367 ++++++++ amazon/paapi5_python_sdk/item_id_type.py | 103 +++ amazon/paapi5_python_sdk/item_info.py | 398 +++++++++ amazon/paapi5_python_sdk/items_result.py | 128 +++ amazon/paapi5_python_sdk/language_type.py | 152 ++++ amazon/paapi5_python_sdk/languages.py | 180 ++++ amazon/paapi5_python_sdk/manufacture_info.py | 180 ++++ amazon/paapi5_python_sdk/max_price.py | 98 +++ amazon/paapi5_python_sdk/merchant.py | 104 +++ amazon/paapi5_python_sdk/min_price.py | 98 +++ .../paapi5_python_sdk/min_reviews_rating.py | 98 +++ .../paapi5_python_sdk/min_saving_percent.py | 98 +++ .../multi_valued_attribute.py | 178 ++++ .../paapi5_python_sdk/offer_availability.py | 203 +++++ amazon/paapi5_python_sdk/offer_condition.py | 232 +++++ amazon/paapi5_python_sdk/offer_count.py | 98 +++ .../paapi5_python_sdk/offer_delivery_info.py | 206 +++++ amazon/paapi5_python_sdk/offer_listing.py | 421 +++++++++ .../paapi5_python_sdk/offer_loyalty_points.py | 126 +++ .../paapi5_python_sdk/offer_merchant_info.py | 178 ++++ amazon/paapi5_python_sdk/offer_price.py | 232 +++++ .../offer_program_eligibility.py | 152 ++++ amazon/paapi5_python_sdk/offer_promotion.py | 255 ++++++ amazon/paapi5_python_sdk/offer_savings.py | 230 +++++ .../offer_shipping_charge.py | 229 +++++ .../paapi5_python_sdk/offer_sub_condition.py | 204 +++++ amazon/paapi5_python_sdk/offer_summary.py | 207 +++++ amazon/paapi5_python_sdk/offers.py | 155 ++++ amazon/paapi5_python_sdk/partner_type.py | 103 +++ amazon/paapi5_python_sdk/price.py | 154 ++++ ...roduct_advertising_api_client_exception.py | 128 +++ ...oduct_advertising_api_service_exception.py | 126 +++ amazon/paapi5_python_sdk/product_info.py | 261 ++++++ amazon/paapi5_python_sdk/properties.py | 83 ++ amazon/paapi5_python_sdk/refinement.py | 180 ++++ amazon/paapi5_python_sdk/refinement_bin.py | 152 ++++ .../paapi5_python_sdk/rental_offer_listing.py | 262 ++++++ amazon/paapi5_python_sdk/rental_offers.py | 128 +++ amazon/paapi5_python_sdk/rest.py | 333 +++++++ .../paapi5_python_sdk/search_items_request.py | 818 ++++++++++++++++++ .../search_items_resource.py | 158 ++++ .../search_items_response.py | 155 ++++ .../paapi5_python_sdk/search_refinements.py | 180 ++++ amazon/paapi5_python_sdk/search_result.py | 207 +++++ .../single_boolean_valued_attribute.py | 178 ++++ .../single_integer_valued_attribute.py | 178 ++++ .../single_string_valued_attribute.py | 178 ++++ amazon/paapi5_python_sdk/sort_by.py | 108 +++ amazon/paapi5_python_sdk/technical_info.py | 128 +++ amazon/paapi5_python_sdk/trade_in_info.py | 154 ++++ amazon/paapi5_python_sdk/trade_in_price.py | 178 ++++ .../paapi5_python_sdk/unit_based_attribute.py | 204 +++++ .../paapi5_python_sdk/variation_attribute.py | 152 ++++ .../paapi5_python_sdk/variation_dimension.py | 204 +++++ amazon/paapi5_python_sdk/variation_summary.py | 207 +++++ amazon/paapi5_python_sdk/variations_result.py | 155 ++++ .../paapi5_python_sdk/website_sales_rank.py | 204 +++++ amazon/parse.py | 550 ++++++++++++ amazon/serializer/dango_rest_framework.py | 156 ++++ amazon/tools.py | 26 + 105 files changed, 20053 insertions(+) create mode 100644 amazon/README.md create mode 100644 amazon/__init__.py create mode 100644 amazon/constant.py create mode 100644 amazon/exception.py create mode 100644 amazon/paapi.py create mode 100644 amazon/paapi5_python_sdk/COPYING.txt create mode 100644 amazon/paapi5_python_sdk/LICENSE.txt create mode 100644 amazon/paapi5_python_sdk/NOTICE.txt create mode 100644 amazon/paapi5_python_sdk/__init__.py create mode 100644 amazon/paapi5_python_sdk/api/__init__.py create mode 100644 amazon/paapi5_python_sdk/api/default_api.py create mode 100644 amazon/paapi5_python_sdk/api_client.py create mode 100644 amazon/paapi5_python_sdk/auth/__init__.py create mode 100644 amazon/paapi5_python_sdk/auth/sig_v4.py create mode 100644 amazon/paapi5_python_sdk/availability.py create mode 100644 amazon/paapi5_python_sdk/browse_node.py create mode 100644 amazon/paapi5_python_sdk/browse_node_ancestor.py create mode 100644 amazon/paapi5_python_sdk/browse_node_child.py create mode 100644 amazon/paapi5_python_sdk/browse_node_children.py create mode 100644 amazon/paapi5_python_sdk/browse_node_info.py create mode 100644 amazon/paapi5_python_sdk/browse_nodes_result.py create mode 100644 amazon/paapi5_python_sdk/by_line_info.py create mode 100644 amazon/paapi5_python_sdk/classifications.py create mode 100644 amazon/paapi5_python_sdk/condition.py create mode 100644 amazon/paapi5_python_sdk/configuration.py create mode 100644 amazon/paapi5_python_sdk/content_info.py create mode 100644 amazon/paapi5_python_sdk/content_rating.py create mode 100644 amazon/paapi5_python_sdk/contributor.py create mode 100644 amazon/paapi5_python_sdk/delivery_flag.py create mode 100644 amazon/paapi5_python_sdk/dimension_based_attribute.py create mode 100644 amazon/paapi5_python_sdk/duration_price.py create mode 100644 amazon/paapi5_python_sdk/error_data.py create mode 100644 amazon/paapi5_python_sdk/external_ids.py create mode 100644 amazon/paapi5_python_sdk/get_browse_nodes_request.py create mode 100644 amazon/paapi5_python_sdk/get_browse_nodes_resource.py create mode 100644 amazon/paapi5_python_sdk/get_browse_nodes_response.py create mode 100644 amazon/paapi5_python_sdk/get_items_request.py create mode 100644 amazon/paapi5_python_sdk/get_items_resource.py create mode 100644 amazon/paapi5_python_sdk/get_items_response.py create mode 100644 amazon/paapi5_python_sdk/get_variations_request.py create mode 100644 amazon/paapi5_python_sdk/get_variations_resource.py create mode 100644 amazon/paapi5_python_sdk/get_variations_response.py create mode 100644 amazon/paapi5_python_sdk/image_size.py create mode 100644 amazon/paapi5_python_sdk/image_type.py create mode 100644 amazon/paapi5_python_sdk/images.py create mode 100644 amazon/paapi5_python_sdk/item.py create mode 100644 amazon/paapi5_python_sdk/item_id_type.py create mode 100644 amazon/paapi5_python_sdk/item_info.py create mode 100644 amazon/paapi5_python_sdk/items_result.py create mode 100644 amazon/paapi5_python_sdk/language_type.py create mode 100644 amazon/paapi5_python_sdk/languages.py create mode 100644 amazon/paapi5_python_sdk/manufacture_info.py create mode 100644 amazon/paapi5_python_sdk/max_price.py create mode 100644 amazon/paapi5_python_sdk/merchant.py create mode 100644 amazon/paapi5_python_sdk/min_price.py create mode 100644 amazon/paapi5_python_sdk/min_reviews_rating.py create mode 100644 amazon/paapi5_python_sdk/min_saving_percent.py create mode 100644 amazon/paapi5_python_sdk/multi_valued_attribute.py create mode 100644 amazon/paapi5_python_sdk/offer_availability.py create mode 100644 amazon/paapi5_python_sdk/offer_condition.py create mode 100644 amazon/paapi5_python_sdk/offer_count.py create mode 100644 amazon/paapi5_python_sdk/offer_delivery_info.py create mode 100644 amazon/paapi5_python_sdk/offer_listing.py create mode 100644 amazon/paapi5_python_sdk/offer_loyalty_points.py create mode 100644 amazon/paapi5_python_sdk/offer_merchant_info.py create mode 100644 amazon/paapi5_python_sdk/offer_price.py create mode 100644 amazon/paapi5_python_sdk/offer_program_eligibility.py create mode 100644 amazon/paapi5_python_sdk/offer_promotion.py create mode 100644 amazon/paapi5_python_sdk/offer_savings.py create mode 100644 amazon/paapi5_python_sdk/offer_shipping_charge.py create mode 100644 amazon/paapi5_python_sdk/offer_sub_condition.py create mode 100644 amazon/paapi5_python_sdk/offer_summary.py create mode 100644 amazon/paapi5_python_sdk/offers.py create mode 100644 amazon/paapi5_python_sdk/partner_type.py create mode 100644 amazon/paapi5_python_sdk/price.py create mode 100644 amazon/paapi5_python_sdk/product_advertising_api_client_exception.py create mode 100644 amazon/paapi5_python_sdk/product_advertising_api_service_exception.py create mode 100644 amazon/paapi5_python_sdk/product_info.py create mode 100644 amazon/paapi5_python_sdk/properties.py create mode 100644 amazon/paapi5_python_sdk/refinement.py create mode 100644 amazon/paapi5_python_sdk/refinement_bin.py create mode 100644 amazon/paapi5_python_sdk/rental_offer_listing.py create mode 100644 amazon/paapi5_python_sdk/rental_offers.py create mode 100644 amazon/paapi5_python_sdk/rest.py create mode 100644 amazon/paapi5_python_sdk/search_items_request.py create mode 100644 amazon/paapi5_python_sdk/search_items_resource.py create mode 100644 amazon/paapi5_python_sdk/search_items_response.py create mode 100644 amazon/paapi5_python_sdk/search_refinements.py create mode 100644 amazon/paapi5_python_sdk/search_result.py create mode 100644 amazon/paapi5_python_sdk/single_boolean_valued_attribute.py create mode 100644 amazon/paapi5_python_sdk/single_integer_valued_attribute.py create mode 100644 amazon/paapi5_python_sdk/single_string_valued_attribute.py create mode 100644 amazon/paapi5_python_sdk/sort_by.py create mode 100644 amazon/paapi5_python_sdk/technical_info.py create mode 100644 amazon/paapi5_python_sdk/trade_in_info.py create mode 100644 amazon/paapi5_python_sdk/trade_in_price.py create mode 100644 amazon/paapi5_python_sdk/unit_based_attribute.py create mode 100644 amazon/paapi5_python_sdk/variation_attribute.py create mode 100644 amazon/paapi5_python_sdk/variation_dimension.py create mode 100644 amazon/paapi5_python_sdk/variation_summary.py create mode 100644 amazon/paapi5_python_sdk/variations_result.py create mode 100644 amazon/paapi5_python_sdk/website_sales_rank.py create mode 100644 amazon/parse.py create mode 100644 amazon/serializer/dango_rest_framework.py create mode 100644 amazon/tools.py diff --git a/amazon/README.md b/amazon/README.md new file mode 100644 index 0000000..755db35 --- /dev/null +++ b/amazon/README.md @@ -0,0 +1,123 @@ +# Amazon Product Advertising API 5.0 wrapper for Python v3.3.4 + +> :warning: **This version is deprecated and it will be removed in the future. Please use [version 4.0.0 or higher](https://github.com/sergioteula/python-amazon-paapi).** + +A simple Python wrapper for the [last version of the Amazon Product Advertising API](https://webservices.amazon.com/paapi5/documentation/quick-start/using-sdk.html). This module allows to get product information from Amazon using the official API in an easier way. + +[![PyPI](https://img.shields.io/pypi/v/python-amazon-paapi?color=%231182C2&label=PyPI)](https://pypi.org/project/python-amazon-paapi/) +[![Python](https://img.shields.io/badge/Python-2.x%20%7C%203.x-%23FFD140)](https://www.python.org/) +[![License](https://img.shields.io/badge/License-MIT-%23e83633)](https://github.com/sergioteula/python-amazon-paapi/blob/master/LICENSE) +[![Support](https://img.shields.io/badge/Support-Good-brightgreen)](https://github.com/sergioteula/python-amazon-paapi/issues) +[![Amazon API](https://img.shields.io/badge/Amazon%20API-5.0-%23FD9B15)](https://webservices.amazon.com/paapi5/documentation/) + +## Features + +- Object oriented interface for simple usage. +- Get information about a product through its ASIN or URL. +- Get item variations or search for products on Amazon. +- Get browse nodes information. +- Get multiple results at once without the 10 items limitation from Amazon. +- Configurable throttling to avoid requests exceptions. +- Built-in serializer for Django REST framework. +- Support for [all available countries](https://github.com/sergioteula/python-amazon-paapi/blob/master/amazon/paapi.py#L31). +- Reorganized product information [structure](https://github.com/sergioteula/python-amazon-paapi/blob/master/PRODUCT.md) for simple use. +- Ask for new features through the [issues](https://github.com/sergioteula/python-amazon-paapi/issues) section. +- Join our [Telegram group](https://t.me/PythonAmazonPAAPI) for support or development. + +## Installation + +You can install this module version with: + + pip install python-amazon-paapi==3.3.4 + +If you get `ModuleNotFoundError`, try installing this: + + pip install amightygirl.paapi5-python-sdk + +## Usage guide + +**Basic usage:** + +```python +from amazon.paapi import AmazonApi +amazon = AmazonApi(KEY, SECRET, TAG, COUNTRY) +product = amazon.get_product('B01N5IB20Q') +print(product.title) +``` + +**Get multiple product information:** + +```python +product = amazon.get_products('B01N5IB20Q,B01F9G43WU') +print(product[0].images.large) +print(product[1].prices.price.value) +``` + +**Use URL insted of ASIN:** + +```python +product = amazon.get_product('https://www.amazon.com/dp/B01N5IB20Q') +``` + +**Get product variations:** + +```python +product = amazon.get_variations('B01N5IB20Q') +print(product[0].title) +``` + +**Search product:** + +```python +product = amazon.search_products(item_count=25, keywords='speaker') +print(product[14].url) +``` + +**Get browse node information:** + +```python +node = amazon.get_browsenodes(browse_nodes=browsenodes_list) +``` + +**Get the ASIN from a URL:** + +```python +from amazon.tools import get_asin +asin = get_asin('https://www.amazon.com/dp/B01N5IB20Q') +``` + +**Throttling:** + +Throttling value must be `greater than 0` or `False` to disable it. This value throttles requests to a maximum of one request every `1 / value` seconds. Note that this value is a per-worker throttling, so applications with multiple workers may make more requests per second. Throttling value is [set by default](https://github.com/sergioteula/python-amazon-paapi/blob/master/amazon/paapi.py#L36) to `0.8` or one request every 1.25 seconds. + +```python +amazon = AmazonApi(KEY, SECRET, TAG, COUNTRY, throttling=0.5) # Max one request every two seconds +amazon = AmazonApi(KEY, SECRET, TAG, COUNTRY, throttling=False) # Unlimited requests per second +``` + +**Serializer for Django:** + +We provide a serializer for Django REST framework, which speeds up your API +implementation. + +```python +from amazon.serializers import AmazonProductSerializer +from rest_framework import serializers + +serialized_product = AmazonProductSerializer(product) +serialized_product.data +``` + +If you want to serialize a list of products: + +```python +serialized_products = AmazonProductSerializer(products, many=True) +serialized_products.data +``` + +For more information on how to work with serializers, check the documentation for +[Django REST framework](https://www.django-rest-framework.org/api-guide/serializers/). + +## License + +Copyright © 2020 Sergio Abad. See [license](https://github.com/sergioteula/python-amazon-paapi/blob/master/LICENSE) for details. diff --git a/amazon/__init__.py b/amazon/__init__.py new file mode 100644 index 0000000..17c61a2 --- /dev/null +++ b/amazon/__init__.py @@ -0,0 +1,4 @@ +"""Amazon Product Advertising API wrapper for Python""" + +__version__ = '3.3.3' +__author__ = 'Sergio Abad' diff --git a/amazon/constant.py b/amazon/constant.py new file mode 100644 index 0000000..c1fae32 --- /dev/null +++ b/amazon/constant.py @@ -0,0 +1,241 @@ +"""Module containing all the constants.""" + +from .paapi5_python_sdk.get_items_resource import GetItemsResource +from .paapi5_python_sdk.search_items_resource import SearchItemsResource +from .paapi5_python_sdk.get_variations_resource import GetVariationsResource +from .paapi5_python_sdk.get_browse_nodes_resource import GetBrowseNodesResource +from .paapi5_python_sdk.condition import Condition + +"""Available regions for the Amazon API.""" +REGIONS = { + 'AU': 'us-west-2', + 'BR': 'us-east-1', + 'CA': 'us-east-1', + 'FR': 'eu-west-1', + 'DE': 'eu-west-1', + 'NL': 'eu-west-1', + 'IN': 'eu-west-1', + 'IT': 'eu-west-1', + 'JP': 'us-west-2', + 'MX': 'us-east-1', + 'ES': 'eu-west-1', + 'TR': 'eu-west-1', + 'AE': 'eu-west-1', + 'UK': 'eu-west-1', + 'US': 'us-east-1', + 'SE': 'eu-west-1' +} + +"""Domains for each region on the Amazon API.""" +DOMAINS = { + 'AU': 'com.au', + 'BR': 'com.br', + 'CA': 'ca', + 'FR': 'fr', + 'DE': 'de', + 'NL': 'nl', + 'IN': 'in', + 'IT': 'it', + 'JP': 'co.jp', + 'MX': 'com.mx', + 'ES': 'es', + 'TR': 'com.tr', + 'AE': 'ae', + 'UK': 'co.uk', + 'US': 'com', + 'SE': 'se' +} + +"""Condition values.""" +CONDITION = { + 'Any': Condition.ANY, + 'Collectible': Condition.COLLECTIBLE, + 'New': Condition.NEW, + 'Refurbished': Condition.REFURBISHED, + 'Used': Condition.USED +} + +"""Product resources to get from Amazon API.""" +PRODUCT_RESOURCES = [ + GetItemsResource.BROWSENODEINFO_BROWSENODES, + GetItemsResource.BROWSENODEINFO_BROWSENODES_ANCESTOR, + GetItemsResource.BROWSENODEINFO_BROWSENODES_SALESRANK, + GetItemsResource.BROWSENODEINFO_WEBSITESALESRANK, + GetItemsResource.IMAGES_PRIMARY_SMALL, + GetItemsResource.IMAGES_PRIMARY_MEDIUM, + GetItemsResource.IMAGES_PRIMARY_LARGE, + GetItemsResource.IMAGES_VARIANTS_SMALL, + GetItemsResource.IMAGES_VARIANTS_MEDIUM, + GetItemsResource.IMAGES_VARIANTS_LARGE, + GetItemsResource.ITEMINFO_BYLINEINFO, + GetItemsResource.ITEMINFO_CONTENTINFO, + GetItemsResource.ITEMINFO_CONTENTRATING, + GetItemsResource.ITEMINFO_CLASSIFICATIONS, + GetItemsResource.ITEMINFO_EXTERNALIDS, + GetItemsResource.ITEMINFO_FEATURES, + GetItemsResource.ITEMINFO_MANUFACTUREINFO, + GetItemsResource.ITEMINFO_PRODUCTINFO, + GetItemsResource.ITEMINFO_TECHNICALINFO, + GetItemsResource.ITEMINFO_TITLE, + GetItemsResource.ITEMINFO_TRADEININFO, + GetItemsResource.OFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY, + GetItemsResource.OFFERS_LISTINGS_AVAILABILITY_MESSAGE, + GetItemsResource.OFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY, + GetItemsResource.OFFERS_LISTINGS_AVAILABILITY_TYPE, + GetItemsResource.OFFERS_LISTINGS_CONDITION, + GetItemsResource.OFFERS_LISTINGS_CONDITION_SUBCONDITION, + GetItemsResource.OFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED, + GetItemsResource.OFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE, + GetItemsResource.OFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE, + GetItemsResource.OFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES, + GetItemsResource.OFFERS_LISTINGS_ISBUYBOXWINNER, + GetItemsResource.OFFERS_LISTINGS_LOYALTYPOINTS_POINTS, + GetItemsResource.OFFERS_LISTINGS_MERCHANTINFO, + GetItemsResource.OFFERS_LISTINGS_PRICE, + GetItemsResource.OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEEXCLUSIVE, + GetItemsResource.OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEPANTRY, + GetItemsResource.OFFERS_LISTINGS_PROMOTIONS, + GetItemsResource.OFFERS_LISTINGS_SAVINGBASIS, + GetItemsResource.OFFERS_SUMMARIES_HIGHESTPRICE, + GetItemsResource.OFFERS_SUMMARIES_LOWESTPRICE, + GetItemsResource.OFFERS_SUMMARIES_OFFERCOUNT, + GetItemsResource.PARENTASIN, + GetItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY, + GetItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MESSAGE, + GetItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY, + GetItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_TYPE, + GetItemsResource.RENTALOFFERS_LISTINGS_BASEPRICE, + GetItemsResource.RENTALOFFERS_LISTINGS_CONDITION, + GetItemsResource.RENTALOFFERS_LISTINGS_CONDITION_SUBCONDITION, + GetItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED, + GetItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE, + GetItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE, + GetItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES, + GetItemsResource.RENTALOFFERS_LISTINGS_MERCHANTINFO] + +"""Search resources to get from Amazon API.""" +SEARCH_RESOURCES = [ + SearchItemsResource.BROWSENODEINFO_BROWSENODES, + SearchItemsResource.BROWSENODEINFO_BROWSENODES_ANCESTOR, + SearchItemsResource.BROWSENODEINFO_BROWSENODES_SALESRANK, + SearchItemsResource.BROWSENODEINFO_WEBSITESALESRANK, + SearchItemsResource.IMAGES_PRIMARY_SMALL, + SearchItemsResource.IMAGES_PRIMARY_MEDIUM, + SearchItemsResource.IMAGES_PRIMARY_LARGE, + SearchItemsResource.IMAGES_VARIANTS_SMALL, + SearchItemsResource.IMAGES_VARIANTS_MEDIUM, + SearchItemsResource.IMAGES_VARIANTS_LARGE, + SearchItemsResource.ITEMINFO_BYLINEINFO, + SearchItemsResource.ITEMINFO_CONTENTINFO, + SearchItemsResource.ITEMINFO_CONTENTRATING, + SearchItemsResource.ITEMINFO_CLASSIFICATIONS, + SearchItemsResource.ITEMINFO_EXTERNALIDS, + SearchItemsResource.ITEMINFO_FEATURES, + SearchItemsResource.ITEMINFO_MANUFACTUREINFO, + SearchItemsResource.ITEMINFO_PRODUCTINFO, + SearchItemsResource.ITEMINFO_TECHNICALINFO, + SearchItemsResource.ITEMINFO_TITLE, + SearchItemsResource.ITEMINFO_TRADEININFO, + SearchItemsResource.OFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY, + SearchItemsResource.OFFERS_LISTINGS_AVAILABILITY_MESSAGE, + SearchItemsResource.OFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY, + SearchItemsResource.OFFERS_LISTINGS_AVAILABILITY_TYPE, + SearchItemsResource.OFFERS_LISTINGS_CONDITION, + SearchItemsResource.OFFERS_LISTINGS_CONDITION_SUBCONDITION, + SearchItemsResource.OFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED, + SearchItemsResource.OFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE, + SearchItemsResource.OFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE, + SearchItemsResource.OFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES, + SearchItemsResource.OFFERS_LISTINGS_ISBUYBOXWINNER, + SearchItemsResource.OFFERS_LISTINGS_LOYALTYPOINTS_POINTS, + SearchItemsResource.OFFERS_LISTINGS_MERCHANTINFO, + SearchItemsResource.OFFERS_LISTINGS_PRICE, + SearchItemsResource.OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEEXCLUSIVE, + SearchItemsResource.OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEPANTRY, + SearchItemsResource.OFFERS_LISTINGS_PROMOTIONS, + SearchItemsResource.OFFERS_LISTINGS_SAVINGBASIS, + SearchItemsResource.OFFERS_SUMMARIES_HIGHESTPRICE, + SearchItemsResource.OFFERS_SUMMARIES_LOWESTPRICE, + SearchItemsResource.OFFERS_SUMMARIES_OFFERCOUNT, + SearchItemsResource.PARENTASIN, + SearchItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY, + SearchItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MESSAGE, + SearchItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY, + SearchItemsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_TYPE, + SearchItemsResource.RENTALOFFERS_LISTINGS_BASEPRICE, + SearchItemsResource.RENTALOFFERS_LISTINGS_CONDITION, + SearchItemsResource.RENTALOFFERS_LISTINGS_CONDITION_SUBCONDITION, + SearchItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED, + SearchItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE, + SearchItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE, + SearchItemsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES, + SearchItemsResource.RENTALOFFERS_LISTINGS_MERCHANTINFO, + SearchItemsResource.SEARCHREFINEMENTS] + +"""Variation resources to get from Amazon API.""" +VARIATION_RESOURCES = [ + GetVariationsResource.BROWSENODEINFO_BROWSENODES, + GetVariationsResource.BROWSENODEINFO_BROWSENODES_ANCESTOR, + GetVariationsResource.BROWSENODEINFO_BROWSENODES_SALESRANK, + GetVariationsResource.BROWSENODEINFO_WEBSITESALESRANK, + GetVariationsResource.IMAGES_PRIMARY_SMALL, + GetVariationsResource.IMAGES_PRIMARY_MEDIUM, + GetVariationsResource.IMAGES_PRIMARY_LARGE, + GetVariationsResource.IMAGES_VARIANTS_SMALL, + GetVariationsResource.IMAGES_VARIANTS_MEDIUM, + GetVariationsResource.IMAGES_VARIANTS_LARGE, + GetVariationsResource.ITEMINFO_BYLINEINFO, + GetVariationsResource.ITEMINFO_CONTENTINFO, + GetVariationsResource.ITEMINFO_CONTENTRATING, + GetVariationsResource.ITEMINFO_CLASSIFICATIONS, + GetVariationsResource.ITEMINFO_EXTERNALIDS, + GetVariationsResource.ITEMINFO_FEATURES, + GetVariationsResource.ITEMINFO_MANUFACTUREINFO, + GetVariationsResource.ITEMINFO_PRODUCTINFO, + GetVariationsResource.ITEMINFO_TECHNICALINFO, + GetVariationsResource.ITEMINFO_TITLE, + GetVariationsResource.ITEMINFO_TRADEININFO, + GetVariationsResource.OFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY, + GetVariationsResource.OFFERS_LISTINGS_AVAILABILITY_MESSAGE, + GetVariationsResource.OFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY, + GetVariationsResource.OFFERS_LISTINGS_AVAILABILITY_TYPE, + GetVariationsResource.OFFERS_LISTINGS_CONDITION, + GetVariationsResource.OFFERS_LISTINGS_CONDITION_SUBCONDITION, + GetVariationsResource.OFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED, + GetVariationsResource.OFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE, + GetVariationsResource.OFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE, + GetVariationsResource.OFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES, + GetVariationsResource.OFFERS_LISTINGS_ISBUYBOXWINNER, + GetVariationsResource.OFFERS_LISTINGS_LOYALTYPOINTS_POINTS, + GetVariationsResource.OFFERS_LISTINGS_MERCHANTINFO, + GetVariationsResource.OFFERS_LISTINGS_PRICE, + GetVariationsResource.OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEEXCLUSIVE, + GetVariationsResource.OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEPANTRY, + GetVariationsResource.OFFERS_LISTINGS_PROMOTIONS, + GetVariationsResource.OFFERS_LISTINGS_SAVINGBASIS, + GetVariationsResource.OFFERS_SUMMARIES_HIGHESTPRICE, + GetVariationsResource.OFFERS_SUMMARIES_LOWESTPRICE, + GetVariationsResource.OFFERS_SUMMARIES_OFFERCOUNT, + GetVariationsResource.PARENTASIN, + GetVariationsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY, + GetVariationsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MESSAGE, + GetVariationsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY, + GetVariationsResource.RENTALOFFERS_LISTINGS_AVAILABILITY_TYPE, + GetVariationsResource.RENTALOFFERS_LISTINGS_BASEPRICE, + GetVariationsResource.RENTALOFFERS_LISTINGS_CONDITION, + GetVariationsResource.RENTALOFFERS_LISTINGS_CONDITION_SUBCONDITION, + GetVariationsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED, + GetVariationsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE, + GetVariationsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE, + GetVariationsResource.RENTALOFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES, + GetVariationsResource.RENTALOFFERS_LISTINGS_MERCHANTINFO, + GetVariationsResource.VARIATIONSUMMARY_PRICE_HIGHESTPRICE, + GetVariationsResource.VARIATIONSUMMARY_PRICE_LOWESTPRICE, + GetVariationsResource.VARIATIONSUMMARY_VARIATIONDIMENSION +] + +"""Browse Node resources to get from Amazon API.""" +BROWSE_RESOURCES = [ + GetBrowseNodesResource.ANCESTOR, + GetBrowseNodesResource.CHILDREN +] diff --git a/amazon/exception.py b/amazon/exception.py new file mode 100644 index 0000000..c9af2df --- /dev/null +++ b/amazon/exception.py @@ -0,0 +1,11 @@ +"""Custom exception class.""" + + +class AmazonException(Exception): + """Custom exception class for Amazon Product Advertising API.""" + def __init__(self, status=None, reason=None): + self.status = status + self.reason = reason + + def __str__(self): + return '%s: %s' % (self.status, self.reason) diff --git a/amazon/paapi.py b/amazon/paapi.py new file mode 100644 index 0000000..d29a79c --- /dev/null +++ b/amazon/paapi.py @@ -0,0 +1,457 @@ +"""Amazon Product Advertising API wrapper for Python + +A simple Python wrapper for the last version of the Amazon Product Advertising API. +This module allows to get product information from Amazon using the official API in +an easier way. +""" + +from .paapi5_python_sdk.api.default_api import DefaultApi +from .paapi5_python_sdk.get_items_request import GetItemsRequest +from .paapi5_python_sdk.search_items_request import SearchItemsRequest +from .paapi5_python_sdk.get_variations_request import GetVariationsRequest +from .paapi5_python_sdk.get_browse_nodes_request import GetBrowseNodesRequest +from .paapi5_python_sdk.partner_type import PartnerType +from .paapi5_python_sdk.rest import ApiException + +from amazon.constant import DOMAINS, REGIONS, CONDITION +from amazon.constant import PRODUCT_RESOURCES, SEARCH_RESOURCES, VARIATION_RESOURCES +from amazon.constant import BROWSE_RESOURCES +from amazon.exception import AmazonException +from amazon.parse import parse_product, AmazonBrowseNode, parse_browsenode +from amazon.tools import get_asin, chunks + +import logging +import time + + +logger = logging.getLogger(__name__) + + +class AmazonAPI: + """Creates an instance containing your API credentials. + + Args: + key (str): Your API key. + secret (str): Your API secret. + tag (str): The tag you want to use for the URL. + country (str): Country code. Use one of the following: + AU, BR, CA, FR, DE, IN, NL, IT, JP, MX, ES, TR, AE, UK, US, SE. + throttling (float, optional): It should be greater than 0 or False to disable throttling. + This value determines wait time between API calls. + """ + def __init__(self, key, secret, tag, country, throttling=0.8): + logger.warning('This version of the module is deprecated and it will be removed in future updates. Please upgrade to version 4.0.0 or higher.') + self.key = key + self.secret = secret + self.tag = tag + try: + if throttling is True: + raise ValueError + elif throttling is False: + self.throttling = False + else: + self.throttling = float(throttling) + if self.throttling <= 0: + raise ValueError + except ValueError: + raise AmazonException('ValueError', 'Throttling should be False or greater than 0') + self.country = country + try: + self.host = 'webservices.amazon.' + DOMAINS[country] + self.region = REGIONS[country] + self.marketplace = 'www.amazon.' + DOMAINS[country] + except KeyError: + raise AmazonException('KeyError', 'Invalid country code') + self.last_query_time = time.time() + self.api = DefaultApi(access_key=self.key, secret_key=self.secret, host=self.host, + region=self.region) + + def _throttle(self): + if self.throttling: + wait_time = 1 / self.throttling - (time.time() - self.last_query_time) + if wait_time > 0: + time.sleep(wait_time) + self.last_query_time = time.time() + + def get_products(self, product_ids, condition='Any', merchant='All', + async_req=False): + """Find product information for multiple products on Amazon. + + Args: + product_ids (str|list): One or more item IDs like ASIN or product URL. + Use a string separated by comma or as a list. + condition (str, optional): Specify the product condition. + Allowed values: Any, Collectible, New, Refurbished, Used. + Defaults to Any. + merchant (str, optional): Filters search results to return items + having at least one offer sold by target merchant. Allowed values: + All, Amazon. Defaults to All. + async_req (bool, optional): Specify if a thread should be created to + run the request. Defaults to False. + + Returns: + list of instances: A list containing 1 instance for each product + or None if no results. + """ + + logger.warning('This version of the module is deprecated and it will be removed in future updates. Please upgrade to version 4.0.0 or higher.') + # Clean up input data and remove 10 items limit from Amazon API + if isinstance(product_ids, str): + product_ids = [x.strip() for x in product_ids.split(',')] + elif not isinstance(product_ids, list): + raise AmazonException('TypeError', 'Arg product_ids should be a list or string') + asin_full_list = list(set([get_asin(x) for x in product_ids])) + asin_full_list = list(chunks(asin_full_list, 10)) + + results = [] + for asin_list in asin_full_list: + try: + request = GetItemsRequest(partner_tag=self.tag, + partner_type=PartnerType.ASSOCIATES, + marketplace=self.marketplace, + merchant=merchant, + condition=CONDITION[condition], + item_ids=asin_list, + resources=PRODUCT_RESOURCES) + except KeyError: + raise AmazonException('KeyError', 'Invalid condition value') + except Exception as e: + raise AmazonException('GetItemsError', e) + + for x in range(3): + try: + # Send the request and create results + self._throttle() + if async_req: + thread = self.api.get_items(request, async_req=True) + response = thread.get() + else: + response = self.api.get_items(request) + break + except ApiException as e: + if x == 2: + raise AmazonException('ApiException', e) + try: + if response.items_result is not None: + if len(response.items_result.items) > 0: + for item in response.items_result.items: + results.append(parse_product(item)) + except Exception as e: + raise AmazonException('ResponseError', e) + + if results: + return results + else: + return None + + def get_product(self, product_id, condition='Any', merchant='All', + async_req=False): + """Find product information for a specific product on Amazon. + + Args: + product_id (str, list): One item ID like ASIN or product URL. + condition (str, optional): Specify the product condition. + Allowed values: Any, Collectible, New, Refurbished, Used. + Defaults to Any. + merchant (str, optional): Filters search results to return items + having at least one offer sold by target merchant. Allowed values: + All, Amazon. Defaults to All. + async_req (bool, optional): Specify if a thread should be created to + run the request. Defaults to False. + + Returns: + instance: An instance containing all the available information + for the product or None if no results. + """ + if isinstance(product_id, list): + product_id = product_id[0] + if isinstance(product_id, str): + product_id = product_id.split(',')[0] + + product = self.get_products(product_id, condition=condition, merchant=merchant, + async_req=async_req) + if product: + return product[0] + else: + return None + + def search_products(self, item_count=10, item_page=1, items_per_page=10, keywords=None, + actor=None, artist=None, author=None, brand=None, title=None, + availability='Available', browse_node=None, condition='Any', delivery=None, + max_price=None, min_price=None, min_rating=None, min_discount=None, + merchant='All', search_index='All', sort_by=None, async_req=False): + """Search products on Amazon using different parameters. At least one of the + following parameters should be used: keywords, actor, artist, author, brand, + title. + + Args: + item_count (int, optional): The total number of products to get. Should be between + 1 and 100. Defaults to 10. + item_page (int, optional): The page where the results start from. Should be between + 1 and 10. Defaults to 1. + items_per_page (int, optional): Products on each page. Should be between + 1 and 10. Defaults to 10. + keywords (str, optional): A word or phrase that describes an item. + actor (str, optional): Actor name associated with the item. + artist (str, optional): Artist name associated with the item. + author (str, optional): Author name associated with the item. + brand (str, optional): Brand name associated with the item. + title (str, optional): Title associated with the item. + availability (str, optional): Filters available items on Amazon. Allowed values: + Available, IncludeOutOfStock. Defaults to Available. + browse_node (str, optional): A unique ID assigned by Amazon that + identifies a product category or subcategory. + condition (str, optional): The condition parameter filters offers by + condition type. Allowed values: Any, Collectible, New, Refurbished, Used. + Defaults to Any. + delivery (list, optional): The delivery flag filters items which + satisfy a certain delivery program promoted by the specific + Amazon Marketplace. Allowed values: AmazonGlobal, FreeShipping, + FulfilledByAmazon, Prime. + max_price (int, optional): Filters search results to items with at + least one offer price below the specified value. + min_price (int, optional): Filters search results to items with at + least one offer price above the specified value. + min_rating (int, optional): Filters search results to items with + customer review ratings above specified value. + min_discount (int, optional): Filters search results to items with + at least one offer having saving percentage above the specified + value. + merchant (str, optional): Filters search results to return items + having at least one offer sold by target merchant. Allowed values: + All, Amazon. Defaults to All. + search_index (str, optional): Indicates the product category to + search. Defaults to All. + sort_by (str, optional): The way in which items in the response + are sorted. Allowed values: AvgCustomerReviews, Featured, + NewestArrivals, Price:HighToLow, Price:LowToHigh, Relevance. + async_req (bool, optional): Specify if a thread should be created to + run the request. Defaults to False. + + Returns: + list of instances: A list containing 1 instance for each product + or None if no results. + """ + + logger.warning('This version of the module is deprecated and it will be removed in future updates. Please upgrade to version 4.0.0 or higher.') + if items_per_page > 10 or items_per_page < 1: + raise AmazonException('ValueError', 'Arg items_per_page should be between 1 and 10') + if item_count > 100 or item_count < 1: + raise AmazonException('ValueError', 'Arg item_count should be between 1 and 100') + if item_page < 1: + raise AmazonException('ValueError', 'Arg item_page should be 1 or higher') + if not keywords and not actor and not artist and not author and not brand and not title and not browse_node and not search_index: + raise AmazonException('ValueError', 'At least one of the following args must be ' + 'provided: keywords, actor, artist, author, brand, ' + 'title, browse_node, search_index') + results = [] + while len(results) < item_count: + try: + request = SearchItemsRequest( + partner_tag=self.tag, + partner_type=PartnerType.ASSOCIATES, + actor=actor, + artist=artist, + author=author, + availability=availability, + brand=brand, + browse_node_id=browse_node, + condition=CONDITION[condition], + delivery_flags=delivery, + item_count=items_per_page, + item_page=item_page, + keywords=keywords, + max_price=max_price, + merchant=merchant, + min_price=min_price, + min_reviews_rating=min_rating, + min_saving_percent=min_discount, + offer_count=1, + resources=SEARCH_RESOURCES, + search_index=search_index, + sort_by=sort_by, + title=title) + except KeyError: + raise AmazonException('KeyError', 'Invalid condition value') + except Exception as e: + raise AmazonException('SearchItemsError', e) + + for x in range(3): + try: + # Send the request and create results + self._throttle() + if async_req: + thread = self.api.search_items(request, async_req=True) + response = thread.get() + else: + response = self.api.search_items(request) + break + except ApiException as e: + if x == 2: + raise AmazonException('ApiException', e) + try: + if response.search_result is not None: + if response.search_result.items is not None: + for item in response.search_result.items: + results.append(parse_product(item)) + if len(results) >= item_count: + break + if len(response.search_result.items) < items_per_page: + break + else: + break + if response.errors is not None: + raise AmazonException(response.errors[0].code, response.errors[0].message) + except Exception as e: + if e.status == "NoResults": + break + raise AmazonException('ResponseError', e) + item_page += 1 + + if results: + return results + else: + return None + + def get_variations(self, asin, item_count=10, item_page=1, items_per_page=10, condition='Any', + merchant='All', async_req=False): + """Returns a set of items that are the same product, but differ according to a + consistent theme, for example size and color. + + Args: + asin (str): One item ID like ASIN or product URL. + item_count (int, optional): The total number of products to get. Should be between + 1 and 100. Defaults to 10. + item_page (int, optional): The page where the results start from. Should be between + 1 and 10. Defaults to 1. + items_per_page (int, optional): Products on each page. Should be between + 1 and 10. Defaults to 10. + condition (str, optional): The condition parameter filters offers by + condition type. Allowed values: Any, Collectible, New, Refurbished, Used. + Defaults to Any. + merchant (str, optional): Filters search results to return items + having at least one offer sold by target merchant. Allowed values: + All, Amazon. Defaults to All. + async_req (bool, optional): Specify if a thread should be created to + run the request. Defaults to False. + + Returns: + list of instances: A list containing 1 instance for each product + or None if no results. + """ + + logger.warning('This version of the module is deprecated and it will be removed in future updates. Please upgrade to version 4.0.0 or higher.') + if items_per_page > 10 or items_per_page < 1: + raise AmazonException('ValueError', 'Arg items_per_page should be between 1 and 10') + if item_count > 100 or item_count < 1: + raise AmazonException('ValueError', 'Arg item_count should be between 1 and 100') + if item_page < 1: + raise AmazonException('ValueError', 'Arg item_page should be 1 or higher') + + results = [] + while len(results) < item_count: + try: + request = GetVariationsRequest( + partner_tag=self.tag, + partner_type=PartnerType.ASSOCIATES, + marketplace=self.marketplace, + asin=get_asin(asin), + condition=CONDITION[condition], + merchant=merchant, + offer_count=1, + variation_count=items_per_page, + variation_page=item_page, + resources=VARIATION_RESOURCES) + except KeyError: + raise AmazonException('KeyError', 'Invalid condition value') + except Exception as e: + raise AmazonException('GetVariationsError', e) + + for x in range(3): + try: + # Send the request and create results + self._throttle() + if async_req: + thread = self.api.get_variations(request, async_req=True) + response = thread.get() + else: + response = self.api.get_variations(request) + break + except ApiException as e: + if x == 2: + raise AmazonException('ApiException', e) + try: + if response.variations_result is not None: + if response.variations_result.items is not None: + for item in response.variations_result.items: + results.append(parse_product(item)) + if len(results) >= item_count: + break + if len(response.variations_result.items) < items_per_page: + break + else: + break + if response.errors is not None: + raise AmazonException(response.errors[0].code, response.errors[0].message) + except Exception as e: + raise AmazonException('ResponseError', e) + item_page += 1 + + if results: + return results + else: + return None + + def get_browsenodes(self, browse_nodes, async_req=False): + """Get browse nodes information from Amazon. + + Args: + browse_nodes (list): List of strings containing the browse node ids. + async_req (bool, optional): Specify if a thread should be created to + run the request. Defaults to False. + + Returns: + dict: A dictionary containing the browse node information. + """ + + logger.warning('This version of the module is deprecated and it will be removed in future updates. Please upgrade to version 4.0.0 or higher.') + if isinstance(browse_nodes, list) is False: + raise Exception('Browse nodes parameter should be a list') + elif not browse_nodes: + raise Exception('Browse nodes parameter can\'t be empty') + + try: + request = GetBrowseNodesRequest( + partner_tag=self.tag, + partner_type=PartnerType.ASSOCIATES, + marketplace=self.marketplace, + browse_node_ids=browse_nodes, + languages_of_preference=None, + resources=BROWSE_RESOURCES) + except ValueError as e: + raise AmazonException("ValueError", e) + + try: + self._throttle() + if async_req: + thread = self.api.get_browse_nodes(request, async_req=True) + response = thread.get() + else: + response = self.api.get_browse_nodes(request) + except ApiException as e: + raise AmazonException('ApiException', e) + + try: + if response.browse_nodes_result is not None: + res = [AmazonBrowseNode(item) for item in response.browse_nodes_result.browse_nodes] + return parse_browsenode(res) + if response.errors is not None: + raise AmazonException(response.errors[0].code, response.errors[0].message) + except TypeError as e: + raise AmazonException("TypeError", e) + except ValueError as e: + raise AmazonException(ValueError, e) + except AmazonException as e: + raise AmazonException(e.status, e.reason) + except Exception as e: + raise AmazonException("General", e) diff --git a/amazon/paapi5_python_sdk/COPYING.txt b/amazon/paapi5_python_sdk/COPYING.txt new file mode 100644 index 0000000..d645695 --- /dev/null +++ b/amazon/paapi5_python_sdk/COPYING.txt @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/amazon/paapi5_python_sdk/LICENSE.txt b/amazon/paapi5_python_sdk/LICENSE.txt new file mode 100644 index 0000000..d645695 --- /dev/null +++ b/amazon/paapi5_python_sdk/LICENSE.txt @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/amazon/paapi5_python_sdk/NOTICE.txt b/amazon/paapi5_python_sdk/NOTICE.txt new file mode 100644 index 0000000..526e5d9 --- /dev/null +++ b/amazon/paapi5_python_sdk/NOTICE.txt @@ -0,0 +1,2 @@ +Product Advertising API 5.0 SDK for Python +Copyright 2019-2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. \ No newline at end of file diff --git a/amazon/paapi5_python_sdk/__init__.py b/amazon/paapi5_python_sdk/__init__.py new file mode 100644 index 0000000..33fd32b --- /dev/null +++ b/amazon/paapi5_python_sdk/__init__.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +# flake8: noqa + +from __future__ import absolute_import + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + +# import apis into sdk package +from .api.default_api import DefaultApi + +# import auth into sdk package +from .auth.sig_v4 import AWSV4Auth + +# import ApiClient +from .api_client import ApiClient +from .configuration import Configuration +# import models into sdk package +from .availability import Availability +from .browse_node import BrowseNode +from .browse_node_ancestor import BrowseNodeAncestor +from .browse_node_child import BrowseNodeChild +from .browse_node_children import BrowseNodeChildren +from .browse_node_info import BrowseNodeInfo +from .browse_nodes_result import BrowseNodesResult +from .by_line_info import ByLineInfo +from .classifications import Classifications +from .condition import Condition +from .content_info import ContentInfo +from .content_rating import ContentRating +from .contributor import Contributor +from .delivery_flag import DeliveryFlag +from .dimension_based_attribute import DimensionBasedAttribute +from .duration_price import DurationPrice +from .error_data import ErrorData +from .external_ids import ExternalIds +from .get_browse_nodes_request import GetBrowseNodesRequest +from .get_browse_nodes_resource import GetBrowseNodesResource +from .get_browse_nodes_response import GetBrowseNodesResponse +from .get_items_request import GetItemsRequest +from .get_items_resource import GetItemsResource +from .get_items_response import GetItemsResponse +from .get_variations_request import GetVariationsRequest +from .get_variations_resource import GetVariationsResource +from .get_variations_response import GetVariationsResponse +from .image_size import ImageSize +from .image_type import ImageType +from .images import Images +from .item import Item +from .item_id_type import ItemIdType +from .item_info import ItemInfo +from .items_result import ItemsResult +from .language_type import LanguageType +from .languages import Languages +from .manufacture_info import ManufactureInfo +from .max_price import MaxPrice +from .merchant import Merchant +from .min_price import MinPrice +from .min_reviews_rating import MinReviewsRating +from .min_saving_percent import MinSavingPercent +from .multi_valued_attribute import MultiValuedAttribute +from .offer_availability import OfferAvailability +from .offer_condition import OfferCondition +from .offer_count import OfferCount +from .offer_delivery_info import OfferDeliveryInfo +from .offer_listing import OfferListing +from .offer_loyalty_points import OfferLoyaltyPoints +from .offer_merchant_info import OfferMerchantInfo +from .offer_price import OfferPrice +from .offer_program_eligibility import OfferProgramEligibility +from .offer_promotion import OfferPromotion +from .offer_savings import OfferSavings +from .offer_shipping_charge import OfferShippingCharge +from .offer_sub_condition import OfferSubCondition +from .offer_summary import OfferSummary +from .offers import Offers +from .partner_type import PartnerType +from .price import Price +from .product_advertising_api_client_exception import ProductAdvertisingAPIClientException +from .product_advertising_api_service_exception import ProductAdvertisingAPIServiceException +from .product_info import ProductInfo +from .properties import Properties +from .refinement import Refinement +from .refinement_bin import RefinementBin +from .rental_offer_listing import RentalOfferListing +from .rental_offers import RentalOffers +from .search_items_request import SearchItemsRequest +from .search_items_resource import SearchItemsResource +from .search_items_response import SearchItemsResponse +from .search_refinements import SearchRefinements +from .search_result import SearchResult +from .single_boolean_valued_attribute import SingleBooleanValuedAttribute +from .single_integer_valued_attribute import SingleIntegerValuedAttribute +from .single_string_valued_attribute import SingleStringValuedAttribute +from .sort_by import SortBy +from .technical_info import TechnicalInfo +from .trade_in_info import TradeInInfo +from .trade_in_price import TradeInPrice +from .unit_based_attribute import UnitBasedAttribute +from .variation_attribute import VariationAttribute +from .variation_dimension import VariationDimension +from .variation_summary import VariationSummary +from .variations_result import VariationsResult +from .website_sales_rank import WebsiteSalesRank diff --git a/amazon/paapi5_python_sdk/api/__init__.py b/amazon/paapi5_python_sdk/api/__init__.py new file mode 100644 index 0000000..8fa4a5c --- /dev/null +++ b/amazon/paapi5_python_sdk/api/__init__.py @@ -0,0 +1,29 @@ +# coding: utf-8 + +# flake8: noqa + +from __future__ import absolute_import + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + +# import apis into api package +from .default_api import DefaultApi diff --git a/amazon/paapi5_python_sdk/api/default_api.py b/amazon/paapi5_python_sdk/api/default_api.py new file mode 100644 index 0000000..268c452 --- /dev/null +++ b/amazon/paapi5_python_sdk/api/default_api.py @@ -0,0 +1,428 @@ +# coding: utf-8 + +from __future__ import absolute_import + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + +import re # noqa: F401 + +# python 2 and python 3 compatibility library +import six + +from ..api_client import ApiClient + + +class DefaultApi(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + Ref: https://github.com/swagger-api/swagger-codegen + """ + + def __init__(self, + access_key=None, + secret_key=None, + host=None, + region=None, + api_client=None): + if not host: + host = "webservices.amazon.com" + if not region: + region = "us-east-1" + if api_client is None: + api_client = ApiClient(access_key = access_key, + secret_key = secret_key, + host = host, + region = region) + self.api_client = api_client + + def get_browse_nodes(self, get_browse_nodes_request, **kwargs): # noqa: E501 + """get_browse_nodes # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.get_browse_nodes(get_browse_nodes_request, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param GetBrowseNodesRequest get_browse_nodes_request: GetBrowseNodesRequest (required) + :return: GetBrowseNodesResponse + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + if kwargs.get('async_req'): + return self.get_browse_nodes_with_http_info(get_browse_nodes_request, **kwargs) # noqa: E501 + else: + (data) = self.get_browse_nodes_with_http_info(get_browse_nodes_request, **kwargs) # noqa: E501 + return data + + def get_browse_nodes_with_http_info(self, get_browse_nodes_request, **kwargs): # noqa: E501 + """get_browse_nodes # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.get_browse_nodes_with_http_info(get_browse_nodes_request, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param GetBrowseNodesRequest get_browse_nodes_request: GetBrowseNodesRequest (required) + :return: GetBrowseNodesResponse + If the method is called asynchronously, + returns the request thread. + """ + + all_params = ['get_browse_nodes_request'] # noqa: E501 + all_params.append('async_req') + all_params.append('_return_http_data_only') + all_params.append('_preload_content') + all_params.append('_request_timeout') + + params = locals() + for key, val in six.iteritems(params['kwargs']): + if key not in all_params: + raise TypeError( + "Got an unexpected keyword argument '%s'" + " to method get_browse_nodes" % key + ) + params[key] = val + del params['kwargs'] + # verify the required parameter 'get_browse_nodes_request' is set + if ('get_browse_nodes_request' not in params or + params['get_browse_nodes_request'] is None): + raise ValueError("Missing the required parameter `get_browse_nodes_request` when calling `get_browse_nodes`") # noqa: E501 + + collection_formats = {} + + path_params = {} + + query_params = [] + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'get_browse_nodes_request' in params: + body_params = params['get_browse_nodes_request'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json']) # noqa: E501 + + # Authentication setting + auth_settings = [] # noqa: E501 + + return self.api_client.call_api( + '/paapi5/getbrowsenodes', 'POST', 'GetBrowseNodes', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='GetBrowseNodesResponse', # noqa: E501 + auth_settings=auth_settings, + async_req=params.get('async_req'), + _return_http_data_only=params.get('_return_http_data_only'), + _preload_content=params.get('_preload_content', True), + _request_timeout=params.get('_request_timeout'), + collection_formats=collection_formats) + + def get_items(self, get_items_request, **kwargs): # noqa: E501 + """get_items # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.get_items(get_items_request, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param GetItemsRequest get_items_request: GetItemsRequest (required) + :return: GetItemsResponse + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + if kwargs.get('async_req'): + return self.get_items_with_http_info(get_items_request, **kwargs) # noqa: E501 + else: + (data) = self.get_items_with_http_info(get_items_request, **kwargs) # noqa: E501 + return data + + def get_items_with_http_info(self, get_items_request, **kwargs): # noqa: E501 + """get_items # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.get_items_with_http_info(get_items_request, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param GetItemsRequest get_items_request: GetItemsRequest (required) + :return: GetItemsResponse + If the method is called asynchronously, + returns the request thread. + """ + + all_params = ['get_items_request'] # noqa: E501 + all_params.append('async_req') + all_params.append('_return_http_data_only') + all_params.append('_preload_content') + all_params.append('_request_timeout') + + params = locals() + for key, val in six.iteritems(params['kwargs']): + if key not in all_params: + raise TypeError( + "Got an unexpected keyword argument '%s'" + " to method get_items" % key + ) + params[key] = val + del params['kwargs'] + # verify the required parameter 'get_items_request' is set + if ('get_items_request' not in params or + params['get_items_request'] is None): + raise ValueError("Missing the required parameter `get_items_request` when calling `get_items`") # noqa: E501 + + collection_formats = {} + + path_params = {} + + query_params = [] + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'get_items_request' in params: + body_params = params['get_items_request'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json']) # noqa: E501 + + # Authentication setting + auth_settings = [] # noqa: E501 + + return self.api_client.call_api( + '/paapi5/getitems', 'POST', 'GetItems', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='GetItemsResponse', # noqa: E501 + auth_settings=auth_settings, + async_req=params.get('async_req'), + _return_http_data_only=params.get('_return_http_data_only'), + _preload_content=params.get('_preload_content', True), + _request_timeout=params.get('_request_timeout'), + collection_formats=collection_formats) + + def get_variations(self, get_variations_request, **kwargs): # noqa: E501 + """get_variations # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.get_variations(get_variations_request, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param GetVariationsRequest get_variations_request: GetVariationsRequest (required) + :return: GetVariationsResponse + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + if kwargs.get('async_req'): + return self.get_variations_with_http_info(get_variations_request, **kwargs) # noqa: E501 + else: + (data) = self.get_variations_with_http_info(get_variations_request, **kwargs) # noqa: E501 + return data + + def get_variations_with_http_info(self, get_variations_request, **kwargs): # noqa: E501 + """get_variations # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.get_variations_with_http_info(get_variations_request, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param GetVariationsRequest get_variations_request: GetVariationsRequest (required) + :return: GetVariationsResponse + If the method is called asynchronously, + returns the request thread. + """ + + all_params = ['get_variations_request'] # noqa: E501 + all_params.append('async_req') + all_params.append('_return_http_data_only') + all_params.append('_preload_content') + all_params.append('_request_timeout') + + params = locals() + for key, val in six.iteritems(params['kwargs']): + if key not in all_params: + raise TypeError( + "Got an unexpected keyword argument '%s'" + " to method get_variations" % key + ) + params[key] = val + del params['kwargs'] + # verify the required parameter 'get_variations_request' is set + if ('get_variations_request' not in params or + params['get_variations_request'] is None): + raise ValueError("Missing the required parameter `get_variations_request` when calling `get_variations`") # noqa: E501 + + collection_formats = {} + + path_params = {} + + query_params = [] + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'get_variations_request' in params: + body_params = params['get_variations_request'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json']) # noqa: E501 + + # Authentication setting + auth_settings = [] # noqa: E501 + + return self.api_client.call_api( + '/paapi5/getvariations', 'POST', 'GetVariations', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='GetVariationsResponse', # noqa: E501 + auth_settings=auth_settings, + async_req=params.get('async_req'), + _return_http_data_only=params.get('_return_http_data_only'), + _preload_content=params.get('_preload_content', True), + _request_timeout=params.get('_request_timeout'), + collection_formats=collection_formats) + + def search_items(self, search_items_request, **kwargs): # noqa: E501 + """search_items # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.search_items(search_items_request, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param SearchItemsRequest search_items_request: SearchItemsRequest (required) + :return: SearchItemsResponse + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + if kwargs.get('async_req'): + return self.search_items_with_http_info(search_items_request, **kwargs) # noqa: E501 + else: + (data) = self.search_items_with_http_info(search_items_request, **kwargs) # noqa: E501 + return data + + def search_items_with_http_info(self, search_items_request, **kwargs): # noqa: E501 + """search_items # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.search_items_with_http_info(search_items_request, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param SearchItemsRequest search_items_request: SearchItemsRequest (required) + :return: SearchItemsResponse + If the method is called asynchronously, + returns the request thread. + """ + + all_params = ['search_items_request'] # noqa: E501 + all_params.append('async_req') + all_params.append('_return_http_data_only') + all_params.append('_preload_content') + all_params.append('_request_timeout') + + params = locals() + for key, val in six.iteritems(params['kwargs']): + if key not in all_params: + raise TypeError( + "Got an unexpected keyword argument '%s'" + " to method search_items" % key + ) + params[key] = val + del params['kwargs'] + # verify the required parameter 'search_items_request' is set + if ('search_items_request' not in params or + params['search_items_request'] is None): + raise ValueError("Missing the required parameter `search_items_request` when calling `search_items`") # noqa: E501 + + collection_formats = {} + + path_params = {} + + query_params = [] + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'search_items_request' in params: + body_params = params['search_items_request'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json']) # noqa: E501 + + # Authentication setting + auth_settings = [] # noqa: E501 + + return self.api_client.call_api( + '/paapi5/searchitems', 'POST', 'SearchItems', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='SearchItemsResponse', # noqa: E501 + auth_settings=auth_settings, + async_req=params.get('async_req'), + _return_http_data_only=params.get('_return_http_data_only'), + _preload_content=params.get('_preload_content', True), + _request_timeout=params.get('_request_timeout'), + collection_formats=collection_formats) diff --git a/amazon/paapi5_python_sdk/api_client.py b/amazon/paapi5_python_sdk/api_client.py new file mode 100644 index 0000000..5f26b32 --- /dev/null +++ b/amazon/paapi5_python_sdk/api_client.py @@ -0,0 +1,685 @@ +# coding: utf-8 + +from __future__ import absolute_import + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + +import datetime +import json +import mimetypes +from multiprocessing.pool import ThreadPool +import os +import re +import tempfile + +# python 2 and python 3 compatibility library +import six +from six.moves.urllib.parse import quote + +from .configuration import Configuration +from .. import paapi5_python_sdk +from . import rest + +from .auth.sig_v4 import AWSV4Auth + +class ApiClient(object): + """Generic API client for Swagger client library builds. + + Swagger generic API client. This client handles the client- + server communication, and is invariant across implementations. Specifics of + the methods and models for each application are generated from the Swagger + templates. + + NOTE: This class is auto generated by the swagger code generator program. + Ref: https://github.com/swagger-api/swagger-codegen + Do not edit the class manually. + + :param configuration: .Configuration object for this client + :param header_name: a header to pass when making calls to the API. + :param header_value: a header value to pass when making calls to + the API. + :param cookie: a cookie to include in the header when making calls + to the API + """ + + PRIMITIVE_TYPES = (float, bool, bytes, six.text_type) + six.integer_types + NATIVE_TYPES_MAPPING = { + 'int': int, + 'long': int if six.PY3 else long, # noqa: F821 + 'float': float, + 'str': str, + 'bool': bool, + 'date': datetime.date, + 'datetime': datetime.datetime, + 'object': object, + } + + def __init__(self, + access_key, + secret_key, + host, + region, + configuration=None, + header_name=None, + header_value=None, + cookie=None): + if configuration is None: + configuration = Configuration() + self.configuration = configuration + + self.pool = None + self.rest_client = rest.RESTClientObject(configuration) + self.default_headers = {} + if header_name is not None: + self.default_headers[header_name] = header_value + self.cookie = cookie + # Set default User-Agent. + self.user_agent = 'paapi5-python-sdk/1.0.0' + + self.access_key = access_key + self.secret_key = secret_key + self.host = host + self.region = region + + def __del__(self): + if self.pool is not None: + self.pool.close() + self.pool.join() + + @property + def user_agent(self): + """User agent for this API client""" + return self.default_headers['User-Agent'] + + @user_agent.setter + def user_agent(self, value): + self.default_headers['User-Agent'] = value + + def set_default_header(self, header_name, header_value): + self.default_headers[header_name] = header_value + + def __call_api( + self, resource_path, method, api_name, path_params=None, + query_params=None, header_params=None, body=None, post_params=None, + files=None, response_type=None, auth_settings=None, + _return_http_data_only=None, collection_formats=None, + _preload_content=True, _request_timeout=None): + + if self.access_key is None or self.secret_key is None: + raise ValueError("Missing Credentials (Access Key and SecretKey). Please specify credentials.") + + config = self.configuration + + # header parameters + header_params = header_params or {} + header_params.update(self.default_headers) + if self.cookie: + header_params['Cookie'] = self.cookie + if header_params: + header_params = self.sanitize_for_serialization(header_params) + header_params = dict(self.parameters_to_tuples(header_params, + collection_formats)) + + # path parameters + if path_params: + path_params = self.sanitize_for_serialization(path_params) + path_params = self.parameters_to_tuples(path_params, + collection_formats) + for k, v in path_params: + # specified safe chars, encode everything + resource_path = resource_path.replace( + '{%s}' % k, + quote(str(v), safe=config.safe_chars_for_path_param) + ) + + # query parameters + if query_params: + query_params = self.sanitize_for_serialization(query_params) + query_params = self.parameters_to_tuples(query_params, + collection_formats) + + # post parameters + if post_params or files: + post_params = self.prepare_post_parameters(post_params, files) + post_params = self.sanitize_for_serialization(post_params) + post_params = self.parameters_to_tuples(post_params, + collection_formats) + + # auth setting + self.update_params_for_auth(header_params, query_params, auth_settings, api_name, method, body, resource_path) + + # body + if body: + body = self.sanitize_for_serialization(body) + + # request url + url = "https://" + self.host + resource_path + + # perform request and return response + response_data = self.request( + method, url, query_params=query_params, headers=header_params, + post_params=post_params, body=body, + _preload_content=_preload_content, + _request_timeout=_request_timeout) + + self.last_response = response_data + + return_data = response_data + if _preload_content: + # deserialize response data + if response_type: + return_data = self.deserialize(response_data, response_type) + else: + return_data = None + + if _return_http_data_only: + return (return_data) + else: + return (return_data, response_data.status, + response_data.getheaders()) + + def sanitize_for_serialization(self, obj): + """Builds a JSON POST object. + + If obj is None, return None. + If obj is str, int, long, float, bool, return directly. + If obj is datetime.datetime, datetime.date + convert to string in iso8601 format. + If obj is list, sanitize each element in the list. + If obj is dict, return the dict. + If obj is swagger model, return the properties dict. + + :param obj: The data to serialize. + :return: The serialized form of data. + """ + if obj is None: + return None + elif isinstance(obj, self.PRIMITIVE_TYPES): + return obj + elif isinstance(obj, list): + return [self.sanitize_for_serialization(sub_obj) + for sub_obj in obj] + elif isinstance(obj, tuple): + return tuple(self.sanitize_for_serialization(sub_obj) + for sub_obj in obj) + elif isinstance(obj, (datetime.datetime, datetime.date)): + return obj.isoformat() + + if isinstance(obj, dict): + obj_dict = obj + else: + # Convert model obj to dict except + # attributes `swagger_types`, `attribute_map` + # and attributes which value is not None. + # Convert attribute name to json key in + # model definition for request. + obj_dict = {obj.attribute_map[attr]: getattr(obj, attr) + for attr, _ in six.iteritems(obj.swagger_types) + if getattr(obj, attr) is not None} + + return {key: self.sanitize_for_serialization(val) + for key, val in six.iteritems(obj_dict)} + + def deserialize(self, response, response_type): + """Deserializes response into an object. + + :param response: RESTResponse object to be deserialized. + :param response_type: class literal for + deserialized object, or string of class name. + + :return: deserialized object. + """ + # handle file downloading + # save response body into a tmp file and return the instance + if response_type == "file": + return self.__deserialize_file(response) + + # fetch data from response object + try: + data = json.loads(response.data) + except ValueError: + data = response.data + + return self.__deserialize(data, response_type) + + def __deserialize(self, data, klass): + """Deserializes dict, list, str into an object. + + :param data: dict, list or str. + :param klass: class literal, or string of class name. + + :return: object. + """ + if data is None: + return None + + if type(klass) == str: + if klass.startswith('list['): + sub_kls = re.match(r'list\[(.*)\]', klass).group(1) + return [self.__deserialize(sub_data, sub_kls) + for sub_data in data] + + if klass.startswith('dict('): + sub_kls = re.match(r'dict\(([^,]*), (.*)\)', klass).group(2) + return {k: self.__deserialize(v, sub_kls) + for k, v in six.iteritems(data)} + + # convert str to class + if klass in self.NATIVE_TYPES_MAPPING: + klass = self.NATIVE_TYPES_MAPPING[klass] + else: + klass = getattr(paapi5_python_sdk, klass) + + if klass in self.PRIMITIVE_TYPES: + return self.__deserialize_primitive(data, klass) + elif klass == object: + return self.__deserialize_object(data) + elif klass == datetime.date: + return self.__deserialize_date(data) + elif klass == datetime.datetime: + return self.__deserialize_datatime(data) + else: + return self.__deserialize_model(data, klass) + + def call_api(self, resource_path, method, api_name, + path_params=None, query_params=None, header_params=None, + body=None, post_params=None, files=None, + response_type=None, auth_settings=None, async_req=None, + _return_http_data_only=None, collection_formats=None, + _preload_content=True, _request_timeout=None): + """Makes the HTTP request (synchronous) and returns deserialized data. + + To make an async request, set the async_req parameter. + + :param resource_path: Path to method endpoint. + :param method: Method to call. + :param path_params: Path parameters in the url. + :param query_params: Query parameters in the url. + :param header_params: Header parameters to be + placed in the request header. + :param body: Request body. + :param post_params dict: Request post form parameters, + for `application/x-www-form-urlencoded`, `multipart/form-data`. + :param auth_settings list: Auth Settings names for the request. + :param response: Response data type. + :param files dict: key -> filename, value -> filepath, + for `multipart/form-data`. + :param async_req bool: execute request asynchronously + :param _return_http_data_only: response data without head status code + and headers + :param collection_formats: dict of collection formats for path, query, + header, and post parameters. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: + If async_req parameter is True, + the request will be called asynchronously. + The method will return the request thread. + If parameter async_req is False or missing, + then the method will return the response directly. + """ + if not async_req: + return self.__call_api(resource_path, method, api_name, + path_params, query_params, header_params, + body, post_params, files, + response_type, auth_settings, + _return_http_data_only, collection_formats, + _preload_content, _request_timeout) + else: + if self.pool is None: + self.pool = ThreadPool() + thread = self.pool.apply_async(self.__call_api, (resource_path, + method, api_name, path_params, query_params, + header_params, body, + post_params, files, + response_type, auth_settings, + _return_http_data_only, + collection_formats, + _preload_content, _request_timeout)) + return thread + + def request(self, method, url, query_params=None, headers=None, + post_params=None, body=None, _preload_content=True, + _request_timeout=None): + """Makes the HTTP request using RESTClient.""" + if method == "GET": + return self.rest_client.GET(url, + query_params=query_params, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + headers=headers) + elif method == "HEAD": + return self.rest_client.HEAD(url, + query_params=query_params, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + headers=headers) + elif method == "OPTIONS": + return self.rest_client.OPTIONS(url, + query_params=query_params, + headers=headers, + post_params=post_params, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + body=body) + elif method == "POST": + return self.rest_client.POST(url, + query_params=query_params, + headers=headers, + post_params=post_params, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + body=body) + elif method == "PUT": + return self.rest_client.PUT(url, + query_params=query_params, + headers=headers, + post_params=post_params, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + body=body) + elif method == "PATCH": + return self.rest_client.PATCH(url, + query_params=query_params, + headers=headers, + post_params=post_params, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + body=body) + elif method == "DELETE": + return self.rest_client.DELETE(url, + query_params=query_params, + headers=headers, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + body=body) + else: + raise ValueError( + "http method must be `GET`, `HEAD`, `OPTIONS`," + " `POST`, `PATCH`, `PUT` or `DELETE`." + ) + + def parameters_to_tuples(self, params, collection_formats): + """Get parameters as list of tuples, formatting collections. + + :param params: Parameters as dict or list of two-tuples + :param dict collection_formats: Parameter collection formats + :return: Parameters as list of tuples, collections formatted + """ + new_params = [] + if collection_formats is None: + collection_formats = {} + for k, v in six.iteritems(params) if isinstance(params, dict) else params: # noqa: E501 + if k in collection_formats: + collection_format = collection_formats[k] + if collection_format == 'multi': + new_params.extend((k, value) for value in v) + else: + if collection_format == 'ssv': + delimiter = ' ' + elif collection_format == 'tsv': + delimiter = '\t' + elif collection_format == 'pipes': + delimiter = '|' + else: # csv is the default + delimiter = ',' + new_params.append( + (k, delimiter.join(str(value) for value in v))) + else: + new_params.append((k, v)) + return new_params + + def prepare_post_parameters(self, post_params=None, files=None): + """Builds form parameters. + + :param post_params: Normal form parameters. + :param files: File parameters. + :return: Form parameters with files. + """ + params = [] + + if post_params: + params = post_params + + if files: + for k, v in six.iteritems(files): + if not v: + continue + file_names = v if type(v) is list else [v] + for n in file_names: + with open(n, 'rb') as f: + filename = os.path.basename(f.name) + filedata = f.read() + mimetype = (mimetypes.guess_type(filename)[0] or + 'application/octet-stream') + params.append( + tuple([k, tuple([filename, filedata, mimetype])])) + + return params + + def select_header_accept(self, accepts): + """Returns `Accept` based on an array of accepts provided. + + :param accepts: List of headers. + :return: Accept (e.g. application/json). + """ + if not accepts: + return + + accepts = [x.lower() for x in accepts] + + if 'application/json' in accepts: + return 'application/json' + else: + return ', '.join(accepts) + + def select_header_content_type(self, content_types): + """Returns `Content-Type` based on an array of content_types provided. + + :param content_types: List of content-types. + :return: Content-Type (e.g. application/json). + """ + if not content_types: + return 'application/json' + + content_types = [x.lower() for x in content_types] + + if 'application/json' in content_types or '*/*' in content_types: + return 'application/json' + else: + return content_types[0] + + def get_amz_date(self, utc_timestamp): + return utc_timestamp.strftime('%Y%m%dT%H%M%SZ') + + def update_params_for_auth(self, headers, querys, auth_settings, api_name, method, body, resource_path): + """Updates header and query params based on authentication setting. + + :param headers: Header parameters dict to be updated. + :param querys: Query parameters tuple list to be updated. + :param auth_settings: Authentication setting identifiers list. + """ + if not auth_settings: + service = 'ProductAdvertisingAPI' + utc_timestamp = datetime.datetime.utcnow() + headers['x-amz-target'] = 'com.amazon.paapi5.v1.ProductAdvertisingAPIv1.' + api_name + headers['content-encoding'] = 'amz-1.0' + headers['Content-Type'] = 'application/json; charset=utf-8' + headers['host'] = self.host + headers['x-amz-date'] = self.get_amz_date(utc_timestamp) + awsv4Auth = AWSV4Auth(access_key=self.access_key, + secret_key=self.secret_key, + host=self.host, + region=self.region, + service=service, + method_name=method, + timestamp=utc_timestamp, + headers=headers, + payload=self.sanitize_for_serialization(body), + path=resource_path) + authHeaders = awsv4Auth.getHeaders() + + return + + for auth in auth_settings: + auth_setting = self.configuration.auth_settings().get(auth) + if auth_setting: + if not auth_setting['value']: + continue + elif auth_setting['in'] == 'header': + headers[auth_setting['key']] = auth_setting['value'] + elif auth_setting['in'] == 'query': + querys.append((auth_setting['key'], auth_setting['value'])) + else: + raise ValueError( + 'Authentication token must be in `query` or `header`' + ) + + def __deserialize_file(self, response): + """Deserializes body to file + + Saves response body into a file in a temporary folder, + using the filename from the `Content-Disposition` header if provided. + + :param response: RESTResponse. + :return: file path. + """ + fd, path = tempfile.mkstemp(dir=self.configuration.temp_folder_path) + os.close(fd) + os.remove(path) + + content_disposition = response.getheader("Content-Disposition") + if content_disposition: + filename = re.search(r'filename=[\'"]?([^\'"\s]+)[\'"]?', + content_disposition).group(1) + path = os.path.join(os.path.dirname(path), filename) + + with open(path, "wb") as f: + f.write(response.data) + + return path + + def __deserialize_primitive(self, data, klass): + """Deserializes string to primitive type. + + :param data: str. + :param klass: class literal. + + :return: int, long, float, str, bool. + """ + try: + return klass(data) + except UnicodeEncodeError: + return six.text_type(data) + #try: + #return unicode(data.replace(r'\\', r'\\\\'), "unicode_escape") + #except TypeError as e: + #if "decoding Unicode is not supported" in str(e): + #return unicode(data.replace(r'\\', r'\\\\')) + except TypeError: + return data + + def __deserialize_object(self, value): + """Return a original value. + + :return: object. + """ + return value + + def __deserialize_date(self, string): + """Deserializes string to date. + + :param string: str. + :return: date. + """ + try: + from dateutil.parser import parse + return parse(string).date() + except ImportError: + return string + except ValueError: + raise rest.ApiException( + status=0, + reason="Failed to parse `{0}` as date object".format(string) + ) + + def __deserialize_datatime(self, string): + """Deserializes string to datetime. + + The string should be in iso8601 datetime format. + + :param string: str. + :return: datetime. + """ + try: + from dateutil.parser import parse + return parse(string) + except ImportError: + return string + except ValueError: + raise rest.ApiException( + status=0, + reason=( + "Failed to parse `{0}` as datetime object" + .format(string) + ) + ) + + def __deserialize_model(self, data, klass): + """Deserializes list or dict to model. + + :param data: dict, list. + :param klass: class literal. + :return: model object. + """ + + if not klass.swagger_types and not hasattr(klass, + 'get_real_child_model'): + return data + + kwargs = {} + if klass.swagger_types is not None: + for attr, attr_type in six.iteritems(klass.swagger_types): + if (data is not None and + klass.attribute_map[attr] in data and + isinstance(data, (list, dict))): + value = data[klass.attribute_map[attr]] + kwargs[attr] = self.__deserialize(value, attr_type) + + instance = klass(**kwargs) + + if (isinstance(instance, dict) and + klass.swagger_types is not None and + isinstance(data, dict)): + for key, value in data.items(): + if key not in klass.swagger_types: + instance[key] = value + if hasattr(instance, 'get_real_child_model'): + klass_name = instance.get_real_child_model(data) + if klass_name: + instance = self.__deserialize(data, klass_name) + return instance diff --git a/amazon/paapi5_python_sdk/auth/__init__.py b/amazon/paapi5_python_sdk/auth/__init__.py new file mode 100644 index 0000000..fe07328 --- /dev/null +++ b/amazon/paapi5_python_sdk/auth/__init__.py @@ -0,0 +1,29 @@ +# coding: utf-8 + +# flake8: noqa + +from __future__ import absolute_import + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + +# import auth into sdk package +from .sig_v4 import AWSV4Auth diff --git a/amazon/paapi5_python_sdk/auth/sig_v4.py b/amazon/paapi5_python_sdk/auth/sig_v4.py new file mode 100644 index 0000000..6fc4bdc --- /dev/null +++ b/amazon/paapi5_python_sdk/auth/sig_v4.py @@ -0,0 +1,149 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" +ProductAdvertisingAPI + +https://webservices.amazon.com/paapi5/documentation/index.html + +""" + +import hashlib +import hmac +import json + + +class AWSV4Auth: + def __init__( + self, + access_key, + secret_key, + host, + region, + service, + method_name, + timestamp, + headers={}, + path="", + payload="", + ): + self.access_key = access_key + self.secret_key = secret_key + self.host = host + self.region = region + self.service = service + self.method_name = method_name + self.headers = headers + self.timestamp = timestamp + self.payload = payload + self.path = path + + self.xAmzDateTime = self.timestamp.strftime("%Y%m%dT%H%M%SZ") + self.xAmzDate = self.timestamp.strftime("%Y%m%d") + + def getHeaders(self): + canonical_request = self.prepareCanonicalURL() + string_to_sign = self.prepareStringToSign(canonical_request=canonical_request) + signing_key = self.getSignatureKey( + self.secret_key, self.xAmzDate, self.region, self.service + ) + signature = self.getSignature( + signing_key=signing_key, string_to_sign=string_to_sign + ) + + authorization_header = ( + self.algorithm + + " " + + "Credential=" + + self.access_key + + "/" + + self.credential_scope + + ", " + + "SignedHeaders=" + + self.signed_header + + ", " + + "Signature=" + + signature + ) + self.headers["Authorization"] = authorization_header + return self.headers + + def prepareCanonicalURL(self): + canonical_uri = self.method_name + "\n" + self.path + canonical_querystring = "" + canonical_header = "" + self.signed_header = "" + sortedkeys = sorted(self.headers, key=str.lower) + for key in sortedkeys: + self.signed_header = self.signed_header + key.lower() + ";" + canonical_header = ( + canonical_header + key.lower() + ":" + self.headers[key] + "\n" + ) + self.signed_header = self.signed_header[:-1] + payload_hash = hashlib.sha256( + json.dumps(self.payload).encode("utf-8") + ).hexdigest() + canonical_request = ( + canonical_uri + + "\n" + + canonical_querystring + + "\n" + + canonical_header + + "\n" + + self.signed_header + + "\n" + + payload_hash + ) + return canonical_request + + def prepareStringToSign(self, canonical_request): + self.algorithm = "AWS4-HMAC-SHA256" + self.credential_scope = ( + self.xAmzDate + + "/" + + self.region + + "/" + + self.service + + "/" + + "aws4_request" + ) + string_to_sign = ( + self.algorithm + + "\n" + + self.xAmzDateTime + + "\n" + + self.credential_scope + + "\n" + + hashlib.sha256(canonical_request.encode("utf-8")).hexdigest() + ) + return string_to_sign + + def sign(self, key, msg): + return hmac.new(key, msg.encode("utf-8"), hashlib.sha256).digest() + + def getSignatureKey(self, key, dateStamp, regionName, serviceName): + kDate = self.sign(("AWS4" + key).encode("utf-8"), dateStamp) + kRegion = self.sign(kDate, regionName) + kService = self.sign(kRegion, serviceName) + kSigning = self.sign(kService, "aws4_request") + return kSigning + + def getSignature(self, signing_key, string_to_sign): + signature = hmac.new( + signing_key, (string_to_sign).encode("utf-8"), hashlib.sha256 + ).hexdigest() + return signature diff --git a/amazon/paapi5_python_sdk/availability.py b/amazon/paapi5_python_sdk/availability.py new file mode 100644 index 0000000..ff22efa --- /dev/null +++ b/amazon/paapi5_python_sdk/availability.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class Availability(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + allowed enum values + """ + AVAILABLE = "Available" + INCLUDEOUTOFSTOCK = "IncludeOutOfStock" + + """ + 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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """Availability - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(Availability, 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, Availability): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/browse_node.py b/amazon/paapi5_python_sdk/browse_node.py new file mode 100644 index 0000000..09e8242 --- /dev/null +++ b/amazon/paapi5_python_sdk/browse_node.py @@ -0,0 +1,285 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .browse_node_ancestor import BrowseNodeAncestor # noqa: F401,E501 +from .browse_node_children import BrowseNodeChildren # noqa: F401,E501 + + +class BrowseNode(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 = { + 'ancestor': 'BrowseNodeAncestor', + 'children': 'BrowseNodeChildren', + 'context_free_name': 'str', + 'display_name': 'str', + 'id': 'str', + 'is_root': 'bool', + 'sales_rank': 'int' + } + + attribute_map = { + 'ancestor': 'Ancestor', + 'children': 'Children', + 'context_free_name': 'ContextFreeName', + 'display_name': 'DisplayName', + 'id': 'Id', + 'is_root': 'IsRoot', + 'sales_rank': 'SalesRank' + } + + def __init__(self, ancestor=None, children=None, context_free_name=None, display_name=None, id=None, is_root=None, sales_rank=None): # noqa: E501 + """BrowseNode - a model defined in Swagger""" # noqa: E501 + + self._ancestor = None + self._children = None + self._context_free_name = None + self._display_name = None + self._id = None + self._is_root = None + self._sales_rank = None + self.discriminator = None + + if ancestor is not None: + self.ancestor = ancestor + if children is not None: + self.children = children + if context_free_name is not None: + self.context_free_name = context_free_name + if display_name is not None: + self.display_name = display_name + if id is not None: + self.id = id + if is_root is not None: + self.is_root = is_root + if sales_rank is not None: + self.sales_rank = sales_rank + + @property + def ancestor(self): + """Gets the ancestor of this BrowseNode. # noqa: E501 + + + :return: The ancestor of this BrowseNode. # noqa: E501 + :rtype: BrowseNodeAncestor + """ + return self._ancestor + + @ancestor.setter + def ancestor(self, ancestor): + """Sets the ancestor of this BrowseNode. + + + :param ancestor: The ancestor of this BrowseNode. # noqa: E501 + :type: BrowseNodeAncestor + """ + + self._ancestor = ancestor + + @property + def children(self): + """Gets the children of this BrowseNode. # noqa: E501 + + + :return: The children of this BrowseNode. # noqa: E501 + :rtype: BrowseNodeChildren + """ + return self._children + + @children.setter + def children(self, children): + """Sets the children of this BrowseNode. + + + :param children: The children of this BrowseNode. # noqa: E501 + :type: BrowseNodeChildren + """ + + self._children = children + + @property + def context_free_name(self): + """Gets the context_free_name of this BrowseNode. # noqa: E501 + + + :return: The context_free_name of this BrowseNode. # noqa: E501 + :rtype: str + """ + return self._context_free_name + + @context_free_name.setter + def context_free_name(self, context_free_name): + """Sets the context_free_name of this BrowseNode. + + + :param context_free_name: The context_free_name of this BrowseNode. # noqa: E501 + :type: str + """ + + self._context_free_name = context_free_name + + @property + def display_name(self): + """Gets the display_name of this BrowseNode. # noqa: E501 + + + :return: The display_name of this BrowseNode. # noqa: E501 + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """Sets the display_name of this BrowseNode. + + + :param display_name: The display_name of this BrowseNode. # noqa: E501 + :type: str + """ + + self._display_name = display_name + + @property + def id(self): + """Gets the id of this BrowseNode. # noqa: E501 + + + :return: The id of this BrowseNode. # noqa: E501 + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """Sets the id of this BrowseNode. + + + :param id: The id of this BrowseNode. # noqa: E501 + :type: str + """ + + self._id = id + + @property + def is_root(self): + """Gets the is_root of this BrowseNode. # noqa: E501 + + + :return: The is_root of this BrowseNode. # noqa: E501 + :rtype: bool + """ + return self._is_root + + @is_root.setter + def is_root(self, is_root): + """Sets the is_root of this BrowseNode. + + + :param is_root: The is_root of this BrowseNode. # noqa: E501 + :type: bool + """ + + self._is_root = is_root + + @property + def sales_rank(self): + """Gets the sales_rank of this BrowseNode. # noqa: E501 + + + :return: The sales_rank of this BrowseNode. # noqa: E501 + :rtype: int + """ + return self._sales_rank + + @sales_rank.setter + def sales_rank(self, sales_rank): + """Sets the sales_rank of this BrowseNode. + + + :param sales_rank: The sales_rank of this BrowseNode. # noqa: E501 + :type: int + """ + + self._sales_rank = sales_rank + + 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(BrowseNode, 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, BrowseNode): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/browse_node_ancestor.py b/amazon/paapi5_python_sdk/browse_node_ancestor.py new file mode 100644 index 0000000..72c6514 --- /dev/null +++ b/amazon/paapi5_python_sdk/browse_node_ancestor.py @@ -0,0 +1,204 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class BrowseNodeAncestor(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 = { + 'ancestor': 'BrowseNodeAncestor', + 'context_free_name': 'str', + 'display_name': 'str', + 'id': 'str' + } + + attribute_map = { + 'ancestor': 'Ancestor', + 'context_free_name': 'ContextFreeName', + 'display_name': 'DisplayName', + 'id': 'Id' + } + + def __init__(self, ancestor=None, context_free_name=None, display_name=None, id=None): # noqa: E501 + """BrowseNodeAncestor - a model defined in Swagger""" # noqa: E501 + + self._ancestor = None + self._context_free_name = None + self._display_name = None + self._id = None + self.discriminator = None + + if ancestor is not None: + self.ancestor = ancestor + if context_free_name is not None: + self.context_free_name = context_free_name + if display_name is not None: + self.display_name = display_name + if id is not None: + self.id = id + + @property + def ancestor(self): + """Gets the ancestor of this BrowseNodeAncestor. # noqa: E501 + + + :return: The ancestor of this BrowseNodeAncestor. # noqa: E501 + :rtype: BrowseNodeAncestor + """ + return self._ancestor + + @ancestor.setter + def ancestor(self, ancestor): + """Sets the ancestor of this BrowseNodeAncestor. + + + :param ancestor: The ancestor of this BrowseNodeAncestor. # noqa: E501 + :type: BrowseNodeAncestor + """ + + self._ancestor = ancestor + + @property + def context_free_name(self): + """Gets the context_free_name of this BrowseNodeAncestor. # noqa: E501 + + + :return: The context_free_name of this BrowseNodeAncestor. # noqa: E501 + :rtype: str + """ + return self._context_free_name + + @context_free_name.setter + def context_free_name(self, context_free_name): + """Sets the context_free_name of this BrowseNodeAncestor. + + + :param context_free_name: The context_free_name of this BrowseNodeAncestor. # noqa: E501 + :type: str + """ + + self._context_free_name = context_free_name + + @property + def display_name(self): + """Gets the display_name of this BrowseNodeAncestor. # noqa: E501 + + + :return: The display_name of this BrowseNodeAncestor. # noqa: E501 + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """Sets the display_name of this BrowseNodeAncestor. + + + :param display_name: The display_name of this BrowseNodeAncestor. # noqa: E501 + :type: str + """ + + self._display_name = display_name + + @property + def id(self): + """Gets the id of this BrowseNodeAncestor. # noqa: E501 + + + :return: The id of this BrowseNodeAncestor. # noqa: E501 + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """Sets the id of this BrowseNodeAncestor. + + + :param id: The id of this BrowseNodeAncestor. # noqa: E501 + :type: str + """ + + self._id = id + + 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(BrowseNodeAncestor, 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, BrowseNodeAncestor): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/browse_node_child.py b/amazon/paapi5_python_sdk/browse_node_child.py new file mode 100644 index 0000000..47c2d9d --- /dev/null +++ b/amazon/paapi5_python_sdk/browse_node_child.py @@ -0,0 +1,178 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class BrowseNodeChild(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 = { + 'context_free_name': 'str', + 'display_name': 'str', + 'id': 'str' + } + + attribute_map = { + 'context_free_name': 'ContextFreeName', + 'display_name': 'DisplayName', + 'id': 'Id' + } + + def __init__(self, context_free_name=None, display_name=None, id=None): # noqa: E501 + """BrowseNodeChild - a model defined in Swagger""" # noqa: E501 + + self._context_free_name = None + self._display_name = None + self._id = None + self.discriminator = None + + if context_free_name is not None: + self.context_free_name = context_free_name + if display_name is not None: + self.display_name = display_name + if id is not None: + self.id = id + + @property + def context_free_name(self): + """Gets the context_free_name of this BrowseNodeChild. # noqa: E501 + + + :return: The context_free_name of this BrowseNodeChild. # noqa: E501 + :rtype: str + """ + return self._context_free_name + + @context_free_name.setter + def context_free_name(self, context_free_name): + """Sets the context_free_name of this BrowseNodeChild. + + + :param context_free_name: The context_free_name of this BrowseNodeChild. # noqa: E501 + :type: str + """ + + self._context_free_name = context_free_name + + @property + def display_name(self): + """Gets the display_name of this BrowseNodeChild. # noqa: E501 + + + :return: The display_name of this BrowseNodeChild. # noqa: E501 + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """Sets the display_name of this BrowseNodeChild. + + + :param display_name: The display_name of this BrowseNodeChild. # noqa: E501 + :type: str + """ + + self._display_name = display_name + + @property + def id(self): + """Gets the id of this BrowseNodeChild. # noqa: E501 + + + :return: The id of this BrowseNodeChild. # noqa: E501 + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """Sets the id of this BrowseNodeChild. + + + :param id: The id of this BrowseNodeChild. # noqa: E501 + :type: str + """ + + self._id = id + + 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(BrowseNodeChild, 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, BrowseNodeChild): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/browse_node_children.py b/amazon/paapi5_python_sdk/browse_node_children.py new file mode 100644 index 0000000..9b9772a --- /dev/null +++ b/amazon/paapi5_python_sdk/browse_node_children.py @@ -0,0 +1,100 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .browse_node_child import BrowseNodeChild # noqa: F401,E501 + + +class BrowseNodeChildren(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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """BrowseNodeChildren - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(BrowseNodeChildren, 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, BrowseNodeChildren): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/browse_node_info.py b/amazon/paapi5_python_sdk/browse_node_info.py new file mode 100644 index 0000000..52d8de7 --- /dev/null +++ b/amazon/paapi5_python_sdk/browse_node_info.py @@ -0,0 +1,155 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .browse_node import BrowseNode # noqa: F401,E501 +from .website_sales_rank import WebsiteSalesRank # noqa: F401,E501 + + +class BrowseNodeInfo(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 = { + 'browse_nodes': 'list[BrowseNode]', + 'website_sales_rank': 'WebsiteSalesRank' + } + + attribute_map = { + 'browse_nodes': 'BrowseNodes', + 'website_sales_rank': 'WebsiteSalesRank' + } + + def __init__(self, browse_nodes=None, website_sales_rank=None): # noqa: E501 + """BrowseNodeInfo - a model defined in Swagger""" # noqa: E501 + + self._browse_nodes = None + self._website_sales_rank = None + self.discriminator = None + + if browse_nodes is not None: + self.browse_nodes = browse_nodes + if website_sales_rank is not None: + self.website_sales_rank = website_sales_rank + + @property + def browse_nodes(self): + """Gets the browse_nodes of this BrowseNodeInfo. # noqa: E501 + + + :return: The browse_nodes of this BrowseNodeInfo. # noqa: E501 + :rtype: list[BrowseNode] + """ + return self._browse_nodes + + @browse_nodes.setter + def browse_nodes(self, browse_nodes): + """Sets the browse_nodes of this BrowseNodeInfo. + + + :param browse_nodes: The browse_nodes of this BrowseNodeInfo. # noqa: E501 + :type: list[BrowseNode] + """ + + self._browse_nodes = browse_nodes + + @property + def website_sales_rank(self): + """Gets the website_sales_rank of this BrowseNodeInfo. # noqa: E501 + + + :return: The website_sales_rank of this BrowseNodeInfo. # noqa: E501 + :rtype: WebsiteSalesRank + """ + return self._website_sales_rank + + @website_sales_rank.setter + def website_sales_rank(self, website_sales_rank): + """Sets the website_sales_rank of this BrowseNodeInfo. + + + :param website_sales_rank: The website_sales_rank of this BrowseNodeInfo. # noqa: E501 + :type: WebsiteSalesRank + """ + + self._website_sales_rank = website_sales_rank + + 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(BrowseNodeInfo, 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, BrowseNodeInfo): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/browse_nodes_result.py b/amazon/paapi5_python_sdk/browse_nodes_result.py new file mode 100644 index 0000000..0bccd5d --- /dev/null +++ b/amazon/paapi5_python_sdk/browse_nodes_result.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .browse_node import BrowseNode # noqa: F401,E501 + + +class BrowseNodesResult(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 = { + 'browse_nodes': 'list[BrowseNode]' + } + + attribute_map = { + 'browse_nodes': 'BrowseNodes' + } + + def __init__(self, browse_nodes=None): # noqa: E501 + """BrowseNodesResult - a model defined in Swagger""" # noqa: E501 + + self._browse_nodes = None + self.discriminator = None + + if browse_nodes is not None: + self.browse_nodes = browse_nodes + + @property + def browse_nodes(self): + """Gets the browse_nodes of this BrowseNodesResult. # noqa: E501 + + + :return: The browse_nodes of this BrowseNodesResult. # noqa: E501 + :rtype: list[BrowseNode] + """ + return self._browse_nodes + + @browse_nodes.setter + def browse_nodes(self, browse_nodes): + """Sets the browse_nodes of this BrowseNodesResult. + + + :param browse_nodes: The browse_nodes of this BrowseNodesResult. # noqa: E501 + :type: list[BrowseNode] + """ + + self._browse_nodes = browse_nodes + + 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(BrowseNodesResult, 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, BrowseNodesResult): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/by_line_info.py b/amazon/paapi5_python_sdk/by_line_info.py new file mode 100644 index 0000000..9b3052b --- /dev/null +++ b/amazon/paapi5_python_sdk/by_line_info.py @@ -0,0 +1,181 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .contributor import Contributor # noqa: F401,E501 +from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 + + +class ByLineInfo(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 = { + 'brand': 'SingleStringValuedAttribute', + 'contributors': 'list[Contributor]', + 'manufacturer': 'SingleStringValuedAttribute' + } + + attribute_map = { + 'brand': 'Brand', + 'contributors': 'Contributors', + 'manufacturer': 'Manufacturer' + } + + def __init__(self, brand=None, contributors=None, manufacturer=None): # noqa: E501 + """ByLineInfo - a model defined in Swagger""" # noqa: E501 + + self._brand = None + self._contributors = None + self._manufacturer = None + self.discriminator = None + + if brand is not None: + self.brand = brand + if contributors is not None: + self.contributors = contributors + if manufacturer is not None: + self.manufacturer = manufacturer + + @property + def brand(self): + """Gets the brand of this ByLineInfo. # noqa: E501 + + + :return: The brand of this ByLineInfo. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._brand + + @brand.setter + def brand(self, brand): + """Sets the brand of this ByLineInfo. + + + :param brand: The brand of this ByLineInfo. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._brand = brand + + @property + def contributors(self): + """Gets the contributors of this ByLineInfo. # noqa: E501 + + + :return: The contributors of this ByLineInfo. # noqa: E501 + :rtype: list[Contributor] + """ + return self._contributors + + @contributors.setter + def contributors(self, contributors): + """Sets the contributors of this ByLineInfo. + + + :param contributors: The contributors of this ByLineInfo. # noqa: E501 + :type: list[Contributor] + """ + + self._contributors = contributors + + @property + def manufacturer(self): + """Gets the manufacturer of this ByLineInfo. # noqa: E501 + + + :return: The manufacturer of this ByLineInfo. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._manufacturer + + @manufacturer.setter + def manufacturer(self, manufacturer): + """Sets the manufacturer of this ByLineInfo. + + + :param manufacturer: The manufacturer of this ByLineInfo. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._manufacturer = manufacturer + + 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(ByLineInfo, 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, ByLineInfo): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/classifications.py b/amazon/paapi5_python_sdk/classifications.py new file mode 100644 index 0000000..86e2e25 --- /dev/null +++ b/amazon/paapi5_python_sdk/classifications.py @@ -0,0 +1,154 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 + + +class Classifications(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 = { + 'binding': 'SingleStringValuedAttribute', + 'product_group': 'SingleStringValuedAttribute' + } + + attribute_map = { + 'binding': 'Binding', + 'product_group': 'ProductGroup' + } + + def __init__(self, binding=None, product_group=None): # noqa: E501 + """Classifications - a model defined in Swagger""" # noqa: E501 + + self._binding = None + self._product_group = None + self.discriminator = None + + if binding is not None: + self.binding = binding + if product_group is not None: + self.product_group = product_group + + @property + def binding(self): + """Gets the binding of this Classifications. # noqa: E501 + + + :return: The binding of this Classifications. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._binding + + @binding.setter + def binding(self, binding): + """Sets the binding of this Classifications. + + + :param binding: The binding of this Classifications. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._binding = binding + + @property + def product_group(self): + """Gets the product_group of this Classifications. # noqa: E501 + + + :return: The product_group of this Classifications. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._product_group + + @product_group.setter + def product_group(self, product_group): + """Sets the product_group of this Classifications. + + + :param product_group: The product_group of this Classifications. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._product_group = product_group + + 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(Classifications, 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, Classifications): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/condition.py b/amazon/paapi5_python_sdk/condition.py new file mode 100644 index 0000000..0f554dc --- /dev/null +++ b/amazon/paapi5_python_sdk/condition.py @@ -0,0 +1,107 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class Condition(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + allowed enum values + """ + ANY = "Any" + COLLECTIBLE = "Collectible" + NEW = "New" + REFURBISHED = "Refurbished" + USED = "Used" + + """ + 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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """Condition - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(Condition, 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, Condition): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/configuration.py b/amazon/paapi5_python_sdk/configuration.py new file mode 100644 index 0000000..562a9c6 --- /dev/null +++ b/amazon/paapi5_python_sdk/configuration.py @@ -0,0 +1,230 @@ +# coding: utf-8 + +from __future__ import absolute_import + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + +import copy +import logging +import multiprocessing +import sys +import urllib3 + +import six +from six.moves import http_client as httplib + + +class TypeWithDefault(type): + def __init__(cls, name, bases, dct): + super(TypeWithDefault, cls).__init__(name, bases, dct) + cls._default = None + + def __call__(cls): + if cls._default is None: + cls._default = type.__call__(cls) + return copy.copy(cls._default) + + def set_default(cls, default): + cls._default = copy.copy(default) + + +class Configuration(six.with_metaclass(TypeWithDefault, object)): + """NOTE: This class is auto generated by the swagger code generator program. + + Ref: https://github.com/swagger-api/swagger-codegen + Do not edit the class manually. + """ + + def __init__(self, connection_pool_maxsize=None): + """Constructor""" + # Default Base url + self.host = "https://webservices.amazon.com" + + # Logging Settings + self.logger = {} + self.logger["package_logger"] = logging.getLogger("") + self.logger["urllib3_logger"] = logging.getLogger("urllib3") + # Log format + self.logger_format = '%(asctime)s %(levelname)s %(message)s' + # Log stream handler + self.logger_stream_handler = None + # Log file handler + self.logger_file_handler = None + # Debug file location + self.logger_file = None + # Debug switch + self.debug = False + + # SSL/TLS verification + # Set this to false to skip verifying SSL certificate when calling API + # from https server. + self.verify_ssl = True + # Set this to customize the certificate file to verify the peer. + self.ssl_ca_cert = None + # client certificate file + self.cert_file = None + # client key file + self.key_file = None + # Set this to True/False to enable/disable SSL hostname verification. + self.assert_hostname = None + + # urllib3 connection pool's maximum number of connections saved + # per pool. urllib3 uses 1 connection as default value, but this is + # not the best value when you are making a lot of possibly parallel + # requests to the same host, which is often the case here. + # cpu_count * 5 is used as default value to increase performance. + if connection_pool_maxsize is None: + connection_pool_maxsize = multiprocessing.cpu_count() * 5 + self.connection_pool_maxsize = connection_pool_maxsize + # Proxy URL + self.proxy = None + # Safe chars for path_param + self.safe_chars_for_path_param = '' + + @property + def logger_file(self): + """The logger file. + + If the logger_file is None, then add stream handler and remove file + handler. Otherwise, add file handler and remove stream handler. + + :param value: The logger_file path. + :type: str + """ + return self.__logger_file + + @logger_file.setter + def logger_file(self, value): + """The logger file. + + If the logger_file is None, then add stream handler and remove file + handler. Otherwise, add file handler and remove stream handler. + + :param value: The logger_file path. + :type: str + """ + self.__logger_file = value + if self.__logger_file: + # If set logging file, + # then add file handler and remove stream handler. + self.logger_file_handler = logging.FileHandler(self.__logger_file) + self.logger_file_handler.setFormatter(self.logger_formatter) + for _, logger in six.iteritems(self.logger): + logger.addHandler(self.logger_file_handler) + if self.logger_stream_handler: + logger.removeHandler(self.logger_stream_handler) + else: + # If not set logging file, + # then add stream handler and remove file handler. + self.logger_stream_handler = logging.StreamHandler() + self.logger_stream_handler.setFormatter(self.logger_formatter) + for _, logger in six.iteritems(self.logger): + logger.addHandler(self.logger_stream_handler) + if self.logger_file_handler: + logger.removeHandler(self.logger_file_handler) + + @property + def debug(self): + """Debug status + + :param value: The debug status, True or False. + :type: bool + """ + return self.__debug + + @debug.setter + def debug(self, value): + """Debug status + + :param value: The debug status, True or False. + :type: bool + """ + self.__debug = value + if self.__debug: + # if debug status is True, turn on debug logging + for _, logger in six.iteritems(self.logger): + logger.setLevel(logging.DEBUG) + # turn on httplib debug + httplib.HTTPConnection.debuglevel = 1 + else: + # if debug status is False, turn off debug logging, + # setting log level to default `logging.WARNING` + for _, logger in six.iteritems(self.logger): + logger.setLevel(logging.WARNING) + # turn off httplib debug + httplib.HTTPConnection.debuglevel = 0 + + @property + def logger_format(self): + """The logger format. + + The logger_formatter will be updated when sets logger_format. + + :param value: The format string. + :type: str + """ + return self.__logger_format + + @logger_format.setter + def logger_format(self, value): + """The logger format. + + The logger_formatter will be updated when sets logger_format. + + :param value: The format string. + :type: str + """ + self.__logger_format = value + self.logger_formatter = logging.Formatter(self.__logger_format) + + def get_api_key_with_prefix(self, identifier): + """Gets API key (with prefix if set). + + :param identifier: The identifier of apiKey. + :return: The token for api key authentication. + """ + if (self.api_key.get(identifier) and + self.api_key_prefix.get(identifier)): + return self.api_key_prefix[identifier] + ' ' + self.api_key[identifier] # noqa: E501 + elif self.api_key.get(identifier): + return self.api_key[identifier] + + def auth_settings(self): + """Gets Auth Settings dict for api client. + + :return: The Auth Settings information dict. + """ + return { + + } + + def to_debug_report(self): + """Gets the essential information for debugging. + + :return: The report for debugging. + """ + return "Python SDK Debug Report:\n"\ + "OS: {env}\n"\ + "Python Version: {pyversion}\n"\ + "Version of the API: 1.0.0\n"\ + "SDK Package Version: 1.0.0".\ + format(env=sys.platform, pyversion=sys.version) diff --git a/amazon/paapi5_python_sdk/content_info.py b/amazon/paapi5_python_sdk/content_info.py new file mode 100644 index 0000000..b46e244 --- /dev/null +++ b/amazon/paapi5_python_sdk/content_info.py @@ -0,0 +1,208 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .languages import Languages # noqa: F401,E501 +from .single_integer_valued_attribute import SingleIntegerValuedAttribute # noqa: F401,E501 +from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 + + +class ContentInfo(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 = { + 'edition': 'SingleStringValuedAttribute', + 'languages': 'Languages', + 'pages_count': 'SingleIntegerValuedAttribute', + 'publication_date': 'SingleStringValuedAttribute' + } + + attribute_map = { + 'edition': 'Edition', + 'languages': 'Languages', + 'pages_count': 'PagesCount', + 'publication_date': 'PublicationDate' + } + + def __init__(self, edition=None, languages=None, pages_count=None, publication_date=None): # noqa: E501 + """ContentInfo - a model defined in Swagger""" # noqa: E501 + + self._edition = None + self._languages = None + self._pages_count = None + self._publication_date = None + self.discriminator = None + + if edition is not None: + self.edition = edition + if languages is not None: + self.languages = languages + if pages_count is not None: + self.pages_count = pages_count + if publication_date is not None: + self.publication_date = publication_date + + @property + def edition(self): + """Gets the edition of this ContentInfo. # noqa: E501 + + + :return: The edition of this ContentInfo. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._edition + + @edition.setter + def edition(self, edition): + """Sets the edition of this ContentInfo. + + + :param edition: The edition of this ContentInfo. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._edition = edition + + @property + def languages(self): + """Gets the languages of this ContentInfo. # noqa: E501 + + + :return: The languages of this ContentInfo. # noqa: E501 + :rtype: Languages + """ + return self._languages + + @languages.setter + def languages(self, languages): + """Sets the languages of this ContentInfo. + + + :param languages: The languages of this ContentInfo. # noqa: E501 + :type: Languages + """ + + self._languages = languages + + @property + def pages_count(self): + """Gets the pages_count of this ContentInfo. # noqa: E501 + + + :return: The pages_count of this ContentInfo. # noqa: E501 + :rtype: SingleIntegerValuedAttribute + """ + return self._pages_count + + @pages_count.setter + def pages_count(self, pages_count): + """Sets the pages_count of this ContentInfo. + + + :param pages_count: The pages_count of this ContentInfo. # noqa: E501 + :type: SingleIntegerValuedAttribute + """ + + self._pages_count = pages_count + + @property + def publication_date(self): + """Gets the publication_date of this ContentInfo. # noqa: E501 + + + :return: The publication_date of this ContentInfo. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._publication_date + + @publication_date.setter + def publication_date(self, publication_date): + """Sets the publication_date of this ContentInfo. + + + :param publication_date: The publication_date of this ContentInfo. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._publication_date = publication_date + + 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(ContentInfo, 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, ContentInfo): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/content_rating.py b/amazon/paapi5_python_sdk/content_rating.py new file mode 100644 index 0000000..10ac8f0 --- /dev/null +++ b/amazon/paapi5_python_sdk/content_rating.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 + + +class ContentRating(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 = { + 'audience_rating': 'SingleStringValuedAttribute' + } + + attribute_map = { + 'audience_rating': 'AudienceRating' + } + + def __init__(self, audience_rating=None): # noqa: E501 + """ContentRating - a model defined in Swagger""" # noqa: E501 + + self._audience_rating = None + self.discriminator = None + + if audience_rating is not None: + self.audience_rating = audience_rating + + @property + def audience_rating(self): + """Gets the audience_rating of this ContentRating. # noqa: E501 + + + :return: The audience_rating of this ContentRating. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._audience_rating + + @audience_rating.setter + def audience_rating(self, audience_rating): + """Sets the audience_rating of this ContentRating. + + + :param audience_rating: The audience_rating of this ContentRating. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._audience_rating = audience_rating + + 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(ContentRating, 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, ContentRating): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/contributor.py b/amazon/paapi5_python_sdk/contributor.py new file mode 100644 index 0000000..1b1f30e --- /dev/null +++ b/amazon/paapi5_python_sdk/contributor.py @@ -0,0 +1,178 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class Contributor(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 = { + 'locale': 'str', + 'name': 'str', + 'role': 'str' + } + + attribute_map = { + 'locale': 'Locale', + 'name': 'Name', + 'role': 'Role' + } + + def __init__(self, locale=None, name=None, role=None): # noqa: E501 + """Contributor - a model defined in Swagger""" # noqa: E501 + + self._locale = None + self._name = None + self._role = None + self.discriminator = None + + if locale is not None: + self.locale = locale + if name is not None: + self.name = name + if role is not None: + self.role = role + + @property + def locale(self): + """Gets the locale of this Contributor. # noqa: E501 + + + :return: The locale of this Contributor. # noqa: E501 + :rtype: str + """ + return self._locale + + @locale.setter + def locale(self, locale): + """Sets the locale of this Contributor. + + + :param locale: The locale of this Contributor. # noqa: E501 + :type: str + """ + + self._locale = locale + + @property + def name(self): + """Gets the name of this Contributor. # noqa: E501 + + + :return: The name of this Contributor. # noqa: E501 + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """Sets the name of this Contributor. + + + :param name: The name of this Contributor. # noqa: E501 + :type: str + """ + + self._name = name + + @property + def role(self): + """Gets the role of this Contributor. # noqa: E501 + + + :return: The role of this Contributor. # noqa: E501 + :rtype: str + """ + return self._role + + @role.setter + def role(self, role): + """Sets the role of this Contributor. + + + :param role: The role of this Contributor. # noqa: E501 + :type: str + """ + + self._role = role + + 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(Contributor, 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, Contributor): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/delivery_flag.py b/amazon/paapi5_python_sdk/delivery_flag.py new file mode 100644 index 0000000..1f0c469 --- /dev/null +++ b/amazon/paapi5_python_sdk/delivery_flag.py @@ -0,0 +1,106 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class DeliveryFlag(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + allowed enum values + """ + AMAZONGLOBAL = "AmazonGlobal" + FREESHIPPING = "FreeShipping" + FULFILLEDBYAMAZON = "FulfilledByAmazon" + PRIME = "Prime" + + """ + 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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """DeliveryFlag - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(DeliveryFlag, 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, DeliveryFlag): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/dimension_based_attribute.py b/amazon/paapi5_python_sdk/dimension_based_attribute.py new file mode 100644 index 0000000..04cc4f7 --- /dev/null +++ b/amazon/paapi5_python_sdk/dimension_based_attribute.py @@ -0,0 +1,206 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .unit_based_attribute import UnitBasedAttribute # noqa: F401,E501 + + +class DimensionBasedAttribute(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 = { + 'height': 'UnitBasedAttribute', + 'length': 'UnitBasedAttribute', + 'weight': 'UnitBasedAttribute', + 'width': 'UnitBasedAttribute' + } + + attribute_map = { + 'height': 'Height', + 'length': 'Length', + 'weight': 'Weight', + 'width': 'Width' + } + + def __init__(self, height=None, length=None, weight=None, width=None): # noqa: E501 + """DimensionBasedAttribute - a model defined in Swagger""" # noqa: E501 + + self._height = None + self._length = None + self._weight = None + self._width = None + self.discriminator = None + + if height is not None: + self.height = height + if length is not None: + self.length = length + if weight is not None: + self.weight = weight + if width is not None: + self.width = width + + @property + def height(self): + """Gets the height of this DimensionBasedAttribute. # noqa: E501 + + + :return: The height of this DimensionBasedAttribute. # noqa: E501 + :rtype: UnitBasedAttribute + """ + return self._height + + @height.setter + def height(self, height): + """Sets the height of this DimensionBasedAttribute. + + + :param height: The height of this DimensionBasedAttribute. # noqa: E501 + :type: UnitBasedAttribute + """ + + self._height = height + + @property + def length(self): + """Gets the length of this DimensionBasedAttribute. # noqa: E501 + + + :return: The length of this DimensionBasedAttribute. # noqa: E501 + :rtype: UnitBasedAttribute + """ + return self._length + + @length.setter + def length(self, length): + """Sets the length of this DimensionBasedAttribute. + + + :param length: The length of this DimensionBasedAttribute. # noqa: E501 + :type: UnitBasedAttribute + """ + + self._length = length + + @property + def weight(self): + """Gets the weight of this DimensionBasedAttribute. # noqa: E501 + + + :return: The weight of this DimensionBasedAttribute. # noqa: E501 + :rtype: UnitBasedAttribute + """ + return self._weight + + @weight.setter + def weight(self, weight): + """Sets the weight of this DimensionBasedAttribute. + + + :param weight: The weight of this DimensionBasedAttribute. # noqa: E501 + :type: UnitBasedAttribute + """ + + self._weight = weight + + @property + def width(self): + """Gets the width of this DimensionBasedAttribute. # noqa: E501 + + + :return: The width of this DimensionBasedAttribute. # noqa: E501 + :rtype: UnitBasedAttribute + """ + return self._width + + @width.setter + def width(self, width): + """Sets the width of this DimensionBasedAttribute. + + + :param width: The width of this DimensionBasedAttribute. # noqa: E501 + :type: UnitBasedAttribute + """ + + self._width = width + + 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(DimensionBasedAttribute, 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, DimensionBasedAttribute): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/duration_price.py b/amazon/paapi5_python_sdk/duration_price.py new file mode 100644 index 0000000..724fe4b --- /dev/null +++ b/amazon/paapi5_python_sdk/duration_price.py @@ -0,0 +1,155 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .offer_price import OfferPrice # noqa: F401,E501 +from .unit_based_attribute import UnitBasedAttribute # noqa: F401,E501 + + +class DurationPrice(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 = { + 'price': 'OfferPrice', + 'duration': 'UnitBasedAttribute' + } + + attribute_map = { + 'price': 'Price', + 'duration': 'Duration' + } + + def __init__(self, price=None, duration=None): # noqa: E501 + """DurationPrice - a model defined in Swagger""" # noqa: E501 + + self._price = None + self._duration = None + self.discriminator = None + + if price is not None: + self.price = price + if duration is not None: + self.duration = duration + + @property + def price(self): + """Gets the price of this DurationPrice. # noqa: E501 + + + :return: The price of this DurationPrice. # noqa: E501 + :rtype: OfferPrice + """ + return self._price + + @price.setter + def price(self, price): + """Sets the price of this DurationPrice. + + + :param price: The price of this DurationPrice. # noqa: E501 + :type: OfferPrice + """ + + self._price = price + + @property + def duration(self): + """Gets the duration of this DurationPrice. # noqa: E501 + + + :return: The duration of this DurationPrice. # noqa: E501 + :rtype: UnitBasedAttribute + """ + return self._duration + + @duration.setter + def duration(self, duration): + """Sets the duration of this DurationPrice. + + + :param duration: The duration of this DurationPrice. # noqa: E501 + :type: UnitBasedAttribute + """ + + self._duration = duration + + 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(DurationPrice, 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, DurationPrice): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/error_data.py b/amazon/paapi5_python_sdk/error_data.py new file mode 100644 index 0000000..3d6b106 --- /dev/null +++ b/amazon/paapi5_python_sdk/error_data.py @@ -0,0 +1,152 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class ErrorData(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 = { + 'code': 'str', + 'message': 'str' + } + + attribute_map = { + 'code': 'Code', + 'message': 'Message' + } + + def __init__(self, code=None, message=None): # noqa: E501 + """ErrorData - a model defined in Swagger""" # noqa: E501 + + self._code = None + self._message = None + self.discriminator = None + + if code is not None: + self.code = code + if message is not None: + self.message = message + + @property + def code(self): + """Gets the code of this ErrorData. # noqa: E501 + + + :return: The code of this ErrorData. # noqa: E501 + :rtype: str + """ + return self._code + + @code.setter + def code(self, code): + """Sets the code of this ErrorData. + + + :param code: The code of this ErrorData. # noqa: E501 + :type: str + """ + + self._code = code + + @property + def message(self): + """Gets the message of this ErrorData. # noqa: E501 + + + :return: The message of this ErrorData. # noqa: E501 + :rtype: str + """ + return self._message + + @message.setter + def message(self, message): + """Sets the message of this ErrorData. + + + :param message: The message of this ErrorData. # noqa: E501 + :type: str + """ + + self._message = message + + 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(ErrorData, 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, ErrorData): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/external_ids.py b/amazon/paapi5_python_sdk/external_ids.py new file mode 100644 index 0000000..ff545a7 --- /dev/null +++ b/amazon/paapi5_python_sdk/external_ids.py @@ -0,0 +1,180 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .multi_valued_attribute import MultiValuedAttribute # noqa: F401,E501 + + +class ExternalIds(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 = { + 'ea_ns': 'MultiValuedAttribute', + 'isb_ns': 'MultiValuedAttribute', + 'up_cs': 'MultiValuedAttribute' + } + + attribute_map = { + 'ea_ns': 'EANs', + 'isb_ns': 'ISBNs', + 'up_cs': 'UPCs' + } + + def __init__(self, ea_ns=None, isb_ns=None, up_cs=None): # noqa: E501 + """ExternalIds - a model defined in Swagger""" # noqa: E501 + + self._ea_ns = None + self._isb_ns = None + self._up_cs = None + self.discriminator = None + + if ea_ns is not None: + self.ea_ns = ea_ns + if isb_ns is not None: + self.isb_ns = isb_ns + if up_cs is not None: + self.up_cs = up_cs + + @property + def ea_ns(self): + """Gets the ea_ns of this ExternalIds. # noqa: E501 + + + :return: The ea_ns of this ExternalIds. # noqa: E501 + :rtype: MultiValuedAttribute + """ + return self._ea_ns + + @ea_ns.setter + def ea_ns(self, ea_ns): + """Sets the ea_ns of this ExternalIds. + + + :param ea_ns: The ea_ns of this ExternalIds. # noqa: E501 + :type: MultiValuedAttribute + """ + + self._ea_ns = ea_ns + + @property + def isb_ns(self): + """Gets the isb_ns of this ExternalIds. # noqa: E501 + + + :return: The isb_ns of this ExternalIds. # noqa: E501 + :rtype: MultiValuedAttribute + """ + return self._isb_ns + + @isb_ns.setter + def isb_ns(self, isb_ns): + """Sets the isb_ns of this ExternalIds. + + + :param isb_ns: The isb_ns of this ExternalIds. # noqa: E501 + :type: MultiValuedAttribute + """ + + self._isb_ns = isb_ns + + @property + def up_cs(self): + """Gets the up_cs of this ExternalIds. # noqa: E501 + + + :return: The up_cs of this ExternalIds. # noqa: E501 + :rtype: MultiValuedAttribute + """ + return self._up_cs + + @up_cs.setter + def up_cs(self, up_cs): + """Sets the up_cs of this ExternalIds. + + + :param up_cs: The up_cs of this ExternalIds. # noqa: E501 + :type: MultiValuedAttribute + """ + + self._up_cs = up_cs + + 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(ExternalIds, 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, ExternalIds): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/get_browse_nodes_request.py b/amazon/paapi5_python_sdk/get_browse_nodes_request.py new file mode 100644 index 0000000..6d5d57b --- /dev/null +++ b/amazon/paapi5_python_sdk/get_browse_nodes_request.py @@ -0,0 +1,262 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .get_browse_nodes_resource import GetBrowseNodesResource # noqa: F401,E501 +from .partner_type import PartnerType # noqa: F401,E501 + + +class GetBrowseNodesRequest(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 = { + 'browse_node_ids': 'list[str]', + 'languages_of_preference': 'list[str]', + 'marketplace': 'str', + 'partner_tag': 'str', + 'partner_type': 'PartnerType', + 'resources': 'list[GetBrowseNodesResource]' + } + + attribute_map = { + 'browse_node_ids': 'BrowseNodeIds', + 'languages_of_preference': 'LanguagesOfPreference', + 'marketplace': 'Marketplace', + 'partner_tag': 'PartnerTag', + 'partner_type': 'PartnerType', + 'resources': 'Resources' + } + + def __init__(self, browse_node_ids=None, languages_of_preference=None, marketplace=None, partner_tag=None, partner_type=None, resources=None): # noqa: E501 + """GetBrowseNodesRequest - a model defined in Swagger""" # noqa: E501 + + self._browse_node_ids = None + self._languages_of_preference = None + self._marketplace = None + self._partner_tag = None + self._partner_type = None + self._resources = None + self.discriminator = None + + self.browse_node_ids = browse_node_ids + if languages_of_preference is not None: + self.languages_of_preference = languages_of_preference + if marketplace is not None: + self.marketplace = marketplace + self.partner_tag = partner_tag + self.partner_type = partner_type + if resources is not None: + self.resources = resources + + @property + def browse_node_ids(self): + """Gets the browse_node_ids of this GetBrowseNodesRequest. # noqa: E501 + + + :return: The browse_node_ids of this GetBrowseNodesRequest. # noqa: E501 + :rtype: list[str] + """ + return self._browse_node_ids + + @browse_node_ids.setter + def browse_node_ids(self, browse_node_ids): + """Sets the browse_node_ids of this GetBrowseNodesRequest. + + + :param browse_node_ids: The browse_node_ids of this GetBrowseNodesRequest. # noqa: E501 + :type: list[str] + """ + if browse_node_ids is None: + raise ValueError("Invalid value for `browse_node_ids`, must not be `None`") # noqa: E501 + + self._browse_node_ids = browse_node_ids + + @property + def languages_of_preference(self): + """Gets the languages_of_preference of this GetBrowseNodesRequest. # noqa: E501 + + + :return: The languages_of_preference of this GetBrowseNodesRequest. # noqa: E501 + :rtype: list[str] + """ + return self._languages_of_preference + + @languages_of_preference.setter + def languages_of_preference(self, languages_of_preference): + """Sets the languages_of_preference of this GetBrowseNodesRequest. + + + :param languages_of_preference: The languages_of_preference of this GetBrowseNodesRequest. # noqa: E501 + :type: list[str] + """ + + self._languages_of_preference = languages_of_preference + + @property + def marketplace(self): + """Gets the marketplace of this GetBrowseNodesRequest. # noqa: E501 + + + :return: The marketplace of this GetBrowseNodesRequest. # noqa: E501 + :rtype: str + """ + return self._marketplace + + @marketplace.setter + def marketplace(self, marketplace): + """Sets the marketplace of this GetBrowseNodesRequest. + + + :param marketplace: The marketplace of this GetBrowseNodesRequest. # noqa: E501 + :type: str + """ + + self._marketplace = marketplace + + @property + def partner_tag(self): + """Gets the partner_tag of this GetBrowseNodesRequest. # noqa: E501 + + + :return: The partner_tag of this GetBrowseNodesRequest. # noqa: E501 + :rtype: str + """ + return self._partner_tag + + @partner_tag.setter + def partner_tag(self, partner_tag): + """Sets the partner_tag of this GetBrowseNodesRequest. + + + :param partner_tag: The partner_tag of this GetBrowseNodesRequest. # noqa: E501 + :type: str + """ + if partner_tag is None: + raise ValueError("Invalid value for `partner_tag`, must not be `None`") # noqa: E501 + + self._partner_tag = partner_tag + + @property + def partner_type(self): + """Gets the partner_type of this GetBrowseNodesRequest. # noqa: E501 + + + :return: The partner_type of this GetBrowseNodesRequest. # noqa: E501 + :rtype: PartnerType + """ + return self._partner_type + + @partner_type.setter + def partner_type(self, partner_type): + """Sets the partner_type of this GetBrowseNodesRequest. + + + :param partner_type: The partner_type of this GetBrowseNodesRequest. # noqa: E501 + :type: PartnerType + """ + if partner_type is None: + raise ValueError("Invalid value for `partner_type`, must not be `None`") # noqa: E501 + + self._partner_type = partner_type + + @property + def resources(self): + """Gets the resources of this GetBrowseNodesRequest. # noqa: E501 + + + :return: The resources of this GetBrowseNodesRequest. # noqa: E501 + :rtype: list[GetBrowseNodesResource] + """ + return self._resources + + @resources.setter + def resources(self, resources): + """Sets the resources of this GetBrowseNodesRequest. + + + :param resources: The resources of this GetBrowseNodesRequest. # noqa: E501 + :type: list[GetBrowseNodesResource] + """ + + self._resources = resources + + 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(GetBrowseNodesRequest, 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, GetBrowseNodesRequest): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/get_browse_nodes_resource.py b/amazon/paapi5_python_sdk/get_browse_nodes_resource.py new file mode 100644 index 0000000..4e7ff94 --- /dev/null +++ b/amazon/paapi5_python_sdk/get_browse_nodes_resource.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class GetBrowseNodesResource(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + allowed enum values + """ + ANCESTOR = "BrowseNodes.Ancestor" + CHILDREN = "BrowseNodes.Children" + + """ + 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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """GetBrowseNodesResource - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(GetBrowseNodesResource, 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, GetBrowseNodesResource): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/get_browse_nodes_response.py b/amazon/paapi5_python_sdk/get_browse_nodes_response.py new file mode 100644 index 0000000..10e0a21 --- /dev/null +++ b/amazon/paapi5_python_sdk/get_browse_nodes_response.py @@ -0,0 +1,155 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .browse_nodes_result import BrowseNodesResult # noqa: F401,E501 +from .error_data import ErrorData # noqa: F401,E501 + + +class GetBrowseNodesResponse(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 = { + 'browse_nodes_result': 'BrowseNodesResult', + 'errors': 'list[ErrorData]' + } + + attribute_map = { + 'browse_nodes_result': 'BrowseNodesResult', + 'errors': 'Errors' + } + + def __init__(self, browse_nodes_result=None, errors=None): # noqa: E501 + """GetBrowseNodesResponse - a model defined in Swagger""" # noqa: E501 + + self._browse_nodes_result = None + self._errors = None + self.discriminator = None + + if browse_nodes_result is not None: + self.browse_nodes_result = browse_nodes_result + if errors is not None: + self.errors = errors + + @property + def browse_nodes_result(self): + """Gets the browse_nodes_result of this GetBrowseNodesResponse. # noqa: E501 + + + :return: The browse_nodes_result of this GetBrowseNodesResponse. # noqa: E501 + :rtype: BrowseNodesResult + """ + return self._browse_nodes_result + + @browse_nodes_result.setter + def browse_nodes_result(self, browse_nodes_result): + """Sets the browse_nodes_result of this GetBrowseNodesResponse. + + + :param browse_nodes_result: The browse_nodes_result of this GetBrowseNodesResponse. # noqa: E501 + :type: BrowseNodesResult + """ + + self._browse_nodes_result = browse_nodes_result + + @property + def errors(self): + """Gets the errors of this GetBrowseNodesResponse. # noqa: E501 + + + :return: The errors of this GetBrowseNodesResponse. # noqa: E501 + :rtype: list[ErrorData] + """ + return self._errors + + @errors.setter + def errors(self, errors): + """Sets the errors of this GetBrowseNodesResponse. + + + :param errors: The errors of this GetBrowseNodesResponse. # noqa: E501 + :type: list[ErrorData] + """ + + self._errors = errors + + 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(GetBrowseNodesResponse, 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, GetBrowseNodesResponse): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/get_items_request.py b/amazon/paapi5_python_sdk/get_items_request.py new file mode 100644 index 0000000..567ba65 --- /dev/null +++ b/amazon/paapi5_python_sdk/get_items_request.py @@ -0,0 +1,423 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .condition import Condition # noqa: F401,E501 +from .get_items_resource import GetItemsResource # noqa: F401,E501 +from .item_id_type import ItemIdType # noqa: F401,E501 +from .merchant import Merchant # noqa: F401,E501 +from .offer_count import OfferCount # noqa: F401,E501 +from .partner_type import PartnerType # noqa: F401,E501 +from .properties import Properties # noqa: F401,E501 + + +class GetItemsRequest(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 = { + 'condition': 'Condition', + 'currency_of_preference': 'str', + 'item_ids': 'list[str]', + 'item_id_type': 'ItemIdType', + 'languages_of_preference': 'list[str]', + 'marketplace': 'str', + 'merchant': 'Merchant', + 'offer_count': 'OfferCount', + 'partner_tag': 'str', + 'partner_type': 'PartnerType', + 'properties': 'Properties', + 'resources': 'list[GetItemsResource]' + } + + attribute_map = { + 'condition': 'Condition', + 'currency_of_preference': 'CurrencyOfPreference', + 'item_ids': 'ItemIds', + 'item_id_type': 'ItemIdType', + 'languages_of_preference': 'LanguagesOfPreference', + 'marketplace': 'Marketplace', + 'merchant': 'Merchant', + 'offer_count': 'OfferCount', + 'partner_tag': 'PartnerTag', + 'partner_type': 'PartnerType', + 'properties': 'Properties', + 'resources': 'Resources' + } + + def __init__(self, condition=None, currency_of_preference=None, item_ids=None, item_id_type=None, languages_of_preference=None, marketplace=None, merchant=None, offer_count=None, partner_tag=None, partner_type=None, properties=None, resources=None): # noqa: E501 + """GetItemsRequest - a model defined in Swagger""" # noqa: E501 + + self._condition = None + self._currency_of_preference = None + self._item_ids = None + self._item_id_type = None + self._languages_of_preference = None + self._marketplace = None + self._merchant = None + self._offer_count = None + self._partner_tag = None + self._partner_type = None + self._properties = None + self._resources = None + self.discriminator = None + + if condition is not None: + self.condition = condition + if currency_of_preference is not None: + self.currency_of_preference = currency_of_preference + self.item_ids = item_ids + if item_id_type is not None: + self.item_id_type = item_id_type + if languages_of_preference is not None: + self.languages_of_preference = languages_of_preference + if marketplace is not None: + self.marketplace = marketplace + if merchant is not None: + self.merchant = merchant + if offer_count is not None: + self.offer_count = offer_count + self.partner_tag = partner_tag + self.partner_type = partner_type + if properties is not None: + self.properties = properties + if resources is not None: + self.resources = resources + + @property + def condition(self): + """Gets the condition of this GetItemsRequest. # noqa: E501 + + + :return: The condition of this GetItemsRequest. # noqa: E501 + :rtype: Condition + """ + return self._condition + + @condition.setter + def condition(self, condition): + """Sets the condition of this GetItemsRequest. + + + :param condition: The condition of this GetItemsRequest. # noqa: E501 + :type: Condition + """ + + self._condition = condition + + @property + def currency_of_preference(self): + """Gets the currency_of_preference of this GetItemsRequest. # noqa: E501 + + + :return: The currency_of_preference of this GetItemsRequest. # noqa: E501 + :rtype: str + """ + return self._currency_of_preference + + @currency_of_preference.setter + def currency_of_preference(self, currency_of_preference): + """Sets the currency_of_preference of this GetItemsRequest. + + + :param currency_of_preference: The currency_of_preference of this GetItemsRequest. # noqa: E501 + :type: str + """ + + self._currency_of_preference = currency_of_preference + + @property + def item_ids(self): + """Gets the item_ids of this GetItemsRequest. # noqa: E501 + + + :return: The item_ids of this GetItemsRequest. # noqa: E501 + :rtype: list[str] + """ + return self._item_ids + + @item_ids.setter + def item_ids(self, item_ids): + """Sets the item_ids of this GetItemsRequest. + + + :param item_ids: The item_ids of this GetItemsRequest. # noqa: E501 + :type: list[str] + """ + if item_ids is None: + raise ValueError("Invalid value for `item_ids`, must not be `None`") # noqa: E501 + + self._item_ids = item_ids + + @property + def item_id_type(self): + """Gets the item_id_type of this GetItemsRequest. # noqa: E501 + + + :return: The item_id_type of this GetItemsRequest. # noqa: E501 + :rtype: ItemIdType + """ + return self._item_id_type + + @item_id_type.setter + def item_id_type(self, item_id_type): + """Sets the item_id_type of this GetItemsRequest. + + + :param item_id_type: The item_id_type of this GetItemsRequest. # noqa: E501 + :type: ItemIdType + """ + + self._item_id_type = item_id_type + + @property + def languages_of_preference(self): + """Gets the languages_of_preference of this GetItemsRequest. # noqa: E501 + + + :return: The languages_of_preference of this GetItemsRequest. # noqa: E501 + :rtype: list[str] + """ + return self._languages_of_preference + + @languages_of_preference.setter + def languages_of_preference(self, languages_of_preference): + """Sets the languages_of_preference of this GetItemsRequest. + + + :param languages_of_preference: The languages_of_preference of this GetItemsRequest. # noqa: E501 + :type: list[str] + """ + + self._languages_of_preference = languages_of_preference + + @property + def marketplace(self): + """Gets the marketplace of this GetItemsRequest. # noqa: E501 + + + :return: The marketplace of this GetItemsRequest. # noqa: E501 + :rtype: str + """ + return self._marketplace + + @marketplace.setter + def marketplace(self, marketplace): + """Sets the marketplace of this GetItemsRequest. + + + :param marketplace: The marketplace of this GetItemsRequest. # noqa: E501 + :type: str + """ + + self._marketplace = marketplace + + @property + def merchant(self): + """Gets the merchant of this GetItemsRequest. # noqa: E501 + + + :return: The merchant of this GetItemsRequest. # noqa: E501 + :rtype: Merchant + """ + return self._merchant + + @merchant.setter + def merchant(self, merchant): + """Sets the merchant of this GetItemsRequest. + + + :param merchant: The merchant of this GetItemsRequest. # noqa: E501 + :type: Merchant + """ + + self._merchant = merchant + + @property + def offer_count(self): + """Gets the offer_count of this GetItemsRequest. # noqa: E501 + + + :return: The offer_count of this GetItemsRequest. # noqa: E501 + :rtype: OfferCount + """ + return self._offer_count + + @offer_count.setter + def offer_count(self, offer_count): + """Sets the offer_count of this GetItemsRequest. + + + :param offer_count: The offer_count of this GetItemsRequest. # noqa: E501 + :type: OfferCount + """ + + self._offer_count = offer_count + + @property + def partner_tag(self): + """Gets the partner_tag of this GetItemsRequest. # noqa: E501 + + + :return: The partner_tag of this GetItemsRequest. # noqa: E501 + :rtype: str + """ + return self._partner_tag + + @partner_tag.setter + def partner_tag(self, partner_tag): + """Sets the partner_tag of this GetItemsRequest. + + + :param partner_tag: The partner_tag of this GetItemsRequest. # noqa: E501 + :type: str + """ + if partner_tag is None: + raise ValueError("Invalid value for `partner_tag`, must not be `None`") # noqa: E501 + + self._partner_tag = partner_tag + + @property + def partner_type(self): + """Gets the partner_type of this GetItemsRequest. # noqa: E501 + + + :return: The partner_type of this GetItemsRequest. # noqa: E501 + :rtype: PartnerType + """ + return self._partner_type + + @partner_type.setter + def partner_type(self, partner_type): + """Sets the partner_type of this GetItemsRequest. + + + :param partner_type: The partner_type of this GetItemsRequest. # noqa: E501 + :type: PartnerType + """ + if partner_type is None: + raise ValueError("Invalid value for `partner_type`, must not be `None`") # noqa: E501 + + self._partner_type = partner_type + + @property + def properties(self): + """Gets the properties of this GetItemsRequest. # noqa: E501 + + + :return: The properties of this GetItemsRequest. # noqa: E501 + :rtype: Properties + """ + return self._properties + + @properties.setter + def properties(self, properties): + """Sets the properties of this GetItemsRequest. + + + :param properties: The properties of this GetItemsRequest. # noqa: E501 + :type: Properties + """ + + self._properties = properties + + @property + def resources(self): + """Gets the resources of this GetItemsRequest. # noqa: E501 + + + :return: The resources of this GetItemsRequest. # noqa: E501 + :rtype: list[GetItemsResource] + """ + return self._resources + + @resources.setter + def resources(self, resources): + """Sets the resources of this GetItemsRequest. + + + :param resources: The resources of this GetItemsRequest. # noqa: E501 + :type: list[GetItemsResource] + """ + + self._resources = resources + + 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(GetItemsRequest, 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, GetItemsRequest): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/get_items_resource.py b/amazon/paapi5_python_sdk/get_items_resource.py new file mode 100644 index 0000000..b0ddcc5 --- /dev/null +++ b/amazon/paapi5_python_sdk/get_items_resource.py @@ -0,0 +1,157 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class GetItemsResource(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + allowed enum values + """ + BROWSENODEINFO_BROWSENODES = "BrowseNodeInfo.BrowseNodes" + BROWSENODEINFO_BROWSENODES_ANCESTOR = "BrowseNodeInfo.BrowseNodes.Ancestor" + BROWSENODEINFO_BROWSENODES_SALESRANK = "BrowseNodeInfo.BrowseNodes.SalesRank" + BROWSENODEINFO_WEBSITESALESRANK = "BrowseNodeInfo.WebsiteSalesRank" + IMAGES_PRIMARY_SMALL = "Images.Primary.Small" + IMAGES_PRIMARY_MEDIUM = "Images.Primary.Medium" + IMAGES_PRIMARY_LARGE = "Images.Primary.Large" + IMAGES_VARIANTS_SMALL = "Images.Variants.Small" + IMAGES_VARIANTS_MEDIUM = "Images.Variants.Medium" + IMAGES_VARIANTS_LARGE = "Images.Variants.Large" + ITEMINFO_BYLINEINFO = "ItemInfo.ByLineInfo" + ITEMINFO_CONTENTINFO = "ItemInfo.ContentInfo" + ITEMINFO_CONTENTRATING = "ItemInfo.ContentRating" + ITEMINFO_CLASSIFICATIONS = "ItemInfo.Classifications" + ITEMINFO_EXTERNALIDS = "ItemInfo.ExternalIds" + ITEMINFO_FEATURES = "ItemInfo.Features" + ITEMINFO_MANUFACTUREINFO = "ItemInfo.ManufactureInfo" + ITEMINFO_PRODUCTINFO = "ItemInfo.ProductInfo" + ITEMINFO_TECHNICALINFO = "ItemInfo.TechnicalInfo" + ITEMINFO_TITLE = "ItemInfo.Title" + ITEMINFO_TRADEININFO = "ItemInfo.TradeInInfo" + OFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY = "Offers.Listings.Availability.MaxOrderQuantity" + OFFERS_LISTINGS_AVAILABILITY_MESSAGE = "Offers.Listings.Availability.Message" + OFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY = "Offers.Listings.Availability.MinOrderQuantity" + OFFERS_LISTINGS_AVAILABILITY_TYPE = "Offers.Listings.Availability.Type" + OFFERS_LISTINGS_CONDITION = "Offers.Listings.Condition" + OFFERS_LISTINGS_CONDITION_SUBCONDITION = "Offers.Listings.Condition.SubCondition" + OFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED = "Offers.Listings.DeliveryInfo.IsAmazonFulfilled" + OFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE = "Offers.Listings.DeliveryInfo.IsFreeShippingEligible" + OFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE = "Offers.Listings.DeliveryInfo.IsPrimeEligible" + OFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES = "Offers.Listings.DeliveryInfo.ShippingCharges" + OFFERS_LISTINGS_ISBUYBOXWINNER = "Offers.Listings.IsBuyBoxWinner" + OFFERS_LISTINGS_LOYALTYPOINTS_POINTS = "Offers.Listings.LoyaltyPoints.Points" + OFFERS_LISTINGS_MERCHANTINFO = "Offers.Listings.MerchantInfo" + OFFERS_LISTINGS_PRICE = "Offers.Listings.Price" + OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEEXCLUSIVE = "Offers.Listings.ProgramEligibility.IsPrimeExclusive" + OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEPANTRY = "Offers.Listings.ProgramEligibility.IsPrimePantry" + OFFERS_LISTINGS_PROMOTIONS = "Offers.Listings.Promotions" + OFFERS_LISTINGS_SAVINGBASIS = "Offers.Listings.SavingBasis" + OFFERS_SUMMARIES_HIGHESTPRICE = "Offers.Summaries.HighestPrice" + OFFERS_SUMMARIES_LOWESTPRICE = "Offers.Summaries.LowestPrice" + OFFERS_SUMMARIES_OFFERCOUNT = "Offers.Summaries.OfferCount" + PARENTASIN = "ParentASIN" + RENTALOFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY = "RentalOffers.Listings.Availability.MaxOrderQuantity" + RENTALOFFERS_LISTINGS_AVAILABILITY_MESSAGE = "RentalOffers.Listings.Availability.Message" + RENTALOFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY = "RentalOffers.Listings.Availability.MinOrderQuantity" + RENTALOFFERS_LISTINGS_AVAILABILITY_TYPE = "RentalOffers.Listings.Availability.Type" + RENTALOFFERS_LISTINGS_BASEPRICE = "RentalOffers.Listings.BasePrice" + RENTALOFFERS_LISTINGS_CONDITION = "RentalOffers.Listings.Condition" + RENTALOFFERS_LISTINGS_CONDITION_SUBCONDITION = "RentalOffers.Listings.Condition.SubCondition" + RENTALOFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED = "RentalOffers.Listings.DeliveryInfo.IsAmazonFulfilled" + RENTALOFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE = "RentalOffers.Listings.DeliveryInfo.IsFreeShippingEligible" + RENTALOFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE = "RentalOffers.Listings.DeliveryInfo.IsPrimeEligible" + RENTALOFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES = "RentalOffers.Listings.DeliveryInfo.ShippingCharges" + RENTALOFFERS_LISTINGS_MERCHANTINFO = "RentalOffers.Listings.MerchantInfo" + + """ + 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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """GetItemsResource - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(GetItemsResource, 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, GetItemsResource): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/get_items_response.py b/amazon/paapi5_python_sdk/get_items_response.py new file mode 100644 index 0000000..fa22753 --- /dev/null +++ b/amazon/paapi5_python_sdk/get_items_response.py @@ -0,0 +1,155 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .error_data import ErrorData # noqa: F401,E501 +from .items_result import ItemsResult # noqa: F401,E501 + + +class GetItemsResponse(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 = { + 'errors': 'list[ErrorData]', + 'items_result': 'ItemsResult' + } + + attribute_map = { + 'errors': 'Errors', + 'items_result': 'ItemsResult' + } + + def __init__(self, errors=None, items_result=None): # noqa: E501 + """GetItemsResponse - a model defined in Swagger""" # noqa: E501 + + self._errors = None + self._items_result = None + self.discriminator = None + + if errors is not None: + self.errors = errors + if items_result is not None: + self.items_result = items_result + + @property + def errors(self): + """Gets the errors of this GetItemsResponse. # noqa: E501 + + + :return: The errors of this GetItemsResponse. # noqa: E501 + :rtype: list[ErrorData] + """ + return self._errors + + @errors.setter + def errors(self, errors): + """Sets the errors of this GetItemsResponse. + + + :param errors: The errors of this GetItemsResponse. # noqa: E501 + :type: list[ErrorData] + """ + + self._errors = errors + + @property + def items_result(self): + """Gets the items_result of this GetItemsResponse. # noqa: E501 + + + :return: The items_result of this GetItemsResponse. # noqa: E501 + :rtype: ItemsResult + """ + return self._items_result + + @items_result.setter + def items_result(self, items_result): + """Sets the items_result of this GetItemsResponse. + + + :param items_result: The items_result of this GetItemsResponse. # noqa: E501 + :type: ItemsResult + """ + + self._items_result = items_result + + 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(GetItemsResponse, 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, GetItemsResponse): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/get_variations_request.py b/amazon/paapi5_python_sdk/get_variations_request.py new file mode 100644 index 0000000..0b1ea3a --- /dev/null +++ b/amazon/paapi5_python_sdk/get_variations_request.py @@ -0,0 +1,448 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .condition import Condition # noqa: F401,E501 +from .get_variations_resource import GetVariationsResource # noqa: F401,E501 +from .merchant import Merchant # noqa: F401,E501 +from .offer_count import OfferCount # noqa: F401,E501 +from .partner_type import PartnerType # noqa: F401,E501 +from .properties import Properties # noqa: F401,E501 + + +class GetVariationsRequest(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 = { + 'asin': 'str', + 'condition': 'Condition', + 'currency_of_preference': 'str', + 'languages_of_preference': 'list[str]', + 'marketplace': 'str', + 'merchant': 'Merchant', + 'offer_count': 'OfferCount', + 'partner_tag': 'str', + 'partner_type': 'PartnerType', + 'properties': 'Properties', + 'resources': 'list[GetVariationsResource]', + 'variation_count': 'int', + 'variation_page': 'int' + } + + attribute_map = { + 'asin': 'ASIN', + 'condition': 'Condition', + 'currency_of_preference': 'CurrencyOfPreference', + 'languages_of_preference': 'LanguagesOfPreference', + 'marketplace': 'Marketplace', + 'merchant': 'Merchant', + 'offer_count': 'OfferCount', + 'partner_tag': 'PartnerTag', + 'partner_type': 'PartnerType', + 'properties': 'Properties', + 'resources': 'Resources', + 'variation_count': 'VariationCount', + 'variation_page': 'VariationPage' + } + + def __init__(self, asin=None, condition=None, currency_of_preference=None, languages_of_preference=None, marketplace=None, merchant=None, offer_count=None, partner_tag=None, partner_type=None, properties=None, resources=None, variation_count=None, variation_page=None): # noqa: E501 + """GetVariationsRequest - a model defined in Swagger""" # noqa: E501 + + self._asin = None + self._condition = None + self._currency_of_preference = None + self._languages_of_preference = None + self._marketplace = None + self._merchant = None + self._offer_count = None + self._partner_tag = None + self._partner_type = None + self._properties = None + self._resources = None + self._variation_count = None + self._variation_page = None + self.discriminator = None + + self.asin = asin + if condition is not None: + self.condition = condition + if currency_of_preference is not None: + self.currency_of_preference = currency_of_preference + if languages_of_preference is not None: + self.languages_of_preference = languages_of_preference + if marketplace is not None: + self.marketplace = marketplace + if merchant is not None: + self.merchant = merchant + if offer_count is not None: + self.offer_count = offer_count + self.partner_tag = partner_tag + self.partner_type = partner_type + if properties is not None: + self.properties = properties + if resources is not None: + self.resources = resources + if variation_count is not None: + self.variation_count = variation_count + if variation_page is not None: + self.variation_page = variation_page + + @property + def asin(self): + """Gets the asin of this GetVariationsRequest. # noqa: E501 + + + :return: The asin of this GetVariationsRequest. # noqa: E501 + :rtype: str + """ + return self._asin + + @asin.setter + def asin(self, asin): + """Sets the asin of this GetVariationsRequest. + + + :param asin: The asin of this GetVariationsRequest. # noqa: E501 + :type: str + """ + if asin is None: + raise ValueError("Invalid value for `asin`, must not be `None`") # noqa: E501 + + self._asin = asin + + @property + def condition(self): + """Gets the condition of this GetVariationsRequest. # noqa: E501 + + + :return: The condition of this GetVariationsRequest. # noqa: E501 + :rtype: Condition + """ + return self._condition + + @condition.setter + def condition(self, condition): + """Sets the condition of this GetVariationsRequest. + + + :param condition: The condition of this GetVariationsRequest. # noqa: E501 + :type: Condition + """ + + self._condition = condition + + @property + def currency_of_preference(self): + """Gets the currency_of_preference of this GetVariationsRequest. # noqa: E501 + + + :return: The currency_of_preference of this GetVariationsRequest. # noqa: E501 + :rtype: str + """ + return self._currency_of_preference + + @currency_of_preference.setter + def currency_of_preference(self, currency_of_preference): + """Sets the currency_of_preference of this GetVariationsRequest. + + + :param currency_of_preference: The currency_of_preference of this GetVariationsRequest. # noqa: E501 + :type: str + """ + + self._currency_of_preference = currency_of_preference + + @property + def languages_of_preference(self): + """Gets the languages_of_preference of this GetVariationsRequest. # noqa: E501 + + + :return: The languages_of_preference of this GetVariationsRequest. # noqa: E501 + :rtype: list[str] + """ + return self._languages_of_preference + + @languages_of_preference.setter + def languages_of_preference(self, languages_of_preference): + """Sets the languages_of_preference of this GetVariationsRequest. + + + :param languages_of_preference: The languages_of_preference of this GetVariationsRequest. # noqa: E501 + :type: list[str] + """ + + self._languages_of_preference = languages_of_preference + + @property + def marketplace(self): + """Gets the marketplace of this GetVariationsRequest. # noqa: E501 + + + :return: The marketplace of this GetVariationsRequest. # noqa: E501 + :rtype: str + """ + return self._marketplace + + @marketplace.setter + def marketplace(self, marketplace): + """Sets the marketplace of this GetVariationsRequest. + + + :param marketplace: The marketplace of this GetVariationsRequest. # noqa: E501 + :type: str + """ + + self._marketplace = marketplace + + @property + def merchant(self): + """Gets the merchant of this GetVariationsRequest. # noqa: E501 + + + :return: The merchant of this GetVariationsRequest. # noqa: E501 + :rtype: Merchant + """ + return self._merchant + + @merchant.setter + def merchant(self, merchant): + """Sets the merchant of this GetVariationsRequest. + + + :param merchant: The merchant of this GetVariationsRequest. # noqa: E501 + :type: Merchant + """ + + self._merchant = merchant + + @property + def offer_count(self): + """Gets the offer_count of this GetVariationsRequest. # noqa: E501 + + + :return: The offer_count of this GetVariationsRequest. # noqa: E501 + :rtype: OfferCount + """ + return self._offer_count + + @offer_count.setter + def offer_count(self, offer_count): + """Sets the offer_count of this GetVariationsRequest. + + + :param offer_count: The offer_count of this GetVariationsRequest. # noqa: E501 + :type: OfferCount + """ + + self._offer_count = offer_count + + @property + def partner_tag(self): + """Gets the partner_tag of this GetVariationsRequest. # noqa: E501 + + + :return: The partner_tag of this GetVariationsRequest. # noqa: E501 + :rtype: str + """ + return self._partner_tag + + @partner_tag.setter + def partner_tag(self, partner_tag): + """Sets the partner_tag of this GetVariationsRequest. + + + :param partner_tag: The partner_tag of this GetVariationsRequest. # noqa: E501 + :type: str + """ + if partner_tag is None: + raise ValueError("Invalid value for `partner_tag`, must not be `None`") # noqa: E501 + + self._partner_tag = partner_tag + + @property + def partner_type(self): + """Gets the partner_type of this GetVariationsRequest. # noqa: E501 + + + :return: The partner_type of this GetVariationsRequest. # noqa: E501 + :rtype: PartnerType + """ + return self._partner_type + + @partner_type.setter + def partner_type(self, partner_type): + """Sets the partner_type of this GetVariationsRequest. + + + :param partner_type: The partner_type of this GetVariationsRequest. # noqa: E501 + :type: PartnerType + """ + if partner_type is None: + raise ValueError("Invalid value for `partner_type`, must not be `None`") # noqa: E501 + + self._partner_type = partner_type + + @property + def properties(self): + """Gets the properties of this GetVariationsRequest. # noqa: E501 + + + :return: The properties of this GetVariationsRequest. # noqa: E501 + :rtype: Properties + """ + return self._properties + + @properties.setter + def properties(self, properties): + """Sets the properties of this GetVariationsRequest. + + + :param properties: The properties of this GetVariationsRequest. # noqa: E501 + :type: Properties + """ + + self._properties = properties + + @property + def resources(self): + """Gets the resources of this GetVariationsRequest. # noqa: E501 + + + :return: The resources of this GetVariationsRequest. # noqa: E501 + :rtype: list[GetVariationsResource] + """ + return self._resources + + @resources.setter + def resources(self, resources): + """Sets the resources of this GetVariationsRequest. + + + :param resources: The resources of this GetVariationsRequest. # noqa: E501 + :type: list[GetVariationsResource] + """ + + self._resources = resources + + @property + def variation_count(self): + """Gets the variation_count of this GetVariationsRequest. # noqa: E501 + + + :return: The variation_count of this GetVariationsRequest. # noqa: E501 + :rtype: int + """ + return self._variation_count + + @variation_count.setter + def variation_count(self, variation_count): + """Sets the variation_count of this GetVariationsRequest. + + + :param variation_count: The variation_count of this GetVariationsRequest. # noqa: E501 + :type: int + """ + + self._variation_count = variation_count + + @property + def variation_page(self): + """Gets the variation_page of this GetVariationsRequest. # noqa: E501 + + + :return: The variation_page of this GetVariationsRequest. # noqa: E501 + :rtype: int + """ + return self._variation_page + + @variation_page.setter + def variation_page(self, variation_page): + """Sets the variation_page of this GetVariationsRequest. + + + :param variation_page: The variation_page of this GetVariationsRequest. # noqa: E501 + :type: int + """ + + self._variation_page = variation_page + + 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(GetVariationsRequest, 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, GetVariationsRequest): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/get_variations_resource.py b/amazon/paapi5_python_sdk/get_variations_resource.py new file mode 100644 index 0000000..bf5018e --- /dev/null +++ b/amazon/paapi5_python_sdk/get_variations_resource.py @@ -0,0 +1,160 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class GetVariationsResource(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + allowed enum values + """ + BROWSENODEINFO_BROWSENODES = "BrowseNodeInfo.BrowseNodes" + BROWSENODEINFO_BROWSENODES_ANCESTOR = "BrowseNodeInfo.BrowseNodes.Ancestor" + BROWSENODEINFO_BROWSENODES_SALESRANK = "BrowseNodeInfo.BrowseNodes.SalesRank" + BROWSENODEINFO_WEBSITESALESRANK = "BrowseNodeInfo.WebsiteSalesRank" + IMAGES_PRIMARY_SMALL = "Images.Primary.Small" + IMAGES_PRIMARY_MEDIUM = "Images.Primary.Medium" + IMAGES_PRIMARY_LARGE = "Images.Primary.Large" + IMAGES_VARIANTS_SMALL = "Images.Variants.Small" + IMAGES_VARIANTS_MEDIUM = "Images.Variants.Medium" + IMAGES_VARIANTS_LARGE = "Images.Variants.Large" + ITEMINFO_BYLINEINFO = "ItemInfo.ByLineInfo" + ITEMINFO_CONTENTINFO = "ItemInfo.ContentInfo" + ITEMINFO_CONTENTRATING = "ItemInfo.ContentRating" + ITEMINFO_CLASSIFICATIONS = "ItemInfo.Classifications" + ITEMINFO_EXTERNALIDS = "ItemInfo.ExternalIds" + ITEMINFO_FEATURES = "ItemInfo.Features" + ITEMINFO_MANUFACTUREINFO = "ItemInfo.ManufactureInfo" + ITEMINFO_PRODUCTINFO = "ItemInfo.ProductInfo" + ITEMINFO_TECHNICALINFO = "ItemInfo.TechnicalInfo" + ITEMINFO_TITLE = "ItemInfo.Title" + ITEMINFO_TRADEININFO = "ItemInfo.TradeInInfo" + OFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY = "Offers.Listings.Availability.MaxOrderQuantity" + OFFERS_LISTINGS_AVAILABILITY_MESSAGE = "Offers.Listings.Availability.Message" + OFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY = "Offers.Listings.Availability.MinOrderQuantity" + OFFERS_LISTINGS_AVAILABILITY_TYPE = "Offers.Listings.Availability.Type" + OFFERS_LISTINGS_CONDITION = "Offers.Listings.Condition" + OFFERS_LISTINGS_CONDITION_SUBCONDITION = "Offers.Listings.Condition.SubCondition" + OFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED = "Offers.Listings.DeliveryInfo.IsAmazonFulfilled" + OFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE = "Offers.Listings.DeliveryInfo.IsFreeShippingEligible" + OFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE = "Offers.Listings.DeliveryInfo.IsPrimeEligible" + OFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES = "Offers.Listings.DeliveryInfo.ShippingCharges" + OFFERS_LISTINGS_ISBUYBOXWINNER = "Offers.Listings.IsBuyBoxWinner" + OFFERS_LISTINGS_LOYALTYPOINTS_POINTS = "Offers.Listings.LoyaltyPoints.Points" + OFFERS_LISTINGS_MERCHANTINFO = "Offers.Listings.MerchantInfo" + OFFERS_LISTINGS_PRICE = "Offers.Listings.Price" + OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEEXCLUSIVE = "Offers.Listings.ProgramEligibility.IsPrimeExclusive" + OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEPANTRY = "Offers.Listings.ProgramEligibility.IsPrimePantry" + OFFERS_LISTINGS_PROMOTIONS = "Offers.Listings.Promotions" + OFFERS_LISTINGS_SAVINGBASIS = "Offers.Listings.SavingBasis" + OFFERS_SUMMARIES_HIGHESTPRICE = "Offers.Summaries.HighestPrice" + OFFERS_SUMMARIES_LOWESTPRICE = "Offers.Summaries.LowestPrice" + OFFERS_SUMMARIES_OFFERCOUNT = "Offers.Summaries.OfferCount" + PARENTASIN = "ParentASIN" + RENTALOFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY = "RentalOffers.Listings.Availability.MaxOrderQuantity" + RENTALOFFERS_LISTINGS_AVAILABILITY_MESSAGE = "RentalOffers.Listings.Availability.Message" + RENTALOFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY = "RentalOffers.Listings.Availability.MinOrderQuantity" + RENTALOFFERS_LISTINGS_AVAILABILITY_TYPE = "RentalOffers.Listings.Availability.Type" + RENTALOFFERS_LISTINGS_BASEPRICE = "RentalOffers.Listings.BasePrice" + RENTALOFFERS_LISTINGS_CONDITION = "RentalOffers.Listings.Condition" + RENTALOFFERS_LISTINGS_CONDITION_SUBCONDITION = "RentalOffers.Listings.Condition.SubCondition" + RENTALOFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED = "RentalOffers.Listings.DeliveryInfo.IsAmazonFulfilled" + RENTALOFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE = "RentalOffers.Listings.DeliveryInfo.IsFreeShippingEligible" + RENTALOFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE = "RentalOffers.Listings.DeliveryInfo.IsPrimeEligible" + RENTALOFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES = "RentalOffers.Listings.DeliveryInfo.ShippingCharges" + RENTALOFFERS_LISTINGS_MERCHANTINFO = "RentalOffers.Listings.MerchantInfo" + VARIATIONSUMMARY_PRICE_HIGHESTPRICE = "VariationSummary.Price.HighestPrice" + VARIATIONSUMMARY_PRICE_LOWESTPRICE = "VariationSummary.Price.LowestPrice" + VARIATIONSUMMARY_VARIATIONDIMENSION = "VariationSummary.VariationDimension" + + """ + 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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """GetVariationsResource - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(GetVariationsResource, 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, GetVariationsResource): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/get_variations_response.py b/amazon/paapi5_python_sdk/get_variations_response.py new file mode 100644 index 0000000..287ee5e --- /dev/null +++ b/amazon/paapi5_python_sdk/get_variations_response.py @@ -0,0 +1,155 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .error_data import ErrorData # noqa: F401,E501 +from .variations_result import VariationsResult # noqa: F401,E501 + + +class GetVariationsResponse(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 = { + 'errors': 'list[ErrorData]', + 'variations_result': 'VariationsResult' + } + + attribute_map = { + 'errors': 'Errors', + 'variations_result': 'VariationsResult' + } + + def __init__(self, errors=None, variations_result=None): # noqa: E501 + """GetVariationsResponse - a model defined in Swagger""" # noqa: E501 + + self._errors = None + self._variations_result = None + self.discriminator = None + + if errors is not None: + self.errors = errors + if variations_result is not None: + self.variations_result = variations_result + + @property + def errors(self): + """Gets the errors of this GetVariationsResponse. # noqa: E501 + + + :return: The errors of this GetVariationsResponse. # noqa: E501 + :rtype: list[ErrorData] + """ + return self._errors + + @errors.setter + def errors(self, errors): + """Sets the errors of this GetVariationsResponse. + + + :param errors: The errors of this GetVariationsResponse. # noqa: E501 + :type: list[ErrorData] + """ + + self._errors = errors + + @property + def variations_result(self): + """Gets the variations_result of this GetVariationsResponse. # noqa: E501 + + + :return: The variations_result of this GetVariationsResponse. # noqa: E501 + :rtype: VariationsResult + """ + return self._variations_result + + @variations_result.setter + def variations_result(self, variations_result): + """Sets the variations_result of this GetVariationsResponse. + + + :param variations_result: The variations_result of this GetVariationsResponse. # noqa: E501 + :type: VariationsResult + """ + + self._variations_result = variations_result + + 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(GetVariationsResponse, 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, GetVariationsResponse): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/image_size.py b/amazon/paapi5_python_sdk/image_size.py new file mode 100644 index 0000000..cb56660 --- /dev/null +++ b/amazon/paapi5_python_sdk/image_size.py @@ -0,0 +1,178 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class ImageSize(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 = { + 'url': 'str', + 'height': 'int', + 'width': 'int' + } + + attribute_map = { + 'url': 'URL', + 'height': 'Height', + 'width': 'Width' + } + + def __init__(self, url=None, height=None, width=None): # noqa: E501 + """ImageSize - a model defined in Swagger""" # noqa: E501 + + self._url = None + self._height = None + self._width = None + self.discriminator = None + + if url is not None: + self.url = url + if height is not None: + self.height = height + if width is not None: + self.width = width + + @property + def url(self): + """Gets the url of this ImageSize. # noqa: E501 + + + :return: The url of this ImageSize. # noqa: E501 + :rtype: str + """ + return self._url + + @url.setter + def url(self, url): + """Sets the url of this ImageSize. + + + :param url: The url of this ImageSize. # noqa: E501 + :type: str + """ + + self._url = url + + @property + def height(self): + """Gets the height of this ImageSize. # noqa: E501 + + + :return: The height of this ImageSize. # noqa: E501 + :rtype: int + """ + return self._height + + @height.setter + def height(self, height): + """Sets the height of this ImageSize. + + + :param height: The height of this ImageSize. # noqa: E501 + :type: int + """ + + self._height = height + + @property + def width(self): + """Gets the width of this ImageSize. # noqa: E501 + + + :return: The width of this ImageSize. # noqa: E501 + :rtype: int + """ + return self._width + + @width.setter + def width(self, width): + """Sets the width of this ImageSize. + + + :param width: The width of this ImageSize. # noqa: E501 + :type: int + """ + + self._width = width + + 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(ImageSize, 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, ImageSize): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/image_type.py b/amazon/paapi5_python_sdk/image_type.py new file mode 100644 index 0000000..1abf7eb --- /dev/null +++ b/amazon/paapi5_python_sdk/image_type.py @@ -0,0 +1,180 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .image_size import ImageSize # noqa: F401,E501 + + +class ImageType(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 = { + 'small': 'ImageSize', + 'medium': 'ImageSize', + 'large': 'ImageSize' + } + + attribute_map = { + 'small': 'Small', + 'medium': 'Medium', + 'large': 'Large' + } + + def __init__(self, small=None, medium=None, large=None): # noqa: E501 + """ImageType - a model defined in Swagger""" # noqa: E501 + + self._small = None + self._medium = None + self._large = None + self.discriminator = None + + if small is not None: + self.small = small + if medium is not None: + self.medium = medium + if large is not None: + self.large = large + + @property + def small(self): + """Gets the small of this ImageType. # noqa: E501 + + + :return: The small of this ImageType. # noqa: E501 + :rtype: ImageSize + """ + return self._small + + @small.setter + def small(self, small): + """Sets the small of this ImageType. + + + :param small: The small of this ImageType. # noqa: E501 + :type: ImageSize + """ + + self._small = small + + @property + def medium(self): + """Gets the medium of this ImageType. # noqa: E501 + + + :return: The medium of this ImageType. # noqa: E501 + :rtype: ImageSize + """ + return self._medium + + @medium.setter + def medium(self, medium): + """Sets the medium of this ImageType. + + + :param medium: The medium of this ImageType. # noqa: E501 + :type: ImageSize + """ + + self._medium = medium + + @property + def large(self): + """Gets the large of this ImageType. # noqa: E501 + + + :return: The large of this ImageType. # noqa: E501 + :rtype: ImageSize + """ + return self._large + + @large.setter + def large(self, large): + """Sets the large of this ImageType. + + + :param large: The large of this ImageType. # noqa: E501 + :type: ImageSize + """ + + self._large = large + + 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(ImageType, 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, ImageType): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/images.py b/amazon/paapi5_python_sdk/images.py new file mode 100644 index 0000000..cf46148 --- /dev/null +++ b/amazon/paapi5_python_sdk/images.py @@ -0,0 +1,154 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .image_type import ImageType # noqa: F401,E501 + + +class Images(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 = { + 'primary': 'ImageType', + 'variants': 'list[ImageType]' + } + + attribute_map = { + 'primary': 'Primary', + 'variants': 'Variants' + } + + def __init__(self, primary=None, variants=None): # noqa: E501 + """Images - a model defined in Swagger""" # noqa: E501 + + self._primary = None + self._variants = None + self.discriminator = None + + if primary is not None: + self.primary = primary + if variants is not None: + self.variants = variants + + @property + def primary(self): + """Gets the primary of this Images. # noqa: E501 + + + :return: The primary of this Images. # noqa: E501 + :rtype: ImageType + """ + return self._primary + + @primary.setter + def primary(self, primary): + """Sets the primary of this Images. + + + :param primary: The primary of this Images. # noqa: E501 + :type: ImageType + """ + + self._primary = primary + + @property + def variants(self): + """Gets the variants of this Images. # noqa: E501 + + + :return: The variants of this Images. # noqa: E501 + :rtype: list[ImageType] + """ + return self._variants + + @variants.setter + def variants(self, variants): + """Sets the variants of this Images. + + + :param variants: The variants of this Images. # noqa: E501 + :type: list[ImageType] + """ + + self._variants = variants + + 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(Images, 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, Images): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/item.py b/amazon/paapi5_python_sdk/item.py new file mode 100644 index 0000000..6583aed --- /dev/null +++ b/amazon/paapi5_python_sdk/item.py @@ -0,0 +1,367 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .browse_node_info import BrowseNodeInfo # noqa: F401,E501 +from .images import Images # noqa: F401,E501 +from .item_info import ItemInfo # noqa: F401,E501 +from .offers import Offers # noqa: F401,E501 +from .rental_offers import RentalOffers # noqa: F401,E501 +from .variation_attribute import VariationAttribute # noqa: F401,E501 + + +class Item(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 = { + 'asin': 'str', + 'browse_node_info': 'BrowseNodeInfo', + 'detail_page_url': 'str', + 'images': 'Images', + 'item_info': 'ItemInfo', + 'offers': 'Offers', + 'parent_asin': 'str', + 'rental_offers': 'RentalOffers', + 'score': 'float', + 'variation_attributes': 'list[VariationAttribute]' + } + + attribute_map = { + 'asin': 'ASIN', + 'browse_node_info': 'BrowseNodeInfo', + 'detail_page_url': 'DetailPageURL', + 'images': 'Images', + 'item_info': 'ItemInfo', + 'offers': 'Offers', + 'parent_asin': 'ParentASIN', + 'rental_offers': 'RentalOffers', + 'score': 'Score', + 'variation_attributes': 'VariationAttributes' + } + + def __init__(self, asin=None, browse_node_info=None, detail_page_url=None, images=None, item_info=None, offers=None, parent_asin=None, rental_offers=None, score=None, variation_attributes=None): # noqa: E501 + """Item - a model defined in Swagger""" # noqa: E501 + + self._asin = None + self._browse_node_info = None + self._detail_page_url = None + self._images = None + self._item_info = None + self._offers = None + self._parent_asin = None + self._rental_offers = None + self._score = None + self._variation_attributes = None + self.discriminator = None + + if asin is not None: + self.asin = asin + if browse_node_info is not None: + self.browse_node_info = browse_node_info + if detail_page_url is not None: + self.detail_page_url = detail_page_url + if images is not None: + self.images = images + if item_info is not None: + self.item_info = item_info + if offers is not None: + self.offers = offers + if parent_asin is not None: + self.parent_asin = parent_asin + if rental_offers is not None: + self.rental_offers = rental_offers + if score is not None: + self.score = score + if variation_attributes is not None: + self.variation_attributes = variation_attributes + + @property + def asin(self): + """Gets the asin of this Item. # noqa: E501 + + + :return: The asin of this Item. # noqa: E501 + :rtype: str + """ + return self._asin + + @asin.setter + def asin(self, asin): + """Sets the asin of this Item. + + + :param asin: The asin of this Item. # noqa: E501 + :type: str + """ + + self._asin = asin + + @property + def browse_node_info(self): + """Gets the browse_node_info of this Item. # noqa: E501 + + + :return: The browse_node_info of this Item. # noqa: E501 + :rtype: BrowseNodeInfo + """ + return self._browse_node_info + + @browse_node_info.setter + def browse_node_info(self, browse_node_info): + """Sets the browse_node_info of this Item. + + + :param browse_node_info: The browse_node_info of this Item. # noqa: E501 + :type: BrowseNodeInfo + """ + + self._browse_node_info = browse_node_info + + @property + def detail_page_url(self): + """Gets the detail_page_url of this Item. # noqa: E501 + + + :return: The detail_page_url of this Item. # noqa: E501 + :rtype: str + """ + return self._detail_page_url + + @detail_page_url.setter + def detail_page_url(self, detail_page_url): + """Sets the detail_page_url of this Item. + + + :param detail_page_url: The detail_page_url of this Item. # noqa: E501 + :type: str + """ + + self._detail_page_url = detail_page_url + + @property + def images(self): + """Gets the images of this Item. # noqa: E501 + + + :return: The images of this Item. # noqa: E501 + :rtype: Images + """ + return self._images + + @images.setter + def images(self, images): + """Sets the images of this Item. + + + :param images: The images of this Item. # noqa: E501 + :type: Images + """ + + self._images = images + + @property + def item_info(self): + """Gets the item_info of this Item. # noqa: E501 + + + :return: The item_info of this Item. # noqa: E501 + :rtype: ItemInfo + """ + return self._item_info + + @item_info.setter + def item_info(self, item_info): + """Sets the item_info of this Item. + + + :param item_info: The item_info of this Item. # noqa: E501 + :type: ItemInfo + """ + + self._item_info = item_info + + @property + def offers(self): + """Gets the offers of this Item. # noqa: E501 + + + :return: The offers of this Item. # noqa: E501 + :rtype: Offers + """ + return self._offers + + @offers.setter + def offers(self, offers): + """Sets the offers of this Item. + + + :param offers: The offers of this Item. # noqa: E501 + :type: Offers + """ + + self._offers = offers + + @property + def parent_asin(self): + """Gets the parent_asin of this Item. # noqa: E501 + + + :return: The parent_asin of this Item. # noqa: E501 + :rtype: str + """ + return self._parent_asin + + @parent_asin.setter + def parent_asin(self, parent_asin): + """Sets the parent_asin of this Item. + + + :param parent_asin: The parent_asin of this Item. # noqa: E501 + :type: str + """ + + self._parent_asin = parent_asin + + @property + def rental_offers(self): + """Gets the rental_offers of this Item. # noqa: E501 + + + :return: The rental_offers of this Item. # noqa: E501 + :rtype: RentalOffers + """ + return self._rental_offers + + @rental_offers.setter + def rental_offers(self, rental_offers): + """Sets the rental_offers of this Item. + + + :param rental_offers: The rental_offers of this Item. # noqa: E501 + :type: RentalOffers + """ + + self._rental_offers = rental_offers + + @property + def score(self): + """Gets the score of this Item. # noqa: E501 + + + :return: The score of this Item. # noqa: E501 + :rtype: float + """ + return self._score + + @score.setter + def score(self, score): + """Sets the score of this Item. + + + :param score: The score of this Item. # noqa: E501 + :type: float + """ + + self._score = score + + @property + def variation_attributes(self): + """Gets the variation_attributes of this Item. # noqa: E501 + + + :return: The variation_attributes of this Item. # noqa: E501 + :rtype: list[VariationAttribute] + """ + return self._variation_attributes + + @variation_attributes.setter + def variation_attributes(self, variation_attributes): + """Sets the variation_attributes of this Item. + + + :param variation_attributes: The variation_attributes of this Item. # noqa: E501 + :type: list[VariationAttribute] + """ + + self._variation_attributes = variation_attributes + + 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(Item, 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, Item): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/item_id_type.py b/amazon/paapi5_python_sdk/item_id_type.py new file mode 100644 index 0000000..0d3b36a --- /dev/null +++ b/amazon/paapi5_python_sdk/item_id_type.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class ItemIdType(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + allowed enum values + """ + ASIN = "ASIN" + + """ + 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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """ItemIdType - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(ItemIdType, 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, ItemIdType): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/item_info.py b/amazon/paapi5_python_sdk/item_info.py new file mode 100644 index 0000000..c03de48 --- /dev/null +++ b/amazon/paapi5_python_sdk/item_info.py @@ -0,0 +1,398 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .by_line_info import ByLineInfo # noqa: F401,E501 +from .classifications import Classifications # noqa: F401,E501 +from .content_info import ContentInfo # noqa: F401,E501 +from .content_rating import ContentRating # noqa: F401,E501 +from .external_ids import ExternalIds # noqa: F401,E501 +from .manufacture_info import ManufactureInfo # noqa: F401,E501 +from .multi_valued_attribute import MultiValuedAttribute # noqa: F401,E501 +from .product_info import ProductInfo # noqa: F401,E501 +from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 +from .technical_info import TechnicalInfo # noqa: F401,E501 +from .trade_in_info import TradeInInfo # noqa: F401,E501 + + +class ItemInfo(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 = { + 'by_line_info': 'ByLineInfo', + 'classifications': 'Classifications', + 'content_info': 'ContentInfo', + 'content_rating': 'ContentRating', + 'external_ids': 'ExternalIds', + 'features': 'MultiValuedAttribute', + 'manufacture_info': 'ManufactureInfo', + 'product_info': 'ProductInfo', + 'technical_info': 'TechnicalInfo', + 'title': 'SingleStringValuedAttribute', + 'trade_in_info': 'TradeInInfo' + } + + attribute_map = { + 'by_line_info': 'ByLineInfo', + 'classifications': 'Classifications', + 'content_info': 'ContentInfo', + 'content_rating': 'ContentRating', + 'external_ids': 'ExternalIds', + 'features': 'Features', + 'manufacture_info': 'ManufactureInfo', + 'product_info': 'ProductInfo', + 'technical_info': 'TechnicalInfo', + 'title': 'Title', + 'trade_in_info': 'TradeInInfo' + } + + def __init__(self, by_line_info=None, classifications=None, content_info=None, content_rating=None, external_ids=None, features=None, manufacture_info=None, product_info=None, technical_info=None, title=None, trade_in_info=None): # noqa: E501 + """ItemInfo - a model defined in Swagger""" # noqa: E501 + + self._by_line_info = None + self._classifications = None + self._content_info = None + self._content_rating = None + self._external_ids = None + self._features = None + self._manufacture_info = None + self._product_info = None + self._technical_info = None + self._title = None + self._trade_in_info = None + self.discriminator = None + + if by_line_info is not None: + self.by_line_info = by_line_info + if classifications is not None: + self.classifications = classifications + if content_info is not None: + self.content_info = content_info + if content_rating is not None: + self.content_rating = content_rating + if external_ids is not None: + self.external_ids = external_ids + if features is not None: + self.features = features + if manufacture_info is not None: + self.manufacture_info = manufacture_info + if product_info is not None: + self.product_info = product_info + if technical_info is not None: + self.technical_info = technical_info + if title is not None: + self.title = title + if trade_in_info is not None: + self.trade_in_info = trade_in_info + + @property + def by_line_info(self): + """Gets the by_line_info of this ItemInfo. # noqa: E501 + + + :return: The by_line_info of this ItemInfo. # noqa: E501 + :rtype: ByLineInfo + """ + return self._by_line_info + + @by_line_info.setter + def by_line_info(self, by_line_info): + """Sets the by_line_info of this ItemInfo. + + + :param by_line_info: The by_line_info of this ItemInfo. # noqa: E501 + :type: ByLineInfo + """ + + self._by_line_info = by_line_info + + @property + def classifications(self): + """Gets the classifications of this ItemInfo. # noqa: E501 + + + :return: The classifications of this ItemInfo. # noqa: E501 + :rtype: Classifications + """ + return self._classifications + + @classifications.setter + def classifications(self, classifications): + """Sets the classifications of this ItemInfo. + + + :param classifications: The classifications of this ItemInfo. # noqa: E501 + :type: Classifications + """ + + self._classifications = classifications + + @property + def content_info(self): + """Gets the content_info of this ItemInfo. # noqa: E501 + + + :return: The content_info of this ItemInfo. # noqa: E501 + :rtype: ContentInfo + """ + return self._content_info + + @content_info.setter + def content_info(self, content_info): + """Sets the content_info of this ItemInfo. + + + :param content_info: The content_info of this ItemInfo. # noqa: E501 + :type: ContentInfo + """ + + self._content_info = content_info + + @property + def content_rating(self): + """Gets the content_rating of this ItemInfo. # noqa: E501 + + + :return: The content_rating of this ItemInfo. # noqa: E501 + :rtype: ContentRating + """ + return self._content_rating + + @content_rating.setter + def content_rating(self, content_rating): + """Sets the content_rating of this ItemInfo. + + + :param content_rating: The content_rating of this ItemInfo. # noqa: E501 + :type: ContentRating + """ + + self._content_rating = content_rating + + @property + def external_ids(self): + """Gets the external_ids of this ItemInfo. # noqa: E501 + + + :return: The external_ids of this ItemInfo. # noqa: E501 + :rtype: ExternalIds + """ + return self._external_ids + + @external_ids.setter + def external_ids(self, external_ids): + """Sets the external_ids of this ItemInfo. + + + :param external_ids: The external_ids of this ItemInfo. # noqa: E501 + :type: ExternalIds + """ + + self._external_ids = external_ids + + @property + def features(self): + """Gets the features of this ItemInfo. # noqa: E501 + + + :return: The features of this ItemInfo. # noqa: E501 + :rtype: MultiValuedAttribute + """ + return self._features + + @features.setter + def features(self, features): + """Sets the features of this ItemInfo. + + + :param features: The features of this ItemInfo. # noqa: E501 + :type: MultiValuedAttribute + """ + + self._features = features + + @property + def manufacture_info(self): + """Gets the manufacture_info of this ItemInfo. # noqa: E501 + + + :return: The manufacture_info of this ItemInfo. # noqa: E501 + :rtype: ManufactureInfo + """ + return self._manufacture_info + + @manufacture_info.setter + def manufacture_info(self, manufacture_info): + """Sets the manufacture_info of this ItemInfo. + + + :param manufacture_info: The manufacture_info of this ItemInfo. # noqa: E501 + :type: ManufactureInfo + """ + + self._manufacture_info = manufacture_info + + @property + def product_info(self): + """Gets the product_info of this ItemInfo. # noqa: E501 + + + :return: The product_info of this ItemInfo. # noqa: E501 + :rtype: ProductInfo + """ + return self._product_info + + @product_info.setter + def product_info(self, product_info): + """Sets the product_info of this ItemInfo. + + + :param product_info: The product_info of this ItemInfo. # noqa: E501 + :type: ProductInfo + """ + + self._product_info = product_info + + @property + def technical_info(self): + """Gets the technical_info of this ItemInfo. # noqa: E501 + + + :return: The technical_info of this ItemInfo. # noqa: E501 + :rtype: TechnicalInfo + """ + return self._technical_info + + @technical_info.setter + def technical_info(self, technical_info): + """Sets the technical_info of this ItemInfo. + + + :param technical_info: The technical_info of this ItemInfo. # noqa: E501 + :type: TechnicalInfo + """ + + self._technical_info = technical_info + + @property + def title(self): + """Gets the title of this ItemInfo. # noqa: E501 + + + :return: The title of this ItemInfo. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._title + + @title.setter + def title(self, title): + """Sets the title of this ItemInfo. + + + :param title: The title of this ItemInfo. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._title = title + + @property + def trade_in_info(self): + """Gets the trade_in_info of this ItemInfo. # noqa: E501 + + + :return: The trade_in_info of this ItemInfo. # noqa: E501 + :rtype: TradeInInfo + """ + return self._trade_in_info + + @trade_in_info.setter + def trade_in_info(self, trade_in_info): + """Sets the trade_in_info of this ItemInfo. + + + :param trade_in_info: The trade_in_info of this ItemInfo. # noqa: E501 + :type: TradeInInfo + """ + + self._trade_in_info = trade_in_info + + 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(ItemInfo, 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, ItemInfo): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/items_result.py b/amazon/paapi5_python_sdk/items_result.py new file mode 100644 index 0000000..4c4192a --- /dev/null +++ b/amazon/paapi5_python_sdk/items_result.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .item import Item # noqa: F401,E501 + + +class ItemsResult(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 = { + 'items': 'list[Item]' + } + + attribute_map = { + 'items': 'Items' + } + + def __init__(self, items=None): # noqa: E501 + """ItemsResult - a model defined in Swagger""" # noqa: E501 + + self._items = None + self.discriminator = None + + if items is not None: + self.items = items + + @property + def items(self): + """Gets the items of this ItemsResult. # noqa: E501 + + + :return: The items of this ItemsResult. # noqa: E501 + :rtype: list[Item] + """ + return self._items + + @items.setter + def items(self, items): + """Sets the items of this ItemsResult. + + + :param items: The items of this ItemsResult. # noqa: E501 + :type: list[Item] + """ + + self._items = items + + 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(ItemsResult, 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, ItemsResult): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/language_type.py b/amazon/paapi5_python_sdk/language_type.py new file mode 100644 index 0000000..c5a038c --- /dev/null +++ b/amazon/paapi5_python_sdk/language_type.py @@ -0,0 +1,152 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class LanguageType(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 = { + 'display_value': 'str', + 'type': 'str' + } + + attribute_map = { + 'display_value': 'DisplayValue', + 'type': 'Type' + } + + def __init__(self, display_value=None, type=None): # noqa: E501 + """LanguageType - a model defined in Swagger""" # noqa: E501 + + self._display_value = None + self._type = None + self.discriminator = None + + if display_value is not None: + self.display_value = display_value + if type is not None: + self.type = type + + @property + def display_value(self): + """Gets the display_value of this LanguageType. # noqa: E501 + + + :return: The display_value of this LanguageType. # noqa: E501 + :rtype: str + """ + return self._display_value + + @display_value.setter + def display_value(self, display_value): + """Sets the display_value of this LanguageType. + + + :param display_value: The display_value of this LanguageType. # noqa: E501 + :type: str + """ + + self._display_value = display_value + + @property + def type(self): + """Gets the type of this LanguageType. # noqa: E501 + + + :return: The type of this LanguageType. # noqa: E501 + :rtype: str + """ + return self._type + + @type.setter + def type(self, type): + """Sets the type of this LanguageType. + + + :param type: The type of this LanguageType. # noqa: E501 + :type: str + """ + + self._type = 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(LanguageType, 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, LanguageType): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/languages.py b/amazon/paapi5_python_sdk/languages.py new file mode 100644 index 0000000..f1f8db0 --- /dev/null +++ b/amazon/paapi5_python_sdk/languages.py @@ -0,0 +1,180 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .language_type import LanguageType # noqa: F401,E501 + + +class Languages(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 = { + 'display_values': 'list[LanguageType]', + 'label': 'str', + 'locale': 'str' + } + + attribute_map = { + 'display_values': 'DisplayValues', + 'label': 'Label', + 'locale': 'Locale' + } + + def __init__(self, display_values=None, label=None, locale=None): # noqa: E501 + """Languages - a model defined in Swagger""" # noqa: E501 + + self._display_values = None + self._label = None + self._locale = None + self.discriminator = None + + if display_values is not None: + self.display_values = display_values + if label is not None: + self.label = label + if locale is not None: + self.locale = locale + + @property + def display_values(self): + """Gets the display_values of this Languages. # noqa: E501 + + + :return: The display_values of this Languages. # noqa: E501 + :rtype: list[LanguageType] + """ + return self._display_values + + @display_values.setter + def display_values(self, display_values): + """Sets the display_values of this Languages. + + + :param display_values: The display_values of this Languages. # noqa: E501 + :type: list[LanguageType] + """ + + self._display_values = display_values + + @property + def label(self): + """Gets the label of this Languages. # noqa: E501 + + + :return: The label of this Languages. # noqa: E501 + :rtype: str + """ + return self._label + + @label.setter + def label(self, label): + """Sets the label of this Languages. + + + :param label: The label of this Languages. # noqa: E501 + :type: str + """ + + self._label = label + + @property + def locale(self): + """Gets the locale of this Languages. # noqa: E501 + + + :return: The locale of this Languages. # noqa: E501 + :rtype: str + """ + return self._locale + + @locale.setter + def locale(self, locale): + """Sets the locale of this Languages. + + + :param locale: The locale of this Languages. # noqa: E501 + :type: str + """ + + self._locale = locale + + 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(Languages, 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, Languages): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/manufacture_info.py b/amazon/paapi5_python_sdk/manufacture_info.py new file mode 100644 index 0000000..ccc9fe7 --- /dev/null +++ b/amazon/paapi5_python_sdk/manufacture_info.py @@ -0,0 +1,180 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 + + +class ManufactureInfo(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 = { + 'item_part_number': 'SingleStringValuedAttribute', + 'model': 'SingleStringValuedAttribute', + 'warranty': 'SingleStringValuedAttribute' + } + + attribute_map = { + 'item_part_number': 'ItemPartNumber', + 'model': 'Model', + 'warranty': 'Warranty' + } + + def __init__(self, item_part_number=None, model=None, warranty=None): # noqa: E501 + """ManufactureInfo - a model defined in Swagger""" # noqa: E501 + + self._item_part_number = None + self._model = None + self._warranty = None + self.discriminator = None + + if item_part_number is not None: + self.item_part_number = item_part_number + if model is not None: + self.model = model + if warranty is not None: + self.warranty = warranty + + @property + def item_part_number(self): + """Gets the item_part_number of this ManufactureInfo. # noqa: E501 + + + :return: The item_part_number of this ManufactureInfo. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._item_part_number + + @item_part_number.setter + def item_part_number(self, item_part_number): + """Sets the item_part_number of this ManufactureInfo. + + + :param item_part_number: The item_part_number of this ManufactureInfo. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._item_part_number = item_part_number + + @property + def model(self): + """Gets the model of this ManufactureInfo. # noqa: E501 + + + :return: The model of this ManufactureInfo. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._model + + @model.setter + def model(self, model): + """Sets the model of this ManufactureInfo. + + + :param model: The model of this ManufactureInfo. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._model = model + + @property + def warranty(self): + """Gets the warranty of this ManufactureInfo. # noqa: E501 + + + :return: The warranty of this ManufactureInfo. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._warranty + + @warranty.setter + def warranty(self, warranty): + """Sets the warranty of this ManufactureInfo. + + + :param warranty: The warranty of this ManufactureInfo. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._warranty = warranty + + 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(ManufactureInfo, 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, ManufactureInfo): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/max_price.py b/amazon/paapi5_python_sdk/max_price.py new file mode 100644 index 0000000..651f4da --- /dev/null +++ b/amazon/paapi5_python_sdk/max_price.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class MaxPrice(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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """MaxPrice - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(MaxPrice, 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, MaxPrice): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/merchant.py b/amazon/paapi5_python_sdk/merchant.py new file mode 100644 index 0000000..f5a6ad9 --- /dev/null +++ b/amazon/paapi5_python_sdk/merchant.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class Merchant(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + allowed enum values + """ + ALL = "All" + AMAZON = "Amazon" + + """ + 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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """Merchant - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(Merchant, 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, Merchant): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/min_price.py b/amazon/paapi5_python_sdk/min_price.py new file mode 100644 index 0000000..b4b2aa4 --- /dev/null +++ b/amazon/paapi5_python_sdk/min_price.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class MinPrice(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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """MinPrice - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(MinPrice, 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, MinPrice): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/min_reviews_rating.py b/amazon/paapi5_python_sdk/min_reviews_rating.py new file mode 100644 index 0000000..a4d1bbb --- /dev/null +++ b/amazon/paapi5_python_sdk/min_reviews_rating.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class MinReviewsRating(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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """MinReviewsRating - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(MinReviewsRating, 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, MinReviewsRating): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/min_saving_percent.py b/amazon/paapi5_python_sdk/min_saving_percent.py new file mode 100644 index 0000000..a3ec1ad --- /dev/null +++ b/amazon/paapi5_python_sdk/min_saving_percent.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class MinSavingPercent(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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """MinSavingPercent - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(MinSavingPercent, 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, MinSavingPercent): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/multi_valued_attribute.py b/amazon/paapi5_python_sdk/multi_valued_attribute.py new file mode 100644 index 0000000..0d1e6b5 --- /dev/null +++ b/amazon/paapi5_python_sdk/multi_valued_attribute.py @@ -0,0 +1,178 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class MultiValuedAttribute(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 = { + 'display_values': 'list[str]', + 'label': 'str', + 'locale': 'str' + } + + attribute_map = { + 'display_values': 'DisplayValues', + 'label': 'Label', + 'locale': 'Locale' + } + + def __init__(self, display_values=None, label=None, locale=None): # noqa: E501 + """MultiValuedAttribute - a model defined in Swagger""" # noqa: E501 + + self._display_values = None + self._label = None + self._locale = None + self.discriminator = None + + if display_values is not None: + self.display_values = display_values + if label is not None: + self.label = label + if locale is not None: + self.locale = locale + + @property + def display_values(self): + """Gets the display_values of this MultiValuedAttribute. # noqa: E501 + + + :return: The display_values of this MultiValuedAttribute. # noqa: E501 + :rtype: list[str] + """ + return self._display_values + + @display_values.setter + def display_values(self, display_values): + """Sets the display_values of this MultiValuedAttribute. + + + :param display_values: The display_values of this MultiValuedAttribute. # noqa: E501 + :type: list[str] + """ + + self._display_values = display_values + + @property + def label(self): + """Gets the label of this MultiValuedAttribute. # noqa: E501 + + + :return: The label of this MultiValuedAttribute. # noqa: E501 + :rtype: str + """ + return self._label + + @label.setter + def label(self, label): + """Sets the label of this MultiValuedAttribute. + + + :param label: The label of this MultiValuedAttribute. # noqa: E501 + :type: str + """ + + self._label = label + + @property + def locale(self): + """Gets the locale of this MultiValuedAttribute. # noqa: E501 + + + :return: The locale of this MultiValuedAttribute. # noqa: E501 + :rtype: str + """ + return self._locale + + @locale.setter + def locale(self, locale): + """Sets the locale of this MultiValuedAttribute. + + + :param locale: The locale of this MultiValuedAttribute. # noqa: E501 + :type: str + """ + + self._locale = locale + + 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(MultiValuedAttribute, 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, MultiValuedAttribute): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_availability.py b/amazon/paapi5_python_sdk/offer_availability.py new file mode 100644 index 0000000..2da4ef6 --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_availability.py @@ -0,0 +1,203 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +class OfferAvailability(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 = { + 'max_order_quantity': 'int', + 'message': 'str', + 'min_order_quantity': 'int', + 'type': 'str' + } + + attribute_map = { + 'max_order_quantity': 'MaxOrderQuantity', + 'message': 'Message', + 'min_order_quantity': 'MinOrderQuantity', + 'type': 'Type' + } + + def __init__(self, max_order_quantity=None, message=None, min_order_quantity=None, type=None): # noqa: E501 + """OfferAvailability - a model defined in Swagger""" # noqa: E501 + + self._max_order_quantity = None + self._message = None + self._min_order_quantity = None + self._type = None + self.discriminator = None + + if max_order_quantity is not None: + self.max_order_quantity = max_order_quantity + if message is not None: + self.message = message + if min_order_quantity is not None: + self.min_order_quantity = min_order_quantity + if type is not None: + self.type = type + + @property + def max_order_quantity(self): + """Gets the max_order_quantity of this OfferAvailability. # noqa: E501 + + + :return: The max_order_quantity of this OfferAvailability. # noqa: E501 + :rtype: int + """ + return self._max_order_quantity + + @max_order_quantity.setter + def max_order_quantity(self, max_order_quantity): + """Sets the max_order_quantity of this OfferAvailability. + + + :param max_order_quantity: The max_order_quantity of this OfferAvailability. # noqa: E501 + :type: int + """ + + self._max_order_quantity = max_order_quantity + + @property + def message(self): + """Gets the message of this OfferAvailability. # noqa: E501 + + + :return: The message of this OfferAvailability. # noqa: E501 + :rtype: str + """ + return self._message + + @message.setter + def message(self, message): + """Sets the message of this OfferAvailability. + + + :param message: The message of this OfferAvailability. # noqa: E501 + :type: str + """ + + self._message = message + + @property + def min_order_quantity(self): + """Gets the min_order_quantity of this OfferAvailability. # noqa: E501 + + + :return: The min_order_quantity of this OfferAvailability. # noqa: E501 + :rtype: int + """ + return self._min_order_quantity + + @min_order_quantity.setter + def min_order_quantity(self, min_order_quantity): + """Sets the min_order_quantity of this OfferAvailability. + + + :param min_order_quantity: The min_order_quantity of this OfferAvailability. # noqa: E501 + :type: int + """ + + self._min_order_quantity = min_order_quantity + + @property + def type(self): + """Gets the type of this OfferAvailability. # noqa: E501 + + + :return: The type of this OfferAvailability. # noqa: E501 + :rtype: str + """ + return self._type + + @type.setter + def type(self, type): + """Sets the type of this OfferAvailability. + + + :param type: The type of this OfferAvailability. # noqa: E501 + :type: str + """ + + self._type = 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(OfferAvailability, 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, OfferAvailability): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_condition.py b/amazon/paapi5_python_sdk/offer_condition.py new file mode 100644 index 0000000..056091f --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_condition.py @@ -0,0 +1,232 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .offer_sub_condition import OfferSubCondition # noqa: F401,E501 + + +class OfferCondition(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 = { + 'display_value': 'str', + 'label': 'str', + 'locale': 'str', + 'value': 'str', + 'sub_condition': 'OfferSubCondition' + } + + attribute_map = { + 'display_value': 'DisplayValue', + 'label': 'Label', + 'locale': 'Locale', + 'value': 'Value', + 'sub_condition': 'SubCondition' + } + + def __init__(self, display_value=None, label=None, locale=None, value=None, sub_condition=None): # noqa: E501 + """OfferCondition - a model defined in Swagger""" # noqa: E501 + + self._display_value = None + self._label = None + self._locale = None + self._value = None + self._sub_condition = None + self.discriminator = None + + if display_value is not None: + self.display_value = display_value + if label is not None: + self.label = label + if locale is not None: + self.locale = locale + if value is not None: + self.value = value + if sub_condition is not None: + self.sub_condition = sub_condition + + @property + def display_value(self): + """Gets the display_value of this OfferCondition. # noqa: E501 + + + :return: The display_value of this OfferCondition. # noqa: E501 + :rtype: str + """ + return self._display_value + + @display_value.setter + def display_value(self, display_value): + """Sets the display_value of this OfferCondition. + + + :param display_value: The display_value of this OfferCondition. # noqa: E501 + :type: str + """ + + self._display_value = display_value + + @property + def label(self): + """Gets the label of this OfferCondition. # noqa: E501 + + + :return: The label of this OfferCondition. # noqa: E501 + :rtype: str + """ + return self._label + + @label.setter + def label(self, label): + """Sets the label of this OfferCondition. + + + :param label: The label of this OfferCondition. # noqa: E501 + :type: str + """ + + self._label = label + + @property + def locale(self): + """Gets the locale of this OfferCondition. # noqa: E501 + + + :return: The locale of this OfferCondition. # noqa: E501 + :rtype: str + """ + return self._locale + + @locale.setter + def locale(self, locale): + """Sets the locale of this OfferCondition. + + + :param locale: The locale of this OfferCondition. # noqa: E501 + :type: str + """ + + self._locale = locale + + @property + def value(self): + """Gets the value of this OfferCondition. # noqa: E501 + + + :return: The value of this OfferCondition. # noqa: E501 + :rtype: str + """ + return self._value + + @value.setter + def value(self, value): + """Sets the value of this OfferCondition. + + + :param value: The value of this OfferCondition. # noqa: E501 + :type: str + """ + + self._value = value + + @property + def sub_condition(self): + """Gets the sub_condition of this OfferCondition. # noqa: E501 + + + :return: The sub_condition of this OfferCondition. # noqa: E501 + :rtype: OfferSubCondition + """ + return self._sub_condition + + @sub_condition.setter + def sub_condition(self, sub_condition): + """Sets the sub_condition of this OfferCondition. + + + :param sub_condition: The sub_condition of this OfferCondition. # noqa: E501 + :type: OfferSubCondition + """ + + self._sub_condition = sub_condition + + 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(OfferCondition, 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, OfferCondition): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_count.py b/amazon/paapi5_python_sdk/offer_count.py new file mode 100644 index 0000000..951020b --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_count.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class OfferCount(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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """OfferCount - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(OfferCount, 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, OfferCount): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_delivery_info.py b/amazon/paapi5_python_sdk/offer_delivery_info.py new file mode 100644 index 0000000..69ad748 --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_delivery_info.py @@ -0,0 +1,206 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .offer_shipping_charge import OfferShippingCharge # noqa: F401,E501 + + +class OfferDeliveryInfo(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 = { + 'is_amazon_fulfilled': 'bool', + 'is_free_shipping_eligible': 'bool', + 'is_prime_eligible': 'bool', + 'shipping_charges': 'list[OfferShippingCharge]' + } + + attribute_map = { + 'is_amazon_fulfilled': 'IsAmazonFulfilled', + 'is_free_shipping_eligible': 'IsFreeShippingEligible', + 'is_prime_eligible': 'IsPrimeEligible', + 'shipping_charges': 'ShippingCharges' + } + + def __init__(self, is_amazon_fulfilled=None, is_free_shipping_eligible=None, is_prime_eligible=None, shipping_charges=None): # noqa: E501 + """OfferDeliveryInfo - a model defined in Swagger""" # noqa: E501 + + self._is_amazon_fulfilled = None + self._is_free_shipping_eligible = None + self._is_prime_eligible = None + self._shipping_charges = None + self.discriminator = None + + if is_amazon_fulfilled is not None: + self.is_amazon_fulfilled = is_amazon_fulfilled + if is_free_shipping_eligible is not None: + self.is_free_shipping_eligible = is_free_shipping_eligible + if is_prime_eligible is not None: + self.is_prime_eligible = is_prime_eligible + if shipping_charges is not None: + self.shipping_charges = shipping_charges + + @property + def is_amazon_fulfilled(self): + """Gets the is_amazon_fulfilled of this OfferDeliveryInfo. # noqa: E501 + + + :return: The is_amazon_fulfilled of this OfferDeliveryInfo. # noqa: E501 + :rtype: bool + """ + return self._is_amazon_fulfilled + + @is_amazon_fulfilled.setter + def is_amazon_fulfilled(self, is_amazon_fulfilled): + """Sets the is_amazon_fulfilled of this OfferDeliveryInfo. + + + :param is_amazon_fulfilled: The is_amazon_fulfilled of this OfferDeliveryInfo. # noqa: E501 + :type: bool + """ + + self._is_amazon_fulfilled = is_amazon_fulfilled + + @property + def is_free_shipping_eligible(self): + """Gets the is_free_shipping_eligible of this OfferDeliveryInfo. # noqa: E501 + + + :return: The is_free_shipping_eligible of this OfferDeliveryInfo. # noqa: E501 + :rtype: bool + """ + return self._is_free_shipping_eligible + + @is_free_shipping_eligible.setter + def is_free_shipping_eligible(self, is_free_shipping_eligible): + """Sets the is_free_shipping_eligible of this OfferDeliveryInfo. + + + :param is_free_shipping_eligible: The is_free_shipping_eligible of this OfferDeliveryInfo. # noqa: E501 + :type: bool + """ + + self._is_free_shipping_eligible = is_free_shipping_eligible + + @property + def is_prime_eligible(self): + """Gets the is_prime_eligible of this OfferDeliveryInfo. # noqa: E501 + + + :return: The is_prime_eligible of this OfferDeliveryInfo. # noqa: E501 + :rtype: bool + """ + return self._is_prime_eligible + + @is_prime_eligible.setter + def is_prime_eligible(self, is_prime_eligible): + """Sets the is_prime_eligible of this OfferDeliveryInfo. + + + :param is_prime_eligible: The is_prime_eligible of this OfferDeliveryInfo. # noqa: E501 + :type: bool + """ + + self._is_prime_eligible = is_prime_eligible + + @property + def shipping_charges(self): + """Gets the shipping_charges of this OfferDeliveryInfo. # noqa: E501 + + + :return: The shipping_charges of this OfferDeliveryInfo. # noqa: E501 + :rtype: list[OfferShippingCharge] + """ + return self._shipping_charges + + @shipping_charges.setter + def shipping_charges(self, shipping_charges): + """Sets the shipping_charges of this OfferDeliveryInfo. + + + :param shipping_charges: The shipping_charges of this OfferDeliveryInfo. # noqa: E501 + :type: list[OfferShippingCharge] + """ + + self._shipping_charges = shipping_charges + + 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(OfferDeliveryInfo, 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, OfferDeliveryInfo): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_listing.py b/amazon/paapi5_python_sdk/offer_listing.py new file mode 100644 index 0000000..0cb3be6 --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_listing.py @@ -0,0 +1,421 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .offer_availability import OfferAvailability # noqa: F401,E501 +from .offer_condition import OfferCondition # noqa: F401,E501 +from .offer_delivery_info import OfferDeliveryInfo # noqa: F401,E501 +from .offer_loyalty_points import OfferLoyaltyPoints # noqa: F401,E501 +from .offer_merchant_info import OfferMerchantInfo # noqa: F401,E501 +from .offer_price import OfferPrice # noqa: F401,E501 +from .offer_program_eligibility import OfferProgramEligibility # noqa: F401,E501 +from .offer_promotion import OfferPromotion # noqa: F401,E501 + + +class OfferListing(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 = { + 'availability': 'OfferAvailability', + 'condition': 'OfferCondition', + 'delivery_info': 'OfferDeliveryInfo', + 'id': 'str', + 'is_buy_box_winner': 'bool', + 'loyalty_points': 'OfferLoyaltyPoints', + 'merchant_info': 'OfferMerchantInfo', + 'price': 'OfferPrice', + 'program_eligibility': 'OfferProgramEligibility', + 'promotions': 'list[OfferPromotion]', + 'saving_basis': 'OfferPrice', + 'violates_map': 'bool' + } + + attribute_map = { + 'availability': 'Availability', + 'condition': 'Condition', + 'delivery_info': 'DeliveryInfo', + 'id': 'Id', + 'is_buy_box_winner': 'IsBuyBoxWinner', + 'loyalty_points': 'LoyaltyPoints', + 'merchant_info': 'MerchantInfo', + 'price': 'Price', + 'program_eligibility': 'ProgramEligibility', + 'promotions': 'Promotions', + 'saving_basis': 'SavingBasis', + 'violates_map': 'ViolatesMAP' + } + + def __init__(self, availability=None, condition=None, delivery_info=None, id=None, is_buy_box_winner=None, loyalty_points=None, merchant_info=None, price=None, program_eligibility=None, promotions=None, saving_basis=None, violates_map=None): # noqa: E501 + """OfferListing - a model defined in Swagger""" # noqa: E501 + + self._availability = None + self._condition = None + self._delivery_info = None + self._id = None + self._is_buy_box_winner = None + self._loyalty_points = None + self._merchant_info = None + self._price = None + self._program_eligibility = None + self._promotions = None + self._saving_basis = None + self._violates_map = None + self.discriminator = None + + if availability is not None: + self.availability = availability + if condition is not None: + self.condition = condition + if delivery_info is not None: + self.delivery_info = delivery_info + if id is not None: + self.id = id + if is_buy_box_winner is not None: + self.is_buy_box_winner = is_buy_box_winner + if loyalty_points is not None: + self.loyalty_points = loyalty_points + if merchant_info is not None: + self.merchant_info = merchant_info + if price is not None: + self.price = price + if program_eligibility is not None: + self.program_eligibility = program_eligibility + if promotions is not None: + self.promotions = promotions + if saving_basis is not None: + self.saving_basis = saving_basis + if violates_map is not None: + self.violates_map = violates_map + + @property + def availability(self): + """Gets the availability of this OfferListing. # noqa: E501 + + + :return: The availability of this OfferListing. # noqa: E501 + :rtype: OfferAvailability + """ + return self._availability + + @availability.setter + def availability(self, availability): + """Sets the availability of this OfferListing. + + + :param availability: The availability of this OfferListing. # noqa: E501 + :type: OfferAvailability + """ + + self._availability = availability + + @property + def condition(self): + """Gets the condition of this OfferListing. # noqa: E501 + + + :return: The condition of this OfferListing. # noqa: E501 + :rtype: OfferCondition + """ + return self._condition + + @condition.setter + def condition(self, condition): + """Sets the condition of this OfferListing. + + + :param condition: The condition of this OfferListing. # noqa: E501 + :type: OfferCondition + """ + + self._condition = condition + + @property + def delivery_info(self): + """Gets the delivery_info of this OfferListing. # noqa: E501 + + + :return: The delivery_info of this OfferListing. # noqa: E501 + :rtype: OfferDeliveryInfo + """ + return self._delivery_info + + @delivery_info.setter + def delivery_info(self, delivery_info): + """Sets the delivery_info of this OfferListing. + + + :param delivery_info: The delivery_info of this OfferListing. # noqa: E501 + :type: OfferDeliveryInfo + """ + + self._delivery_info = delivery_info + + @property + def id(self): + """Gets the id of this OfferListing. # noqa: E501 + + + :return: The id of this OfferListing. # noqa: E501 + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """Sets the id of this OfferListing. + + + :param id: The id of this OfferListing. # noqa: E501 + :type: str + """ + + self._id = id + + @property + def is_buy_box_winner(self): + """Gets the is_buy_box_winner of this OfferListing. # noqa: E501 + + + :return: The is_buy_box_winner of this OfferListing. # noqa: E501 + :rtype: bool + """ + return self._is_buy_box_winner + + @is_buy_box_winner.setter + def is_buy_box_winner(self, is_buy_box_winner): + """Sets the is_buy_box_winner of this OfferListing. + + + :param is_buy_box_winner: The is_buy_box_winner of this OfferListing. # noqa: E501 + :type: bool + """ + + self._is_buy_box_winner = is_buy_box_winner + + @property + def loyalty_points(self): + """Gets the loyalty_points of this OfferListing. # noqa: E501 + + + :return: The loyalty_points of this OfferListing. # noqa: E501 + :rtype: OfferLoyaltyPoints + """ + return self._loyalty_points + + @loyalty_points.setter + def loyalty_points(self, loyalty_points): + """Sets the loyalty_points of this OfferListing. + + + :param loyalty_points: The loyalty_points of this OfferListing. # noqa: E501 + :type: OfferLoyaltyPoints + """ + + self._loyalty_points = loyalty_points + + @property + def merchant_info(self): + """Gets the merchant_info of this OfferListing. # noqa: E501 + + + :return: The merchant_info of this OfferListing. # noqa: E501 + :rtype: OfferMerchantInfo + """ + return self._merchant_info + + @merchant_info.setter + def merchant_info(self, merchant_info): + """Sets the merchant_info of this OfferListing. + + + :param merchant_info: The merchant_info of this OfferListing. # noqa: E501 + :type: OfferMerchantInfo + """ + + self._merchant_info = merchant_info + + @property + def price(self): + """Gets the price of this OfferListing. # noqa: E501 + + + :return: The price of this OfferListing. # noqa: E501 + :rtype: OfferPrice + """ + return self._price + + @price.setter + def price(self, price): + """Sets the price of this OfferListing. + + + :param price: The price of this OfferListing. # noqa: E501 + :type: OfferPrice + """ + + self._price = price + + @property + def program_eligibility(self): + """Gets the program_eligibility of this OfferListing. # noqa: E501 + + + :return: The program_eligibility of this OfferListing. # noqa: E501 + :rtype: OfferProgramEligibility + """ + return self._program_eligibility + + @program_eligibility.setter + def program_eligibility(self, program_eligibility): + """Sets the program_eligibility of this OfferListing. + + + :param program_eligibility: The program_eligibility of this OfferListing. # noqa: E501 + :type: OfferProgramEligibility + """ + + self._program_eligibility = program_eligibility + + @property + def promotions(self): + """Gets the promotions of this OfferListing. # noqa: E501 + + + :return: The promotions of this OfferListing. # noqa: E501 + :rtype: list[OfferPromotion] + """ + return self._promotions + + @promotions.setter + def promotions(self, promotions): + """Sets the promotions of this OfferListing. + + + :param promotions: The promotions of this OfferListing. # noqa: E501 + :type: list[OfferPromotion] + """ + + self._promotions = promotions + + @property + def saving_basis(self): + """Gets the saving_basis of this OfferListing. # noqa: E501 + + + :return: The saving_basis of this OfferListing. # noqa: E501 + :rtype: OfferPrice + """ + return self._saving_basis + + @saving_basis.setter + def saving_basis(self, saving_basis): + """Sets the saving_basis of this OfferListing. + + + :param saving_basis: The saving_basis of this OfferListing. # noqa: E501 + :type: OfferPrice + """ + + self._saving_basis = saving_basis + + @property + def violates_map(self): + """Gets the violates_map of this OfferListing. # noqa: E501 + + + :return: The violates_map of this OfferListing. # noqa: E501 + :rtype: bool + """ + return self._violates_map + + @violates_map.setter + def violates_map(self, violates_map): + """Sets the violates_map of this OfferListing. + + + :param violates_map: The violates_map of this OfferListing. # noqa: E501 + :type: bool + """ + + self._violates_map = violates_map + + 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(OfferListing, 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, OfferListing): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_loyalty_points.py b/amazon/paapi5_python_sdk/offer_loyalty_points.py new file mode 100644 index 0000000..08b86e9 --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_loyalty_points.py @@ -0,0 +1,126 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class OfferLoyaltyPoints(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 = { + 'points': 'int' + } + + attribute_map = { + 'points': 'Points' + } + + def __init__(self, points=None): # noqa: E501 + """OfferLoyaltyPoints - a model defined in Swagger""" # noqa: E501 + + self._points = None + self.discriminator = None + + if points is not None: + self.points = points + + @property + def points(self): + """Gets the points of this OfferLoyaltyPoints. # noqa: E501 + + + :return: The points of this OfferLoyaltyPoints. # noqa: E501 + :rtype: int + """ + return self._points + + @points.setter + def points(self, points): + """Sets the points of this OfferLoyaltyPoints. + + + :param points: The points of this OfferLoyaltyPoints. # noqa: E501 + :type: int + """ + + self._points = points + + 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(OfferLoyaltyPoints, 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, OfferLoyaltyPoints): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_merchant_info.py b/amazon/paapi5_python_sdk/offer_merchant_info.py new file mode 100644 index 0000000..b0ec576 --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_merchant_info.py @@ -0,0 +1,178 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class OfferMerchantInfo(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 = { + 'default_shipping_country': 'str', + 'id': 'str', + 'name': 'str' + } + + attribute_map = { + 'default_shipping_country': 'DefaultShippingCountry', + 'id': 'Id', + 'name': 'Name' + } + + def __init__(self, default_shipping_country=None, id=None, name=None): # noqa: E501 + """OfferMerchantInfo - a model defined in Swagger""" # noqa: E501 + + self._default_shipping_country = None + self._id = None + self._name = None + self.discriminator = None + + if default_shipping_country is not None: + self.default_shipping_country = default_shipping_country + if id is not None: + self.id = id + if name is not None: + self.name = name + + @property + def default_shipping_country(self): + """Gets the default_shipping_country of this OfferMerchantInfo. # noqa: E501 + + + :return: The default_shipping_country of this OfferMerchantInfo. # noqa: E501 + :rtype: str + """ + return self._default_shipping_country + + @default_shipping_country.setter + def default_shipping_country(self, default_shipping_country): + """Sets the default_shipping_country of this OfferMerchantInfo. + + + :param default_shipping_country: The default_shipping_country of this OfferMerchantInfo. # noqa: E501 + :type: str + """ + + self._default_shipping_country = default_shipping_country + + @property + def id(self): + """Gets the id of this OfferMerchantInfo. # noqa: E501 + + + :return: The id of this OfferMerchantInfo. # noqa: E501 + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """Sets the id of this OfferMerchantInfo. + + + :param id: The id of this OfferMerchantInfo. # noqa: E501 + :type: str + """ + + self._id = id + + @property + def name(self): + """Gets the name of this OfferMerchantInfo. # noqa: E501 + + + :return: The name of this OfferMerchantInfo. # noqa: E501 + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """Sets the name of this OfferMerchantInfo. + + + :param name: The name of this OfferMerchantInfo. # noqa: E501 + :type: str + """ + + self._name = name + + 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(OfferMerchantInfo, 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, OfferMerchantInfo): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_price.py b/amazon/paapi5_python_sdk/offer_price.py new file mode 100644 index 0000000..343c9b5 --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_price.py @@ -0,0 +1,232 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .offer_savings import OfferSavings # noqa: F401,E501 + + +class OfferPrice(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 = { + 'amount': 'float', + 'currency': 'str', + 'display_amount': 'str', + 'price_per_unit': 'float', + 'savings': 'OfferSavings' + } + + attribute_map = { + 'amount': 'Amount', + 'currency': 'Currency', + 'display_amount': 'DisplayAmount', + 'price_per_unit': 'PricePerUnit', + 'savings': 'Savings' + } + + def __init__(self, amount=None, currency=None, display_amount=None, price_per_unit=None, savings=None): # noqa: E501 + """OfferPrice - a model defined in Swagger""" # noqa: E501 + + self._amount = None + self._currency = None + self._display_amount = None + self._price_per_unit = None + self._savings = None + self.discriminator = None + + if amount is not None: + self.amount = amount + if currency is not None: + self.currency = currency + if display_amount is not None: + self.display_amount = display_amount + if price_per_unit is not None: + self.price_per_unit = price_per_unit + if savings is not None: + self.savings = savings + + @property + def amount(self): + """Gets the amount of this OfferPrice. # noqa: E501 + + + :return: The amount of this OfferPrice. # noqa: E501 + :rtype: float + """ + return self._amount + + @amount.setter + def amount(self, amount): + """Sets the amount of this OfferPrice. + + + :param amount: The amount of this OfferPrice. # noqa: E501 + :type: float + """ + + self._amount = amount + + @property + def currency(self): + """Gets the currency of this OfferPrice. # noqa: E501 + + + :return: The currency of this OfferPrice. # noqa: E501 + :rtype: str + """ + return self._currency + + @currency.setter + def currency(self, currency): + """Sets the currency of this OfferPrice. + + + :param currency: The currency of this OfferPrice. # noqa: E501 + :type: str + """ + + self._currency = currency + + @property + def display_amount(self): + """Gets the display_amount of this OfferPrice. # noqa: E501 + + + :return: The display_amount of this OfferPrice. # noqa: E501 + :rtype: str + """ + return self._display_amount + + @display_amount.setter + def display_amount(self, display_amount): + """Sets the display_amount of this OfferPrice. + + + :param display_amount: The display_amount of this OfferPrice. # noqa: E501 + :type: str + """ + + self._display_amount = display_amount + + @property + def price_per_unit(self): + """Gets the price_per_unit of this OfferPrice. # noqa: E501 + + + :return: The price_per_unit of this OfferPrice. # noqa: E501 + :rtype: float + """ + return self._price_per_unit + + @price_per_unit.setter + def price_per_unit(self, price_per_unit): + """Sets the price_per_unit of this OfferPrice. + + + :param price_per_unit: The price_per_unit of this OfferPrice. # noqa: E501 + :type: float + """ + + self._price_per_unit = price_per_unit + + @property + def savings(self): + """Gets the savings of this OfferPrice. # noqa: E501 + + + :return: The savings of this OfferPrice. # noqa: E501 + :rtype: OfferSavings + """ + return self._savings + + @savings.setter + def savings(self, savings): + """Sets the savings of this OfferPrice. + + + :param savings: The savings of this OfferPrice. # noqa: E501 + :type: OfferSavings + """ + + self._savings = savings + + 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(OfferPrice, 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, OfferPrice): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_program_eligibility.py b/amazon/paapi5_python_sdk/offer_program_eligibility.py new file mode 100644 index 0000000..ffeaa6c --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_program_eligibility.py @@ -0,0 +1,152 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class OfferProgramEligibility(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 = { + 'is_prime_exclusive': 'bool', + 'is_prime_pantry': 'bool' + } + + attribute_map = { + 'is_prime_exclusive': 'IsPrimeExclusive', + 'is_prime_pantry': 'IsPrimePantry' + } + + def __init__(self, is_prime_exclusive=None, is_prime_pantry=None): # noqa: E501 + """OfferProgramEligibility - a model defined in Swagger""" # noqa: E501 + + self._is_prime_exclusive = None + self._is_prime_pantry = None + self.discriminator = None + + if is_prime_exclusive is not None: + self.is_prime_exclusive = is_prime_exclusive + if is_prime_pantry is not None: + self.is_prime_pantry = is_prime_pantry + + @property + def is_prime_exclusive(self): + """Gets the is_prime_exclusive of this OfferProgramEligibility. # noqa: E501 + + + :return: The is_prime_exclusive of this OfferProgramEligibility. # noqa: E501 + :rtype: bool + """ + return self._is_prime_exclusive + + @is_prime_exclusive.setter + def is_prime_exclusive(self, is_prime_exclusive): + """Sets the is_prime_exclusive of this OfferProgramEligibility. + + + :param is_prime_exclusive: The is_prime_exclusive of this OfferProgramEligibility. # noqa: E501 + :type: bool + """ + + self._is_prime_exclusive = is_prime_exclusive + + @property + def is_prime_pantry(self): + """Gets the is_prime_pantry of this OfferProgramEligibility. # noqa: E501 + + + :return: The is_prime_pantry of this OfferProgramEligibility. # noqa: E501 + :rtype: bool + """ + return self._is_prime_pantry + + @is_prime_pantry.setter + def is_prime_pantry(self, is_prime_pantry): + """Sets the is_prime_pantry of this OfferProgramEligibility. + + + :param is_prime_pantry: The is_prime_pantry of this OfferProgramEligibility. # noqa: E501 + :type: bool + """ + + self._is_prime_pantry = is_prime_pantry + + 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(OfferProgramEligibility, 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, OfferProgramEligibility): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_promotion.py b/amazon/paapi5_python_sdk/offer_promotion.py new file mode 100644 index 0000000..d161a4b --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_promotion.py @@ -0,0 +1,255 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +class OfferPromotion(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 = { + 'amount': 'float', + 'currency': 'str', + 'discount_percent': 'int', + 'display_amount': 'str', + 'price_per_unit': 'float', + 'type': 'str' + } + + attribute_map = { + 'amount': 'Amount', + 'currency': 'Currency', + 'discount_percent': 'DiscountPercent', + 'display_amount': 'DisplayAmount', + 'price_per_unit': 'PricePerUnit', + 'type': 'Type' + } + + def __init__(self, amount=None, currency=None, discount_percent=None, display_amount=None, price_per_unit=None, type=None): # noqa: E501 + """OfferPromotion - a model defined in Swagger""" # noqa: E501 + + self._amount = None + self._currency = None + self._discount_percent = None + self._display_amount = None + self._price_per_unit = None + self._type = None + self.discriminator = None + + if amount is not None: + self.amount = amount + if currency is not None: + self.currency = currency + if discount_percent is not None: + self.discount_percent = discount_percent + if display_amount is not None: + self.display_amount = display_amount + if price_per_unit is not None: + self.price_per_unit = price_per_unit + if type is not None: + self.type = type + + @property + def amount(self): + """Gets the amount of this OfferPromotion. # noqa: E501 + + + :return: The amount of this OfferPromotion. # noqa: E501 + :rtype: float + """ + return self._amount + + @amount.setter + def amount(self, amount): + """Sets the amount of this OfferPromotion. + + + :param amount: The amount of this OfferPromotion. # noqa: E501 + :type: float + """ + + self._amount = amount + + @property + def currency(self): + """Gets the currency of this OfferPromotion. # noqa: E501 + + + :return: The currency of this OfferPromotion. # noqa: E501 + :rtype: str + """ + return self._currency + + @currency.setter + def currency(self, currency): + """Sets the currency of this OfferPromotion. + + + :param currency: The currency of this OfferPromotion. # noqa: E501 + :type: str + """ + + self._currency = currency + + @property + def discount_percent(self): + """Gets the discount_percent of this OfferPromotion. # noqa: E501 + + + :return: The discount_percent of this OfferPromotion. # noqa: E501 + :rtype: int + """ + return self._discount_percent + + @discount_percent.setter + def discount_percent(self, discount_percent): + """Sets the discount_percent of this OfferPromotion. + + + :param discount_percent: The discount_percent of this OfferPromotion. # noqa: E501 + :type: int + """ + + self._discount_percent = discount_percent + + @property + def display_amount(self): + """Gets the display_amount of this OfferPromotion. # noqa: E501 + + + :return: The display_amount of this OfferPromotion. # noqa: E501 + :rtype: str + """ + return self._display_amount + + @display_amount.setter + def display_amount(self, display_amount): + """Sets the display_amount of this OfferPromotion. + + + :param display_amount: The display_amount of this OfferPromotion. # noqa: E501 + :type: str + """ + + self._display_amount = display_amount + + @property + def price_per_unit(self): + """Gets the price_per_unit of this OfferPromotion. # noqa: E501 + + + :return: The price_per_unit of this OfferPromotion. # noqa: E501 + :rtype: float + """ + return self._price_per_unit + + @price_per_unit.setter + def price_per_unit(self, price_per_unit): + """Sets the price_per_unit of this OfferPromotion. + + + :param price_per_unit: The price_per_unit of this OfferPromotion. # noqa: E501 + :type: float + """ + + self._price_per_unit = price_per_unit + + @property + def type(self): + """Gets the type of this OfferPromotion. # noqa: E501 + + + :return: The type of this OfferPromotion. # noqa: E501 + :rtype: str + """ + return self._type + + @type.setter + def type(self, type): + """Sets the type of this OfferPromotion. + + + :param type: The type of this OfferPromotion. # noqa: E501 + :type: str + """ + + self._type = 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(OfferPromotion, 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, OfferPromotion): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_savings.py b/amazon/paapi5_python_sdk/offer_savings.py new file mode 100644 index 0000000..42c5eb9 --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_savings.py @@ -0,0 +1,230 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class OfferSavings(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 = { + 'amount': 'float', + 'currency': 'str', + 'display_amount': 'str', + 'percentage': 'int', + 'price_per_unit': 'float' + } + + attribute_map = { + 'amount': 'Amount', + 'currency': 'Currency', + 'display_amount': 'DisplayAmount', + 'percentage': 'Percentage', + 'price_per_unit': 'PricePerUnit' + } + + def __init__(self, amount=None, currency=None, display_amount=None, percentage=None, price_per_unit=None): # noqa: E501 + """OfferSavings - a model defined in Swagger""" # noqa: E501 + + self._amount = None + self._currency = None + self._display_amount = None + self._percentage = None + self._price_per_unit = None + self.discriminator = None + + if amount is not None: + self.amount = amount + if currency is not None: + self.currency = currency + if display_amount is not None: + self.display_amount = display_amount + if percentage is not None: + self.percentage = percentage + if price_per_unit is not None: + self.price_per_unit = price_per_unit + + @property + def amount(self): + """Gets the amount of this OfferSavings. # noqa: E501 + + + :return: The amount of this OfferSavings. # noqa: E501 + :rtype: float + """ + return self._amount + + @amount.setter + def amount(self, amount): + """Sets the amount of this OfferSavings. + + + :param amount: The amount of this OfferSavings. # noqa: E501 + :type: float + """ + + self._amount = amount + + @property + def currency(self): + """Gets the currency of this OfferSavings. # noqa: E501 + + + :return: The currency of this OfferSavings. # noqa: E501 + :rtype: str + """ + return self._currency + + @currency.setter + def currency(self, currency): + """Sets the currency of this OfferSavings. + + + :param currency: The currency of this OfferSavings. # noqa: E501 + :type: str + """ + + self._currency = currency + + @property + def display_amount(self): + """Gets the display_amount of this OfferSavings. # noqa: E501 + + + :return: The display_amount of this OfferSavings. # noqa: E501 + :rtype: str + """ + return self._display_amount + + @display_amount.setter + def display_amount(self, display_amount): + """Sets the display_amount of this OfferSavings. + + + :param display_amount: The display_amount of this OfferSavings. # noqa: E501 + :type: str + """ + + self._display_amount = display_amount + + @property + def percentage(self): + """Gets the percentage of this OfferSavings. # noqa: E501 + + + :return: The percentage of this OfferSavings. # noqa: E501 + :rtype: int + """ + return self._percentage + + @percentage.setter + def percentage(self, percentage): + """Sets the percentage of this OfferSavings. + + + :param percentage: The percentage of this OfferSavings. # noqa: E501 + :type: int + """ + + self._percentage = percentage + + @property + def price_per_unit(self): + """Gets the price_per_unit of this OfferSavings. # noqa: E501 + + + :return: The price_per_unit of this OfferSavings. # noqa: E501 + :rtype: float + """ + return self._price_per_unit + + @price_per_unit.setter + def price_per_unit(self, price_per_unit): + """Sets the price_per_unit of this OfferSavings. + + + :param price_per_unit: The price_per_unit of this OfferSavings. # noqa: E501 + :type: float + """ + + self._price_per_unit = price_per_unit + + 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(OfferSavings, 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, OfferSavings): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_shipping_charge.py b/amazon/paapi5_python_sdk/offer_shipping_charge.py new file mode 100644 index 0000000..5674f19 --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_shipping_charge.py @@ -0,0 +1,229 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +class OfferShippingCharge(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 = { + 'amount': 'float', + 'currency': 'str', + 'display_amount': 'str', + 'is_rate_tax_inclusive': 'bool', + 'type': 'str' + } + + attribute_map = { + 'amount': 'Amount', + 'currency': 'Currency', + 'display_amount': 'DisplayAmount', + 'is_rate_tax_inclusive': 'IsRateTaxInclusive', + 'type': 'Type' + } + + def __init__(self, amount=None, currency=None, display_amount=None, is_rate_tax_inclusive=None, type=None): # noqa: E501 + """OfferShippingCharge - a model defined in Swagger""" # noqa: E501 + + self._amount = None + self._currency = None + self._display_amount = None + self._is_rate_tax_inclusive = None + self._type = None + self.discriminator = None + + if amount is not None: + self.amount = amount + if currency is not None: + self.currency = currency + if display_amount is not None: + self.display_amount = display_amount + if is_rate_tax_inclusive is not None: + self.is_rate_tax_inclusive = is_rate_tax_inclusive + if type is not None: + self.type = type + + @property + def amount(self): + """Gets the amount of this OfferShippingCharge. # noqa: E501 + + + :return: The amount of this OfferShippingCharge. # noqa: E501 + :rtype: float + """ + return self._amount + + @amount.setter + def amount(self, amount): + """Sets the amount of this OfferShippingCharge. + + + :param amount: The amount of this OfferShippingCharge. # noqa: E501 + :type: float + """ + + self._amount = amount + + @property + def currency(self): + """Gets the currency of this OfferShippingCharge. # noqa: E501 + + + :return: The currency of this OfferShippingCharge. # noqa: E501 + :rtype: str + """ + return self._currency + + @currency.setter + def currency(self, currency): + """Sets the currency of this OfferShippingCharge. + + + :param currency: The currency of this OfferShippingCharge. # noqa: E501 + :type: str + """ + + self._currency = currency + + @property + def display_amount(self): + """Gets the display_amount of this OfferShippingCharge. # noqa: E501 + + + :return: The display_amount of this OfferShippingCharge. # noqa: E501 + :rtype: str + """ + return self._display_amount + + @display_amount.setter + def display_amount(self, display_amount): + """Sets the display_amount of this OfferShippingCharge. + + + :param display_amount: The display_amount of this OfferShippingCharge. # noqa: E501 + :type: str + """ + + self._display_amount = display_amount + + @property + def is_rate_tax_inclusive(self): + """Gets the is_rate_tax_inclusive of this OfferShippingCharge. # noqa: E501 + + + :return: The is_rate_tax_inclusive of this OfferShippingCharge. # noqa: E501 + :rtype: bool + """ + return self._is_rate_tax_inclusive + + @is_rate_tax_inclusive.setter + def is_rate_tax_inclusive(self, is_rate_tax_inclusive): + """Sets the is_rate_tax_inclusive of this OfferShippingCharge. + + + :param is_rate_tax_inclusive: The is_rate_tax_inclusive of this OfferShippingCharge. # noqa: E501 + :type: bool + """ + + self._is_rate_tax_inclusive = is_rate_tax_inclusive + + @property + def type(self): + """Gets the type of this OfferShippingCharge. # noqa: E501 + + + :return: The type of this OfferShippingCharge. # noqa: E501 + :rtype: str + """ + return self._type + + @type.setter + def type(self, type): + """Sets the type of this OfferShippingCharge. + + + :param type: The type of this OfferShippingCharge. # noqa: E501 + :type: str + """ + + self._type = 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(OfferShippingCharge, 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, OfferShippingCharge): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_sub_condition.py b/amazon/paapi5_python_sdk/offer_sub_condition.py new file mode 100644 index 0000000..bb5be69 --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_sub_condition.py @@ -0,0 +1,204 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class OfferSubCondition(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 = { + 'display_value': 'str', + 'label': 'str', + 'locale': 'str', + 'value': 'str' + } + + attribute_map = { + 'display_value': 'DisplayValue', + 'label': 'Label', + 'locale': 'Locale', + 'value': 'Value' + } + + def __init__(self, display_value=None, label=None, locale=None, value=None): # noqa: E501 + """OfferSubCondition - a model defined in Swagger""" # noqa: E501 + + self._display_value = None + self._label = None + self._locale = None + self._value = None + self.discriminator = None + + if display_value is not None: + self.display_value = display_value + if label is not None: + self.label = label + if locale is not None: + self.locale = locale + if value is not None: + self.value = value + + @property + def display_value(self): + """Gets the display_value of this OfferSubCondition. # noqa: E501 + + + :return: The display_value of this OfferSubCondition. # noqa: E501 + :rtype: str + """ + return self._display_value + + @display_value.setter + def display_value(self, display_value): + """Sets the display_value of this OfferSubCondition. + + + :param display_value: The display_value of this OfferSubCondition. # noqa: E501 + :type: str + """ + + self._display_value = display_value + + @property + def label(self): + """Gets the label of this OfferSubCondition. # noqa: E501 + + + :return: The label of this OfferSubCondition. # noqa: E501 + :rtype: str + """ + return self._label + + @label.setter + def label(self, label): + """Sets the label of this OfferSubCondition. + + + :param label: The label of this OfferSubCondition. # noqa: E501 + :type: str + """ + + self._label = label + + @property + def locale(self): + """Gets the locale of this OfferSubCondition. # noqa: E501 + + + :return: The locale of this OfferSubCondition. # noqa: E501 + :rtype: str + """ + return self._locale + + @locale.setter + def locale(self, locale): + """Sets the locale of this OfferSubCondition. + + + :param locale: The locale of this OfferSubCondition. # noqa: E501 + :type: str + """ + + self._locale = locale + + @property + def value(self): + """Gets the value of this OfferSubCondition. # noqa: E501 + + + :return: The value of this OfferSubCondition. # noqa: E501 + :rtype: str + """ + return self._value + + @value.setter + def value(self, value): + """Sets the value of this OfferSubCondition. + + + :param value: The value of this OfferSubCondition. # noqa: E501 + :type: str + """ + + self._value = value + + 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(OfferSubCondition, 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, OfferSubCondition): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offer_summary.py b/amazon/paapi5_python_sdk/offer_summary.py new file mode 100644 index 0000000..f2363b2 --- /dev/null +++ b/amazon/paapi5_python_sdk/offer_summary.py @@ -0,0 +1,207 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .offer_condition import OfferCondition # noqa: F401,E501 +from .offer_price import OfferPrice # noqa: F401,E501 + + +class OfferSummary(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 = { + 'condition': 'OfferCondition', + 'highest_price': 'OfferPrice', + 'lowest_price': 'OfferPrice', + 'offer_count': 'int' + } + + attribute_map = { + 'condition': 'Condition', + 'highest_price': 'HighestPrice', + 'lowest_price': 'LowestPrice', + 'offer_count': 'OfferCount' + } + + def __init__(self, condition=None, highest_price=None, lowest_price=None, offer_count=None): # noqa: E501 + """OfferSummary - a model defined in Swagger""" # noqa: E501 + + self._condition = None + self._highest_price = None + self._lowest_price = None + self._offer_count = None + self.discriminator = None + + if condition is not None: + self.condition = condition + if highest_price is not None: + self.highest_price = highest_price + if lowest_price is not None: + self.lowest_price = lowest_price + if offer_count is not None: + self.offer_count = offer_count + + @property + def condition(self): + """Gets the condition of this OfferSummary. # noqa: E501 + + + :return: The condition of this OfferSummary. # noqa: E501 + :rtype: OfferCondition + """ + return self._condition + + @condition.setter + def condition(self, condition): + """Sets the condition of this OfferSummary. + + + :param condition: The condition of this OfferSummary. # noqa: E501 + :type: OfferCondition + """ + + self._condition = condition + + @property + def highest_price(self): + """Gets the highest_price of this OfferSummary. # noqa: E501 + + + :return: The highest_price of this OfferSummary. # noqa: E501 + :rtype: OfferPrice + """ + return self._highest_price + + @highest_price.setter + def highest_price(self, highest_price): + """Sets the highest_price of this OfferSummary. + + + :param highest_price: The highest_price of this OfferSummary. # noqa: E501 + :type: OfferPrice + """ + + self._highest_price = highest_price + + @property + def lowest_price(self): + """Gets the lowest_price of this OfferSummary. # noqa: E501 + + + :return: The lowest_price of this OfferSummary. # noqa: E501 + :rtype: OfferPrice + """ + return self._lowest_price + + @lowest_price.setter + def lowest_price(self, lowest_price): + """Sets the lowest_price of this OfferSummary. + + + :param lowest_price: The lowest_price of this OfferSummary. # noqa: E501 + :type: OfferPrice + """ + + self._lowest_price = lowest_price + + @property + def offer_count(self): + """Gets the offer_count of this OfferSummary. # noqa: E501 + + + :return: The offer_count of this OfferSummary. # noqa: E501 + :rtype: int + """ + return self._offer_count + + @offer_count.setter + def offer_count(self, offer_count): + """Sets the offer_count of this OfferSummary. + + + :param offer_count: The offer_count of this OfferSummary. # noqa: E501 + :type: int + """ + + self._offer_count = offer_count + + 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(OfferSummary, 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, OfferSummary): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/offers.py b/amazon/paapi5_python_sdk/offers.py new file mode 100644 index 0000000..4565b7b --- /dev/null +++ b/amazon/paapi5_python_sdk/offers.py @@ -0,0 +1,155 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .offer_listing import OfferListing # noqa: F401,E501 +from .offer_summary import OfferSummary # noqa: F401,E501 + + +class Offers(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 = { + 'listings': 'list[OfferListing]', + 'summaries': 'list[OfferSummary]' + } + + attribute_map = { + 'listings': 'Listings', + 'summaries': 'Summaries' + } + + def __init__(self, listings=None, summaries=None): # noqa: E501 + """Offers - a model defined in Swagger""" # noqa: E501 + + self._listings = None + self._summaries = None + self.discriminator = None + + if listings is not None: + self.listings = listings + if summaries is not None: + self.summaries = summaries + + @property + def listings(self): + """Gets the listings of this Offers. # noqa: E501 + + + :return: The listings of this Offers. # noqa: E501 + :rtype: list[OfferListing] + """ + return self._listings + + @listings.setter + def listings(self, listings): + """Sets the listings of this Offers. + + + :param listings: The listings of this Offers. # noqa: E501 + :type: list[OfferListing] + """ + + self._listings = listings + + @property + def summaries(self): + """Gets the summaries of this Offers. # noqa: E501 + + + :return: The summaries of this Offers. # noqa: E501 + :rtype: list[OfferSummary] + """ + return self._summaries + + @summaries.setter + def summaries(self, summaries): + """Sets the summaries of this Offers. + + + :param summaries: The summaries of this Offers. # noqa: E501 + :type: list[OfferSummary] + """ + + self._summaries = summaries + + 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(Offers, 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, Offers): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/partner_type.py b/amazon/paapi5_python_sdk/partner_type.py new file mode 100644 index 0000000..37f9a39 --- /dev/null +++ b/amazon/paapi5_python_sdk/partner_type.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class PartnerType(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + allowed enum values + """ + ASSOCIATES = "Associates" + + """ + 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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """PartnerType - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(PartnerType, 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, PartnerType): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/price.py b/amazon/paapi5_python_sdk/price.py new file mode 100644 index 0000000..9fa403c --- /dev/null +++ b/amazon/paapi5_python_sdk/price.py @@ -0,0 +1,154 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .offer_price import OfferPrice # noqa: F401,E501 + + +class Price(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 = { + 'highest_price': 'OfferPrice', + 'lowest_price': 'OfferPrice' + } + + attribute_map = { + 'highest_price': 'HighestPrice', + 'lowest_price': 'LowestPrice' + } + + def __init__(self, highest_price=None, lowest_price=None): # noqa: E501 + """Price - a model defined in Swagger""" # noqa: E501 + + self._highest_price = None + self._lowest_price = None + self.discriminator = None + + if highest_price is not None: + self.highest_price = highest_price + if lowest_price is not None: + self.lowest_price = lowest_price + + @property + def highest_price(self): + """Gets the highest_price of this Price. # noqa: E501 + + + :return: The highest_price of this Price. # noqa: E501 + :rtype: OfferPrice + """ + return self._highest_price + + @highest_price.setter + def highest_price(self, highest_price): + """Sets the highest_price of this Price. + + + :param highest_price: The highest_price of this Price. # noqa: E501 + :type: OfferPrice + """ + + self._highest_price = highest_price + + @property + def lowest_price(self): + """Gets the lowest_price of this Price. # noqa: E501 + + + :return: The lowest_price of this Price. # noqa: E501 + :rtype: OfferPrice + """ + return self._lowest_price + + @lowest_price.setter + def lowest_price(self, lowest_price): + """Sets the lowest_price of this Price. + + + :param lowest_price: The lowest_price of this Price. # noqa: E501 + :type: OfferPrice + """ + + self._lowest_price = lowest_price + + 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(Price, 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, Price): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/product_advertising_api_client_exception.py b/amazon/paapi5_python_sdk/product_advertising_api_client_exception.py new file mode 100644 index 0000000..2e5cd35 --- /dev/null +++ b/amazon/paapi5_python_sdk/product_advertising_api_client_exception.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .error_data import ErrorData # noqa: F401,E501 + + +class ProductAdvertisingAPIClientException(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 = { + 'errors': 'list[ErrorData]' + } + + attribute_map = { + 'errors': 'Errors' + } + + def __init__(self, errors=None): # noqa: E501 + """ProductAdvertisingAPIClientException - a model defined in Swagger""" # noqa: E501 + + self._errors = None + self.discriminator = None + + if errors is not None: + self.errors = errors + + @property + def errors(self): + """Gets the errors of this ProductAdvertisingAPIClientException. # noqa: E501 + + + :return: The errors of this ProductAdvertisingAPIClientException. # noqa: E501 + :rtype: list[ErrorData] + """ + return self._errors + + @errors.setter + def errors(self, errors): + """Sets the errors of this ProductAdvertisingAPIClientException. + + + :param errors: The errors of this ProductAdvertisingAPIClientException. # noqa: E501 + :type: list[ErrorData] + """ + + self._errors = errors + + 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(ProductAdvertisingAPIClientException, 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, ProductAdvertisingAPIClientException): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/product_advertising_api_service_exception.py b/amazon/paapi5_python_sdk/product_advertising_api_service_exception.py new file mode 100644 index 0000000..957d9d4 --- /dev/null +++ b/amazon/paapi5_python_sdk/product_advertising_api_service_exception.py @@ -0,0 +1,126 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class ProductAdvertisingAPIServiceException(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 = { + 'message': 'str' + } + + attribute_map = { + 'message': 'message' + } + + def __init__(self, message=None): # noqa: E501 + """ProductAdvertisingAPIServiceException - a model defined in Swagger""" # noqa: E501 + + self._message = None + self.discriminator = None + + if message is not None: + self.message = message + + @property + def message(self): + """Gets the message of this ProductAdvertisingAPIServiceException. # noqa: E501 + + + :return: The message of this ProductAdvertisingAPIServiceException. # noqa: E501 + :rtype: str + """ + return self._message + + @message.setter + def message(self, message): + """Sets the message of this ProductAdvertisingAPIServiceException. + + + :param message: The message of this ProductAdvertisingAPIServiceException. # noqa: E501 + :type: str + """ + + self._message = message + + 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(ProductAdvertisingAPIServiceException, 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, ProductAdvertisingAPIServiceException): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/product_info.py b/amazon/paapi5_python_sdk/product_info.py new file mode 100644 index 0000000..d0558d1 --- /dev/null +++ b/amazon/paapi5_python_sdk/product_info.py @@ -0,0 +1,261 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .dimension_based_attribute import DimensionBasedAttribute # noqa: F401,E501 +from .single_boolean_valued_attribute import SingleBooleanValuedAttribute # noqa: F401,E501 +from .single_integer_valued_attribute import SingleIntegerValuedAttribute # noqa: F401,E501 +from .single_string_valued_attribute import SingleStringValuedAttribute # noqa: F401,E501 + + +class ProductInfo(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 = { + 'color': 'SingleStringValuedAttribute', + 'is_adult_product': 'SingleBooleanValuedAttribute', + 'item_dimensions': 'DimensionBasedAttribute', + 'release_date': 'SingleStringValuedAttribute', + 'size': 'SingleStringValuedAttribute', + 'unit_count': 'SingleIntegerValuedAttribute' + } + + attribute_map = { + 'color': 'Color', + 'is_adult_product': 'IsAdultProduct', + 'item_dimensions': 'ItemDimensions', + 'release_date': 'ReleaseDate', + 'size': 'Size', + 'unit_count': 'UnitCount' + } + + def __init__(self, color=None, is_adult_product=None, item_dimensions=None, release_date=None, size=None, unit_count=None): # noqa: E501 + """ProductInfo - a model defined in Swagger""" # noqa: E501 + + self._color = None + self._is_adult_product = None + self._item_dimensions = None + self._release_date = None + self._size = None + self._unit_count = None + self.discriminator = None + + if color is not None: + self.color = color + if is_adult_product is not None: + self.is_adult_product = is_adult_product + if item_dimensions is not None: + self.item_dimensions = item_dimensions + if release_date is not None: + self.release_date = release_date + if size is not None: + self.size = size + if unit_count is not None: + self.unit_count = unit_count + + @property + def color(self): + """Gets the color of this ProductInfo. # noqa: E501 + + + :return: The color of this ProductInfo. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._color + + @color.setter + def color(self, color): + """Sets the color of this ProductInfo. + + + :param color: The color of this ProductInfo. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._color = color + + @property + def is_adult_product(self): + """Gets the is_adult_product of this ProductInfo. # noqa: E501 + + + :return: The is_adult_product of this ProductInfo. # noqa: E501 + :rtype: SingleBooleanValuedAttribute + """ + return self._is_adult_product + + @is_adult_product.setter + def is_adult_product(self, is_adult_product): + """Sets the is_adult_product of this ProductInfo. + + + :param is_adult_product: The is_adult_product of this ProductInfo. # noqa: E501 + :type: SingleBooleanValuedAttribute + """ + + self._is_adult_product = is_adult_product + + @property + def item_dimensions(self): + """Gets the item_dimensions of this ProductInfo. # noqa: E501 + + + :return: The item_dimensions of this ProductInfo. # noqa: E501 + :rtype: DimensionBasedAttribute + """ + return self._item_dimensions + + @item_dimensions.setter + def item_dimensions(self, item_dimensions): + """Sets the item_dimensions of this ProductInfo. + + + :param item_dimensions: The item_dimensions of this ProductInfo. # noqa: E501 + :type: DimensionBasedAttribute + """ + + self._item_dimensions = item_dimensions + + @property + def release_date(self): + """Gets the release_date of this ProductInfo. # noqa: E501 + + + :return: The release_date of this ProductInfo. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._release_date + + @release_date.setter + def release_date(self, release_date): + """Sets the release_date of this ProductInfo. + + + :param release_date: The release_date of this ProductInfo. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._release_date = release_date + + @property + def size(self): + """Gets the size of this ProductInfo. # noqa: E501 + + + :return: The size of this ProductInfo. # noqa: E501 + :rtype: SingleStringValuedAttribute + """ + return self._size + + @size.setter + def size(self, size): + """Sets the size of this ProductInfo. + + + :param size: The size of this ProductInfo. # noqa: E501 + :type: SingleStringValuedAttribute + """ + + self._size = size + + @property + def unit_count(self): + """Gets the unit_count of this ProductInfo. # noqa: E501 + + + :return: The unit_count of this ProductInfo. # noqa: E501 + :rtype: SingleIntegerValuedAttribute + """ + return self._unit_count + + @unit_count.setter + def unit_count(self, unit_count): + """Sets the unit_count of this ProductInfo. + + + :param unit_count: The unit_count of this ProductInfo. # noqa: E501 + :type: SingleIntegerValuedAttribute + """ + + self._unit_count = unit_count + + 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(ProductInfo, 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, ProductInfo): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/properties.py b/amazon/paapi5_python_sdk/properties.py new file mode 100644 index 0000000..ea72b0a --- /dev/null +++ b/amazon/paapi5_python_sdk/properties.py @@ -0,0 +1,83 @@ +# coding: utf-8 + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class Properties(dict): + """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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """Properties - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(Properties, 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, Properties): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/refinement.py b/amazon/paapi5_python_sdk/refinement.py new file mode 100644 index 0000000..cce4c59 --- /dev/null +++ b/amazon/paapi5_python_sdk/refinement.py @@ -0,0 +1,180 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .refinement_bin import RefinementBin # noqa: F401,E501 + + +class Refinement(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 = { + 'bins': 'list[RefinementBin]', + 'display_name': 'str', + 'id': 'str' + } + + attribute_map = { + 'bins': 'Bins', + 'display_name': 'DisplayName', + 'id': 'Id' + } + + def __init__(self, bins=None, display_name=None, id=None): # noqa: E501 + """Refinement - a model defined in Swagger""" # noqa: E501 + + self._bins = None + self._display_name = None + self._id = None + self.discriminator = None + + if bins is not None: + self.bins = bins + if display_name is not None: + self.display_name = display_name + if id is not None: + self.id = id + + @property + def bins(self): + """Gets the bins of this Refinement. # noqa: E501 + + + :return: The bins of this Refinement. # noqa: E501 + :rtype: list[RefinementBin] + """ + return self._bins + + @bins.setter + def bins(self, bins): + """Sets the bins of this Refinement. + + + :param bins: The bins of this Refinement. # noqa: E501 + :type: list[RefinementBin] + """ + + self._bins = bins + + @property + def display_name(self): + """Gets the display_name of this Refinement. # noqa: E501 + + + :return: The display_name of this Refinement. # noqa: E501 + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """Sets the display_name of this Refinement. + + + :param display_name: The display_name of this Refinement. # noqa: E501 + :type: str + """ + + self._display_name = display_name + + @property + def id(self): + """Gets the id of this Refinement. # noqa: E501 + + + :return: The id of this Refinement. # noqa: E501 + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """Sets the id of this Refinement. + + + :param id: The id of this Refinement. # noqa: E501 + :type: str + """ + + self._id = id + + 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(Refinement, 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, Refinement): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/refinement_bin.py b/amazon/paapi5_python_sdk/refinement_bin.py new file mode 100644 index 0000000..9b44ba6 --- /dev/null +++ b/amazon/paapi5_python_sdk/refinement_bin.py @@ -0,0 +1,152 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class RefinementBin(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 = { + 'display_name': 'str', + 'id': 'str' + } + + attribute_map = { + 'display_name': 'DisplayName', + 'id': 'Id' + } + + def __init__(self, display_name=None, id=None): # noqa: E501 + """RefinementBin - a model defined in Swagger""" # noqa: E501 + + self._display_name = None + self._id = None + self.discriminator = None + + if display_name is not None: + self.display_name = display_name + if id is not None: + self.id = id + + @property + def display_name(self): + """Gets the display_name of this RefinementBin. # noqa: E501 + + + :return: The display_name of this RefinementBin. # noqa: E501 + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """Sets the display_name of this RefinementBin. + + + :param display_name: The display_name of this RefinementBin. # noqa: E501 + :type: str + """ + + self._display_name = display_name + + @property + def id(self): + """Gets the id of this RefinementBin. # noqa: E501 + + + :return: The id of this RefinementBin. # noqa: E501 + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """Sets the id of this RefinementBin. + + + :param id: The id of this RefinementBin. # noqa: E501 + :type: str + """ + + self._id = id + + 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(RefinementBin, 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, RefinementBin): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/rental_offer_listing.py b/amazon/paapi5_python_sdk/rental_offer_listing.py new file mode 100644 index 0000000..95936a6 --- /dev/null +++ b/amazon/paapi5_python_sdk/rental_offer_listing.py @@ -0,0 +1,262 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .duration_price import DurationPrice # noqa: F401,E501 +from .offer_availability import OfferAvailability # noqa: F401,E501 +from .offer_condition import OfferCondition # noqa: F401,E501 +from .offer_delivery_info import OfferDeliveryInfo # noqa: F401,E501 +from .offer_merchant_info import OfferMerchantInfo # noqa: F401,E501 + + +class RentalOfferListing(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 = { + 'availability': 'OfferAvailability', + 'base_price': 'DurationPrice', + 'condition': 'OfferCondition', + 'delivery_info': 'OfferDeliveryInfo', + 'id': 'str', + 'merchant_info': 'OfferMerchantInfo' + } + + attribute_map = { + 'availability': 'Availability', + 'base_price': 'BasePrice', + 'condition': 'Condition', + 'delivery_info': 'DeliveryInfo', + 'id': 'Id', + 'merchant_info': 'MerchantInfo' + } + + def __init__(self, availability=None, base_price=None, condition=None, delivery_info=None, id=None, merchant_info=None): # noqa: E501 + """RentalOfferListing - a model defined in Swagger""" # noqa: E501 + + self._availability = None + self._base_price = None + self._condition = None + self._delivery_info = None + self._id = None + self._merchant_info = None + self.discriminator = None + + if availability is not None: + self.availability = availability + if base_price is not None: + self.base_price = base_price + if condition is not None: + self.condition = condition + if delivery_info is not None: + self.delivery_info = delivery_info + if id is not None: + self.id = id + if merchant_info is not None: + self.merchant_info = merchant_info + + @property + def availability(self): + """Gets the availability of this RentalOfferListing. # noqa: E501 + + + :return: The availability of this RentalOfferListing. # noqa: E501 + :rtype: OfferAvailability + """ + return self._availability + + @availability.setter + def availability(self, availability): + """Sets the availability of this RentalOfferListing. + + + :param availability: The availability of this RentalOfferListing. # noqa: E501 + :type: OfferAvailability + """ + + self._availability = availability + + @property + def base_price(self): + """Gets the base_price of this RentalOfferListing. # noqa: E501 + + + :return: The base_price of this RentalOfferListing. # noqa: E501 + :rtype: DurationPrice + """ + return self._base_price + + @base_price.setter + def base_price(self, base_price): + """Sets the base_price of this RentalOfferListing. + + + :param base_price: The base_price of this RentalOfferListing. # noqa: E501 + :type: DurationPrice + """ + + self._base_price = base_price + + @property + def condition(self): + """Gets the condition of this RentalOfferListing. # noqa: E501 + + + :return: The condition of this RentalOfferListing. # noqa: E501 + :rtype: OfferCondition + """ + return self._condition + + @condition.setter + def condition(self, condition): + """Sets the condition of this RentalOfferListing. + + + :param condition: The condition of this RentalOfferListing. # noqa: E501 + :type: OfferCondition + """ + + self._condition = condition + + @property + def delivery_info(self): + """Gets the delivery_info of this RentalOfferListing. # noqa: E501 + + + :return: The delivery_info of this RentalOfferListing. # noqa: E501 + :rtype: OfferDeliveryInfo + """ + return self._delivery_info + + @delivery_info.setter + def delivery_info(self, delivery_info): + """Sets the delivery_info of this RentalOfferListing. + + + :param delivery_info: The delivery_info of this RentalOfferListing. # noqa: E501 + :type: OfferDeliveryInfo + """ + + self._delivery_info = delivery_info + + @property + def id(self): + """Gets the id of this RentalOfferListing. # noqa: E501 + + + :return: The id of this RentalOfferListing. # noqa: E501 + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """Sets the id of this RentalOfferListing. + + + :param id: The id of this RentalOfferListing. # noqa: E501 + :type: str + """ + + self._id = id + + @property + def merchant_info(self): + """Gets the merchant_info of this RentalOfferListing. # noqa: E501 + + + :return: The merchant_info of this RentalOfferListing. # noqa: E501 + :rtype: OfferMerchantInfo + """ + return self._merchant_info + + @merchant_info.setter + def merchant_info(self, merchant_info): + """Sets the merchant_info of this RentalOfferListing. + + + :param merchant_info: The merchant_info of this RentalOfferListing. # noqa: E501 + :type: OfferMerchantInfo + """ + + self._merchant_info = merchant_info + + 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(RentalOfferListing, 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, RentalOfferListing): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/rental_offers.py b/amazon/paapi5_python_sdk/rental_offers.py new file mode 100644 index 0000000..6fb4e09 --- /dev/null +++ b/amazon/paapi5_python_sdk/rental_offers.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .rental_offer_listing import RentalOfferListing # noqa: F401,E501 + + +class RentalOffers(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 = { + 'listings': 'list[RentalOfferListing]' + } + + attribute_map = { + 'listings': 'Listings' + } + + def __init__(self, listings=None): # noqa: E501 + """RentalOffers - a model defined in Swagger""" # noqa: E501 + + self._listings = None + self.discriminator = None + + if listings is not None: + self.listings = listings + + @property + def listings(self): + """Gets the listings of this RentalOffers. # noqa: E501 + + + :return: The listings of this RentalOffers. # noqa: E501 + :rtype: list[RentalOfferListing] + """ + return self._listings + + @listings.setter + def listings(self, listings): + """Sets the listings of this RentalOffers. + + + :param listings: The listings of this RentalOffers. # noqa: E501 + :type: list[RentalOfferListing] + """ + + self._listings = listings + + 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(RentalOffers, 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, RentalOffers): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/rest.py b/amazon/paapi5_python_sdk/rest.py new file mode 100644 index 0000000..a4e74fa --- /dev/null +++ b/amazon/paapi5_python_sdk/rest.py @@ -0,0 +1,333 @@ +# coding: utf-8 + +from __future__ import absolute_import + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + +import io +import json +import logging +import re +import ssl + +import certifi +# python 2 and python 3 compatibility library +import six +from six.moves.urllib.parse import urlencode + +try: + import urllib3 +except ImportError: + raise ImportError('Swagger python client requires urllib3.') + + +logger = logging.getLogger(__name__) + + +class RESTResponse(io.IOBase): + + def __init__(self, resp): + self.urllib3_response = resp + self.status = resp.status + self.reason = resp.reason + self.data = resp.data + + def getheaders(self): + """Returns a dictionary of the response headers.""" + return self.urllib3_response.getheaders() + + def getheader(self, name, default=None): + """Returns a given response header.""" + return self.urllib3_response.getheader(name, default) + + +class RESTClientObject(object): + + def __init__(self, configuration, pools_size=4, maxsize=None): + # urllib3.PoolManager will pass all kw parameters to connectionpool + # https://github.com/shazow/urllib3/blob/f9409436f83aeb79fbaf090181cd81b784f1b8ce/urllib3/poolmanager.py#L75 # noqa: E501 + # https://github.com/shazow/urllib3/blob/f9409436f83aeb79fbaf090181cd81b784f1b8ce/urllib3/connectionpool.py#L680 # noqa: E501 + # maxsize is the number of requests to host that are allowed in parallel # noqa: E501 + # Custom SSL certificates and client certificates: http://urllib3.readthedocs.io/en/latest/advanced-usage.html # noqa: E501 + + # cert_reqs + if configuration.verify_ssl: + cert_reqs = ssl.CERT_REQUIRED + else: + cert_reqs = ssl.CERT_NONE + + # ca_certs + if configuration.ssl_ca_cert: + ca_certs = configuration.ssl_ca_cert + else: + # if not set certificate file, use Mozilla's root certificates. + ca_certs = certifi.where() + + addition_pool_args = {} + if configuration.assert_hostname is not None: + addition_pool_args['assert_hostname'] = configuration.assert_hostname # noqa: E501 + + if maxsize is None: + if configuration.connection_pool_maxsize is not None: + maxsize = configuration.connection_pool_maxsize + else: + maxsize = 4 + + # https pool manager + if configuration.proxy: + self.pool_manager = urllib3.ProxyManager( + num_pools=pools_size, + maxsize=maxsize, + cert_reqs=cert_reqs, + ca_certs=ca_certs, + cert_file=configuration.cert_file, + key_file=configuration.key_file, + proxy_url=configuration.proxy, + **addition_pool_args + ) + else: + self.pool_manager = urllib3.PoolManager( + num_pools=pools_size, + maxsize=maxsize, + cert_reqs=cert_reqs, + ca_certs=ca_certs, + cert_file=configuration.cert_file, + key_file=configuration.key_file, + **addition_pool_args + ) + + def request(self, method, url, query_params=None, headers=None, + body=None, post_params=None, _preload_content=True, + _request_timeout=None): + """Perform requests. + + :param method: http request method + :param url: http request url + :param query_params: query parameters in the url + :param headers: http request headers + :param body: request json body, for `application/json` + :param post_params: request post parameters, + `application/x-www-form-urlencoded` + and `multipart/form-data` + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + """ + method = method.upper() + assert method in ['GET', 'HEAD', 'DELETE', 'POST', 'PUT', + 'PATCH', 'OPTIONS'] + + if post_params and body: + raise ValueError( + "body parameter cannot be used with post_params parameter." + ) + + post_params = post_params or {} + headers = headers or {} + + timeout = None + if _request_timeout: + if isinstance(_request_timeout, (int, ) if six.PY3 else (int, long)): # noqa: E501,F821 + timeout = urllib3.Timeout(total=_request_timeout) + elif (isinstance(_request_timeout, tuple) and + len(_request_timeout) == 2): + timeout = urllib3.Timeout( + connect=_request_timeout[0], read=_request_timeout[1]) + + if 'Content-Type' not in headers: + headers['Content-Type'] = 'application/json' + + try: + # For `POST`, `PUT`, `PATCH`, `OPTIONS`, `DELETE` + if method in ['POST', 'PUT', 'PATCH', 'OPTIONS', 'DELETE']: + if query_params: + url += '?' + urlencode(query_params) + if re.search('json', headers['Content-Type'], re.IGNORECASE): + request_body = None + if body is not None: + request_body = json.dumps(body) + r = self.pool_manager.request( + method, url, + body=request_body, + preload_content=_preload_content, + timeout=timeout, + headers=headers) + elif headers['Content-Type'] == 'application/x-www-form-urlencoded': # noqa: E501 + r = self.pool_manager.request( + method, url, + fields=post_params, + encode_multipart=False, + preload_content=_preload_content, + timeout=timeout, + headers=headers) + elif headers['Content-Type'] == 'multipart/form-data': + # must del headers['Content-Type'], or the correct + # Content-Type which generated by urllib3 will be + # overwritten. + del headers['Content-Type'] + r = self.pool_manager.request( + method, url, + fields=post_params, + encode_multipart=True, + preload_content=_preload_content, + timeout=timeout, + headers=headers) + # Pass a `string` parameter directly in the body to support + # other content types than Json when `body` argument is + # provided in serialized form + elif isinstance(body, str): + request_body = body + r = self.pool_manager.request( + method, url, + body=request_body, + preload_content=_preload_content, + timeout=timeout, + headers=headers) + else: + # Cannot generate the request from given parameters + msg = """Cannot prepare a request message for provided + arguments. Please check that your arguments match + declared content type.""" + raise ApiException(status=0, reason=msg) + # For `GET`, `HEAD` + else: + r = self.pool_manager.request(method, url, + fields=query_params, + preload_content=_preload_content, + timeout=timeout, + headers=headers) + except urllib3.exceptions.SSLError as e: + msg = "{0}\n{1}".format(type(e).__name__, str(e)) + raise ApiException(status=0, reason=msg) + + if _preload_content: + r = RESTResponse(r) + + # In the python 3, the response.data is bytes. + # we need to decode it to string. + if six.PY3: + r.data = r.data.decode('utf8') + + # log response body + logger.debug("response body: %s", r.data) + + if not 200 <= r.status <= 299: + raise ApiException(http_resp=r) + + return r + + def GET(self, url, headers=None, query_params=None, _preload_content=True, + _request_timeout=None): + return self.request("GET", url, + headers=headers, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + query_params=query_params) + + def HEAD(self, url, headers=None, query_params=None, _preload_content=True, + _request_timeout=None): + return self.request("HEAD", url, + headers=headers, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + query_params=query_params) + + def OPTIONS(self, url, headers=None, query_params=None, post_params=None, + body=None, _preload_content=True, _request_timeout=None): + return self.request("OPTIONS", url, + headers=headers, + query_params=query_params, + post_params=post_params, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + body=body) + + def DELETE(self, url, headers=None, query_params=None, body=None, + _preload_content=True, _request_timeout=None): + return self.request("DELETE", url, + headers=headers, + query_params=query_params, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + body=body) + + def POST(self, url, headers=None, query_params=None, post_params=None, + body=None, _preload_content=True, _request_timeout=None): + return self.request("POST", url, + headers=headers, + query_params=query_params, + post_params=post_params, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + body=body) + + def PUT(self, url, headers=None, query_params=None, post_params=None, + body=None, _preload_content=True, _request_timeout=None): + return self.request("PUT", url, + headers=headers, + query_params=query_params, + post_params=post_params, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + body=body) + + def PATCH(self, url, headers=None, query_params=None, post_params=None, + body=None, _preload_content=True, _request_timeout=None): + return self.request("PATCH", url, + headers=headers, + query_params=query_params, + post_params=post_params, + _preload_content=_preload_content, + _request_timeout=_request_timeout, + body=body) + + +class ApiException(Exception): + + def __init__(self, status=None, reason=None, http_resp=None): + if http_resp: + self.status = http_resp.status + self.reason = http_resp.reason + self.body = http_resp.data + self.headers = http_resp.getheaders() + else: + self.status = status + self.reason = reason + self.body = None + self.headers = None + + def __str__(self): + """Custom error messages for exception""" + error_message = "({0})\n"\ + "Reason: {1}\n".format(self.status, self.reason) + if self.headers: + error_message += "HTTP response headers: {0}\n".format( + self.headers) + + if self.body: + error_message += "HTTP response body: {0}\n".format(self.body) + + return error_message diff --git a/amazon/paapi5_python_sdk/search_items_request.py b/amazon/paapi5_python_sdk/search_items_request.py new file mode 100644 index 0000000..4d1107a --- /dev/null +++ b/amazon/paapi5_python_sdk/search_items_request.py @@ -0,0 +1,818 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .availability import Availability # noqa: F401,E501 +from .condition import Condition # noqa: F401,E501 +from .delivery_flag import DeliveryFlag # noqa: F401,E501 +from .max_price import MaxPrice # noqa: F401,E501 +from .merchant import Merchant # noqa: F401,E501 +from .min_price import MinPrice # noqa: F401,E501 +from .min_reviews_rating import MinReviewsRating # noqa: F401,E501 +from .min_saving_percent import MinSavingPercent # noqa: F401,E501 +from .offer_count import OfferCount # noqa: F401,E501 +from .partner_type import PartnerType # noqa: F401,E501 +from .properties import Properties # noqa: F401,E501 +from .search_items_resource import SearchItemsResource # noqa: F401,E501 +from .sort_by import SortBy # noqa: F401,E501 + + +class SearchItemsRequest(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 = { + 'actor': 'str', + 'artist': 'str', + 'author': 'str', + 'availability': 'Availability', + 'brand': 'str', + 'browse_node_id': 'str', + 'condition': 'Condition', + 'currency_of_preference': 'str', + 'delivery_flags': 'list[DeliveryFlag]', + 'item_count': 'int', + 'item_page': 'int', + 'keywords': 'str', + 'languages_of_preference': 'list[str]', + 'marketplace': 'str', + 'max_price': 'MaxPrice', + 'merchant': 'Merchant', + 'min_price': 'MinPrice', + 'min_reviews_rating': 'MinReviewsRating', + 'min_saving_percent': 'MinSavingPercent', + 'offer_count': 'OfferCount', + 'partner_tag': 'str', + 'partner_type': 'PartnerType', + 'properties': 'Properties', + 'resources': 'list[SearchItemsResource]', + 'search_index': 'str', + 'sort_by': 'SortBy', + 'title': 'str' + } + + attribute_map = { + 'actor': 'Actor', + 'artist': 'Artist', + 'author': 'Author', + 'availability': 'Availability', + 'brand': 'Brand', + 'browse_node_id': 'BrowseNodeId', + 'condition': 'Condition', + 'currency_of_preference': 'CurrencyOfPreference', + 'delivery_flags': 'DeliveryFlags', + 'item_count': 'ItemCount', + 'item_page': 'ItemPage', + 'keywords': 'Keywords', + 'languages_of_preference': 'LanguagesOfPreference', + 'marketplace': 'Marketplace', + 'max_price': 'MaxPrice', + 'merchant': 'Merchant', + 'min_price': 'MinPrice', + 'min_reviews_rating': 'MinReviewsRating', + 'min_saving_percent': 'MinSavingPercent', + 'offer_count': 'OfferCount', + 'partner_tag': 'PartnerTag', + 'partner_type': 'PartnerType', + 'properties': 'Properties', + 'resources': 'Resources', + 'search_index': 'SearchIndex', + 'sort_by': 'SortBy', + 'title': 'Title' + } + + def __init__(self, actor=None, artist=None, author=None, availability=None, brand=None, browse_node_id=None, condition=None, currency_of_preference=None, delivery_flags=None, item_count=None, item_page=None, keywords=None, languages_of_preference=None, marketplace=None, max_price=None, merchant=None, min_price=None, min_reviews_rating=None, min_saving_percent=None, offer_count=None, partner_tag=None, partner_type=None, properties=None, resources=None, search_index=None, sort_by=None, title=None): # noqa: E501 + """SearchItemsRequest - a model defined in Swagger""" # noqa: E501 + + self._actor = None + self._artist = None + self._author = None + self._availability = None + self._brand = None + self._browse_node_id = None + self._condition = None + self._currency_of_preference = None + self._delivery_flags = None + self._item_count = None + self._item_page = None + self._keywords = None + self._languages_of_preference = None + self._marketplace = None + self._max_price = None + self._merchant = None + self._min_price = None + self._min_reviews_rating = None + self._min_saving_percent = None + self._offer_count = None + self._partner_tag = None + self._partner_type = None + self._properties = None + self._resources = None + self._search_index = None + self._sort_by = None + self._title = None + self.discriminator = None + + if actor is not None: + self.actor = actor + if artist is not None: + self.artist = artist + if author is not None: + self.author = author + if availability is not None: + self.availability = availability + if brand is not None: + self.brand = brand + if browse_node_id is not None: + self.browse_node_id = browse_node_id + if condition is not None: + self.condition = condition + if currency_of_preference is not None: + self.currency_of_preference = currency_of_preference + if delivery_flags is not None: + self.delivery_flags = delivery_flags + if item_count is not None: + self.item_count = item_count + if item_page is not None: + self.item_page = item_page + if keywords is not None: + self.keywords = keywords + if languages_of_preference is not None: + self.languages_of_preference = languages_of_preference + if marketplace is not None: + self.marketplace = marketplace + if max_price is not None: + self.max_price = max_price + if merchant is not None: + self.merchant = merchant + if min_price is not None: + self.min_price = min_price + if min_reviews_rating is not None: + self.min_reviews_rating = min_reviews_rating + if min_saving_percent is not None: + self.min_saving_percent = min_saving_percent + if offer_count is not None: + self.offer_count = offer_count + self.partner_tag = partner_tag + self.partner_type = partner_type + if properties is not None: + self.properties = properties + if resources is not None: + self.resources = resources + if search_index is not None: + self.search_index = search_index + if sort_by is not None: + self.sort_by = sort_by + if title is not None: + self.title = title + + @property + def actor(self): + """Gets the actor of this SearchItemsRequest. # noqa: E501 + + + :return: The actor of this SearchItemsRequest. # noqa: E501 + :rtype: str + """ + return self._actor + + @actor.setter + def actor(self, actor): + """Sets the actor of this SearchItemsRequest. + + + :param actor: The actor of this SearchItemsRequest. # noqa: E501 + :type: str + """ + + self._actor = actor + + @property + def artist(self): + """Gets the artist of this SearchItemsRequest. # noqa: E501 + + + :return: The artist of this SearchItemsRequest. # noqa: E501 + :rtype: str + """ + return self._artist + + @artist.setter + def artist(self, artist): + """Sets the artist of this SearchItemsRequest. + + + :param artist: The artist of this SearchItemsRequest. # noqa: E501 + :type: str + """ + + self._artist = artist + + @property + def author(self): + """Gets the author of this SearchItemsRequest. # noqa: E501 + + + :return: The author of this SearchItemsRequest. # noqa: E501 + :rtype: str + """ + return self._author + + @author.setter + def author(self, author): + """Sets the author of this SearchItemsRequest. + + + :param author: The author of this SearchItemsRequest. # noqa: E501 + :type: str + """ + + self._author = author + + @property + def availability(self): + """Gets the availability of this SearchItemsRequest. # noqa: E501 + + + :return: The availability of this SearchItemsRequest. # noqa: E501 + :rtype: Availability + """ + return self._availability + + @availability.setter + def availability(self, availability): + """Sets the availability of this SearchItemsRequest. + + + :param availability: The availability of this SearchItemsRequest. # noqa: E501 + :type: Availability + """ + + self._availability = availability + + @property + def brand(self): + """Gets the brand of this SearchItemsRequest. # noqa: E501 + + + :return: The brand of this SearchItemsRequest. # noqa: E501 + :rtype: str + """ + return self._brand + + @brand.setter + def brand(self, brand): + """Sets the brand of this SearchItemsRequest. + + + :param brand: The brand of this SearchItemsRequest. # noqa: E501 + :type: str + """ + + self._brand = brand + + @property + def browse_node_id(self): + """Gets the browse_node_id of this SearchItemsRequest. # noqa: E501 + + + :return: The browse_node_id of this SearchItemsRequest. # noqa: E501 + :rtype: str + """ + return self._browse_node_id + + @browse_node_id.setter + def browse_node_id(self, browse_node_id): + """Sets the browse_node_id of this SearchItemsRequest. + + + :param browse_node_id: The browse_node_id of this SearchItemsRequest. # noqa: E501 + :type: str + """ + + self._browse_node_id = browse_node_id + + @property + def condition(self): + """Gets the condition of this SearchItemsRequest. # noqa: E501 + + + :return: The condition of this SearchItemsRequest. # noqa: E501 + :rtype: Condition + """ + return self._condition + + @condition.setter + def condition(self, condition): + """Sets the condition of this SearchItemsRequest. + + + :param condition: The condition of this SearchItemsRequest. # noqa: E501 + :type: Condition + """ + + self._condition = condition + + @property + def currency_of_preference(self): + """Gets the currency_of_preference of this SearchItemsRequest. # noqa: E501 + + + :return: The currency_of_preference of this SearchItemsRequest. # noqa: E501 + :rtype: str + """ + return self._currency_of_preference + + @currency_of_preference.setter + def currency_of_preference(self, currency_of_preference): + """Sets the currency_of_preference of this SearchItemsRequest. + + + :param currency_of_preference: The currency_of_preference of this SearchItemsRequest. # noqa: E501 + :type: str + """ + + self._currency_of_preference = currency_of_preference + + @property + def delivery_flags(self): + """Gets the delivery_flags of this SearchItemsRequest. # noqa: E501 + + + :return: The delivery_flags of this SearchItemsRequest. # noqa: E501 + :rtype: list[DeliveryFlag] + """ + return self._delivery_flags + + @delivery_flags.setter + def delivery_flags(self, delivery_flags): + """Sets the delivery_flags of this SearchItemsRequest. + + + :param delivery_flags: The delivery_flags of this SearchItemsRequest. # noqa: E501 + :type: list[DeliveryFlag] + """ + + self._delivery_flags = delivery_flags + + @property + def item_count(self): + """Gets the item_count of this SearchItemsRequest. # noqa: E501 + + + :return: The item_count of this SearchItemsRequest. # noqa: E501 + :rtype: int + """ + return self._item_count + + @item_count.setter + def item_count(self, item_count): + """Sets the item_count of this SearchItemsRequest. + + + :param item_count: The item_count of this SearchItemsRequest. # noqa: E501 + :type: int + """ + + self._item_count = item_count + + @property + def item_page(self): + """Gets the item_page of this SearchItemsRequest. # noqa: E501 + + + :return: The item_page of this SearchItemsRequest. # noqa: E501 + :rtype: int + """ + return self._item_page + + @item_page.setter + def item_page(self, item_page): + """Sets the item_page of this SearchItemsRequest. + + + :param item_page: The item_page of this SearchItemsRequest. # noqa: E501 + :type: int + """ + + self._item_page = item_page + + @property + def keywords(self): + """Gets the keywords of this SearchItemsRequest. # noqa: E501 + + + :return: The keywords of this SearchItemsRequest. # noqa: E501 + :rtype: str + """ + return self._keywords + + @keywords.setter + def keywords(self, keywords): + """Sets the keywords of this SearchItemsRequest. + + + :param keywords: The keywords of this SearchItemsRequest. # noqa: E501 + :type: str + """ + + self._keywords = keywords + + @property + def languages_of_preference(self): + """Gets the languages_of_preference of this SearchItemsRequest. # noqa: E501 + + + :return: The languages_of_preference of this SearchItemsRequest. # noqa: E501 + :rtype: list[str] + """ + return self._languages_of_preference + + @languages_of_preference.setter + def languages_of_preference(self, languages_of_preference): + """Sets the languages_of_preference of this SearchItemsRequest. + + + :param languages_of_preference: The languages_of_preference of this SearchItemsRequest. # noqa: E501 + :type: list[str] + """ + + self._languages_of_preference = languages_of_preference + + @property + def marketplace(self): + """Gets the marketplace of this SearchItemsRequest. # noqa: E501 + + + :return: The marketplace of this SearchItemsRequest. # noqa: E501 + :rtype: str + """ + return self._marketplace + + @marketplace.setter + def marketplace(self, marketplace): + """Sets the marketplace of this SearchItemsRequest. + + + :param marketplace: The marketplace of this SearchItemsRequest. # noqa: E501 + :type: str + """ + + self._marketplace = marketplace + + @property + def max_price(self): + """Gets the max_price of this SearchItemsRequest. # noqa: E501 + + + :return: The max_price of this SearchItemsRequest. # noqa: E501 + :rtype: MaxPrice + """ + return self._max_price + + @max_price.setter + def max_price(self, max_price): + """Sets the max_price of this SearchItemsRequest. + + + :param max_price: The max_price of this SearchItemsRequest. # noqa: E501 + :type: MaxPrice + """ + + self._max_price = max_price + + @property + def merchant(self): + """Gets the merchant of this SearchItemsRequest. # noqa: E501 + + + :return: The merchant of this SearchItemsRequest. # noqa: E501 + :rtype: Merchant + """ + return self._merchant + + @merchant.setter + def merchant(self, merchant): + """Sets the merchant of this SearchItemsRequest. + + + :param merchant: The merchant of this SearchItemsRequest. # noqa: E501 + :type: Merchant + """ + + self._merchant = merchant + + @property + def min_price(self): + """Gets the min_price of this SearchItemsRequest. # noqa: E501 + + + :return: The min_price of this SearchItemsRequest. # noqa: E501 + :rtype: MinPrice + """ + return self._min_price + + @min_price.setter + def min_price(self, min_price): + """Sets the min_price of this SearchItemsRequest. + + + :param min_price: The min_price of this SearchItemsRequest. # noqa: E501 + :type: MinPrice + """ + + self._min_price = min_price + + @property + def min_reviews_rating(self): + """Gets the min_reviews_rating of this SearchItemsRequest. # noqa: E501 + + + :return: The min_reviews_rating of this SearchItemsRequest. # noqa: E501 + :rtype: MinReviewsRating + """ + return self._min_reviews_rating + + @min_reviews_rating.setter + def min_reviews_rating(self, min_reviews_rating): + """Sets the min_reviews_rating of this SearchItemsRequest. + + + :param min_reviews_rating: The min_reviews_rating of this SearchItemsRequest. # noqa: E501 + :type: MinReviewsRating + """ + + self._min_reviews_rating = min_reviews_rating + + @property + def min_saving_percent(self): + """Gets the min_saving_percent of this SearchItemsRequest. # noqa: E501 + + + :return: The min_saving_percent of this SearchItemsRequest. # noqa: E501 + :rtype: MinSavingPercent + """ + return self._min_saving_percent + + @min_saving_percent.setter + def min_saving_percent(self, min_saving_percent): + """Sets the min_saving_percent of this SearchItemsRequest. + + + :param min_saving_percent: The min_saving_percent of this SearchItemsRequest. # noqa: E501 + :type: MinSavingPercent + """ + + self._min_saving_percent = min_saving_percent + + @property + def offer_count(self): + """Gets the offer_count of this SearchItemsRequest. # noqa: E501 + + + :return: The offer_count of this SearchItemsRequest. # noqa: E501 + :rtype: OfferCount + """ + return self._offer_count + + @offer_count.setter + def offer_count(self, offer_count): + """Sets the offer_count of this SearchItemsRequest. + + + :param offer_count: The offer_count of this SearchItemsRequest. # noqa: E501 + :type: OfferCount + """ + + self._offer_count = offer_count + + @property + def partner_tag(self): + """Gets the partner_tag of this SearchItemsRequest. # noqa: E501 + + + :return: The partner_tag of this SearchItemsRequest. # noqa: E501 + :rtype: str + """ + return self._partner_tag + + @partner_tag.setter + def partner_tag(self, partner_tag): + """Sets the partner_tag of this SearchItemsRequest. + + + :param partner_tag: The partner_tag of this SearchItemsRequest. # noqa: E501 + :type: str + """ + if partner_tag is None: + raise ValueError("Invalid value for `partner_tag`, must not be `None`") # noqa: E501 + + self._partner_tag = partner_tag + + @property + def partner_type(self): + """Gets the partner_type of this SearchItemsRequest. # noqa: E501 + + + :return: The partner_type of this SearchItemsRequest. # noqa: E501 + :rtype: PartnerType + """ + return self._partner_type + + @partner_type.setter + def partner_type(self, partner_type): + """Sets the partner_type of this SearchItemsRequest. + + + :param partner_type: The partner_type of this SearchItemsRequest. # noqa: E501 + :type: PartnerType + """ + if partner_type is None: + raise ValueError("Invalid value for `partner_type`, must not be `None`") # noqa: E501 + + self._partner_type = partner_type + + @property + def properties(self): + """Gets the properties of this SearchItemsRequest. # noqa: E501 + + + :return: The properties of this SearchItemsRequest. # noqa: E501 + :rtype: Properties + """ + return self._properties + + @properties.setter + def properties(self, properties): + """Sets the properties of this SearchItemsRequest. + + + :param properties: The properties of this SearchItemsRequest. # noqa: E501 + :type: Properties + """ + + self._properties = properties + + @property + def resources(self): + """Gets the resources of this SearchItemsRequest. # noqa: E501 + + + :return: The resources of this SearchItemsRequest. # noqa: E501 + :rtype: list[SearchItemsResource] + """ + return self._resources + + @resources.setter + def resources(self, resources): + """Sets the resources of this SearchItemsRequest. + + + :param resources: The resources of this SearchItemsRequest. # noqa: E501 + :type: list[SearchItemsResource] + """ + + self._resources = resources + + @property + def search_index(self): + """Gets the search_index of this SearchItemsRequest. # noqa: E501 + + + :return: The search_index of this SearchItemsRequest. # noqa: E501 + :rtype: str + """ + return self._search_index + + @search_index.setter + def search_index(self, search_index): + """Sets the search_index of this SearchItemsRequest. + + + :param search_index: The search_index of this SearchItemsRequest. # noqa: E501 + :type: str + """ + + self._search_index = search_index + + @property + def sort_by(self): + """Gets the sort_by of this SearchItemsRequest. # noqa: E501 + + + :return: The sort_by of this SearchItemsRequest. # noqa: E501 + :rtype: SortBy + """ + return self._sort_by + + @sort_by.setter + def sort_by(self, sort_by): + """Sets the sort_by of this SearchItemsRequest. + + + :param sort_by: The sort_by of this SearchItemsRequest. # noqa: E501 + :type: SortBy + """ + + self._sort_by = sort_by + + @property + def title(self): + """Gets the title of this SearchItemsRequest. # noqa: E501 + + + :return: The title of this SearchItemsRequest. # noqa: E501 + :rtype: str + """ + return self._title + + @title.setter + def title(self, title): + """Sets the title of this SearchItemsRequest. + + + :param title: The title of this SearchItemsRequest. # noqa: E501 + :type: str + """ + + self._title = title + + 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(SearchItemsRequest, 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, SearchItemsRequest): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/search_items_resource.py b/amazon/paapi5_python_sdk/search_items_resource.py new file mode 100644 index 0000000..a55a559 --- /dev/null +++ b/amazon/paapi5_python_sdk/search_items_resource.py @@ -0,0 +1,158 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class SearchItemsResource(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + allowed enum values + """ + BROWSENODEINFO_BROWSENODES = "BrowseNodeInfo.BrowseNodes" + BROWSENODEINFO_BROWSENODES_ANCESTOR = "BrowseNodeInfo.BrowseNodes.Ancestor" + BROWSENODEINFO_BROWSENODES_SALESRANK = "BrowseNodeInfo.BrowseNodes.SalesRank" + BROWSENODEINFO_WEBSITESALESRANK = "BrowseNodeInfo.WebsiteSalesRank" + IMAGES_PRIMARY_SMALL = "Images.Primary.Small" + IMAGES_PRIMARY_MEDIUM = "Images.Primary.Medium" + IMAGES_PRIMARY_LARGE = "Images.Primary.Large" + IMAGES_VARIANTS_SMALL = "Images.Variants.Small" + IMAGES_VARIANTS_MEDIUM = "Images.Variants.Medium" + IMAGES_VARIANTS_LARGE = "Images.Variants.Large" + ITEMINFO_BYLINEINFO = "ItemInfo.ByLineInfo" + ITEMINFO_CONTENTINFO = "ItemInfo.ContentInfo" + ITEMINFO_CONTENTRATING = "ItemInfo.ContentRating" + ITEMINFO_CLASSIFICATIONS = "ItemInfo.Classifications" + ITEMINFO_EXTERNALIDS = "ItemInfo.ExternalIds" + ITEMINFO_FEATURES = "ItemInfo.Features" + ITEMINFO_MANUFACTUREINFO = "ItemInfo.ManufactureInfo" + ITEMINFO_PRODUCTINFO = "ItemInfo.ProductInfo" + ITEMINFO_TECHNICALINFO = "ItemInfo.TechnicalInfo" + ITEMINFO_TITLE = "ItemInfo.Title" + ITEMINFO_TRADEININFO = "ItemInfo.TradeInInfo" + OFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY = "Offers.Listings.Availability.MaxOrderQuantity" + OFFERS_LISTINGS_AVAILABILITY_MESSAGE = "Offers.Listings.Availability.Message" + OFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY = "Offers.Listings.Availability.MinOrderQuantity" + OFFERS_LISTINGS_AVAILABILITY_TYPE = "Offers.Listings.Availability.Type" + OFFERS_LISTINGS_CONDITION = "Offers.Listings.Condition" + OFFERS_LISTINGS_CONDITION_SUBCONDITION = "Offers.Listings.Condition.SubCondition" + OFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED = "Offers.Listings.DeliveryInfo.IsAmazonFulfilled" + OFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE = "Offers.Listings.DeliveryInfo.IsFreeShippingEligible" + OFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE = "Offers.Listings.DeliveryInfo.IsPrimeEligible" + OFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES = "Offers.Listings.DeliveryInfo.ShippingCharges" + OFFERS_LISTINGS_ISBUYBOXWINNER = "Offers.Listings.IsBuyBoxWinner" + OFFERS_LISTINGS_LOYALTYPOINTS_POINTS = "Offers.Listings.LoyaltyPoints.Points" + OFFERS_LISTINGS_MERCHANTINFO = "Offers.Listings.MerchantInfo" + OFFERS_LISTINGS_PRICE = "Offers.Listings.Price" + OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEEXCLUSIVE = "Offers.Listings.ProgramEligibility.IsPrimeExclusive" + OFFERS_LISTINGS_PROGRAMELIGIBILITY_ISPRIMEPANTRY = "Offers.Listings.ProgramEligibility.IsPrimePantry" + OFFERS_LISTINGS_PROMOTIONS = "Offers.Listings.Promotions" + OFFERS_LISTINGS_SAVINGBASIS = "Offers.Listings.SavingBasis" + OFFERS_SUMMARIES_HIGHESTPRICE = "Offers.Summaries.HighestPrice" + OFFERS_SUMMARIES_LOWESTPRICE = "Offers.Summaries.LowestPrice" + OFFERS_SUMMARIES_OFFERCOUNT = "Offers.Summaries.OfferCount" + PARENTASIN = "ParentASIN" + RENTALOFFERS_LISTINGS_AVAILABILITY_MAXORDERQUANTITY = "RentalOffers.Listings.Availability.MaxOrderQuantity" + RENTALOFFERS_LISTINGS_AVAILABILITY_MESSAGE = "RentalOffers.Listings.Availability.Message" + RENTALOFFERS_LISTINGS_AVAILABILITY_MINORDERQUANTITY = "RentalOffers.Listings.Availability.MinOrderQuantity" + RENTALOFFERS_LISTINGS_AVAILABILITY_TYPE = "RentalOffers.Listings.Availability.Type" + RENTALOFFERS_LISTINGS_BASEPRICE = "RentalOffers.Listings.BasePrice" + RENTALOFFERS_LISTINGS_CONDITION = "RentalOffers.Listings.Condition" + RENTALOFFERS_LISTINGS_CONDITION_SUBCONDITION = "RentalOffers.Listings.Condition.SubCondition" + RENTALOFFERS_LISTINGS_DELIVERYINFO_ISAMAZONFULFILLED = "RentalOffers.Listings.DeliveryInfo.IsAmazonFulfilled" + RENTALOFFERS_LISTINGS_DELIVERYINFO_ISFREESHIPPINGELIGIBLE = "RentalOffers.Listings.DeliveryInfo.IsFreeShippingEligible" + RENTALOFFERS_LISTINGS_DELIVERYINFO_ISPRIMEELIGIBLE = "RentalOffers.Listings.DeliveryInfo.IsPrimeEligible" + RENTALOFFERS_LISTINGS_DELIVERYINFO_SHIPPINGCHARGES = "RentalOffers.Listings.DeliveryInfo.ShippingCharges" + RENTALOFFERS_LISTINGS_MERCHANTINFO = "RentalOffers.Listings.MerchantInfo" + SEARCHREFINEMENTS = "SearchRefinements" + + """ + 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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """SearchItemsResource - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(SearchItemsResource, 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, SearchItemsResource): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/search_items_response.py b/amazon/paapi5_python_sdk/search_items_response.py new file mode 100644 index 0000000..8c66fc7 --- /dev/null +++ b/amazon/paapi5_python_sdk/search_items_response.py @@ -0,0 +1,155 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .error_data import ErrorData # noqa: F401,E501 +from .search_result import SearchResult # noqa: F401,E501 + + +class SearchItemsResponse(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 = { + 'search_result': 'SearchResult', + 'errors': 'list[ErrorData]' + } + + attribute_map = { + 'search_result': 'SearchResult', + 'errors': 'Errors' + } + + def __init__(self, search_result=None, errors=None): # noqa: E501 + """SearchItemsResponse - a model defined in Swagger""" # noqa: E501 + + self._search_result = None + self._errors = None + self.discriminator = None + + if search_result is not None: + self.search_result = search_result + if errors is not None: + self.errors = errors + + @property + def search_result(self): + """Gets the search_result of this SearchItemsResponse. # noqa: E501 + + + :return: The search_result of this SearchItemsResponse. # noqa: E501 + :rtype: SearchResult + """ + return self._search_result + + @search_result.setter + def search_result(self, search_result): + """Sets the search_result of this SearchItemsResponse. + + + :param search_result: The search_result of this SearchItemsResponse. # noqa: E501 + :type: SearchResult + """ + + self._search_result = search_result + + @property + def errors(self): + """Gets the errors of this SearchItemsResponse. # noqa: E501 + + + :return: The errors of this SearchItemsResponse. # noqa: E501 + :rtype: list[ErrorData] + """ + return self._errors + + @errors.setter + def errors(self, errors): + """Sets the errors of this SearchItemsResponse. + + + :param errors: The errors of this SearchItemsResponse. # noqa: E501 + :type: list[ErrorData] + """ + + self._errors = errors + + 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(SearchItemsResponse, 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, SearchItemsResponse): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/search_refinements.py b/amazon/paapi5_python_sdk/search_refinements.py new file mode 100644 index 0000000..2741661 --- /dev/null +++ b/amazon/paapi5_python_sdk/search_refinements.py @@ -0,0 +1,180 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .refinement import Refinement # noqa: F401,E501 + + +class SearchRefinements(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 = { + 'browse_node': 'Refinement', + 'other_refinements': 'list[Refinement]', + 'search_index': 'Refinement' + } + + attribute_map = { + 'browse_node': 'BrowseNode', + 'other_refinements': 'OtherRefinements', + 'search_index': 'SearchIndex' + } + + def __init__(self, browse_node=None, other_refinements=None, search_index=None): # noqa: E501 + """SearchRefinements - a model defined in Swagger""" # noqa: E501 + + self._browse_node = None + self._other_refinements = None + self._search_index = None + self.discriminator = None + + if browse_node is not None: + self.browse_node = browse_node + if other_refinements is not None: + self.other_refinements = other_refinements + if search_index is not None: + self.search_index = search_index + + @property + def browse_node(self): + """Gets the browse_node of this SearchRefinements. # noqa: E501 + + + :return: The browse_node of this SearchRefinements. # noqa: E501 + :rtype: Refinement + """ + return self._browse_node + + @browse_node.setter + def browse_node(self, browse_node): + """Sets the browse_node of this SearchRefinements. + + + :param browse_node: The browse_node of this SearchRefinements. # noqa: E501 + :type: Refinement + """ + + self._browse_node = browse_node + + @property + def other_refinements(self): + """Gets the other_refinements of this SearchRefinements. # noqa: E501 + + + :return: The other_refinements of this SearchRefinements. # noqa: E501 + :rtype: list[Refinement] + """ + return self._other_refinements + + @other_refinements.setter + def other_refinements(self, other_refinements): + """Sets the other_refinements of this SearchRefinements. + + + :param other_refinements: The other_refinements of this SearchRefinements. # noqa: E501 + :type: list[Refinement] + """ + + self._other_refinements = other_refinements + + @property + def search_index(self): + """Gets the search_index of this SearchRefinements. # noqa: E501 + + + :return: The search_index of this SearchRefinements. # noqa: E501 + :rtype: Refinement + """ + return self._search_index + + @search_index.setter + def search_index(self, search_index): + """Sets the search_index of this SearchRefinements. + + + :param search_index: The search_index of this SearchRefinements. # noqa: E501 + :type: Refinement + """ + + self._search_index = search_index + + 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(SearchRefinements, 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, SearchRefinements): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/search_result.py b/amazon/paapi5_python_sdk/search_result.py new file mode 100644 index 0000000..6ba2d5e --- /dev/null +++ b/amazon/paapi5_python_sdk/search_result.py @@ -0,0 +1,207 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .item import Item # noqa: F401,E501 +from .search_refinements import SearchRefinements # noqa: F401,E501 + + +class SearchResult(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 = { + 'total_result_count': 'int', + 'search_url': 'str', + 'items': 'list[Item]', + 'search_refinements': 'SearchRefinements' + } + + attribute_map = { + 'total_result_count': 'TotalResultCount', + 'search_url': 'SearchURL', + 'items': 'Items', + 'search_refinements': 'SearchRefinements' + } + + def __init__(self, total_result_count=None, search_url=None, items=None, search_refinements=None): # noqa: E501 + """SearchResult - a model defined in Swagger""" # noqa: E501 + + self._total_result_count = None + self._search_url = None + self._items = None + self._search_refinements = None + self.discriminator = None + + if total_result_count is not None: + self.total_result_count = total_result_count + if search_url is not None: + self.search_url = search_url + if items is not None: + self.items = items + if search_refinements is not None: + self.search_refinements = search_refinements + + @property + def total_result_count(self): + """Gets the total_result_count of this SearchResult. # noqa: E501 + + + :return: The total_result_count of this SearchResult. # noqa: E501 + :rtype: int + """ + return self._total_result_count + + @total_result_count.setter + def total_result_count(self, total_result_count): + """Sets the total_result_count of this SearchResult. + + + :param total_result_count: The total_result_count of this SearchResult. # noqa: E501 + :type: int + """ + + self._total_result_count = total_result_count + + @property + def search_url(self): + """Gets the search_url of this SearchResult. # noqa: E501 + + + :return: The search_url of this SearchResult. # noqa: E501 + :rtype: str + """ + return self._search_url + + @search_url.setter + def search_url(self, search_url): + """Sets the search_url of this SearchResult. + + + :param search_url: The search_url of this SearchResult. # noqa: E501 + :type: str + """ + + self._search_url = search_url + + @property + def items(self): + """Gets the items of this SearchResult. # noqa: E501 + + + :return: The items of this SearchResult. # noqa: E501 + :rtype: list[Item] + """ + return self._items + + @items.setter + def items(self, items): + """Sets the items of this SearchResult. + + + :param items: The items of this SearchResult. # noqa: E501 + :type: list[Item] + """ + + self._items = items + + @property + def search_refinements(self): + """Gets the search_refinements of this SearchResult. # noqa: E501 + + + :return: The search_refinements of this SearchResult. # noqa: E501 + :rtype: SearchRefinements + """ + return self._search_refinements + + @search_refinements.setter + def search_refinements(self, search_refinements): + """Sets the search_refinements of this SearchResult. + + + :param search_refinements: The search_refinements of this SearchResult. # noqa: E501 + :type: SearchRefinements + """ + + self._search_refinements = search_refinements + + 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(SearchResult, 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, SearchResult): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/single_boolean_valued_attribute.py b/amazon/paapi5_python_sdk/single_boolean_valued_attribute.py new file mode 100644 index 0000000..df043f6 --- /dev/null +++ b/amazon/paapi5_python_sdk/single_boolean_valued_attribute.py @@ -0,0 +1,178 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class SingleBooleanValuedAttribute(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 = { + 'display_value': 'bool', + 'label': 'str', + 'locale': 'str' + } + + attribute_map = { + 'display_value': 'DisplayValue', + 'label': 'Label', + 'locale': 'Locale' + } + + def __init__(self, display_value=None, label=None, locale=None): # noqa: E501 + """SingleBooleanValuedAttribute - a model defined in Swagger""" # noqa: E501 + + self._display_value = None + self._label = None + self._locale = None + self.discriminator = None + + if display_value is not None: + self.display_value = display_value + if label is not None: + self.label = label + if locale is not None: + self.locale = locale + + @property + def display_value(self): + """Gets the display_value of this SingleBooleanValuedAttribute. # noqa: E501 + + + :return: The display_value of this SingleBooleanValuedAttribute. # noqa: E501 + :rtype: bool + """ + return self._display_value + + @display_value.setter + def display_value(self, display_value): + """Sets the display_value of this SingleBooleanValuedAttribute. + + + :param display_value: The display_value of this SingleBooleanValuedAttribute. # noqa: E501 + :type: bool + """ + + self._display_value = display_value + + @property + def label(self): + """Gets the label of this SingleBooleanValuedAttribute. # noqa: E501 + + + :return: The label of this SingleBooleanValuedAttribute. # noqa: E501 + :rtype: str + """ + return self._label + + @label.setter + def label(self, label): + """Sets the label of this SingleBooleanValuedAttribute. + + + :param label: The label of this SingleBooleanValuedAttribute. # noqa: E501 + :type: str + """ + + self._label = label + + @property + def locale(self): + """Gets the locale of this SingleBooleanValuedAttribute. # noqa: E501 + + + :return: The locale of this SingleBooleanValuedAttribute. # noqa: E501 + :rtype: str + """ + return self._locale + + @locale.setter + def locale(self, locale): + """Sets the locale of this SingleBooleanValuedAttribute. + + + :param locale: The locale of this SingleBooleanValuedAttribute. # noqa: E501 + :type: str + """ + + self._locale = locale + + 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(SingleBooleanValuedAttribute, 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, SingleBooleanValuedAttribute): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/single_integer_valued_attribute.py b/amazon/paapi5_python_sdk/single_integer_valued_attribute.py new file mode 100644 index 0000000..63b93e3 --- /dev/null +++ b/amazon/paapi5_python_sdk/single_integer_valued_attribute.py @@ -0,0 +1,178 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class SingleIntegerValuedAttribute(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 = { + 'display_value': 'int', + 'label': 'str', + 'locale': 'str' + } + + attribute_map = { + 'display_value': 'DisplayValue', + 'label': 'Label', + 'locale': 'Locale' + } + + def __init__(self, display_value=None, label=None, locale=None): # noqa: E501 + """SingleIntegerValuedAttribute - a model defined in Swagger""" # noqa: E501 + + self._display_value = None + self._label = None + self._locale = None + self.discriminator = None + + if display_value is not None: + self.display_value = display_value + if label is not None: + self.label = label + if locale is not None: + self.locale = locale + + @property + def display_value(self): + """Gets the display_value of this SingleIntegerValuedAttribute. # noqa: E501 + + + :return: The display_value of this SingleIntegerValuedAttribute. # noqa: E501 + :rtype: int + """ + return self._display_value + + @display_value.setter + def display_value(self, display_value): + """Sets the display_value of this SingleIntegerValuedAttribute. + + + :param display_value: The display_value of this SingleIntegerValuedAttribute. # noqa: E501 + :type: int + """ + + self._display_value = display_value + + @property + def label(self): + """Gets the label of this SingleIntegerValuedAttribute. # noqa: E501 + + + :return: The label of this SingleIntegerValuedAttribute. # noqa: E501 + :rtype: str + """ + return self._label + + @label.setter + def label(self, label): + """Sets the label of this SingleIntegerValuedAttribute. + + + :param label: The label of this SingleIntegerValuedAttribute. # noqa: E501 + :type: str + """ + + self._label = label + + @property + def locale(self): + """Gets the locale of this SingleIntegerValuedAttribute. # noqa: E501 + + + :return: The locale of this SingleIntegerValuedAttribute. # noqa: E501 + :rtype: str + """ + return self._locale + + @locale.setter + def locale(self, locale): + """Sets the locale of this SingleIntegerValuedAttribute. + + + :param locale: The locale of this SingleIntegerValuedAttribute. # noqa: E501 + :type: str + """ + + self._locale = locale + + 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(SingleIntegerValuedAttribute, 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, SingleIntegerValuedAttribute): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/single_string_valued_attribute.py b/amazon/paapi5_python_sdk/single_string_valued_attribute.py new file mode 100644 index 0000000..e217d62 --- /dev/null +++ b/amazon/paapi5_python_sdk/single_string_valued_attribute.py @@ -0,0 +1,178 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class SingleStringValuedAttribute(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 = { + 'display_value': 'str', + 'label': 'str', + 'locale': 'str' + } + + attribute_map = { + 'display_value': 'DisplayValue', + 'label': 'Label', + 'locale': 'Locale' + } + + def __init__(self, display_value=None, label=None, locale=None): # noqa: E501 + """SingleStringValuedAttribute - a model defined in Swagger""" # noqa: E501 + + self._display_value = None + self._label = None + self._locale = None + self.discriminator = None + + if display_value is not None: + self.display_value = display_value + if label is not None: + self.label = label + if locale is not None: + self.locale = locale + + @property + def display_value(self): + """Gets the display_value of this SingleStringValuedAttribute. # noqa: E501 + + + :return: The display_value of this SingleStringValuedAttribute. # noqa: E501 + :rtype: str + """ + return self._display_value + + @display_value.setter + def display_value(self, display_value): + """Sets the display_value of this SingleStringValuedAttribute. + + + :param display_value: The display_value of this SingleStringValuedAttribute. # noqa: E501 + :type: str + """ + + self._display_value = display_value + + @property + def label(self): + """Gets the label of this SingleStringValuedAttribute. # noqa: E501 + + + :return: The label of this SingleStringValuedAttribute. # noqa: E501 + :rtype: str + """ + return self._label + + @label.setter + def label(self, label): + """Sets the label of this SingleStringValuedAttribute. + + + :param label: The label of this SingleStringValuedAttribute. # noqa: E501 + :type: str + """ + + self._label = label + + @property + def locale(self): + """Gets the locale of this SingleStringValuedAttribute. # noqa: E501 + + + :return: The locale of this SingleStringValuedAttribute. # noqa: E501 + :rtype: str + """ + return self._locale + + @locale.setter + def locale(self, locale): + """Sets the locale of this SingleStringValuedAttribute. + + + :param locale: The locale of this SingleStringValuedAttribute. # noqa: E501 + :type: str + """ + + self._locale = locale + + 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(SingleStringValuedAttribute, 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, SingleStringValuedAttribute): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/sort_by.py b/amazon/paapi5_python_sdk/sort_by.py new file mode 100644 index 0000000..33f8312 --- /dev/null +++ b/amazon/paapi5_python_sdk/sort_by.py @@ -0,0 +1,108 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class SortBy(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + allowed enum values + """ + AVGCUSTOMERREVIEWS = "AvgCustomerReviews" + FEATURED = "Featured" + NEWESTARRIVALS = "NewestArrivals" + PRICE_HIGHTOLOW = "Price:HighToLow" + PRICE_LOWTOHIGH = "Price:LowToHigh" + RELEVANCE = "Relevance" + + """ + 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 = { + } + + attribute_map = { + } + + def __init__(self): # noqa: E501 + """SortBy - a model defined in Swagger""" # noqa: E501 + self.discriminator = None + + 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(SortBy, 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, SortBy): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/technical_info.py b/amazon/paapi5_python_sdk/technical_info.py new file mode 100644 index 0000000..508af10 --- /dev/null +++ b/amazon/paapi5_python_sdk/technical_info.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .multi_valued_attribute import MultiValuedAttribute # noqa: F401,E501 + + +class TechnicalInfo(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 = { + 'formats': 'MultiValuedAttribute' + } + + attribute_map = { + 'formats': 'Formats' + } + + def __init__(self, formats=None): # noqa: E501 + """TechnicalInfo - a model defined in Swagger""" # noqa: E501 + + self._formats = None + self.discriminator = None + + if formats is not None: + self.formats = formats + + @property + def formats(self): + """Gets the formats of this TechnicalInfo. # noqa: E501 + + + :return: The formats of this TechnicalInfo. # noqa: E501 + :rtype: MultiValuedAttribute + """ + return self._formats + + @formats.setter + def formats(self, formats): + """Sets the formats of this TechnicalInfo. + + + :param formats: The formats of this TechnicalInfo. # noqa: E501 + :type: MultiValuedAttribute + """ + + self._formats = formats + + 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(TechnicalInfo, 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, TechnicalInfo): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/trade_in_info.py b/amazon/paapi5_python_sdk/trade_in_info.py new file mode 100644 index 0000000..248b4e1 --- /dev/null +++ b/amazon/paapi5_python_sdk/trade_in_info.py @@ -0,0 +1,154 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .trade_in_price import TradeInPrice # noqa: F401,E501 + + +class TradeInInfo(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 = { + 'is_eligible_for_trade_in': 'bool', + 'price': 'TradeInPrice' + } + + attribute_map = { + 'is_eligible_for_trade_in': 'IsEligibleForTradeIn', + 'price': 'Price' + } + + def __init__(self, is_eligible_for_trade_in=None, price=None): # noqa: E501 + """TradeInInfo - a model defined in Swagger""" # noqa: E501 + + self._is_eligible_for_trade_in = None + self._price = None + self.discriminator = None + + if is_eligible_for_trade_in is not None: + self.is_eligible_for_trade_in = is_eligible_for_trade_in + if price is not None: + self.price = price + + @property + def is_eligible_for_trade_in(self): + """Gets the is_eligible_for_trade_in of this TradeInInfo. # noqa: E501 + + + :return: The is_eligible_for_trade_in of this TradeInInfo. # noqa: E501 + :rtype: bool + """ + return self._is_eligible_for_trade_in + + @is_eligible_for_trade_in.setter + def is_eligible_for_trade_in(self, is_eligible_for_trade_in): + """Sets the is_eligible_for_trade_in of this TradeInInfo. + + + :param is_eligible_for_trade_in: The is_eligible_for_trade_in of this TradeInInfo. # noqa: E501 + :type: bool + """ + + self._is_eligible_for_trade_in = is_eligible_for_trade_in + + @property + def price(self): + """Gets the price of this TradeInInfo. # noqa: E501 + + + :return: The price of this TradeInInfo. # noqa: E501 + :rtype: TradeInPrice + """ + return self._price + + @price.setter + def price(self, price): + """Sets the price of this TradeInInfo. + + + :param price: The price of this TradeInInfo. # noqa: E501 + :type: TradeInPrice + """ + + self._price = price + + 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(TradeInInfo, 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, TradeInInfo): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/trade_in_price.py b/amazon/paapi5_python_sdk/trade_in_price.py new file mode 100644 index 0000000..3e968e5 --- /dev/null +++ b/amazon/paapi5_python_sdk/trade_in_price.py @@ -0,0 +1,178 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class TradeInPrice(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 = { + 'amount': 'float', + 'currency': 'str', + 'display_amount': 'str' + } + + attribute_map = { + 'amount': 'Amount', + 'currency': 'Currency', + 'display_amount': 'DisplayAmount' + } + + def __init__(self, amount=None, currency=None, display_amount=None): # noqa: E501 + """TradeInPrice - a model defined in Swagger""" # noqa: E501 + + self._amount = None + self._currency = None + self._display_amount = None + self.discriminator = None + + if amount is not None: + self.amount = amount + if currency is not None: + self.currency = currency + if display_amount is not None: + self.display_amount = display_amount + + @property + def amount(self): + """Gets the amount of this TradeInPrice. # noqa: E501 + + + :return: The amount of this TradeInPrice. # noqa: E501 + :rtype: float + """ + return self._amount + + @amount.setter + def amount(self, amount): + """Sets the amount of this TradeInPrice. + + + :param amount: The amount of this TradeInPrice. # noqa: E501 + :type: float + """ + + self._amount = amount + + @property + def currency(self): + """Gets the currency of this TradeInPrice. # noqa: E501 + + + :return: The currency of this TradeInPrice. # noqa: E501 + :rtype: str + """ + return self._currency + + @currency.setter + def currency(self, currency): + """Sets the currency of this TradeInPrice. + + + :param currency: The currency of this TradeInPrice. # noqa: E501 + :type: str + """ + + self._currency = currency + + @property + def display_amount(self): + """Gets the display_amount of this TradeInPrice. # noqa: E501 + + + :return: The display_amount of this TradeInPrice. # noqa: E501 + :rtype: str + """ + return self._display_amount + + @display_amount.setter + def display_amount(self, display_amount): + """Sets the display_amount of this TradeInPrice. + + + :param display_amount: The display_amount of this TradeInPrice. # noqa: E501 + :type: str + """ + + self._display_amount = display_amount + + 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(TradeInPrice, 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, TradeInPrice): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/unit_based_attribute.py b/amazon/paapi5_python_sdk/unit_based_attribute.py new file mode 100644 index 0000000..19e5f31 --- /dev/null +++ b/amazon/paapi5_python_sdk/unit_based_attribute.py @@ -0,0 +1,204 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class UnitBasedAttribute(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 = { + 'display_value': 'float', + 'label': 'str', + 'locale': 'str', + 'unit': 'str' + } + + attribute_map = { + 'display_value': 'DisplayValue', + 'label': 'Label', + 'locale': 'Locale', + 'unit': 'Unit' + } + + def __init__(self, display_value=None, label=None, locale=None, unit=None): # noqa: E501 + """UnitBasedAttribute - a model defined in Swagger""" # noqa: E501 + + self._display_value = None + self._label = None + self._locale = None + self._unit = None + self.discriminator = None + + if display_value is not None: + self.display_value = display_value + if label is not None: + self.label = label + if locale is not None: + self.locale = locale + if unit is not None: + self.unit = unit + + @property + def display_value(self): + """Gets the display_value of this UnitBasedAttribute. # noqa: E501 + + + :return: The display_value of this UnitBasedAttribute. # noqa: E501 + :rtype: float + """ + return self._display_value + + @display_value.setter + def display_value(self, display_value): + """Sets the display_value of this UnitBasedAttribute. + + + :param display_value: The display_value of this UnitBasedAttribute. # noqa: E501 + :type: float + """ + + self._display_value = display_value + + @property + def label(self): + """Gets the label of this UnitBasedAttribute. # noqa: E501 + + + :return: The label of this UnitBasedAttribute. # noqa: E501 + :rtype: str + """ + return self._label + + @label.setter + def label(self, label): + """Sets the label of this UnitBasedAttribute. + + + :param label: The label of this UnitBasedAttribute. # noqa: E501 + :type: str + """ + + self._label = label + + @property + def locale(self): + """Gets the locale of this UnitBasedAttribute. # noqa: E501 + + + :return: The locale of this UnitBasedAttribute. # noqa: E501 + :rtype: str + """ + return self._locale + + @locale.setter + def locale(self, locale): + """Sets the locale of this UnitBasedAttribute. + + + :param locale: The locale of this UnitBasedAttribute. # noqa: E501 + :type: str + """ + + self._locale = locale + + @property + def unit(self): + """Gets the unit of this UnitBasedAttribute. # noqa: E501 + + + :return: The unit of this UnitBasedAttribute. # noqa: E501 + :rtype: str + """ + return self._unit + + @unit.setter + def unit(self, unit): + """Sets the unit of this UnitBasedAttribute. + + + :param unit: The unit of this UnitBasedAttribute. # noqa: E501 + :type: str + """ + + self._unit = unit + + 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(UnitBasedAttribute, 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, UnitBasedAttribute): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/variation_attribute.py b/amazon/paapi5_python_sdk/variation_attribute.py new file mode 100644 index 0000000..1173e3d --- /dev/null +++ b/amazon/paapi5_python_sdk/variation_attribute.py @@ -0,0 +1,152 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class VariationAttribute(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 = { + 'name': 'str', + 'value': 'str' + } + + attribute_map = { + 'name': 'Name', + 'value': 'Value' + } + + def __init__(self, name=None, value=None): # noqa: E501 + """VariationAttribute - a model defined in Swagger""" # noqa: E501 + + self._name = None + self._value = None + self.discriminator = None + + if name is not None: + self.name = name + if value is not None: + self.value = value + + @property + def name(self): + """Gets the name of this VariationAttribute. # noqa: E501 + + + :return: The name of this VariationAttribute. # noqa: E501 + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """Sets the name of this VariationAttribute. + + + :param name: The name of this VariationAttribute. # noqa: E501 + :type: str + """ + + self._name = name + + @property + def value(self): + """Gets the value of this VariationAttribute. # noqa: E501 + + + :return: The value of this VariationAttribute. # noqa: E501 + :rtype: str + """ + return self._value + + @value.setter + def value(self, value): + """Sets the value of this VariationAttribute. + + + :param value: The value of this VariationAttribute. # noqa: E501 + :type: str + """ + + self._value = value + + 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(VariationAttribute, 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, VariationAttribute): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/variation_dimension.py b/amazon/paapi5_python_sdk/variation_dimension.py new file mode 100644 index 0000000..8ff9e86 --- /dev/null +++ b/amazon/paapi5_python_sdk/variation_dimension.py @@ -0,0 +1,204 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class VariationDimension(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 = { + 'display_name': 'str', + 'locale': 'str', + 'name': 'str', + 'values': 'list[str]' + } + + attribute_map = { + 'display_name': 'DisplayName', + 'locale': 'Locale', + 'name': 'Name', + 'values': 'Values' + } + + def __init__(self, display_name=None, locale=None, name=None, values=None): # noqa: E501 + """VariationDimension - a model defined in Swagger""" # noqa: E501 + + self._display_name = None + self._locale = None + self._name = None + self._values = None + self.discriminator = None + + if display_name is not None: + self.display_name = display_name + if locale is not None: + self.locale = locale + if name is not None: + self.name = name + if values is not None: + self.values = values + + @property + def display_name(self): + """Gets the display_name of this VariationDimension. # noqa: E501 + + + :return: The display_name of this VariationDimension. # noqa: E501 + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """Sets the display_name of this VariationDimension. + + + :param display_name: The display_name of this VariationDimension. # noqa: E501 + :type: str + """ + + self._display_name = display_name + + @property + def locale(self): + """Gets the locale of this VariationDimension. # noqa: E501 + + + :return: The locale of this VariationDimension. # noqa: E501 + :rtype: str + """ + return self._locale + + @locale.setter + def locale(self, locale): + """Sets the locale of this VariationDimension. + + + :param locale: The locale of this VariationDimension. # noqa: E501 + :type: str + """ + + self._locale = locale + + @property + def name(self): + """Gets the name of this VariationDimension. # noqa: E501 + + + :return: The name of this VariationDimension. # noqa: E501 + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """Sets the name of this VariationDimension. + + + :param name: The name of this VariationDimension. # noqa: E501 + :type: str + """ + + self._name = name + + @property + def values(self): + """Gets the values of this VariationDimension. # noqa: E501 + + + :return: The values of this VariationDimension. # noqa: E501 + :rtype: list[str] + """ + return self._values + + @values.setter + def values(self, values): + """Sets the values of this VariationDimension. + + + :param values: The values of this VariationDimension. # noqa: E501 + :type: list[str] + """ + + self._values = values + + 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(VariationDimension, 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, VariationDimension): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/variation_summary.py b/amazon/paapi5_python_sdk/variation_summary.py new file mode 100644 index 0000000..e8aeea4 --- /dev/null +++ b/amazon/paapi5_python_sdk/variation_summary.py @@ -0,0 +1,207 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .price import Price # noqa: F401,E501 +from .variation_dimension import VariationDimension # noqa: F401,E501 + + +class VariationSummary(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 = { + 'page_count': 'int', + 'price': 'Price', + 'variation_count': 'int', + 'variation_dimensions': 'list[VariationDimension]' + } + + attribute_map = { + 'page_count': 'PageCount', + 'price': 'Price', + 'variation_count': 'VariationCount', + 'variation_dimensions': 'VariationDimensions' + } + + def __init__(self, page_count=None, price=None, variation_count=None, variation_dimensions=None): # noqa: E501 + """VariationSummary - a model defined in Swagger""" # noqa: E501 + + self._page_count = None + self._price = None + self._variation_count = None + self._variation_dimensions = None + self.discriminator = None + + if page_count is not None: + self.page_count = page_count + if price is not None: + self.price = price + if variation_count is not None: + self.variation_count = variation_count + if variation_dimensions is not None: + self.variation_dimensions = variation_dimensions + + @property + def page_count(self): + """Gets the page_count of this VariationSummary. # noqa: E501 + + + :return: The page_count of this VariationSummary. # noqa: E501 + :rtype: int + """ + return self._page_count + + @page_count.setter + def page_count(self, page_count): + """Sets the page_count of this VariationSummary. + + + :param page_count: The page_count of this VariationSummary. # noqa: E501 + :type: int + """ + + self._page_count = page_count + + @property + def price(self): + """Gets the price of this VariationSummary. # noqa: E501 + + + :return: The price of this VariationSummary. # noqa: E501 + :rtype: Price + """ + return self._price + + @price.setter + def price(self, price): + """Sets the price of this VariationSummary. + + + :param price: The price of this VariationSummary. # noqa: E501 + :type: Price + """ + + self._price = price + + @property + def variation_count(self): + """Gets the variation_count of this VariationSummary. # noqa: E501 + + + :return: The variation_count of this VariationSummary. # noqa: E501 + :rtype: int + """ + return self._variation_count + + @variation_count.setter + def variation_count(self, variation_count): + """Sets the variation_count of this VariationSummary. + + + :param variation_count: The variation_count of this VariationSummary. # noqa: E501 + :type: int + """ + + self._variation_count = variation_count + + @property + def variation_dimensions(self): + """Gets the variation_dimensions of this VariationSummary. # noqa: E501 + + + :return: The variation_dimensions of this VariationSummary. # noqa: E501 + :rtype: list[VariationDimension] + """ + return self._variation_dimensions + + @variation_dimensions.setter + def variation_dimensions(self, variation_dimensions): + """Sets the variation_dimensions of this VariationSummary. + + + :param variation_dimensions: The variation_dimensions of this VariationSummary. # noqa: E501 + :type: list[VariationDimension] + """ + + self._variation_dimensions = variation_dimensions + + 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(VariationSummary, 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, VariationSummary): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/variations_result.py b/amazon/paapi5_python_sdk/variations_result.py new file mode 100644 index 0000000..9ce3c66 --- /dev/null +++ b/amazon/paapi5_python_sdk/variations_result.py @@ -0,0 +1,155 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + +from .item import Item # noqa: F401,E501 +from .variation_summary import VariationSummary # noqa: F401,E501 + + +class VariationsResult(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 = { + 'items': 'list[Item]', + 'variation_summary': 'VariationSummary' + } + + attribute_map = { + 'items': 'Items', + 'variation_summary': 'VariationSummary' + } + + def __init__(self, items=None, variation_summary=None): # noqa: E501 + """VariationsResult - a model defined in Swagger""" # noqa: E501 + + self._items = None + self._variation_summary = None + self.discriminator = None + + if items is not None: + self.items = items + if variation_summary is not None: + self.variation_summary = variation_summary + + @property + def items(self): + """Gets the items of this VariationsResult. # noqa: E501 + + + :return: The items of this VariationsResult. # noqa: E501 + :rtype: list[Item] + """ + return self._items + + @items.setter + def items(self, items): + """Sets the items of this VariationsResult. + + + :param items: The items of this VariationsResult. # noqa: E501 + :type: list[Item] + """ + + self._items = items + + @property + def variation_summary(self): + """Gets the variation_summary of this VariationsResult. # noqa: E501 + + + :return: The variation_summary of this VariationsResult. # noqa: E501 + :rtype: VariationSummary + """ + return self._variation_summary + + @variation_summary.setter + def variation_summary(self, variation_summary): + """Sets the variation_summary of this VariationsResult. + + + :param variation_summary: The variation_summary of this VariationsResult. # noqa: E501 + :type: VariationSummary + """ + + self._variation_summary = variation_summary + + 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(VariationsResult, 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, VariationsResult): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/paapi5_python_sdk/website_sales_rank.py b/amazon/paapi5_python_sdk/website_sales_rank.py new file mode 100644 index 0000000..da92d28 --- /dev/null +++ b/amazon/paapi5_python_sdk/website_sales_rank.py @@ -0,0 +1,204 @@ +# coding: utf-8 + +""" + Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + A copy of the License is located at + + http://www.apache.org/licenses/LICENSE-2.0 + + or in the "license" file accompanying this file. This file is distributed + on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either + express or implied. See the License for the specific language governing + permissions and limitations under the License. +""" + +""" + ProductAdvertisingAPI + + https://webservices.amazon.com/paapi5/documentation/index.html # noqa: E501 +""" + + +import pprint +import re # noqa: F401 + +import six + + +class WebsiteSalesRank(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 = { + 'context_free_name': 'str', + 'display_name': 'str', + 'id': 'str', + 'sales_rank': 'int' + } + + attribute_map = { + 'context_free_name': 'ContextFreeName', + 'display_name': 'DisplayName', + 'id': 'Id', + 'sales_rank': 'SalesRank' + } + + def __init__(self, context_free_name=None, display_name=None, id=None, sales_rank=None): # noqa: E501 + """WebsiteSalesRank - a model defined in Swagger""" # noqa: E501 + + self._context_free_name = None + self._display_name = None + self._id = None + self._sales_rank = None + self.discriminator = None + + if context_free_name is not None: + self.context_free_name = context_free_name + if display_name is not None: + self.display_name = display_name + if id is not None: + self.id = id + if sales_rank is not None: + self.sales_rank = sales_rank + + @property + def context_free_name(self): + """Gets the context_free_name of this WebsiteSalesRank. # noqa: E501 + + + :return: The context_free_name of this WebsiteSalesRank. # noqa: E501 + :rtype: str + """ + return self._context_free_name + + @context_free_name.setter + def context_free_name(self, context_free_name): + """Sets the context_free_name of this WebsiteSalesRank. + + + :param context_free_name: The context_free_name of this WebsiteSalesRank. # noqa: E501 + :type: str + """ + + self._context_free_name = context_free_name + + @property + def display_name(self): + """Gets the display_name of this WebsiteSalesRank. # noqa: E501 + + + :return: The display_name of this WebsiteSalesRank. # noqa: E501 + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """Sets the display_name of this WebsiteSalesRank. + + + :param display_name: The display_name of this WebsiteSalesRank. # noqa: E501 + :type: str + """ + + self._display_name = display_name + + @property + def id(self): + """Gets the id of this WebsiteSalesRank. # noqa: E501 + + + :return: The id of this WebsiteSalesRank. # noqa: E501 + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """Sets the id of this WebsiteSalesRank. + + + :param id: The id of this WebsiteSalesRank. # noqa: E501 + :type: str + """ + + self._id = id + + @property + def sales_rank(self): + """Gets the sales_rank of this WebsiteSalesRank. # noqa: E501 + + + :return: The sales_rank of this WebsiteSalesRank. # noqa: E501 + :rtype: int + """ + return self._sales_rank + + @sales_rank.setter + def sales_rank(self, sales_rank): + """Sets the sales_rank of this WebsiteSalesRank. + + + :param sales_rank: The sales_rank of this WebsiteSalesRank. # noqa: E501 + :type: int + """ + + self._sales_rank = sales_rank + + 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(WebsiteSalesRank, 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, WebsiteSalesRank): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/amazon/parse.py b/amazon/parse.py new file mode 100644 index 0000000..1f65cf3 --- /dev/null +++ b/amazon/parse.py @@ -0,0 +1,550 @@ +"""Data parser for instance creation.""" +import pprint + +import six + +class Class: + """Base class for creating the product instance.""" + pass + + +class AmazonBrowseNode(): + swagger_types = { + 'ancestor': 'BrowseNodeAncestor', + 'children': 'BrowseNodeChildren', + 'context_free_name': 'str', + 'display_name': 'str', + 'id': 'str', + 'is_root': 'bool', + 'sales_rank': 'int' + } + + def __init__(self, node): + self.ancestor = node.ancestor + self.children = node.children + self.context_free_name = node.context_free_name + self.display_name = node.display_name + self.id = node.id + self.is_root = node.is_root + self.sales_rank = node.sales_rank + + def to_dict(self): + 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(AmazonBrowseNode, dict): + for key, value in self.items(): + result[key] = value + + return result + + def to_str(self): + return pprint.pformat(self.to_dict()) + + def __repr__(self): + return self.to_str() + + def __eq__(self, other): + if not isinstance(other, AmazonBrowseNode): + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other + + +def parse_browsenode(browse_nodes_response): + """Parse browse node data and creates a dict. + + Args: + browse_nodes_response (list): List of browse nodes responses. + + Returns: + dict: Dict with browse node information. + """ + mapped_response = {} + for browse_node in browse_nodes_response: + mapped_response[browse_node.id] = browse_node + return mapped_response + + +def parse_product(item): + """Parse item data and creates product instance. + + Args: + item (instance): The instance with the data from Amazon API. + + Returns: + instance: Product instance with parsed data. + """ + product = Class() + product.raw_info = item + + # Main + product.asin = item.asin + try: + product.url = item.detail_page_url + except Exception: + product.url = None + try: + product.title = item.item_info.title.display_value + except Exception: + product.title = None + try: + product.parent_asin = item.parent_asin + except Exception: + product.parent_asin = None + + # Info + product.info = Class() + try: + product.info.contributors = [] + for x in item.item_info.by_line_info.contributors: + contributor = Class() + contributor.name = x.name + contributor.role = x.role + product.info.contributors.append(contributor) + except Exception: + product.info.contributors = None + try: + product.info.manufacturer = item.item_info.by_line_info.manufacturer.display_value + except Exception: + product.info.manufacturer = None + try: + product.info.brand = item.item_info.by_line_info.brand.display_value + except Exception: + product.info.brand = None + try: + product.info.product_group = item.item_info.classifications.product_group.display_value + except Exception: + product.info.product_group = None + try: + product.info.binding = item.item_info.classifications.binding.display_value + except Exception: + product.info.binding = None + try: + product.info.is_adult = item.item_info.product_info.is_adult_product.display_value + except Exception: + product.info.is_adult = None + try: + product.info.edition = item.item_info.content_info.edition.display_value + except Exception: + product.info.edition = None + try: + product.info.warranty = item.item_info.manufacture_info.warranty.display_value + except Exception: + product.info.warranty = None + try: + product.info.audience_rating = item.item_info.content_rating.audience_rating.display_value + except Exception: + product.info.audience_rating = None + try: + product.info.part_number = item.item_info.manufacture_info.item_part_number.display_value + except Exception: + product.info.part_number = None + try: + product.info.model = item.item_info.manufacture_info.model.display_value + except Exception: + product.info.model = None + try: + product.info.publication_date = item.item_info.content_info.publication_date.display_value + except Exception: + product.info.publication_date = None + try: + product.info.release_date = item.item_info.product_info.release_date.display_value + except Exception: + product.info.release_date = None + product.info.external_ids = Class() + try: + product.info.external_ids.ean = item.item_info.external_ids.ea_ns.display_values + except Exception: + product.info.external_ids.ean = None + try: + product.info.external_ids.isbn = item.item_info.external_ids.isb_ns.display_values + except Exception: + product.info.external_ids.isbn = None + try: + product.info.external_ids.upc = item.item_info.external_ids.up_cs.display_values + except Exception: + product.info.external_ids.upc = None + + # Product + product.product = Class() + try: + product.product.features = item.item_info.features.display_values + except Exception: + product.product.features = None + try: + product.product.languages = [] + for x in item.item_info.content_info.languages.display_values: + product.product.languages.append(x.display_value + ' ' + x.type) + except Exception: + product.product.languages = None + try: + product.product.pages_count = item.item_info.content_info.pages_count.display_value + except Exception: + product.product.pages_count = None + try: + product.product.formats = item.item_info.technical_info.formats.display_values + except Exception: + product.product.formats = None + try: + product.product.color = item.item_info.product_info.color.display_value + except Exception: + product.product.color = None + try: + product.product.unit_count = item.item_info.product_info.unit_count.display_value + except Exception: + product.product.unit_count = None + product.product.dimensions = Class() + try: + product.product.size = item.item_info.product_info.size.display_value + except Exception: + product.product.size = None + product.product.dimensions.height = Class() + try: + product.product.dimensions.height.value = item.item_info.product_info.item_dimensions.height.display_value + except Exception: + product.product.dimensions.height.value = None + try: + product.product.dimensions.height.unit = item.item_info.product_info.item_dimensions.height.unit + except Exception: + product.product.dimensions.height.unit = None + product.product.dimensions.length = Class() + try: + product.product.dimensions.length.value = item.item_info.product_info.item_dimensions.length.display_value + except Exception: + product.product.dimensions.length.value = None + try: + product.product.dimensions.length.unit = item.item_info.product_info.item_dimensions.length.unit + except Exception: + product.product.dimensions.length.unit = None + product.product.dimensions.width = Class() + try: + product.product.dimensions.width.value = item.item_info.product_info.item_dimensions.width.display_value + except Exception: + product.product.dimensions.width.value = None + try: + product.product.dimensions.width.unit = item.item_info.product_info.item_dimensions.width.unit + except Exception: + product.product.dimensions.width.unit = None + product.product.weight = Class() + try: + product.product.weight.value = item.item_info.product_info.item_dimensions.weight.display_value + except Exception: + product.product.weight.value = None + try: + product.product.weight.unit = item.item_info.product_info.item_dimensions.weight.unit + except Exception: + product.product.weight.unit = None + + # Images + product.images = Class() + try: + product.images.large = item.images.primary.large.url + except Exception: + product.images.large = None + try: + product.images.medium = item.images.primary.medium.url + except Exception: + product.images.medium = None + try: + product.images.small = item.images.primary.small.url + except Exception: + product.images.small = None + try: + product.images.variants = Class() + product.images.variants.small = [] + product.images.variants.medium = [] + product.images.variants.large = [] + for variant in item.images.variants: + try: + product.images.variants.large.append(variant.large.url) + product.images.variants.medium.append(variant.medium.url) + product.images.variants.small.append(variant.small.url) + except Exception: + pass + if not product.images.variants.small and not product.images.variants.medium and not product.images.variants.large: + product.images.variants = None + except Exception: + product.images.variants = None + product.images.cropped = Class() + product.images.cropped.small = [] + product.images.cropped.medium = [] + product.images.cropped.large = [] + try: + product.images.cropped.small.append(product.images.small.replace('_SL', '_AC')) + except Exception: + pass + try: + product.images.cropped.medium.append(product.images.medium.replace('_SL', '_AC')) + except Exception: + pass + try: + product.images.cropped.large.append(product.images.large.replace('.jpg', '._AC_.jpg')) + except Exception: + pass + try: + for x in product.images.variants.small: + product.images.cropped.small.append(x.replace('_SL', '_AC')) + except Exception: + pass + try: + for x in product.images.variants.medium: + product.images.cropped.medium.append(x.replace('_SL', '_AC')) + except Exception: + pass + try: + for x in product.images.variants.large: + product.images.cropped.large.append(x.replace('.jpg', '._AC_.jpg')) + except Exception: + pass + + # Trade In + product.trade_in = Class() + try: + product.trade_in.eligible = item.item_info.trade_in_info.is_eligible_for_trade_in + except Exception: + product.trade_in.eligible = None + try: + product.trade_in.price = item.item_info.trade_in_info.price.amount + except Exception: + product.trade_in.price = None + try: + product.trade_in.currency = item.item_info.trade_in_info.price.currency + except Exception: + product.trade_in.currency = None + if not product.trade_in.eligible and not product.trade_in.price and not product.trade_in.currency: + product.trade_in = None + + # Prices + try: + listings = item.offers.listings[0] + except Exception: + listings = None + product.prices = Class() + product.prices.price = Class() + try: + product.prices.price.value = listings.price.amount + except Exception: + product.prices.price.value = None + try: + product.prices.price.currency = listings.price.currency + except Exception: + product.prices.price.currency = None + try: + product.prices.price.per_unit = listings.price.price_per_unit + except Exception: + product.prices.price.per_unit = None + try: + product.prices.price.display = listings.price.display_amount + except Exception: + product.prices.price.display = None + product.prices.price.savings = Class() + try: + product.prices.price.savings.value = listings.price.savings.amount + except Exception: + product.prices.price.savings.value = None + try: + product.prices.price.savings.currency = listings.price.savings.currency + except Exception: + product.prices.price.savings.currency = None + try: + product.prices.price.savings.per_unit = listings.price.savings.price_per_unit + except Exception: + product.prices.price.savings.per_unit = None + try: + product.prices.price.savings.display = listings.price.savings.display_amount + except Exception: + product.prices.price.savings.display = None + try: + product.prices.price.savings.percentage = listings.price.savings.percentage + except Exception: + product.prices.price.savings.percentage = None + product.prices.pvp = Class() + try: + product.prices.pvp.value = listings.saving_basis.amount + except Exception: + product.prices.pvp.value = None + try: + product.prices.pvp.currency = listings.saving_basis.currency + except Exception: + product.prices.pvp.currency = None + try: + product.prices.pvp.per_unit = listings.saving_basis.price_per_unit + except Exception: + product.prices.pvp.per_unit = None + try: + product.prices.pvp.display = listings.saving_basis.display_amount + except Exception: + product.prices.pvp.display = None + product.prices.availability = Class() + try: + product.prices.availability.message = listings.availability.message + except Exception: + product.prices.availability.message = None + try: + product.prices.availability.type = listings.availability.type + except Exception: + product.prices.availability.type = None + try: + product.prices.availability.max_order_quantity = listings.availability.max_order_quantity + except Exception: + product.prices.availability.max_order_quantity = None + try: + product.prices.availability.min_order_quantity = listings.availability.min_order_quantity + except Exception: + product.prices.availability.min_order_quantity = None + product.prices.condition = Class() + try: + product.prices.condition.condition = listings.condition.value + except Exception: + product.prices.condition = None + try: + product.prices.condition.condition_display = listings.condition.display_value + except Exception: + product.prices.condition_display = None + try: + product.prices.condition.sub_condition = listings.condition.sub_condition.value + except Exception: + product.prices.sub_condition = None + try: + product.prices.condition.sub_condition_display = listings.condition.sub_condition.display_value + except Exception: + product.prices.sub_condition_display = None + product.prices.merchant = Class() + try: + product.prices.merchant.default_shipping_country = listings.merchant_info.default_shipping_country + except Exception: + product.prices.merchant.default_shipping_country = None + try: + product.prices.merchant.merchant_id = listings.merchant_info.id + except Exception: + product.prices.merchant.merchant_id = None + try: + product.prices.merchant.name = listings.merchant_info.name + except Exception: + product.prices.merchant.name = None + product.prices.other = Class() + try: + product.prices.other.buybox_winner = listings.is_buy_box_winner + except Exception: + product.prices.other.buybox_winner = None + try: + product.prices.other.loyalty_points = listings.loyalty_points + except Exception: + product.prices.other.loyalty_points = None + try: + product.prices.other.amazon_fulfilled = listings.delivery_info.is_amazon_fulfilled + except Exception: + product.prices.other.amazon_fulfilled = None + try: + product.prices.other.free_shipping_eligible = listings.delivery_info.is_free_shipping_eligible + except Exception: + product.prices.other.free_shipping_eligible = None + try: + product.prices.other.prime_eligible = listings.delivery_info.is_prime_eligible + except Exception: + product.prices.other.prime_eligible = None + try: + product.prices.other.prime_exclusive = listings.program_eligibility.is_prime_exclusive + except Exception: + product.prices.other.prime_exclusive = None + try: + product.prices.other.prime_pantry = listings.program_eligibility.is_prime_pantry + except Exception: + product.prices.other.prime_pantry = None + try: + product.prices.other.violates_map = listings.violates_map + except Exception: + product.prices.other.violates_map = None + try: + product.prices.other.offer_id = listings.id + except Exception: + product.prices.other.offer_id = None + + # Offers Summary + try: + summaries = item.offers.summaries + product.offers_summary = [] + except Exception: + summaries = None + product.offers_summary = None + if summaries: + for x in summaries: + offer = Class() + offer.highest_price = Class() + offer.lowest_price = Class() + try: + offer.highest_price.value = x.highest_price.amount + except Exception: + offer.highest_price.value = None + try: + offer.highest_price.currency = x.highest_price.currency + except Exception: + offer.highest_price.currency = None + try: + offer.highest_price.per_unit = x.highest_price.price_per_unit + except Exception: + offer.highest_price.per_unit = None + try: + offer.highest_price.display = x.highest_price.display_amount + except Exception: + offer.highest_price.display = None + try: + offer.lowest_price.value = x.lowest_price.amount + except Exception: + offer.lowest_price.value = None + try: + offer.lowest_price.currency = x.lowest_price.currency + except Exception: + offer.lowest_price.currency = None + try: + offer.lowest_price.per_unit = x.lowest_price.price_per_unit + except Exception: + offer.lowest_price.per_unit = None + try: + offer.lowest_price.display = x.lowest_price.display_amount + except Exception: + offer.lowest_price.display = None + offer.condition = Class() + try: + offer.condition.condition = x.condition.value + except Exception: + offer.condition.condition = None + try: + offer.condition.condition.condition_display = x.condition.display_value + except Exception: + offer.condition.condition_display = None + try: + offer.condition.condition.sub_condition = x.condition.sub_condition.value + except Exception: + offer.condition.sub_condition = None + try: + offer.condition.condition.sub_condition_display = x.condition.sub_condition.display_value + except Exception: + offer.condition.sub_condition_display = None + try: + offer.offer_count = x.offer_count + except Exception: + offer.offer_count = None + product.offers_summary.append(offer) + + return product diff --git a/amazon/serializer/dango_rest_framework.py b/amazon/serializer/dango_rest_framework.py new file mode 100644 index 0000000..8988c15 --- /dev/null +++ b/amazon/serializer/dango_rest_framework.py @@ -0,0 +1,156 @@ +from rest_framework import serializers + + +class _AmazonValueUnitSerializer(serializers.Serializer): + value = serializers.FloatField() + unit = serializers.CharField() + + +class _AmazonDimensionsSerializer(serializers.Serializer): + height = _AmazonValueUnitSerializer() + length = _AmazonValueUnitSerializer() + width = _AmazonValueUnitSerializer() + + +class _AmazonProductSerializer(serializers.Serializer): + features = serializers.ListField() + languages = serializers.ListField() + formats = serializers.ListField() + pages_count = serializers.ListField() + color = serializers.CharField() + unit_count = serializers.IntegerField() + size = serializers.CharField() + dimensions = _AmazonDimensionsSerializer() + weight = _AmazonValueUnitSerializer() + + +class _AmazonContributorsSerializer(serializers.Serializer): + name = serializers.CharField() + role = serializers.CharField() + + +class _AmazonExternalIdsSerializer(serializers.Serializer): + ean = serializers.ListField() + isbn = serializers.ListField() + upc = serializers.ListField() + + +class _AmazonInfoSerializer(serializers.Serializer): + contributors = _AmazonContributorsSerializer(many=True) + manufacturer = serializers.CharField() + brand = serializers.CharField() + model = serializers.CharField() + part_number = serializers.CharField() + product_group = serializers.CharField() + binding = serializers.CharField() + is_adult = serializers.BooleanField() + audience_rating = serializers.CharField() + edition = serializers.CharField() + warranty = serializers.CharField() + publication_date = serializers.CharField() + release_date = serializers.CharField() + external_ids = _AmazonExternalIdsSerializer() + + +class _AmazonImageVariantsSerializer(serializers.Serializer): + small = serializers.ListField() + medium = serializers.ListField() + large = serializers.ListField() + + +class _AmazonImagesSerializer(serializers.Serializer): + small = serializers.CharField() + medium = serializers.CharField() + large = serializers.CharField() + cropped = _AmazonImageVariantsSerializer() + variants = _AmazonImageVariantsSerializer() + + +class _AmazonTradeInSerializer(serializers.Serializer): + elegible = serializers.BooleanField() + price = serializers.FloatField() + currency = serializers.CharField() + + +class _AmazonSavingsSerializer(serializers.Serializer): + value = serializers.FloatField() + currency = serializers.CharField() + per_unit = serializers.FloatField() + display = serializers.CharField() + percentage = serializers.FloatField() + + +class _AmazonPriceSerializer(serializers.Serializer): + value = serializers.FloatField() + currency = serializers.CharField() + per_unit = serializers.FloatField() + display = serializers.CharField() + savings = _AmazonSavingsSerializer() + + +class _AmazonPvpSerializer(serializers.Serializer): + value = serializers.FloatField() + currency = serializers.CharField() + per_unit = serializers.FloatField() + display = serializers.CharField() + + +class _AmazonAvailabilitySerializer(serializers.Serializer): + max_order_quantity = serializers.IntegerField() + min_order_quantity = serializers.IntegerField() + type = serializers.CharField() + message = serializers.CharField() + + +class _AmazonConditionSerializer(serializers.Serializer): + condition = serializers.CharField() + condition_display = serializers.CharField() + sub_condition = serializers.CharField() + sub_condition_display = serializers.CharField() + + +class _AmazonMerchantSerializer(serializers.Serializer): + default_shipping_country = serializers.CharField() + merchant_id = serializers.CharField() + name = serializers.CharField() + + +class _AmazonOtherSerializer(serializers.Serializer): + buybox_winner = serializers.BooleanField() + loyalty_points = serializers.IntegerField() + amazon_fulfilled = serializers.BooleanField() + free_shipping_eligible = serializers.BooleanField() + prime_eligible = serializers.BooleanField() + prime_exclusive = serializers.BooleanField() + prime_pantry = serializers.BooleanField() + violates_map = serializers.BooleanField() + offer_id = serializers.CharField() + + +class _AmazonPricesSerializer(serializers.Serializer): + price = _AmazonPriceSerializer() + pvp = _AmazonPvpSerializer() + availability = _AmazonAvailabilitySerializer() + condition = _AmazonConditionSerializer() + merchant = _AmazonMerchantSerializer() + other = _AmazonOtherSerializer() + + +class _AmazonOffersSummarySerializer(serializers.Serializer): + highest_price = _AmazonPvpSerializer() + lowest_price = _AmazonPvpSerializer() + condition = _AmazonConditionSerializer() + offer_count = serializers.IntegerField() + + +class AmazonProductSerializer(serializers.Serializer): + asin = serializers.CharField(max_length=10) + parent_asin = serializers.CharField(max_length=10) + title = serializers.CharField() + url = serializers.CharField() + product = _AmazonProductSerializer() + info = _AmazonInfoSerializer() + images = _AmazonImagesSerializer() + trade_in = _AmazonTradeInSerializer() + prices = _AmazonPricesSerializer() + offers_summary = _AmazonOffersSummarySerializer(many=True) diff --git a/amazon/tools.py b/amazon/tools.py new file mode 100644 index 0000000..c67e29f --- /dev/null +++ b/amazon/tools.py @@ -0,0 +1,26 @@ +"""Some useful tools.""" + +import re + + +def get_asin(url: str): + """Find the ASIN from a given URL. + + Args: + url (str): The URL containing the product ASIN. + + Returns: + str: Product ASIN. None if ASIN not found. + """ + # Return if url parameter already is the ASIN + if re.search(r'^[A-Z0-9]{10}$', url): + return url + # Extract ASIN from URL searching for alphanumeric and 10 digits + have_asin = re.search(r'(dp|gp/product|gp/aw/d|dp/product)/([a-zA-Z0-9]{10})', url) + return have_asin.group(2) if have_asin else None + + +def chunks(lst, n): + """Yield successive n-sized chunks from lst.""" + for i in range(0, len(lst), n): + yield lst[i:i + n]