@ikatec/digisac-api-sdk 4.12.0 → 4.13.0

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.
Files changed (103) hide show
  1. package/dist/apis/absence/AbsenceApi.cjs +46 -2
  2. package/dist/apis/absence/AbsenceApi.cjs.map +1 -1
  3. package/dist/apis/absence/AbsenceApi.d.ts +38 -4
  4. package/dist/apis/absence/AbsenceApi.d.ts.map +1 -1
  5. package/dist/apis/absence/AbsenceApi.mjs +46 -2
  6. package/dist/apis/absence/AbsenceApi.mjs.map +1 -1
  7. package/dist/apis/absence/types.d.ts +51 -2
  8. package/dist/apis/absence/types.d.ts.map +1 -1
  9. package/dist/apis/activityLog/ActivityLogApi.cjs +10 -1
  10. package/dist/apis/activityLog/ActivityLogApi.cjs.map +1 -1
  11. package/dist/apis/activityLog/ActivityLogApi.d.ts +10 -3
  12. package/dist/apis/activityLog/ActivityLogApi.d.ts.map +1 -1
  13. package/dist/apis/activityLog/ActivityLogApi.mjs +10 -1
  14. package/dist/apis/activityLog/ActivityLogApi.mjs.map +1 -1
  15. package/dist/apis/activityLog/types.d.ts +48 -8
  16. package/dist/apis/activityLog/types.d.ts.map +1 -1
  17. package/dist/apis/creditMovements/CreditMovementsApi.cjs +31 -2
  18. package/dist/apis/creditMovements/CreditMovementsApi.cjs.map +1 -1
  19. package/dist/apis/creditMovements/CreditMovementsApi.d.ts +21 -3
  20. package/dist/apis/creditMovements/CreditMovementsApi.d.ts.map +1 -1
  21. package/dist/apis/creditMovements/CreditMovementsApi.mjs +31 -2
  22. package/dist/apis/creditMovements/CreditMovementsApi.mjs.map +1 -1
  23. package/dist/apis/creditMovements/types.d.ts +73 -2
  24. package/dist/apis/creditMovements/types.d.ts.map +1 -1
  25. package/dist/apis/knowledgeBase/KnowledgeBaseApi.cjs +27 -0
  26. package/dist/apis/knowledgeBase/KnowledgeBaseApi.cjs.map +1 -1
  27. package/dist/apis/knowledgeBase/KnowledgeBaseApi.d.ts +22 -1
  28. package/dist/apis/knowledgeBase/KnowledgeBaseApi.d.ts.map +1 -1
  29. package/dist/apis/knowledgeBase/KnowledgeBaseApi.mjs +27 -0
  30. package/dist/apis/knowledgeBase/KnowledgeBaseApi.mjs.map +1 -1
  31. package/dist/apis/knowledgeBase/types.d.ts +56 -2
  32. package/dist/apis/knowledgeBase/types.d.ts.map +1 -1
  33. package/dist/apis/knowledgeBaseItem/KnowledgeBaseItemApi.cjs +26 -0
  34. package/dist/apis/knowledgeBaseItem/KnowledgeBaseItemApi.cjs.map +1 -1
  35. package/dist/apis/knowledgeBaseItem/KnowledgeBaseItemApi.d.ts +24 -0
  36. package/dist/apis/knowledgeBaseItem/KnowledgeBaseItemApi.d.ts.map +1 -1
  37. package/dist/apis/knowledgeBaseItem/KnowledgeBaseItemApi.mjs +26 -0
  38. package/dist/apis/knowledgeBaseItem/KnowledgeBaseItemApi.mjs.map +1 -1
  39. package/dist/apis/knowledgeBaseItem/types.d.ts +23 -6
  40. package/dist/apis/knowledgeBaseItem/types.d.ts.map +1 -1
  41. package/dist/apis/notifications/NotificationsApi.cjs +50 -2
  42. package/dist/apis/notifications/NotificationsApi.cjs.map +1 -1
  43. package/dist/apis/notifications/NotificationsApi.d.ts +41 -3
  44. package/dist/apis/notifications/NotificationsApi.d.ts.map +1 -1
  45. package/dist/apis/notifications/NotificationsApi.mjs +50 -2
  46. package/dist/apis/notifications/NotificationsApi.mjs.map +1 -1
  47. package/dist/apis/notifications/types.d.ts +54 -8
  48. package/dist/apis/notifications/types.d.ts.map +1 -1
  49. package/dist/apis/serviceAccessManagement/ServiceAccessManagementApi.cjs.map +1 -1
  50. package/dist/apis/serviceAccessManagement/ServiceAccessManagementApi.d.ts +4 -1
  51. package/dist/apis/serviceAccessManagement/ServiceAccessManagementApi.d.ts.map +1 -1
  52. package/dist/apis/serviceAccessManagement/ServiceAccessManagementApi.mjs.map +1 -1
  53. package/dist/apis/serviceAccessManagement/types.d.ts +3 -0
  54. package/dist/apis/serviceAccessManagement/types.d.ts.map +1 -1
  55. package/dist/apis/stickerUsers/StickerUsersApi.cjs.map +1 -1
  56. package/dist/apis/stickerUsers/StickerUsersApi.d.ts +3 -1
  57. package/dist/apis/stickerUsers/StickerUsersApi.d.ts.map +1 -1
  58. package/dist/apis/stickerUsers/StickerUsersApi.mjs.map +1 -1
  59. package/dist/apis/stickerUsers/types.d.ts +4 -0
  60. package/dist/apis/stickerUsers/types.d.ts.map +1 -1
  61. package/dist/apis/stickers/StickersApi.cjs +27 -3
  62. package/dist/apis/stickers/StickersApi.cjs.map +1 -1
  63. package/dist/apis/stickers/StickersApi.d.ts +24 -4
  64. package/dist/apis/stickers/StickersApi.d.ts.map +1 -1
  65. package/dist/apis/stickers/StickersApi.mjs +27 -3
  66. package/dist/apis/stickers/StickersApi.mjs.map +1 -1
  67. package/dist/apis/stickers/types.d.ts +28 -4
  68. package/dist/apis/stickers/types.d.ts.map +1 -1
  69. package/dist/apis/whatsappBusinessTemplates/WhatsappBusinessTemplatesApi.cjs +1 -2
  70. package/dist/apis/whatsappBusinessTemplates/WhatsappBusinessTemplatesApi.cjs.map +1 -1
  71. package/dist/apis/whatsappBusinessTemplates/WhatsappBusinessTemplatesApi.d.ts +1 -2
  72. package/dist/apis/whatsappBusinessTemplates/WhatsappBusinessTemplatesApi.d.ts.map +1 -1
  73. package/dist/apis/whatsappBusinessTemplates/WhatsappBusinessTemplatesApi.mjs +1 -2
  74. package/dist/apis/whatsappBusinessTemplates/WhatsappBusinessTemplatesApi.mjs.map +1 -1
  75. package/package.json +1 -1
  76. package/src/apis/absence/AbsenceApi.test.ts +65 -0
  77. package/src/apis/absence/AbsenceApi.ts +77 -4
  78. package/src/apis/absence/types.ts +53 -2
  79. package/src/apis/activityLog/ActivityLogApi.test.ts +44 -0
  80. package/src/apis/activityLog/ActivityLogApi.ts +22 -3
  81. package/src/apis/activityLog/types.ts +47 -8
  82. package/src/apis/creditMovements/CreditMovementsApi.test.ts +88 -0
  83. package/src/apis/creditMovements/CreditMovementsApi.ts +73 -2
  84. package/src/apis/creditMovements/types.ts +74 -2
  85. package/src/apis/knowledgeBase/KnowledgeBaseApi.test.ts +54 -0
  86. package/src/apis/knowledgeBase/KnowledgeBaseApi.ts +61 -1
  87. package/src/apis/knowledgeBase/types.ts +62 -2
  88. package/src/apis/knowledgeBaseItem/KnowledgeBaseItemApi.test.ts +57 -0
  89. package/src/apis/knowledgeBaseItem/KnowledgeBaseItemApi.ts +45 -0
  90. package/src/apis/knowledgeBaseItem/types.ts +23 -6
  91. package/src/apis/me/MeApi.test.ts +1 -1
  92. package/src/apis/notifications/NotificationsApi.test.ts +74 -0
  93. package/src/apis/notifications/NotificationsApi.ts +88 -3
  94. package/src/apis/notifications/types.ts +65 -7
  95. package/src/apis/payloads.test-d.ts +46 -0
  96. package/src/apis/serviceAccessManagement/ServiceAccessManagementApi.ts +4 -1
  97. package/src/apis/serviceAccessManagement/types.ts +3 -0
  98. package/src/apis/stickerUsers/StickerUsersApi.ts +3 -1
  99. package/src/apis/stickerUsers/types.ts +4 -0
  100. package/src/apis/stickers/StickersApi.test.ts +58 -0
  101. package/src/apis/stickers/StickersApi.ts +46 -4
  102. package/src/apis/stickers/types.ts +29 -4
  103. package/src/apis/whatsappBusinessTemplates/WhatsappBusinessTemplatesApi.ts +1 -2
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/apis/knowledgeBaseItem/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAA;AAC1C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAA;AAE3D,MAAM,MAAM,iBAAiB,GAAG;IAC9B,EAAE,EAAE,MAAM,CAAA;IACV,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,MAAM,CAAA;IACZ,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAA;IACvB,GAAG,EAAE,MAAM,GAAG,IAAI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IAAI,CAAC,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACxB,GAAG,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACnB,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;CACvB,CAAA"}
@@ -2,17 +2,65 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
2
  const require_core_BaseCrudApi = require('../../core/BaseCrudApi.cjs');
3
3
 
4
4
  //#region src/apis/notifications/NotificationsApi.ts
