@nomalism-com/api 1.3.22 → 1.3.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.
package/dist/index.d.ts CHANGED
@@ -59,15 +59,15 @@ declare class Repository$1S implements Nomalism$1.Chat.IRepository {
59
59
  route: string;
60
60
  private api;
61
61
  constructor({ api, route }: IModuleConstructor);
62
- findActiveByOwnerId(params: Nomalism$1.shared.IFindByOwnerIdRequest): Promise<Nomalism$1.Chat.IPublicFindActiveByOwnerIdResponse>;
63
- clientWebAppFindActiveByOwnerId(params: Nomalism$1.shared.IFindByOwnerIdRequest): Promise<Nomalism$1.Chat.IPublicClientWebAppFindActiveByOwnerIdResponse>;
64
- findActiveBySubscriberId(params: Nomalism$1.shared.IFindByOwnerIdRequest): Promise<Nomalism$1.Chat.IPublicFindBySubscriberId>;
62
+ findActiveByOwnerId(params: Nomalism$1.shared.IFindByIdRequest): Promise<Nomalism$1.Chat.IFindActiveByOwnerIdResponse>;
63
+ clientWebAppFindActiveByOwnerId(params: Nomalism$1.shared.IFindByIdRequest): Promise<Nomalism$1.Chat.IPublicClientWebAppFindActiveByOwnerIdResponse>;
64
+ findActiveBySubscriberId(params: Nomalism$1.shared.IFindByIdRequest): Promise<Nomalism$1.Chat.IPublicFindBySubscriberId>;
65
65
  create(body: Nomalism$1.Chat.ICreateRequest): Promise<Nomalism$1.Chat.Entity>;
66
- update(selector: Nomalism$1.shared.IFindByIdRequest, body: Nomalism$1.Chat.IUpdateRequest): Promise<void>;
67
- deleteOne(selector: Nomalism$1.shared.IFindByIdRequest): Promise<void>;
68
- resendLast({ owner_id }: Nomalism$1.shared.IFindByOwnerIdRequest): Promise<void>;
69
- markAllAsRead(params: Nomalism$1.shared.IFindByOwnerIdRequest): Promise<void>;
70
- markAllAsUnread(params: Nomalism$1.shared.IFindByOwnerIdRequest): Promise<void>;
66
+ update({ id }: Nomalism$1.shared.IFindByIdRequest, body: Nomalism$1.Chat.IUpdateRequest): Promise<void>;
67
+ deleteOne({ id }: Nomalism$1.shared.IFindByIdRequest): Promise<void>;
68
+ resendLast({ id }: Nomalism$1.shared.IFindByIdRequest): Promise<void>;
69
+ markAllAsRead({ id }: Nomalism$1.shared.IFindByIdRequest): Promise<void>;
70
+ markAllAsUnread({ id }: Nomalism$1.shared.IFindByIdRequest): Promise<void>;
71
71
  publicMarkAllClientReadUnread(params: Nomalism$1.Chat.IMarkAllClientReadUnreadRequest): Promise<void>;
72
72
  }
73
73
 
package/dist/index.js CHANGED
@@ -290,24 +290,24 @@ var Repository4 = class {
290
290
  const response = await this.api.post(`${this.route}`, body);
291
291
  return response.data;
292
292
  }
293
- async update(selector, body) {
294
- await this.api.put(`${this.route}${selector.id}`, body);
293
+ async update({ id }, body) {
294
+ await this.api.put(`${this.route}${id}`, body);
295
295
  }
296
- async deleteOne(selector) {
297
- await this.api.delete(`${this.route}${selector.id}`);
296
+ async deleteOne({ id }) {
297
+ await this.api.delete(`${this.route}${id}`);
298
298
  }
299
- async resendLast({ owner_id }) {
300
- await this.api.post(`${this.route}resend_last/${owner_id}`);
299
+ async resendLast({ id }) {
300
+ await this.api.post(`${this.route}resend_last/${id}`);
301
301
  }
302
- async markAllAsRead(params) {
303
- await this.api.put(`${this.route}mark_all_as_read/${params.owner_id}`);
302
+ async markAllAsRead({ id }) {
303
+ await this.api.put(`${this.route}mark_all_as_read/${id}`);
304
304
  }
305
- async markAllAsUnread(params) {
306
- await this.api.put(`${this.route}mark_all_as_unread/${params.owner_id}`);
305
+ async markAllAsUnread({ id }) {
306
+ await this.api.put(`${this.route}mark_all_as_unread/${id}`);
307
307
  }
308
308
  async publicMarkAllClientReadUnread(params) {
309
309
  await this.api.put(
310
- `${this.route}mark_all_client_read_unread/${params.owner_id}/${params.client_read}`
310
+ `${this.route}mark_all_client_read_unread/${params.chat_document_header_id}/${params.client_read}`
311
311
  );
312
312
  }
313
313
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@nomalism-com/api",
3
3
  "description": "A nomalism API package for performing HTTP requests on API endpoints",
4
- "version": "1.3.22",
4
+ "version": "1.3.24",
5
5
  "author": "Nomalism <it.nomalism@gmail.com> (https://https://nomalism.com/)",
6
6
  "license": "UNLICENSED",
7
7
  "type": "module",
@@ -23,14 +23,14 @@
23
23
  "prepack": "npm run lint && npm run build"
24
24
  },
25
25
  "dependencies": {
26
- "@nomalism-com/types": "^1.3.25",
27
- "axios": "^1.13.4"
26
+ "@nomalism-com/types": "^1.3.28",
27
+ "axios": "^1.13.5"
28
28
  },
29
29
  "devDependencies": {
30
30
  "@swc/core": "^1.15.11",
31
- "@types/node": "^24.10.10",
32
- "@typescript-eslint/eslint-plugin": "^8.54.0",
33
- "@typescript-eslint/parser": "^8.54.0",
31
+ "@types/node": "^24.10.13",
32
+ "@typescript-eslint/eslint-plugin": "^8.55.0",
33
+ "@typescript-eslint/parser": "^8.55.0",
34
34
  "eslint": "^9.39.2",
35
35
  "eslint-config-prettier": "^10.1.8",
36
36
  "eslint-import-resolver-typescript": "^4.4.4",