createSkus
put
/ccadmin/v1/skus
Create Skus. Create skus for product based on the input request parameters. **Requires the x-ccasset-language header so translated content can be set for a specific language.**
Request
Supported Media Types
- application/json
Header Parameters
- X-CCAsset-Language
-
Type:
string
Required:true
The asset language of the request
Body Parameter
Root Schema : createSkus_request
{
"productId":"xprod12345",
"variants":[
{
"color":"red",
"id":"sku1",
"listPrice":"200"
},
{
"color":"blue",
"id":"sku2"
}
]
}
- includePrices
-
Type:
boolean
Boolean flag to determine whether to include price maps for the skus in the response. - priceListGroupId
-
Type:
string
Price list group id for adding the prices to the SKU in the response. - productId
-
Type:
string
Required:true
ID corresponding to the product. - variants
-
Type:
array
variantsRequired:true
Array of objects with dynamic properties. The properties change from one product type to another.
Nested Schema : variants
Nested Schema : items
Type:
object
- id
-
Type:
string
Required:true
The id of the SKU.
Response
Supported Media Types
- application/json
200 Response
Following model is returned when operation succeeds.
Body
Root Schema : createSkus_response
- items
-
Type:
array
itemsthe list of created skus
Nested Schema : items
Type:
object
- active
-
Type:
boolean
Indicates whether SKU is active or inactive. Inactive SKUs will not appear on the storefront. This property value defaults to true. - barcode
-
Type:
string
Barcode property of the sku - configurable
-
Type:
boolean
Indicates whether the SKU is configurable or not - fractionalQuantitiesAllowed
-
Type:
boolean
If fractional quantities are allowed. - fullImageURLs
-
Type:
array
fullImageURLsFull Image URLs of SKU. - images
-
Type:
array
imagesArray of images for the SKU. - largeImage
-
Type:
integer
Large image of the SKU. - largeImageURLs
-
Type:
array
largeImageURLsLarge Image URLs of SKU. - listPrice
-
Type:
number
List price of the SKU. - listVolumePrice
-
Type:
object
listVolumePricelist volume price of the SKU - listVolumePrices
-
Type:
object
listVolumePricesObject with price group IDs as keys and list prices as values - mediumImageURLs
-
Type:
array
mediumImageURLsMedium Image URLs SKU. - model
-
Type:
string
Model property of the SKU - primaryLargeImageURL
-
Type:
string
Primary Large Image URL of SKU. - primaryMediumImageURL
-
Type:
string
Primary Medium Image URL ID of SKU. - primarySmallImageURL
-
Type:
string
Primary Small Image URL of SKU. - primarySourceImageURL
-
Type:
string
Primary Source Image URL of SKU. - primaryThumbImageURL
-
Type:
string
Primary Source Image URL of SKU. - productFamily
-
Type:
string
Product Family property of the SKU - productLine
-
Type:
string
Product line property of the SKU - productListingSku
-
Type:
boolean
This is true if this sku is the listing sku for a particular variant - quantity
-
Type:
integer
Quantity of the SKU. - repositoryId
-
Type:
string
Repository ID of the SKU. - salePrice
-
Type:
string
Sale price of the SKU. - salePriceEndDate
-
Type:
integer
Sale price end date of the SKU. - salePriceStartDate
-
Type:
string
Sale price start date of the SKU. - saleVolumePrice
-
Type:
object
saleVolumePriceSale volume price of the SKU - saleVolumePrices
-
Type:
object
saleVolumePricesObject with price group IDs as keys and sale prices as values - smallImage
-
Type:
integer
Small image of the SKU. - smallImageURLs
-
Type:
array
smallImageURLsSmall Image URLs of SKU. - sourceImageURLs
-
Type:
array
sourceImageURLsSource Image URLs of SKU. - thumbImageURLs
-
Type:
array
thumbImageURLsThumb Image URLs of SKU. - thumbnailImage
-
Type:
string
Thumbnail image of the SKU.
Nested Schema : fullImageURLs
Nested Schema : largeImageURLs
Nested Schema : listVolumePrice
Type:
object
list volume price of the SKU
- pricingScheme
-
Type:
object
pricingSchemePricing scheme can be either tieredPrice or bulkPrice
Nested Schema : listVolumePrices
Type:
object
Object with price group IDs as keys and list prices as values
- PriceGroupID1
-
Type:
object
PriceGroupID1List price of the SKU in price group 1 - PriceGroupID2
-
Type:
object
PriceGroupID2List price of the SKU in price group 2
Nested Schema : mediumImageURLs
Nested Schema : saleVolumePrice
Type:
object
Sale volume price of the SKU
- pricingScheme
-
Type:
object
pricingSchemePricing scheme can be either tieredPrice or bulkPrice
Nested Schema : saleVolumePrices
Type:
object
Object with price group IDs as keys and sale prices as values
- PriceGroupID1
-
Type:
object
PriceGroupID1Sale price of the SKU in price group 1 - PriceGroupID2
-
Type:
object
PriceGroupID2Sale price of the SKU in price group 2
Nested Schema : smallImageURLs
Nested Schema : sourceImageURLs
Nested Schema : thumbImageURLs
Nested Schema : items
Type:
object
Nested Schema : metadata
Type:
object
Seo meta info.
- altText
-
Type:
string
Alt text for image. - titleText
-
Type:
string
Title text for image.
Nested Schema : pricingScheme
Type:
object
Pricing scheme can be either tieredPrice or bulkPrice
- levels
-
Type:
array
levelsPrice levels array for volume price - numLevels
-
Type:
number
Number of levels in the volume price
Nested Schema : items
Type:
object
- levelMaximum
-
Type:
number
minimum quantity for price level - levelMinimum
-
Type:
number
minimum quantity for price level - price
-
Type:
number
price value for price level
Nested Schema : PriceGroupID1
Type:
object
List price of the SKU in price group 1
- pricingScheme
-
Type:
object
pricingSchemePricing scheme can be either tieredPrice or bulkPrice
Nested Schema : PriceGroupID2
Type:
object
List price of the SKU in price group 2
- pricingScheme
-
Type:
object
pricingSchemePricing scheme can be either tieredPrice or bulkPrice
Nested Schema : pricingScheme
Type:
object
Pricing scheme can be either tieredPrice or bulkPrice
- levels
-
Type:
array
levelsPrice levels array for volume price - numLevels
-
Type:
number
Number of levels in the volume price
Nested Schema : items
Type:
object
- levelMaximum
-
Type:
number
minimum quantity for price level - levelMinimum
-
Type:
number
minimum quantity for price level - price
-
Type:
number
price value for price level
Nested Schema : pricingScheme
Type:
object
Pricing scheme can be either tieredPrice or bulkPrice
- levels
-
Type:
array
levelsPrice levels array for volume price - numLevels
-
Type:
number
Number of levels in the volume price
Nested Schema : items
Type:
object
- levelMaximum
-
Type:
number
minimum quantity for price level - levelMinimum
-
Type:
number
minimum quantity for price level - price
-
Type:
number
price value for price level
Nested Schema : pricingScheme
Type:
object
Pricing scheme can be either tieredPrice or bulkPrice
- levels
-
Type:
array
levelsPrice levels array for volume price - numLevels
-
Type:
number
Number of levels in the volume price
Nested Schema : items
Type:
object
- levelMaximum
-
Type:
number
minimum quantity for price level - levelMinimum
-
Type:
number
minimum quantity for price level - price
-
Type:
number
price value for price level
Nested Schema : PriceGroupID1
Type:
object
Sale price of the SKU in price group 1
- pricingScheme
-
Type:
object
pricingSchemePricing scheme can be either tieredPrice or bulkPrice
Nested Schema : PriceGroupID2
Type:
object
Sale price of the SKU in price group 2
- pricingScheme
-
Type:
object
pricingSchemePricing scheme can be either tieredPrice or bulkPrice
Nested Schema : pricingScheme
Type:
object
Pricing scheme can be either tieredPrice or bulkPrice
- levels
-
Type:
array
levelsPrice levels array for volume price - numLevels
-
Type:
number
Number of levels in the volume price
Nested Schema : items
Type:
object
- levelMaximum
-
Type:
number
minimum quantity for price level - levelMinimum
-
Type:
number
minimum quantity for price level - price
-
Type:
number
price value for price level
Nested Schema : pricingScheme
Type:
object
Pricing scheme can be either tieredPrice or bulkPrice
- levels
-
Type:
array
levelsPrice levels array for volume price - numLevels
-
Type:
number
Number of levels in the volume price
Nested Schema : items
Type:
object
- levelMaximum
-
Type:
number
minimum quantity for price level - levelMinimum
-
Type:
number
minimum quantity for price level - price
-
Type:
number
price value for price level
Example application/json
[
{
"productFamily":null,
"dynamicPropertyMapLong":{
"sku-MensApparel_color":2
},
"primaryThumbImageURL":null,
"largeImage":null,
"smallImage":null,
"color":"red",
"listPrices":{
"UsDollar":"200"
},
"salePrices":null,
"primaryFullImageURL":null,
"productListingSku":null,
"largeImageURLs":[
],
"productLine":null,
"primaryLargeImageURL":null,
"smallImageURLs":[
],
"model":null,
"thumbnailImage":null,
"barcode":null,
"salePriceEndDate":null,
"salePriceStartDate":null,
"images":[
],
"quantity":null,
"salePrice":null,
"primaryMediumImageURL":null,
"fullImageURLs":[
],
"active":true,
"thumbImageURLs":[
],
"mediumImageURLs":[
],
"repositoryId":"sku1",
"primarySourceImageURL":null,
"primarySmallImageURL":null,
"sourceImageURLs":[
],
"listPrice":"200",
"configurable":"false"
},
{
"productFamily":null,
"dynamicPropertyMapLong":{
"sku-MensApparel_color":3
},
"primaryThumbImageURL":null,
"largeImage":null,
"smallImage":null,
"listVolumePrice":null,
"color":"Blue",
"listPrices":null,
"salePrices":null,
"primaryFullImageURL":null,
"productListingSku":null,
"largeImageURLs":[
],
"productLine":null,
"listVolumePrices":null,
"primaryLargeImageURL":null,
"smallImageURLs":[
],
"model":null,
"thumbnailImage":null,
"saleVolumePrices":null,
"barcode":null,
"salePriceEndDate":null,
"saleVolumePrice":null,
"salePriceStartDate":null,
"images":[
],
"quantity":null,
"salePrice":null,
"primaryMediumImageURL":null,
"fullImageURLs":[
],
"active":true,
"thumbImageURLs":[
],
"mediumImageURLs":[
],
"repositoryId":"sku2",
"primarySourceImageURL":null,
"primarySmallImageURL":null,
"sourceImageURLs":[
],
"listPrice":null,
"configurable":"false"
}
]
Default Response
The error response
Body
Root Schema : errorModel
Type:
object
- devMessage
-
Type:
string
An optional non-localized message containing technical information for developers - errorCode
-
Type:
string
The numerical code identifying the error - errors
-
Type:
array
errorsAn optional list of errors if multiple errors were encountered - message
-
Type:
string
The localized message describing the error - moreInfo
-
Type:
string
An optional non-localized message with more information - o:errorPath
-
Type:
string
An optional machine readable description of where the error occurred - status
-
Type:
string
The HTTP status code - type
-
Type:
string
The URI to the HTTP state code definition
Nested Schema : errors
Nested Schema : items
Type:
object
- devMessage
-
Type:
string
An optional non-localized message containing technical information for developers - errorCode
-
Type:
string
The numerical code identifying the error - message
-
Type:
string
The localized message describing the error - moreInfo
-
Type:
string
An optional non-localized message with more information - o:errorPath
-
Type:
string
An optional machine readable description of where the error occurred - status
-
Type:
string
The HTTP status code
Examples
Sample Request:
{ "productId": "xprod12345", "variants": [ { "color": "red", "id": "sku1", "listPrice": "200" }, { "color": "blue", "id": "sku2" } ] }
Sample Response Payload returned by endpoint:
[ { "productFamily": null, "dynamicPropertyMapLong": {"sku-MensApparel_color": 2}, "primaryThumbImageURL": null, "largeImage": null, "smallImage": null, "color": "red", "listPrices": {"UsDollar": "200"}, "salePrices": null, "primaryFullImageURL": null, "productListingSku": null, "largeImageURLs": [], "productLine": null, "primaryLargeImageURL": null, "smallImageURLs": [], "model": null, "thumbnailImage": null, "barcode": null, "salePriceEndDate": null, "salePriceStartDate": null, "images": [], "quantity": null, "salePrice": null, "primaryMediumImageURL": null, "fullImageURLs": [], "active": true, "thumbImageURLs": [], "mediumImageURLs": [], "repositoryId": "sku1", "primarySourceImageURL": null, "primarySmallImageURL": null, "sourceImageURLs": [], "listPrice": "200", "configurable": "false" }, { "productFamily": null, "dynamicPropertyMapLong": {"sku-MensApparel_color": 3}, "primaryThumbImageURL": null, "largeImage": null, "smallImage": null, "listVolumePrice": null, "color": "Blue", "listPrices": null, "salePrices": null, "primaryFullImageURL": null, "productListingSku": null, "largeImageURLs": [], "productLine": null, "listVolumePrices": null, "primaryLargeImageURL": null, "smallImageURLs": [], "model": null, "thumbnailImage": null, "saleVolumePrices": null, "barcode": null, "salePriceEndDate": null, "saleVolumePrice": null, "salePriceStartDate": null, "images": [], "quantity": null, "salePrice": null, "primaryMediumImageURL": null, "fullImageURLs": [], "active": true, "thumbImageURLs": [], "mediumImageURLs": [], "repositoryId": "sku2", "primarySourceImageURL": null, "primarySmallImageURL": null, "sourceImageURLs": [], "listPrice": null, "configurable": "false" } ]