Appearance
Create Product API
Endpoint
POST /product
Headers
| Key | Value |
|---|---|
| Authorization | Bearer change_to_your_access_token |
| X-S2-Organization | 95d73baf-76ba-4bea-86ac-1534c5e5d4aa |
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| sku | string | Yes | Product SKU |
| brand | string | Yes | Brand name of the product. |
| gtin | string | Yes | GTIN |
| name | string | Yes | Name of the product. |
| remarks | string | Yes | Should be an empty string if there is no value. Do not use null. |
| imageMain | string | Yes | Main image URL for the product. |
| packageLengthMm | float | Yes | Length of the product's package in millimeters. |
| packageWidthMm | float | Yes | Width of the product's package in millimeters. |
| packageHeightMm | float | Yes | Height of the product's package in millimeters. |
| shippingWeightKg | float | Yes | Weight of the product for shipping purposes in kilograms. |
| caseUnit | string | Yes | Unit of measurement for a case of products (e.g., EACH). |
| casePack | integer | Yes | Number of items in a case pack. |
| caseLengthMm | float | Yes | Length of the product case in millimeters. |
| caseWidthMm | float | Yes | Width of the product case in millimeters. |
| caseHeightMm | float | Yes | Height of the product case in millimeters. |
| caseWeightKg | float | Yes | Weight of the product case in kilograms. |
| condition | string | Yes | Condition of the product (e.g., NEW). |
| serialNumberRequired | boolean | Yes | Indicates if a serial number is required for the product. True/False. |
| expiryDateRequired | boolean | Yes | Indicates if an expiry date is required for the product. True/False. |
Request Body Example
json
{
"sku": "test21",
"brand": "Sony",
"gtin": "7045557637838",
"name": "Test Product",
"remarks": "test.",
"imageMain": "95d73baf-76ba-4bea-86ac-1534c5e5d4aa/2024-04-23/avatar/听雨__24_x_26.25__PFPWig_4_YXKT59pJLuoIk82VgaF.jpg",
"packageLengthMm": 33.27078,
"packageWidthMm": 64.29312,
"packageHeightMm": 96.57682,
"shippingWeightKg": 76.44365,
"caseUnit": "EACH",
"casePack": 2,
"caseLengthMm": 34.340958,
"caseWidthMm": 20.323586,
"caseHeightMm": 12.659683,
"caseWeightKg": 0.35708416,
"condition": "NEW",
"serialNumberRequired": true,
"expiryDateRequired": true
}Response Example
json
{
"id": "3775cc37-30e7-4579-a58e-c9adda6fac86",
"organization": {
"id": "3f424caf-0eba-4813-b3e7-7ca0393af888",
"name": "test organization",
"createdAt": "2024-03-05T22:17:23.520948Z",
"updatedAt": "2024-04-09T21:15:15.615765Z"
},
"sku": "test21",
"brand": {
"id": "e0cbbf33-cbea-4867-9fd9-5d72f22c2321",
"name": "Sony",
"nameNormalized": "sony",
"createdAt": "2024-06-04T03:16:22.617577Z"
},
"gtin": "7045557637838",
"name": "Test Product",
"remarks": "test.",
"imageMain": "95d73baf-76ba-4bea-86ac-1534c5e5d4aa/2024-04-23/avatar/听雨__24_x_26.25__PFPWig_4_YXKT59pJLuoIk82VgaF.jpg",
"packageLengthMm": 33.27078,
"packageWidthMm": 64.29312,
"packageHeightMm": 96.57682,
"shippingWeightKg": 76.44365,
"caseUnit": "EACH",
"casePack": 2,
"caseLengthMm": 34.340958,
"caseWidthMm": 20.323586,
"caseHeightMm": 12.659683,
"caseWeightKg": 0.35708416,
"condition": "NEW",
"serialNumberRequired": false,
"expiryDateRequired": false,
"unknown": false,
"createdAt": "2024-06-04T03:16:22.617577Z",
"updatedAt": "2024-06-04T03:16:22.617577Z",
"otherIds": []
}