@xpert-ai/contracts 3.37.2 → 3.38.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xpert-ai/contracts",
3
- "version": "3.37.2",
3
+ "version": "3.38.0",
4
4
  "license": "AGPL-3.0",
5
5
  "repository": {
6
6
  "type": "git",
@@ -37,7 +37,7 @@
37
37
  "dependencies": {
38
38
  "@octokit/types": "13.10.0",
39
39
  "@types/json-schema": "^7.0.15",
40
- "@xpert-ai/chatkit-types": "~0.23.0",
40
+ "@xpert-ai/chatkit-types": "~0.24.0",
41
41
  "zod-to-json-schema": "^3.25.2"
42
42
  },
43
43
  "peerDependencies": {
@@ -0,0 +1,27 @@
1
+ export type ConversationProjectDestination = 'existing' | 'create';
2
+ export interface ConversationProjectMoveOffer {
3
+ requestId: string;
4
+ assistantMessageId: string;
5
+ threadId: string;
6
+ /** Initial preference until confirmation, then the mode used to bind the Project. */
7
+ destination: ConversationProjectDestination;
8
+ projectId: string | null;
9
+ projectName?: string;
10
+ executionId: string;
11
+ conversationId: string;
12
+ waitingForIdle: boolean;
13
+ executionStatus: string | null;
14
+ }
15
+ export type ConversationProjectMoveConfirmation = {
16
+ requestId: string;
17
+ moveFromConversationId: string;
18
+ threadId: string;
19
+ shareHistory: true;
20
+ target: {
21
+ mode: 'existing';
22
+ projectId: string;
23
+ } | {
24
+ mode: 'create';
25
+ name: string;
26
+ };
27
+ };
package/src/ai/index.d.ts CHANGED
@@ -6,6 +6,7 @@ export type * from '@xpert-ai/chatkit-types';
6
6
  export type { IconDefinition, IconType } from '../types';
7
7
  export type { TChatRequest } from './xpert-chat.model';
8
8
  export type { ProjectSelection } from './project-selection.model';
9
+ export * from './conversation-project-move.model';
9
10
  export { CHAT_EVENT_TYPE_FOLLOW_UP_CONSUMED } from './chat-event.model';
10
11
  export * from './assistant-binding.model';
11
12
  export * from './clawxpert-recovery.model';
@@ -139,3 +140,4 @@ export * from './execution-observability.model';
139
140
  export * from './model-management.model';
140
141
  export * from './model-replacement.model';
141
142
  export * from './default-model-role';
143
+ export * from './project-task-view.model';
@@ -0,0 +1,133 @@
1
+ import { z } from 'zod';
2
+ /** Resource names determine the projection; clients cannot request arbitrary entity fields. */
3
+ export declare const projectTaskViewQuerySchema: z.ZodDiscriminatedUnion<"resource", [z.ZodObject<{
4
+ resource: z.ZodLiteral<"context">;
5
+ contractVersion: z.ZodLiteral<2>;
6
+ knownVersion: z.ZodOptional<z.ZodString>;
7
+ }, "strict", z.ZodTypeAny, {
8
+ resource?: "context";
9
+ contractVersion?: 2;
10
+ knownVersion?: string;
11
+ }, {
12
+ resource?: "context";
13
+ contractVersion?: 2;
14
+ knownVersion?: string;
15
+ }>, z.ZodObject<{
16
+ resource: z.ZodLiteral<"task-index">;
17
+ compactAvatars: z.ZodOptional<z.ZodBoolean>;
18
+ avatarVersions: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
19
+ contractVersion: z.ZodLiteral<2>;
20
+ knownVersion: z.ZodOptional<z.ZodString>;
21
+ }, "strict", z.ZodTypeAny, {
22
+ resource?: "task-index";
23
+ contractVersion?: 2;
24
+ knownVersion?: string;
25
+ compactAvatars?: boolean;
26
+ avatarVersions?: string[];
27
+ }, {
28
+ resource?: "task-index";
29
+ contractVersion?: 2;
30
+ knownVersion?: string;
31
+ compactAvatars?: boolean;
32
+ avatarVersions?: string[];
33
+ }>, z.ZodObject<{
34
+ after: z.ZodOptional<z.ZodString>;
35
+ limit: z.ZodDefault<z.ZodNumber>;
36
+ resource: z.ZodLiteral<"executions">;
37
+ taskIds: z.ZodArray<z.ZodString, "many">;
38
+ contractVersion: z.ZodLiteral<2>;
39
+ knownVersion: z.ZodOptional<z.ZodString>;
40
+ }, "strict", z.ZodTypeAny, {
41
+ resource?: "executions";
42
+ taskIds?: string[];
43
+ limit?: number;
44
+ contractVersion?: 2;
45
+ knownVersion?: string;
46
+ after?: string;
47
+ }, {
48
+ resource?: "executions";
49
+ taskIds?: string[];
50
+ limit?: number;
51
+ contractVersion?: 2;
52
+ knownVersion?: string;
53
+ after?: string;
54
+ }>, z.ZodObject<{
55
+ resource: z.ZodLiteral<"task-detail">;
56
+ taskId: z.ZodString;
57
+ contractVersion: z.ZodLiteral<2>;
58
+ knownVersion: z.ZodOptional<z.ZodString>;
59
+ }, "strict", z.ZodTypeAny, {
60
+ resource?: "task-detail";
61
+ taskId?: string;
62
+ contractVersion?: 2;
63
+ knownVersion?: string;
64
+ }, {
65
+ resource?: "task-detail";
66
+ taskId?: string;
67
+ contractVersion?: 2;
68
+ knownVersion?: string;
69
+ }>, z.ZodObject<{
70
+ resource: z.ZodLiteral<"execution-detail">;
71
+ taskId: z.ZodString;
72
+ executionId: z.ZodString;
73
+ contractVersion: z.ZodLiteral<2>;
74
+ knownVersion: z.ZodOptional<z.ZodString>;
75
+ }, "strict", z.ZodTypeAny, {
76
+ executionId?: string;
77
+ resource?: "execution-detail";
78
+ taskId?: string;
79
+ contractVersion?: 2;
80
+ knownVersion?: string;
81
+ }, {
82
+ executionId?: string;
83
+ resource?: "execution-detail";
84
+ taskId?: string;
85
+ contractVersion?: 2;
86
+ knownVersion?: string;
87
+ }>, z.ZodObject<{
88
+ resource: z.ZodLiteral<"execution-artifacts">;
89
+ taskId: z.ZodString;
90
+ executionId: z.ZodString;
91
+ contractVersion: z.ZodLiteral<2>;
92
+ knownVersion: z.ZodOptional<z.ZodString>;
93
+ }, "strict", z.ZodTypeAny, {
94
+ executionId?: string;
95
+ resource?: "execution-artifacts";
96
+ taskId?: string;
97
+ contractVersion?: 2;
98
+ knownVersion?: string;
99
+ }, {
100
+ executionId?: string;
101
+ resource?: "execution-artifacts";
102
+ taskId?: string;
103
+ contractVersion?: 2;
104
+ knownVersion?: string;
105
+ }>, z.ZodObject<{
106
+ resource: z.ZodLiteral<"execution-result">;
107
+ taskId: z.ZodString;
108
+ executionId: z.ZodString;
109
+ expectedRevision: z.ZodNumber;
110
+ offset: z.ZodDefault<z.ZodNumber>;
111
+ limit: z.ZodDefault<z.ZodNumber>;
112
+ contractVersion: z.ZodLiteral<2>;
113
+ knownVersion: z.ZodOptional<z.ZodString>;
114
+ }, "strict", z.ZodTypeAny, {
115
+ executionId?: string;
116
+ resource?: "execution-result";
117
+ taskId?: string;
118
+ offset?: number;
119
+ expectedRevision?: number;
120
+ limit?: number;
121
+ contractVersion?: 2;
122
+ knownVersion?: string;
123
+ }, {
124
+ executionId?: string;
125
+ resource?: "execution-result";
126
+ taskId?: string;
127
+ offset?: number;
128
+ expectedRevision?: number;
129
+ limit?: number;
130
+ contractVersion?: 2;
131
+ knownVersion?: string;
132
+ }>]>;
133
+ export type ProjectTaskViewQuery = z.output<typeof projectTaskViewQuerySchema>;
@@ -664,7 +664,7 @@ export interface AppPlatformStatus {
664
664
  }>;
665
665
  }>;
666
666
  }
