vivo付费

This commit is contained in:
kuang.yife 2023-11-20 17:51:02 +08:00
parent 61d7556e6d
commit 7f2af57d39
1 changed files with 11 additions and 0 deletions

View File

@ -168,6 +168,17 @@ public class ClewController extends BaseController
log.info("请求https://api.ads.heytapmobi.com/api/uploadActiveData的属性{}", JSONObject.toJSONString(oppoCheck));
String s = HttpUtils.sendPost("https://api.ads.heytapmobi.com/api/uploadActiveData", JSONObject.toJSONString(oppoCheck), headerMap);
log.info("请求https://api.ads.heytapmobi.com/api/uploadActiveData的响应{}", s);
}else if("vivo".equalsIgnoreCase(clew.getRemark())){
String token = "78c0170798cf83a7f79ce8fcb5eba68f3329b0e94967686917efcb1dc37e336f";
String timeStamp = System.currentTimeMillis() + "";
String notice = "VIVO"+ (long)((Math.random()+1) * 10000000);
String url = "https://marketing-api.vivo.com.cn/openapi/v1/advertiser/behavior/upload?access_token="+token+"&timestamp="+timeStamp+"&nonce="+notice;
String content = "{\"dataList\":[{\"cvTime\":"+timeStamp+",\"cvType\":\"PAY\",\"userId\":\""+ clew.getOaid() +"\",\"userIdType\":\"OAID\"}],\"pkgName\":\"com.yinliu.loan\",\"srcId\":\"ds-202310270565\",\"srcType\":\"app\"}";
Map<String, String> headerMap = new HashMap<>();
headerMap.put("Content-Type", "application/json");
log.info("请求{}的属性{}", url, content);
String s = HttpUtils.sendPost(url, content, headerMap);
log.info("请求{}的响应{}", url, s);
}
}catch (Exception e){
e.printStackTrace();