| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586 |
- package com.cyksj.service.wechat;
- import com.cyksj.model.dto.*;
- import com.cyksj.model.response.WxGzhQrCodeTicketRep;
- import java.math.BigDecimal;
- import java.util.Date;
- import java.util.Map;
- public interface WeChatService {
- String createUrl(String state, String redirectUrl);
- String createUrl(String state, String redirectUrl, String appId, String scope);
- AuthToken getAuthToken(String code) throws Exception;
- AuthToken getAuthToken(String code, String appId) throws Exception;
- String getJsTicket() throws Exception;
- String getJsTicket(String appId) throws Exception;
- GzhOAuth2UserInfo getUserInfo(String accessToken, String openid) throws Exception;
- /**
- * 通过公众号的access_token 获取用户基本信息
- */
- GzhUnionidUserinfo getUserInfo2(String accessToken, String openid) throws Exception;
- String getAccessToken() throws Exception;
- String getAccessToken(String appId) throws Exception;
- /**
- * 统一订单
- *
- * @param appid 微信应用唯一id
- * @param openid 微信的用户标识
- * @param totalFee 订单总金额 单位为分
- * @param outTradeNo 订单批次号 一次支付对应一条订单批次号 可以包含多条购物记录(订单)
- * @param notifyUrl 通知地址
- * /@param attach 传入订单id 在查询API和支付通知中原样返回 用于处理订单
- * @return h5调用微信js-sdk必要的参数
- */
- H5JsPayParams getJsPayParams(String appid, String shopId,String openid, Integer totalFee, String outTradeNo, String notifyUrl, String attach, String body, String tradeType, Date ExpiryTime) throws Exception;
- /* 微信签名算法 */
- boolean checkSignWithMd5(Map<String, String> map) throws Exception;
- boolean checkSignWithMd5(Map<String, String> map, String shopKey) throws Exception;
- H5PayParams getH5PayParams(String appid, Integer totalFee, String outTradeNo, String notifyUrl, String attach, String ip, String body) throws Exception;
- /**
- * 发送模板消息 单对象
- *
- * @param accessToken WechatCache.getAccessToken()
- * @param json 消息json
- */
- void sendTemplateMessage(String accessToken, String json) throws Exception;
- /**
- * @param appId 应用id
- * @param transactionId 微信支付订单号
- * @param outRefundNo 商户退款单号
- * @param totalFee 订单金额 单位为分,只能为整数
- * @param refundMoney 退款金额
- */
- void refundWxOrder(String appId, String shopId, String transactionId, String outRefundNo, BigDecimal totalFee, BigDecimal refundMoney, String notifyUrl) throws Exception;
- /**
- * 获取公众号带参数的临时二维码
- * @return
- */
- WxGzhQrCodeTicketRep getWxGzhQrCode(Long sharedId, Integer dsType, Long popularizeId) throws Exception;
- /**
- * 获取公众号带参数的永久二维码
- */
- String getNotExpiredWxGzhQrCode(String sceneKey) throws Exception;
- }
|