|
|
@@ -30,7 +30,8 @@ import lombok.extern.slf4j.Slf4j;
|
|
|
@Slf4j
|
|
|
public class EigeneaiApi {
|
|
|
|
|
|
- private String apiUrl = "http://api.eigene.io/rec";
|
|
|
+ private String apiUrl = "https://api.eigene.io/rec";
|
|
|
+ private String rtsApiUrl = "https://rts-api.eigene.io/api";
|
|
|
private String cuid = "1252aed4-78dc-46e8-b784-94ac42e86dd4";
|
|
|
|
|
|
@Autowired
|
|
|
@@ -166,9 +167,15 @@ public class EigeneaiApi {
|
|
|
* @author gagamel
|
|
|
* @since 2021. 5. 14
|
|
|
*/
|
|
|
- public Eigeneai getRealtimeGoodsList(int size) {
|
|
|
- String requestUrl = apiUrl + "/stream?cuid=" + cuid + "&size=" + size; //iids
|
|
|
- return this.getRecommendationGoodsList(requestUrl);
|
|
|
+ public Collection<Result> getRealtimeGoodsList(int size) {
|
|
|
+ String requestUrl = rtsApiUrl + "/stream?cuid=" + cuid + "&size=" + size + "&type=view";
|
|
|
+
|
|
|
+ Eigeneai eigeneai = this.getRecommendationGoodsList(requestUrl);
|
|
|
+ if (eigeneai.getResults() != null && !eigeneai.getResults().isEmpty()) {
|
|
|
+ return eigeneai.getResults();
|
|
|
+ }
|
|
|
+
|
|
|
+ return new ArrayList<Result>();
|
|
|
}
|
|
|
|
|
|
/**
|