curtain-web-api 1.0.23 → 1.0.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -41,4 +41,5 @@ export declare class CurtainWebAPI {
|
|
|
41
41
|
postPrimitiveStatsTest(data: any, type?: string): Promise<import("axios").AxiosResponse<any, any>>;
|
|
42
42
|
getDataAllListCategory(): Promise<import("axios").AxiosResponse<any, any>>;
|
|
43
43
|
postCompareSession(idList: string[], matchType: string, studyList: string[], sessionId: string): Promise<import("axios").AxiosResponse<any, any>>;
|
|
44
|
+
getStatsSummary(lastNDays: number): Promise<import("axios").AxiosResponse<any, any>>;
|
|
44
45
|
}
|
|
@@ -421,5 +421,11 @@ class CurtainWebAPI {
|
|
|
421
421
|
headers["Content-Type"] = "application/json";
|
|
422
422
|
return axios_1.default.post(this.baseURL + "compare-session/", { matchType, studyList, idList, sessionId }, { headers: headers, responseType: "json" }).then((response) => { return response; });
|
|
423
423
|
}
|
|
424
|
+
getStatsSummary(lastNDays) {
|
|
425
|
+
let headers = new axios_1.AxiosHeaders();
|
|
426
|
+
headers["Accept"] = "application/json";
|
|
427
|
+
headers["Content-Type"] = "application/json";
|
|
428
|
+
return this.axiosInstance.get(this.baseURL + `stats/summary/${lastNDays}/`, { responseType: "json", headers });
|
|
429
|
+
}
|
|
424
430
|
}
|
|
425
431
|
exports.CurtainWebAPI = CurtainWebAPI;
|
package/package.json
CHANGED
|
@@ -437,5 +437,12 @@ export class CurtainWebAPI {
|
|
|
437
437
|
headers["Content-Type"] = "application/json";
|
|
438
438
|
return axios.post(this.baseURL + "compare-session/", {matchType, studyList, idList, sessionId}, {headers: headers, responseType: "json"}).then((response) => {return response;});
|
|
439
439
|
}
|
|
440
|
+
|
|
441
|
+
getStatsSummary(lastNDays: number) {
|
|
442
|
+
let headers = new AxiosHeaders();
|
|
443
|
+
headers["Accept"] = "application/json";
|
|
444
|
+
headers["Content-Type"] = "application/json";
|
|
445
|
+
return this.axiosInstance.get(this.baseURL + `stats/summary/${lastNDays}/`, {responseType:"json", headers})
|
|
446
|
+
}
|
|
440
447
|
}
|
|
441
448
|
|