第三方api接口
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

model.go 3.5 KiB

1 year ago
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. package jd
  2. // 1-好券商品,2-精选卖场,10-9.9包邮,15-京东配送,22-实时热销榜,23-为你推荐,24-数码家电,25-超市,26-母婴玩具,27-家具日用,28-美妆穿搭,29-医药保健,30-图书文具,31-今日必推,32-京东好物,33-京东秒杀,34-拼购商品,40-高收益榜,41-自营热卖榜,109-新品首发,110-自营,112-京东爆品,125-首购商品,129-高佣榜单,130-视频商品,153-历史最低价商品榜
  3. // 排序字段(price:单价, commissionShare:佣金比例, commission:佣金, inOrderCount30DaysSku:sku维度30天引单量,comments:评论数,goodComments:好评数)
  4. //RequestJD is 请求 京东sdk的参数
  5. type RequestJD struct {
  6. PageIndex int `json:"page_index"`
  7. PageSize int `json:"page_size"`
  8. EliteID int `json:"elite_id"`
  9. SortName string `json:"sort_name"`
  10. UserIDType int `json:"userid_type"`
  11. UserID string `json:"user_id"`
  12. }
  13. // JDFeaturedResponse is return from taoke.jd
  14. type JDFeaturedResponse struct {
  15. JdUnionOpenGoodsJingfenQueryResponse struct {
  16. Code string `json:"code"`
  17. Result string `json:"result"`
  18. } `json:"jd_union_open_goods_jingfen_query_response"`
  19. }
  20. // JDFeature is jd 精选 for微信
  21. type JDFeature struct {
  22. BrandCode string `json:"brandCode"`
  23. BrandName string `json:"brandName"`
  24. CategoryInfo struct {
  25. Cid1 int `json:"cid1"`
  26. Cid1Name string `json:"cid1Name"`
  27. Cid2 int `json:"cid2"`
  28. Cid2Name string `json:"cid2Name"`
  29. Cid3 int `json:"cid3"`
  30. Cid3Name string `json:"cid3Name"`
  31. } `json:"categoryInfo"`
  32. Comments int `json:"comments"`
  33. CommissionInfo struct {
  34. Commission float64 `json:"commission"`
  35. CommissionShare float64 `json:"commissionShare"`
  36. CouponCommission float64 `json:"couponCommission"`
  37. PlusCommissionShare float64 `json:"plusCommissionShare"`
  38. } `json:"commissionInfo"`
  39. CouponInfo struct {
  40. CouponList []struct {
  41. BindType int `json:"bindType"`
  42. Discount float64 `json:"discount"`
  43. GetEndTime int64 `json:"getEndTime"`
  44. GetStartTime int64 `json:"getStartTime"`
  45. HotValue int `json:"hotValue"`
  46. IsBest int `json:"isBest"`
  47. Link string `json:"link"`
  48. PlatformType int `json:"platformType"`
  49. Quota float64 `json:"quota"`
  50. UseEndTime int64 `json:"useEndTime"`
  51. UseStartTime int64 `json:"useStartTime"`
  52. } `json:"couponList"`
  53. } `json:"couponInfo"`
  54. GoodCommentsShare float64 `json:"goodCommentsShare"`
  55. ImageInfo struct {
  56. ImageList []struct {
  57. URL string `json:"url"`
  58. } `json:"imageList"`
  59. } `json:"imageInfo"`
  60. InOrderCount30Days int `json:"inOrderCount30Days"`
  61. InOrderCount30DaysSku int `json:"inOrderCount30DaysSku"`
  62. IsHot int `json:"isHot"`
  63. MaterialURL string `json:"materialUrl"`
  64. Owner string `json:"owner"`
  65. PinGouInfo struct {
  66. } `json:"pinGouInfo"`
  67. PriceInfo struct {
  68. LowestCouponPrice float64 `json:"lowestCouponPrice"`
  69. LowestPrice float64 `json:"lowestPrice"`
  70. LowestPriceType int `json:"lowestPriceType"`
  71. Price float64 `json:"price"`
  72. } `json:"priceInfo"`
  73. ResourceInfo struct {
  74. EliteID int `json:"eliteId"`
  75. EliteName string `json:"eliteName"`
  76. } `json:"resourceInfo"`
  77. ShopInfo struct {
  78. ShopID int `json:"shopId"`
  79. ShopLevel float64 `json:"shopLevel"`
  80. ShopName string `json:"shopName"`
  81. } `json:"shopInfo"`
  82. SkuID int64 `json:"skuId"`
  83. SkuName string `json:"skuName"`
  84. Spuid int64 `json:"spuid"`
  85. }