ASNetApis.h 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. //
  2. // ASNetApis.h
  3. // Asteria
  4. //
  5. // Created by iOS on 2023/11/25.
  6. //
  7. #ifndef ASNetApis_h
  8. #define ASNetApis_h
  9. #define BaseRequestrUrl(url) ([NSString stringWithFormat:@"%@%@",@"rest/V1/",url])
  10. #define BaseWebUrl(url) ([NSString stringWithFormat:@"%@%@",@"rest/V1/",url])
  11. // MARK: - host
  12. #if (DEBUG)
  13. //#define HostPath @"www.bilisar.com"//@"https://www.bilisar.com/" //测试
  14. #define HostPath @"pc.bilisar.com" //正式
  15. #else
  16. #define HostPath @"pc.bilisar.com"//@"https://pc.bilisar.com/" //正式
  17. #endif
  18. // MARK: - path
  19. #define ProductImgPath @"/media/catalog/product"
  20. #define CategoryImgPath @"/media/catalog/category/"
  21. // MARK: - 商品列表
  22. #define getProductListUrl BaseRequestrUrl(@"rewrite/categories/%@/products")
  23. // MARK: - 货币
  24. #define getAllCurrencyUrl BaseRequestrUrl(@"directory/currency")
  25. // MARK: - 分类列表
  26. #define getAllCategoriesUrl BaseRequestrUrl(@"rewrite/categories")
  27. // 热词
  28. #define getHotList BaseRequestrUrl(@"hot/index")
  29. // MARK: - userinfo
  30. #define registerUrl BaseRequestrUrl(@"customers")
  31. #define loginUrl BaseRequestrUrl(@"integration/customer/token")
  32. #define userinfoUrl BaseRequestrUrl(@"customers/me")
  33. #define vipInfoUrl BaseRequestrUrl(@"vip/index")
  34. #define userBirthUrl BaseRequestrUrl(@"vip/birthday")
  35. // MARK: - 修改用户信息
  36. #define putUserInfo BaseRequestrUrl(@"customers/me")
  37. #define putUserPassword BaseRequestrUrl(@"customers/me/password")
  38. //MARK: - 个人中心
  39. #define postLogOut BaseRequestrUrl(@"integration/customer/revoke-customer-token")
  40. #define getSignStateUrl BaseRequestrUrl(@"sign/index")
  41. #define postSignUrl BaseRequestrUrl(@"sign/add")
  42. // MARK: 优惠券/礼品卡
  43. #define getUserCouponUrl BaseRequestrUrl(@"coupon/index")
  44. #define getUserGiftCardUrl BaseRequestrUrl(@"gift/index")
  45. // vip 优惠券
  46. #define getVipCouponUrl BaseRequestrUrl(@"vip/coupon")
  47. #define postAddVipCoupon BaseRequestrUrl(@"coupon/add")
  48. // MARK: 积分
  49. #define getPointsDetailUrl BaseRequestrUrl(@"points/index")
  50. #define getExtraPoints BaseRequestrUrl(@"points/show")
  51. #define postTakeExtraPoints BaseRequestrUrl(@"points/more")
  52. #endif /* ASNetApis_h */