CdfClient.java 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. package com.cdf.httpClient.client;
  2. import com.alibaba.fastjson.JSONObject;
  3. import com.cdf.httpClient.response.cdf.CdfProductListRequest;
  4. import com.cdf.httpClient.response.cdf.CdfProductListResponse;
  5. import com.cdf.httpClient.response.cdf.CdfProductVo;
  6. import com.dtflys.forest.annotation.*;
  7. @Address(basePath = "https://m.cdfmembers.com")
  8. public interface CdfClient {
  9. /**
  10. * 获取商品详情
  11. */
  12. @Get(url = "/api/prod/sqdetail?productId=${productId}",
  13. headers = {
  14. "app-key: h5sqBuyer_600667208",
  15. "app-version: 6.6.88",
  16. })
  17. CdfProductVo getProductById(@Var("productId") String productId);
  18. /**
  19. * 根据关键字搜索商品列表
  20. */
  21. @Post(url = "/api/nodesearch/sqsearch",
  22. headers = {
  23. "app-key: h5sqBuyer_600667208",
  24. "app-version: 6.6.88",
  25. })
  26. CdfProductListResponse getProductList(@JSONBody CdfProductListRequest param);
  27. /**
  28. * 查询购物车数量
  29. */
  30. @Get(url = "/api/trading/sqscartprodnum",
  31. headers = {
  32. "app-key: h5sqBuyer_600667208",
  33. "app-version: 6.6.88",
  34. "ymt-pars: appid=71&accesstoken=C10DBE77A888E4592F2EBAEDC252C0A4279DF95858B3DBBF271513CE83F44FE90E39CC0AA7E08823D671F0A359B2AE8971A3DDAEFCC522A7&mchId=600667208&language=zh_CN&format=json",
  35. })
  36. JSONObject getCatNum();
  37. }