/// <summary> /// 创建二维码接口 /// </summary> public CreateQRCodeResult CreateQRCode(CreareQRCodeRequest model) { var url = GetAccessApiUrl("create", "card/qrcode", "https://api.weixin.qq.com"); var result = Post <CreateQRCodeResult>(url, model); return(result); }
public void CreateQRCode() { var CreateQRCodeRequest = new CreareQRCodeRequest() { ActionName = "QR_CARD", ActionInfo = new ActionInfo() { CardInfo = new QRCardInfo() { CardId = "pl0uwwXdAIetRFMDxLlsoqRlBJac", Outer_str = "test" } } }; var result = _weChatApi.CreateQRCode(CreateQRCodeRequest); if (!result.IsSuccess()) { Assert.Fail("创建二维码失败,返回结果如下:" + result.DetailResult + ";Msg:" + result.GetFriendlyMessage()); } }