667
- /** Account-wide storage, using the same snapshot and limits as quota enforcement. */
667
+ /** Storage owned by the current tenant + organization, shared by all members and Apps. */
668
668
  export interface AppPlatformStorageUsage {
669
669
  limitBytes: number;
670
670
  snapshot: {
@@ -14,6 +14,12 @@ export interface IFileAssetSource {
14
14
  filePath?: string;
15
15
  metadata?: Record<string, any>;
16
16
  }
17
+ /** Serializable public failure details, independent of the upload transport. */
18
+ export interface IFileUploadFailure {
19
+ statusCode: number;
20
+ code?: string;
21
+ message: string | string[];
22
+ }
17
23
  export interface IFileAssetDestination {
18
24
  kind: FileAssetDestinationKind;
19
25
  status: 'success' | 'failed';
@@ -22,6 +28,7 @@ export interface IFileAssetDestination {
22
28
  referenceId?: string;
23
29
  metadata?: Record<string, any>;
24
30
  error?: string;
31
+ failure?: IFileUploadFailure;
25
32
  }
26
33
  export interface IFileAsset {
27
34
  name?: string;
@@ -39,4 +39,6 @@ export interface XpertViewAssistantIdentity {
39
39
  currentId: string;
40
40
  versionIds: string[];
41
41
  principalUserId?: string | null;
42
+ /** Persisted Assistant ownership, independent of the viewer's selected organization. */
43
+ organizationId?: string | null;
42
44
  }