python-amazon-sp-api 2.0.15__py3-none-any.whl → 2.1.3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (214) hide show
  1. {python_amazon_sp_api-2.0.15.dist-info → python_amazon_sp_api-2.1.3.dist-info}/METADATA +7 -7
  2. python_amazon_sp_api-2.1.3.dist-info/RECORD +350 -0
  3. sp_api/__version__.py +1 -1
  4. sp_api/api/__init__.py +160 -4
  5. sp_api/api/amazon_warehousing_and_distribu/amazon_warehousing_and_distribu.py +85 -110
  6. sp_api/api/amazon_warehousing_and_distribu/amazon_warehousing_and_distribu_2024_05_09.py +456 -0
  7. sp_api/api/aplus_content/aplus_content.py +176 -125
  8. sp_api/api/application_integrations/application_integrations.py +59 -68
  9. sp_api/api/application_management/application_management.py +20 -13
  10. sp_api/api/authorization/authorization.py +8 -26
  11. sp_api/api/catalog/catalog.py +27 -61
  12. sp_api/api/catalog_items/catalog_items.py +108 -78
  13. sp_api/api/catalog_items/catalog_items_2020_12_01.py +86 -0
  14. sp_api/api/catalog_items/catalog_items_2022_04_01.py +89 -0
  15. sp_api/api/customer_feedback/customer_feedback.py +100 -0
  16. sp_api/api/data_kiosk/data_kiosk.py +80 -75
  17. sp_api/api/delivery_by_amazon/__init__.py +0 -0
  18. sp_api/api/delivery_by_amazon/delivery_by_amazon.py +92 -0
  19. sp_api/api/delivery_by_amazon/delivery_by_amazon_2022_07_01.py +81 -0
  20. sp_api/api/easy_ship/easy_ship.py +121 -111
  21. sp_api/api/external_fulfillment/external_fulfillment.py +211 -434
  22. sp_api/api/external_fulfillment/inventory.py +120 -0
  23. sp_api/api/external_fulfillment/inventory_2021_01_06.py +71 -0
  24. sp_api/api/external_fulfillment/inventory_2024_09_11.py +96 -0
  25. sp_api/api/external_fulfillment/returns.py +120 -0
  26. sp_api/api/external_fulfillment/returns_2021_08_19.py +88 -0
  27. sp_api/api/external_fulfillment/returns_2024_09_11.py +141 -0
  28. sp_api/api/external_fulfillment/shipping.py +120 -0
  29. sp_api/api/external_fulfillment/shipping_2021_01_06.py +256 -0
  30. sp_api/api/external_fulfillment/shipping_2024_09_11.py +233 -0
  31. sp_api/api/fba_inbound_eligibility/fba_inbound_eligibility.py +30 -24
  32. sp_api/api/fba_small_and_light/fba_small_and_light.py +60 -99
  33. sp_api/api/feeds/feeds.py +75 -245
  34. sp_api/api/feeds/feeds_2021_06_30.py +320 -0
  35. sp_api/api/finances/finances.py +123 -90
  36. sp_api/api/finances/finances_2024_06_01.py +71 -0
  37. sp_api/api/finances/finances_2024_06_19.py +114 -0
  38. sp_api/api/finances/finances_v0.py +116 -0
  39. sp_api/api/fulfillment_inbound/fulfillment_inbound.py +107 -1784
  40. sp_api/api/fulfillment_inbound/fulfillment_inbound_2024_03_20.py +1722 -0
  41. sp_api/api/fulfillment_inbound/fulfillment_inbound_v0.py +1384 -0
  42. sp_api/api/fulfillment_outbound/fulfillment_outbound.py +256 -480
  43. sp_api/api/inventories/inventories.py +79 -42
  44. sp_api/api/invoices/__init__.py +0 -0
  45. sp_api/api/invoices/invoices.py +92 -0
  46. sp_api/api/invoices/invoices_2024_06_19.py +344 -0
  47. sp_api/api/listings_items/listings_items.py +110 -163
  48. sp_api/api/listings_items/listings_items_2020_09_01.py +189 -0
  49. sp_api/api/listings_items/listings_items_2021_08_01.py +233 -0
  50. sp_api/api/listings_restrictions/listings_restrictions.py +23 -10
  51. sp_api/api/merchant_fulfillment/merchant_fulfillment.py +107 -222
  52. sp_api/api/messaging/messaging.py +184 -198
  53. sp_api/api/notifications/notifications.py +144 -106
  54. sp_api/api/orders/orders.py +9 -46
  55. sp_api/api/orders/orders_2026_01_01.py +19 -65
  56. sp_api/api/orders/orders_v0.py +152 -184
  57. sp_api/api/product_fees/product_fees.py +101 -75
  58. sp_api/api/product_type_definitions/product_type_definitions.py +47 -36
  59. sp_api/api/products/products.py +94 -386
  60. sp_api/api/products/products_2022_05_01.py +96 -0
  61. sp_api/api/products/products_v0.py +389 -0
  62. sp_api/api/replenishment/replenishment.py +58 -69
  63. sp_api/api/reports/reports.py +124 -157
  64. sp_api/api/sales/sales.py +22 -39
  65. sp_api/api/seller_wallet/__init__.py +0 -0
  66. sp_api/api/seller_wallet/seller_wallet.py +92 -0
  67. sp_api/api/seller_wallet/seller_wallet_2024_03_01.py +300 -0
  68. sp_api/api/sellers/sellers.py +15 -35
  69. sp_api/api/services/services.py +479 -82
  70. sp_api/api/shipment_invoicing/__init__.py +0 -0
  71. sp_api/api/shipment_invoicing/shipment_invoicing.py +92 -0
  72. sp_api/api/shipment_invoicing/shipment_invoicing_v0.py +101 -0
  73. sp_api/api/shipping/shipping.py +94 -440
  74. sp_api/api/shipping/shippingV2.py +183 -474
  75. sp_api/api/shipping/shipping_v1.py +330 -0
  76. sp_api/api/shipping/shipping_v2.py +723 -0
  77. sp_api/api/solicitations/solicitations.py +28 -18
  78. sp_api/api/supply_sources/supply_sources.py +67 -57
  79. sp_api/api/tokens/tokens.py +14 -35
  80. sp_api/api/vehicles/__init__.py +0 -0
  81. sp_api/api/vehicles/vehicles.py +92 -0
  82. sp_api/api/vehicles/vehicles_2024_11_01.py +33 -0
  83. sp_api/api/vendor_direct_fulfillment_inventory/vendor_direct_fulfillment_inventory.py +16 -29
  84. sp_api/api/vendor_direct_fulfillment_orders/vendor_direct_fulfillment_orders.py +116 -189
  85. sp_api/api/vendor_direct_fulfillment_orders/vendor_direct_fulfillment_orders_2021_12_28.py +114 -0
  86. sp_api/api/vendor_direct_fulfillment_orders/vendor_direct_fulfillment_orders_v1.py +114 -0
  87. sp_api/api/vendor_direct_fulfillment_payments/vendor_direct_fulfillment_payments.py +15 -225
  88. sp_api/api/vendor_direct_fulfillment_sandbox_test_data/__init__.py +0 -0
  89. sp_api/api/vendor_direct_fulfillment_sandbox_test_data/vendor_direct_fulfillment_sandbox_test_data.py +92 -0
  90. sp_api/api/vendor_direct_fulfillment_sandbox_test_data/vendor_direct_fulfillment_sandbox_test_data_2021_10_28.py +50 -0
  91. sp_api/api/vendor_direct_fulfillment_shipping/vendor_direct_fulfillment_shipping.py +122 -624
  92. sp_api/api/vendor_direct_fulfillment_shipping/vendor_direct_fulfillment_shipping_2021_12_28.py +390 -0
  93. sp_api/api/vendor_direct_fulfillment_shipping/vendor_direct_fulfillment_shipping_v1.py +320 -0
  94. sp_api/api/vendor_direct_fulfillment_transactions/vendor_direct_fulfillment_transactions.py +113 -29
  95. sp_api/api/vendor_direct_fulfillment_transactions/vendor_direct_fulfillment_transactions_2021_12_28.py +47 -0
  96. sp_api/api/vendor_direct_fulfillment_transactions/vendor_direct_fulfillment_transactions_v1.py +47 -0
  97. sp_api/api/vendor_invoices/vendor_invoices.py +15 -264
  98. sp_api/api/vendor_orders/vendor_orders.py +83 -131
  99. sp_api/api/vendor_shipments/vendor_shipments.py +149 -68
  100. sp_api/api/vendor_transaction_status/vendor_transaction_status.py +16 -11
  101. sp_api/asyncio/api/__init__.py +159 -4
  102. sp_api/asyncio/api/amazon_warehousing_and_distribu/amazon_warehousing_and_distribu.py +84 -110
  103. sp_api/asyncio/api/amazon_warehousing_and_distribu/amazon_warehousing_and_distribu_2024_05_09.py +457 -0
  104. sp_api/asyncio/api/aplus_content/aplus_content.py +176 -125
  105. sp_api/asyncio/api/application_integrations/application_integrations.py +59 -68
  106. sp_api/asyncio/api/application_management/application_management.py +20 -13
  107. sp_api/asyncio/api/authorization/authorization.py +8 -26
  108. sp_api/asyncio/api/catalog/catalog.py +27 -61
  109. sp_api/asyncio/api/catalog_items/catalog_items.py +94 -71
  110. sp_api/asyncio/api/catalog_items/catalog_items_2020_12_01.py +87 -0
  111. sp_api/asyncio/api/catalog_items/catalog_items_2022_04_01.py +90 -0
  112. sp_api/asyncio/api/customer_feedback/customer_feedback.py +100 -0
  113. sp_api/asyncio/api/data_kiosk/data_kiosk.py +80 -75
  114. sp_api/asyncio/api/delivery_by_amazon/__init__.py +0 -0
  115. sp_api/asyncio/api/delivery_by_amazon/delivery_by_amazon.py +92 -0
  116. sp_api/asyncio/api/delivery_by_amazon/delivery_by_amazon_2022_07_01.py +82 -0
  117. sp_api/asyncio/api/easy_ship/easy_ship.py +121 -111
  118. sp_api/asyncio/api/external_fulfillment/external_fulfillment.py +212 -435
  119. sp_api/asyncio/api/external_fulfillment/inventory.py +126 -0
  120. sp_api/asyncio/api/external_fulfillment/inventory_2021_01_06.py +73 -0
  121. sp_api/asyncio/api/external_fulfillment/inventory_2024_09_11.py +98 -0
  122. sp_api/asyncio/api/external_fulfillment/returns.py +124 -0
  123. sp_api/asyncio/api/external_fulfillment/returns_2021_08_19.py +90 -0
  124. sp_api/asyncio/api/external_fulfillment/returns_2024_09_11.py +143 -0
  125. sp_api/asyncio/api/external_fulfillment/shipping.py +124 -0
  126. sp_api/asyncio/api/external_fulfillment/shipping_2021_01_06.py +258 -0
  127. sp_api/asyncio/api/external_fulfillment/shipping_2024_09_11.py +235 -0
  128. sp_api/asyncio/api/fba_inbound_eligibility/fba_inbound_eligibility.py +31 -25
  129. sp_api/asyncio/api/fba_small_and_light/fba_small_and_light.py +61 -100
  130. sp_api/asyncio/api/feeds/feeds.py +75 -243
  131. sp_api/asyncio/api/feeds/feeds_2021_06_30.py +318 -0
  132. sp_api/asyncio/api/finances/finances.py +123 -91
  133. sp_api/asyncio/api/finances/finances_2024_06_01.py +72 -0
  134. sp_api/asyncio/api/finances/finances_2024_06_19.py +115 -0
  135. sp_api/asyncio/api/finances/finances_v0.py +117 -0
  136. sp_api/asyncio/api/fulfillment_inbound/fulfillment_inbound.py +107 -1785
  137. sp_api/asyncio/api/fulfillment_inbound/fulfillment_inbound_2024_03_20.py +1723 -0
  138. sp_api/asyncio/api/fulfillment_inbound/fulfillment_inbound_v0.py +1385 -0
  139. sp_api/asyncio/api/fulfillment_outbound/fulfillment_outbound.py +257 -481
  140. sp_api/asyncio/api/inventories/inventories.py +79 -42
  141. sp_api/asyncio/api/invoices/__init__.py +0 -0
  142. sp_api/asyncio/api/invoices/invoices.py +92 -0
  143. sp_api/asyncio/api/invoices/invoices_2024_06_19.py +345 -0
  144. sp_api/asyncio/api/listings_items/listings_items.py +109 -163
  145. sp_api/asyncio/api/listings_items/listings_items_2020_09_01.py +190 -0
  146. sp_api/asyncio/api/listings_items/listings_items_2021_08_01.py +233 -0
  147. sp_api/asyncio/api/listings_restrictions/listings_restrictions.py +23 -10
  148. sp_api/asyncio/api/merchant_fulfillment/merchant_fulfillment.py +110 -222
  149. sp_api/asyncio/api/messaging/messaging.py +185 -199
  150. sp_api/asyncio/api/notifications/notifications.py +145 -107
  151. sp_api/asyncio/api/orders/orders.py +9 -46
  152. sp_api/asyncio/api/orders/orders_2026_01_01.py +19 -65
  153. sp_api/asyncio/api/orders/orders_v0.py +152 -184
  154. sp_api/asyncio/api/product_fees/product_fees.py +101 -75
  155. sp_api/asyncio/api/product_type_definitions/product_type_definitions.py +47 -36
  156. sp_api/asyncio/api/products/products.py +94 -387
  157. sp_api/asyncio/api/products/products_2022_05_01.py +109 -0
  158. sp_api/asyncio/api/products/products_v0.py +388 -0
  159. sp_api/asyncio/api/replenishment/replenishment.py +59 -70
  160. sp_api/asyncio/api/reports/reports.py +124 -157
  161. sp_api/asyncio/api/sales/sales.py +22 -39
  162. sp_api/asyncio/api/seller_wallet/__init__.py +0 -0
  163. sp_api/asyncio/api/seller_wallet/seller_wallet.py +92 -0
  164. sp_api/asyncio/api/seller_wallet/seller_wallet_2024_03_01.py +301 -0
  165. sp_api/asyncio/api/sellers/sellers.py +16 -36
  166. sp_api/asyncio/api/services/services.py +479 -82
  167. sp_api/asyncio/api/shipment_invoicing/__init__.py +0 -0
  168. sp_api/asyncio/api/shipment_invoicing/shipment_invoicing.py +92 -0
  169. sp_api/asyncio/api/shipment_invoicing/shipment_invoicing_v0.py +102 -0
  170. sp_api/asyncio/api/shipping/shipping.py +94 -441
  171. sp_api/asyncio/api/shipping/shippingV2.py +181 -472
  172. sp_api/asyncio/api/shipping/shipping_v1.py +331 -0
  173. sp_api/asyncio/api/shipping/shipping_v2.py +717 -0
  174. sp_api/asyncio/api/solicitations/solicitations.py +29 -19
  175. sp_api/asyncio/api/supply_sources/supply_sources.py +67 -57
  176. sp_api/asyncio/api/tokens/tokens.py +14 -35
  177. sp_api/asyncio/api/vehicles/__init__.py +0 -0
  178. sp_api/asyncio/api/vehicles/vehicles.py +92 -0
  179. sp_api/asyncio/api/vehicles/vehicles_2024_11_01.py +34 -0
  180. sp_api/asyncio/api/vendor_direct_fulfillment_inventory/vendor_direct_fulfillment_inventory.py +16 -29
  181. sp_api/asyncio/api/vendor_direct_fulfillment_orders/vendor_direct_fulfillment_orders.py +120 -192
  182. sp_api/asyncio/api/vendor_direct_fulfillment_orders/vendor_direct_fulfillment_orders_2021_12_28.py +116 -0
  183. sp_api/asyncio/api/vendor_direct_fulfillment_orders/vendor_direct_fulfillment_orders_v1.py +115 -0
  184. sp_api/asyncio/api/vendor_direct_fulfillment_payments/vendor_direct_fulfillment_payments.py +15 -225
  185. sp_api/asyncio/api/vendor_direct_fulfillment_sandbox_test_data/__init__.py +0 -0
  186. sp_api/asyncio/api/vendor_direct_fulfillment_sandbox_test_data/vendor_direct_fulfillment_sandbox_test_data.py +92 -0
  187. sp_api/asyncio/api/vendor_direct_fulfillment_sandbox_test_data/vendor_direct_fulfillment_sandbox_test_data_2021_10_28.py +51 -0
  188. sp_api/asyncio/api/vendor_direct_fulfillment_shipping/vendor_direct_fulfillment_shipping.py +120 -623
  189. sp_api/asyncio/api/vendor_direct_fulfillment_shipping/vendor_direct_fulfillment_shipping_2021_12_28.py +392 -0
  190. sp_api/asyncio/api/vendor_direct_fulfillment_shipping/vendor_direct_fulfillment_shipping_v1.py +321 -0
  191. sp_api/asyncio/api/vendor_direct_fulfillment_transactions/vendor_direct_fulfillment_transactions.py +112 -29
  192. sp_api/asyncio/api/vendor_direct_fulfillment_transactions/vendor_direct_fulfillment_transactions_2021_12_28.py +49 -0
  193. sp_api/asyncio/api/vendor_direct_fulfillment_transactions/vendor_direct_fulfillment_transactions_v1.py +48 -0
  194. sp_api/asyncio/api/vendor_invoices/vendor_invoices.py +16 -265
  195. sp_api/asyncio/api/vendor_orders/vendor_orders.py +84 -132
  196. sp_api/asyncio/api/vendor_shipments/vendor_shipments.py +150 -69
  197. sp_api/asyncio/api/vendor_transaction_status/vendor_transaction_status.py +17 -12
  198. sp_api/asyncio/base/client.py +2 -2
  199. sp_api/asyncio/util/load_date_bound.py +1 -1
  200. sp_api/base/__init__.py +10 -0
  201. sp_api/base/_core.py +2 -2
  202. sp_api/base/client.py +3 -3
  203. sp_api/base/helpers.py +12 -1
  204. sp_api/base/marketplaces.py +6 -3
  205. sp_api/util/__init__.py +2 -0
  206. sp_api/util/load_date_bound.py +1 -1
  207. sp_api/util/versioned_client.py +45 -0
  208. python_amazon_sp_api-2.0.15.dist-info/RECORD +0 -255
  209. sp_api/asyncio/api/models/__init__.py +0 -4
  210. sp_api/asyncio/api/overrides/__init__.py +0 -1
  211. {python_amazon_sp_api-2.0.15.data → python_amazon_sp_api-2.1.3.data}/scripts/make_endpoint +0 -0
  212. {python_amazon_sp_api-2.0.15.dist-info → python_amazon_sp_api-2.1.3.dist-info}/WHEEL +0 -0
  213. {python_amazon_sp_api-2.0.15.dist-info → python_amazon_sp_api-2.1.3.dist-info}/licenses/LICENSE +0 -0
  214. {python_amazon_sp_api-2.0.15.dist-info → python_amazon_sp_api-2.1.3.dist-info}/top_level.txt +0 -0
