@nomalism-com/api 0.51.14 → 0.51.16

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.cjs CHANGED
@@ -1475,6 +1475,10 @@ var Repository36 = class {
1475
1475
  );
1476
1476
  return response.data;
1477
1477
  }
1478
+ async findToday() {
1479
+ const response = await this.api.get(`${this.route}today`);
1480
+ return response.data;
1481
+ }
1478
1482
  async findByOwner(params) {
1479
1483
  const response = await this.api.get(
1480
1484
  `${this.route}by_owner`,
@@ -1872,9 +1876,10 @@ var Repository47 = class {
1872
1876
  const response = await this.api.get(`${this.route}auth`);
1873
1877
  return response.data;
1874
1878
  }
1875
- async emails() {
1879
+ async emails(params) {
1876
1880
  const response = await this.api.get(
1877
- `${this.route}emails`
1881
+ `${this.route}emails`,
1882
+ { params }
1878
1883
  );
1879
1884
  return response.data;
1880
1885
  }
@@ -2360,7 +2365,9 @@ var Repository58 = class {
2360
2365
  return response.data;
2361
2366
  }
2362
2367
  async from_master_checked() {
2363
- const response = await this.api.post(`${this.route}from_master`);
2368
+ const response = await this.api.post(
2369
+ `${this.route}from_master_checked`
2370
+ );
2364
2371
  return response.data;
2365
2372
  }
2366
2373
  };
@@ -3595,7 +3602,7 @@ var Repository92 = class {
3595
3602
  return response.data;
3596
3603
  }
3597
3604
  async update({ id }, body) {
3598
- await this.api.post(`${this.route}${id}`, body);
3605
+ await this.api.put(`${this.route}${id}`, body);
3599
3606
  }
3600
3607
  async deleteOne({
3601
3608
  id
@@ -3616,13 +3623,6 @@ var Repository93 = class {
3616
3623
  this.api = api;
3617
3624
  this.route = route;
3618
3625
  }
3619
- async create(body) {
3620
- const response = await this.api.post(
3621
- `${this.route}`,
3622
- body
3623
- );
3624
- return response.data;
3625
- }
3626
3626
  async find() {
3627
3627
  const response = await this.api.get(`${this.route}`);
3628
3628
  return response.data;
@@ -3645,12 +3645,7 @@ var Repository93 = class {
3645
3645
  return response.data;
3646
3646
  }
3647
3647
  async update({ id }, body) {
3648
- await this.api.post(`${this.route}${id}`, body);
3649
- }
3650
- async deleteOne({
3651
- id
3652
- }) {
3653
- await this.api.delete(`${this.route}${id}`);
3648
+ await this.api.put(`${this.route}${id}`, body);
3654
3649
  }
3655
3650
  };
3656
3651
 
@@ -3697,7 +3692,7 @@ var Repository94 = class {
3697
3692
  return response.data;
3698
3693
  }
3699
3694
  async update({ id }, body) {
3700
- await this.api.post(`${this.route}${id}`, body);
3695
+ await this.api.put(`${this.route}${id}`, body);
3701
3696
  }
3702
3697
  async deleteOne({
3703
3698
  id
package/dist/index.js CHANGED
@@ -1442,6 +1442,10 @@ var Repository36 = class {
1442
1442
  );
1443
1443
  return response.data;
1444
1444
  }
1445
+ async findToday() {
1446
+ const response = await this.api.get(`${this.route}today`);
1447
+ return response.data;
1448
+ }
1445
1449
  async findByOwner(params) {
1446
1450
  const response = await this.api.get(
1447
1451
  `${this.route}by_owner`,
@@ -1839,9 +1843,10 @@ var Repository47 = class {
1839
1843
  const response = await this.api.get(`${this.route}auth`);
1840
1844
  return response.data;
1841
1845
  }
1842
- async emails() {
1846
+ async emails(params) {
1843
1847
  const response = await this.api.get(
1844
- `${this.route}emails`
1848
+ `${this.route}emails`,
1849
+ { params }
1845
1850
  );
1846
1851
  return response.data;
1847
1852
  }
@@ -2327,7 +2332,9 @@ var Repository58 = class {
2327
2332
  return response.data;
2328
2333
  }
2329
2334
  async from_master_checked() {
2330
- const response = await this.api.post(`${this.route}from_master`);
2335
+ const response = await this.api.post(
2336
+ `${this.route}from_master_checked`
2337
+ );
2331
2338
  return response.data;
2332
2339
  }
2333
2340
  };
@@ -3562,7 +3569,7 @@ var Repository92 = class {
3562
3569
  return response.data;
3563
3570
  }
3564
3571
  async update({ id }, body) {
3565
- await this.api.post(`${this.route}${id}`, body);
3572
+ await this.api.put(`${this.route}${id}`, body);
3566
3573
  }
3567
3574
  async deleteOne({
3568
3575
  id
@@ -3583,13 +3590,6 @@ var Repository93 = class {
3583
3590
  this.api = api;
3584
3591
  this.route = route;
3585
3592
  }
3586
- async create(body) {
3587
- const response = await this.api.post(
3588
- `${this.route}`,
3589
- body
3590
- );
3591
- return response.data;
3592
- }
3593
3593
  async find() {
3594
3594
  const response = await this.api.get(`${this.route}`);
3595
3595
  return response.data;
@@ -3612,12 +3612,7 @@ var Repository93 = class {
3612
3612
  return response.data;
3613
3613
  }
3614
3614
  async update({ id }, body) {
3615
- await this.api.post(`${this.route}${id}`, body);
3616
- }
3617
- async deleteOne({
3618
- id
3619
- }) {
3620
- await this.api.delete(`${this.route}${id}`);
3615
+ await this.api.put(`${this.route}${id}`, body);
3621
3616
  }
3622
3617
  };
3623
3618
 
@@ -3664,7 +3659,7 @@ var Repository94 = class {
3664
3659
  return response.data;
3665
3660
  }
3666
3661
  async update({ id }, body) {
3667
- await this.api.post(`${this.route}${id}`, body);
3662
+ await this.api.put(`${this.route}${id}`, body);
3668
3663
  }
3669
3664
  async deleteOne({
3670
3665
  id
@@ -4,7 +4,7 @@ export default class Repository implements Nomalism.Settings.IRepository {
4
4
  route: string;
5
5
  private api;
6
6
  constructor({ api, route }: IModuleConstructor);
7
- findByKey(params: Nomalism.Settings.IFindByKeyRequest): Promise<Nomalism.Settings.Entity | null>;
8
- update(body: Nomalism.Settings.IUpdateRequest): Promise<Nomalism.Settings.Entity | null>;
9
- find(): Promise<Nomalism.Settings.Entity[]>;
7
+ findByKey(params: Nomalism.Settings.IFindByKeyRequest): Promise<Nomalism.Settings.IFindResponse | null>;
8
+ update(body: Nomalism.Settings.IUpdateRequest): Promise<Nomalism.Settings.IFindResponse | null>;
9
+ find(): Promise<Nomalism.Settings.IFindResponse[]>;
10
10
  }
@@ -8,5 +8,6 @@ export default class Repository implements Nomalism.SchedulePrintJob.IRepository
8
8
  createMany(body: Nomalism.SchedulePrintJob.ICreateManySchedulePrintJobRequest): Promise<void>;
9
9
  deleteOne(selector: Nomalism.shared.IFindByIdRequest): Promise<void>;
10
10
  dispatchSchedulePrintJob(body: Nomalism.SchedulePrintJob.IDispatchSchedulePrintJobRequest): Promise<Nomalism.SchedulePrintJob.IDispatchSchedulePrintJobResponse>;
11
+ findToday(): Promise<Nomalism.SchedulePrintJob.IFindTodayItem[]>;
11
12
  findByOwner(params: Nomalism.shared.IFindByOwnerIdRequest): Promise<Nomalism.SchedulePrintJob.Entity[]>;
12
13
  }
@@ -5,5 +5,5 @@ export default class Repository implements Nomalism.Gmails.IRepository {
5
5
  private api;
6
6
  constructor({ api, route }: IModuleConstructor);
7
7
  auth(): Promise<string>;
8
- emails(): Promise<Nomalism.Gmails.IGmailsResponse[]>;
8
+ emails(params?: Nomalism.Gmails.IFindRequest): Promise<Nomalism.Gmails.IFindResponse>;
9
9
  }
@@ -4,10 +4,8 @@ export default class Repository implements Nomalism.CLT.IRepository {
4
4
  route: string;
5
5
  private api;
6
6
  constructor({ api, route }: IModuleConstructor);
7
- create(body: Nomalism.CLT.ICreateRequest): Promise<Nomalism.CLT.Entity>;
8
7
  find(): Promise<Nomalism.CLT.Entity[]>;
9
8
  findMinified(params?: Nomalism.CLT.IFindMinifiedRequest): Promise<Nomalism.CLT.Entity[]>;
10
9
  findById({ id, }: Nomalism.shared.IFindByIdNumberRequest): Promise<Nomalism.CLT.Entity | null>;
11
10
  update({ id }: Nomalism.shared.IFindByIdNumberRequest, body: Nomalism.CLT.IUpdateRequest): Promise<void>;
12
- deleteOne({ id, }: Nomalism.shared.IFindByIdNumberRequest): Promise<void>;
13
11
  }
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": "0.51.14",
4
+ "version": "0.51.16",
5
5
  "author": "Nomalism <it.nomalism@gmail.com> (https://https://nomalism.com/)",
6
6
  "license": "UNLICENSED",
7
7
  "type": "module",
@@ -30,19 +30,19 @@
30
30
  "prepare": "husky"
31
31
  },
32
32
  "dependencies": {
33
- "@nomalism-com/types": "^0.51.14",
33
+ "@nomalism-com/types": "^0.51.16",
34
34
  "axios": "^1.21.0"
35
35
  },
36
36
  "devDependencies": {
37
37
  "@eslint/js": "^10.0.1",
38
- "@swc/core": "^1.16.20",
38
+ "@swc/core": "^1.16.21",
39
39
  "@types/node": "^26.6.6",
40
40
  "@typescript-eslint/eslint-plugin": "^8.62.0",
41
41
  "@typescript-eslint/parser": "^8.62.0",
42
- "eslint": "^10.13.0",
42
+ "eslint": "^10.14.0",
43
43
  "eslint-config-prettier": "^10.1.8",
44
44
  "eslint-plugin-simple-import-sort": "^14.0.0",
45
- "globals": "^17.13.0",
45
+ "globals": "^17.14.0",
46
46
  "husky": "^9.1.7",
47
47
  "lint-staged": "^17.6.0",
48
48
  "prettier": "^3.9.10",