Repository navigation
Vendor Product Add
Mehrdad Pajuhaan edited this page Oct 23, 2026
·
4 revisions
Create a new vendor-specific offering for a product in a multi-vendor marketplace. Each vendor can offer a product (or one of its variants) with its own price, quantity and lead time.
Base URL:
https://api.selldone.comAuth header:Authorization: Bearer YOUR_ACCESS_TOKEN
POST /shops/{shop_id}/products/{product_id}/vendors
SDK URL builder: window.API.POST_ADD_PRODUCT_VENDOR(shop_id, product_id).
This endpoint is restricted to marketplace owners: the token needs the backoffice:product:write scope and access
to the shop's Marketplace permission region. Vendors cannot add product offers themselves through this API.
| Name | Type | Required | Description |
|---|---|---|---|
vendor_id |
integer | Yes | ID of the vendor to assign the product to. |
variant_id |
integer | Optional | Required if the product has variants. |
raw_price |
number | Yes | Base price before applying pricing rules. |
price |
number | Yes | Final sell price (ignored if pricing_id is used). |
pricing_id |
integer | Optional | ID of a pricing plan to auto-calculate the price. |
quantity |
integer | Yes | Initial inventory quantity. |
lead |
integer | Yes | Delivery lead time in days (-1 if unknown). |
enable |
boolean | Optional | Default: true. Whether the offer is active. |
currency |
string | Optional | Must match the product currency (for example USD). |
commission |
number | Optional | Optional vendor commission override. |
discount |
number | Optional | Optional discount percentage. |
dis_start |
date | Optional | Discount start date. |
dis_end |
date | Optional | Discount end date. |
- If the product has multiple variants, you must set
variant_id. - Duplicate entries (same vendor and variant) are not allowed.
- If a
pricing_idis provided,priceis calculated automatically asraw_price × (1 + commission%), rounded according to the currency format. - The currency must match the product's currency.
POST https://api.selldone.com/shops/123/products/456/vendors
Authorization: Bearer YOUR_ACCESS_TOKEN
Content-Type: application/json
{
"vendor_id": 10,
"variant_id": 3,
"raw_price": 12.0,
"pricing_id": 2,
"quantity": 20,
"lead": 5,
"enable": true,
"currency": "USD"
}{
"success": true,
"vendor": {
"id": 10,
"name": "FreshBazaar"
},
"vendor_product": {
"id": 88,
"product_id": 456,
"vendor_id": 10,
"variant_id": 3,
"raw_price": 12.0,
"price": 13.2,
"quantity": 20,
"enable": true,
"currency": "USD",
"lead": 5,
...
}
}| Error | Description |
|---|---|
Vendor not found |
The provided vendor_id does not exist. |
Variant required |
The product has variants, but none was selected. |
Duplicate vendor-product |
The vendor is already assigned to this product or variant. |
Currency mismatch |
The offer currency does not match the product currency. |
Pricing plan not found |
pricing_id is invalid. |
- Check whether the product has variants before submitting.
- Use pricing plans (
pricing_id) for consistent commission handling across vendors. - Call Vendor Products List first to check for existing assignments.
-
Vendor Products List:
GET /shops/{shop_id}/products/{product_id}/vendors -
Vendor Product Update:
PUT /shops/{shop_id}/products/{product_id}/vendors/{vendor_product_id} -
Vendor Product Delete:
DELETE /shops/{shop_id}/products/{product_id}/vendors/{vendor_product_id} -
Get Vendors List:
GET /shops/{shop_id}/vendors
Guides
Products
- Fetch Products List
- Edit Product
- Edit Product's Variant
- Add Images to Products/Variants
- Upload Products Category Image
Marketplace vendors
- Get Vendors List
- Vendor Products List
- Vendor Product Add
- Vendor Product Update
- Vendor Product Delete
Ecosystem
Links