@@ -37,36 +37,33 @@ class Reports(Client):
37
37
  def get_reports(self, **kwargs) -> ApiResponse:
38
38
  """
39
39
  get_reports(self, **kwargs) -> ApiResponse
40
-
40
+
41
41
  Returns report details for the reports that match the filters that you specify.
42
-
42
+
43
43
  **Usage Plan:**
44
-
44
+
45
45
  ====================================== ==============
46
46
  Rate (requests per second) Burst
47
47
  ====================================== ==============
48
48
  0.0222 10
49
49
  ====================================== ==============
50
-
50
+
51
51
  For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
52
-
52
+
53
53
  Examples:
54
54
  literal blocks::
55
-
56
- report_types = ["FEE_DISCOUNTS_REPORT", "GET_AFN_INVENTORY_DATA"]
57
- processing_status = ["IN_QUEUE", "IN_PROGRESS"]
58
- res = Reports().get_reports(reportTypes=report_types, processingStatuses=processing_status)
59
-
55
+
56
+ Reports().get_reports()
57
+
60
58
  Args:
61
- key reportTypes: str[] or ReportType[] | optional A list of report types used to filter reports. When reportTypes is provided, the other filter parameters (processingStatuses, marketplaceIds, createdSince, createdUntil) and pageSize may also be provided. Either reportTypes or nextToken is required.
62
- key processingStatuses: str[] or ProcessingStatus[] optional A list of processing statuses used to filter reports.
63
- key marketplaceIds: str[] or Marketplaces[] optional A list of marketplace identifiers used to filter reports. The reports returned will match at least one of the marketplaces that you specify.
64
- key pageSize: int optional The maximum number of reports to return in a single call.
65
- key createdSince: str or datetime optional The earliest report creation date and time for reports to include in the response, in ISO 8601 date time format. The default is 90 days ago. Reports are retained for a maximum of 90 days. string (date-time) -
66
- key createdUntil: str or datetime optional The latest report creation date and time for reports to include in the response, in ISO 8601 date time format. The default is now. string (date-time) -
67
- key nextToken: str optional A stringget_report_document token returned in the response to your previous request. nextToken is returned when the number of results exceeds the specified pageSize value. To get the next page of results, call the getReports operation and include this token as the only parameter. Specifying nextToken with any other parameters will cause the request to fail. string -
68
-
69
-
59
+ key reportTypes: object | A list of report types used to filter reports. Refer to [Report Type Values](https://developer-docs.amazon.com/sp-api/docs/report-type-values) for more information. When reportTypes is provided, the other filter parameters (processingStatuses, marketplaceIds, createdSince, createdUntil) and pageSize may also be provided. Either reportTypes or nextToken is required.
60
+ key processingStatuses: object | A list of processing statuses used to filter reports.
61
+ key marketplaceIds: object | A list of marketplace identifiers used to filter reports. The reports returned will match at least one of the marketplaces that you specify.
62
+ key pageSize: object | The maximum number of reports to return in a single call.
63
+ key createdSince: object | The earliest report creation date and time for reports to include in the response, in <a href='https://developer-docs.amazon.com/sp-api/docs/iso-8601'>ISO 8601</a> date time format. The default is 90 days ago. Reports are retained for a maximum of 90 days.
64
+ key createdUntil: object | The latest report creation date and time for reports to include in the response, in <a href='https://developer-docs.amazon.com/sp-api/docs/iso-8601'>ISO 8601</a> date time format. The default is now.
65
+ key nextToken: object | A string token returned in the response to your previous request. `nextToken` is returned when the number of results exceeds the specified `pageSize` value. To get the next page of results, call the `getReports` operation and include this token as the only parameter. Specifying `nextToken` with any other parameters will cause the request to fail.
66
+
70
67
  Returns:
71
68
  ApiResponse
72
69
  """
