@livechat/developer-studio-api 2.3.8 → 2.3.9
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.
- package/dist/index.js +19 -5
- package/dist/index.mjs +19 -5
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -2047,11 +2047,25 @@ var textPlatformDashboardApi = {
|
|
|
2047
2047
|
getReport(params, authorization) {
|
|
2048
2048
|
return __async(this, null, function* () {
|
|
2049
2049
|
try {
|
|
2050
|
-
const searchParams = new URLSearchParams(
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
)
|
|
2054
|
-
|
|
2050
|
+
const searchParams = new URLSearchParams();
|
|
2051
|
+
Object.keys(params).forEach((entry) => {
|
|
2052
|
+
const key = entry;
|
|
2053
|
+
if (key === "group_by") {
|
|
2054
|
+
const value = params[key];
|
|
2055
|
+
if (!value) {
|
|
2056
|
+
return;
|
|
2057
|
+
}
|
|
2058
|
+
value.forEach((innerValue) => {
|
|
2059
|
+
searchParams.append(key, innerValue);
|
|
2060
|
+
});
|
|
2061
|
+
} else {
|
|
2062
|
+
const value = params[key];
|
|
2063
|
+
if (!value) {
|
|
2064
|
+
return;
|
|
2065
|
+
}
|
|
2066
|
+
searchParams.append(key, value);
|
|
2067
|
+
}
|
|
2068
|
+
});
|
|
2055
2069
|
const response = yield textClientInstance.get(
|
|
2056
2070
|
`/platform_dashboard/report?${searchParams.toString()}`,
|
|
2057
2071
|
getTextClientConfig(authorization)
|
package/dist/index.mjs
CHANGED
|
@@ -1956,11 +1956,25 @@ var textPlatformDashboardApi = {
|
|
|
1956
1956
|
getReport(params, authorization) {
|
|
1957
1957
|
return __async(this, null, function* () {
|
|
1958
1958
|
try {
|
|
1959
|
-
const searchParams = new URLSearchParams(
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
)
|
|
1963
|
-
|
|
1959
|
+
const searchParams = new URLSearchParams();
|
|
1960
|
+
Object.keys(params).forEach((entry) => {
|
|
1961
|
+
const key = entry;
|
|
1962
|
+
if (key === "group_by") {
|
|
1963
|
+
const value = params[key];
|
|
1964
|
+
if (!value) {
|
|
1965
|
+
return;
|
|
1966
|
+
}
|
|
1967
|
+
value.forEach((innerValue) => {
|
|
1968
|
+
searchParams.append(key, innerValue);
|
|
1969
|
+
});
|
|
1970
|
+
} else {
|
|
1971
|
+
const value = params[key];
|
|
1972
|
+
if (!value) {
|
|
1973
|
+
return;
|
|
1974
|
+
}
|
|
1975
|
+
searchParams.append(key, value);
|
|
1976
|
+
}
|
|
1977
|
+
});
|
|
1964
1978
|
const response = yield textClientInstance.get(
|
|
1965
1979
|
`/platform_dashboard/report?${searchParams.toString()}`,
|
|
1966
1980
|
getTextClientConfig(authorization)
|