python-amazon-sp-api 1.9.18__py3-none-any.whl → 2.0.7__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.
- {python_amazon_sp_api-1.9.18.data → python_amazon_sp_api-2.0.7.data}/scripts/make_endpoint +2 -2
- {python_amazon_sp_api-1.9.18.dist-info → python_amazon_sp_api-2.0.7.dist-info}/METADATA +46 -23
- python_amazon_sp_api-2.0.7.dist-info/RECORD +251 -0
- {python_amazon_sp_api-1.9.18.dist-info → python_amazon_sp_api-2.0.7.dist-info}/WHEEL +1 -1
- {python_amazon_sp_api-1.9.18.dist-info → python_amazon_sp_api-2.0.7.dist-info}/top_level.txt +0 -1
- sp_api/__version__.py +1 -1
- sp_api/api/__init__.py +18 -1
- sp_api/api/application_integrations/application_integrations.py +118 -0
- sp_api/api/application_management/application_management.py +2 -1
- sp_api/api/catalog/catalog.py +3 -4
- sp_api/api/catalog_items/catalog_items.py +3 -6
- sp_api/api/customer_feedback/customer_feedback.py +110 -0
- sp_api/api/data_kiosk/data_kiosk.py +5 -6
- sp_api/api/easy_ship/easy_ship.py +190 -0
- sp_api/api/external_fulfillment/external_fulfillment.py +706 -0
- sp_api/api/feeds/feeds.py +11 -8
- sp_api/api/finances/finances.py +30 -4
- sp_api/api/fulfillment_inbound/fulfillment_inbound.py +35 -2
- sp_api/api/inventories/inventories.py +2 -7
- sp_api/api/listings_items/listings_items.py +3 -24
- sp_api/api/messaging/messaging.py +42 -0
- sp_api/api/orders/orders.py +7 -0
- sp_api/api/product_fees/product_fees.py +31 -74
- sp_api/api/products/products.py +80 -2
- sp_api/api/products/products_definitions.py +11 -85
- sp_api/api/reports/reports.py +65 -97
- sp_api/api/sales/sales.py +2 -2
- sp_api/asyncio/api/__init__.py +164 -0
- sp_api/asyncio/api/amazon_warehousing_and_distribu/__init__.py +9 -0
- sp_api/asyncio/api/amazon_warehousing_and_distribu/amazon_warehousing_and_distribu.py +130 -0
- sp_api/asyncio/api/aplus_content/__init__.py +5 -0
- sp_api/asyncio/api/aplus_content/aplus_content.py +330 -0
- sp_api/asyncio/api/application_integrations/__init__.py +5 -0
- sp_api/asyncio/api/application_integrations/application_integrations.py +119 -0
- sp_api/asyncio/api/application_management/__init__.py +5 -0
- sp_api/asyncio/api/application_management/application_management.py +36 -0
- sp_api/asyncio/api/authorization/__init__.py +5 -0
- sp_api/asyncio/api/authorization/authorization.py +54 -0
- sp_api/asyncio/api/catalog/__init__.py +5 -0
- sp_api/asyncio/api/catalog/catalog.py +111 -0
- sp_api/asyncio/api/catalog_items/__init__.py +6 -0
- sp_api/asyncio/api/catalog_items/catalog_items.py +93 -0
- sp_api/asyncio/api/clients/__init__.py +1 -0
- sp_api/asyncio/api/customer_feedback/__init__.py +5 -0
- sp_api/asyncio/api/customer_feedback/customer_feedback.py +111 -0
- sp_api/asyncio/api/data_kiosk/__init__.py +5 -0
- sp_api/asyncio/api/data_kiosk/data_kiosk.py +236 -0
- sp_api/asyncio/api/easy_ship/__init__.py +5 -0
- sp_api/asyncio/api/easy_ship/easy_ship.py +191 -0
- sp_api/asyncio/api/external_fulfillment/__init__.py +5 -0
- sp_api/asyncio/api/external_fulfillment/external_fulfillment.py +706 -0
- sp_api/asyncio/api/fba_inbound_eligibility/__init__.py +5 -0
- sp_api/asyncio/api/fba_inbound_eligibility/fba_inbound_eligibility.py +96 -0
- sp_api/asyncio/api/fba_small_and_light/__init__.py +5 -0
- sp_api/asyncio/api/fba_small_and_light/fba_small_and_light.py +213 -0
- sp_api/asyncio/api/feeds/feeds.py +260 -0
- sp_api/asyncio/api/finances/finances.py +100 -0
- sp_api/asyncio/api/fulfillment_inbound/fulfillment_inbound.py +1798 -0
- sp_api/asyncio/api/fulfillment_outbound/fulfillment_outbound.py +736 -0
- sp_api/asyncio/api/inventories/inventories.py +74 -0
- sp_api/asyncio/api/listings_items/__init__.py +0 -0
- sp_api/asyncio/api/listings_items/listings_items.py +170 -0
- sp_api/asyncio/api/listings_restrictions/__init__.py +0 -0
- sp_api/asyncio/api/listings_restrictions/listings_restrictions.py +36 -0
- sp_api/asyncio/api/merchant_fulfillment/__init__.py +0 -0
- sp_api/asyncio/api/merchant_fulfillment/merchant_fulfillment.py +384 -0
- sp_api/asyncio/api/messaging/__init__.py +0 -0
- sp_api/asyncio/api/messaging/messaging.py +511 -0
- sp_api/asyncio/api/models/__init__.py +4 -0
- sp_api/asyncio/api/notifications/__init__.py +0 -0
- sp_api/asyncio/api/notifications/notifications.py +295 -0
- sp_api/asyncio/api/orders/__init__.py +0 -0
- sp_api/asyncio/api/orders/orders.py +362 -0
- sp_api/asyncio/api/overrides/__init__.py +1 -0
- sp_api/asyncio/api/product_fees/__init__.py +0 -0
- sp_api/asyncio/api/product_fees/product_fees.py +194 -0
- sp_api/asyncio/api/product_type_definitions/__init__.py +0 -0
- sp_api/asyncio/api/product_type_definitions/product_type_definitions.py +75 -0
- sp_api/asyncio/api/products/__init__.py +0 -0
- sp_api/asyncio/api/products/products.py +405 -0
- sp_api/asyncio/api/products/products_definitions.py +11 -0
- sp_api/asyncio/api/replenishment/__init__.py +0 -0
- sp_api/asyncio/api/replenishment/replenishment.py +121 -0
- sp_api/asyncio/api/reports/__init__.py +0 -0
- sp_api/asyncio/api/reports/reports.py +439 -0
- sp_api/asyncio/api/sales/__init__.py +0 -0
- sp_api/asyncio/api/sales/sales.py +93 -0
- sp_api/asyncio/api/sellers/__init__.py +0 -0
- sp_api/asyncio/api/sellers/sellers.py +70 -0
- sp_api/asyncio/api/services/__init__.py +0 -0
- sp_api/asyncio/api/services/services.py +218 -0
- sp_api/asyncio/api/shipping/__init__.py +0 -0
- sp_api/asyncio/api/shipping/shipping.py +459 -0
- sp_api/asyncio/api/shipping/shippingV2.py +651 -0
- sp_api/asyncio/api/solicitations/__init__.py +0 -0
- sp_api/asyncio/api/solicitations/solicitations.py +78 -0
- sp_api/asyncio/api/supply_sources/__init__.py +0 -0
- sp_api/asyncio/api/supply_sources/supply_sources.py +138 -0
- sp_api/asyncio/api/tokens/__init__.py +0 -0
- sp_api/asyncio/api/tokens/tokens.py +65 -0
- sp_api/asyncio/api/upload/__init__.py +0 -0
- sp_api/asyncio/api/upload/upload.py +18 -0
- sp_api/asyncio/api/vendor_direct_fulfillment_inventory/__init__.py +0 -0
- sp_api/asyncio/api/vendor_direct_fulfillment_inventory/vendor_direct_fulfillment_inventory.py +64 -0
- sp_api/asyncio/api/vendor_direct_fulfillment_orders/__init__.py +0 -0
- sp_api/asyncio/api/vendor_direct_fulfillment_orders/vendor_direct_fulfillment_orders.py +196 -0
- sp_api/asyncio/api/vendor_direct_fulfillment_payments/__init__.py +0 -0
- sp_api/asyncio/api/vendor_direct_fulfillment_payments/vendor_direct_fulfillment_payments.py +254 -0
- sp_api/asyncio/api/vendor_direct_fulfillment_shipping/__init__.py +0 -0
- sp_api/asyncio/api/vendor_direct_fulfillment_shipping/vendor_direct_fulfillment_shipping.py +627 -0
- sp_api/asyncio/api/vendor_direct_fulfillment_transactions/__init__.py +0 -0
- sp_api/asyncio/api/vendor_direct_fulfillment_transactions/vendor_direct_fulfillment_transactions.py +43 -0
- sp_api/asyncio/api/vendor_invoices/__init__.py +0 -0
- sp_api/asyncio/api/vendor_invoices/vendor_invoices.py +295 -0
- sp_api/asyncio/api/vendor_orders/__init__.py +0 -0
- sp_api/asyncio/api/vendor_orders/vendor_orders.py +210 -0
- sp_api/asyncio/api/vendor_shipments/__init__.py +0 -0
- sp_api/asyncio/api/vendor_shipments/vendor_shipments.py +118 -0
- sp_api/asyncio/api/vendor_transaction_status/__init__.py +0 -0
- sp_api/asyncio/api/vendor_transaction_status/vendor_transaction_status.py +41 -0
- sp_api/asyncio/auth/__init__.py +12 -0
- sp_api/asyncio/auth/access_token_client.py +145 -0
- sp_api/asyncio/auth/exceptions.py +5 -0
- sp_api/asyncio/base/__init__.py +53 -0
- sp_api/asyncio/base/_transport_httpx.py +50 -0
- sp_api/asyncio/base/base_client.py +8 -0
- sp_api/asyncio/base/client.py +169 -0
- sp_api/asyncio/util/__init__.py +29 -0
- sp_api/asyncio/util/key_maker.py +5 -0
- sp_api/asyncio/util/load_all_pages.py +55 -0
- sp_api/asyncio/util/load_date_bound.py +53 -0
- sp_api/asyncio/util/retry.py +88 -0
- sp_api/auth/_core.py +39 -0
- sp_api/auth/access_token_client.py +18 -29
- sp_api/base/ApiResponse.py +3 -2
- sp_api/base/_core.py +110 -0
- sp_api/base/_transport_httpx.py +39 -0
- sp_api/base/client.py +40 -63
- sp_api/base/helpers.py +1 -1
- sp_api/base/reportTypes.py +3 -2
- sp_api/util/__init__.py +36 -0
- sp_api/util/load_all_pages.py +2 -1
- sp_api/util/params.py +57 -0
- sp_api/util/product_fees.py +40 -0
- sp_api/util/products_definitions.py +169 -0
- sp_api/util/report_document.py +154 -0
- python_amazon_sp_api-1.9.18.dist-info/RECORD +0 -144
- tests/api/finances/test_finances.py +0 -19
- tests/api/notifications/test_notifications.py +0 -26
- tests/api/orders/test_orders.py +0 -122
- tests/api/product_fees/product_fees.py +0 -49
- tests/api/reports/test_reports.py +0 -127
- tests/client/test_auth.py +0 -59
- tests/client/test_base.py +0 -163
- tests/client/test_credential_provider.py +0 -45
- tests/client/test_helpers.py +0 -142
- {python_amazon_sp_api-1.9.18.dist-info → python_amazon_sp_api-2.0.7.dist-info/licenses}/LICENSE +0 -0
- {tests → sp_api/api/application_integrations}/__init__.py +0 -0
- {tests/api → sp_api/api/customer_feedback}/__init__.py +0 -0
- {tests/api/finances → sp_api/api/easy_ship}/__init__.py +0 -0
- {tests/api/notifications → sp_api/api/external_fulfillment}/__init__.py +0 -0
- {tests/api/orders → sp_api/asyncio}/__init__.py +0 -0
- {tests/api/product_fees → sp_api/asyncio/api/feeds}/__init__.py +0 -0
- {tests/api/reports → sp_api/asyncio/api/finances}/__init__.py +0 -0
- {tests/api/sellers → sp_api/asyncio/api/fulfillment_inbound}/__init__.py +0 -0
- {tests/client → sp_api/asyncio/api/fulfillment_outbound}/__init__.py +0 -0
- /tests/api/sellers/test_sellers.py → /sp_api/asyncio/api/inventories/__init__.py +0 -0
|
@@ -0,0 +1,627 @@
|
|
|
1
|
+
import urllib.parse
|
|
2
|
+
|
|
3
|
+
from sp_api.base import Client, sp_endpoint, fill_query_params, ApiResponse
|
|
4
|
+
from sp_api.asyncio.base import AsyncBaseClient
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
class VendorDirectFulfillmentShipping(AsyncBaseClient):
|
|
8
|
+
"""
|
|
9
|
+
VendorDirectFulfillmentShipping SP-API Client
|
|
10
|
+
:link:
|
|
11
|
+
|
|
12
|
+
The Selling Partner API for Direct Fulfillment Shipping provides programmatic access to a direct fulfillment vendor's shipping data.
|
|
13
|
+
"""
|
|
14
|
+
|
|
15
|
+
@sp_endpoint("/vendor/directFulfillment/shipping/v1/shippingLabels", method="GET")
|
|
16
|
+
async def get_shipping_labels(self, **kwargs) -> ApiResponse:
|
|
17
|
+
"""
|
|
18
|
+
get_shipping_labels(self, **kwargs) -> ApiResponse
|
|
19
|
+
|
|
20
|
+
Returns a list of shipping labels created during the time frame that you specify. You define that time frame using the createdAfter and createdBefore parameters. You must use both of these parameters. The date range to search must not be more than 7 days.
|
|
21
|
+
|
|
22
|
+
**Usage Plans:**
|
|
23
|
+
|
|
24
|
+
====================================== ==============
|
|
25
|
+
Rate (requests per second) Burst
|
|
26
|
+
====================================== ==============
|
|
27
|
+
10 10
|
|
28
|
+
====================================== ==============
|
|
29
|
+
|
|
30
|
+
The x-amzn-RateLimit-Limit response header returns the usage plan rate limits that were applied to the requested operation. Rate limits for some selling partners will vary from the default rate and burst shown in the table above. For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
|
|
31
|
+
|
|
32
|
+
Args:
|
|
33
|
+
key shipFromPartyId:string | The vendor warehouseId for order fulfillment. If not specified, the result will contain orders for all warehouses.
|
|
34
|
+
key limit:integer | The limit to the number of records returned.
|
|
35
|
+
key createdAfter:string | * REQUIRED Shipping labels that became available after this date and time will be included in the result. Must be in ISO-8601 date/time format.
|
|
36
|
+
key createdBefore:string | * REQUIRED Shipping labels that became available before this date and time will be included in the result. Must be in ISO-8601 date/time format.
|
|
37
|
+
key sortOrder:string | Sort ASC or DESC by order creation date.
|
|
38
|
+
key nextToken:string | Used for pagination when there are more ship labels than the specified result size limit. The token value is returned in the previous API call.
|
|
39
|
+
|
|
40
|
+
Returns:
|
|
41
|
+
ApiResponse:
|
|
42
|
+
"""
|
|
43
|
+
|
|
44
|
+
return await self._request(kwargs.pop("path"), params=kwargs)
|
|
45
|
+
|
|
46
|
+
@sp_endpoint("/vendor/directFulfillment/shipping/v1/shippingLabels", method="POST")
|
|
47
|
+
async def submit_shipping_label_request(self, **kwargs) -> ApiResponse:
|
|
48
|
+
"""
|
|
49
|
+
submit_shipping_label_request(self, **kwargs) -> ApiResponse
|
|
50
|
+
|
|
51
|
+
Creates a shipping label for a purchase order and returns a transactionId for reference.
|
|
52
|
+
|
|
53
|
+
**Usage Plans:**
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
====================================== ==============
|
|
57
|
+
Rate (requests per second) Burst
|
|
58
|
+
====================================== ==============
|
|
59
|
+
10 10
|
|
60
|
+
====================================== ==============
|
|
61
|
+
|
|
62
|
+
The x-amzn-RateLimit-Limit response header returns the usage plan rate limits that were applied to the requested operation. Rate limits for some selling partners will vary from the default rate and burst shown in the table above. For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
|
|
63
|
+
|
|
64
|
+
Args:
|
|
65
|
+
body: {
|
|
66
|
+
"shippingLabelRequests": [
|
|
67
|
+
{
|
|
68
|
+
"purchaseOrderNumber": "string",
|
|
69
|
+
"sellingParty": {
|
|
70
|
+
"partyId": "string",
|
|
71
|
+
"address": {
|
|
72
|
+
"name": "string",
|
|
73
|
+
"addressLine1": "string",
|
|
74
|
+
"addressLine2": "string",
|
|
75
|
+
"addressLine3": "string",
|
|
76
|
+
"city": "string",
|
|
77
|
+
"county": "string",
|
|
78
|
+
"district": "string",
|
|
79
|
+
"stateOrRegion": "string",
|
|
80
|
+
"postalCode": "string",
|
|
81
|
+
"countryCode": "string",
|
|
82
|
+
"phone": "string"
|
|
83
|
+
},
|
|
84
|
+
"taxRegistrationDetails": [
|
|
85
|
+
{
|
|
86
|
+
"taxRegistrationType": "VAT",
|
|
87
|
+
"taxRegistrationNumber": "string",
|
|
88
|
+
"taxRegistrationAddress": {
|
|
89
|
+
"name": "string",
|
|
90
|
+
"addressLine1": "string",
|
|
91
|
+
"addressLine2": "string",
|
|
92
|
+
"addressLine3": "string",
|
|
93
|
+
"city": "string",
|
|
94
|
+
"county": "string",
|
|
95
|
+
"district": "string",
|
|
96
|
+
"stateOrRegion": "string",
|
|
97
|
+
"postalCode": "string",
|
|
98
|
+
"countryCode": "string",
|
|
99
|
+
"phone": "string"
|
|
100
|
+
},
|
|
101
|
+
"taxRegistrationMessages": "string"
|
|
102
|
+
}
|
|
103
|
+
]
|
|
104
|
+
},
|
|
105
|
+
"shipFromParty": {
|
|
106
|
+
"partyId": "string",
|
|
107
|
+
"address": {
|
|
108
|
+
"name": "string",
|
|
109
|
+
"addressLine1": "string",
|
|
110
|
+
"addressLine2": "string",
|
|
111
|
+
"addressLine3": "string",
|
|
112
|
+
"city": "string",
|
|
113
|
+
"county": "string",
|
|
114
|
+
"district": "string",
|
|
115
|
+
"stateOrRegion": "string",
|
|
116
|
+
"postalCode": "string",
|
|
117
|
+
"countryCode": "string",
|
|
118
|
+
"phone": "string"
|
|
119
|
+
},
|
|
120
|
+
"taxRegistrationDetails": [
|
|
121
|
+
{
|
|
122
|
+
"taxRegistrationType": "VAT",
|
|
123
|
+
"taxRegistrationNumber": "string",
|
|
124
|
+
"taxRegistrationAddress": {
|
|
125
|
+
"name": "string",
|
|
126
|
+
"addressLine1": "string",
|
|
127
|
+
"addressLine2": "string",
|
|
128
|
+
"addressLine3": "string",
|
|
129
|
+
"city": "string",
|
|
130
|
+
"county": "string",
|
|
131
|
+
"district": "string",
|
|
132
|
+
"stateOrRegion": "string",
|
|
133
|
+
"postalCode": "string",
|
|
134
|
+
"countryCode": "string",
|
|
135
|
+
"phone": "string"
|
|
136
|
+
},
|
|
137
|
+
"taxRegistrationMessages": "string"
|
|
138
|
+
}
|
|
139
|
+
]
|
|
140
|
+
},
|
|
141
|
+
"containers": [
|
|
142
|
+
{
|
|
143
|
+
"containerType": "carton",
|
|
144
|
+
"containerIdentifier": "string",
|
|
145
|
+
"trackingNumber": "string",
|
|
146
|
+
"manifestId": "string",
|
|
147
|
+
"manifestDate": "string",
|
|
148
|
+
"shipMethod": "string",
|
|
149
|
+
"scacCode": "string",
|
|
150
|
+
"carrier": "string",
|
|
151
|
+
"containerSequenceNumber": 0,
|
|
152
|
+
"dimensions": {
|
|
153
|
+
"length": "string",
|
|
154
|
+
"width": "string",
|
|
155
|
+
"height": "string",
|
|
156
|
+
"unitOfMeasure": "IN"
|
|
157
|
+
},
|
|
158
|
+
"weight": {
|
|
159
|
+
"unitOfMeasure": "KG",
|
|
160
|
+
"value": "string"
|
|
161
|
+
},
|
|
162
|
+
"packedItems": [
|
|
163
|
+
{
|
|
164
|
+
"itemSequenceNumber": 0,
|
|
165
|
+
"buyerProductIdentifier": "string",
|
|
166
|
+
"vendorProductIdentifier": "string",
|
|
167
|
+
"packedQuantity": {
|
|
168
|
+
"amount": 0,
|
|
169
|
+
"unitOfMeasure": "string"
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
]
|
|
173
|
+
}
|
|
174
|
+
]
|
|
175
|
+
}
|
|
176
|
+
]
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
Returns:
|
|
180
|
+
ApiResponse:
|
|
181
|
+
"""
|
|
182
|
+
|
|
183
|
+
return await self._request(kwargs.pop("path"), data=kwargs, add_marketplace=False)
|
|
184
|
+
|
|
185
|
+
@sp_endpoint(
|
|
186
|
+
"/vendor/directFulfillment/shipping/v1/shippingLabels/{}", method="GET"
|
|
187
|
+
)
|
|
188
|
+
async def get_shipping_label(self, purchaseOrderNumber, **kwargs) -> ApiResponse:
|
|
189
|
+
"""
|
|
190
|
+
get_shipping_label(self, purchaseOrderNumber, **kwargs) -> ApiResponse
|
|
191
|
+
|
|
192
|
+
Returns a shipping label for the purchaseOrderNumber that you specify.
|
|
193
|
+
|
|
194
|
+
**Usage Plans:**
|
|
195
|
+
|
|
196
|
+
|
|
197
|
+
====================================== ==============
|
|
198
|
+
Rate (requests per second) Burst
|
|
199
|
+
====================================== ==============
|
|
200
|
+
10 10
|
|
201
|
+
====================================== ==============
|
|
202
|
+
|
|
203
|
+
The x-amzn-RateLimit-Limit response header returns the usage plan rate limits that were applied to the requested operation. Rate limits for some selling partners will vary from the default rate and burst shown in the table above. For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
|
|
204
|
+
|
|
205
|
+
Args:
|
|
206
|
+
purchaseOrderNumber:string | * REQUIRED The purchase order number for which you want to return the shipping label. It should be the same purchaseOrderNumber as received in the order.
|
|
207
|
+
|
|
208
|
+
Returns:
|
|
209
|
+
ApiResponse:
|
|
210
|
+
"""
|
|
211
|
+
|
|
212
|
+
return await self._request(
|
|
213
|
+
fill_query_params(kwargs.pop("path"), purchaseOrderNumber), params=kwargs
|
|
214
|
+
)
|
|
215
|
+
|
|
216
|
+
@sp_endpoint(
|
|
217
|
+
"/vendor/directFulfillment/shipping/v1/shipmentConfirmations", method="POST"
|
|
218
|
+
)
|
|
219
|
+
async def submit_shipment_confirmations(self, **kwargs) -> ApiResponse:
|
|
220
|
+
"""
|
|
221
|
+
submit_shipment_confirmations(self, **kwargs) -> ApiResponse
|
|
222
|
+
|
|
223
|
+
Submits one or more shipment confirmations for vendor orders.
|
|
224
|
+
|
|
225
|
+
**Usage Plans:**
|
|
226
|
+
|
|
227
|
+
|
|
228
|
+
====================================== ==============
|
|
229
|
+
Rate (requests per second) Burst
|
|
230
|
+
====================================== ==============
|
|
231
|
+
10 10
|
|
232
|
+
====================================== ==============
|
|
233
|
+
|
|
234
|
+
The x-amzn-RateLimit-Limit response header returns the usage plan rate limits that were applied to the requested operation. Rate limits for some selling partners will vary from the default rate and burst shown in the table above. For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
|
|
235
|
+
|
|
236
|
+
Args:
|
|
237
|
+
body: {
|
|
238
|
+
"shipmentConfirmations": [
|
|
239
|
+
{
|
|
240
|
+
"purchaseOrderNumber": "string",
|
|
241
|
+
"shipmentDetails": {
|
|
242
|
+
"shippedDate": "2019-08-24T14:15:22Z",
|
|
243
|
+
"shipmentStatus": "SHIPPED",
|
|
244
|
+
"isPriorityShipment": true,
|
|
245
|
+
"vendorOrderNumber": "string",
|
|
246
|
+
"estimatedDeliveryDate": "2019-08-24T14:15:22Z"
|
|
247
|
+
},
|
|
248
|
+
"sellingParty": {
|
|
249
|
+
"partyId": "string",
|
|
250
|
+
"address": {
|
|
251
|
+
"name": "string",
|
|
252
|
+
"addressLine1": "string",
|
|
253
|
+
"addressLine2": "string",
|
|
254
|
+
"addressLine3": "string",
|
|
255
|
+
"city": "string",
|
|
256
|
+
"county": "string",
|
|
257
|
+
"district": "string",
|
|
258
|
+
"stateOrRegion": "string",
|
|
259
|
+
"postalCode": "string",
|
|
260
|
+
"countryCode": "string",
|
|
261
|
+
"phone": "string"
|
|
262
|
+
},
|
|
263
|
+
"taxRegistrationDetails": [
|
|
264
|
+
{
|
|
265
|
+
"taxRegistrationType": "VAT",
|
|
266
|
+
"taxRegistrationNumber": "string",
|
|
267
|
+
"taxRegistrationAddress": {
|
|
268
|
+
"name": "string",
|
|
269
|
+
"addressLine1": "string",
|
|
270
|
+
"addressLine2": "string",
|
|
271
|
+
"addressLine3": "string",
|
|
272
|
+
"city": "string",
|
|
273
|
+
"county": "string",
|
|
274
|
+
"district": "string",
|
|
275
|
+
"stateOrRegion": "string",
|
|
276
|
+
"postalCode": "string",
|
|
277
|
+
"countryCode": "string",
|
|
278
|
+
"phone": "string"
|
|
279
|
+
},
|
|
280
|
+
"taxRegistrationMessages": "string"
|
|
281
|
+
}
|
|
282
|
+
]
|
|
283
|
+
},
|
|
284
|
+
"shipFromParty": {
|
|
285
|
+
"partyId": "string",
|
|
286
|
+
"address": {
|
|
287
|
+
"name": "string",
|
|
288
|
+
"addressLine1": "string",
|
|
289
|
+
"addressLine2": "string",
|
|
290
|
+
"addressLine3": "string",
|
|
291
|
+
"city": "string",
|
|
292
|
+
"county": "string",
|
|
293
|
+
"district": "string",
|
|
294
|
+
"stateOrRegion": "string",
|
|
295
|
+
"postalCode": "string",
|
|
296
|
+
"countryCode": "string",
|
|
297
|
+
"phone": "string"
|
|
298
|
+
},
|
|
299
|
+
"taxRegistrationDetails": [
|
|
300
|
+
{
|
|
301
|
+
"taxRegistrationType": "VAT",
|
|
302
|
+
"taxRegistrationNumber": "string",
|
|
303
|
+
"taxRegistrationAddress": {
|
|
304
|
+
"name": "string",
|
|
305
|
+
"addressLine1": "string",
|
|
306
|
+
"addressLine2": "string",
|
|
307
|
+
"addressLine3": "string",
|
|
308
|
+
"city": "string",
|
|
309
|
+
"county": "string",
|
|
310
|
+
"district": "string",
|
|
311
|
+
"stateOrRegion": "string",
|
|
312
|
+
"postalCode": "string",
|
|
313
|
+
"countryCode": "string",
|
|
314
|
+
"phone": "string"
|
|
315
|
+
},
|
|
316
|
+
"taxRegistrationMessages": "string"
|
|
317
|
+
}
|
|
318
|
+
]
|
|
319
|
+
},
|
|
320
|
+
"items": [
|
|
321
|
+
{
|
|
322
|
+
"itemSequenceNumber": 0,
|
|
323
|
+
"buyerProductIdentifier": "string",
|
|
324
|
+
"vendorProductIdentifier": "string",
|
|
325
|
+
"shippedQuantity": {
|
|
326
|
+
"amount": 0,
|
|
327
|
+
"unitOfMeasure": "string"
|
|
328
|
+
}
|
|
329
|
+
}
|
|
330
|
+
],
|
|
331
|
+
"containers": [
|
|
332
|
+
{
|
|
333
|
+
"containerType": "carton",
|
|
334
|
+
"containerIdentifier": "string",
|
|
335
|
+
"trackingNumber": "string",
|
|
336
|
+
"manifestId": "string",
|
|
337
|
+
"manifestDate": "string",
|
|
338
|
+
"shipMethod": "string",
|
|
339
|
+
"scacCode": "string",
|
|
340
|
+
"carrier": "string",
|
|
341
|
+
"containerSequenceNumber": 0,
|
|
342
|
+
"dimensions": {
|
|
343
|
+
"length": "string",
|
|
344
|
+
"width": "string",
|
|
345
|
+
"height": "string",
|
|
346
|
+
"unitOfMeasure": "IN"
|
|
347
|
+
},
|
|
348
|
+
"weight": {
|
|
349
|
+
"unitOfMeasure": "KG",
|
|
350
|
+
"value": "string"
|
|
351
|
+
},
|
|
352
|
+
"packedItems": [
|
|
353
|
+
{
|
|
354
|
+
"itemSequenceNumber": 0,
|
|
355
|
+
"buyerProductIdentifier": "string",
|
|
356
|
+
"vendorProductIdentifier": "string",
|
|
357
|
+
"packedQuantity": {
|
|
358
|
+
"amount": 0,
|
|
359
|
+
"unitOfMeasure": "string"
|
|
360
|
+
}
|
|
361
|
+
}
|
|
362
|
+
]
|
|
363
|
+
}
|
|
364
|
+
]
|
|
365
|
+
}
|
|
366
|
+
]
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
Returns:
|
|
370
|
+
ApiResponse:
|
|
371
|
+
"""
|
|
372
|
+
|
|
373
|
+
return await self._request(kwargs.pop("path"), data=kwargs, add_marketplace=False)
|
|
374
|
+
|
|
375
|
+
@sp_endpoint(
|
|
376
|
+
"/vendor/directFulfillment/shipping/v1/shipmentStatusUpdates", method="POST"
|
|
377
|
+
)
|
|
378
|
+
async def submit_shipment_status_updates(self, **kwargs) -> ApiResponse:
|
|
379
|
+
"""
|
|
380
|
+
submit_shipment_status_updates(self, **kwargs) -> ApiResponse
|
|
381
|
+
|
|
382
|
+
This API call is only to be used by Vendor-Own-Carrier (VOC) vendors. Calling this API will submit a shipment status update for the package that a vendor has shipped. It will provide the Amazon customer visibility on their order, when the package is outside of Amazon Network visibility.
|
|
383
|
+
|
|
384
|
+
**Usage Plans:**
|
|
385
|
+
|
|
386
|
+
====================================== ==============
|
|
387
|
+
Rate (requests per second) Burst
|
|
388
|
+
====================================== ==============
|
|
389
|
+
10 10
|
|
390
|
+
====================================== ==============
|
|
391
|
+
|
|
392
|
+
The x-amzn-RateLimit-Limit response header returns the usage plan rate limits that were applied to the requested operation. Rate limits for some selling partners will vary from the default rate and burst shown in the table above. For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
|
|
393
|
+
|
|
394
|
+
Args:
|
|
395
|
+
body: {
|
|
396
|
+
"shipmentStatusUpdates": [
|
|
397
|
+
{
|
|
398
|
+
"purchaseOrderNumber": "string",
|
|
399
|
+
"sellingParty": {
|
|
400
|
+
"partyId": "string",
|
|
401
|
+
"address": {
|
|
402
|
+
"name": "string",
|
|
403
|
+
"addressLine1": "string",
|
|
404
|
+
"addressLine2": "string",
|
|
405
|
+
"addressLine3": "string",
|
|
406
|
+
"city": "string",
|
|
407
|
+
"county": "string",
|
|
408
|
+
"district": "string",
|
|
409
|
+
"stateOrRegion": "string",
|
|
410
|
+
"postalCode": "string",
|
|
411
|
+
"countryCode": "string",
|
|
412
|
+
"phone": "string"
|
|
413
|
+
},
|
|
414
|
+
"taxRegistrationDetails": [
|
|
415
|
+
{
|
|
416
|
+
"taxRegistrationType": "VAT",
|
|
417
|
+
"taxRegistrationNumber": "string",
|
|
418
|
+
"taxRegistrationAddress": {
|
|
419
|
+
"name": "string",
|
|
420
|
+
"addressLine1": "string",
|
|
421
|
+
"addressLine2": "string",
|
|
422
|
+
"addressLine3": "string",
|
|
423
|
+
"city": "string",
|
|
424
|
+
"county": "string",
|
|
425
|
+
"district": "string",
|
|
426
|
+
"stateOrRegion": "string",
|
|
427
|
+
"postalCode": "string",
|
|
428
|
+
"countryCode": "string",
|
|
429
|
+
"phone": "string"
|
|
430
|
+
},
|
|
431
|
+
"taxRegistrationMessages": "string"
|
|
432
|
+
}
|
|
433
|
+
]
|
|
434
|
+
},
|
|
435
|
+
"shipFromParty": {
|
|
436
|
+
"partyId": "string",
|
|
437
|
+
"address": {
|
|
438
|
+
"name": "string",
|
|
439
|
+
"addressLine1": "string",
|
|
440
|
+
"addressLine2": "string",
|
|
441
|
+
"addressLine3": "string",
|
|
442
|
+
"city": "string",
|
|
443
|
+
"county": "string",
|
|
444
|
+
"district": "string",
|
|
445
|
+
"stateOrRegion": "string",
|
|
446
|
+
"postalCode": "string",
|
|
447
|
+
"countryCode": "string",
|
|
448
|
+
"phone": "string"
|
|
449
|
+
},
|
|
450
|
+
"taxRegistrationDetails": [
|
|
451
|
+
{
|
|
452
|
+
"taxRegistrationType": "VAT",
|
|
453
|
+
"taxRegistrationNumber": "string",
|
|
454
|
+
"taxRegistrationAddress": {
|
|
455
|
+
"name": "string",
|
|
456
|
+
"addressLine1": "string",
|
|
457
|
+
"addressLine2": "string",
|
|
458
|
+
"addressLine3": "string",
|
|
459
|
+
"city": "string",
|
|
460
|
+
"county": "string",
|
|
461
|
+
"district": "string",
|
|
462
|
+
"stateOrRegion": "string",
|
|
463
|
+
"postalCode": "string",
|
|
464
|
+
"countryCode": "string",
|
|
465
|
+
"phone": "string"
|
|
466
|
+
},
|
|
467
|
+
"taxRegistrationMessages": "string"
|
|
468
|
+
}
|
|
469
|
+
]
|
|
470
|
+
},
|
|
471
|
+
"statusUpdateDetails": {
|
|
472
|
+
"trackingNumber": "string",
|
|
473
|
+
"statusCode": "string",
|
|
474
|
+
"reasonCode": "string",
|
|
475
|
+
"statusDateTime": "2019-08-24T14:15:22Z",
|
|
476
|
+
"statusLocationAddress": {
|
|
477
|
+
"name": "string",
|
|
478
|
+
"addressLine1": "string",
|
|
479
|
+
"addressLine2": "string",
|
|
480
|
+
"addressLine3": "string",
|
|
481
|
+
"city": "string",
|
|
482
|
+
"county": "string",
|
|
483
|
+
"district": "string",
|
|
484
|
+
"stateOrRegion": "string",
|
|
485
|
+
"postalCode": "string",
|
|
486
|
+
"countryCode": "string",
|
|
487
|
+
"phone": "string"
|
|
488
|
+
},
|
|
489
|
+
"shipmentSchedule": {
|
|
490
|
+
"estimatedDeliveryDateTime": "2019-08-24T14:15:22Z",
|
|
491
|
+
"apptWindowStartDateTime": "2019-08-24T14:15:22Z",
|
|
492
|
+
"apptWindowEndDateTime": "2019-08-24T14:15:22Z"
|
|
493
|
+
}
|
|
494
|
+
}
|
|
495
|
+
}
|
|
496
|
+
]
|
|
497
|
+
}
|
|
498
|
+
|
|
499
|
+
Returns:
|
|
500
|
+
ApiResponse:
|
|
501
|
+
"""
|
|
502
|
+
|
|
503
|
+
return await self._request(kwargs.pop("path"), data=kwargs)
|
|
504
|
+
|
|
505
|
+
@sp_endpoint("/vendor/directFulfillment/shipping/v1/customerInvoices", method="GET")
|
|
506
|
+
async def get_customer_invoices(self, **kwargs) -> ApiResponse:
|
|
507
|
+
"""
|
|
508
|
+
get_customer_invoices(self, **kwargs) -> ApiResponse
|
|
509
|
+
|
|
510
|
+
Returns a list of customer invoices created during a time frame that you specify. You define the time frame using the createdAfter and createdBefore parameters. You must use both of these parameters. The date range to search must be no more than 7 days.
|
|
511
|
+
|
|
512
|
+
**Usage Plans:**
|
|
513
|
+
|
|
514
|
+
|
|
515
|
+
====================================== ==============
|
|
516
|
+
Rate (requests per second) Burst
|
|
517
|
+
====================================== ==============
|
|
518
|
+
10 10
|
|
519
|
+
====================================== ==============
|
|
520
|
+
|
|
521
|
+
The x-amzn-RateLimit-Limit response header returns the usage plan rate limits that were applied to the requested operation. Rate limits for some selling partners will vary from the default rate and burst shown in the table above. For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
|
|
522
|
+
|
|
523
|
+
Args:
|
|
524
|
+
key shipFromPartyId:string | The vendor warehouseId for order fulfillment. If not specified, the result will contain orders for all warehouses.
|
|
525
|
+
key limit:integer | The limit to the number of records returned
|
|
526
|
+
key createdAfter:string | * REQUIRED Orders that became available after this date and time will be included in the result. Must be in ISO-8601 date/time format.
|
|
527
|
+
key createdBefore:string | * REQUIRED Orders that became available before this date and time will be included in the result. Must be in ISO-8601 date/time format.
|
|
528
|
+
key sortOrder:string | Sort ASC or DESC by order creation date.
|
|
529
|
+
key nextToken:string | Used for pagination when there are more orders than the specified result size limit. The token value is returned in the previous API call.
|
|
530
|
+
|
|
531
|
+
Returns:
|
|
532
|
+
ApiResponse:
|
|
533
|
+
"""
|
|
534
|
+
|
|
535
|
+
return await self._request(kwargs.pop("path"), params=kwargs)
|
|
536
|
+
|
|
537
|
+
@sp_endpoint(
|
|
538
|
+
"/vendor/directFulfillment/shipping/v1/customerInvoices/{}", method="GET"
|
|
539
|
+
)
|
|
540
|
+
async def get_customer_invoice(self, purchaseOrderNumber, **kwargs) -> ApiResponse:
|
|
541
|
+
"""
|
|
542
|
+
get_customer_invoice(self, purchaseOrderNumber, **kwargs) -> ApiResponse
|
|
543
|
+
|
|
544
|
+
Returns a customer invoice based on the purchaseOrderNumber that you specify.
|
|
545
|
+
|
|
546
|
+
**Usage Plans:**
|
|
547
|
+
|
|
548
|
+
|
|
549
|
+
====================================== ==============
|
|
550
|
+
Rate (requests per second) Burst
|
|
551
|
+
====================================== ==============
|
|
552
|
+
10 10
|
|
553
|
+
====================================== ==============
|
|
554
|
+
|
|
555
|
+
The x-amzn-RateLimit-Limit response header returns the usage plan rate limits that were applied to the requested operation. Rate limits for some selling partners will vary from the default rate and burst shown in the table above. For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
|
|
556
|
+
|
|
557
|
+
Args:
|
|
558
|
+
purchaseOrderNumber:string | * REQUIRED Purchase order number of the shipment for which to return the invoice.
|
|
559
|
+
|
|
560
|
+
Returns:
|
|
561
|
+
ApiResponse:
|
|
562
|
+
"""
|
|
563
|
+
|
|
564
|
+
return await self._request(
|
|
565
|
+
fill_query_params(kwargs.pop("path"), purchaseOrderNumber), params=kwargs
|
|
566
|
+
)
|
|
567
|
+
|
|
568
|
+
@sp_endpoint("/vendor/directFulfillment/shipping/v1/packingSlips", method="GET")
|
|
569
|
+
async def get_packing_slips(self, **kwargs) -> ApiResponse:
|
|
570
|
+
"""
|
|
571
|
+
get_packing_slips(self, **kwargs) -> ApiResponse
|
|
572
|
+
|
|
573
|
+
Returns a list of packing slips for the purchase orders that match the criteria specified. Date range to search must not be more than 7 days.
|
|
574
|
+
|
|
575
|
+
**Usage Plans:**
|
|
576
|
+
|
|
577
|
+
|
|
578
|
+
====================================== ==============
|
|
579
|
+
Rate (requests per second) Burst
|
|
580
|
+
====================================== ==============
|
|
581
|
+
10 10
|
|
582
|
+
====================================== ==============
|
|
583
|
+
|
|
584
|
+
The x-amzn-RateLimit-Limit response header returns the usage plan rate limits that were applied to the requested operation. Rate limits for some selling partners will vary from the default rate and burst shown in the table above. For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
|
|
585
|
+
|
|
586
|
+
Args:
|
|
587
|
+
key shipFromPartyId:string | The vendor warehouseId for order fulfillment. If not specified the result will contain orders for all warehouses.
|
|
588
|
+
key limit:integer | The limit to the number of records returned
|
|
589
|
+
key createdAfter:string | * REQUIRED Packing slips that became available after this date and time will be included in the result. Must be in ISO-8601 date/time format.
|
|
590
|
+
key createdBefore:string | * REQUIRED Packing slips that became available before this date and time will be included in the result. Must be in ISO-8601 date/time format.
|
|
591
|
+
key sortOrder:string | Sort ASC or DESC by packing slip creation date.
|
|
592
|
+
key nextToken:string | Used for pagination when there are more packing slips than the specified result size limit. The token value is returned in the previous API call.
|
|
593
|
+
|
|
594
|
+
Returns:
|
|
595
|
+
ApiResponse:
|
|
596
|
+
"""
|
|
597
|
+
|
|
598
|
+
return await self._request(kwargs.pop("path"), params=kwargs)
|
|
599
|
+
|
|
600
|
+
@sp_endpoint("/vendor/directFulfillment/shipping/v1/packingSlips/{}", method="GET")
|
|
601
|
+
async def get_packing_slip(self, purchaseOrderNumber, **kwargs) -> ApiResponse:
|
|
602
|
+
"""
|
|
603
|
+
get_packing_slip(self, purchaseOrderNumber, **kwargs) -> ApiResponse
|
|
604
|
+
|
|
605
|
+
Returns a packing slip based on the purchaseOrderNumber that you specify.
|
|
606
|
+
|
|
607
|
+
**Usage Plans:**
|
|
608
|
+
|
|
609
|
+
|
|
610
|
+
====================================== ==============
|
|
611
|
+
Rate (requests per second) Burst
|
|
612
|
+
====================================== ==============
|
|
613
|
+
10 10
|
|
614
|
+
====================================== ==============
|
|
615
|
+
|
|
616
|
+
The x-amzn-RateLimit-Limit response header returns the usage plan rate limits that were applied to the requested operation. Rate limits for some selling partners will vary from the default rate and burst shown in the table above. For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
|
|
617
|
+
|
|
618
|
+
Args:
|
|
619
|
+
purchaseOrderNumber:string | * REQUIRED The purchaseOrderNumber for the packing slip you want.
|
|
620
|
+
|
|
621
|
+
Returns:
|
|
622
|
+
ApiResponse:
|
|
623
|
+
"""
|
|
624
|
+
|
|
625
|
+
return await self._request(
|
|
626
|
+
fill_query_params(kwargs.pop("path"), purchaseOrderNumber), params=kwargs
|
|
627
|
+
)
|
|
File without changes
|
sp_api/asyncio/api/vendor_direct_fulfillment_transactions/vendor_direct_fulfillment_transactions.py
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import urllib.parse
|
|
2
|
+
|
|
3
|
+
from sp_api.base import Client, sp_endpoint, fill_query_params, ApiResponse
|
|
4
|
+
from sp_api.asyncio.base import AsyncBaseClient
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
class VendorDirectFulfillmentTransactions(AsyncBaseClient):
|
|
8
|
+
"""
|
|
9
|
+
VendorDirectFulfillmentTransactions SP-API Client
|
|
10
|
+
:link:
|
|
11
|
+
|
|
12
|
+
The Selling Partner API for Direct Fulfillment Transaction Status provides programmatic access to a direct fulfillment vendor's transaction status.
|
|
13
|
+
"""
|
|
14
|
+
|
|
15
|
+
@sp_endpoint(
|
|
16
|
+
"/vendor/directFulfillment/transactions/v1/transactions/{}", method="GET"
|
|
17
|
+
)
|
|
18
|
+
async def get_transaction_status(self, transactionId, **kwargs) -> ApiResponse:
|
|
19
|
+
"""
|
|
20
|
+
get_transaction_status(self, transactionId, **kwargs) -> ApiResponse
|
|
21
|
+
|
|
22
|
+
Returns the status of the transaction indicated by the specified transactionId.
|
|
23
|
+
|
|
24
|
+
**Usage Plans:**
|
|
25
|
+
|
|
26
|
+
====================================== ==============
|
|
27
|
+
Rate (requests per second) Burst
|
|
28
|
+
====================================== ==============
|
|
29
|
+
10 10
|
|
30
|
+
====================================== ==============
|
|
31
|
+
|
|
32
|
+
The x-amzn-RateLimit-Limit response header returns the usage plan rate limits that were applied to the requested operation. Rate limits for some selling partners will vary from the default rate and burst shown in the table above. For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
|
|
33
|
+
|
|
34
|
+
Args:
|
|
35
|
+
transactionId:string | * REQUIRED Previously returned in the response to the POST request of a specific transaction.
|
|
36
|
+
|
|
37
|
+
Returns:
|
|
38
|
+
ApiResponse:
|
|
39
|
+
"""
|
|
40
|
+
|
|
41
|
+
return await self._request(
|
|
42
|
+
fill_query_params(kwargs.pop("path"), transactionId), params=kwargs
|
|
43
|
+
)
|
|
File without changes
|