@livechat/developer-studio-api 2.0.48 → 2.0.49

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.d.mts CHANGED
@@ -444,8 +444,8 @@ interface AppMonitoringEventsLog {
444
444
  }
445
445
 
446
446
  interface GetAppMonitoringEventsLogPayload {
447
- type?: string;
448
447
  from?: string;
448
+ type?: string[];
449
449
  search?: string;
450
450
  }
451
451
  interface GetAppMonitoringEventsLogResponse {
package/dist/index.d.ts CHANGED
@@ -444,8 +444,8 @@ interface AppMonitoringEventsLog {
444
444
  }
445
445
 
446
446
  interface GetAppMonitoringEventsLogPayload {
447
- type?: string;
448
447
  from?: string;
448
+ type?: string[];
449
449
  search?: string;
450
450
  }
451
451
  interface GetAppMonitoringEventsLogResponse {
package/dist/index.js CHANGED
@@ -1804,14 +1804,17 @@ var textAppMonitoringEventsApi = {
1804
1804
  },
1805
1805
  getEventsLog(appId, payload, authorization) {
1806
1806
  return __async(this, null, function* () {
1807
- var _a, _b, _c;
1807
+ var _a, _b;
1808
1808
  try {
1809
+ const searchParams = new URLSearchParams({
1810
+ from: (_a = payload.from) != null ? _a : "",
1811
+ search: (_b = payload.search) != null ? _b : ""
1812
+ });
1813
+ if (payload.type) {
1814
+ payload.type.forEach((type) => searchParams.append("type", type));
1815
+ }
1809
1816
  const response = yield textClientInstance.get(
1810
- `/app_monitoring/${appId}/events/logs?${new URLSearchParams({
1811
- from: (_a = payload.from) != null ? _a : "",
1812
- type: (_b = payload.type) != null ? _b : "",
1813
- search: (_c = payload.search) != null ? _c : ""
1814
- }).toString()}`,
1817
+ `/app_monitoring/${appId}/events/logs?${searchParams.toString()}`,
1815
1818
  getTextClientConfig(authorization)
1816
1819
  );
1817
1820
  return response.data;
package/dist/index.mjs CHANGED
@@ -1716,14 +1716,17 @@ var textAppMonitoringEventsApi = {
1716
1716
  },
1717
1717
  getEventsLog(appId, payload, authorization) {
1718
1718
  return __async(this, null, function* () {
1719
- var _a, _b, _c;
1719
+ var _a, _b;
1720
1720
  try {
1721
+ const searchParams = new URLSearchParams({
1722
+ from: (_a = payload.from) != null ? _a : "",
1723
+ search: (_b = payload.search) != null ? _b : ""
1724
+ });
1725
+ if (payload.type) {
1726
+ payload.type.forEach((type) => searchParams.append("type", type));
1727
+ }
1721
1728
  const response = yield textClientInstance.get(
1722
- `/app_monitoring/${appId}/events/logs?${new URLSearchParams({
1723
- from: (_a = payload.from) != null ? _a : "",
1724
- type: (_b = payload.type) != null ? _b : "",
1725
- search: (_c = payload.search) != null ? _c : ""
1726
- }).toString()}`,
1729
+ `/app_monitoring/${appId}/events/logs?${searchParams.toString()}`,
1727
1730
  getTextClientConfig(authorization)
1728
1731
  );
1729
1732
  return response.data;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@livechat/developer-studio-api",
3
- "version": "2.0.48",
3
+ "version": "2.0.49",
4
4
  "description": "This project is API for LiveChat Developer Studio.",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
@@ -17,10 +17,10 @@
17
17
  "@types/node": "^17.0.12",
18
18
  "tsup": "^7.1.0",
19
19
  "typescript": "^5.1.6",
20
- "types": "0.0.1",
21
- "eslint-config-custom-lib": "0.0.1",
22
20
  "config": "0.0.0",
23
- "tsconfig": "0.0.0"
21
+ "tsconfig": "0.0.0",
22
+ "eslint-config-custom-lib": "0.0.1",
23
+ "types": "0.0.1"
24
24
  },
25
25
  "scripts": {
26
26
  "build": "tsup src/index.ts --format esm,cjs --dts",