@@ -85,36 +82,27 @@ class Reports(Client):
85
82
  def create_report(self, **kwargs) -> ApiResponse:
86
83
  """
87
84
  create_report(self, **kwargs) -> ApiResponse
88
-
89
- See report types at
90
- :link: https://github.com/amzn/selling-partner-api-docs/blob/main/references/reports-api/reporttype-values.md
91
-
85
+
86
+ Creates a report.
87
+
92
88
  **Usage Plan:**
93
-
89
+
94
90
  ====================================== ==============
95
91
  Rate (requests per second) Burst
96
92
  ====================================== ==============
97
93
  0.0167 15
98
94
  ====================================== ==============
99
-
95
+
96
+ For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
97
+
100
98
  Examples:
101
99
  literal blocks::
102
-
103
- res = Reports().create_report(
104
- reportType=ReportType.GET_MERCHANT_LISTINGS_ALL_DATA,
105
- dataStartTime='2019-12-10T20:11:24.000Z',
106
- marketplaceIds=[
107
- "A1PA6795UKMFR9",
108
- "ATVPDKIKX0DER"
109
- ])
110
-
100
+
101
+ Reports().create_report()
102
+
111
103
  Args:
112
- key reportOptions: optional Additional information passed to reports. This varies by report type. ReportOptions
113
- key reportType: required The report type. :link: https://github.com/amzn/selling-partner-api-docs/blob/main/references/reports-api/reporttype-values.md
114
- key dataStartTime: optional The start of a date and time range, in ISO 8601 date time format, used for selecting the data to report. The default is now. The value must be prior to or equal to the current date and time. Not all report types make use of this. string (date-time)
115
- key dataEndTime: optional The end of a date and time range, in ISO 8601 date time format, used for selecting the data to report. The default is now. The value must be prior to or equal to the current date and time. Not all report types make use of this. string (date-time)
116
- key marketplaceIds: optional, defaults to the client's marketplace A list of marketplace identifiers. The report document's contents will contain data for all of the specified marketplaces, unless the report type indicates otherwise. < string > array
117
-
104
+ body: CreateReportSpecification | required Information required to create the report.
105
+
118
106
  Returns:
119
107
  ApiResponse
120
108
  """
