Update Product by ID
Update Product by ID
PUT /products/{id}
Parameters
| Name | Description | Type |
|---|---|---|
| id* | Path parameter | string |
| tenantId* | Header parameter | string |
| countryCode* | Header parameter | string |
Request Body
{
"merchantId": "string",
"businessId": "string",
"name": "string",
"description": "string",
"sku": "string",
"productPublicId": "string",
"category": "string",
"subCategories": [
"string"
],
"brand": "string",
"costPrice": {
"price": 0,
"unitQuantity": 0,
"unitPrice": 0
},
"sellingPrice": {
"price": 0,
"unitQuantity": 0,
"unitPrice": 0
},
"priceMargin": {
"type": "FIXED",
"source": "BUSINESS",
"value": 0,
"enabled": true
},
"promotionRequest": {
"name": "string",
"discountType": "FIXED",
"amount": 0,
"percentage": 0,
"endDate": "string"
},
"reorderLevel": 0,
"quantityOnHand": 0,
"unit": "string",
"minimumOrderQuantity": 0,
"weight": 0,
"imageLinks": [
"string"
],
"base64Images": [
"string"
],
"clusters": [
"string"
]
}
Responses
200 OK
Description: Successful operation
Example Value:
{
"message": "string",
"data": {
"id": "string",
"name": "string",
"description": "string",
"sku": "string",
"category": "string",
"subCategories": [
"string"
],
"brand": "string",
"productPublicId": "string",
"costPrice": {
"price": 0,
"unitQuantity": 0,
"unitPrice": 0
},
"sellingPrice": {
"price": 0,
"unitQuantity": 0,
"unitPrice": 0
},
"priceMargin": {
"type": "FIXED",
"source": "BUSINESS",
"value": 0,
"enabled": true
},
"quantityOnHand": 0,
"minimumOrderQuantity": 0,
"reorderLevel": 0,
"stockLevel": "OUT_OF_STOCK",
"unit": "string",
"weight": 0,
"visibility": true,
"images": [
"string"
],
"businessId": "string",
"merchantId": "string",
"vatRatio": 0,
"createdAt": "2024-07-17T17:36:45.183Z",
"updatedAt": "2024-07-17T17:36:45.183Z",
"clusters": [
"string"
],
"business": {
"get_id": "string",
"name": "string",
"email": "string",
"photo": "string",
"wallet": {
"userId": "string",
"virtualBankCode": "string",
"floatAccountId": "string",
"floatAccountUuid": "string",
"floatAccountNumber": "string",
"commissionAccountId": "string"
},
"address": {
"country": "string",
"latitude": 0,
"lga": "string",
"name": "string",
"state": "string",
"longitude": 0
},
"location": {
"coordinates": [
0
],
"type": "string"
},
"user": "string",
"owner": {
"profileTenant": "string",
"city": {
"code": "string",
"name": "string"
},
"country": {
"code": "string",
"name": "string",
"currency": "string"
},
"firstName": "string",
"lastName": "string",
"phone": "string",
"photo": "string",
"state": {
"code": "string",
"name": "string"
},
"username": "string",
"wallet": {
"userId": "string",
"virtualBankCode": "string",
"floatAccountId": "string",
"floatAccountUuid": "string",
"floatAccountNumber": "string",
"commissionAccountId": "string"
},
"id": "string",
"fullName": "string"
},
"businessHandle": "string",
"shippingFee": 0,
"phone": "string",
"category": "string",
"active": true,
"acceptingOrder": true,
"isDistributor": true,
"isManufacturer": true,
"isHead": true,
"extraLocationPrice": 0,
"distance": 0,
"kycDetails": {
"additionalProp1": {},
"additionalProp2": {},
"additionalProp3": {}
},
"pickUpAddresses": [
{
"country": "string",
"latitude": 0,
"lga": "string",
"name": "string",
"state": "string",
"longitude": 0,
"location": {
"coordinates": [
0
],
"type": "string"
}
}
],
"priceMargin": {
"type": "FIXED",
"source": "BUSINESS",
"value": 0,
"enabled": true
}
}
},
"meta": {
"currentPage": 0,
"from": 0,
"to": 0,
"perPage": 0,
"total": 0,
"lastPage": 0
}
}