@xpert-ai/contracts 3.21.3 → 3.23.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/index.cjs.js CHANGED
@@ -7866,6 +7866,7 @@ function isUserOrganizationEntryGuideKey(value) {
7866
7866
 
7867
7867
  exports.UserGroupManagedByEnum = void 0;
7868
7868
  (function(UserGroupManagedByEnum) {
7869
+ UserGroupManagedByEnum["XPERT_SHARING"] = "xpert-sharing";
7869
7870
  UserGroupManagedByEnum["XPERT_MARKETPLACE"] = "xpert-marketplace";
7870
7871
  })(exports.UserGroupManagedByEnum || (exports.UserGroupManagedByEnum = {}));
7871
7872
  exports.UserGroupManagedEntityTypeEnum = void 0;
package/index.esm.js CHANGED
@@ -7865,6 +7865,7 @@ function isUserOrganizationEntryGuideKey(value) {
7865
7865
 
7866
7866
  var UserGroupManagedByEnum;
7867
7867
  (function(UserGroupManagedByEnum) {
7868
+ UserGroupManagedByEnum["XPERT_SHARING"] = "xpert-sharing";
7868
7869
  UserGroupManagedByEnum["XPERT_MARKETPLACE"] = "xpert-marketplace";
7869
7870
  })(UserGroupManagedByEnum || (UserGroupManagedByEnum = {}));
7870
7871
  var UserGroupManagedEntityTypeEnum;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xpert-ai/contracts",
3
- "version": "3.21.3",
3
+ "version": "3.23.0",
4
4
  "license": "AGPL-3.0",
5
5
  "repository": {
6
6
  "type": "git",
@@ -21,7 +21,7 @@
21
21
  "dependencies": {
22
22
  "@octokit/types": "13.10.0",
23
23
  "@types/json-schema": "^7.0.15",
24
- "@xpert-ai/chatkit-types": "0.14.2",
24
+ "@xpert-ai/chatkit-types": "0.16.0",
25
25
  "zod-to-json-schema": "^3.25.2"
26
26
  },
27
27
  "peerDependencies": {
@@ -0,0 +1,24 @@
1
+ /** Updates follow a Git branch; existing runtime selections remain pinned. */
2
+ export interface AgentPluginUpdateProgress {
3
+ operationId: string | null;
4
+ packageId: string | null;
5
+ branch: string | null;
6
+ commit: string | null;
7
+ phase: 'idle' | 'updating' | 'completed' | 'failed';
8
+ result?: {
9
+ packageId: string;
10
+ status: 'imported' | 'existing' | 'repaired';
11
+ };
12
+ error?: string;
13
+ }
14
+ export interface AgentPluginCleanupItem {
15
+ packageId: string;
16
+ version: string;
17
+ reason: 'current' | 'updating' | 'configured' | 'referenced' | 'unreferenced';
18
+ }
19
+ export interface AgentPluginCleanupResult {
20
+ targetPackageId: string;
21
+ items: AgentPluginCleanupItem[];
22
+ deleted: string[];
23
+ pendingFileCleanup: number;
24
+ }
@@ -6,6 +6,10 @@ import type { I18nText } from './i18n.model';
6
6
  * agent_plugin is distinct from a native server-code plugin.
7
7
  */
8
8
  export type RuntimeResourceKind = 'agent_plugin' | 'middleware' | 'external_xpert';
9
+ /** Package usage role; omission preserves legacy ChatKit visibility. */
10
+ export type AgentPluginRole = 'capability' | 'assistant' | 'subagent';
11
+ /** Selection lookup retains metadata for existing references hidden from discovery. */
12
+ export type RuntimeResourceCatalogPurpose = 'browse' | 'selection';
9
13
  /**
10
14
  * Availability in the current user/project context; execution still revalidates access.
11
15
  * partial means some components are usable; requires_auth needs Connector authorization;
@@ -19,6 +23,33 @@ export interface RuntimeResourceReference {
19
23
  /** Opaque resource version; existing selections must not silently upgrade. */
20
24
  version: string;
21
25
  }
26
+ /** Presentation only. Executable instructions stay in the referenced SKILL.md. */
27
+ export interface AgentPluginCommandPresentation {
28
+ label?: I18nText;
29
+ description?: I18nText;
30
+ argsHint?: string;
31
+ }
32
+ export interface AgentPluginCommand extends AgentPluginCommandPresentation {
33
+ /** Arguments interpreted by the skill, not separately executable commands. */
34
+ subcommands?: Record<string, AgentPluginCommandPresentation>;
35
+ }
36
+ /** A skill in an exact selected plugin version; never a workspace skill authorization. */
37
+ export interface RuntimeResourceSkillReference extends RuntimeResourceReference {
38
+ skillKey: string;
39
+ }
40
+ export interface RuntimeResourceCommand {
41
+ skill: RuntimeResourceSkillReference;
42
+ packageName: string;
43
+ description: string;
44
+ command: AgentPluginCommand;
45
+ }
46
+ /** Immutable template identity used by task-level Agent executions. */
47
+ export interface TemplateAgentSource extends RuntimeResourceReference {
48
+ kind: 'agent_plugin_template';
49
+ packageName: string;
50
+ digest: string;
51
+ templateKey: string;
52
+ }
22
53
  /**
23
54
  * Complete conversation selection, independent of graph runtimeCapabilities.
24
55
  * Updates apply to the next execution without changing the Assistant graph.
@@ -53,7 +84,9 @@ export interface RuntimeResourceCatalogItem extends RuntimeResourceReference {
53
84
  /** Package components and their individual availability. Plugins are selected as a whole. */
54
85
  components: Array<{
55
86
  key: string;
56
- kind: 'skill' | 'mcp' | 'middleware' | 'external_xpert';
87
+ kind: 'skill' | 'mcp' | 'middleware' | 'external_xpert' | 'assistant_template';
88
+ title?: string;
89
+ description?: string;
57
90
  status: RuntimeResourceStatus;
58
91
  }>;
59
92
  }
@@ -79,6 +112,10 @@ export interface RuntimeResourceCatalog {
79
112
  export interface AgentPluginXpertExtension {
80
113
  /** Extension schema version, independent of the Agent Plugins spec version. */
81
114
  version: 1 | 2;
115
+ /** Only assistant is excluded from ChatKit discovery; template availability is independent. */
116
+ role?: AgentPluginRole;
117
+ /** Skill-keyed shortcuts. Omitted skills have no command shortcut. */
118
+ commands?: Record<string, AgentPluginCommand>;
82
119
  /** Version 2: package-contained Assistant DSL; runtime state is never packaged. */
83
120
  templates?: Array<{
84
121
  key: string;
@@ -17,25 +17,25 @@ export declare const agentRuntimeProgressSchema: z.ZodObject<{
17
17
  completed: z.ZodNumber;
18
18
  total: z.ZodNumber;
19
19
  }, "strict", z.ZodTypeAny, {
20
- total?: number;
21
20
  completed?: number;
22
- }, {
23
21
  total?: number;
22
+ }, {
24
23
  completed?: number;
25
- }>, {
26
24
  total?: number;
25
+ }>, {
27
26
  completed?: number;
28
- }, {
29
27
  total?: number;
28
+ }, {
30
29
  completed?: number;
30
+ total?: number;
31
31
  }>>;
32
32
  }, "strict", z.ZodTypeAny, {
33
33
  source?: "executor" | "host";
34
34
  startedAt?: string;
35
35
  summary?: string;
36
36
  steps?: {
37
- total?: number;
38
37
  completed?: number;
38
+ total?: number;
39
39
  };
40
40
  observedAt?: string;
41
41
  phase?: string;
@@ -44,8 +44,8 @@ export declare const agentRuntimeProgressSchema: z.ZodObject<{
44
44
  startedAt?: string;
45
45
  summary?: string;
46
46
  steps?: {
47
- total?: number;
48
47
  completed?: number;
48
+ total?: number;
49
49
  };
50
50
  observedAt?: string;
51
51
  phase?: string;
@@ -13,15 +13,19 @@ import type { TAvatar } from '../types';
13
13
  * routes back to its sender; `message` publishes information without waking addressed Assistants.
14
14
  */
15
15
  export type ChatGroupIntent = 'request' | 'reply' | 'message';
16
- /** Per-recipient delivery progress, not a read receipt or the overall Assistant run status. */
16
+ /** Per-recipient delivery progress, independent of the overall Assistant run status. */
17
17
  export type ChatGroupDeliveryStatus =
18
18
  /** Accepted for delivery; dispatch may still be pending. */
19
19
  'pending'
20
- /** Starting an Assistant run for this message. */
20
+ /** Runtime reserved; acceptance of this specific input has not yet been confirmed. */
21
21
  | 'starting'
22
22
  /** Submitted to an active run through the existing steer/follow-up mechanism. */
23
23
  | 'steering'
24
- /** Consumed by the runtime; does not by itself mean a reply has been published. */
24
+ /**
25
+ * Consumed by the runtime; an Assistant delivery linked to an execution can display this as "read".
26
+ * Non-waking deliveries also use this terminal state, without asserting that a human has read them.
27
+ * Does not mean a reply has been published or the run has finished.
28
+ */
25
29
  | 'consumed'
26
30
  /** Delivery cannot proceed under the current authorization or runtime state. */
27
31
  | 'blocked'
@@ -89,7 +89,7 @@ export declare const executionActivityItemSchema: z.ZodObject<{
89
89
  }[];
90
90
  }>]>>;
91
91
  }, "strict", z.ZodTypeAny, {
92
- status?: "unknown" | "succeeded" | "failed" | "running";
92
+ status?: "failed" | "unknown" | "succeeded" | "running";
93
93
  name?: string;
94
94
  input?: string;
95
95
  output?: string;
@@ -114,7 +114,7 @@ export declare const executionActivityItemSchema: z.ZodObject<{
114
114
  key?: string;
115
115
  };
116
116
  }, {
117
- status?: "unknown" | "succeeded" | "failed" | "running";
117
+ status?: "failed" | "unknown" | "succeeded" | "running";
118
118
  name?: string;
119
119
  input?: string;
120
120
  output?: string;
@@ -157,7 +157,7 @@ export declare const executionActivityItemSchema: z.ZodObject<{
157
157
  text?: string;
158
158
  kind?: "message";
159
159
  } | {
160
- status?: "unknown" | "succeeded" | "failed" | "running";
160
+ status?: "failed" | "unknown" | "succeeded" | "running";
161
161
  name?: string;
162
162
  input?: string;
163
163
  output?: string;
@@ -193,7 +193,7 @@ export declare const executionActivityItemSchema: z.ZodObject<{
193
193
  text?: string;
194
194
  kind?: "message";
195
195
  } | {
196
- status?: "unknown" | "succeeded" | "failed" | "running";
196
+ status?: "failed" | "unknown" | "succeeded" | "running";
197
197
  name?: string;
198
198
  input?: string;
199
199
  output?: string;
@@ -304,7 +304,7 @@ export declare const executionActivityBatchSchema: z.ZodObject<{
304
304
  }[];
305
305
  }>]>>;
306
306
  }, "strict", z.ZodTypeAny, {
307
- status?: "unknown" | "succeeded" | "failed" | "running";
307
+ status?: "failed" | "unknown" | "succeeded" | "running";
308
308
  name?: string;
309
309
  input?: string;
310
310
  output?: string;
@@ -329,7 +329,7 @@ export declare const executionActivityBatchSchema: z.ZodObject<{
329
329
  key?: string;
330
330
  };
331
331
  }, {
332
- status?: "unknown" | "succeeded" | "failed" | "running";
332
+ status?: "failed" | "unknown" | "succeeded" | "running";
333
333
  name?: string;
334
334
  input?: string;
335
335
  output?: string;
@@ -372,7 +372,7 @@ export declare const executionActivityBatchSchema: z.ZodObject<{
372
372
  text?: string;
373
373
  kind?: "message";
374
374
  } | {
375
- status?: "unknown" | "succeeded" | "failed" | "running";
375
+ status?: "failed" | "unknown" | "succeeded" | "running";
376
376
  name?: string;
377
377
  input?: string;
378
378
  output?: string;
@@ -408,7 +408,7 @@ export declare const executionActivityBatchSchema: z.ZodObject<{
408
408
  text?: string;
409
409
  kind?: "message";
410
410
  } | {
411
- status?: "unknown" | "succeeded" | "failed" | "running";
411
+ status?: "failed" | "unknown" | "succeeded" | "running";
412
412
  name?: string;
413
413
  input?: string;
414
414
  output?: string;
@@ -451,7 +451,7 @@ export declare const executionActivityBatchSchema: z.ZodObject<{
451
451
  text?: string;
452
452
  kind?: "message";
453
453
  } | {
454
- status?: "unknown" | "succeeded" | "failed" | "running";
454
+ status?: "failed" | "unknown" | "succeeded" | "running";
455
455
  name?: string;
456
456
  input?: string;
457
457
  output?: string;
@@ -493,7 +493,7 @@ export declare const executionActivityBatchSchema: z.ZodObject<{
493
493
  text?: string;
494
494
  kind?: "message";
495
495
  } | {
496
- status?: "unknown" | "succeeded" | "failed" | "running";
496
+ status?: "failed" | "unknown" | "succeeded" | "running";
497
497
  name?: string;
498
498
  input?: string;
499
499
  output?: string;
@@ -607,13 +607,13 @@ export declare const projectTaskDispatchReceiptSchema: z.ZodObject<{
607
607
  invocationId: z.ZodString;
608
608
  status: z.ZodEnum<["queued", "running", "waiting", "cancelling", "succeeded", "failed", "cancelled", "unknown"]>;
609
609
  }, "strict", z.ZodTypeAny, {
610
- status?: "unknown" | "succeeded" | "failed" | "running" | "queued" | "waiting" | "cancelled" | "cancelling";
610
+ status?: "failed" | "unknown" | "succeeded" | "running" | "queued" | "waiting" | "cancelled" | "cancelling";
611
611
  projectId?: string;
612
612
  invocationId?: string;
613
613
  projectTaskId?: string;
614
614
  taskExecutionId?: string;
615
615
  }, {
616
- status?: "unknown" | "succeeded" | "failed" | "running" | "queued" | "waiting" | "cancelled" | "cancelling";
616
+ status?: "failed" | "unknown" | "succeeded" | "running" | "queued" | "waiting" | "cancelled" | "cancelling";
617
617
  projectId?: string;
618
618
  invocationId?: string;
619
619
  projectTaskId?: string;
@@ -99,6 +99,7 @@ export declare enum XpertAgentExecutionStatusEnum {
99
99
  INTERRUPTED = "interrupted"
100
100
  }
101
101
  export type TAgentExecutionMetadata = {
102
+ templateSource?: import('../agent-plugin').TemplateAgentSource;
102
103
  businessOutcome?: import('@xpert-ai/chatkit-types').TAgentExecutionOutcome;
103
104
  /** Recorded by the invocation boundary; never inferred from agent names. */
104
105
  invocationKind?: 'external_assistant' | 'sub_agent';
@@ -305,6 +305,11 @@ export type TXpertDataXpertOptions = {
305
305
  [key: string]: unknown;
306
306
  };
307
307
  export type TXpertOptions = {
308
+ /** Server-owned activation checkpoint; excluded from reusable template exports/imports. */
309
+ pendingPublication?: {
310
+ version: string;
311
+ previousGraph?: TXpertGraph;
312
+ };
308
313
  operationPolicy?: import('./assistant-template-setup.model').AssistantOperationPolicy;
309
314
  templateDefinition?: import('./assistant-template.model').AssistantTemplateMetadata;
310
315
  templateDependencyLocks?: import('./template-installation.model').TemplateDependencyLock[];
@@ -0,0 +1,175 @@
1
+ import type { JSONValue } from './core.model';
2
+ /** JSON-safe scalar shared by cells and controls; nested objects/arrays are not dataset cells. */
3
+ export type AnalyticsValue = string | number | boolean | null;
4
+ /** int64/decimal use exact strings; date uses YYYY-MM-DD; timestamp includes a timezone. */
5
+ export type AnalyticsLogicalType = 'string' | 'boolean' | 'int64' | 'float64' | 'decimal' | 'date' | 'timestamp';
6
+ /** Maps one provider column to a stable, typed field consumed by renderers. */
7
+ export interface AnalyticsField {
8
+ /** Dataset row key and chart-binding identifier; never derived from the display label. */
9
+ id: string;
10
+ /** Exact provider column key used when semanticRef is absent. */
11
+ sourceField: string;
12
+ label: string;
13
+ logicalType: AnalyticsLogicalType;
14
+ /** Allows null cells, not missing row keys. */
15
+ nullable: boolean;
16
+ /** Declared business role; does not implicitly aggregate or convert values. */
17
+ role: 'dimension' | 'measure' | 'time' | 'identifier';
18
+ /** Exact provider semantic identifier; takes precedence over sourceField and must match one column. */
19
+ semanticRef?: string;
20
+ /** Authored unit such as CNY; metadata only, with no automatic scaling or conversion. */
21
+ unit?: string;
22
+ }
23
+ /** Output projection shared by native SQL, ontology, file and other provider implementations. */
24
+ export interface AnalyticsOutputContract {
25
+ /** Renderer-facing identifier, independent of native table/resource names. */
26
+ datasetId: string;
27
+ fields: AnalyticsField[];
28
+ /** Composite key of field IDs, unique within returned rows; [] leaves grain unspecified. */
29
+ grain: string[];
30
+ }
31
+ /** Maps a UI control to a validated provider parameter without rewriting the native payload. */
32
+ export interface AnalyticsParameter {
33
+ /** Key passed to the provider's resolved parameters object. */
34
+ name: string;
35
+ /** Key read from request.controls; multiple parameters may consume the same control. */
36
+ controlId: string;
37
+ /** Scalar parameter type; date is a valid YYYY-MM-DD string. */
38
+ type: 'string' | 'number' | 'boolean' | 'date';
39
+ /** Rejects missing/null values after defaults; unresolved optional parameters become null. */
40
+ required: boolean;
41
+ /** Used only when the control key is absent; an explicit null does not select this default. */
42
+ defaultValue?: AnalyticsValue;
43
+ /** Optional allowlist for non-null values; does not grant access to source data. */
44
+ allowedValues?: AnalyticsValue[];
45
+ }
46
+ /**
47
+ * Serializable query declaration. The host owns scope/limits; the provider owns native syntax.
48
+ * Renderers consume the normalized Dataset, never execute payload or handle source credentials.
49
+ */
50
+ export interface AnalyticsBinding {
51
+ /** Version of this shared envelope, separate from the provider operation's contractVersion. */
52
+ schemaVersion: 1;
53
+ /** Binding identity used for lookup and result provenance. */
54
+ id: string;
55
+ /** Platform DataSource ID; access is rechecked for the current actor on each execution. */
56
+ dataSourceId: string;
57
+ /** Registered provider descriptor ID, not a display name or database engine switch. */
58
+ providerId: string;
59
+ /** Must match a read-only operation advertised by the provider. */
60
+ operation: string;
61
+ /** Provider-owned operation version; incompatible payload semantics require a new version. */
62
+ contractVersion: number;
63
+ /** Provider-defined JSON, e.g. a native query or resource reference; exclude credentials and actor scope. */
64
+ payload: JSONValue;
65
+ parameters: AnalyticsParameter[];
66
+ output: AnalyticsOutputContract;
67
+ }
68
+ /** Public query input; tenant, organization and user identity come from trusted host context. */
69
+ export interface AnalyticsQueryRequest {
70
+ binding: AnalyticsBinding;
71
+ /** Values keyed by controlId; undeclared keys are rejected and absent keys resolve through defaults. */
72
+ controls: Record<string, AnalyticsValue>;
73
+ }
74
+ /** Canonical, provider-independent result; consumers must inspect completeness before presenting totals. */
75
+ export interface AnalyticalDataset {
76
+ schema: 'xpert.analytics.dataset/v1';
77
+ datasetId: string;
78
+ /** Preserved even when rows is empty, so renderers can retain bindings and labels. */
79
+ fields: AnalyticsField[];
80
+ /** Keys are AnalyticsField.id, not native column names; precise numbers remain strings. */
81
+ rows: Array<Record<string, AnalyticsValue>>;
82
+ /** Declared output grain, validated for uniqueness when nonempty. */
83
+ grain: string[];
84
+ completeness: {
85
+ /** Number of rows in this response; must equal rows.length. */
86
+ returnedRows: number;
87
+ /** Optional source count, qualified by totalAccuracy; absence never means zero. */
88
+ totalRows?: number;
89
+ totalAccuracy: 'exact' | 'estimated' | 'unknown';
90
+ /** What the response represents; page/sample/top_n must not be presented as the complete query. */
91
+ scope: 'full_query_result' | 'page' | 'sample' | 'top_n';
92
+ /** Omitted rows due to a limit; cannot be true with full_query_result. */
93
+ truncated: boolean;
94
+ };
95
+ freshness: {
96
+ /** Host timestamp when the result was normalized, not the source's business-data timestamp. */
97
+ executedAt: string;
98
+ /** Provider timestamp for fetching source data; must not be replaced with page render time. */
99
+ sourceFetchedAt: string;
100
+ /** Optional source-reported snapshot/watermark time; omit when unknown. */
101
+ dataAsOf?: string;
102
+ };
103
+ provenance: {
104
+ /** Host-generated execution identity, distinct from the reusable Binding ID. */
105
+ executionId: string;
106
+ bindingId: string;
107
+ providerId: string;
108
+ /** Opaque source/definition revision; not an authorization token or cache permission. */
109
+ sourceVersion?: string;
110
+ /** Source-system execution identity, when the provider delegates execution. */
111
+ upstreamExecutionId?: string;
112
+ /** Reference to governed audit evidence; do not embed secrets or full logs here. */
113
+ auditRef?: string;
114
+ };
115
+ }
116
+ /** Public discovery metadata. Advertising a capability does not authorize its execution. */
117
+ export interface AnalyticsProviderDescriptor {
118
+ /** Stable registration ID used by Binding.providerId. */
119
+ id: string;
120
+ name: string;
121
+ /** Exact platform DataSource.type identifiers supported by this provider. */
122
+ dataSourceTypes: string[];
123
+ /** Supported operation/version pairs; providers must enforce read-only behavior at the source. */
124
+ operations: Array<{
125
+ name: string;
126
+ contractVersion: number;
127
+ readOnly: true;
128
+ }>;
129
+ /** Optional new source type and configuration schema, never connection values; omit for existing types. */
130
+ connectionType?: {
131
+ type: string;
132
+ name: string;
133
+ configuration: Record<string, JSONValue>;
134
+ };
135
+ }
136
+ /** Discoverable source and available providers for the current actor; contains no connection options. */
137
+ export interface AnalyticsSourceSummary {
138
+ id: string;
139
+ name: string;
140
+ type: string;
141
+ providers: AnalyticsProviderDescriptor[];
142
+ }
143
+ /** Read-only catalog navigation; continuation data is provider-owned and never grants authorization. */
144
+ export interface AnalyticsDiscoveryRequest {
145
+ dataSourceId: string;
146
+ providerId: string;
147
+ /** Initial provider request or a returned inspectRequest/nextRequest, forwarded without interpretation. */
148
+ request: JSONValue;
149
+ }
150
+ /** Bounded discovery page plus the native query contract needed by an Agent or query builder. */
151
+ export interface AnalyticsDiscoveryResult {
152
+ schemaVersion: 1;
153
+ items: Array<{
154
+ /** Provider-local resource identity; need not be a platform entity UUID. */
155
+ id: string;
156
+ name: string;
157
+ /** Explicit navigation distinction; consumers must not infer it from names or metadata. */
158
+ kind: 'collection' | 'dataset';
159
+ description?: string;
160
+ /** Request for inspecting this item using the same source/provider; not a token or executable query. */
161
+ inspectRequest?: JSONValue;
162
+ /** Provider-owned metadata, e.g. authored field descriptions, units or ontology definitions. */
163
+ metadata: JSONValue;
164
+ }>;
165
+ /** Request for the next discovery page; omission means no continuation is offered. */
166
+ nextRequest?: JSONValue;
167
+ /** Describes Binding.payload; actual queries still require provider validation and authorization. */
168
+ queryContract: {
169
+ operation: string;
170
+ contractVersion: number;
171
+ payloadSchema: JSONValue;
172
+ /** Native syntax and business-semantic guidance; does not replace payloadSchema validation. */
173
+ instructions: string;
174
+ };
175
+ }
@@ -98,6 +98,21 @@ export interface IArtifactVersion extends IBasePerTenantAndOrganizationEntityMod
98
98
  userId?: string | null;
99
99
  metadata?: Record<string, unknown> | null;
100
100
  }
101
+ /** Persisted mutable working copy, separate from immutable Artifact versions. */
102
+ export interface IArtifactDraft extends IBasePerTenantAndOrganizationEntityModel {
103
+ artifactId: string;
104
+ revision: number;
105
+ baseVersionId: string | null;
106
+ publishedRevision: number | null;
107
+ publishedVersionId: string | null;
108
+ content: {
109
+ workspaceFileRef: IArtifactWorkspaceFileReference;
110
+ mimeType: string;
111
+ title?: string | null;
112
+ sha256?: string | null;
113
+ metadata?: Record<string, unknown> | null;
114
+ };
115
+ }
101
116
  /**
102
117
  * Access entrypoint for an Artifact.
103
118
  *
@@ -0,0 +1,32 @@
1
+ import { IUser } from './user.model';
2
+ export type AssistantSharingUser = Pick<IUser, 'id' | 'firstName' | 'lastName' | 'email' | 'username' | 'imageUrl'>;
3
+ export type AssistantSharingGroup = {
4
+ id: string;
5
+ name: string;
6
+ description?: string | null;
7
+ };
8
+ export type AssistantSharingCapabilities = {
9
+ canViewAccess: boolean;
10
+ canManageAccess: boolean;
11
+ canUseGroups: boolean;
12
+ canManageGroups: boolean;
13
+ };
14
+ export type AssistantSharingState = {
15
+ capabilities: AssistantSharingCapabilities;
16
+ organization: {
17
+ id: string;
18
+ name: string;
19
+ };
20
+ users: AssistantSharingUser[];
21
+ groups: AssistantSharingGroup[];
22
+ groupRevision: string;
23
+ inherited: {
24
+ creator?: AssistantSharingUser;
25
+ workspace?: {
26
+ id: string;
27
+ name: string;
28
+ organizationShared: boolean;
29
+ memberCount: number;
30
+ };
31
+ };
32
+ };
@@ -7,7 +7,7 @@ export declare const DEFAULT_AGENT_PLUGINS_SOURCE: {
7
7
  };
8
8
  export interface DefaultAgentPluginImportItem {
9
9
  id: string;
10
- status: 'imported' | 'existing' | 'failed';
10
+ status: 'imported' | 'existing' | 'repaired' | 'failed';
11
11
  packageId?: string;
12
12
  title?: string;
13
13
  diagnosticCount?: number;
@@ -17,3 +17,14 @@ export interface DefaultAgentPluginsImportResult {
17
17
  commit: string;
18
18
  items: DefaultAgentPluginImportItem[];
19
19
  }
20
+ /** Scope-owned receipt for a background import; completed items survive API restarts. */
21
+ export interface DefaultAgentPluginsImportProgress {
22
+ operationId: string | null;
23
+ phase: 'idle' | 'fetching' | 'importing' | 'completed' | 'failed';
24
+ commit: string | null;
25
+ total: number;
26
+ currentId: string | null;
27
+ items: DefaultAgentPluginImportItem[];
28
+ updatedAt: string;
29
+ error?: string;
30
+ }
package/src/index.d.ts CHANGED
@@ -39,9 +39,11 @@ export * from './user-organization.model';
39
39
  export * from './user-group.model';
40
40
  export * from './user-me-context.model';
41
41
  export * from './user.model';
42
+ export * from './user-directory.model';
42
43
  export * from './custom-smtp.model';
43
44
  export * from './date-picker.model';
44
45
  export * from './data-source.model';
46
+ export * from './analytics-query.model';
45
47
  export * from './data-source-type.model';
46
48
  export * from './integration.model';
47
49
  export * from './invite.model';
@@ -65,9 +67,11 @@ export * from './plain-object.model';
65
67
  export * from './plugin';
66
68
  export * from './view-extension';
67
69
  export * from './runtime-control';
68
- export type { RuntimeResourceKind, RuntimeResourceStatus, RuntimeResourceReference, RuntimeResourcesSelection, AgentPluginDiagnostic, RuntimeResourceCatalogItem, RuntimeResourceView, RuntimeResourceCatalog, AgentPluginXpertExtension, AgentPluginConnectorAuth, AgentPluginConnectorBinding, RuntimeResourceDefinition, RuntimeResourceBindingInput, WorkspaceAgentPlugin, WorkspaceAgentPluginOptions, WorkspaceAgentPluginAddInput, WorkspaceAgentPluginAddResult, InstalledAgentPlugin } from './agent-plugin';
70
+ export type { RuntimeResourceKind, AgentPluginRole, RuntimeResourceCatalogPurpose, RuntimeResourceStatus, RuntimeResourceReference, TemplateAgentSource, RuntimeResourcesSelection, AgentPluginDiagnostic, RuntimeResourceCatalogItem, RuntimeResourceView, RuntimeResourceCatalog, AgentPluginXpertExtension, AgentPluginCommand, AgentPluginCommandPresentation, RuntimeResourceCommand, RuntimeResourceSkillReference, AgentPluginConnectorAuth, AgentPluginConnectorBinding, RuntimeResourceDefinition, RuntimeResourceBindingInput, WorkspaceAgentPlugin, WorkspaceAgentPluginOptions, WorkspaceAgentPluginAddInput, WorkspaceAgentPluginAddResult, InstalledAgentPlugin } from './agent-plugin';
69
71
  export * from './desktop-shell.model';
70
72
  export * from './ai/agent-output-delivery.model';
71
73
  export * from './ai/execution-activity.model';
72
74
  export * from './setup-plugins';
73
75
  export * from './default-agent-plugins';
76
+ export * from './agent-plugin-maintenance';
77
+ export * from './assistant-sharing.model';
@@ -57,6 +57,7 @@ export interface PluginMarketplaceAppModelRequirements {
57
57
  primary?: boolean;
58
58
  embedding?: boolean;
59
59
  vision?: boolean;
60
+ speechToText?: boolean;
60
61
  embeddingLabel?: string | I18nObject;
61
62
  visionLabel?: string | I18nObject;
62
63
  }
@@ -216,9 +217,10 @@ export interface PluginApplicationPreflight {
216
217
  supported: boolean;
217
218
  scope: PluginApplicationScope;
218
219
  canInitialize: boolean;
219
- reason?: 'organization_scope_required' | 'role_required' | 'scope_not_supported' | 'primary_model_required' | 'embedding_model_required' | 'vision_model_required' | 'toolset_provider_required' | 'toolset_configuration_required';
220
+ reason?: 'organization_scope_required' | 'role_required' | 'scope_not_supported' | 'primary_model_required' | 'embedding_model_required' | 'vision_model_required' | 'speech_to_text_model_required' | 'toolset_provider_required' | 'toolset_configuration_required';
220
221
  embeddingModels: PluginApplicationModelOption[];
221
222
  visionModels: PluginApplicationModelOption[];
223
+ speechToTextModels?: PluginApplicationModelOption[];
222
224
  /** Organization Embedding-role default when it is present in embeddingModels. */
223
225
  defaultEmbeddingModelId?: string | null;
224
226
  /** Organization Primary-role default when it is vision-capable and present in visionModels. */
@@ -250,6 +252,7 @@ export interface PluginApplicationInitializeInput {
250
252
  appName: string;
251
253
  embeddingModelId?: string;
252
254
  visionModelId?: string;
255
+ speechToTextModelId?: string;
253
256
  toolsets?: PluginApplicationToolsetSelection[];
254
257
  operationId: string;
255
258
  }
@@ -0,0 +1,15 @@
1
+ import type { IOrganization } from './organization.model';
2
+ import type { IUser, UserType } from './user.model';
3
+ export type UserDirectoryStatus = 'all' | 'active' | 'disabled';
4
+ export interface IUserDirectoryQuery {
5
+ take?: number;
6
+ skip?: number;
7
+ search?: string;
8
+ types?: UserType[];
9
+ roles?: string[];
10
+ status?: UserDirectoryStatus;
11
+ organizationIds?: string[];
12
+ }
13
+ export interface IUserDirectoryItem extends IUser {
14
+ displayOrganizations: IOrganization[];
15
+ }
@@ -1,6 +1,7 @@
1
1
  import { IBasePerTenantAndOrganizationEntityModel } from './base-entity.model';
2
2
  import { IUser } from './user.model';
3
3
  export declare enum UserGroupManagedByEnum {
4
+ XPERT_SHARING = "xpert-sharing",
4
5
  XPERT_MARKETPLACE = "xpert-marketplace"
5
6
  }
6
7
  export declare enum UserGroupManagedEntityTypeEnum {
@@ -35,6 +35,8 @@ export interface XpertViewHostCapabilities {
35
35
  featureProviders?: Record<string, XpertViewFeatureProvider[]>;
36
36
  }
37
37
  export interface XpertViewRuntimeScopeInput {
38
+ /** Route through the group boundary; the server resolves and validates its runtime. */
39
+ groupId?: string | null;
38
40
  projectId?: string | null;
39
41
  conversationId?: string | null;
40
42
  }
@@ -545,6 +547,12 @@ export interface XpertRemoteViewContextChangedEvent extends XpertRemoteViewHostE
545
547
  runtimeScope: Required<XpertViewRuntimeScopeInput>;
546
548
  };
547
549
  }
550
+ /** Credential-free activation signal from the top-level shell to its embedded views. */
551
+ export interface XpertHostLifecycleMessage {
552
+ channel: 'xpertai.host_lifecycle';
553
+ protocolVersion: 1;
554
+ type: 'activated';
555
+ }
548
556
  /**
549
557
  * Host-internal event message. `hostType` and `hostId` are routing fields and
550
558
  * must be stripped before forwarding to remote components.