WxMaApiUrlConstants.java 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400
  1. package cn.binarywang.wx.miniapp.constant;
  2. import lombok.experimental.UtilityClass;
  3. /**
  4. * 小程序接口地址常量.
  5. *
  6. * @author <a href="https://github.com/binarywang">Binary Wang</a>
  7. * @date 2021-01-28
  8. */
  9. @UtilityClass
  10. public class WxMaApiUrlConstants {
  11. public interface Analysis {
  12. String GET_DAILY_SUMMARY_TREND_URL = "https://api.weixin.qq.com/datacube/getweanalysisappiddailysummarytrend";
  13. String GET_DAILY_VISIT_TREND_URL = "https://api.weixin.qq.com/datacube/getweanalysisappiddailyvisittrend";
  14. String GET_WEEKLY_VISIT_TREND_URL = "https://api.weixin.qq.com/datacube/getweanalysisappidweeklyvisittrend";
  15. String GET_MONTHLY_VISIT_TREND_URL = "https://api.weixin.qq.com/datacube/getweanalysisappidmonthlyvisittrend";
  16. String GET_VISIT_DISTRIBUTION_URL = "https://api.weixin.qq.com/datacube/getweanalysisappidvisitdistribution";
  17. String GET_DAILY_RETAIN_INFO_URL = "https://api.weixin.qq.com/datacube/getweanalysisappiddailyretaininfo";
  18. String GET_WEEKLY_RETAIN_INFO_URL = "https://api.weixin.qq.com/datacube/getweanalysisappidweeklyretaininfo";
  19. String GET_MONTHLY_RETAIN_INFO_URL = "https://api.weixin.qq.com/datacube/getweanalysisappidmonthlyretaininfo";
  20. String GET_VISIT_PAGE_URL = "https://api.weixin.qq.com/datacube/getweanalysisappidvisitpage";
  21. String GET_USER_PORTRAIT_URL = "https://api.weixin.qq.com/datacube/getweanalysisappiduserportrait";
  22. }
  23. public interface Cloud {
  24. String INVOKE_CLOUD_FUNCTION_URL = "https://api.weixin.qq.com/tcb/invokecloudfunction?env=%s&name=%s";
  25. String DATABASE_COLLECTION_GET_URL = "https://api.weixin.qq.com/tcb/databasecollectionget";
  26. String DATABASE_COLLECTION_DELETE_URL = "https://api.weixin.qq.com/tcb/databasecollectiondelete";
  27. String DATABASE_COLLECTION_ADD_URL = "https://api.weixin.qq.com/tcb/databasecollectionadd";
  28. String GET_QCLOUD_TOKEN_URL = "https://api.weixin.qq.com/tcb/getqcloudtoken";
  29. String BATCH_DELETE_FILE_URL = "https://api.weixin.qq.com/tcb/batchdeletefile";
  30. String BATCH_DOWNLOAD_FILE_URL = "https://api.weixin.qq.com/tcb/batchdownloadfile";
  31. String UPLOAD_FILE_URL = "https://api.weixin.qq.com/tcb/uploadfile";
  32. String DATABASE_MIGRATE_QUERY_INFO_URL = "https://api.weixin.qq.com/tcb/databasemigratequeryinfo";
  33. String DATABASE_MIGRATE_EXPORT_URL = "https://api.weixin.qq.com/tcb/databasemigrateexport";
  34. String DATABASE_MIGRATE_IMPORT_URL = "https://api.weixin.qq.com/tcb/databasemigrateimport";
  35. String UPDATE_INDEX_URL = "https://api.weixin.qq.com/tcb/updateindex";
  36. String DATABASE_COUNT_URL = "https://api.weixin.qq.com/tcb/databasecount";
  37. String DATABASE_AGGREGATE_URL = "https://api.weixin.qq.com/tcb/databaseaggregate";
  38. String DATABASE_QUERY_URL = "https://api.weixin.qq.com/tcb/databasequery";
  39. String DATABASE_UPDATE_URL = "https://api.weixin.qq.com/tcb/databaseupdate";
  40. String DATABASE_DELETE_URL = "https://api.weixin.qq.com/tcb/databasedelete";
  41. String DATABASE_ADD_URL = "https://api.weixin.qq.com/tcb/databaseadd";
  42. }
  43. public interface Msg {
  44. String KEFU_MESSAGE_SEND_URL = "https://api.weixin.qq.com/cgi-bin/message/custom/send";
  45. String TEMPLATE_MSG_SEND_URL = "https://api.weixin.qq.com/cgi-bin/message/wxopen/template/send";
  46. String SUBSCRIBE_MSG_SEND_URL = "https://api.weixin.qq.com/cgi-bin/message/subscribe/send";
  47. String UNIFORM_MSG_SEND_URL = "https://api.weixin.qq.com/cgi-bin/message/wxopen/template/uniform_send";
  48. String ACTIVITY_ID_CREATE_URL = "https://api.weixin.qq.com/cgi-bin/message/wxopen/activityid/create";
  49. String UPDATABLE_MSG_SEND_URL = "https://api.weixin.qq.com/cgi-bin/message/wxopen/updatablemsg/send";
  50. }
  51. public interface Code {
  52. /**
  53. * 为授权的小程序帐号上传小程序代码.
  54. */
  55. String COMMIT_URL = "https://api.weixin.qq.com/wxa/commit";
  56. String GET_QRCODE_URL = "https://api.weixin.qq.com/wxa/get_qrcode";
  57. String GET_CATEGORY_URL = "https://api.weixin.qq.com/wxa/get_category";
  58. String GET_PAGE_URL = "https://api.weixin.qq.com/wxa/get_page";
  59. String SUBMIT_AUDIT_URL = "https://api.weixin.qq.com/wxa/submit_audit";
  60. String GET_AUDIT_STATUS_URL = "https://api.weixin.qq.com/wxa/get_auditstatus";
  61. String GET_LATEST_AUDIT_STATUS_URL = "https://api.weixin.qq.com/wxa/get_latest_auditstatus";
  62. String RELEASE_URL = "https://api.weixin.qq.com/wxa/release";
  63. String CHANGE_VISIT_STATUS_URL = "https://api.weixin.qq.com/wxa/change_visitstatus";
  64. String REVERT_CODE_RELEASE_URL = "https://api.weixin.qq.com/wxa/revertcoderelease";
  65. String GET_SUPPORT_VERSION_URL = "https://api.weixin.qq.com/cgi-bin/wxopen/getweappsupportversion";
  66. String SET_SUPPORT_VERSION_URL = "https://api.weixin.qq.com/cgi-bin/wxopen/setweappsupportversion";
  67. String UNDO_CODE_AUDIT_URL = "https://api.weixin.qq.com/wxa/undocodeaudit";
  68. }
  69. public interface Express {
  70. /**
  71. * 获取支持的快递公司列表
  72. */
  73. String ALL_DELIVERY_URL = "https://api.weixin.qq.com/cgi-bin/express/business/delivery/getall";
  74. /**
  75. * 获取所有绑定的物流账号
  76. */
  77. String ALL_ACCOUNT_URL = "https://api.weixin.qq.com/cgi-bin/express/business/account/getall";
  78. /**
  79. * 绑定、解绑物流账号
  80. */
  81. String BIND_ACCOUNT_URL = "https://api.weixin.qq.com/cgi-bin/express/business/account/bind";
  82. /**
  83. * 获取电子面单余额
  84. */
  85. String GET_QUOTA_URL = "https://api.weixin.qq.com/cgi-bin/express/business/quota/get";
  86. /**
  87. * 配置面单打印员
  88. */
  89. String UPDATE_PRINTER_URL = "https://api.weixin.qq.com/cgi-bin/express/business/printer/update";
  90. /**
  91. * 获取打印员
  92. */
  93. String GET_PRINTER_URL = "https://api.weixin.qq.com/cgi-bin/express/business/printer/getall";
  94. /**
  95. * 生成运单
  96. */
  97. String ADD_ORDER_URL = "https://api.weixin.qq.com/cgi-bin/express/business/order/add";
  98. /**
  99. * 批量获取运单数据
  100. */
  101. String BATCH_GET_ORDER_URL = "https://api.weixin.qq.com/cgi-bin/express/business/order/batchget";
  102. /**
  103. * 取消运单
  104. */
  105. String CANCEL_ORDER_URL = "https://api.weixin.qq.com/cgi-bin/express/business/order/cancel";
  106. /**
  107. * 获取运单数据
  108. */
  109. String GET_ORDER_URL = "https://api.weixin.qq.com/cgi-bin/express/business/order/get";
  110. /**
  111. * 查询运单轨迹
  112. */
  113. String GET_PATH_URL = "https://api.weixin.qq.com/cgi-bin/express/business/path/get";
  114. /**
  115. * 模拟快递公司更新订单状态
  116. */
  117. String TEST_UPDATE_ORDER_URL = "https://api.weixin.qq.com/cgi-bin/express/business/test_update_order";
  118. }
  119. public interface ImgProc {
  120. /**
  121. * 二维码/条码识别
  122. */
  123. String QRCODE = "https://api.weixin.qq.com/cv/img/qrcode?img_url=%s";
  124. /**
  125. * 二维码/条码识别(文件)
  126. */
  127. String FILE_QRCODE = "https://api.weixin.qq.com/cv/img/qrcode";
  128. /**
  129. * 图片高清化
  130. */
  131. String SUPER_RESOLUTION = "https://api.weixin.qq.com/cv/img/superresolution?img_url=%s";
  132. /**
  133. * 图片高清化(文件)
  134. */
  135. String FILE_SUPER_RESOLUTION = "https://api.weixin.qq.com/cv/img/superresolution";
  136. /**
  137. * 图片智能裁剪
  138. */
  139. String AI_CROP = "https://api.weixin.qq.com/cv/img/aicrop?img_url=%s&ratios=%s";
  140. /**
  141. * 图片智能裁剪(文件)
  142. */
  143. String FILE_AI_CROP = "https://api.weixin.qq.com/cv/img/aicrop?ratios=%s";
  144. }
  145. public interface Jsapi {
  146. /**
  147. * 获得jsapi_ticket的url
  148. */
  149. String GET_JSAPI_TICKET_URL = "https://api.weixin.qq.com/cgi-bin/ticket/getticket";
  150. }
  151. public interface Broadcast {
  152. String GET_LIVE_INFO = "https://api.weixin.qq.com/wxa/business/getliveinfo";
  153. /**
  154. * 直播间管理相关接口
  155. */
  156. interface Room {
  157. String CREATE_ROOM = "https://api.weixin.qq.com/wxaapi/broadcast/room/create";
  158. String ADD_GOODS = "https://api.weixin.qq.com/wxaapi/broadcast/room/addgoods";
  159. String DELETE_ROOM = "https://api.weixin.qq.com/wxaapi/broadcast/room/deleteroom";
  160. String EDIT_ROOM = "https://api.weixin.qq.com/wxaapi/broadcast/room/editroom";
  161. String GET_PUSH_URL = "https://api.weixin.qq.com/wxaapi/broadcast/room/getpushurl";
  162. String GET_SHARED_CODE = "https://api.weixin.qq.com/wxaapi/broadcast/room/getsharedcode";
  163. String ADD_ASSISTANT = "https://api.weixin.qq.com/wxaapi/broadcast/room/addassistant";
  164. String MODIFY_ASSISTANT = "https://api.weixin.qq.com/wxaapi/broadcast/room/modifyassistant";
  165. String REMOVE_ASSISTANT = "https://api.weixin.qq.com/wxaapi/broadcast/room/removeassistant";
  166. String GET_ASSISTANT_LIST = "https://api.weixin.qq.com/wxaapi/broadcast/room/getassistantlist";
  167. }
  168. /**
  169. * 直播商品管理相关接口
  170. */
  171. interface Goods {
  172. String ADD_GOODS = "https://api.weixin.qq.com/wxaapi/broadcast/goods/add";
  173. String RESET_AUDIT_GOODS = "https://api.weixin.qq.com/wxaapi/broadcast/goods/resetaudit";
  174. String AUDIT_GOODS = "https://api.weixin.qq.com/wxaapi/broadcast/goods/audit";
  175. String DELETE_GOODS = "https://api.weixin.qq.com/wxaapi/broadcast/goods/delete";
  176. String UPDATE_GOODS = "https://api.weixin.qq.com/wxaapi/broadcast/goods/update";
  177. String GET_GOODS_WARE_HOUSE = "https://api.weixin.qq.com/wxa/business/getgoodswarehouse";
  178. String GET_APPROVED_GOODS = "https://api.weixin.qq.com/wxaapi/broadcast/goods/getapproved";
  179. }
  180. /**
  181. * 小程序直播成员管理接口
  182. */
  183. interface Role {
  184. String ADD_ROLE = "https://api.weixin.qq.com/wxaapi/broadcast/role/addrole";
  185. String DELETE_ROLE = "https://api.weixin.qq.com/wxaapi/broadcast/role/deleterole";
  186. String LIST_BY_ROLE = "https://api.weixin.qq.com/wxaapi/broadcast/role/getrolelist";
  187. }
  188. }
  189. public interface Media {
  190. String MEDIA_UPLOAD_URL = "https://api.weixin.qq.com/cgi-bin/media/upload?type=%s";
  191. String MEDIA_GET_URL = "https://api.weixin.qq.com/cgi-bin/media/get";
  192. }
  193. public interface Plugin {
  194. String PLUGIN_URL = "https://api.weixin.qq.com/wxa/plugin";
  195. }
  196. public interface Qrcode {
  197. String CREATE_QRCODE_URL = "https://api.weixin.qq.com/cgi-bin/wxaapp/createwxaqrcode";
  198. String GET_WXACODE_URL = "https://api.weixin.qq.com/wxa/getwxacode";
  199. String GET_WXACODE_UNLIMIT_URL = "https://api.weixin.qq.com/wxa/getwxacodeunlimit";
  200. }
  201. public interface Run {
  202. }
  203. public interface Scheme {
  204. String GENERATE_SCHEME_URL = "https://api.weixin.qq.com/wxa/generatescheme";
  205. }
  206. public interface Link {
  207. String GENERATE_URLLINK_URL = "https://api.weixin.qq.com/wxa/generate_urllink";
  208. }
  209. public interface ShortLink {
  210. String GENERATE_SHORT_LINK_URL = "https://api.weixin.qq.com/wxa/genwxashortlink";
  211. }
  212. public interface SecCheck {
  213. String IMG_SEC_CHECK_URL = "https://api.weixin.qq.com/wxa/img_sec_check";
  214. String MSG_SEC_CHECK_URL = "https://api.weixin.qq.com/wxa/msg_sec_check";
  215. String MEDIA_CHECK_ASYNC_URL = "https://api.weixin.qq.com/wxa/media_check_async";
  216. }
  217. public interface Setting {
  218. /**
  219. * 修改服务器地址:https://open.weixin.qq.com/cgi-bin/showdocument?action=dir_list&t=resource/res_list&verify=1&id=open1489138143_WPbOO&token=&lang=zh_CN
  220. * access_token 为 authorizer_access_token
  221. */
  222. String MODIFY_DOMAIN_URL = "https://api.weixin.qq.com/wxa/modify_domain";
  223. String SET_WEB_VIEW_DOMAIN_URL = "https://api.weixin.qq.com/wxa/setwebviewdomain";
  224. /**
  225. * 小程序成员管理:https://open.weixin.qq.com/cgi-bin/showdocument?action=dir_list&t=resource/res_list&verify=1&id=open1489140588_nVUgx&token=&lang=zh_CN
  226. * access_token 为 authorizer_access_token
  227. */
  228. String BIND_TESTER_URL = "https://api.weixin.qq.com/wxa/bind_tester";
  229. String UNBIND_TESTER_URL = "https://api.weixin.qq.com/wxa/unbind_tester";
  230. }
  231. public interface Share {
  232. }
  233. public interface Subscribe {
  234. /**
  235. * 获取模板标题下的关键词列表.
  236. */
  237. String GET_PUB_TEMPLATE_TITLE_LIST_URL = "https://api.weixin.qq.com/wxaapi/newtmpl/getpubtemplatetitles";
  238. /**
  239. * 获取模板标题下的关键词列表.
  240. */
  241. String GET_PUB_TEMPLATE_KEY_WORDS_BY_ID_URL = "https://api.weixin.qq.com/wxaapi/newtmpl/getpubtemplatekeywords";
  242. /**
  243. * 组合模板并添加至帐号下的个人模板库.
  244. */
  245. String TEMPLATE_ADD_URL = "https://api.weixin.qq.com/wxaapi/newtmpl/addtemplate";
  246. /**
  247. * 获取当前帐号下的个人模板列表.
  248. */
  249. String TEMPLATE_LIST_URL = "https://api.weixin.qq.com/wxaapi/newtmpl/gettemplate";
  250. /**
  251. * 删除帐号下的某个模板.
  252. */
  253. String TEMPLATE_DEL_URL = "https://api.weixin.qq.com/wxaapi/newtmpl/deltemplate";
  254. /**
  255. * 获取小程序账号的类目
  256. */
  257. String GET_CATEGORY_URL = "https://api.weixin.qq.com/wxaapi/newtmpl/getcategory";
  258. /**
  259. * 发送订阅消息
  260. */
  261. String SUBSCRIBE_MSG_SEND_URL = "https://api.weixin.qq.com/cgi-bin/message/subscribe/send";
  262. }
  263. public interface User {
  264. String SET_USER_STORAGE = "https://api.weixin.qq.com/wxa/set_user_storage?appid=%s&signature=%s&openid=%s&sig_method=%s";
  265. }
  266. public interface Ocr {
  267. String IDCARD = "https://api.weixin.qq.com/cv/ocr/idcard?img_url=%s";
  268. String FILEIDCARD = "https://api.weixin.qq.com/cv/ocr/idcard";
  269. String BANK_CARD = "https://api.weixin.qq.com/cv/ocr/bankcard?img_url=%s";
  270. String FILE_BANK_CARD = "https://api.weixin.qq.com/cv/ocr/bankcard";
  271. String DRIVING = "https://api.weixin.qq.com/cv/ocr/driving?img_url=%s";
  272. String FILE_DRIVING = "https://api.weixin.qq.com/cv/ocr/driving";
  273. String DRIVING_LICENSE = "https://api.weixin.qq.com/cv/ocr/drivinglicense?img_url=%s";
  274. String FILE_DRIVING_LICENSE = "https://api.weixin.qq.com/cv/ocr/drivinglicense";
  275. String BIZ_LICENSE = "https://api.weixin.qq.com/cv/ocr/bizlicense?img_url=%s";
  276. String FILE_BIZ_LICENSE = "https://api.weixin.qq.com/cv/ocr/bizlicense";
  277. String COMM = "https://api.weixin.qq.com/cv/ocr/comm?img_url=%s";
  278. String FILE_COMM = "https://api.weixin.qq.com/cv/ocr/comm";
  279. }
  280. public interface Shop {
  281. interface Spu {
  282. String SPU_ADD_URL = "https://api.weixin.qq.com/shop/spu/add";
  283. String SPU_DEL_URL = "https://api.weixin.qq.com/shop/spu/del";
  284. String SPU_GET_URL = "https://api.weixin.qq.com/shop/spu/get";
  285. String SPU_GET_LIST_URL = "https://api.weixin.qq.com/shop/spu/get_list";
  286. String SPU_UPDATE_URL = "https://api.weixin.qq.com/shop/spu/update";
  287. String SPU_UPDATE_WITHOUT_URL = "https://api.weixin.qq.com/shop/spu/update_without_audit";
  288. String SPU_LISTING_URL = "https://api.weixin.qq.com/shop/spu/listing";
  289. String SPU_DELISTING_URL = "https://api.weixin.qq.com/shop/spu/delisting";
  290. String DEL_AUDIT_URL = "https://api.weixin.qq.com/shop/spu/del_audit";
  291. }
  292. interface Order {
  293. String ORDER_CHECK_SCENE = "https://api.weixin.qq.com/shop/scene/check";
  294. String ORDER_ADD = "https://api.weixin.qq.com/shop/order/add";
  295. String ORDER_PAY = "https://api.weixin.qq.com/shop/order/pay";
  296. String ORDER_GET = "https://api.weixin.qq.com/shop/order/get";
  297. }
  298. interface Register {
  299. String REGISTER_APPLY = "https://api.weixin.qq.com/shop/register/apply";
  300. String REGISTER_CHECK = "https://api.weixin.qq.com/shop/register/check";
  301. String REGISTER_FINISH_ACCESS_INFO = "https://api.weixin.qq.com/shop/register/finish_access_info";
  302. String REGISTER_APPLY_SCENE = "https://api.weixin.qq.com/shop/register/apply_scene";
  303. }
  304. interface Account {
  305. String GET_CATEGORY_LIST = "https://api.weixin.qq.com/shop/account/get_category_list";
  306. String GET_BRAND_LIST = "https://api.weixin.qq.com/shop/account/get_brand_list";
  307. String UPDATE_INFO = "https://api.weixin.qq.com/shop/account/update_info";
  308. String GET_INFO = "https://api.weixin.qq.com/shop/account/get_info";
  309. }
  310. interface Cat {
  311. String GET_CAT = "https://api.weixin.qq.com/shop/cat/get";
  312. }
  313. interface Img {
  314. String IMG_UPLOAD = "https://api.weixin.qq.com/shop/img/upload";
  315. }
  316. interface Audit {
  317. String AUDIT_BRAND = "https://api.weixin.qq.com/shop/audit/audit_brand";
  318. String AUDIT_CATEGORY = "https://api.weixin.qq.com/shop/audit/audit_category";
  319. String AUDIT_RESULT = "https://api.weixin.qq.com/shop/audit/result";
  320. String GET_MINIAPP_CERTIFICATE = "https://api.weixin.qq.com/shop/audit/get_miniapp_certificate";
  321. }
  322. interface Delivery {
  323. String GET_COMPANY_LIST = "https://api.weixin.qq.com/shop/delivery/get_company_list";
  324. String DELIVERY_SEND = "https://api.weixin.qq.com/shop/delivery/send";
  325. String DELIVERY_RECEIVE = "https://api.weixin.qq.com/shop/delivery/recieve";
  326. }
  327. interface Aftersale {
  328. String AFTERSALE_ADD = "https://api.weixin.qq.com/shop/aftersale/add";
  329. String AFTERSALE_GET = "https://api.weixin.qq.com/shop/aftersale/get";
  330. String AFTERSALE_UPDATE = "https://api.weixin.qq.com/shop/aftersale/update";
  331. }
  332. }
  333. /**
  334. * 电子发票报销方
  335. */
  336. public interface Invoice{
  337. /**
  338. * 报销方查询报销发票信息
  339. */
  340. String GET_INVOICE_INFO = "https://api.weixin.qq.com/card/invoice/reimburse/getinvoiceinfo";
  341. /**
  342. * 报销方批量查询报销发票信息
  343. */
  344. String GET_INVOICE_BATCH = "https://api.weixin.qq.com/card/invoice/reimburse/getinvoicebatch";
  345. /**
  346. * 报销方更新发票状态
  347. */
  348. String UPDATE_INVOICE_STATUS = "https://api.weixin.qq.com/card/invoice/reimburse/updateinvoicestatus";
  349. /**
  350. * 报销方批量更新发票状态
  351. */
  352. String UPDATE_STATUS_BATCH = "https://api.weixin.qq.com/card/invoice/reimburse/updatestatusbatch";
  353. }
  354. public interface Internet{
  355. String GET_USER_ENCRYPT_KEY = "https://api.weixin.qq.com/wxa/business/getuserencryptkey";
  356. }
  357. }