5
+ /**
6
+ * Notifications of the current user (all of the account with `notification.view.all`). Some types open a modal in the web app as soon as they arrive (`announcement`, `credits-90`,
7
+ * `credits-100`, `smart-summary`, `warn-service-reconnect`).
8
+ */
5
9
  var NotificationsApi = class extends require_core_BaseCrudApi.BaseCrudApi {
6
10
  constructor(client) {
7
11
  super(client, "/notifications");
8
12
  }
9
13
  /**
10
- * Deletes a notification. Resolves the text `'OK'`; an unknown id answers 500. The route checks
11
- * no permission.
14
+ * Deletes a notification. Resolves the text `'OK'`; an unknown id answers 500.
12
15
  */
13
16
  deleteById(id, headers) {
14
17
  return super.deleteById(id, headers);
15
18
  }
19
+ /**
20
+ * Counts the notifications the user sees: `{ count: { total, read, unread } }`, as TEXT.
21
+ */
22
+ count(headers) {
23
+ return this.client.post(`${this.basePath}/count`, void 0, headers);
24
+ }
25
+ /**
26
+ * Marks a notification as read for the current user and resolves the new counts. An unknown id answers
27
+ * 400 `Notification not found.`.
28
+ */
29
+ read(id, headers) {
30
+ return this.client.put(`${this.basePath}/${id}/read`, void 0, headers);
31
+ }
32
+ /**
33
+ * Marks a notification as unread for the current user and resolves the new counts. An unknown id
34
+ * answers 400 `Notification not found.`.
35
+ */
36
+ unread(id, headers) {
37
+ return this.client.put(`${this.basePath}/${id}/unread`, void 0, headers);
38
+ }
39
+ /**
40
+ * Marks the notifications of `ids` as read. Resolves with no body; a body that is not an array answers
41
+ * 500 `Body must be an array of notification IDs`.
42
+ */
43
+ readMany(ids, headers) {
44
+ return this.client.post(`${this.basePath}/read-many`, ids, headers);
45
+ }
46
+ /**
47
+ * Marks every notification the user sees as read (a GET that writes: it recreates the read receipts of
48
+ * the user) and resolves the counts, as numbers.
49
+ */
50
+ readAll(headers) {
51
+ return this.client.get(`${this.basePath}/read-all`, headers);
52
+ }
53
+ /** Clears the push badge counter of the current user. Resolves `{ success: true }`. */
54
+ resetBadgeCount(headers) {
55
+ return this.client.post(`${this.basePath}/reset-badge-count`, void 0, headers);
56
+ }
57
+ /**
58
+ * SENDS an announcement (`type: 'announcement'`, which opens a modal in the web app) to every user of
59
+ * the account, or only to the admins with `to: 'admin'`. Resolves `{ message: 'Notificações enviadas' }` before the notifications are created.
60
+ */
61
+ sendAll(body, headers) {
62
+ return this.client.post(`${this.basePath}/send-all`, body, headers);
63
+ }
16
64
  };
17
65
 
18
66
  //#endregion
@@ -1 +1 @@
1
- {"version":3,"file":"NotificationsApi.cjs","names":["BaseCrudApi"],"sources":["../../../src/apis/notifications/NotificationsApi.ts"],"sourcesContent":["import type { ApiClient } from '../../core/ApiClient'\nimport type { ListQuery } from '../../core/types'\nimport { BaseCrudApi } from '../../core/BaseCrudApi'\nimport type { Notification, CreateNotificationPayload, UpdateNotificationPayload } from './types'\n\nexport class NotificationsApi extends BaseCrudApi<\n Notification,\n CreateNotificationPayload,\n UpdateNotificationPayload,\n ListQuery<Notification>,\n 'OK'\n> {\n constructor(client: ApiClient) {\n super(client, '/notifications')\n }\n\n /**\n * Deletes a notification. Resolves the text `'OK'`; an unknown id answers 500. The route checks\n * no permission.\n */\n override deleteById(id: string, headers?: Record<string, string>): Promise<'OK'> {\n return super.deleteById(id, headers)\n }\n}\n"],"mappings":";;;;AAKA,IAAa,mBAAb,cAAsCA,qCAMpC;CACA,YAAY,QAAmB;AAC7B,QAAM,QAAQ,iBAAiB;;;;;;CAOjC,AAAS,WAAW,IAAY,SAAiD;AAC/E,SAAO,MAAM,WAAW,IAAI,QAAQ"}
1
+ {"version":3,"file":"NotificationsApi.cjs","names":["BaseCrudApi"],"sources":["../../../src/apis/notifications/NotificationsApi.ts"],"sourcesContent":["import type { ApiClient } from '../../core/ApiClient'\nimport type { ListQuery } from '../../core/types'\nimport { BaseCrudApi } from '../../core/BaseCrudApi'\nimport type {\n Notification,\n CreateNotificationPayload,\n UpdateNotificationPayload,\n NotificationCountsResponse,\n NotificationReadAllResponse,\n SendAllNotificationsPayload,\n} from './types'\n\n/**\n * Notifications of the current user (all of the account with `notification.view.all`). Some types open a modal in the web app as soon as they arrive (`announcement`, `credits-90`,\n * `credits-100`, `smart-summary`, `warn-service-reconnect`).\n */\nexport class NotificationsApi extends BaseCrudApi<\n Notification,\n CreateNotificationPayload,\n UpdateNotificationPayload,\n ListQuery<Notification>,\n 'OK'\n> {\n constructor(client: ApiClient) {\n super(client, '/notifications')\n }\n\n /**\n * Deletes a notification. Resolves the text `'OK'`; an unknown id answers 500.\n */\n override deleteById(id: string, headers?: Record<string, string>): Promise<'OK'> {\n return super.deleteById(id, headers)\n }\n\n /**\n * Counts the notifications the user sees: `{ count: { total, read, unread } }`, as TEXT.\n */\n count(headers?: Record<string, string>): Promise<NotificationCountsResponse> {\n return this.client.post<NotificationCountsResponse>(\n `${this.basePath}/count`,\n undefined,\n headers,\n )\n }\n\n /**\n * Marks a notification as read for the current user and resolves the new counts. An unknown id answers\n * 400 `Notification not found.`.\n */\n read(id: string, headers?: Record<string, string>): Promise<NotificationCountsResponse> {\n return this.client.put<NotificationCountsResponse>(\n `${this.basePath}/${id}/read`,\n undefined,\n headers,\n )\n }\n\n /**\n * Marks a notification as unread for the current user and resolves the new counts. An unknown id\n * answers 400 `Notification not found.`.\n */\n unread(id: string, headers?: Record<string, string>): Promise<NotificationCountsResponse> {\n return this.client.put<NotificationCountsResponse>(\n `${this.basePath}/${id}/unread`,\n undefined,\n headers,\n )\n }\n\n /**\n * Marks the notifications of `ids` as read. Resolves with no body; a body that is not an array answers\n * 500 `Body must be an array of notification IDs`.\n */\n readMany(ids: string[], headers?: Record<string, string>): Promise<void> {\n return this.client.post<void, string[]>(`${this.basePath}/read-many`, ids, headers)\n }\n\n /**\n * Marks every notification the user sees as read (a GET that writes: it recreates the read receipts of\n * the user) and resolves the counts, as numbers.\n */\n readAll(headers?: Record<string, string>): Promise<NotificationReadAllResponse> {\n return this.client.get<NotificationReadAllResponse>(`${this.basePath}/read-all`, headers)\n }\n\n /** Clears the push badge counter of the current user. Resolves `{ success: true }`. */\n resetBadgeCount(headers?: Record<string, string>): Promise<{ success: true }> {\n return this.client.post<{ success: true }>(\n `${this.basePath}/reset-badge-count`,\n undefined,\n headers,\n )\n }\n\n /**\n * SENDS an announcement (`type: 'announcement'`, which opens a modal in the web app) to every user of\n * the account, or only to the admins with `to: 'admin'`. Resolves `{ message: 'Notificações enviadas' }` before the notifications are created.\n */\n sendAll(\n body: SendAllNotificationsPayload,\n headers?: Record<string, string>,\n ): Promise<{ message: string }> {\n return this.client.post<{ message: string }, SendAllNotificationsPayload>(\n `${this.basePath}/send-all`,\n body,\n headers,\n )\n }\n}\n"],"mappings":";;;;;;;;AAgBA,IAAa,mBAAb,cAAsCA,qCAMpC;CACA,YAAY,QAAmB;AAC7B,QAAM,QAAQ,iBAAiB;;;;;CAMjC,AAAS,WAAW,IAAY,SAAiD;AAC/E,SAAO,MAAM,WAAW,IAAI,QAAQ;;;;;CAMtC,MAAM,SAAuE;AAC3E,SAAO,KAAK,OAAO,KACjB,GAAG,KAAK,SAAS,SACjB,QACA,QACD;;;;;;CAOH,KAAK,IAAY,SAAuE;AACtF,SAAO,KAAK,OAAO,IACjB,GAAG,KAAK,SAAS,GAAG,GAAG,QACvB,QACA,QACD;;;;;;CAOH,OAAO,IAAY,SAAuE;AACxF,SAAO,KAAK,OAAO,IACjB,GAAG,KAAK,SAAS,GAAG,GAAG,UACvB,QACA,QACD;;;;;;CAOH,SAAS,KAAe,SAAiD;AACvE,SAAO,KAAK,OAAO,KAAqB,GAAG,KAAK,SAAS,aAAa,KAAK,QAAQ;;;;;;CAOrF,QAAQ,SAAwE;AAC9E,SAAO,KAAK,OAAO,IAAiC,GAAG,KAAK,SAAS,YAAY,QAAQ;;;CAI3F,gBAAgB,SAA8D;AAC5E,SAAO,KAAK,OAAO,KACjB,GAAG,KAAK,SAAS,qBACjB,QACA,QACD;;;;;;CAOH,QACE,MACA,SAC8B;AAC9B,SAAO,KAAK,OAAO,KACjB,GAAG,KAAK,SAAS,YACjB,MACA,QACD"}
@@ -1,13 +1,51 @@
1
1
  import type { ApiClient } from '../../core/ApiClient';
