注:创建微信小程序卡券部分可见 卡券接口文档
 
 
小程序在线学习平台:http://school.jisuapp.cn/ 
小程序&卡券打通1 打通主要支持特性 支持在小程序中领取/查看/使用公众号AppId创建的会员卡、票、券(含通用卡)。  
 2 商家需要做什么 2.2. 原卡券中配置的自定义外链基础上新增一组小程序页面配置字段,支持将卡券内链接升级为小程序; 2.3. 以小程序AppId调用添加/查看卡券JS-API,签名参数与公众号Addcard/Opencard JS-SDK一致; 2.4. 核销卡券、数据查看保持现网路径,商家无需调整。   3 商家接入落地的接口内容 3.1. 创建接口/更新卡券信息接口base_info中新增进入小程序页面字段,商家需将小程序字段配置进原自定义外链结构体中,小程序页面新增字段示例如下: [mw_shl_code=applescript,true]{ "card": { 
    "card_type": "MEMBER_CARD", 
    "member_card": { 
        "base_info": { 
            "custom_url_name": "立即使用", 
            "custom_url": "http://www.qq.com", 
            "custom_app_brand_user_name": "gh_86a091e50ad4@app", 
            "custom_app_brand_pass":"API/cardPage", 
            "custom_url_sub_title": "6个汉字tips", 
            "promotion_url_name": "更多优惠", 
          "promotion_url": "http://www.qq.com", 
            "promotion_app_brand_user_name": "gh_86a091e50ad4@app", 
            "promotion_app_brand_pass":"API/cardPage"        } 
        } 
}[/mw_shl_code] 字段名  |  |  |  custom_app_brand_user_name  | 自定义使用入口跳转小程序的user_name,格式为原始id+@app  |  |   |  |  |  center_app_brand_user_name  |  |  |   |  |  |  promotion_app_brand_user_name  |  |  |   |  |  |  activate_app_brand_user_name  |  |  |   |  |  |   | --  | --  |  
 *需调用卡券更新接口将相应小程序页面更新至对应跳转外链结构体中,原跳转H5字段保留。   3.2. 领取/查看卡券的接口参数不变,以小程序的AppId调用JSSDK,填入公众号AppId下的参数。查看接口文档。 [mw_shl_code=applescript,true]// 微信低版本下尚未支持小程序卡券 wx.addCard, wx.openCard, 
// 这两个接口调用前请先判断,示例: 
if ( typeof wx.addCard === 'function' ) { 
            wx.addCard({ 
                cardList: [{ 
                        cardId: '', 
                        cardExt: '' 
                                           }], // 需要添加的卡券列表,cardExt内的签名使用公众号appid获取 
                success: function (res) { 
                               var cardList = res.cardList; // 添加的卡券列表信息 
                                        } 
                                   })};[/mw_shl_code]  
 
 
 
 |