@xpert-ai/contracts 3.26.0 → 3.26.2

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.
@@ -26,6 +26,22 @@ export declare const projectPipelineDefinitionShapeSchema: z.ZodDiscriminatedUni
26
26
  key: z.ZodEffects<z.ZodString, string, string>;
27
27
  version: z.ZodString;
28
28
  title: z.ZodString;
29
+ projectTypes: z.ZodEffects<z.ZodArray<z.ZodObject<{
30
+ applicationKey: z.ZodString;
31
+ projectTypeKey: z.ZodString;
32
+ }, "strict", z.ZodTypeAny, {
33
+ applicationKey: string;
34
+ projectTypeKey: string;
35
+ }, {
36
+ applicationKey: string;
37
+ projectTypeKey: string;
38
+ }>, "many">, {
39
+ applicationKey: string;
40
+ projectTypeKey: string;
41
+ }[], {
42
+ applicationKey: string;
43
+ projectTypeKey: string;
44
+ }[]>;
29
45
  subjectResolverRef: z.ZodString;
30
46
  roles: z.ZodArray<z.ZodObject<{
31
47
  key: z.ZodEffects<z.ZodString, string, string>;
@@ -102,6 +118,10 @@ export declare const projectPipelineDefinitionShapeSchema: z.ZodDiscriminatedUni
102
118
  };
103
119
  version: string;
104
120
  title: string;
121
+ projectTypes: {
122
+ applicationKey: string;
123
+ projectTypeKey: string;
124
+ }[];
105
125
  subjectResolverRef: string;
106
126
  roles: {
107
127
  key: string;
@@ -143,6 +163,10 @@ export declare const projectPipelineDefinitionShapeSchema: z.ZodDiscriminatedUni
143
163
  };
144
164
  version: string;
145
165
  title: string;
166
+ projectTypes: {
167
+ applicationKey: string;
168
+ projectTypeKey: string;
169
+ }[];
146
170
  subjectResolverRef: string;
