@vitalfit/sdk 0.2.2 → 0.2.4

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
@@ -1360,6 +1360,11 @@ var BillingService = class {
1360
1360
  this.getInvoices = this.getInvoices.bind(this);
1361
1361
  this.getTaxRateByBranch = this.getTaxRateByBranch.bind(this);
1362
1362
  this.getExchangeRate = this.getExchangeRate.bind(this);
1363
+ this.getFiscalDocuments = this.getFiscalDocuments.bind(this);
1364
+ this.createFiscalDocument = this.createFiscalDocument.bind(this);
1365
+ this.getFiscalDocumentById = this.getFiscalDocumentById.bind(this);
1366
+ this.updateFiscalDocument = this.updateFiscalDocument.bind(this);
1367
+ this.deleteFiscalDocument = this.deleteFiscalDocument.bind(this);
1363
1368
  }
1364
1369
  async getTaxRateByBranch(jwt, branchId) {
1365
1370
  const response = await this.client.get({
@@ -1448,6 +1453,46 @@ var BillingService = class {
1448
1453
  });
1449
1454
  return response;
1450
1455
  }
1456
+ async getFiscalDocuments(jwt, { page = 1, limit = 10, sort = "desc", search }) {
1457
+ const response = await this.client.get({
1458
+ url: "/billing/fiscal-document-types",
1459
+ jwt,
1460
+ params: {
1461
+ page,
1462
+ limit,
1463
+ sort,
1464
+ search
1465
+ }
1466
+ });
1467
+ return response;
1468
+ }
1469
+ async createFiscalDocument(jwt, data) {
1470
+ await this.client.post({
1471
+ url: "/billing/fiscal-document-types",
1472
+ jwt,
1473
+ data
1474
+ });
1475
+ }
1476
+ async getFiscalDocumentById(jwt, id) {
1477
+ const response = await this.client.get({
1478
+ url: `/billing/fiscal-document-types/${id}`,
1479
+ jwt
1480
+ });
1481
+ return response;
1482
+ }
1483
+ async updateFiscalDocument(jwt, id, data) {
1484
+ await this.client.patch({
1485
+ url: `/billing/fiscal-document-types/${id}`,
1486
+ jwt,
1487
+ data
1488
+ });
1489
+ }
1490
+ async deleteFiscalDocument(jwt, id) {
1491
+ await this.client.delete({
1492
+ url: `/billing/fiscal-document-types/${id}`,
1493
+ jwt
1494
+ });
1495
+ }
1451
1496
  };
1452
1497
 
1453
1498
  // src/services/booking.ts
@@ -1571,6 +1616,7 @@ var ReportService = class {
1571
1616
  this.activityHeatmap = this.activityHeatmap.bind(this);
1572
1617
  this.classOccupancyChart = this.classOccupancyChart.bind(this);
1573
1618
  this.financialSummary = this.financialSummary.bind(this);
1619
+ this.salesByDemography = this.salesByDemography.bind(this);
1574
1620
  }
1575
1621
  async mostUsedServices(jwt, start, end) {
1576
1622
  const response = await this.client.get({
@@ -1894,6 +1940,19 @@ var ReportService = class {
1894
1940
  });
1895
1941
  return response;
1896
1942
  }
1943
+ async salesByDemography(jwt, branchId, dimension, start, end) {
1944
+ const response = await this.client.get({
1945
+ url: "/reports/charts/sales-by-demographics",
1946
+ jwt,
1947
+ params: {
1948
+ dimension,
1949
+ ...start ? { start } : {},
1950
+ ...end ? { end } : {},
1951
+ ...branchId ? { branch_id: branchId } : {}
1952
+ }
1953
+ });
1954
+ return response;
1955
+ }
1897
1956
  };
1898
1957
 
1899
1958
  // src/services/staff.ts
@@ -2189,7 +2248,7 @@ var VitalFit = class _VitalFit {
2189
2248
  return _VitalFit.instance;
2190
2249
  }
2191
2250
  version() {
2192
- return "0.2.2";
2251
+ return "0.2.4";
2193
2252
  }
2194
2253
  };
2195
2254
  // Annotate the CommonJS export names for ESM import in node: