Add New Product
### Add New Product
This APIs endpoint allows you to add a new product to the Dice. The request should be sent as an HTTP POST to `hostName/apis/external/product/addProduct`.
### Request Body
| Params | Required | Type | Description |
| --- | --- | --- | --- |
| id | Optional | string | The ID of the product. |
| gl | Optional | string | The GL code of the product. |
| title | Mandatory | string | The title or name of the product. |
| des | Mandatory | string | The description of the product. |
| sku | Optional | string | The SKU (stock keeping unit) of the product. |
| hsn | Mandatory | string | The HSN (Harmonized System of Nomenclature) code. |
| category | Mandatory | integer | The category of the product. <br>required only if serviceName not present in request body |
| serviceName | Optional | String | if category is provided in request body than this field required |
| tax | Mandatory | integer | The tax rate applicable to the product. |
| units | Mandatory | string | The units in which the product is measured. |
| currency | Optional | string | The currency in which the amount is specified. |
| amount | Mandatory | integer | The amount of the product. |
| sale | Mandatory | boolean | Indicates if the product is available for sale. |
| buy | Mandatory | boolean | Indicates if the product is available for purchase. |
| type | Mandatory | string | The type of the product. |
| image | Mandatory | string | The image URL of the product. |
### Response
- `success` (boolean): Indicates whether the product addition was successful.
Headers
DICE-APP-ID
Company Code of client
X-CLIENT-ID
API Client ID
X-CLIENT-SECRET
API Client Secret
Request
This endpoint expects an object.
id
gl
title
des
sku
hsn
category
serviceName
tax
units
currency
amount
sale
buy
type
image
Response
OK
success