147
171
  roles: {
148
172
  key: string;
@@ -1077,6 +1101,22 @@ export declare const projectPipelineDefinitionShapeSchema: z.ZodDiscriminatedUni
1077
1101
  key: z.ZodEffects<z.ZodString, string, string>;
1078
1102
  version: z.ZodString;
1079
1103
  title: z.ZodString;
1104
+ projectTypes: z.ZodEffects<z.ZodArray<z.ZodObject<{
1105
+ applicationKey: z.ZodString;
1106
+ projectTypeKey: z.ZodString;
1107
+ }, "strict", z.ZodTypeAny, {
1108
+ applicationKey: string;
1109
+ projectTypeKey: string;
1110
+ }, {
1111
+ applicationKey: string;
1112
+ projectTypeKey: string;
1113
+ }>, "many">, {
1114
+ applicationKey: string;
1115
+ projectTypeKey: string;
1116
+ }[], {
1117
+ applicationKey: string;
1118
+ projectTypeKey: string;
1119
+ }[]>;
1080
1120
  subjectResolverRef: z.ZodString;
1081
1121
  roles: z.ZodArray<z.ZodObject<{
1082
1122
  key: z.ZodEffects<z.ZodString, string, string>;
@@ -1151,6 +1191,10 @@ export declare const projectPipelineDefinitionShapeSchema: z.ZodDiscriminatedUni
1151
1191
  };
1152
1192
  version: string;
1153
1193
  title: string;
1194
+ projectTypes: {
1195
+ applicationKey: string;
1196
+ projectTypeKey: string;
1197
+ }[];
1154
1198
  subjectResolverRef: string;
1155
1199
  roles: {
1156
1200
  key: string;
@@ -1390,6 +1434,10 @@ export declare const projectPipelineDefinitionShapeSchema: z.ZodDiscriminatedUni
1390
1434
  };
1391
1435
  version: string;
1392
1436
  title: string;
1437
+ projectTypes: {
1438
+ applicationKey: string;
1439
+ projectTypeKey: string;
1440
+ }[];
1393
1441
  subjectResolverRef: string;
1394
1442
  roles: {
1395
1443
  key: string;
@@ -1650,6 +1698,22 @@ export declare const projectPipelineDefinitionSchema: z.ZodEffects<z.ZodDiscrimi
1650
1698
  key: z.ZodEffects<z.ZodString, string, string>;
1651
1699
  version: z.ZodString;
1652
1700
  title: z.ZodString;
1701
+ projectTypes: z.ZodEffects<z.ZodArray<z.ZodObject<{
1702
+ applicationKey: z.ZodString;
1703
+ projectTypeKey: z.ZodString;
1704
+ }, "strict", z.ZodTypeAny, {
1705
+ applicationKey: string;
1706
+ projectTypeKey: string;
1707
+ }, {
1708
+ applicationKey: string;
1709
+ projectTypeKey: string;
1710
+ }>, "many">, {
1711
+ applicationKey: string;
1712
+ projectTypeKey: string;
1713
+ }[], {
1714
+ applicationKey: string;
1715
+ projectTypeKey: string;
1716
+ }[]>;
1653
1717
  subjectResolverRef: z.ZodString;
1654
1718
  roles: z.ZodArray<z.ZodObject<{
1655
1719
  key: z.ZodEffects<z.ZodString, string, string>;
@@ -1726,6 +1790,10 @@ export declare const projectPipelineDefinitionSchema: z.ZodEffects<z.ZodDiscrimi
1726
1790
  };
1727
1791
  version: string;
1728
1792
  title: string;
1793
+ projectTypes: {
1794
+ applicationKey: string;
1795
+ projectTypeKey: string;
1796
+ }[];
1729
1797
  subjectResolverRef: string;
1730
1798
  roles: {
1731
1799
  key: string;
@@ -1767,6 +1835,10 @@ export declare const projectPipelineDefinitionSchema: z.ZodEffects<z.ZodDiscrimi
1767
1835
  };
1768
1836
  version: string;
1769
1837
  title: string;
1838
+ projectTypes: {
1839
+ applicationKey: string;
1840
+ projectTypeKey: string;
1841
+ }[];
1770
1842
  subjectResolverRef: string;
1771
1843
  roles: {
1772
1844
  key: string;
@@ -2701,6 +2773,22 @@ export declare const projectPipelineDefinitionSchema: z.ZodEffects<z.ZodDiscrimi
2701
2773
  key: z.ZodEffects<z.ZodString, string, string>;
2702
2774
  version: z.ZodString;
2703
2775
  title: z.ZodString;
2776
+ projectTypes: z.ZodEffects<z.ZodArray<z.ZodObject<{
2777
+ applicationKey: z.ZodString;
2778
+ projectTypeKey: z.ZodString;
2779
+ }, "strict", z.ZodTypeAny, {
2780
+ applicationKey: string;
2781
+ projectTypeKey: string;
2782
+ }, {
2783
+ applicationKey: string;
2784
+ projectTypeKey: string;
2785
+ }>, "many">, {
2786
+ applicationKey: string;
2787
+ projectTypeKey: string;
2788
+ }[], {
2789
+ applicationKey: string;
2790
+ projectTypeKey: string;
2791
+ }[]>;
2704
2792
  subjectResolverRef: z.ZodString;
2705
2793
  roles: z.ZodArray<z.ZodObject<{
2706
2794
  key: z.ZodEffects<z.ZodString, string, string>;
@@ -2775,6 +2863,10 @@ export declare const projectPipelineDefinitionSchema: z.ZodEffects<z.ZodDiscrimi
2775
2863
  };
2776
2864
  version: string;
2777
2865
  title: string;
2866
+ projectTypes: {
2867
+ applicationKey: string;
2868
+ projectTypeKey: string;
2869
+ }[];
2778
2870
  subjectResolverRef: string;
2779
2871
  roles: {
2780
2872
  key: string;
@@ -3014,6 +3106,10 @@ export declare const projectPipelineDefinitionSchema: z.ZodEffects<z.ZodDiscrimi
3014
3106
  };
3015
3107
  version: string;
3016
3108
  title: string;
3109
+ projectTypes: {
3110
+ applicationKey: string;
3111
+ projectTypeKey: string;
3112
+ }[];
3017
3113
  subjectResolverRef: string;
3018
3114
  roles: {
3019
3115
  key: string;
@@ -3255,6 +3351,10 @@ export declare const projectPipelineDefinitionSchema: z.ZodEffects<z.ZodDiscrimi
3255
3351
  };
3256
3352
  version: string;
3257
3353
  title: string;
3354
+ projectTypes: {
3355
+ applicationKey: string;
3356
+ projectTypeKey: string;
3357
+ }[];
3258
3358
  subjectResolverRef: string;
3259
3359
  roles: {
3260
3360
  key: string;
@@ -3294,6 +3394,10 @@ export declare const projectPipelineDefinitionSchema: z.ZodEffects<z.ZodDiscrimi
3294
3394
  };
3295
3395
  version: string;
3296
3396
  title: string;
3397
+ projectTypes: {
3398
+ applicationKey: string;
3399
+ projectTypeKey: string;
3400
+ }[];
3297
3401
  subjectResolverRef: string;
3298
3402
  roles: {
3299
3403
  key: string;
@@ -3535,6 +3639,10 @@ export declare const projectPipelineDefinitionSchema: z.ZodEffects<z.ZodDiscrimi
3535
3639
  };
3536
3640
  version: string;
3537
3641
  title: string;
3642
+ projectTypes: {
3643
+ applicationKey: string;
3644
+ projectTypeKey: string;
3645
+ }[];
3538
3646
  subjectResolverRef: string;
3539
3647
  roles: {
3540
3648
  key: string;
@@ -3574,6 +3682,10 @@ export declare const projectPipelineDefinitionSchema: z.ZodEffects<z.ZodDiscrimi
3574
3682
  };
3575
3683
  version: string;
3576
3684
  title: string;
3685
+ projectTypes: {
3686
+ applicationKey: string;
3687
+ projectTypeKey: string;
3688
+ }[];
3577
3689
  subjectResolverRef: string;
3578
3690
  roles: {
3579
3691
  key: string;
@@ -1,6 +1,7 @@
1
1
  export * from './primitives.schema';
2
2
  export * from './node.schema';
3
3
  export * from './definition.schema';
4
+ export * from './project-types';
4
5
  export * from './definition.validation';
5
6
  export * from './configuration.schema';
6
7
  export * from './runtime.schema';
@@ -12,6 +13,7 @@ export * from './operation.schema';
12
13
  export * from './commands.schema';
13
14
  export * from './statistics';
14
15
  export * from './configuration-form';
16
+ export * from './command-capability.schema';
15
17
  export * from './provider-actions.schema';
16
18
  export * from './execution-statistics';
17
19
  export * from './model-usage-statistics';
@@ -0,0 +1,23 @@
1
+ import { z } from 'zod/v3';
2
+ import type { ProjectPipelineDefinition } from './definition.schema';
3
+ /** Explicit application/type identities; plugin availability alone never implies applicability. */
4
+ export declare const projectPipelineProjectTypesSchema: z.ZodEffects<z.ZodArray<z.ZodObject<{
5
+ applicationKey: z.ZodString;
6
+ projectTypeKey: z.ZodString;
7
+ }, "strict", z.ZodTypeAny, {
8
+ applicationKey: string;
9
+ projectTypeKey: string;
10
+ }, {
11
+ applicationKey: string;
12
+ projectTypeKey: string;
13
+ }>, "many">, {
14
+ applicationKey: string;
15
+ projectTypeKey: string;
16
+ }[], {
17
+ applicationKey: string;
18
+ projectTypeKey: string;
19
+ }[]>;
20
+ export declare function isProjectPipelineApplicable(definition: Pick<ProjectPipelineDefinition, 'projectTypes'>, project: {
21
+ applicationKey?: string | null;
22
+ projectTypeKey?: string | null;
23
+ }): boolean;
@@ -488,6 +488,22 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
488
488
  key: z.ZodEffects<z.ZodString, string, string>;
489
489
  version: z.ZodString;
490
490
  title: z.ZodString;
491
+ projectTypes: z.ZodEffects<z.ZodArray<z.ZodObject<{
492
+ applicationKey: z.ZodString;
493
+ projectTypeKey: z.ZodString;
494
+ }, "strict", z.ZodTypeAny, {
495
+ applicationKey: string;
496
+ projectTypeKey: string;
497
+ }, {
498
+ applicationKey: string;
499
+ projectTypeKey: string;
500
+ }>, "many">, {
501
+ applicationKey: string;
502
+ projectTypeKey: string;
503
+ }[], {
504
+ applicationKey: string;
505
+ projectTypeKey: string;
506
+ }[]>;
491
507
  subjectResolverRef: z.ZodString;
492
508
  roles: z.ZodArray<z.ZodObject<{
493
509
  key: z.ZodEffects<z.ZodString, string, string>;
@@ -564,6 +580,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
564
580
  };
565
581
  version: string;
566
582
  title: string;
583
+ projectTypes: {
584
+ applicationKey: string;
585
+ projectTypeKey: string;
586
+ }[];
567
587
  subjectResolverRef: string;
568
588
  roles: {
569
589
  key: string;
@@ -605,6 +625,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
605
625
  };
606
626
  version: string;
607
627
  title: string;
628
+ projectTypes: {
629
+ applicationKey: string;
630
+ projectTypeKey: string;
631
+ }[];
608
632
  subjectResolverRef: string;
609
633
  roles: {
610
634
  key: string;
@@ -1539,6 +1563,22 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
1539
1563
  key: z.ZodEffects<z.ZodString, string, string>;
1540
1564
  version: z.ZodString;
1541
1565
  title: z.ZodString;
1566
+ projectTypes: z.ZodEffects<z.ZodArray<z.ZodObject<{
1567
+ applicationKey: z.ZodString;
1568
+ projectTypeKey: z.ZodString;
1569
+ }, "strict", z.ZodTypeAny, {
1570
+ applicationKey: string;
1571
+ projectTypeKey: string;
1572
+ }, {
1573
+ applicationKey: string;
1574
+ projectTypeKey: string;
1575
+ }>, "many">, {
1576
+ applicationKey: string;
1577
+ projectTypeKey: string;
1578
+ }[], {
1579
+ applicationKey: string;
1580
+ projectTypeKey: string;
1581
+ }[]>;
1542
1582
  subjectResolverRef: z.ZodString;
1543
1583
  roles: z.ZodArray<z.ZodObject<{
1544
1584
  key: z.ZodEffects<z.ZodString, string, string>;
@@ -1613,6 +1653,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
1613
1653
  };
1614
1654
  version: string;
1615
1655
  title: string;
1656
+ projectTypes: {
1657
+ applicationKey: string;
1658
+ projectTypeKey: string;
1659
+ }[];
1616
1660
  subjectResolverRef: string;
1617
1661
  roles: {
1618
1662
  key: string;
@@ -1852,6 +1896,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
1852
1896
  };
1853
1897
  version: string;
1854
1898
  title: string;
1899
+ projectTypes: {
1900
+ applicationKey: string;
1901
+ projectTypeKey: string;
1902
+ }[];
1855
1903
  subjectResolverRef: string;
1856
1904
  roles: {
1857
1905
  key: string;
@@ -2093,6 +2141,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
2093
2141
  };
2094
2142
  version: string;
2095
2143
  title: string;
2144
+ projectTypes: {
2145
+ applicationKey: string;
2146
+ projectTypeKey: string;
2147
+ }[];
2096
2148
  subjectResolverRef: string;
2097
2149
  roles: {
2098
2150
  key: string;
@@ -2132,6 +2184,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
2132
2184
  };
2133
2185
  version: string;
2134
2186
  title: string;
2187
+ projectTypes: {
2188
+ applicationKey: string;
2189
+ projectTypeKey: string;
2190
+ }[];
2135
2191
  subjectResolverRef: string;
2136
2192
  roles: {
2137
2193
  key: string;
@@ -2373,6 +2429,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
2373
2429
  };
2374
2430
  version: string;
2375
2431
  title: string;
2432
+ projectTypes: {
2433
+ applicationKey: string;
2434
+ projectTypeKey: string;
2435
+ }[];
2376
2436
  subjectResolverRef: string;
2377
2437
  roles: {
2378
2438
  key: string;
@@ -2412,6 +2472,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
2412
2472
  };
2413
2473
  version: string;
2414
2474
  title: string;
2475
+ projectTypes: {
2476
+ applicationKey: string;
2477
+ projectTypeKey: string;
2478
+ }[];
2415
2479
  subjectResolverRef: string;
2416
2480
  roles: {
2417
2481
  key: string;
@@ -3147,6 +3211,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
3147
3211
  };
3148
3212
  version: string;
3149
3213
  title: string;
3214
+ projectTypes: {
3215
+ applicationKey: string;
3216
+ projectTypeKey: string;
3217
+ }[];
3150
3218
  subjectResolverRef: string;
3151
3219
  roles: {
3152
3220
  key: string;
@@ -3186,6 +3254,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
3186
3254
  };
3187
3255
  version: string;
3188
3256
  title: string;
3257
+ projectTypes: {
3258
+ applicationKey: string;
3259
+ projectTypeKey: string;
3260
+ }[];
3189
3261
  subjectResolverRef: string;
3190
3262
  roles: {
3191
3263
  key: string;
@@ -3548,6 +3620,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
3548
3620
  };
3549
3621
  version: string;
3550
3622
  title: string;
3623
+ projectTypes: {
3624
+ applicationKey: string;
3625
+ projectTypeKey: string;
3626
+ }[];
3551
3627
  subjectResolverRef: string;
3552
3628
  roles: {
3553
3629
  key: string;
@@ -3587,6 +3663,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
3587
3663
  };
3588
3664
  version: string;
3589
3665
  title: string;
3666
+ projectTypes: {
3667
+ applicationKey: string;
3668
+ projectTypeKey: string;
3669
+ }[];
3590
3670
  subjectResolverRef: string;
3591
3671
  roles: {
3592
3672
  key: string;
@@ -3949,6 +4029,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
3949
4029
  };
3950
4030
  version: string;
3951
4031
  title: string;
4032
+ projectTypes: {
4033
+ applicationKey: string;
4034
+ projectTypeKey: string;
4035
+ }[];
3952
4036
  subjectResolverRef: string;
3953
4037
  roles: {
3954
4038
  key: string;
@@ -3988,6 +4072,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
3988
4072
  };
3989
4073
  version: string;
3990
4074
  title: string;
4075
+ projectTypes: {
4076
+ applicationKey: string;
4077
+ projectTypeKey: string;
4078
+ }[];
3991
4079
  subjectResolverRef: string;
3992
4080
  roles: {
3993
4081
  key: string;
@@ -4350,6 +4438,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
4350
4438
  };
4351
4439
  version: string;
4352
4440
  title: string;
4441
+ projectTypes: {
4442
+ applicationKey: string;
4443
+ projectTypeKey: string;
4444
+ }[];
4353
4445
  subjectResolverRef: string;
4354
4446
  roles: {
4355
4447
  key: string;
@@ -4389,6 +4481,10 @@ export declare const projectPipelineProjectionSchema: z.ZodEffects<z.ZodObject<{
4389
4481
  };
4390
4482
  version: string;
4391
4483
  title: string;
4484
+ projectTypes: {
4485
+ applicationKey: string;
4486
+ projectTypeKey: string;
4487
+ }[];
4392
4488
  subjectResolverRef: string;
4393
4489
  roles: {
4394
4490
  key: string;
@@ -84,11 +84,11 @@ export declare const templateDependencyLocksSchema: z.ZodArray<z.ZodObject<{
84
84
  kind: z.ZodEnum<["middleware", "sandbox", "toolset"]>;
85
85
  key: z.ZodString;
86
86
  }, "strict", z.ZodTypeAny, {
87
- key?: string;
88
87
  kind?: "middleware" | "toolset" | "sandbox";
89
- }, {
90
88
  key?: string;
89
+ }, {
91
90
  kind?: "middleware" | "toolset" | "sandbox";
91
+ key?: string;
92
92
  }>, "many">>;
93
93
  components: z.ZodArray<z.ZodObject<{
94
94
  type: z.ZodEnum<["skill", "mcp_server", "toolset", "app", "hook", "asset"]>;
@@ -120,8 +120,8 @@ export declare const templateDependencyLocksSchema: z.ZodArray<z.ZodObject<{
120
120
  pluginName?: string;
121
121
  requiredVersion?: string;
122
122
  providers?: {
123
- key?: string;
124
123
  kind?: "middleware" | "toolset" | "sandbox";
124
+ key?: string;
125
125
  }[];
126
126
  }, {
127
127
  version?: string;
@@ -140,8 +140,8 @@ export declare const templateDependencyLocksSchema: z.ZodArray<z.ZodObject<{
140
140
  pluginName?: string;
141
141
  requiredVersion?: string;
142
142
  providers?: {
143
- key?: string;
144
143
  kind?: "middleware" | "toolset" | "sandbox";
144
+ key?: string;
145
145
  }[];
146
146
  }>, "many">;
147
147
  export type TemplateDependencyLock = z.output<typeof templateDependencyLocksSchema>[number];
@@ -7,15 +7,15 @@ export declare const templatePublicationInputSchema: z.ZodObject<{
7
7
  releaseNotes: z.ZodDefault<z.ZodString>;
8
8
  }, "strict", z.ZodTypeAny, {
9
9
  version?: string;
10
+ visibility?: "public" | "team";
10
11
  revision?: string;
11
12
  contentHash?: string;
12
- visibility?: "public" | "team";
13
13
  releaseNotes?: string;
14
14
  }, {
15
15
  version?: string;
16
+ visibility?: "public" | "team";
16
17
  revision?: string;
17
18
  contentHash?: string;
18
- visibility?: "public" | "team";
19
19
  releaseNotes?: string;
20
20
  }>;
21
21
  export type TemplatePublicationInput = z.output<typeof templatePublicationInputSchema>;
@@ -43,12 +43,12 @@ export declare const templateUpgradeInputSchema: z.ZodObject<{
43
43
  revision?: string;
44
44
  sourceHash?: string;
45
45
  targetTemplateId?: string;
46
- choices?: Partial<Record<"runtime" | "instructions" | "presentation" | "definition", "replace" | "keep">>;
46
+ choices?: Partial<Record<"definition" | "runtime" | "instructions" | "presentation", "replace" | "keep">>;
47
47
  }, {
48
48
  revision?: string;
49
49
  sourceHash?: string;
50
50
  targetTemplateId?: string;
51
- choices?: Partial<Record<"runtime" | "instructions" | "presentation" | "definition", "replace" | "keep">>;
51
+ choices?: Partial<Record<"definition" | "runtime" | "instructions" | "presentation", "replace" | "keep">>;
52
52
  }>;
53
53
  export type TemplateUpgradeInput = z.output<typeof templateUpgradeInputSchema>;
54
54
  export interface TemplateUpgradeSource {
@@ -0,0 +1,45 @@
1
+ import type { AnalyticsProviderDescriptor } from './analytics-query.model';
2
+ import type { JSONValue } from './core.model';
3
+ /** Configuration is owned by a provider; bindings contain only immutable source identities. */
4
+ export type AnalyticsConfigurationEntry = {
5
+ kind: 'definition';
6
+ schema: Record<string, JSONValue>;
7
+ connection: 'workspace-files' | 'rest-toolset' | 'mcp-toolset' | 'integration';
8
+ } | {
9
+ kind: 'artifact';
10
+ pluginName: string;
11
+ resourceType: string;
12
+ registrationTool: string;
13
+ };
14
+ export interface AnalyticsConfigurableProvider {
15
+ descriptor: AnalyticsProviderDescriptor;
16
+ configuration: AnalyticsConfigurationEntry;
17
+ }
18
+ export interface IAnalyticsDefinition {
19
+ id: string;
20
+ tenantId: string;
21
+ organizationId: string;
22
+ userId: string;
23
+ name: string;
24
+ providerId: string;
25
+ visibility: 'private' | 'organization';
26
+ status: 'active' | 'archived';
27
+ currentVersionId: string | null;
28
+ }
29
+ export interface IAnalyticsDefinitionVersion {
30
+ id: string;
31
+ definitionId: string;
32
+ versionNumber: number;
33
+ options: Record<string, JSONValue>;
34
+ sha256: string;
35
+ }
36
+ export interface AnalyticsDefinitionCreate {
37
+ name: string;
38
+ providerId: string;
39
+ visibility: IAnalyticsDefinition['visibility'];
40
+ options: Record<string, JSONValue>;
41
+ }
42
+ export interface AnalyticsDefinitionPublish {
43
+ expectedCurrentVersionId: string;
44
+ options: Record<string, JSONValue>;
45
+ }
@@ -1,3 +1,4 @@
1
+ import type { AnalyticsSourceRef } from './analytics-source.model';
1
2
  import type { JSONValue } from './core.model';
2
3
  /** JSON-safe scalar shared by cells and controls; nested objects/arrays are not dataset cells. */
3
4
  export type AnalyticsValue = string | number | boolean | null;
@@ -48,12 +49,10 @@ export interface AnalyticsParameter {
48
49
  * Renderers consume the normalized Dataset, never execute payload or handle source credentials.
49
50
  */
50
51
  export interface AnalyticsBinding {
51
- /** Version of this shared envelope, separate from the provider operation's contractVersion. */
52
- schemaVersion: 1;
53
52
  /** Binding identity used for lookup and result provenance. */
54
53
  id: string;
55
- /** Platform DataSource ID; access is rechecked for the current actor on each execution. */
56
- dataSourceId: string;
54
+ /** Exact governed resource; access is rechecked for the current actor on each execution. */
55
+ source: AnalyticsSourceRef;
57
56
  /** Registered provider descriptor ID, not a display name or database engine switch. */
58
57
  providerId: string;
59
58
  /** Must match a read-only operation advertised by the provider. */
@@ -73,7 +72,7 @@ export interface AnalyticsQueryRequest {
73
72
  }
74
73
  /** Canonical, provider-independent result; consumers must inspect completeness before presenting totals. */
75
74
  export interface AnalyticalDataset {
76
- schema: 'xpert.analytics.dataset/v1';
75
+ schema: 'xpert.analytics.dataset';
77
76
  datasetId: string;
78
77
  /** Preserved even when rows is empty, so renderers can retain bindings and labels. */
79
78
  fields: AnalyticsField[];
@@ -119,7 +118,8 @@ export interface AnalyticsProviderDescriptor {
119
118
  id: string;
120
119
  name: string;
121
120
  /** Exact platform DataSource.type identifiers supported by this provider. */
122
- dataSourceTypes: string[];
121
+ dataSourceTypes?: string[];
122
+ sourceKinds: AnalyticsSourceRef['kind'][];
123
123
  /** Supported operation/version pairs; providers must enforce read-only behavior at the source. */
124
124
  operations: Array<{
125
125
  name: string;
@@ -131,30 +131,22 @@ export interface AnalyticsProviderDescriptor {
131
131
  mode: 'viewer_permissions' | 'owner_only';
132
132
  reasonCode?: string;
133
133
  };
134
- /** Optional new source type and configuration schema, never connection values; omit for existing types. */
135
- connectionType?: {
136
- type: string;
137
- name: string;
138
- configuration: Record<string, JSONValue>;
139
- };
140
134
  }
141
135
  /** Discoverable source and available providers for the current actor; contains no connection options. */
142
136
  export interface AnalyticsSourceSummary {
143
- id: string;
137
+ source: AnalyticsSourceRef;
144
138
  name: string;
145
- type: string;
146
139
  providers: AnalyticsProviderDescriptor[];
147
140
  }
148
141
  /** Read-only catalog navigation; continuation data is provider-owned and never grants authorization. */
149
142
  export interface AnalyticsDiscoveryRequest {
150
- dataSourceId: string;
143
+ source: AnalyticsSourceRef;
151
144
  providerId: string;
152
145
  /** Initial provider request or a returned inspectRequest/nextRequest, forwarded without interpretation. */
153
146
  request: JSONValue;
154
147
  }
155
148
  /** Bounded discovery page plus the native query contract needed by an Agent or query builder. */
156
149
  export interface AnalyticsDiscoveryResult {
157
- schemaVersion: 1;
158
150
  items: Array<{
159
151
  /** Provider-local resource identity; need not be a platform entity UUID. */
160
152
  id: string;
@@ -0,0 +1,16 @@
1
+ /** References are identities, never credentials, actor scope or mutable latest pointers. */
2
+ export type AnalyticsSourceRef = {
3
+ kind: 'data-source';
4
+ dataSourceId: string;
5
+ } | {
6
+ kind: 'definition';
7
+ definitionId: string;
8
+ versionId: string;
9
+ } | {
10
+ kind: 'artifact';
11
+ artifactId: string;
12
+ versionId: string;
13
+ };
14
+ export type AnalyticsVersionedSourceRef = Exclude<AnalyticsSourceRef, {
15
+ kind: 'data-source';
16
+ }>;