@mastra/cloudflare-d1 1.1.0-alpha.0 → 1.1.1-alpha.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.
@@ -1,6 +1,6 @@
1
1
  import type { ListScoresResponse, SaveScorePayload, ScoreRowData, ScoringSource } from '@mastra/core/evals';
2
2
  import { ScoresStorage } from '@mastra/core/storage';
3
- import type { StoragePagination } from '@mastra/core/storage';
3
+ import type { ScoreTenancyFilters, StoragePagination } from '@mastra/core/storage';
4
4
  import type { D1DomainConfig } from '../../db/index.js';
5
5
  export declare class ScoresStorageD1 extends ScoresStorage {
6
6
  #private;
@@ -13,26 +13,30 @@ export declare class ScoresStorageD1 extends ScoresStorage {
13
13
  saveScore(score: SaveScorePayload): Promise<{
14
14
  score: ScoreRowData;
15
15
  }>;
16
- listScoresByScorerId({ scorerId, entityId, entityType, source, pagination, }: {
16
+ listScoresByScorerId({ scorerId, entityId, entityType, source, pagination, filters, }: {
17
17
  scorerId: string;
18
18
  entityId?: string;
19
19
  entityType?: string;
20
20
  source?: ScoringSource;
21
21
  pagination: StoragePagination;
22
+ filters?: ScoreTenancyFilters;
22
23
  }): Promise<ListScoresResponse>;
23
- listScoresByRunId({ runId, pagination, }: {
24
+ listScoresByRunId({ runId, pagination, filters, }: {
24
25
  runId: string;
25
26
  pagination: StoragePagination;
27
+ filters?: ScoreTenancyFilters;
26
28
  }): Promise<ListScoresResponse>;
27
- listScoresByEntityId({ entityId, entityType, pagination, }: {
29
+ listScoresByEntityId({ entityId, entityType, pagination, filters, }: {
28
30
  pagination: StoragePagination;
29
31
  entityId: string;
30
32
  entityType: string;
33
+ filters?: ScoreTenancyFilters;
31
34
  }): Promise<ListScoresResponse>;
32
- listScoresBySpan({ traceId, spanId, pagination, }: {
35
+ listScoresBySpan({ traceId, spanId, pagination, filters, }: {
33
36
  traceId: string;
34
37
  spanId: string;
35
38
  pagination: StoragePagination;
39
+ filters?: ScoreTenancyFilters;
36
40
  }): Promise<ListScoresResponse>;
37
41
  }
38
42
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/storage/domains/scores/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAE5G,OAAO,EAEL,aAAa,EAMd,MAAM,sBAAsB,CAAC;AAC9B,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAE9D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAgB/C,qBAAa,eAAgB,SAAQ,aAAa;;gBAGpC,MAAM,EAAE,cAAc;IAK5B,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAIrB,mBAAmB,IAAI,OAAO,CAAC,IAAI,CAAC;IAIpC,YAAY,CAAC,EAAE,EAAE,EAAE,EAAE;QAAE,EAAE,EAAE,MAAM,CAAA;KAAE,GAAG,OAAO,CAAC,YAAY,GAAG,IAAI,CAAC;IAyBlE,SAAS,CAAC,KAAK,EAAE,gBAAgB,GAAG,OAAO,CAAC;QAAE,KAAK,EAAE,YAAY,CAAA;KAAE,CAAC;IAoEpE,oBAAoB,CAAC,EACzB,QAAQ,EACR,QAAQ,EACR,UAAU,EACV,MAAM,EACN,UAAU,GACX,EAAE;QACD,QAAQ,EAAE,MAAM,CAAC;QACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,MAAM,CAAC,EAAE,aAAa,CAAC;QACvB,UAAU,EAAE,iBAAiB,CAAC;KAC/B,GAAG,OAAO,CAAC,kBAAkB,CAAC;IA6EzB,iBAAiB,CAAC,EACtB,KAAK,EACL,UAAU,GACX,EAAE;QACD,KAAK,EAAE,MAAM,CAAC;QACd,UAAU,EAAE,iBAAiB,CAAC;KAC/B,GAAG,OAAO,C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N,UAAU,EACV,OAAO,GACR,EAAE;QACD,QAAQ,EAAE,MAAM,CAAC;QACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,MAAM,CAAC,EAAE,aAAa,CAAC;QACvB,UAAU,EAAE,iBAAiB,CAAC;QAC9B,OAAO,CAAC,EAAE,mBAAmB,CAAC;KAC/B,GAAG,OAAO,CAAC,kBAAkB,CAAC;IA+EzB,iBAAiB,CAAC,EACtB,KAAK,EACL,UAAU,EACV,OAAO,GACR,EAAE;QACD,KAAK,EAAE,MAAM,CAAC;QACd,UAAU,EAAE,iBAAiB,CAAC;QAC9B,OAAO,CAAC,EAAE,mBAAmB,CAAC;KAC/B,GAAG,OAAO,CAAC,kBAAkB,CAAC;IA2DzB,oBAAoB,CAAC,EACzB,QAAQ,EACR,UAAU,EACV,UAAU,EACV,OAAO,GACR,EAAE;QACD,UAAU,EAAE,iBAAiB,CAAC;QAC9B,QAAQ,EAAE,MAAM,CAAC;QACjB,UAAU,EAAE,MAAM,CAAC;QACnB,OAAO,CAAC,EAAE,mBAAmB,CAAC;KAC/B,GAAG,OAAO,CAAC,kBAAkB,CAAC;IAoEzB,gBAAgB,CAAC,EACrB,OAAO,EACP,MAAM,EACN,UAAU,EACV,OAAO,GACR,EAAE;QACD,OAAO,EAAE,MAAM,CAAC;QAChB,MAAM,EAAE,MAAM,CAAC;QACf,UAAU,EAAE,iBAAiB,CAAC;QAC9B,OAAO,CAAC,EAAE,mBAAmB,CAAC;KAC/B,GAAG,OAAO,CAAC,kBAAkB,CAAC;CAkEhC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mastra/cloudflare-d1",
3
- "version": "1.1.0-alpha.0",
3
+ "version": "1.1.1-alpha.0",
4
4
  "description": "D1 provider for Mastra - includes db storage capabilities",
5
5
  "type": "module",
6
6
  "files": [
@@ -37,10 +37,10 @@
37
37
  "tsx": "^4.22.4",
38
38
  "typescript": "^6.0.3",
39
39
  "vitest": "4.1.8",
40
- "@internal/storage-test-utils": "0.0.102",
41
- "@internal/lint": "0.0.106",
42
- "@internal/types-builder": "0.0.81",
43
- "@mastra/core": "1.45.0-alpha.0"
40
+ "@internal/lint": "0.0.110",
41
+ "@internal/types-builder": "0.0.85",
42
+ "@internal/storage-test-utils": "0.0.106",
43
+ "@mastra/core": "1.49.0-alpha.5"
44
44
  },
45
45
  "peerDependencies": {
46
46
  "@mastra/core": ">=1.0.0-0 <2.0.0-0",