@@ -125,24 +113,29 @@ class Reports(Client):
125
113
  def cancel_report(self, reportId, **kwargs) -> ApiResponse:
126
114
  """
127
115
  cancel_report(self, reportId, **kwargs) -> ApiResponse
128
-
129
- Cancels the report that you specify. Only reports with processingStatus=IN_QUEUE can be cancelled. Cancelled reports are returned in subsequent calls to the getReport and getReports operations.
130
-
116
+
117
+ Cancels the report that you specify. Only reports with `processingStatus=IN_QUEUE` can be cancelled. Cancelled reports are returned in subsequent calls to the `getReport` and `getReports` operations.
118
+
131
119
  **Usage Plan:**
132
-
120
+
133
121
  ====================================== ==============
134
122
  Rate (requests per second) Burst
135
123
  ====================================== ==============
136
- 0.0022 10
124
+ 0.0222 10
137
125
  ====================================== ==============
138
-
126
+
139
127
  For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
140
-
128
+
129
+ Examples:
130
+ literal blocks::
131
+
132
+ Reports().cancel_report("value")
133
+
141
134
  Args:
142
- reportId:string | * REQUIRED The identifier for the report. This identifier is unique only in combination with a seller ID.
143
-
135
+ reportId: object | required The identifier for the report. This identifier is unique only in combination with a seller ID.
136
+
144
137
  Returns:
145
- ApiResponse:
138
+ ApiResponse
146
139
  """
