Developers

Products

Markdown

Create a product

Creates a hidden product. It appears in the store once its price is set and it is activated.

POST/stores/{storeId}/v1/products

A new product has status: inactive, price 0.00 and price_state: required. Sending price in the body also requires products.prices:write.

Headers

Idempotency-Keystringrequired

Request body

namestringrequired
descriptionstring
short_descstring
imagestring | null
imagesarray<string>
image_altstring
categorystring | null
slugstring
keywordsarray<string>
supported_devicesarray<string>
seo_titlestring
seo_descriptionstring
og_imagestring | null
product_kindstringrequired
digital service physical
pricestring
old_pricestring | null

Response

dataobjectrequired
idinteger
namestring
descriptionstring
short_descstring | null
imagestring | null
imagesarray<string>
image_altstring | null
categorystring | null
Category name.
slugstring | null
keywordsarray<string>
supported_devicesobject
seo_titlestring | null
seo_descriptionstring | null
og_imagestring | null
product_kindobject
digital service physical
statusobject
active inactive
pricestring
Price in SAR.
old_pricestring | null
Price before discount.
price_stateobject
required until a price is set; a new product is created inactive with price 0.00.required ready
resource_versioninteger
executionobject
Who executed the request: the app, version, installation and store. Field names here are camelCase.
appIdstring (uuid)
versionIdstring (uuid)
installationIdstring (uuid)
storeIdstring (uuid)
requestIdstring (uuid)
generationinteger
routeEpochinteger
appAuthEpochinteger
grantRevisioninteger
metaobjectrequired
request_idstring (uuid)
The request ID; include it in any support request.

Errors

HTTPCodeMeaning
400IDEMPOTENCY_KEY_REQUIREDNo Idempotency-Key header.
422CATEGORY_NOT_FOUNDThe category does not exist.
422UNKNOWN_FIELDUnknown field.

Shared codes are listed in Errors.

    ↑↓ moveEnter openEsc close