2
2
  import type { ListQuery } from '../../core/types';
3
3
  import { BaseCrudApi } from '../../core/BaseCrudApi';
4
- import type { Notification, CreateNotificationPayload, UpdateNotificationPayload } from './types';
4
+ import type { Notification, CreateNotificationPayload, UpdateNotificationPayload, NotificationCountsResponse, NotificationReadAllResponse, SendAllNotificationsPayload } from './types';
5
+ /**
6
+ * Notifications of the current user (all of the account with `notification.view.all`). Some types open a modal in the web app as soon as they arrive (`announcement`, `credits-90`,
7
+ * `credits-100`, `smart-summary`, `warn-service-reconnect`).
8
+ */
5
9
  export declare class NotificationsApi extends BaseCrudApi<Notification, CreateNotificationPayload, UpdateNotificationPayload, ListQuery<Notification>, 'OK'> {
6
10
  constructor(client: ApiClient);
7
11
  /**
8
- * Deletes a notification. Resolves the text `'OK'`; an unknown id answers 500. The route checks
9
- * no permission.
12
+ * Deletes a notification. Resolves the text `'OK'`; an unknown id answers 500.
10
13
  */
11
14
  deleteById(id: string, headers?: Record<string, string>): Promise<'OK'>;
15
+ /**
16
+ * Counts the notifications the user sees: `{ count: { total, read, unread } }`, as TEXT.
17
+ */
18
+ count(headers?: Record<string, string>): Promise<NotificationCountsResponse>;
19
+ /**
20
+ * Marks a notification as read for the current user and resolves the new counts. An unknown id answers
21
+ * 400 `Notification not found.`.
22
+ */
23
+ read(id: string, headers?: Record<string, string>): Promise<NotificationCountsResponse>;
24
+ /**
25
+ * Marks a notification as unread for the current user and resolves the new counts. An unknown id
26
+ * answers 400 `Notification not found.`.
27
+ */
28
+ unread(id: string, headers?: Record<string, string>): Promise<NotificationCountsResponse>;
29
+ /**
30
+ * Marks the notifications of `ids` as read. Resolves with no body; a body that is not an array answers
31
+ * 500 `Body must be an array of notification IDs`.
32
+ */
33
+ readMany(ids: string[], headers?: Record<string, string>): Promise<void>;
34
+ /**
35
+ * Marks every notification the user sees as read (a GET that writes: it recreates the read receipts of
36
+ * the user) and resolves the counts, as numbers.
37
+ */
38
+ readAll(headers?: Record<string, string>): Promise<NotificationReadAllResponse>;
39
+ /** Clears the push badge counter of the current user. Resolves `{ success: true }`. */
40
+ resetBadgeCount(headers?: Record<string, string>): Promise<{
41
+ success: true;
42
+ }>;
43
+ /**
44
+ * SENDS an announcement (`type: 'announcement'`, which opens a modal in the web app) to every user of
45
+ * the account, or only to the admins with `to: 'admin'`. Resolves `{ message: 'Notificações enviadas' }` before the notifications are created.
46
+ */
47
+ sendAll(body: SendAllNotificationsPayload, headers?: Record<string, string>): Promise<{
48
+ message: string;
49
+ }>;
12
50
  }
13
51
  //# sourceMappingURL=NotificationsApi.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"NotificationsApi.d.ts","sourceRoot":"","sources":["../../../src/apis/notifications/NotificationsApi.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAA;AACrD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAA;AACjD,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAA;AACpD,OAAO,KAAK,EAAE,YAAY,EAAE,yBAAyB,EAAE,yBAAyB,EAAE,MAAM,SAAS,CAAA;AAEjG,qBAAa,gBAAiB,SAAQ,WAAW,CAC/C,YAAY,EACZ,yBAAyB,EACzB,yBAAyB,EACzB,SAAS,CAAC,YAAY,CAAC,EACvB,IAAI,CACL;gBACa,MAAM,EAAE,SAAS;IAI7B;;;OAGG;IACM,UAAU,CAAC,EAAE,EA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,GAAG,EAAE,MAAM,EAAE,EAAE,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC;IAIxE;;;OAGG;IACH,OAAO,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,OAAO,CAAC,2BAA2B,CAAC;IAI/E,uFAAuF;IACvF,eAAe,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,OAAO,CAAC;QAAE,OAAO,EAAE,IAAI,CAAA;KAAE,CAAC;IAQ7E;;;OAGG;IACH,OAAO,CACL,IAAI,EAAE,2BAA2B,EACjC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC;QAAE,OAAO,EAAE,MAAM,CAAA;KAAE,CAAC;CAOhC"}
@@ -1,17 +1,65 @@
1
1
  import { BaseCrudApi } from "../../core/BaseCrudApi.mjs";
2
2
 
3
3
  //#region src/apis/notifications/NotificationsApi.ts
4
+ /**
5
+ * Notifications of the current user (all of the account with `notification.view.all`). Some types open a modal in the web app as soon as they arrive (`announcement`, `credits-90`,
6
+ * `credits-100`, `smart-summary`, `warn-service-reconnect`).
7
+ */
4
8
  var NotificationsApi = class extends BaseCrudApi {
5
9
  constructor(client) {
6
10
  super(client, "/notifications");
7
11
  }
8
12
  /**
9
- * Deletes a notification. Resolves the text `'OK'`; an unknown id answers 500. The route checks
10
- * no permission.
13
+ * Deletes a notification. Resolves the text `'OK'`; an unknown id answers 500.
11
14
  */
12
15
  deleteById(id, headers) {
13
16
  return super.deleteById(id, headers);
14
17
  }
18
+ /**
19
+ * Counts the notifications the user sees: `{ count: { total, read, unread } }`, as TEXT.
20
+ */
21
+ count(headers) {
22
+ return this.client.post(`${this.basePath}/count`, void 0, headers);
23
+ }
24
+ /**
25
+ * Marks a notification as read for the current user and resolves the new counts. An unknown id answers
26
+ * 400 `Notification not found.`.
27
+ */
28
+ read(id, headers) {
29
+ return this.client.put(`${this.basePath}/${id}/read`, void 0, headers);
30
+ }
31
+ /**
32
+ * Marks a notification as unread for the current user and resolves the new counts. An unknown id
33
+ * answers 400 `Notification not found.`.
34
+ */
35
+ unread(id, headers) {
36
+ return this.client.put(`${this.basePath}/${id}/unread`, void 0, headers);
37
+ }
38
+ /**
39
+ * Marks the notifications of `ids` as read. Resolves with no body; a body that is not an array answers
40
+ * 500 `Body must be an array of notification IDs`.
41
+ */
42
+ readMany(ids, headers) {
43
+ return this.client.post(`${this.basePath}/read-many`, ids, headers);
44
+ }
45
+ /**
46
+ * Marks every notification the user sees as read (a GET that writes: it recreates the read receipts of
47
+ * the user) and resolves the counts, as numbers.
48
+ */
49
+ readAll(headers) {
50
+ return this.client.get(`${this.basePath}/read-all`, headers);
51
+ }
52
+ /** Clears the push badge counter of the current user. Resolves `{ success: true }`. */
53
+ resetBadgeCount(headers) {
54
+ return this.client.post(`${this.basePath}/reset-badge-count`, void 0, headers);
55
+ }
56
+ /**
57
+ * SENDS an announcement (`type: 'announcement'`, which opens a modal in the web app) to every user of
58
+ * the account, or only to the admins with `to: 'admin'`. Resolves `{ message: 'Notificações enviadas' }` before the notifications are created.
59
+ */
60
+ sendAll(body, headers) {
61
+ return this.client.post(`${this.basePath}/send-all`, body, headers);
62
+ }
15
63
  };
16
64
 
17
65
  //#endregion
