营销活动送红包之触发现金红包活动(alipay.marketing.campaign.cash.trigger)-java版

说明: 本帖是测试营销活动送红包的触发现金红包活动接口,本帖是使用沙箱环境测试的,仅供参考!!

是否需要签约:需要【如何签约】 

是否支持沙箱环境:支持

接口文档:查看 

sdk下载:下载 

营销活动送红包沙箱Java版demo:download:营销活动送红包Java版.zip

1.代码请求示例:

AlipayClient alipayClient = new DefaultAlipayClient(AlipayConfig.URL ,AlipayConfig.APPID,AlipayConfig.RSA_PRIVATE_KEY,"json",AlipayConfig.CHARSET,AlipayConfig.ALIPAY_PUBLIC_KEY,AlipayConfig.Sign_Type);

     AlipayMarketingCampaignCashTriggerRequest request = new AlipayMarketingCampaignCashTriggerRequest();
      
    request.setBizContent("{" +
        ""user_id":"2088102174701092"," +
        ""crowd_no":"eHPLr-8bu0Y38JNVd3gldY4e50c_CcaYsm039bIsTafMnSZ96O-zxUfKlHp5cxmx"," +
        ""login_id":"dvnvqi3054@sandbox.com"," +
        ""order_price":"1"," +
        ""out_biz_no":"20180210145831454"" +
        "}");
   AlipayMarketingCampaignCashTriggerResponse response = alipayClient.execute(request);
             
         if(response.isSuccess()){
           System.out.println("调用成功");
      } else {
           System.out.println("调用失败");
      }
         System.out.println(response.getBody());//打印完整的响应报文信息
  
    }

2.请求成功返回信息示例:

调用成功
{"alipay_marketing_campaign_cash_trigger_response":{"code":"10000","msg":"Success","biz_no":"20180508110070001502090000070793","coupon_name":"煜雨创建营销活动送红包","out_biz_no":"2018021014584545454","partner_id":"2088102170119260","prize_amount":"0.02","prize_msg":"煜雨小哥哥在测试","repeat_trigger_flag":"false","trigger_result":"true"},"sign":"XXX"}
					

3.钱包中可查询红包的账单信息:

红包说明是固定格式:沙箱环境是:沙箱环境-现金红包;正式环境是:公司名称-现金红包

营销活动送红包之触发现金红包活动(alipay.marketing.campaign.cash.trigger)-java版营销活动送红包之触发现金红包活动(alipay.marketing.campaign.cash.trigger)-java版

               沙箱环境账单                                                正式环境账单

4.参数说明

1>.crowd_no参数值是通过创建现金活动接口([url]https://openclub.alipay.com/read.php?tid=5278&fid=72[/url]获取的

2>.user_idlogin_id参数都是领红包的用户的信息

正确的提问方式:

  appid+使用环境(正式/沙箱)+调用接口时间+请求参数(提供信息不完整不回复,谢谢配合)

如果您在接入该接口还有疑问欢迎在本帖下方追问吐槽营销活动送红包之触发现金红包活动(alipay.marketing.campaign.cash.trigger)-java版

上一篇:Javascript设置对象的ReadOnly属性


下一篇:寒假充电季,防疫不停学!参与Alibaba Java技术图谱21天打卡活动,赢多重好礼!