京东商城商品图片修改
This commit is contained in:
@@ -142,11 +142,12 @@ type CreateSkuResult struct {
|
||||
}
|
||||
|
||||
type UpdateWareParam struct {
|
||||
WareID int64 `json:"wareId"`
|
||||
Title string `json:"title"` //否 标题 商品名称 限制45个字符内
|
||||
VenderID int64 `json:"venderId"`
|
||||
PromiseID int `json:"promiseId"` // 否 无 配送时效
|
||||
// Weight int `json:"weight"` //否 无 商品重量,单位kg
|
||||
WareID int64 `json:"wareId"`
|
||||
Title string `json:"title"` //否 标题 商品名称 限制45个字符内
|
||||
VenderID int64 `json:"venderId"`
|
||||
PromiseID int `json:"promiseId"` // 否 无 配送时效
|
||||
MobileDesc string `json:"mobileDesc"` // 是 无 移动版的商品介绍 长度限制10W个字符
|
||||
Introduction string `json:"introduction"` // 是 无 PC版的商品介绍 长度限制10W个字符
|
||||
}
|
||||
|
||||
type QueryPictureReuslt struct {
|
||||
@@ -401,3 +402,15 @@ func (a *API) FindSkuStock(skuId int64) (err error) {
|
||||
})
|
||||
return err
|
||||
}
|
||||
|
||||
//修改商品图片
|
||||
//https://open.jd.com/home/home#/doc/api?apiCateId=48&apiId=1258&apiName=jingdong.image.write.update
|
||||
func (a *API) ImageUpdate(wareId int64, imgIndex int, imgUrl string) (err error) {
|
||||
_, err = a.AccessAPI("jingdong.image.write.update", prodURL, map[string]interface{}{
|
||||
"wareId": wareId,
|
||||
"imgIndex": imgIndex,
|
||||
"imgUrl": imgUrl,
|
||||
"colorId": "0000000000",
|
||||
})
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user