@@ -1 +1 @@
1
- {"version":3,"file":"NotificationsApi.mjs","names":[],"sources":["../../../src/apis/notifications/NotificationsApi.ts"],"sourcesContent":["import type { ApiClient } from '../../core/ApiClient'\nimport type { ListQuery } from '../../core/types'\nimport { BaseCrudApi } from '../../core/BaseCrudApi'\nimport type { Notification, CreateNotificationPayload, UpdateNotificationPayload } from './types'\n\nexport class NotificationsApi extends BaseCrudApi<\n Notification,\n CreateNotificationPayload,\n UpdateNotificationPayload,\n ListQuery<Notification>,\n 'OK'\n> {\n constructor(client: ApiClient) {\n super(client, '/notifications')\n }\n\n /**\n * Deletes a notification. Resolves the text `'OK'`; an unknown id answers 500. The route checks\n * no permission.\n */\n override deleteById(id: string, headers?: Record<string, string>): Promise<'OK'> {\n return super.deleteById(id, headers)\n }\n}\n"],"mappings":";;;AAKA,IAAa,mBAAb,cAAsC,YAMpC;CACA,YAAY,QAAmB;AAC7B,QAAM,QAAQ,iBAAiB;;;;;;CAOjC,AAAS,WAAW,IAAY,SAAiD;AAC/E,SAAO,MAAM,WAAW,IAAI,QAAQ"}
1
+ {"version":3,"file":"NotificationsApi.mjs","names":[],"sources":["../../../src/apis/notifications/NotificationsApi.ts"],"sourcesContent":["import type { ApiClient } from '../../core/ApiClient'\nimport type { ListQuery } from '../../core/types'\nimport { BaseCrudApi } from '../../core/BaseCrudApi'\nimport type {\n Notification,\n CreateNotificationPayload,\n UpdateNotificationPayload,\n NotificationCountsResponse,\n NotificationReadAllResponse,\n SendAllNotificationsPayload,\n} from './types'\n\n/**\n * Notifications of the current user (all of the account with `notification.view.all`). Some types open a modal in the web app as soon as they arrive (`announcement`, `credits-90`,\n * `credits-100`, `smart-summary`, `warn-service-reconnect`).\n */\nexport class NotificationsApi extends BaseCrudApi<\n Notification,\n CreateNotificationPayload,\n UpdateNotificationPayload,\n ListQuery<Notification>,\n 'OK'\n> {\n constructor(client: ApiClient) {\n super(client, '/notifications')\n }\n\n /**\n * Deletes a notification. Resolves the text `'OK'`; an unknown id answers 500.\n */\n override deleteById(id: string, headers?: Record<string, string>): Promise<'OK'> {\n return super.deleteById(id, headers)\n }\n\n /**\n * Counts the notifications the user sees: `{ count: { total, read, unread } }`, as TEXT.\n */\n count(headers?: Record<string, string>): Promise<NotificationCountsResponse> {\n return this.client.post<NotificationCountsResponse>(\n `${this.basePath}/count`,\n undefined,\n headers,\n )\n }\n\n /**\n * Marks a notification as read for the current user and resolves the new counts. An unknown id answers\n * 400 `Notification not found.`.\n */\n read(id: string, headers?: Record<string, string>): Promise<NotificationCountsResponse> {\n return this.client.put<NotificationCountsResponse>(\n `${this.basePath}/${id}/read`,\n undefined,\n headers,\n )\n }\n\n /**\n * Marks a notification as unread for the current user and resolves the new counts. An unknown id\n * answers 400 `Notification not found.`.\n */\n unread(id: string, headers?: Record<string, string>): Promise<NotificationCountsResponse> {\n return this.client.put<NotificationCountsResponse>(\n `${this.basePath}/${id}/unread`,\n undefined,\n headers,\n )\n }\n\n /**\n * Marks the notifications of `ids` as read. Resolves with no body; a body that is not an array answers\n * 500 `Body must be an array of notification IDs`.\n */\n readMany(ids: string[], headers?: Record<string, string>): Promise<void> {\n return this.client.post<void, string[]>(`${this.basePath}/read-many`, ids, headers)\n }\n\n /**\n * Marks every notification the user sees as read (a GET that writes: it recreates the read receipts of\n * the user) and resolves the counts, as numbers.\n */\n readAll(headers?: Record<string, string>): Promise<NotificationReadAllResponse> {\n return this.client.get<NotificationReadAllResponse>(`${this.basePath}/read-all`, headers)\n }\n\n /** Clears the push badge counter of the current user. Resolves `{ success: true }`. */\n resetBadgeCount(headers?: Record<string, string>): Promise<{ success: true }> {\n return this.client.post<{ success: true }>(\n `${this.basePath}/reset-badge-count`,\n undefined,\n headers,\n )\n }\n\n /**\n * SENDS an announcement (`type: 'announcement'`, which opens a modal in the web app) to every user of\n * the account, or only to the admins with `to: 'admin'`. Resolves `{ message: 'Notificações enviadas' }` before the notifications are created.\n */\n sendAll(\n body: SendAllNotificationsPayload,\n headers?: Record<string, string>,\n ): Promise<{ message: string }> {\n return this.client.post<{ message: string }, SendAllNotificationsPayload>(\n `${this.basePath}/send-all`,\n body,\n headers,\n )\n }\n}\n"],"mappings":";;;;;;;AAgBA,IAAa,mBAAb,cAAsC,YAMpC;CACA,YAAY,QAAmB;AAC7B,QAAM,QAAQ,iBAAiB;;;;;CAMjC,AAAS,WAAW,IAAY,SAAiD;AAC/E,SAAO,MAAM,WAAW,IAAI,QAAQ;;;;;CAMtC,MAAM,SAAuE;AAC3E,SAAO,KAAK,OAAO,KACjB,GAAG,KAAK,SAAS,SACjB,QACA,QACD;;;;;;CAOH,KAAK,IAAY,SAAuE;AACtF,SAAO,KAAK,OAAO,IACjB,GAAG,KAAK,SAAS,GAAG,GAAG,QACvB,QACA,QACD;;;;;;CAOH,OAAO,IAAY,SAAuE;AACxF,SAAO,KAAK,OAAO,IACjB,GAAG,KAAK,SAAS,GAAG,GAAG,UACvB,QACA,QACD;;;;;;CAOH,SAAS,KAAe,SAAiD;AACvE,SAAO,KAAK,OAAO,KAAqB,GAAG,KAAK,SAAS,aAAa,KAAK,QAAQ;;;;;;CAOrF,QAAQ,SAAwE;AAC9E,SAAO,KAAK,OAAO,IAAiC,GAAG,KAAK,SAAS,YAAY,QAAQ;;;CAI3F,gBAAgB,SAA8D;AAC5E,SAAO,KAAK,OAAO,KACjB,GAAG,KAAK,SAAS,qBACjB,QACA,QACD;;;;;;CAOH,QACE,MACA,SAC8B;AAC9B,SAAO,KAAK,OAAO,KACjB,GAAG,KAAK,SAAS,YACjB,MACA,QACD"}
@@ -1,42 +1,88 @@
1
1
  import type { Contact } from '../contacts/types';
2
2
  import type { Schedule } from '../schedule/types';
3
3
  import type { User } from '../users/types';
4
- export type NotificationType = 'schedule' | 'distribution' | 'info' | 'warn' | 'error' | 'announcement' | 'copilot' | 'undefined' | 'waba-health-warning' | 'waba-health-block';
5
- /** Present on pipeline-related notifications. */
4
+ export type NotificationType = 'schedule' | 'distribution' | 'info' | 'warn' | 'error' | 'announcement' | 'copilot' | 'undefined' | 'waba-health-warning' | 'waba-health-block' | 'kanban-board-initialized' | 'users-bulk-archive-blocked' | 'user-import' | 'credits-90' | 'credits-100' | 'smart-summary' | 'warn-service-reconnect';
5
+ /** Extra data of the notification; the pipeline notifications carry the pipeline ids. */
6
6
  export type NotificationConfig = {
7
- pipelineId: string;
8
- pipelineAutomationId: string;
7
+ pipelineId?: string;
8
+ pipelineAutomationId?: string;
9
+ [key: string]: unknown;
10
+ };
11
+ /** The read receipt of a notification for the current user. */
12
+ export type NotificationRead = {
13
+ id: string;
14
+ notificationId: string;
15
+ userId: string;
16
+ readAt: string | null;
17
+ createdAt: string;
18
+ updatedAt: string;
19
+ };
20
+ /**
21
+ * Counts of the notifications the user sees (all of the account with `notification.view.all`).
22
+ * They come as TEXT: the backend answers the `COUNT` of the database as is (e.g. `"43"`).
23
+ */
24
+ export type NotificationCounts = {
25
+ total: string;
26
+ read: string;
27
+ unread: string;
28
+ };
29
+ /** What `read`, `unread` and `count` answer. */
30
+ export type NotificationCountsResponse = {
31
+ count: NotificationCounts;
32
+ };
33
+ /** What `readAll` answers: the counts after marking everything as read, as numbers. */
34
+ export type NotificationReadAllResponse = {
35
+ total: number;
36
+ read: number;
37
+ unread: number;
38
+ };
39
+ /** The body of `sendAll`: `to: 'admin'` sends only to the admins; any other value sends to every user. */
40
+ export type SendAllNotificationsPayload = {
41
+ /** Up to 255 characters. */
42
+ text: string;
43
+ to: 'admin' | 'all' | (string & {});
44
+ image?: string;
9
45
  };
10
46
  export type Notification = {
11
47
  id: string;
12
48
  text: string;
13
49
  type: NotificationType | null;
14
- read: boolean;
50
+ /** `null` on the announcements of `sendAll` until they are read. */
51
+ read: boolean | null;
15
52
  image: string | null;
16
53
  label: string | null;
17
54
  config: NotificationConfig | null;
18
55
  attachedType: string | null;
56
+ attachedId: string | null;
57
+ notificationReadId: string | null;
19
58
  contactId: string | null;
20
59
  userId: string;
21
60
  accountId: string;
22
61
  scheduleId: string | null;
23
62
  createdAt: string;
24
63
  updatedAt: string;
25
- deletedAt: string | null;
64
+ /** @deprecated Not answered: the transformer of the backend does not send it. */
65
+ deletedAt?: string | null;
26
66
  user?: User;
27
67
  schedule?: Schedule | null;
68
+ /** @deprecated Not served: the model has no such association, so it never comes. */
28
69
  contact?: Contact | null;
70
+ notificationRead?: NotificationRead | null;
29
71
  };
30
- export type NotificationRelationships = 'user' | 'schedule' | 'contact';
72
+ /** The backend serves `user`, `schedule` and `notificationRead` (`contact` is never answered). */
73
+ export type NotificationRelationships = 'user' | 'schedule' | 'contact' | 'notificationRead';
31
74
  export type CreateNotificationPayload = {
75
+ /** Up to 255 characters. */
32
76
  text: string;
33
- userId: string;
77
+ /** Ignored: the backend creates the notification for the current user. */
78
+ userId?: string;
34
79
  type?: NotificationType;
35
80
  label?: string;
36
81
  config?: NotificationConfig;
37
82
  attachedType?: string;
38
83
  contactId?: string;
39
84
  scheduleId?: string;
85
+ image?: string;
40
86
  };
