post https://{host}/v1.1/product/add
Allows you to add product to the inventory.
Enabling OU support for product entities
To enable OU support for product entities, you need to create a JIRA ticket and enable the config
CONF_OU_LEVEL_PRODUCTS_ENABLED
. For more information, see Configuring Organisation Unit (OU) support for product entities.
Request Body Parameters
Parameter | Datatype | Description |
---|---|---|
product* | array-obj | list of products to add. |
sku* | string | SKU of the product to add. |
ean | string | European article number of the product. |
price* | double | Price of the product. |
description | string | Brief description of the product. |
returnable | boolean | Pass true if the item is allowed to return post purchase. You also need to mention returnableDays . Default value is false . |
returnableDays | int | Number of days in which the item can be returned after purchasing. Default value is -1 (no limit). |
long_description | string | Detailed description of the product. |
ou_code | string | Identification code of the organisation unit. This is applicable only if OU support for product inventory is enabled. For more information, see OU support for product inventory. |
img_url | string | URL of the product image. |
size | obj | Size of the product in name:value pairs. |
style | obj | Product style in name:value pairs. |
type | string | Size type. |
brand | obj | Pass a valid brand name (as per the database) of the product. |
color | obj | Pass a valid product color (as per the database) . |
category | obj | Pass a valid product category name ((as per the database). |
attributes | obj | Other product attributes in name-value pairs. |
Parameters marked with * are mandatory. Values of product attributes such as style, size, brand, type, color, and category should have been configured for the org. You can set these on the Organization Settings page on InTouch.
Response Parameters
Parameter | Datatype | Description |
---|---|---|
item_id | long | Unique ID of the product generated by the system. |
name | string | Name of the entry. |
label | string | UI name of the specific entry (style, color, category, brand) |
added_on | date-time | Date and time of the product addition. |
description | string | Description of the specific entry as in the database. |
ou_code | string | Identification code of the organisation unit. |
ou_id | Integer | Identification number of the organisation unit. |