147
140
 
148
141
  return self._request(
@@ -152,31 +145,30 @@ class Reports(Client):
152
145
  @sp_endpoint("/reports/2021-06-30/reports/{}", method="GET")
153
146
  def get_report(self, reportId, **kwargs) -> ApiResponse:
154
147
  """
155
- get_report(self, report_id, **kwargs)
156
- Returns report details (including the reportDocumentId, if available) for the report that you specify.
157
-
148
+ get_report(self, reportId, **kwargs) -> ApiResponse
149
+
150
+ Returns report details (including the `reportDocumentId`, if available) for the report that you specify.
151
+
158
152
  **Usage Plan:**
159
-
153
+
160
154
  ====================================== ==============
161
155
  Rate (requests per second) Burst
162
156
  ====================================== ==============
163
157
  2 15
164
158
  ====================================== ==============
165
-
166
-
159
+
167
160
  For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
168
-
161
+
169
162
  Examples:
170
163
  literal blocks::
171
-
172
- Reports().get_report('ID323')
173
-
164
+
165
+ Reports().get_report("value")
166
+
174
167
  Args:
175
- reportId: str
176
-
168
+ reportId: object | required The identifier for the report. This identifier is unique only in combination with a seller ID.
169
+
177
170
  Returns:
178
171
  ApiResponse
179
-
180
172
  """
181
173
 
182
174
  return self._request(
@@ -186,21 +178,28 @@ class Reports(Client):
186
178
  @sp_endpoint("/reports/2021-06-30/schedules", method="GET")
187
179
  def get_report_schedules(self, **kwargs) -> ApiResponse:
188
180
  """
181
+ get_report_schedules(self, **kwargs) -> ApiResponse
182
+
189
183
  Returns report schedule details that match the filters that you specify.
190
-
184
+
191
185
  **Usage Plan:**
192
-
186
+
193
187
  ====================================== ==============
194
188
  Rate (requests per second) Burst
195
189
  ====================================== ==============
196
190
  0.0222 10
197
191
  ====================================== ==============
198
-
192
+
199
193
  For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
200
-
194
+
195
+ Examples:
196
+ literal blocks::
197
+
198
+ Reports().get_report_schedules()
199
+
201
200
  Args:
202
- key reportTypes: str[] or ReportType[] | required A list of report types used to filter report schedules. Min count : 1. Max count : 10.
203
-
201
+ key reportTypes: object | required A list of report types used to filter report schedules. Refer to [Report Type Values](https://developer-docs.amazon.com/sp-api/docs/report-type-values) for more information.
202
+
204
203
  Returns:
205
204
  ApiResponse
206
205
  """
@@ -212,34 +211,29 @@ class Reports(Client):
212
211
  def create_report_schedule(self, **kwargs) -> ApiResponse:
213
212
  """
214
213
  create_report_schedule(self, **kwargs) -> ApiResponse
215
-
214
+
216
215
  Creates a report schedule. If a report schedule with the same report type and marketplace IDs already exists, it will be cancelled and replaced with this one.
217
-
216
+
218
217
  **Usage Plan:**
219
-
218
+
220
219
  ====================================== ==============
221
220
  Rate (requests per second) Burst
222
221
  ====================================== ==============
223
222
  0.0222 10
224
223
  ====================================== ==============
225
-
224
+
225
+ For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
226
+
226
227
  Examples:
227
228
  literal blocks::
228
-
229
- Reports().create_report_schedule(reportType='FEE_DISCOUNTS_REPORT',
230
- period=Schedules.MINUTES_5.value,
231
- nextReportCreationTime="2019-12-10T20:11:24.000Z",
232
- marketplaceIds=["A1PA6795UKMFR9", "ATVPDKIKX0DER"])
233
-
229
+
230
+ Reports().create_report_schedule()
231
+
234
232
  Args:
235
- key reportType: str
236
- key marketplaceIds: str
237
- key reportOptions: dict
238
- key period: Schedules
239
- key nextReportCreationTime: str datetime isoformat
240
-
233
+ body: CreateReportScheduleSpecification | required Information required to create the report schedule.
234
+
241
235
  Returns:
242
- ApiResponse:
236
+ ApiResponse
243
237
  """
244
238
 
245
239
  return self._request(kwargs.pop("path"), data=kwargs)
@@ -248,28 +242,27 @@ class Reports(Client):
248
242
  def cancel_report_schedule(self, reportScheduleId, **kwargs) -> ApiResponse:
249
243
  """
250
244
  cancel_report_schedule(self, reportScheduleId, **kwargs) -> ApiResponse
251
-
245
+
252
246
  Cancels the report schedule that you specify.
253
-
247
+
254
248
  **Usage Plan:**
255
-
249
+
256
250
  ====================================== ==============
257
251
  Rate (requests per second) Burst
258
252
  ====================================== ==============
259
253
  0.0222 10
260
254
  ====================================== ==============
261
-
255
+
262
256
  For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
263
-
257
+
264
258
  Examples:
265
259
  literal blocks::
266
-
267
- Reports().cancel_report_schedule('ID')
268
-
260
+
261
+ Reports().cancel_report_schedule("value")
262
+
269
263
  Args:
270
- reportScheduleId: str
271
- kwargs:
272
-
264
+ reportScheduleId: object | required The identifier for the report schedule. This identifier is unique only in combination with a seller ID.
265
+
273
266
  Returns:
274
267
  ApiResponse
275
268
  """
@@ -279,29 +272,20 @@ class Reports(Client):
279
272
 
280
273
  def delete_report_schedule(self, reportScheduleId, **kwargs) -> ApiResponse:
281
274
  """
275
+ delete_report_schedule(self, reportScheduleId, **kwargs) -> ApiResponse
276
+
282
277
  cancel_report_schedule(self, reportScheduleId, **kwargs) -> ApiResponse
283
-
284
- Cancels the report schedule that you specify.
285
-
286
- **Usage Plan:**
287
-
288
- ====================================== ==============
289
- Rate (requests per second) Burst
290
- ====================================== ==============
291
- 0.0222 10
292
- ====================================== ==============
293
-
294
- For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
295
-
278
+ Cancels the report schedule that you specify.
279
+
296
280
  Examples:
297
281
  literal blocks::
298
-
299
- Reports().cancel_report_schedule('ID')
300
-
282
+
283
+ Reports().delete_report_schedule("value")
284
+
301
285
  Args:
302
- reportScheduleId: str
303
- kwargs:
304
-
286
+ reportScheduleId: | required
287
+ **kwargs:
288
+
305
289
  Returns:
306
290
  ApiResponse
307
291
  """
@@ -311,28 +295,27 @@ class Reports(Client):
311
295
  def get_report_schedule(self, reportScheduleId, **kwargs) -> ApiResponse:
312
296
  """
313
297
  get_report_schedule(self, reportScheduleId, **kwargs) -> ApiResponse
314
-
298
+
315
299
  Returns report schedule details for the report schedule that you specify.
316
-
300
+
317
301
  **Usage Plan:**
318
-
302
+
319
303
  ====================================== ==============
320
304
  Rate (requests per second) Burst
321
305
  ====================================== ==============
322
306
  0.0222 10
323
307
  ====================================== ==============
324
-
308
+
325
309
  For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
326
-
310
+
327
311
  Examples:
328
312
  literal blocks::
329
-
330
- Reports().get_report_schedule('ID323')
331
-
313
+
314
+ Reports().get_report_schedule("value")
315
+
332
316
  Args:
333
- reportScheduleId: str | required The identifier for the report schedule. This identifier is unique only in combination with a seller ID.
334
- kwargs:
335
-
317
+ reportScheduleId: object | required The identifier for the report schedule. This identifier is unique only in combination with a seller ID.
318
+
336
319
  Returns:
337
320
  ApiResponse
338
321
  """
@@ -352,47 +335,31 @@ class Reports(Client):
352
335
  **kwargs
353
336
  ) -> ApiResponse:
354
337
  """
355
- get_report_document(self, document_id, decrypt: bool = False, file=None, character_code: Optional[str] = None, **kwargs) -> ApiResponse
356
- Returns the information required for retrieving a report document's contents. This includes a presigned URL for the report document as well as the information required to decrypt the document's contents.
357
-
358
- If decrypt = True the report will automatically be loaded and decrypted/unpacked
359
- If file is set to a file (or file like object), the report's contents are written to the file
360
-
361
-
338
+ get_report_document(self, reportDocumentId, download, file, character_code, stream, timeout, **kwargs) -> ApiResponse
339
+
340
+ Returns the information required for retrieving a report document's contents.
341
+
362
342
  **Usage Plan:**
363
-
364
-
343
+
365
344
  ====================================== ==============
366
345
  Rate (requests per second) Burst
367
346
  ====================================== ==============
368
347
  0.0167 15
369
348
  ====================================== ==============
370
-
371
-
372
-
349
+
373
350
  For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
374
-
351
+
375
352
  Examples:
376
353
  literal blocks::
377
-
378
- Reports().get_report_document('0356cf79-b8b0-4226-b4b9-0ee058ea5760', download=True, file=file)
379
-
354
+
355
+ Reports().get_report_document("value", "value", "value", "value", "value", "value")
356
+
380
357
  Args:
381
- reportDocumentId: str | the document to load
382
- download: bool | flag to automatically download a report
383
- file: If passed, will save the document to the file specified.
384
- Only valid if decrypt=True
385
- character_code: If passed, will be a file with the specified character code.
386
- The default is the Content-Encoding in the response while
387
- obtaining the document from the document URL.
388
- It fallbacks to 'iso-8859-1' if no encoding was found.
389
- Only valid if decrypt=True.
390
- stream: bool | if True and file is provided, stream the document to disk
391
- timeout: int | optional, the timeout for the request to download the document
392
-
358
+ reportDocumentId: object | required The identifier for the report document.
359
+
393
360
  Returns:
394
- ApiResponse
395
- """ # noqa: E501
361
+ ApiResponse
362
+ """
396
363
  res = self._request(
397
364
  fill_query_params(kwargs.pop("path"), reportDocumentId),
398
365
  add_marketplace=False,
sp_api/api/sales/sales.py CHANGED
@@ -20,45 +20,21 @@ class Sales(Client):
20
20
  **kwargs
21
21
  ) -> ApiResponse:
22
22
  """
23
- get_order_metrics(self, interval: tuple, granularity: Granularity, granularityTimeZone: str = None, **kwargs) -> ApiResponse
24
-
23
+ get_order_metrics(self, interval, granularity, granularityTimeZone, **kwargs) -> ApiResponse
24
+
25
25
  Returns aggregated order metrics for given interval, broken down by granularity, for given buyer type.
26
-
27
- **Usage Plan:**
28
-
29
-
30
- ====================================== ==============
31
- Rate (requests per second) Burst
32
- ====================================== ==============
33
- 0.5 15
34
- ====================================== ==============
35
-
36
- For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
37
-
26
+
38
27
  Examples:
39
28
  literal blocks::
40
-
41
- from sp_api.api import Sales
42
- from sp_api.base import Granularity
43
-
44
- Sales().get_order_metrics(interval, Granularity.TOTAL, granularityTimeZone='US/Central')
45
- Sales().get_order_metrics(interval, Granularity.DAY, granularityTimeZone='US/Central')
46
- Sales().get_order_metrics(interval, Granularity.TOTAL, granularityTimeZone='US/Central', asin='B008OLKVEW')
47
- Sales().get_order_metrics(interval, Granularity.DAY, granularityTimeZone='US/Central', asin='B008OLKVEW')
48
-
49
-
29
+
30
+ Sales().get_order_metrics("value", "value", "value")
31
+
50
32
  Args:
51
- key marketplaceIds: [str]
52
- interval: tuple | A time interval used for selecting order metrics. This takes the form of two dates separated by two hyphens (first date is inclusive; second date is exclusive). Dates are in ISO8601 format and must represent absolute time (either Z notation or offset notation). Example: 2018-09-01T00:00:00-07:00--2018-09-04T00:00:00-07:00 requests order metrics for Sept 1st, 2nd and 3rd in the -07:00 zone. string - Query granularityTimeZone
53
- granularity: Granularity | The granularity of the grouping of order metrics, based on a unit of time. Specifying granularity=Hour results in a successful request only if the interval specified is less than or equal to 30 days from now. For all other granularities, the interval specified must be less or equal to 2 years from now. Specifying granularity=Total results in order metrics that are aggregated over the entire interval that you specify. If the interval start and end date don’t align with the specified granularity, the head and tail end of the response interval will contain partial data. Example: Day to get a daily breakdown of the request interval, where the day boundary is defined by the granularityTimeZone. enum (Granularity) -
54
- key buyerType: BuyerType | Filters the results by the buyer type that you specify, B2B (business to business) or B2C (business to customer). Example: B2B, if you want the response to include order metrics for only B2B buyers. Default: enum (BuyerType) "All"
55
- key fulfillmentNetwork: str | Filters the results by the fulfillment network that you specify, MFN (merchant fulfillment network) or AFN (Amazon fulfillment network). Do not include this filter if you want the response to include order metrics for all fulfillment networks. Example: AFN, if you want the response to include order metrics for only Amazon fulfillment network. string -
56
- key firstDayOfWeek: str | Specifies the day that the week starts on when granularity=Week, either Monday or Sunday. Default: Monday. Example: Sunday, if you want the week to start on a Sunday. enum (FirstDayOfWeek) "Monday"
57
- key asin: str | Filters the results by the ASIN that you specify. Specifying both ASIN and SKU returns an error. Do not include this filter if you want the response to include order metrics for all ASINs. Example: B0792R1RSN, if you want the response to include order metrics for only ASIN B0792R1RSN. string -
58
- key sku: str | Filters the results by the SKU that you specify. Specifying both ASIN and SKU returns an error. Do not include this filter if you want the response to include order metrics for all SKUs. Example: TestSKU, if you want the response to include order metrics for only SKU TestSKU.
59
- granularityTimeZone: str
60
-
61
-
33
+ interval: | required
34
+ granularity: | required
35
+ granularityTimeZone: | required
36
+ **kwargs:
37
+
62
38
  Returns:
63
39
  ApiResponse
64
40
  """
@@ -78,13 +54,20 @@ class Sales(Client):
78
54
  @staticmethod
79
55
  def _create_datetime_stamp(datetime_obj: datetime or str):
80
56
  """
57
+ _create_datetime_stamp(datetime_obj) -> ApiResponse
58
+
81
59
  Create datetimestring
82
-
60
+
61
+ Examples:
62
+ literal blocks::
63
+
64
+ Sales()._create_datetime_stamp("value")
65
+
83
66
  Args:
84
- datetime_obj:
85
-
67
+ datetime_obj: | required
68
+
86
69
  Returns:
87
-
70
+ ApiResponse
88
71
  """
89
72
  if isinstance(datetime_obj, str):
90
73
  return datetime_obj
File without changes
@@ -0,0 +1,92 @@
1
+ from __future__ import annotations
2
+
3
+ import enum
4
+ from typing import Any, Literal, TYPE_CHECKING, overload
5
+ from sp_api.util.versioned_client import VersionedClientMeta
6
+
7
+ from sp_api.base import Client
8
+
9
+ from .seller_wallet_2024_03_01 import SellerWalletV20240301
10
+
11
+
12
+ class SellerWalletVersion(str, enum.Enum):
13
+ V_2024_03_01 = "2024-03-01"
14
+ LATEST = "2024-03-01"
15
+
16
+
17
+ if TYPE_CHECKING:
18
+
19
+ class _SellerWalletMeta(VersionedClientMeta):
20
+ @overload
21
+ def __call__(
22
+ cls,
23
+ *args: Any,
24
+ version: Literal[SellerWalletVersion.V_2024_03_01, SellerWalletVersion.LATEST, "2024-03-01"],
25
+ **kwargs: Any,
26
+ ) -> SellerWalletV20240301: ...
27
+
28
+ @overload
29
+ def __call__(
30
+ cls,
31
+ *args: Any,
32
+ version: None = None,
33
+ **kwargs: Any,
34
+ ) -> SellerWalletV20240301: ...
35
+
36
+ @overload
37
+ def __call__(
38
+ cls,
39
+ *args: Any,
40
+ version: str | SellerWalletVersion,
41
+ **kwargs: Any,
42
+ ) -> Client: ...
43
+
44
+
45
+ else:
46
+ _SellerWalletMeta = VersionedClientMeta
47
+
48
+
49
+ class SellerWallet(Client, metaclass=_SellerWalletMeta):
50
+ """SellerWallet API client.
51
+
52
+ This class dispatches to a versioned SellerWallet API client.
53
+
54
+ If you do not pass a version, the constructor returns the oldest supported implementation ("2024-03-01").
55
+ """
56
+
57
+ if TYPE_CHECKING:
58
+ @overload
59
+ def __new__(
60
+ cls,
61
+ *args: Any,
62
+ version: Literal[SellerWalletVersion.V_2024_03_01, SellerWalletVersion.LATEST, "2024-03-01"],
63
+ **kwargs: Any,
64
+ ) -> SellerWalletV20240301: ...
65
+
66
+ @overload
67
+ def __new__(
68
+ cls,
69
+ *args: Any,
70
+ version: None = None,
71
+ **kwargs: Any,
72
+ ) -> SellerWalletV20240301: ...
73
+
74
+ @overload
75
+ def __new__(
76
+ cls,
77
+ *args: Any,
78
+ version: str | SellerWalletVersion,
79
+ **kwargs: Any,
80
+ ) -> Client: ...
81
+
82
+ _DISPATCH = True
83
+
84
+ _DEFAULT_VERSION = "2024-03-01"
85
+
86
+ _VERSION_MAP = {
87
+ "2024-03-01": SellerWalletV20240301,
88
+ }
89
+
90
+ _VERSION_ALIASES = {
91
+ "2024-03-01": "2024-03-01",
92
+ }