41
87
  export type UpdateNotificationPayload = {
42
88
  text?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/apis/notifications/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAA;AAChD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AACjD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAA;AAE1C,MAAM,MAAM,gBAAgB,GACxB,UAAU,GACV,cAAc,GACd,MAAM,GACN,MAAM,GACN,OAAO,GACP,cAAc,GACd,SAAS,GACT,WAAW,GACX,qBAAqB,GACrB,mBAAmB,CAAA;AAEvB,iDAAiD;AACjD,MAAM,MAAM,kBAAkB,GAAG;IAC/B,UAAU,EAAE,MAAM,CAAA;IAClB,oBAAoB,EAAE,MAAM,CAAA;CAC7B,CAAA;AAED,MAAM,MAAM,YAAY,GAAG;IACzB,EAAE,EAAE,MAAM,CAAA;IACV,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,gBAAgB,GAAG,IAAI,CAAA;IAC7B,IAAI,EAAE,OAAO,CAAA;IACb,KAAK,EAAE,MAAM,GAAG,IAAI,CAAA;IACpB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAA;IACpB,MAAM,EAAE,kBAAkB,GAAG,IAAI,CAAA;IACjC,YAAY,EAAE,MAAM,GAAG,IAAI,CAAA;IAC3B,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;IACxB,MAAM,EAAE,MAAM,CAAA;IACd,SAAS,EAAE,MAAM,CAAA;IACj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,MAAM,CAAA;IAClB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,KAAK,CAAC,EAAE,MAAM,CAAA;CACf,CAAA;AAED,MAAM,MAAM,yBAAyB,GAAG;IACtC,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;CACtB,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"ServiceAccessManagementApi.cjs","names":["BaseApi"],"sources":["../../../src/apis/serviceAccessManagement/ServiceAccessManagementApi.ts"],"sourcesContent":["import { BaseApi } from '../../core/BaseApi'\nimport type { ListQuery, Paginated, HasGetMany } from '../../core/types'\nimport type { ServiceAccessManagement } from './types'\n\nexport class ServiceAccessManagementApi\n extends BaseApi\n implements HasGetMany<ServiceAccessManagement>\n{\n /** Returns a paginated list of which users have access to which services. */\n getMany(\n query: ListQuery<ServiceAccessManagement> & { paginate: false },\n headers?: Record<string, string>,\n ): Promise<ServiceAccessManagement[]>\n getMany(\n query?: ListQuery<ServiceAccessManagement> & { paginate?: true },\n headers?: Record<string, string>,\n ): Promise<Paginated<ServiceAccessManagement>>\n getMany(\n query?: ListQuery<ServiceAccessManagement>,\n headers?: Record<string, string>,\n ): Promise<Paginated<ServiceAccessManagement> | ServiceAccessManagement[]>\n getMany(\n query?: ListQuery<ServiceAccessManagement>,\n headers?: Record<string, string>,\n ): Promise<Paginated<ServiceAccessManagement> | ServiceAccessManagement[]> {\n const queryString = this.toQueryString(query)\n return this.client.get<Paginated<ServiceAccessManagement> | ServiceAccessManagement[]>(\n `/service-access-management${queryString}`,\n headers,\n )\n }\n}\n"],"mappings":";;;;AAIA,IAAa,6BAAb,cACUA,6BAEV;CAcE,QACE,OACA,SACyE;EACzE,MAAM,cAAc,KAAK,cAAc,MAAM;AAC7C,SAAO,KAAK,OAAO,IACjB,6BAA6B,eAC7B,QACD"}
1
+ {"version":3,"file":"ServiceAccessManagementApi.cjs","names":["BaseApi"],"sources":["../../../src/apis/serviceAccessManagement/ServiceAccessManagementApi.ts"],"sourcesContent":["import { BaseApi } from '../../core/BaseApi'\nimport type { ListQuery, Paginated, HasGetMany } from '../../core/types'\nimport type { ServiceAccessManagement } from './types'\n\nexport class ServiceAccessManagementApi\n extends BaseApi\n implements HasGetMany<ServiceAccessManagement>\n{\n /**\n * The connections denied to each user (one row per user × connection, written by\n * `POST /services/:id/access-management`), raw. Filter by the `serviceId` or `userId` you want.\n */\n getMany(\n query: ListQuery<ServiceAccessManagement> & { paginate: false },\n headers?: Record<string, string>,\n ): Promise<ServiceAccessManagement[]>\n getMany(\n query?: ListQuery<ServiceAccessManagement> & { paginate?: true },\n headers?: Record<string, string>,\n ): Promise<Paginated<ServiceAccessManagement>>\n getMany(\n query?: ListQuery<ServiceAccessManagement>,\n headers?: Record<string, string>,\n ): Promise<Paginated<ServiceAccessManagement> | ServiceAccessManagement[]>\n getMany(\n query?: ListQuery<ServiceAccessManagement>,\n headers?: Record<string, string>,\n ): Promise<Paginated<ServiceAccessManagement> | ServiceAccessManagement[]> {\n const queryString = this.toQueryString(query)\n return this.client.get<Paginated<ServiceAccessManagement> | ServiceAccessManagement[]>(\n `/service-access-management${queryString}`,\n headers,\n )\n }\n}\n"],"mappings":";;;;AAIA,IAAa,6BAAb,cACUA,6BAEV;CAiBE,QACE,OACA,SACyE;EACzE,MAAM,cAAc,KAAK,cAAc,MAAM;AAC7C,SAAO,KAAK,OAAO,IACjB,6BAA6B,eAC7B,QACD"}
@@ -2,7 +2,10 @@ import { BaseApi } from '../../core/BaseApi';
2
2
  import type { ListQuery, Paginated, HasGetMany } from '../../core/types';
3
3
  import type { ServiceAccessManagement } from './types';
