|
@@ -1780,6 +1780,36 @@ public class BatchServiceImpl implements IBatchService {
|
|
|
}
|
|
|
|
|
|
|
|
|
+ /**
|
|
|
+ * 获取可选的贴纸样式
|
|
|
+ *
|
|
|
+ * @param accountId
|
|
|
+ * @param accessToken
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ @Override
|
|
|
+ public JSONArray getCreativeWordStyles(Long accountId, String accessToken) {
|
|
|
+ String url = "https://ad.e.kuaishou.com/rest/openapi/v1/tool/creative_word/styles";
|
|
|
+ Map<String, String> headers = new HashMap<String, String>();
|
|
|
+ headers.put("Content-Type", "application/json");
|
|
|
+ headers.put("Access-Token", accessToken);
|
|
|
+ Map<String, Object> param = new HashMap<String, Object>();
|
|
|
+ param.put("advertiser_id", accountId);
|
|
|
+
|
|
|
+ String result = HttpUtils.httpPostRequest(url, param, headers);
|
|
|
+ JSONObject resultJson = JSONObject.parseObject(result);
|
|
|
+ log.info("获取贴纸样式,accountId:{},data:{}", accountId, resultJson);
|
|
|
+ if (!Check.isNull(resultJson)) {
|
|
|
+ Integer code = resultJson.getInteger("code");
|
|
|
+ if (code == 0) {
|
|
|
+ return resultJson.getJSONArray("data");
|
|
|
+ }
|
|
|
+
|
|
|
+ }
|
|
|
+ return null;
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
}
|
|
|
|
|
|
|