From ed86a1f58dad88ae3cd0c8038440150e098ab54a Mon Sep 17 00:00:00 2001 From: sdk-team Date: Fri, 9 Aug 2024 11:52:33 +0000 Subject: [PATCH] Support Android badge. --- aliyun-java-sdk-push/ChangeLog.txt | 3 ++ aliyun-java-sdk-push/pom.xml | 2 +- .../push/model/v20160801/MassPushRequest.java | 33 ++++++++++++++++ .../push/model/v20160801/PushRequest.java | 39 +++++++++++++++++++ 4 files changed, 76 insertions(+), 1 deletion(-) diff --git a/aliyun-java-sdk-push/ChangeLog.txt b/aliyun-java-sdk-push/ChangeLog.txt index 26fe6504ef..93dce4f2bf 100644 --- a/aliyun-java-sdk-push/ChangeLog.txt +++ b/aliyun-java-sdk-push/ChangeLog.txt @@ -1,3 +1,6 @@ +2024-08-09 Version: 3.13.16 +- Support Android badge. + 2024-06-26 Version: 3.13.15 - Support harmony app. - QueryPushRecords API Source parameter support OpenAPIExplorer. diff --git a/aliyun-java-sdk-push/pom.xml b/aliyun-java-sdk-push/pom.xml index 63ca53836e..b59d57b26d 100644 --- a/aliyun-java-sdk-push/pom.xml +++ b/aliyun-java-sdk-push/pom.xml @@ -4,7 +4,7 @@ com.aliyun aliyun-java-sdk-push jar - 3.13.15 + 3.13.16 aliyun-java-sdk-push http://www.aliyun.com Aliyun Open API SDK for Java diff --git a/aliyun-java-sdk-push/src/main/java/com/aliyuncs/push/model/v20160801/MassPushRequest.java b/aliyun-java-sdk-push/src/main/java/com/aliyuncs/push/model/v20160801/MassPushRequest.java index 773108bd7e..bb257dba60 100644 --- a/aliyun-java-sdk-push/src/main/java/com/aliyuncs/push/model/v20160801/MassPushRequest.java +++ b/aliyun-java-sdk-push/src/main/java/com/aliyuncs/push/model/v20160801/MassPushRequest.java @@ -81,6 +81,7 @@ public void setPushTasks(List pushTasks) { putBodyParameter("PushTask." + (depth1 + 1) + ".JobKey" , pushTasks.get(depth1).getJobKey()); putBodyParameter("PushTask." + (depth1 + 1) + ".HarmonyReceiptId" , pushTasks.get(depth1).getHarmonyReceiptId()); putBodyParameter("PushTask." + (depth1 + 1) + ".AndroidOpenUrl" , pushTasks.get(depth1).getAndroidOpenUrl()); + putBodyParameter("PushTask." + (depth1 + 1) + ".AndroidBadgeSetNum" , pushTasks.get(depth1).getAndroidBadgeSetNum()); putBodyParameter("PushTask." + (depth1 + 1) + ".AndroidXiaoMiNotifyBody" , pushTasks.get(depth1).getAndroidXiaoMiNotifyBody()); putBodyParameter("PushTask." + (depth1 + 1) + ".iOSSubtitle" , pushTasks.get(depth1).getIOSSubtitle()); putBodyParameter("PushTask." + (depth1 + 1) + ".AndroidXiaomiBigPictureUrl" , pushTasks.get(depth1).getAndroidXiaomiBigPictureUrl()); @@ -102,9 +103,11 @@ public void setPushTasks(List pushTasks) { putBodyParameter("PushTask." + (depth1 + 1) + ".AndroidOpenType" , pushTasks.get(depth1).getAndroidOpenType()); putBodyParameter("PushTask." + (depth1 + 1) + ".HarmonyRemindTitle" , pushTasks.get(depth1).getHarmonyRemindTitle()); putBodyParameter("PushTask." + (depth1 + 1) + ".Title" , pushTasks.get(depth1).getTitle()); + putBodyParameter("PushTask." + (depth1 + 1) + ".AndroidBadgeClass" , pushTasks.get(depth1).getAndroidBadgeClass()); putBodyParameter("PushTask." + (depth1 + 1) + ".HarmonyTestMessage" , pushTasks.get(depth1).getHarmonyTestMessage()); putBodyParameter("PushTask." + (depth1 + 1) + ".AndroidRenderStyle" , pushTasks.get(depth1).getAndroidRenderStyle()); putBodyParameter("PushTask." + (depth1 + 1) + ".iOSExtParameters" , pushTasks.get(depth1).getIOSExtParameters()); + putBodyParameter("PushTask." + (depth1 + 1) + ".AndroidBadgeAddNum" , pushTasks.get(depth1).getAndroidBadgeAddNum()); putBodyParameter("PushTask." + (depth1 + 1) + ".AndroidHuaweiReceiptId" , pushTasks.get(depth1).getAndroidHuaweiReceiptId()); putBodyParameter("PushTask." + (depth1 + 1) + ".AndroidNotificationHonorChannel" , pushTasks.get(depth1).getAndroidNotificationHonorChannel()); putBodyParameter("PushTask." + (depth1 + 1) + ".AndroidXiaomiImageUrl" , pushTasks.get(depth1).getAndroidXiaomiImageUrl()); @@ -215,6 +218,8 @@ public static class PushTask { private String androidOpenUrl; + private Integer androidBadgeSetNum; + private String androidXiaoMiNotifyBody; private String iOSSubtitle; @@ -257,12 +262,16 @@ public static class PushTask { private String title; + private String androidBadgeClass; + private Boolean harmonyTestMessage; private String androidRenderStyle; private String iOSExtParameters; + private Integer androidBadgeAddNum; + private String androidHuaweiReceiptId; private String androidNotificationHonorChannel; @@ -589,6 +598,14 @@ public void setAndroidOpenUrl(String androidOpenUrl) { this.androidOpenUrl = androidOpenUrl; } + public Integer getAndroidBadgeSetNum() { + return this.androidBadgeSetNum; + } + + public void setAndroidBadgeSetNum(Integer androidBadgeSetNum) { + this.androidBadgeSetNum = androidBadgeSetNum; + } + public String getAndroidXiaoMiNotifyBody() { return this.androidXiaoMiNotifyBody; } @@ -757,6 +774,14 @@ public void setTitle(String title) { this.title = title; } + public String getAndroidBadgeClass() { + return this.androidBadgeClass; + } + + public void setAndroidBadgeClass(String androidBadgeClass) { + this.androidBadgeClass = androidBadgeClass; + } + public Boolean getHarmonyTestMessage() { return this.harmonyTestMessage; } @@ -781,6 +806,14 @@ public void setIOSExtParameters(String iOSExtParameters) { this.iOSExtParameters = iOSExtParameters; } + public Integer getAndroidBadgeAddNum() { + return this.androidBadgeAddNum; + } + + public void setAndroidBadgeAddNum(Integer androidBadgeAddNum) { + this.androidBadgeAddNum = androidBadgeAddNum; + } + public String getAndroidHuaweiReceiptId() { return this.androidHuaweiReceiptId; } diff --git a/aliyun-java-sdk-push/src/main/java/com/aliyuncs/push/model/v20160801/PushRequest.java b/aliyun-java-sdk-push/src/main/java/com/aliyuncs/push/model/v20160801/PushRequest.java index ea71be528d..5412ea32c0 100644 --- a/aliyun-java-sdk-push/src/main/java/com/aliyuncs/push/model/v20160801/PushRequest.java +++ b/aliyun-java-sdk-push/src/main/java/com/aliyuncs/push/model/v20160801/PushRequest.java @@ -75,6 +75,8 @@ public class PushRequest extends RpcAcsRequest { private String harmonyRemindTitle; + private String androidBadgeClass; + private Integer smsDelaySecs; private Integer androidRenderStyle; @@ -161,6 +163,8 @@ public class PushRequest extends RpcAcsRequest { private String androidOpenUrl; + private Integer androidBadgeSetNum; + private String androidXiaoMiNotifyBody; private String iOSSubtitle; @@ -181,6 +185,8 @@ public class PushRequest extends RpcAcsRequest { private Boolean harmonyTestMessage; + private Integer androidBadgeAddNum; + private String androidHuaweiReceiptId; private String androidNotificationHonorChannel; @@ -484,6 +490,17 @@ public void setHarmonyRemindTitle(String harmonyRemindTitle) { } } + public String getAndroidBadgeClass() { + return this.androidBadgeClass; + } + + public void setAndroidBadgeClass(String androidBadgeClass) { + this.androidBadgeClass = androidBadgeClass; + if(androidBadgeClass != null){ + putQueryParameter("AndroidBadgeClass", androidBadgeClass); + } + } + public Integer getSmsDelaySecs() { return this.smsDelaySecs; } @@ -957,6 +974,17 @@ public void setAndroidOpenUrl(String androidOpenUrl) { } } + public Integer getAndroidBadgeSetNum() { + return this.androidBadgeSetNum; + } + + public void setAndroidBadgeSetNum(Integer androidBadgeSetNum) { + this.androidBadgeSetNum = androidBadgeSetNum; + if(androidBadgeSetNum != null){ + putQueryParameter("AndroidBadgeSetNum", androidBadgeSetNum.toString()); + } + } + public String getAndroidXiaoMiNotifyBody() { return this.androidXiaoMiNotifyBody; } @@ -1067,6 +1095,17 @@ public void setHarmonyTestMessage(Boolean harmonyTestMessage) { } } + public Integer getAndroidBadgeAddNum() { + return this.androidBadgeAddNum; + } + + public void setAndroidBadgeAddNum(Integer androidBadgeAddNum) { + this.androidBadgeAddNum = androidBadgeAddNum; + if(androidBadgeAddNum != null){ + putQueryParameter("AndroidBadgeAddNum", androidBadgeAddNum.toString()); + } + } + public String getAndroidHuaweiReceiptId() { return this.androidHuaweiReceiptId; }