Skip to navigation

Create products in batch

View as Markdown

Create or update multiple ecommerce products in a single request. The products array accepts up to 100 product objects for creation (or up to 1000 when updateEnabled is true and the account has an increased limit). Each product requires a unique id and name (name is mandatory for creation only). When updateEnabled is false, all products are inserted as new; if any ID already exists, a 400 error is returned. When updateEnabled is true, existing products are updated and new ones are created via upsert. Duplicate IDs within the same request payload are rejected. The response returns the count of created and updated products.

Authentication

api-keystring

The API key should be passed in the request headers as api-key for authentication.

OR
AuthorizationBearer

OAuth 2.0 client_credentials (machine-to-machine) grant. Exchange your app's client_id/client_secret for a short-lived Bearer token.

Request

Values to create a batch of products
productslist of objectsRequired
array of products objects
updateEnabledbooleanOptional

Facilitate to update the existing products in the same request (updateEnabled = true)

Response

Products created and updated
createdCountlongOptional
Number of the new created products
updatedCountlongOptional
Number of the existing products updated

Errors

400
Bad Request Error