|
@@ -7,12 +7,9 @@ import cn.com.ctop.kuaishou.modules.material.entity.KuaishouResultToken;
|
|
import cn.com.ctop.kuaishou.modules.report.entity.*;
|
|
import cn.com.ctop.kuaishou.modules.report.entity.*;
|
|
import com.alibaba.fastjson.JSONArray;
|
|
import com.alibaba.fastjson.JSONArray;
|
|
import com.alibaba.fastjson.JSONObject;
|
|
import com.alibaba.fastjson.JSONObject;
|
|
-import org.springframework.web.multipart.MultipartFile;
|
|
|
|
|
|
|
|
-import javax.servlet.http.HttpServletRequest;
|
|
|
|
import java.text.ParseException;
|
|
import java.text.ParseException;
|
|
import java.util.Date;
|
|
import java.util.Date;
|
|
-import java.util.List;
|
|
|
|
import java.util.Map;
|
|
import java.util.Map;
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -20,24 +17,92 @@ import java.util.Map;
|
|
* 2019年11月12日11:08:52
|
|
* 2019年11月12日11:08:52
|
|
*/
|
|
*/
|
|
public interface IKuaishouInterfaceService {
|
|
public interface IKuaishouInterfaceService {
|
|
- KuaishouResult<KuaishouReportHourlyAccount> getAccountHourlyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
|
|
-
|
|
|
|
- KuaishouResult<KuaishouReportDailyAccount> getAccountDailyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 计划日报
|
|
|
|
+ *
|
|
|
|
+ * @param accessToken
|
|
|
|
+ * @param advertiserId
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ * @param pageSize
|
|
|
|
+ * @param pageNum
|
|
|
|
+ * @return
|
|
|
|
+ */
|
|
KuaishouResult<KuaishouReportDailyCampaign> getCampaignDailyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
KuaishouResult<KuaishouReportDailyCampaign> getCampaignDailyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 计划时报
|
|
|
|
+ *
|
|
|
|
+ * @param accessToken
|
|
|
|
+ * @param advertiserId
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ * @param pageSize
|
|
|
|
+ * @param pageNum
|
|
|
|
+ * @return
|
|
|
|
+ */
|
|
KuaishouResult<KuaishouReportHourlyCampaign> getCampaignHourlyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
KuaishouResult<KuaishouReportHourlyCampaign> getCampaignHourlyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 组日报
|
|
|
|
+ *
|
|
|
|
+ * @param accessToken
|
|
|
|
+ * @param advertiserId
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ * @param pageSize
|
|
|
|
+ * @param pageNum
|
|
|
|
+ * @return
|
|
|
|
+ */
|
|
KuaishouResult<KuaishouReportDailyGroup> getGroupDailyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
KuaishouResult<KuaishouReportDailyGroup> getGroupDailyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 组时报
|
|
|
|
+ *
|
|
|
|
+ * @param accessToken
|
|
|
|
+ * @param advertiserId
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ * @param pageSize
|
|
|
|
+ * @param pageNum
|
|
|
|
+ * @return
|
|
|
|
+ */
|
|
KuaishouResult<KuaishouReportHourlyGroup> getGroupHourlyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
KuaishouResult<KuaishouReportHourlyGroup> getGroupHourlyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 创意日报 暂停使用
|
|
|
|
+ *
|
|
|
|
+ * @param accessToken
|
|
|
|
+ * @param advertiserId
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ * @param pageSize
|
|
|
|
+ * @param pageNum
|
|
|
|
+ * @return
|
|
|
|
+ */
|
|
KuaishouResult<KuaishouReportDailyCreative> getCreativeDailyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
KuaishouResult<KuaishouReportDailyCreative> getCreativeDailyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 创意时报 暂停使用
|
|
|
|
+ *
|
|
|
|
+ * @param accessToken
|
|
|
|
+ * @param advertiserId
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ * @param pageSize
|
|
|
|
+ * @param pageNum
|
|
|
|
+ * @return
|
|
|
|
+ */
|
|
KuaishouResult<KuaishouReportHourlyCreative> getCreativeHourlyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
KuaishouResult<KuaishouReportHourlyCreative> getCreativeHourlyReport(String accessToken, Long advertiserId, String startDate, String endDate, int pageSize, int pageNum);
|
|
|
|
|
|
- void loadAllKuaishouData(List<CtopOauthToken> tokens);
|
|
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取历史数据
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @throws ParseException
|
|
|
|
+ */
|
|
void loadKuaishouDataSingle(CtopOauthToken token) throws ParseException;
|
|
void loadKuaishouDataSingle(CtopOauthToken token) throws ParseException;
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -63,15 +128,6 @@ public interface IKuaishouInterfaceService {
|
|
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
- * 获取广告计划信息 全量
|
|
|
|
- *
|
|
|
|
- * @param accessToken
|
|
|
|
- * @param advertiserId
|
|
|
|
- */
|
|
|
|
- void getCampaignList(String accessToken, Long advertiserId, Date startDate, Date endDate, Integer page);
|
|
|
|
-
|
|
|
|
-
|
|
|
|
- /**
|
|
|
|
* 获取广告计划信息 单条
|
|
* 获取广告计划信息 单条
|
|
*
|
|
*
|
|
* @param accessToken
|
|
* @param accessToken
|
|
@@ -79,14 +135,6 @@ public interface IKuaishouInterfaceService {
|
|
*/
|
|
*/
|
|
void getCampaign(String accessToken, Long advertiserId, Long campaignId);
|
|
void getCampaign(String accessToken, Long advertiserId, Long campaignId);
|
|
|
|
|
|
- /**
|
|
|
|
- * 获取广告组信息 全量
|
|
|
|
- *
|
|
|
|
- * @param accessToken
|
|
|
|
- * @param advertiserId
|
|
|
|
- * @param page
|
|
|
|
- */
|
|
|
|
- void getGroupList(String accessToken, Long advertiserId, Date startDate, Date endDate, Integer page);
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
* 获取广告组信息 单条
|
|
* 获取广告组信息 单条
|
|
@@ -98,17 +146,24 @@ public interface IKuaishouInterfaceService {
|
|
void getGroup(String accessToken, Long advertiserId, Long unitId);
|
|
void getGroup(String accessToken, Long advertiserId, Long unitId);
|
|
|
|
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取创意列表
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ */
|
|
void getCreativeList(CtopOauthToken token, Date startDate, Date endDate);
|
|
void getCreativeList(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
|
|
- void getVideoInfo(String accessToken, Long advertiserId, String photoId);
|
|
|
|
-
|
|
|
|
/**
|
|
/**
|
|
- * 获取创意信息
|
|
|
|
|
|
+ * 获取视频信息
|
|
*
|
|
*
|
|
* @param accessToken
|
|
* @param accessToken
|
|
* @param advertiserId
|
|
* @param advertiserId
|
|
|
|
+ * @param photoId
|
|
*/
|
|
*/
|
|
- void getCreativeList(String accessToken, Long advertiserId, Date startDate, Date endDate, Integer page);
|
|
|
|
|
|
+ void getVideoInfo(String accessToken, Long advertiserId, String photoId);
|
|
|
|
+
|
|
|
|
|
|
/**
|
|
/**
|
|
* 获取token
|
|
* 获取token
|
|
@@ -127,6 +182,13 @@ public interface IKuaishouInterfaceService {
|
|
*/
|
|
*/
|
|
Map<String, Object> getDeepConversionInfos(Long advertiserId, String accessToken);
|
|
Map<String, Object> getDeepConversionInfos(Long advertiserId, String accessToken);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 取可选的深度转化类型
|
|
|
|
+ *
|
|
|
|
+ * @param advertiserId
|
|
|
|
+ * @param accessToken
|
|
|
|
+ * @return
|
|
|
|
+ */
|
|
JSONObject getDeepConversionInfosV2(Long advertiserId, String accessToken);
|
|
JSONObject getDeepConversionInfosV2(Long advertiserId, String accessToken);
|
|
|
|
|
|
|
|
|
|
@@ -139,7 +201,14 @@ public interface IKuaishouInterfaceService {
|
|
*/
|
|
*/
|
|
Map<String, Object> creativeCreate(String accessToken, Long advertiserId, JSONObject requestJson);
|
|
Map<String, Object> creativeCreate(String accessToken, Long advertiserId, JSONObject requestJson);
|
|
|
|
|
|
- void getCreativeByCreativeId(String accessToken, Long advertiserId, Date startDate, Date endDate, Integer page, Long creativeId);
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 根据创意id 获取创意信息
|
|
|
|
+ *
|
|
|
|
+ * @param accessToken
|
|
|
|
+ * @param advertiserId
|
|
|
|
+ * @param creativeId
|
|
|
|
+ */
|
|
|
|
+ void getCreativeByCreativeId(String accessToken, Long advertiserId, Long creativeId);
|
|
|
|
|
|
/**
|
|
/**
|
|
* 文件上传
|
|
* 文件上传
|
|
@@ -216,17 +285,6 @@ public interface IKuaishouInterfaceService {
|
|
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
- * 修改应用
|
|
|
|
- *
|
|
|
|
- * @param advertiserId
|
|
|
|
- * @param accessToken
|
|
|
|
- * @param requestJson
|
|
|
|
- * @param multipartFile
|
|
|
|
- * @param request
|
|
|
|
- */
|
|
|
|
- void appUpdate(Long advertiserId, String accessToken, JSONObject requestJson, MultipartFile multipartFile, HttpServletRequest request);
|
|
|
|
-
|
|
|
|
- /**
|
|
|
|
* 创建 url应用
|
|
* 创建 url应用
|
|
*
|
|
*
|
|
* @param accountId
|
|
* @param accountId
|
|
@@ -245,59 +303,117 @@ public interface IKuaishouInterfaceService {
|
|
*/
|
|
*/
|
|
Map<String, Object> advertiserInfo(Long accountId, String accessToken);
|
|
Map<String, Object> advertiserInfo(Long accountId, String accessToken);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取视频列表
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ */
|
|
void getVideoList(CtopOauthToken token, Date startDate, Date endDate);
|
|
void getVideoList(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
|
|
- void getVideoList(String token, Long advertiserId, Date startDate, Date endDate, int page);
|
|
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取广告主分天报表
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ */
|
|
void getAdvertiserReportDaily(CtopOauthToken token, Date startDate, Date endDate);
|
|
void getAdvertiserReportDaily(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取计划分天报表
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ */
|
|
void getAdvertiserCampaignReportDaily(CtopOauthToken token, Date startDate, Date endDate);
|
|
void getAdvertiserCampaignReportDaily(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取广告计划分天报表 暂停使用
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ */
|
|
void getAdvertiserGroupReportDaily(CtopOauthToken token, Date startDate, Date endDate);
|
|
void getAdvertiserGroupReportDaily(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取创意分天报表 暂停使用
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ * @param campaignIds
|
|
|
|
+ */
|
|
void getAdvertiserCreativeReportDaily(CtopOauthToken token, Date startDate, Date endDate, JSONArray campaignIds);
|
|
void getAdvertiserCreativeReportDaily(CtopOauthToken token, Date startDate, Date endDate, JSONArray campaignIds);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取广告主时报
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ */
|
|
void getAdvertiserReportHourly(CtopOauthToken token, Date startDate, Date endDate);
|
|
void getAdvertiserReportHourly(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取计划时报
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ */
|
|
void getAdvertiserCampaignReportHourly(CtopOauthToken token, Date startDate, Date endDate);
|
|
void getAdvertiserCampaignReportHourly(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取组时报
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ */
|
|
void getAdvertiserGroupReportHourly(CtopOauthToken token, Date startDate, Date endDate);
|
|
void getAdvertiserGroupReportHourly(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取创意时报 暂停使用
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ */
|
|
void getAdvertiserCreativeReportHourly(CtopOauthToken token, Date startDate, Date endDate);
|
|
void getAdvertiserCreativeReportHourly(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取计划列表
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @param startDate
|
|
|
|
+ * @param endDate
|
|
|
|
+ */
|
|
void getCampaignList(CtopOauthToken token, Date startDate, Date endDate);
|
|
void getCampaignList(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
|
|
- void getGroupList(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
-
|
|
|
|
- void loadData() throws InterruptedException;
|
|
|
|
-
|
|
|
|
- void updateCreativeReportHourlyStatistic(CtopOauthToken token, Date getDate);
|
|
|
|
-
|
|
|
|
- void deleteHourlyReport(Date deleteDate);
|
|
|
|
-
|
|
|
|
/**
|
|
/**
|
|
- * 获取快手图片列表
|
|
|
|
|
|
+ * 获取组列表
|
|
*
|
|
*
|
|
* @param token
|
|
* @param token
|
|
* @param startDate
|
|
* @param startDate
|
|
* @param endDate
|
|
* @param endDate
|
|
*/
|
|
*/
|
|
- void getImageList(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
-
|
|
|
|
-
|
|
|
|
- void getImageList2(CtopOauthToken token, Date startDate, Date endDate, Integer page);
|
|
|
|
|
|
+ void getGroupList(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
- * 获取快手图片列表--测试使用
|
|
|
|
|
|
+ * 获取快手图片列表
|
|
*
|
|
*
|
|
* @param token
|
|
* @param token
|
|
- * @param accountId
|
|
|
|
* @param startDate
|
|
* @param startDate
|
|
* @param endDate
|
|
* @param endDate
|
|
- * @param page
|
|
|
|
*/
|
|
*/
|
|
- void getImageList(String token, Long accountId, Date startDate, Date endDate, int page);
|
|
|
|
|
|
+ void getImageList(CtopOauthToken token, Date startDate, Date endDate);
|
|
|
|
+
|
|
|
|
|
|
/**
|
|
/**
|
|
* 获取账户余额
|
|
* 获取账户余额
|
|
@@ -346,16 +462,13 @@ public interface IKuaishouInterfaceService {
|
|
JSONArray getAppSearch(Long accountId, String accessToken, String appName);
|
|
JSONArray getAppSearch(Long accountId, String accessToken, String appName);
|
|
|
|
|
|
|
|
|
|
- void getVideoList2(CtopOauthToken token, Date startDate, Date endDate, Integer page);
|
|
|
|
-
|
|
|
|
- void getCreativeList2(CtopOauthToken token, Date startDate, Date endDate, Integer page);
|
|
|
|
-
|
|
|
|
- void getCreative(String token, Long advertiserId, Long creativeId);
|
|
|
|
-
|
|
|
|
-
|
|
|
|
- void getAdvertiserCreativeReportDailyV2(Long campaignId, CtopOauthToken ctopOauthToken, Date startDate, Date endDate);
|
|
|
|
-
|
|
|
|
-
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 获取素造素材列表
|
|
|
|
+ *
|
|
|
|
+ * @param token
|
|
|
|
+ * @param accountId
|
|
|
|
+ * @param page
|
|
|
|
+ */
|
|
void getSuZaoList(String token, Long accountId, int page);
|
|
void getSuZaoList(String token, Long accountId, int page);
|
|
|
|
|
|
|
|
|