@opens/gateways 1.16.20 → 1.16.22

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.mjs CHANGED
@@ -350,6 +350,32 @@ var CustomerServiceGateway = class {
350
350
  });
351
351
  return data;
352
352
  }
353
+ /**
354
+ * Submits one response to a survey announcement.
355
+ * @param announcementId - The unique identifier of the survey announcement.
356
+ * @param payload - The subject identifier and validated survey answers.
357
+ * @returns The persisted survey response.
358
+ */
359
+ async submitSurveyResponse(announcementId, payload) {
360
+ const { data } = await this.httpClient.post(
361
+ `${this.baseUrl}/announcements/${announcementId}/responses`,
362
+ payload
363
+ );
364
+ return data;
365
+ }
366
+ /**
367
+ * Retrieves paginated responses for a survey announcement.
368
+ * @param announcementId - The unique identifier of the survey announcement.
369
+ * @param query - Pagination options for the administrative list.
370
+ * @returns Paginated survey responses.
371
+ */
372
+ async findSurveyResponses(announcementId, query) {
373
+ const { data } = await this.httpClient.get(
374
+ `${this.baseUrl}/announcements/admin/${announcementId}/responses`,
375
+ { params: query }
376
+ );
377
+ return data;
378
+ }
353
379
  };
354
380
 
355
381
  // src/chat-config/index.ts
@@ -896,6 +922,23 @@ var IntegrationsGateway = class {
896
922
  }
897
923
  httpClient;
898
924
  baseUrl;
925
+ /**
926
+ * Retrieves the apps available to the authenticated company.
927
+ * @returns The available apps and their total count.
928
+ */
929
+ async getAppList() {
930
+ const { data } = await this.httpClient.get(`${this.baseUrl}/apps`);
931
+ return data;
932
+ }
933
+ /**
934
+ * Retrieves an app and its form definition.
935
+ * @param appId - The app identifier.
936
+ * @returns The app details.
937
+ */
938
+ async getApp({ appId }) {
939
+ const { data } = await this.httpClient.get(`${this.baseUrl}/apps/${appId}`);
940
+ return data;
941
+ }
899
942
  /**
900
943
  * Retrieves all integration partners configured for a company.
901
944
  * @param companyId - The company identifier.