@adobe/spacecat-shared-data-access 2.49.0 → 2.51.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.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,17 @@
1
+ # [@adobe/spacecat-shared-data-access-v2.51.0](https://github.com/adobe/spacecat-shared/compare/@adobe/spacecat-shared-data-access-v2.50.0...@adobe/spacecat-shared-data-access-v2.51.0) (2025-08-12)
2
+
3
+
4
+ ### Features
5
+
6
+ * removed slash from reports path ([#906](https://github.com/adobe/spacecat-shared/issues/906)) ([44ace99](https://github.com/adobe/spacecat-shared/commit/44ace9999fc2d5d2fc332b03cae7ceafbd9a939a))
7
+
8
+ # [@adobe/spacecat-shared-data-access-v2.50.0](https://github.com/adobe/spacecat-shared/compare/@adobe/spacecat-shared-data-access-v2.49.0...@adobe/spacecat-shared-data-access-v2.50.0) (2025-08-12)
9
+
10
+
11
+ ### Features
12
+
13
+ * SITES-34221 implemented getters for raw and ai reports ([#905](https://github.com/adobe/spacecat-shared/issues/905)) ([e2916f5](https://github.com/adobe/spacecat-shared/commit/e2916f52e5b13350a37d34502f65b7454f65cd0b))
14
+
1
15
  # [@adobe/spacecat-shared-data-access-v2.49.0](https://github.com/adobe/spacecat-shared/compare/@adobe/spacecat-shared-data-access-v2.48.0...@adobe/spacecat-shared-data-access-v2.49.0) (2025-08-11)
2
16
 
3
17
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adobe/spacecat-shared-data-access",
3
- "version": "2.49.0",
3
+ "version": "2.51.0",
4
4
  "description": "Shared modules of the Spacecat Services - Data Access",
5
5
  "type": "module",
6
6
  "engines": {
@@ -17,6 +17,8 @@ export interface Report extends BaseModel {
17
17
  getReportPeriod(): { startDate: string; endDate: string };
18
18
  getComparisonPeriod(): { startDate: string; endDate: string };
19
19
  getStoragePath(): string;
20
+ getRawStoragePath(): string;
21
+ getEnhancedStoragePath(): string;
20
22
  getSite(): Promise<Site>;
21
23
  setReportType(reportType: string): Report;
22
24
  setReportPeriod(period: { startDate: string; endDate: string }): Report;
@@ -25,7 +25,7 @@ class ReportCollection extends BaseCollection {
25
25
 
26
26
  // If storagePath is empty string (default value), compute it automatically
27
27
  if (report.getStoragePath() === '') {
28
- const storagePath = `/reports/${item.siteId}/${item.reportType}/${report.getId()}/`;
28
+ const storagePath = `reports/${item.siteId}/${item.reportType}/${report.getId()}/`;
29
29
  report.setStoragePath(storagePath);
30
30
  await report.save();
31
31
  }
@@ -18,6 +18,14 @@ class Report extends BaseModel {
18
18
  SUCCESS: 'success',
19
19
  FAILED: 'failed',
20
20
  };
21
+
22
+ getRawStoragePath() {
23
+ return `${this.getStoragePath()}raw/`;
24
+ }
25
+
26
+ getEnhancedStoragePath() {
27
+ return `${this.getStoragePath()}enhanced/`;
28
+ }
21
29
  }
22
30
 
23
31
  export default Report;