@thinkai/tai-api-contract 2.177.0 → 2.181.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.
@@ -66,6 +66,48 @@ export interface paths {
66
66
  patch?: never;
67
67
  trace?: never;
68
68
  };
69
+ "/admin/workspaces/{workspaceId}/assessment-preflight": {
70
+ parameters: {
71
+ query?: never;
72
+ header?: never;
73
+ path?: never;
74
+ cookie?: never;
75
+ };
76
+ get?: never;
77
+ put?: never;
78
+ /**
79
+ * Evaluate assessment preflight from server-loaded evidence
80
+ * @description Loads repository scope, readiness scan age, and window coverage for one workspace. Client fields for scope, scans, windows, and engineer counts are ignored, so an unscanned source cannot be marked fresh. The five-business-day clock uses Monday–Friday in America/New_York and is stored on the first passing result. A later blocker does not clear it. Active-engineer counts stay unloaded until stored activity can be counted.
81
+ * **Authorization:** Bearer JWT required. Caller email must appear in `PLATFORM_ADMIN_EMAILS`.
82
+ */
83
+ post: operations["runLiveAssessmentPreflight"];
84
+ delete?: never;
85
+ options?: never;
86
+ head?: never;
87
+ patch?: never;
88
+ trace?: never;
89
+ };
90
+ "/admin/assessment-queue": {
91
+ parameters: {
92
+ query?: never;
93
+ header?: never;
94
+ path?: never;
95
+ cookie?: never;
96
+ };
97
+ /**
98
+ * List operator assessment records
99
+ * @description Returns the stored assessment record for each workspace an operator has evaluated. The next blocker is on this list. A second workspace is not required.
100
+ * **Authorization:** Bearer JWT required. Caller email must appear in `PLATFORM_ADMIN_EMAILS`.
101
+ */
102
+ get: operations["listAssessmentQueue"];
103
+ put?: never;
104
+ post?: never;
105
+ delete?: never;
106
+ options?: never;
107
+ head?: never;
108
+ patch?: never;
109
+ trace?: never;
110
+ };
69
111
  "/admin/assessment-manifest-validation": {
70
112
  parameters: {
71
113
  query?: never;
@@ -3431,6 +3473,26 @@ export interface paths {
3431
3473
  patch?: never;
3432
3474
  trace?: never;
3433
3475
  };
3476
+ "/workspaces/{workspaceId}/knowledge-pages/{slug}": {
3477
+ parameters: {
3478
+ query?: never;
3479
+ header?: never;
3480
+ path?: never;
3481
+ cookie?: never;
3482
+ };
3483
+ get?: never;
3484
+ put?: never;
3485
+ post?: never;
3486
+ /**
3487
+ * Delete a workspace knowledge page by slug
3488
+ * @description Removes one page (typically a `prd-*` / `rfc-*` / `adr-*` draft). Does not regenerate the rest of the knowledge base.
3489
+ */
3490
+ delete: operations["deleteWorkspaceKnowledgePage"];
3491
+ options?: never;
3492
+ head?: never;
3493
+ patch?: never;
3494
+ trace?: never;
3495
+ };
3434
3496
  "/workspaces/{workspaceId}/knowledge-pages/generate": {
3435
3497
  parameters: {
3436
3498
  query?: never;
@@ -10304,12 +10366,21 @@ export interface components {
10304
10366
  * @description Classified Ask intent for the turn
10305
10367
  * @enum {string}
10306
10368
  */
10307
- intent?: "inventory_apis" | "inventory_modules" | "explain" | "platform_ops" | "feature_impact" | "prd_request";
10369
+ intent?: "inventory_apis" | "inventory_modules" | "explain" | "platform_ops" | "feature_impact" | "pr_review" | "prd_request";
10308
10370
  /**
10309
10371
  * @description Conversation skill pack that grounded the LLM answer (Wave 10)
10310
10372
  * @enum {string}
10311
10373
  */
10312
- skillId?: "chat-api-detail" | "chat-architecture" | "chat-tests" | "chat-contracts" | "chat-cicd" | "chat-stack" | "chat-platform" | "chat-wiki";
10374
+ skillId?: "chat-api-detail" | "chat-architecture" | "chat-tests" | "chat-contracts" | "chat-cicd" | "chat-stack" | "chat-platform" | "chat-workspace" | "chat-product" | "chat-pr-review" | "chat-wiki";
10375
+ /** @description Short customer-safe summary when mode is failed. Shown in the reply body; raw provider detail is only in providerFailures / debug marker. */
10376
+ userMessage?: string;
10377
+ /** @description Structured provider failures for Conversations ⓘ hover (primary first). Also embedded in content as `<!-- code-intel-debug:{...} -->` for reload. */
10378
+ providerFailures?: {
10379
+ /** @enum {string} */
10380
+ provider: "anthropic_messages" | "cursor_agent";
10381
+ sanitized: string;
10382
+ raw: string;
10383
+ }[];
10313
10384
  usage?: components["schemas"]["CodeIntelligenceUsageDto"];
10314
10385
  };
10315
10386
  CodeChatApiRouteRowDto: {
@@ -12705,6 +12776,182 @@ export interface operations {
12705
12776
  };
12706
12777
  };
12707
12778
  };
12779
+ runLiveAssessmentPreflight: {
12780
+ parameters: {
12781
+ query?: never;
12782
+ header?: never;
12783
+ path: {
12784
+ workspaceId: components["parameters"]["WorkspaceId"];
12785
+ };
12786
+ cookie?: never;
12787
+ };
12788
+ requestBody: {
12789
+ content: {
12790
+ "application/json": {
12791
+ /** @enum {string} */
12792
+ offerId: "engineering_readiness_baseline" | "agentic_ai_roi";
12793
+ /** @enum {string} */
12794
+ sourceControl: "connected" | "pending_approval" | "setup_in_progress" | "revoked" | "stale" | "missing";
12795
+ platformExecutionReady: boolean;
12796
+ premiumAi: {
12797
+ cursor: boolean;
12798
+ claude: boolean;
12799
+ copilot: boolean;
12800
+ };
12801
+ jiraSelected: boolean;
12802
+ incidentSelected: boolean;
12803
+ incidentAvailable: boolean;
12804
+ owner?: string | null;
12805
+ };
12806
+ };
12807
+ };
12808
+ responses: {
12809
+ /** @description Preflight result. `dueDate` is set once the clock has started and stays set if a later check is blocked. */
12810
+ 200: {
12811
+ headers: {
12812
+ [name: string]: unknown;
12813
+ };
12814
+ content: {
12815
+ "application/json": {
12816
+ ready: boolean;
12817
+ clockStarted: boolean;
12818
+ /** Format: date */
12819
+ dueDate: string | null;
12820
+ owner: string | null;
12821
+ blocker: string | null;
12822
+ nextAction: {
12823
+ label: string;
12824
+ href: string | null;
12825
+ } | null;
12826
+ failures: {
12827
+ code: string;
12828
+ blocker: string;
12829
+ nextAction: {
12830
+ label: string;
12831
+ href: string | null;
12832
+ };
12833
+ }[];
12834
+ chapters: {
12835
+ /** @enum {string} */
12836
+ id: "jira" | "incidents";
12837
+ /** @enum {string} */
12838
+ status: "unavailable";
12839
+ reason: string;
12840
+ }[];
12841
+ };
12842
+ };
12843
+ };
12844
+ /** @description Body or workspace id failed validation. */
12845
+ 400: {
12846
+ headers: {
12847
+ [name: string]: unknown;
12848
+ };
12849
+ content: {
12850
+ /**
12851
+ * @example {
12852
+ * "error": "offerId is not a known assessment offer",
12853
+ * "code": "invalid_body"
12854
+ * }
12855
+ */
12856
+ "application/json": components["schemas"]["ErrorMessageDto"];
12857
+ };
12858
+ };
12859
+ /** @description Missing or invalid JWT. */
12860
+ 401: {
12861
+ headers: {
12862
+ [name: string]: unknown;
12863
+ };
12864
+ content: {
12865
+ "application/json": components["schemas"]["ErrorMessageDto"];
12866
+ };
12867
+ };
12868
+ /** @description Caller is not a platform admin. */
12869
+ 403: {
12870
+ headers: {
12871
+ [name: string]: unknown;
12872
+ };
12873
+ content: {
12874
+ /**
12875
+ * @example {
12876
+ * "error": "Forbidden",
12877
+ * "code": "forbidden"
12878
+ * }
12879
+ */
12880
+ "application/json": components["schemas"]["ErrorMessageDto"];
12881
+ };
12882
+ };
12883
+ /** @description Evidence store is unavailable. */
12884
+ 503: {
12885
+ headers: {
12886
+ [name: string]: unknown;
12887
+ };
12888
+ content: {
12889
+ "application/json": components["schemas"]["ErrorMessageDto"];
12890
+ };
12891
+ };
12892
+ };
12893
+ };
12894
+ listAssessmentQueue: {
12895
+ parameters: {
12896
+ query?: never;
12897
+ header?: never;
12898
+ path?: never;
12899
+ cookie?: never;
12900
+ };
12901
+ requestBody?: never;
12902
+ responses: {
12903
+ /** @description Operator queue. */
12904
+ 200: {
12905
+ headers: {
12906
+ [name: string]: unknown;
12907
+ };
12908
+ content: {
12909
+ "application/json": {
12910
+ records: {
12911
+ /** Format: uuid */
12912
+ workspaceId: string;
12913
+ /** @enum {string} */
12914
+ offerId: "engineering_readiness_baseline" | "agentic_ai_roi";
12915
+ ready: boolean;
12916
+ blocker: string | null;
12917
+ nextAction: {
12918
+ label: string;
12919
+ href: string | null;
12920
+ } | null;
12921
+ /** Format: date */
12922
+ dueDate: string | null;
12923
+ /** Format: date-time */
12924
+ evaluatedAt: string;
12925
+ }[];
12926
+ };
12927
+ };
12928
+ };
12929
+ /** @description Missing or invalid JWT. */
12930
+ 401: {
12931
+ headers: {
12932
+ [name: string]: unknown;
12933
+ };
12934
+ content: {
12935
+ "application/json": components["schemas"]["ErrorMessageDto"];
12936
+ };
12937
+ };
12938
+ /** @description Caller is not a platform admin. */
12939
+ 403: {
12940
+ headers: {
12941
+ [name: string]: unknown;
12942
+ };
12943
+ content: {
12944
+ /**
12945
+ * @example {
12946
+ * "error": "Forbidden",
12947
+ * "code": "forbidden"
12948
+ * }
12949
+ */
12950
+ "application/json": components["schemas"]["ErrorMessageDto"];
12951
+ };
12952
+ };
12953
+ };
12954
+ };
12708
12955
  runAssessmentManifestValidation: {
12709
12956
  parameters: {
12710
12957
  query?: never;
@@ -21747,6 +21994,37 @@ export interface operations {
21747
21994
  401: components["responses"]["Unauthorized"];
21748
21995
  };
21749
21996
  };
21997
+ deleteWorkspaceKnowledgePage: {
21998
+ parameters: {
21999
+ query?: never;
22000
+ header?: never;
22001
+ path: {
22002
+ workspaceId: components["parameters"]["WorkspaceId"];
22003
+ slug: string;
22004
+ };
22005
+ cookie?: never;
22006
+ };
22007
+ requestBody?: never;
22008
+ responses: {
22009
+ /** @description Page deleted */
22010
+ 204: {
22011
+ headers: {
22012
+ [name: string]: unknown;
22013
+ };
22014
+ content?: never;
22015
+ };
22016
+ 401: components["responses"]["Unauthorized"];
22017
+ /** @description Page not found (`knowledge_page_not_found`) */
22018
+ 404: {
22019
+ headers: {
22020
+ [name: string]: unknown;
22021
+ };
22022
+ content: {
22023
+ "application/json": components["schemas"]["ErrorMessageDto"];
22024
+ };
22025
+ };
22026
+ };
22027
+ };
21750
22028
  generateWorkspaceKnowledgePages: {
21751
22029
  parameters: {
21752
22030
  query?: never;