开放平台

扒书 ERP Open API

估价公式参数(存)

保存估价公式参数,保存后立即影响新的估价结果。

请求方式GET/POST
接口路径/api/recycle/predicate/assessPriceFormula/save
Content-Typeapplication/json
鉴权X-Nideshop-Token

请求体字段

字段类型必填说明
KV_KEYString否-
minAvgPricedouble否均价下限(> 此值才进入公式)
minHalfYearSellint否半年销量下限(> 此值才进入公式)
sellWeightMaxdouble否销量权重:scaleByProportion 的 returnMax
sellWeightMindouble否销量权重:scaleByProportion 的 returnMin
sellWeightBasedouble否销量权重:scaleByProportion 的 baseValue(对比近三月销量)
priceWeightMaxdouble否价格权重:scaleByProportion 的 returnMax
priceWeightMindouble否价格权重:scaleByProportion 的 returnMin
priceWeightBasedouble否价格权重:scaleByProportion 的 baseValue(对比均价)
finalMultiplierdouble否最终乘数:recyclePrice = sellWeight × priceWeight × finalMultiplier × avgPrice

curl 调用

curl -s 'https://www.8shu8.com/api/recycle/predicate/assessPriceFormula/save' \
  -H 'X-Nideshop-Token: YOUR_LOGIN_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "KV_KEY": "string",
  "minAvgPrice": 0.0,
  "minHalfYearSell": 1,
  "sellWeightMax": 0.0,
  "sellWeightMin": 0.0,
  "sellWeightBase": 0.0,
  "priceWeightMax": 0.0,
  "priceWeightMin": 0.0,
  "priceWeightBase": 0.0,
  "finalMultiplier": 0.0
}'

响应示例

{
  "code": 200,
  "message": "操作成功",
  "success": true,
  "data": "..."
}