Catalog Upload
As your company uses Amazon’s retail technology, you will need to provide Amazon with a catalog of detailed product information for the products you sell and keep this information up-to-date. You can update your catalog manually using the 3PCC Portal or you can use our Catalog API, which allows you to programmatically update your catalog through a simple REST API. This spec will assist you in automating your catalog updates using the Amazon Catalog API.
Note: In the future, new attributes might be added. We recommend that you structure your code so that it can handle new attributes gracefully
Upload Catalog
POST /v1/catalog/upload
This method is used for JWO stores. The UploadCatalog API method allows you to upload list of items available for sale in your JWO store to the Amazon systems
Body parameter
{
"catalogItems": [
{
"item_sku": "string",
"external_product_id": "string",
"external_product_id_type": "string",
"item_name": "string",
"store_id": "string",
"standard_price": "string",
"brand_name": "string",
"product_tax_code": "string",
"product_category": "string",
"product_subcategory": "string"
}
]
}
Data Field | Required | Description |
---|---|---|
item_sku | Required | <= 255 characters. A unique identifier for the product, assigned by the retailer. The SKU must be unique for each product listed. |
external_product_id | Required | <= 255 characters. A standard, alphanumeric string that uniquely identifies the product and should match the barcode value that will be scanned as part of inventory stocking. Scannable barcodes can either be 12/8 digits (UPC), 13 digits (EAN), 8 digits (EAN8), 10 digits (ISBN), 14 digits (GTIN) or PLU (Integer). |
external_product_id_type | Optional | <= 255 characters. The type of standard, unique identifier entered in the scannable barcode field. For example it can be UPC, ISBN, EAN, EAN8, GTIN or PLU |
item_name | Required | <= 255 characters. A short title for a product. |
store_id | Required | <= 255 characters. The store_id field contains a unique identifier for your store defined during your onboarding process with Amazon. The storeId is also used when uploading the store catalog into the JWO portal |
standard_price | Optional | <= 10 characters. This price can either include price without tax or price with tax at which an item is being sold in the local currency. |
brand_name | Optional | <= 255 characters The brand name of the product. |
product_tax_code | Optional | <= 255 characters. Amazon Standard code to identify the tax properties of a product. |
product_category | Optional | <= 50 characters. This is a custom field you can use to categorize your products and enable grouping and filtering in analytics dashboards and reports. |
product_subcategory | Optional | <= 50 characters.This is a custom field you can use to categorize your products and enable grouping and filtering in analytics dashboards and reports. |
Example responses
201 Response
{
"ingestionId": "string"
}
Data Field | Description |
---|---|
ingestionId | <= 255 characters. Unique ID for a catalog upload to Amazon systems. Amazon will generate a unique id for each catalog upload |
Status | Meaning | Description |
---|---|---|
201 | OK | Unique ID for a catalog upload to Amazon systems. Amazon will generate a unique id for each catalog upload |
400 | Bad Request | You will receive a 400 error message when the API call fails due to a validation error. |
429 | Too Many Requests | You will receive a 429 error message when the API is called too many times. When you receive a 429 error due to multiple calls to the API you will receive the following response. errorMsg: Too Many Requests |
500 | Internal Server Error | You will receive a 500 error message when the API call fails due to an error. |
Code sample
Upload Cart Catalog Code sample
import requests
from requests_aws4auth import AWS4Auth
# There is a chance that the requests and AWS4Auth will require to be included in the Lambda layer.
import json
import boto3
# Sample catalog update
# Replace with Catalog input JSON source
request_parameters =json.dumps(<INSERT CATALOG JSON>)
# ARN of IAM allow listed by Amazon
roleArn = <INSERT IAM ROLE>
# Get temp credentials using STS
client_sts = boto3.client('sts')
response = client_sts.assume_role(
RoleArn=roleArn,
RoleSessionName='CatalogAPI'
)
ACCESS_KEY = response['Credentials']['AccessKeyId']
SECRET_KEY = response['Credentials']['SecretAccessKey']
SESSION_TOKEN = response['Credentials']['SessionToken']
# Auth the outgoing API call
auth = AWS4Auth(ACCESS_KEY, SECRET_KEY, 'us-east-1', 'execute-api',
session_token=SESSION_TOKEN)
# Use requests library to post to the API end point
response = requests.post(<URL to API end point>, auth=auth)
# Check response code and act accordingly
resonseCode = response.status_code
if resonseCode == 201:
reponsetext = (json.loads(response.text))
print(reponsetext['ingestionId'])
elif resonseCode == 403:
print("Error authenticating to the API")
print(response.status_code)
elif resonseCode == 400:
print("Error: Bad request")
print(response.status_code)
# Note: please ensure you handle the error codes listed in the API spec for more complete error handling
else:
print("Not recognized code")
print(response.status_code)