4
4
  export declare class ServiceAccessManagementApi extends BaseApi implements HasGetMany<ServiceAccessManagement> {
5
- /** Returns a paginated list of which users have access to which services. */
5
+ /**
6
+ * The connections denied to each user (one row per user × connection, written by
7
+ * `POST /services/:id/access-management`), raw. Filter by the `serviceId` or `userId` you want.
8
+ */
6
9
  getMany(query: ListQuery<ServiceAccessManagement> & {
7
10
  paginate: false;
8
11
  }, headers?: Record<string, string>): Promise<ServiceAccessManagement[]>;
@@ -1 +1 @@
1
- {"version":3,"file":"ServiceAccessManagementApi.d.ts","sourceRoot":"","sources":["../../../src/apis/serviceAccessManagement/ServiceAccessManagementApi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAA;AAC5C,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AACxE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAA;AAEtD,qBAAa,0BACX,SAAQ,OACR,YAAW,UAAU,CAAC,uBAAuB,CAAC;IAE9C,6EAA6E;IAC7E,OAAO,CACL,KAAK,EAAE,SAAS,CAAC,uBAAuB,CAAC,GAAG;QAAE,QAAQ,EAAE,KAAK,CAAA;KAAE,EAC/D,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,uBAAuB,EAAE,CAAC;IACrC,OAAO,CACL,KAAK,CAAC,EAAE,SAAS,CAAC,uBAAuB,CAAC,GAAG;QAAE,QAAQ,CAAC,EAAE,IAAI,CAAA;KAAE,EAChE,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,SAAS,CAAC,uBAAuB,CAAC,CAAC;IAC9C,OAAO,CACL,KAAK,CAAC,EAAE,SAAS,CAAC,uBAAuB,CAAC,EAC1C,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,SAAS,CAAC,uBAAuB,CAAC,GAAG,uBAAuB,EAAE,CAAC;CAW3E"}
1
+ {"version":3,"file":"ServiceAccessManagementApi.d.ts","sourceRoot":"","sources":["../../../src/apis/serviceAccessManagement/ServiceAccessManagementApi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAA;AAC5C,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AACxE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAA;AAEtD,qBAAa,0BACX,SAAQ,OACR,YAAW,UAAU,CAAC,uBAAuB,CAAC;IAE9C;;;OAGG;IACH,OAAO,CACL,KAAK,EAAE,SAAS,CAAC,uBAAuB,CAAC,GAAG;QAAE,QAAQ,EAAE,KAAK,CAAA;KAAE,EAC/D,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,uBAAuB,EAAE,CAAC;IACrC,OAAO,CACL,KAAK,CAAC,EAAE,SAAS,CAAC,uBAAuB,CAAC,GAAG;QAAE,QAAQ,CAAC,EAAE,IAAI,CAAA;KAAE,EAChE,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,SAAS,CAAC,uBAAuB,CAAC,CAAC;IAC9C,OAAO,CACL,KAAK,CAAC,EAAE,SAAS,CAAC,uBAAuB,CAAC,EAC1C,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,SAAS,CAAC,uBAAuB,CAAC,GAAG,uBAAuB,EAAE,CAAC;CAW3E"}
@@ -1 +1 @@
1
- {"version":3,"file":"ServiceAccessManagementApi.mjs","names":[],"sources":["../../../src/apis/serviceAccessManagement/ServiceAccessManagementApi.ts"],"sourcesContent":["import { BaseApi } from '../../core/BaseApi'\nimport type { ListQuery, Paginated, HasGetMany } from '../../core/types'\nimport type { ServiceAccessManagement } from './types'\n\nexport class ServiceAccessManagementApi\n extends BaseApi\n implements HasGetMany<ServiceAccessManagement>\n{\n /** Returns a paginated list of which users have access to which services. */\n getMany(\n query: ListQuery<ServiceAccessManagement> & { paginate: false },\n headers?: Record<string, string>,\n ): Promise<ServiceAccessManagement[]>\n getMany(\n query?: ListQuery<ServiceAccessManagement> & { paginate?: true },\n headers?: Record<string, string>,\n ): Promise<Paginated<ServiceAccessManagement>>\n getMany(\n query?: ListQuery<ServiceAccessManagement>,\n headers?: Record<string, string>,\n ): Promise<Paginated<ServiceAccessManagement> | ServiceAccessManagement[]>\n getMany(\n query?: ListQuery<ServiceAccessManagement>,\n headers?: Record<string, string>,\n ): Promise<Paginated<ServiceAccessManagement> | ServiceAccessManagement[]> {\n const queryString = this.toQueryString(query)\n return this.client.get<Paginated<ServiceAccessManagement> | ServiceAccessManagement[]>(\n `/service-access-management${queryString}`,\n headers,\n )\n }\n}\n"],"mappings":";;;AAIA,IAAa,6BAAb,cACU,QAEV;CAcE,QACE,OACA,SACyE;EACzE,MAAM,cAAc,KAAK,cAAc,MAAM;AAC7C,SAAO,KAAK,OAAO,IACjB,6BAA6B,eAC7B,QACD"}
1
+ {"version":3,"file":"ServiceAccessManagementApi.mjs","names":[],"sources":["../../../src/apis/serviceAccessManagement/ServiceAccessManagementApi.ts"],"sourcesContent":["import { BaseApi } from '../../core/BaseApi'\nimport type { ListQuery, Paginated, HasGetMany } from '../../core/types'\nimport type { ServiceAccessManagement } from './types'\n\nexport class ServiceAccessManagementApi\n extends BaseApi\n implements HasGetMany<ServiceAccessManagement>\n{\n /**\n * The connections denied to each user (one row per user × connection, written by\n * `POST /services/:id/access-management`), raw. Filter by the `serviceId` or `userId` you want.\n */\n getMany(\n query: ListQuery<ServiceAccessManagement> & { paginate: false },\n headers?: Record<string, string>,\n ): Promise<ServiceAccessManagement[]>\n getMany(\n query?: ListQuery<ServiceAccessManagement> & { paginate?: true },\n headers?: Record<string, string>,\n ): Promise<Paginated<ServiceAccessManagement>>\n getMany(\n query?: ListQuery<ServiceAccessManagement>,\n headers?: Record<string, string>,\n ): Promise<Paginated<ServiceAccessManagement> | ServiceAccessManagement[]>\n getMany(\n query?: ListQuery<ServiceAccessManagement>,\n headers?: Record<string, string>,\n ): Promise<Paginated<ServiceAccessManagement> | ServiceAccessManagement[]> {\n const queryString = this.toQueryString(query)\n return this.client.get<Paginated<ServiceAccessManagement> | ServiceAccessManagement[]>(\n `/service-access-management${queryString}`,\n headers,\n )\n }\n}\n"],"mappings":";;;AAIA,IAAa,6BAAb,cACU,QAEV;CAiBE,QACE,OACA,SACyE;EACzE,MAAM,cAAc,KAAK,cAAc,MAAM;AAC7C,SAAO,KAAK,OAAO,IACjB,6BAA6B,eAC7B,QACD"}
@@ -4,8 +4,11 @@ export type ServiceAccessManagement = {
4
4
  userId: string;
5
5
  serviceId: string;
6
6
  createdAt: string;
7
+ /** @deprecated Not served: the backend drops every include of this route. */
7
8
  user?: User;
9
+ /** @deprecated Not served: the backend drops every include of this route. */
8
10
  service?: Service;
9
11
  };
12
+ /** None is served: the backend drops every include of this route. */
10
13
  export type ServiceAccessManagementRelationships = 'user' | 'service';
11
14
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/apis/serviceAccessManagement/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAA;AAChD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAA;AAE1C,MAAM,MAAM,uBAAuB,GAAG;IACpC,MAAM,EAAE,MAAM,CAAA;IACd,SAAS,EAAE,MAAM,CAAA;IACjB,SAAS,EAAE,MAAM,CAAA;IAEjB,IAAI,CAAC,EAAE,IAAI,CAAA;IACX,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB,CAAA;AAED,MAAM,MAAM,oCAAoC,GAAG,MAAM,GAAG,SAAS,CAAA"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/apis/serviceAccessManagement/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAA;AAChD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAA;AAE1C,MAAM,MAAM,uBAAuB,GAAG;IACpC,MAAM,EAAE,MAAM,CAAA;IACd,SAAS,EAAE,MAAM,CAAA;IACjB,SAAS,EAAE,MAAM,CAAA;IAEjB,6EAA6E;IAC7E,IAAI,CAAC,EAAE,IAAI,CAAA;IACX,6EAA6E;IAC7E,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB,CAAA;AAED,qEAAqE;AACrE,MAAM,MAAM,oCAAoC,GAAG,MAAM,GAAG,SAAS,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"StickerUsersApi.cjs","names":["BaseApi"],"sources":["../../../src/apis/stickerUsers/StickerUsersApi.ts"],"sourcesContent":["import { BaseApi } from '../../core/BaseApi'\nimport type { ListQuery, Paginated, HasGetMany } from '../../core/types'\nimport type { StickerUser } from './types'\n\nexport class StickerUsersApi extends BaseApi implements HasGetMany<StickerUser> {\n /**\n * Returns a paginated list of sticker-user associations with their related file.\n * @permissions stickers.send\n */\n getMany(\n query: ListQuery<StickerUser> & { paginate: false },\n headers?: Record<string, string>,\n ): Promise<StickerUser[]>\n getMany(\n query?: ListQuery<StickerUser> & { paginate?: true },\n headers?: Record<string, string>,\n ): Promise<Paginated<StickerUser>>\n getMany(\n query?: ListQuery<StickerUser>,\n headers?: Record<string, string>,\n ): Promise<Paginated<StickerUser> | StickerUser[]>\n getMany(\n query?: ListQuery<StickerUser>,\n headers?: Record<string, string>,\n ): Promise<Paginated<StickerUser> | StickerUser[]> {\n const queryString = this.toQueryString(query)\n return this.client.get<Paginated<StickerUser> | StickerUser[]>(\n `/sticker-users${queryString}`,\n headers,\n )\n }\n}\n"],"mappings":";;;;AAIA,IAAa,kBAAb,cAAqCA,6BAA2C;CAiB9E,QACE,OACA,SACiD;EACjD,MAAM,cAAc,KAAK,cAAc,MAAM;AAC7C,SAAO,KAAK,OAAO,IACjB,iBAAiB,eACjB,QACD"}
1
+ {"version":3,"file":"StickerUsersApi.cjs","names":["BaseApi"],"sources":["../../../src/apis/stickerUsers/StickerUsersApi.ts"],"sourcesContent":["import { BaseApi } from '../../core/BaseApi'\nimport type { ListQuery, Paginated, HasGetMany } from '../../core/types'\nimport type { StickerUser } from './types'\n\nexport class StickerUsersApi extends BaseApi implements HasGetMany<StickerUser> {\n /**\n * The stickers the current user sent recently (`lastSendAt`), paginated; only the `file` include is\n * served. A row is written when the user sends a message of type `sticker` (in the background, after the\n * send).\n * @permissions stickers.send\n */\n getMany(\n query: ListQuery<StickerUser> & { paginate: false },\n headers?: Record<string, string>,\n ): Promise<StickerUser[]>\n getMany(\n query?: ListQuery<StickerUser> & { paginate?: true },\n headers?: Record<string, string>,\n ): Promise<Paginated<StickerUser>>\n getMany(\n query?: ListQuery<StickerUser>,\n headers?: Record<string, string>,\n ): Promise<Paginated<StickerUser> | StickerUser[]>\n getMany(\n query?: ListQuery<StickerUser>,\n headers?: Record<string, string>,\n ): Promise<Paginated<StickerUser> | StickerUser[]> {\n const queryString = this.toQueryString(query)\n return this.client.get<Paginated<StickerUser> | StickerUser[]>(\n `/sticker-users${queryString}`,\n headers,\n )\n }\n}\n"],"mappings":";;;;AAIA,IAAa,kBAAb,cAAqCA,6BAA2C;CAmB9E,QACE,OACA,SACiD;EACjD,MAAM,cAAc,KAAK,cAAc,MAAM;AAC7C,SAAO,KAAK,OAAO,IACjB,iBAAiB,eACjB,QACD"}
@@ -3,7 +3,9 @@ import type { ListQuery, Paginated, HasGetMany } from '../../core/types';
3
3
  import type { StickerUser } from './types';
4
4
  export declare class StickerUsersApi extends BaseApi implements HasGetMany<StickerUser> {
5
5
  /**
6
- * Returns a paginated list of sticker-user associations with their related file.
6
+ * The stickers the current user sent recently (`lastSendAt`), paginated; only the `file` include is
7
+ * served. A row is written when the user sends a message of type `sticker` (in the background, after the
8
+ * send).
7
9
  * @permissions stickers.send
8
10
  */
9
11
  getMany(query: ListQuery<StickerUser> & {
@@ -1 +1 @@
1
- {"version":3,"file":"StickerUsersApi.d.ts","sourceRoot":"","sources":["../../../src/apis/stickerUsers/StickerUsersApi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAA;AAC5C,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AACxE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,SAAS,CAAA;AAE1C,qBAAa,eAAgB,SAAQ,OAAQ,YAAW,UAAU,CAAC,WAAW,CAAC;IAC7E;;;OAGG;IACH,OAAO,CACL,KAAK,EAAE,SAAS,CAAC,WAAW,CAAC,GAAG;QAAE,QAAQ,EAAE,KAAK,CAAA;KAAE,EACnD,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,WAAW,EAAE,CAAC;IACzB,OAAO,CACL,KAAK,CAAC,EAAE,SAAS,CAAC,WAAW,CAAC,GAAG;QAAE,QAAQ,CAAC,EAAE,IAAI,CAAA;KAAE,EACpD,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,SAAS,CAAC,WAAW,CAAC,CAAC;IAClC,OAAO,CACL,KAAK,CAAC,EAAE,SAAS,CAAC,WAAW,CAAC,EAC9B,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,SAAS,CAAC,WAAW,CAAC,GAAG,WAAW,EAAE,CAAC;CAWnD"}
1
+ {"version":3,"file":"StickerUsersApi.d.ts","sourceRoot":"","sources":["../../../src/apis/stickerUsers/StickerUsersApi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAA;AAC5C,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AACxE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,SAAS,CAAA;AAE1C,qBAAa,eAAgB,SAAQ,OAAQ,YAAW,UAAU,CAAC,WAAW,CAAC;IAC7E;;;;;OAKG;IACH,OAAO,CACL,KAAK,EAAE,SAAS,CAAC,WAAW,CAAC,GAAG;QAAE,QAAQ,EAAE,KAAK,CAAA;KAAE,EACnD,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,WAAW,EAAE,CAAC;IACzB,OAAO,CACL,KAAK,CAAC,EAAE,SAAS,CAAC,WAAW,CAAC,GAAG;QAAE,QAAQ,CAAC,EAAE,IAAI,CAAA;KAAE,EACpD,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,SAAS,CAAC,WAAW,CAAC,CAAC;IAClC,OAAO,CACL,KAAK,CAAC,EAAE,SAAS,CAAC,WAAW,CAAC,EAC9B,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,SAAS,CAAC,WAAW,CAAC,GAAG,WAAW,EAAE,CAAC;CAWnD"}
@@ -1 +1 @@
1
- {"version":3,"file":"StickerUsersApi.mjs","names":[],"sources":["../../../src/apis/stickerUsers/StickerUsersApi.ts"],"sourcesContent":["import { BaseApi } from '../../core/BaseApi'\nimport type { ListQuery, Paginated, HasGetMany } from '../../core/types'\nimport type { StickerUser } from './types'\n\nexport class StickerUsersApi extends BaseApi implements HasGetMany<StickerUser> {\n /**\n * Returns a paginated list of sticker-user associations with their related file.\n * @permissions stickers.send\n */\n getMany(\n query: ListQuery<StickerUser> & { paginate: false },\n headers?: Record<string, string>,\n ): Promise<StickerUser[]>\n getMany(\n query?: ListQuery<StickerUser> & { paginate?: true },\n headers?: Record<string, string>,\n ): Promise<Paginated<StickerUser>>\n getMany(\n query?: ListQuery<StickerUser>,\n headers?: Record<string, string>,\n ): Promise<Paginated<StickerUser> | StickerUser[]>\n getMany(\n query?: ListQuery<StickerUser>,\n headers?: Record<string, string>,\n ): Promise<Paginated<StickerUser> | StickerUser[]> {\n const queryString = this.toQueryString(query)\n return this.client.get<Paginated<StickerUser> | StickerUser[]>(\n `/sticker-users${queryString}`,\n headers,\n )\n }\n}\n"],"mappings":";;;AAIA,IAAa,kBAAb,cAAqC,QAA2C;CAiB9E,QACE,OACA,SACiD;EACjD,MAAM,cAAc,KAAK,cAAc,MAAM;AAC7C,SAAO,KAAK,OAAO,IACjB,iBAAiB,eACjB,QACD"}
1
+ {"version":3,"file":"StickerUsersApi.mjs","names":[],"sources":["../../../src/apis/stickerUsers/StickerUsersApi.ts"],"sourcesContent":["import { BaseApi } from '../../core/BaseApi'\nimport type { ListQuery, Paginated, HasGetMany } from '../../core/types'\nimport type { StickerUser } from './types'\n\nexport class StickerUsersApi extends BaseApi implements HasGetMany<StickerUser> {\n /**\n * The stickers the current user sent recently (`lastSendAt`), paginated; only the `file` include is\n * served. A row is written when the user sends a message of type `sticker` (in the background, after the\n * send).\n * @permissions stickers.send\n */\n getMany(\n query: ListQuery<StickerUser> & { paginate: false },\n headers?: Record<string, string>,\n ): Promise<StickerUser[]>\n getMany(\n query?: ListQuery<StickerUser> & { paginate?: true },\n headers?: Record<string, string>,\n ): Promise<Paginated<StickerUser>>\n getMany(\n query?: ListQuery<StickerUser>,\n headers?: Record<string, string>,\n ): Promise<Paginated<StickerUser> | StickerUser[]>\n getMany(\n query?: ListQuery<StickerUser>,\n headers?: Record<string, string>,\n ): Promise<Paginated<StickerUser> | StickerUser[]> {\n const queryString = this.toQueryString(query)\n return this.client.get<Paginated<StickerUser> | StickerUser[]>(\n `/sticker-users${queryString}`,\n headers,\n )\n }\n}\n"],"mappings":";;;AAIA,IAAa,kBAAb,cAAqC,QAA2C;CAmB9E,QACE,OACA,SACiD;EACjD,MAAM,cAAc,KAAK,cAAc,MAAM;AAC7C,SAAO,KAAK,OAAO,IACjB,iBAAiB,eACjB,QACD"}
@@ -8,9 +8,13 @@ export type StickerUser = {
8
8
  lastSendAt: string;
9
9
  createdAt: string;
10
10
  updatedAt: string;
11
+ /** @deprecated Not served: the backend only serves the `file` include. */
11
12
  sticker?: Sticker;
13
+ /** @deprecated Not served: the backend only serves the `file` include. */
12
14
  user?: User;
15
+ /** The image of the sticker. */
13
16
  file?: File;
14
17
  };
18
+ /** The backend serves only `file` (`sticker` and `user` are dropped). */
15
19
  export type StickerUserRelationships = 'sticker' | 'user' | 'file';
16
20
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/apis/stickerUsers/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAA;AAC1C,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAA;AAChD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAA;AAE1C,MAAM,MAAM,WAAW,GAAG;IACxB,SAAS,EAAE,MAAM,CAAA;IACjB,MAAM,EAAE,MAAM,CAAA;IACd,SAAS,EAAE,MAAM,CAAA;IACjB,UAAU,EAAE,MAAM,CAAA;IAClB,SAAS,EAAE,MAAM,CAAA;IACjB,SAAS,EAAE,MAAM,CAAA;IAEjB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,IAAI,CAAC,EAAE,IAAI,CAAA;IACX,IAAI,CAAC,EAAE,IAAI,CAAA;CACZ,CAAA;AAED,MAAM,MAAM,wBAAwB,GAAG,SAAS,GAAG,MAAM,GAAG,MAAM,CAAA"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/apis/stickerUsers/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAA;AAC1C,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAA;AAChD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAA;AAE1C,MAAM,MAAM,WAAW,GAAG;IACxB,SAAS,EAAE,MAAM,CAAA;IACjB,MAAM,EAAE,MAAM,CAAA;IACd,SAAS,EAAE,MAAM,CAAA;IACjB,UAAU,EAAE,MAAM,CAAA;IAClB,SAAS,EAAE,MAAM,CAAA;IACjB,SAAS,EAAE,MAAM,CAAA;IAEjB,0EAA0E;IAC1E,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,0EAA0E;IAC1E,IAAI,CAAC,EAAE,IAAI,CAAA;IACX,gCAAgC;IAChC,IAAI,CAAC,EAAE,IAAI,CAAA;CACZ,CAAA;AAED,yEAAyE;AACzE,MAAM,MAAM,wBAAwB,GAAG,SAAS,GAAG,MAAM,GAAG,MAAM,CAAA"}
@@ -3,9 +3,10 @@ const require_core_BaseCrudApi = require('../../core/BaseCrudApi.cjs');
3
3
 
4
4
  //#region src/apis/stickers/StickersApi.ts
5
5
  /**
6
- * Stickers of the account. The backend serves `GET /stickers` and `POST /stickers` (plus
7
- * `GET /stickers/exist`, `POST /stickers/add` and `DELETE /stickers/remove/:stickerId`); there is
8
- * no read by id, update nor `DELETE /stickers/:id`.
6
+ * Stickers of the account: every user of the account sees them. The backend serves `GET /stickers`,
7
+ * `POST /stickers`, `GET /stickers/exist`, `POST /stickers/add` and `DELETE /stickers/remove/:stickerId`;
8
+ * there is no read by id, update nor `DELETE /stickers/:id`. The list accepts only the `file` include.
9
+ * @permissions stickers.send (list) · stickers.management (create, exist, add, remove)
9
10
  */
10
11
  var StickersApi = class extends require_core_BaseCrudApi.BaseCrudApi {
11
12
  constructor(client) {
@@ -26,6 +27,29 @@ var StickersApi = class extends require_core_BaseCrudApi.BaseCrudApi {
26
27
  deleteById(id, headers) {
27
28
  return super.deleteById(id, headers);
28
29
  }
30
+ /**
31
+ * Finds the sticker of the account that came from the message, or from the file of `fileChecksum` or
32
+ * `filehash`. Resolves `{ stickerId }`, or `{}` when there is none; without `messageId` it answers 500
33
+ * `Invalid message ID`.
34
+ */
35
+ exist(query, headers) {
36
+ return this.client.get(`${this.basePath}/exist${this.toQueryString(query)}`, headers);
37
+ }
38
+ /**
39
+ * Turns the file of a message of the account into a sticker (`type: 'added'`). Idempotent: a sticker that
40
+ * already came from the message (or its file) is answered as is, and a removed one is restored. A message
41
+ * without file answers 500 `Message or file not found`.
42
+ */
43
+ add(messageId, headers) {
44
+ return this.client.post(`${this.basePath}/add`, { messageId }, headers);
45
+ }
46
+ /**
47
+ * Removes a sticker of the account (soft delete; its file stays in the storage) and clears it from the
48
+ * recent stickers of every user. Resolves the text `'OK'`, or `false` when there is no such sticker.
49
+ */
50
+ remove(stickerId, headers) {
51
+ return this.client.delete(`${this.basePath}/remove/${stickerId}`, headers);
52
+ }
29
53
  };
30
54
 
31
55
  //#endregion
@@ -1 +1 @@
1
- {"version":3,"file":"StickersApi.cjs","names":["BaseCrudApi"],"sources":["../../../src/apis/stickers/StickersApi.ts"],"sourcesContent":["import type { ApiClient } from '../../core/ApiClient'\nimport { BaseCrudApi } from '../../core/BaseCrudApi'\nimport type { GetByIdQuery } from '../../core/types'\nimport type { Sticker, CreateStickerPayload, UpdateStickerPayload } from './types'\n\n/**\n * Stickers of the account. The backend serves `GET /stickers` and `POST /stickers` (plus\n * `GET /stickers/exist`, `POST /stickers/add` and `DELETE /stickers/remove/:stickerId`); there is\n * no read by id, update nor `DELETE /stickers/:id`.\n */\nexport class StickersApi extends BaseCrudApi<Sticker, CreateStickerPayload, UpdateStickerPayload> {\n constructor(client: ApiClient) {\n super(client, '/stickers')\n }\n\n /** @deprecated Not served: the backend has no GET /stickers/:id, so this route answers 404. */\n override getById(\n id: string,\n query?: GetByIdQuery<Sticker>,\n headers?: Record<string, string>,\n ): Promise<Sticker> {\n return super.getById(id, query, headers)\n }\n\n /** @deprecated Not served: the backend has no PUT /stickers/:id, so this route answers 404. */\n override updateById(\n id: string,\n body: UpdateStickerPayload,\n headers?: Record<string, string>,\n ): Promise<Sticker> {\n return super.updateById(id, body, headers)\n }\n\n /**\n * @deprecated Not served: the backend has no DELETE /stickers/:id (it removes a sticker by\n * `DELETE /stickers/remove/:stickerId`), so this route answers 404.\n */\n override deleteById(id: string, headers?: Record<string, string>): Promise<Sticker> {\n return super.deleteById(id, headers)\n }\n}\n"],"mappings":";;;;;;;;;AAUA,IAAa,cAAb,cAAiCA,qCAAiE;CAChG,YAAY,QAAmB;AAC7B,QAAM,QAAQ,YAAY;;;CAI5B,AAAS,QACP,IACA,OACA,SACkB;AAClB,SAAO,MAAM,QAAQ,IAAI,OAAO,QAAQ;;;CAI1C,AAAS,WACP,IACA,MACA,SACkB;AAClB,SAAO,MAAM,WAAW,IAAI,MAAM,QAAQ;;;;;;CAO5C,AAAS,WAAW,IAAY,SAAoD;AAClF,SAAO,MAAM,WAAW,IAAI,QAAQ"}
1
+ {"version":3,"file":"StickersApi.cjs","names":["BaseCrudApi"],"sources":["../../../src/apis/stickers/StickersApi.ts"],"sourcesContent":["import type { ApiClient } from '../../core/ApiClient'\nimport { BaseCrudApi } from '../../core/BaseCrudApi'\nimport type { GetByIdQuery } from '../../core/types'\nimport type {\n Sticker,\n CreateStickerPayload,\n UpdateStickerPayload,\n StickerExistQuery,\n} from './types'\n\n/**\n * Stickers of the account: every user of the account sees them. The backend serves `GET /stickers`,\n * `POST /stickers`, `GET /stickers/exist`, `POST /stickers/add` and `DELETE /stickers/remove/:stickerId`;\n * there is no read by id, update nor `DELETE /stickers/:id`. The list accepts only the `file` include.\n * @permissions stickers.send (list) · stickers.management (create, exist, add, remove)\n */\nexport class StickersApi extends BaseCrudApi<Sticker, CreateStickerPayload, UpdateStickerPayload> {\n constructor(client: ApiClient) {\n super(client, '/stickers')\n }\n\n /** @deprecated Not served: the backend has no GET /stickers/:id, so this route answers 404. */\n override getById(\n id: string,\n query?: GetByIdQuery<Sticker>,\n headers?: Record<string, string>,\n ): Promise<Sticker> {\n return super.getById(id, query, headers)\n }\n\n /** @deprecated Not served: the backend has no PUT /stickers/:id, so this route answers 404. */\n override updateById(\n id: string,\n body: UpdateStickerPayload,\n headers?: Record<string, string>,\n ): Promise<Sticker> {\n return super.updateById(id, body, headers)\n }\n\n /**\n * @deprecated Not served: the backend has no DELETE /stickers/:id (it removes a sticker by\n * `DELETE /stickers/remove/:stickerId`), so this route answers 404.\n */\n override deleteById(id: string, headers?: Record<string, string>): Promise<Sticker> {\n return super.deleteById(id, headers)\n }\n\n /**\n * Finds the sticker of the account that came from the message, or from the file of `fileChecksum` or\n * `filehash`. Resolves `{ stickerId }`, or `{}` when there is none; without `messageId` it answers 500\n * `Invalid message ID`.\n */\n exist(\n query: StickerExistQuery,\n headers?: Record<string, string>,\n ): Promise<{ stickerId?: string }> {\n return this.client.get<{ stickerId?: string }>(\n `${this.basePath}/exist${this.toQueryString(query)}`,\n headers,\n )\n }\n\n /**\n * Turns the file of a message of the account into a sticker (`type: 'added'`). Idempotent: a sticker that\n * already came from the message (or its file) is answered as is, and a removed one is restored. A message\n * without file answers 500 `Message or file not found`.\n */\n add(messageId: string, headers?: Record<string, string>): Promise<Sticker> {\n return this.client.post<Sticker, { messageId: string }>(\n `${this.basePath}/add`,\n { messageId },\n headers,\n )\n }\n\n /**\n * Removes a sticker of the account (soft delete; its file stays in the storage) and clears it from the\n * recent stickers of every user. Resolves the text `'OK'`, or `false` when there is no such sticker.\n */\n remove(stickerId: string, headers?: Record<string, string>): Promise<'OK' | false> {\n return this.client.delete<'OK' | false>(`${this.basePath}/remove/${stickerId}`, headers)\n }\n}\n"],"mappings":";;;;;;;;;;AAgBA,IAAa,cAAb,cAAiCA,qCAAiE;CAChG,YAAY,QAAmB;AAC7B,QAAM,QAAQ,YAAY;;;CAI5B,AAAS,QACP,IACA,OACA,SACkB;AAClB,SAAO,MAAM,QAAQ,IAAI,OAAO,QAAQ;;;CAI1C,AAAS,WACP,IACA,MACA,SACkB;AAClB,SAAO,MAAM,WAAW,IAAI,MAAM,QAAQ;;;;;;CAO5C,AAAS,WAAW,IAAY,SAAoD;AAClF,SAAO,MAAM,WAAW,IAAI,QAAQ;;;;;;;CAQtC,MACE,OACA,SACiC;AACjC,SAAO,KAAK,OAAO,IACjB,GAAG,KAAK,SAAS,QAAQ,KAAK,cAAc,MAAM,IAClD,QACD;;;;;;;CAQH,IAAI,WAAmB,SAAoD;AACzE,SAAO,KAAK,OAAO,KACjB,GAAG,KAAK,SAAS,OACjB,EAAE,WAAW,EACb,QACD;;;;;;CAOH,OAAO,WAAmB,SAAyD;AACjF,SAAO,KAAK,OAAO,OAAqB,GAAG,KAAK,SAAS,UAAU,aAAa,QAAQ"}
@@ -1,11 +1,12 @@
1
1
  import type { ApiClient } from '../../core/ApiClient';
2
2
  import { BaseCrudApi } from '../../core/BaseCrudApi';
3
3
  import type { GetByIdQuery } from '../../core/types';
4
- import type { Sticker, CreateStickerPayload, UpdateStickerPayload } from './types';
4
+ import type { Sticker, CreateStickerPayload, UpdateStickerPayload, StickerExistQuery } from './types';
5
5
  /**
6
- * Stickers of the account. The backend serves `GET /stickers` and `POST /stickers` (plus
7
- * `GET /stickers/exist`, `POST /stickers/add` and `DELETE /stickers/remove/:stickerId`); there is
8
- * no read by id, update nor `DELETE /stickers/:id`.
6
+ * Stickers of the account: every user of the account sees them. The backend serves `GET /stickers`,
7
+ * `POST /stickers`, `GET /stickers/exist`, `POST /stickers/add` and `DELETE /stickers/remove/:stickerId`;
8
+ * there is no read by id, update nor `DELETE /stickers/:id`. The list accepts only the `file` include.
9
+ * @permissions stickers.send (list) · stickers.management (create, exist, add, remove)
9
10
  */
10
11
  export declare class StickersApi extends BaseCrudApi<Sticker, CreateStickerPayload, UpdateStickerPayload> {
11
12
  constructor(client: ApiClient);
@@ -18,5 +19,24 @@ export declare class StickersApi extends BaseCrudApi<Sticker, CreateStickerPaylo
18
19
  * `DELETE /stickers/remove/:stickerId`), so this route answers 404.
19
20
  */
20
21
  deleteById(id: string, headers?: Record<string, string>): Promise<Sticker>;
22
+ /**
23
+ * Finds the sticker of the account that came from the message, or from the file of `fileChecksum` or
24
+ * `filehash`. Resolves `{ stickerId }`, or `{}` when there is none; without `messageId` it answers 500
25
+ * `Invalid message ID`.
26
+ */
27
+ exist(query: StickerExistQuery, headers?: Record<string, string>): Promise<{
28
+ stickerId?: string;
29
+ }>;
30
+ /**
31
+ * Turns the file of a message of the account into a sticker (`type: 'added'`). Idempotent: a sticker that
32
+ * already came from the message (or its file) is answered as is, and a removed one is restored. A message
33
+ * without file answers 500 `Message or file not found`.
34
+ */
35
+ add(messageId: string, headers?: Record<string, string>): Promise<Sticker>;
36
+ /**
37
+ * Removes a sticker of the account (soft delete; its file stays in the storage) and clears it from the
38
+ * recent stickers of every user. Resolves the text `'OK'`, or `false` when there is no such sticker.
39
+ */
40
+ remove(stickerId: string, headers?: Record<string, string>): Promise<'OK' | false>;
21
41
  }
22
42
  //# sourceMappingURL=StickersApi.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"StickersApi.d.ts","sourceRoot":"","sources":["../../../src/apis/stickers/StickersApi.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAA;AACrD,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAA;AACpD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAA;AACpD,OAAO,KAAK,EAAE,OAAO,EAAE,oBAAoB,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAA;AAElF;;;;GAIG;AACH,qBAAa,WAAY,SAAQ,WAAW,CAAC,OAAO,EAAE,oBAAoB,EAAE,oBAAoB,CAAC;gBACnF,MAAM,EAAE,SAAS;IAI7B,+FAA+F;IACtF,OAAO,CACd,EAAE,EAAE,MAAM,EACV,KAAK,CAAC,EAAE,YAAY,CAAC,OAAO,CAAC,EAC7B,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC/B,OAAO,CAAC,OAAO,CAAC;IAInB,+FAA+F;IACtF,UAAU,CACjB,EAAE,EAAE,MAAM,EACV,IAAI,EAAE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