Skip to content

Commit 256ff3f

Browse files
songguocolakevinlin09
authored andcommitted
update: add client_info.active_foreground_app
1 parent cf7b221 commit 256ff3f

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

src/main/java/com/alibaba/dashscope/multimodal/MultiModalDialogApiKeyWords.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ public class MultiModalDialogApiKeyWords {
4242
public static String CONST_NAME_CLIENT_INFO_LOCATION_LATITUDE = "latitude";
4343
public static String CONST_NAME_CLIENT_INFO_LOCATION_LONGITUDE = "longitude";
4444
public static String CONST_NAME_CLIENT_INFO_LOCATION_CITY_NAME = "city_name";
45+
public static String CONST_NAME_CLIENT_INFO_ACTIVE_FOREGROUND_APP = "active_foreground_app";
4546

4647
public static String CONST_NAME_BIZ_PARAMS_USER_DEFINED_PARAMS = "user_defined_params";
4748
public static String CONST_NAME_BIZ_PARAMS_USER_DEFINED_TOKENS = "user_defined_tokens";

src/main/java/com/alibaba/dashscope/multimodal/MultiModalRequestParam.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,8 @@ public static class ClientInfo {
8989
private Network network;
9090
private Locations location;
9191
private Object status;
92+
private String activeForegroundApp;
93+
private Map<String, Object> passThroughParams;
9294

9395
@Builder
9496
public static class Network {
@@ -191,6 +193,12 @@ public Map<String, Object> getParameters() {
191193
if (clientInfo.status != null) {
192194
clientInfoParams.put(CONST_NAME_CLIENT_INFO_STATUS, clientInfo.status);
193195
}
196+
if (clientInfo.activeForegroundApp != null){
197+
clientInfoParams.put(CONST_NAME_CLIENT_INFO_ACTIVE_FOREGROUND_APP, clientInfo.activeForegroundApp);
198+
}
199+
if (clientInfo.passThroughParams != null) {
200+
clientInfoParams.putAll(clientInfo.passThroughParams);
201+
}
194202
params.put(CONST_NAME_CLIENT_INFO, clientInfoParams);
195203
}
196204

0 commit comments

Comments
 (0)