@thinkai/tai-api-contract 2.85.0 → 2.89.0-pr.986.c95d8ece
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/dist/generated/openapi.d.ts +125 -3
- package/dist/generated/openapi.d.ts.map +1 -1
- package/openapi/openapi.yaml +131 -4
- package/package.json +1 -1
- package/src/generated/openapi.ts +125 -3
package/openapi/openapi.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
openapi: 3.0.3
|
|
2
2
|
info:
|
|
3
3
|
title: ThinkAI API
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.89.0
|
|
5
5
|
description: >
|
|
6
6
|
Contract surface for the AI Driven SDLC backend used by ThinkAI.
|
|
7
7
|
Workspace-scoped routes use `/workspaces/{workspaceId}/...`.
|
|
@@ -7308,6 +7308,43 @@ paths:
|
|
|
7308
7308
|
"404":
|
|
7309
7309
|
description: Not found
|
|
7310
7310
|
|
|
7311
|
+
/workspaces/{workspaceId}/code-chat/indexes/{indexId}/wiki/export:
|
|
7312
|
+
get:
|
|
7313
|
+
tags: [CodeChat]
|
|
7314
|
+
summary: Export the wiki as an Open Knowledge Format (OKF) v0.2 bundle
|
|
7315
|
+
description: >-
|
|
7316
|
+
Adapter over the stored wiki for OKF-aware platforms and agents. Does not
|
|
7317
|
+
change the live pages. Rewrites `wiki:` links to relative concept paths,
|
|
7318
|
+
adds YAML front matter plus reserved `index.md` / `log.md`, and validates
|
|
7319
|
+
Mermaid (invalid diagrams are demoted to a text fence inside the export).
|
|
7320
|
+
operationId: exportCodeChatWikiOkf
|
|
7321
|
+
x-test-coverage-skip: covered by code-context okf-export unit tests
|
|
7322
|
+
parameters:
|
|
7323
|
+
- $ref: "#/components/parameters/WorkspaceId"
|
|
7324
|
+
- name: indexId
|
|
7325
|
+
in: path
|
|
7326
|
+
required: true
|
|
7327
|
+
schema: { type: string, format: uuid }
|
|
7328
|
+
- name: format
|
|
7329
|
+
in: query
|
|
7330
|
+
required: false
|
|
7331
|
+
schema: { type: string, enum: [okf], default: okf }
|
|
7332
|
+
responses:
|
|
7333
|
+
"200":
|
|
7334
|
+
description: OKF bundle (JSON with a files array of path/content pairs)
|
|
7335
|
+
content:
|
|
7336
|
+
application/json:
|
|
7337
|
+
schema:
|
|
7338
|
+
$ref: "#/components/schemas/CodeChatWikiOkfExportDto"
|
|
7339
|
+
"400":
|
|
7340
|
+
description: Unsupported format
|
|
7341
|
+
"401":
|
|
7342
|
+
$ref: "#/components/responses/Unauthorized"
|
|
7343
|
+
"404":
|
|
7344
|
+
description: Index not found
|
|
7345
|
+
"409":
|
|
7346
|
+
description: Wiki has no pages yet
|
|
7347
|
+
|
|
7311
7348
|
/workspaces/{workspaceId}/code-chat/indexes/{indexId}/wiki/{slug}:
|
|
7312
7349
|
get:
|
|
7313
7350
|
tags: [CodeChat]
|
|
@@ -16949,6 +16986,12 @@ components:
|
|
|
16949
16986
|
edgeCount: { type: integer }
|
|
16950
16987
|
commitSha: { type: string, nullable: true }
|
|
16951
16988
|
errorMessage: { type: string, nullable: true }
|
|
16989
|
+
progressMessage:
|
|
16990
|
+
type: string
|
|
16991
|
+
nullable: true
|
|
16992
|
+
description: >
|
|
16993
|
+
Human-readable indexing stage while a job is running (queued, clone, graph,
|
|
16994
|
+
save, wiki). Cleared when the index is ready or failed.
|
|
16952
16995
|
indexedAt: { type: string, format: date-time, nullable: true }
|
|
16953
16996
|
createdAt: { type: string, format: date-time }
|
|
16954
16997
|
updatedAt: { type: string, format: date-time }
|
|
@@ -16977,6 +17020,12 @@ components:
|
|
|
16977
17020
|
type: array
|
|
16978
17021
|
items: { type: string, format: uuid }
|
|
16979
17022
|
description: Optional subset; omit or empty to enqueue all readiness GitHub repos.
|
|
17023
|
+
force:
|
|
17024
|
+
type: boolean
|
|
17025
|
+
default: false
|
|
17026
|
+
description: >
|
|
17027
|
+
When true, re-enqueue even if the repository is already indexing or was
|
|
17028
|
+
indexed within the last 10 minutes.
|
|
16980
17029
|
|
|
16981
17030
|
CodeChatSyncIndexesResultDto:
|
|
16982
17031
|
type: object
|
|
@@ -16999,7 +17048,7 @@ components:
|
|
|
16999
17048
|
repoName: { type: string }
|
|
17000
17049
|
code:
|
|
17001
17050
|
type: string
|
|
17002
|
-
enum: [repo_ineligible]
|
|
17051
|
+
enum: [repo_ineligible, indexed_recently, index_in_progress]
|
|
17003
17052
|
description: Stable machine-readable skip reason
|
|
17004
17053
|
|
|
17005
17054
|
CodeChatThreadDto:
|
|
@@ -17175,6 +17224,32 @@ components:
|
|
|
17175
17224
|
type: array
|
|
17176
17225
|
items: { $ref: "#/components/schemas/CodeChatWikiPageDto" }
|
|
17177
17226
|
|
|
17227
|
+
CodeChatWikiOkfExportDto:
|
|
17228
|
+
type: object
|
|
17229
|
+
description: >-
|
|
17230
|
+
Portable OKF v0.2 knowledge bundle. Unpack `files` into a directory tree
|
|
17231
|
+
for OKF-aware tools; the in-app wiki is unchanged.
|
|
17232
|
+
required: [kind, okfVersion, generatedAt, repoName, files, demotedDiagrams]
|
|
17233
|
+
properties:
|
|
17234
|
+
kind: { type: string, enum: [okf-bundle] }
|
|
17235
|
+
okfVersion: { type: string, enum: ["0.2"] }
|
|
17236
|
+
generatedAt: { type: string, format: date-time }
|
|
17237
|
+
repoName: { type: string }
|
|
17238
|
+
files:
|
|
17239
|
+
type: array
|
|
17240
|
+
items:
|
|
17241
|
+
type: object
|
|
17242
|
+
required: [path, content]
|
|
17243
|
+
properties:
|
|
17244
|
+
path:
|
|
17245
|
+
type: string
|
|
17246
|
+
description: Path inside the bundle (e.g. concepts/overview.md)
|
|
17247
|
+
content: { type: string }
|
|
17248
|
+
demotedDiagrams:
|
|
17249
|
+
type: array
|
|
17250
|
+
description: Concept paths whose Mermaid failed validation and was exported as a text fence
|
|
17251
|
+
items: { type: string }
|
|
17252
|
+
|
|
17178
17253
|
CodeChatSymbolQueryBodyDto:
|
|
17179
17254
|
type: object
|
|
17180
17255
|
required: [query]
|
|
@@ -17338,8 +17413,21 @@ components:
|
|
|
17338
17413
|
CodeChatVisualizeBodyDto:
|
|
17339
17414
|
type: object
|
|
17340
17415
|
properties:
|
|
17341
|
-
kind:
|
|
17342
|
-
|
|
17416
|
+
kind:
|
|
17417
|
+
type: string
|
|
17418
|
+
enum: [auto, dependency, module, focus, impact, blast, atlas]
|
|
17419
|
+
description: >-
|
|
17420
|
+
Omit or send `auto` to let the server pick the most informative view for the
|
|
17421
|
+
repository. `blast` traces `query` as a symbol and falls back to a focused
|
|
17422
|
+
subgraph, or to impact hotspots when `query` is empty.
|
|
17423
|
+
query:
|
|
17424
|
+
type: string
|
|
17425
|
+
description: >-
|
|
17426
|
+
Symbol, path, or plain-language request ("how does billing reach the ledger").
|
|
17427
|
+
Free text is resolved against the graph to seed a focused view.
|
|
17428
|
+
symbol:
|
|
17429
|
+
type: string
|
|
17430
|
+
description: Deprecated alias for `query`.
|
|
17343
17431
|
repoIds:
|
|
17344
17432
|
type: array
|
|
17345
17433
|
items: { type: string, format: uuid }
|
|
@@ -17358,6 +17446,34 @@ components:
|
|
|
17358
17446
|
note:
|
|
17359
17447
|
type: string
|
|
17360
17448
|
description: Set when dependency edges could not be resolved and a fallback view is shown.
|
|
17449
|
+
architectureBrief:
|
|
17450
|
+
type: string
|
|
17451
|
+
description: >-
|
|
17452
|
+
Short plain-prose narrative for the Engineering Context Graph panel.
|
|
17453
|
+
LLM-written when the workspace has an agent execution key, otherwise a
|
|
17454
|
+
deterministic reading of hubs and areas from the graph.
|
|
17455
|
+
kind:
|
|
17456
|
+
type: string
|
|
17457
|
+
enum: [dependency, module, focus, impact, blast]
|
|
17458
|
+
description: >-
|
|
17459
|
+
Which reading of the repository this diagram is. `module` rolls files up
|
|
17460
|
+
into source groups when too few file dependencies resolved for a file map,
|
|
17461
|
+
`focus` answers a plain-language request, `impact` shows the most
|
|
17462
|
+
depended-on files, and `blast` traces one symbol.
|
|
17463
|
+
insights:
|
|
17464
|
+
type: array
|
|
17465
|
+
description: Measured facts about the graph — hubs, dependency coverage, test share, route count.
|
|
17466
|
+
items: { type: string }
|
|
17467
|
+
focus:
|
|
17468
|
+
type: object
|
|
17469
|
+
description: Present when free text drove the view.
|
|
17470
|
+
required: [query, paths]
|
|
17471
|
+
properties:
|
|
17472
|
+
query: { type: string }
|
|
17473
|
+
paths:
|
|
17474
|
+
type: array
|
|
17475
|
+
description: Files that matched the request and seeded the graph.
|
|
17476
|
+
items: { type: string }
|
|
17361
17477
|
nodes:
|
|
17362
17478
|
type: array
|
|
17363
17479
|
items:
|
|
@@ -17367,6 +17483,17 @@ components:
|
|
|
17367
17483
|
id: { type: string }
|
|
17368
17484
|
label: { type: string }
|
|
17369
17485
|
kind: { type: string }
|
|
17486
|
+
path: { type: string }
|
|
17487
|
+
summary: { type: string }
|
|
17488
|
+
group: { type: string }
|
|
17489
|
+
inDegree: { type: integer }
|
|
17490
|
+
outDegree: { type: integer }
|
|
17491
|
+
isFocus:
|
|
17492
|
+
type: boolean
|
|
17493
|
+
description: File matched the request; highlight it as the answer.
|
|
17494
|
+
weight:
|
|
17495
|
+
type: integer
|
|
17496
|
+
description: Files behind a module box.
|
|
17370
17497
|
edges:
|
|
17371
17498
|
type: array
|
|
17372
17499
|
items:
|
package/package.json
CHANGED
package/src/generated/openapi.ts
CHANGED
|
@@ -2848,6 +2848,26 @@ export interface paths {
|
|
|
2848
2848
|
patch?: never;
|
|
2849
2849
|
trace?: never;
|
|
2850
2850
|
};
|
|
2851
|
+
"/workspaces/{workspaceId}/code-chat/indexes/{indexId}/wiki/export": {
|
|
2852
|
+
parameters: {
|
|
2853
|
+
query?: never;
|
|
2854
|
+
header?: never;
|
|
2855
|
+
path?: never;
|
|
2856
|
+
cookie?: never;
|
|
2857
|
+
};
|
|
2858
|
+
/**
|
|
2859
|
+
* Export the wiki as an Open Knowledge Format (OKF) v0.2 bundle
|
|
2860
|
+
* @description Adapter over the stored wiki for OKF-aware platforms and agents. Does not change the live pages. Rewrites `wiki:` links to relative concept paths, adds YAML front matter plus reserved `index.md` / `log.md`, and validates Mermaid (invalid diagrams are demoted to a text fence inside the export).
|
|
2861
|
+
*/
|
|
2862
|
+
get: operations["exportCodeChatWikiOkf"];
|
|
2863
|
+
put?: never;
|
|
2864
|
+
post?: never;
|
|
2865
|
+
delete?: never;
|
|
2866
|
+
options?: never;
|
|
2867
|
+
head?: never;
|
|
2868
|
+
patch?: never;
|
|
2869
|
+
trace?: never;
|
|
2870
|
+
};
|
|
2851
2871
|
"/workspaces/{workspaceId}/code-chat/indexes/{indexId}/wiki/{slug}": {
|
|
2852
2872
|
parameters: {
|
|
2853
2873
|
query?: never;
|
|
@@ -7334,6 +7354,8 @@ export interface components {
|
|
|
7334
7354
|
edgeCount: number;
|
|
7335
7355
|
commitSha?: string | null;
|
|
7336
7356
|
errorMessage?: string | null;
|
|
7357
|
+
/** @description Human-readable indexing stage while a job is running (queued, clone, graph, save, wiki). Cleared when the index is ready or failed. */
|
|
7358
|
+
progressMessage?: string | null;
|
|
7337
7359
|
/** Format: date-time */
|
|
7338
7360
|
indexedAt?: string | null;
|
|
7339
7361
|
/** Format: date-time */
|
|
@@ -7353,6 +7375,11 @@ export interface components {
|
|
|
7353
7375
|
CodeChatSyncIndexesBodyDto: {
|
|
7354
7376
|
/** @description Optional subset; omit or empty to enqueue all readiness GitHub repos. */
|
|
7355
7377
|
repoIds?: string[];
|
|
7378
|
+
/**
|
|
7379
|
+
* @description When true, re-enqueue even if the repository is already indexing or was indexed within the last 10 minutes.
|
|
7380
|
+
* @default false
|
|
7381
|
+
*/
|
|
7382
|
+
force: boolean;
|
|
7356
7383
|
};
|
|
7357
7384
|
CodeChatSyncIndexesResultDto: {
|
|
7358
7385
|
enqueued: number;
|
|
@@ -7368,7 +7395,7 @@ export interface components {
|
|
|
7368
7395
|
* @description Stable machine-readable skip reason
|
|
7369
7396
|
* @enum {string}
|
|
7370
7397
|
*/
|
|
7371
|
-
code: "repo_ineligible";
|
|
7398
|
+
code: "repo_ineligible" | "indexed_recently" | "index_in_progress";
|
|
7372
7399
|
};
|
|
7373
7400
|
CodeChatThreadDto: {
|
|
7374
7401
|
/** Format: uuid */
|
|
@@ -7495,6 +7522,23 @@ export interface components {
|
|
|
7495
7522
|
CodeChatWikiPageListDto: {
|
|
7496
7523
|
items: components["schemas"]["CodeChatWikiPageDto"][];
|
|
7497
7524
|
};
|
|
7525
|
+
/** @description Portable OKF v0.2 knowledge bundle. Unpack `files` into a directory tree for OKF-aware tools; the in-app wiki is unchanged. */
|
|
7526
|
+
CodeChatWikiOkfExportDto: {
|
|
7527
|
+
/** @enum {string} */
|
|
7528
|
+
kind: "okf-bundle";
|
|
7529
|
+
/** @enum {string} */
|
|
7530
|
+
okfVersion: "0.2";
|
|
7531
|
+
/** Format: date-time */
|
|
7532
|
+
generatedAt: string;
|
|
7533
|
+
repoName: string;
|
|
7534
|
+
files: {
|
|
7535
|
+
/** @description Path inside the bundle (e.g. concepts/overview.md) */
|
|
7536
|
+
path: string;
|
|
7537
|
+
content: string;
|
|
7538
|
+
}[];
|
|
7539
|
+
/** @description Concept paths whose Mermaid failed validation and was exported as a text fence */
|
|
7540
|
+
demotedDiagrams: string[];
|
|
7541
|
+
};
|
|
7498
7542
|
CodeChatSymbolQueryBodyDto: {
|
|
7499
7543
|
query: string;
|
|
7500
7544
|
repoIds?: string[];
|
|
@@ -7595,8 +7639,14 @@ export interface components {
|
|
|
7595
7639
|
}[];
|
|
7596
7640
|
};
|
|
7597
7641
|
CodeChatVisualizeBodyDto: {
|
|
7598
|
-
/**
|
|
7599
|
-
|
|
7642
|
+
/**
|
|
7643
|
+
* @description Omit or send `auto` to let the server pick the most informative view for the repository. `blast` traces `query` as a symbol and falls back to a focused subgraph, or to impact hotspots when `query` is empty.
|
|
7644
|
+
* @enum {string}
|
|
7645
|
+
*/
|
|
7646
|
+
kind?: "auto" | "dependency" | "module" | "focus" | "impact" | "blast" | "atlas";
|
|
7647
|
+
/** @description Symbol, path, or plain-language request ("how does billing reach the ledger"). Free text is resolved against the graph to seed a focused view. */
|
|
7648
|
+
query?: string;
|
|
7649
|
+
/** @description Deprecated alias for `query`. */
|
|
7600
7650
|
symbol?: string;
|
|
7601
7651
|
repoIds?: string[];
|
|
7602
7652
|
};
|
|
@@ -7611,10 +7661,34 @@ export interface components {
|
|
|
7611
7661
|
source: string;
|
|
7612
7662
|
/** @description Set when dependency edges could not be resolved and a fallback view is shown. */
|
|
7613
7663
|
note?: string;
|
|
7664
|
+
/** @description Short plain-prose narrative for the Engineering Context Graph panel. LLM-written when the workspace has an agent execution key, otherwise a deterministic reading of hubs and areas from the graph. */
|
|
7665
|
+
architectureBrief?: string;
|
|
7666
|
+
/**
|
|
7667
|
+
* @description Which reading of the repository this diagram is. `module` rolls files up into source groups when too few file dependencies resolved for a file map, `focus` answers a plain-language request, `impact` shows the most depended-on files, and `blast` traces one symbol.
|
|
7668
|
+
* @enum {string}
|
|
7669
|
+
*/
|
|
7670
|
+
kind?: "dependency" | "module" | "focus" | "impact" | "blast";
|
|
7671
|
+
/** @description Measured facts about the graph — hubs, dependency coverage, test share, route count. */
|
|
7672
|
+
insights?: string[];
|
|
7673
|
+
/** @description Present when free text drove the view. */
|
|
7674
|
+
focus?: {
|
|
7675
|
+
query: string;
|
|
7676
|
+
/** @description Files that matched the request and seeded the graph. */
|
|
7677
|
+
paths: string[];
|
|
7678
|
+
};
|
|
7614
7679
|
nodes: {
|
|
7615
7680
|
id: string;
|
|
7616
7681
|
label: string;
|
|
7617
7682
|
kind?: string;
|
|
7683
|
+
path?: string;
|
|
7684
|
+
summary?: string;
|
|
7685
|
+
group?: string;
|
|
7686
|
+
inDegree?: number;
|
|
7687
|
+
outDegree?: number;
|
|
7688
|
+
/** @description File matched the request; highlight it as the answer. */
|
|
7689
|
+
isFocus?: boolean;
|
|
7690
|
+
/** @description Files behind a module box. */
|
|
7691
|
+
weight?: number;
|
|
7618
7692
|
}[];
|
|
7619
7693
|
edges: {
|
|
7620
7694
|
from: string;
|
|
@@ -8314,6 +8388,7 @@ export type CodeChatModuleInventoryRowDto = components['schemas']['CodeChatModul
|
|
|
8314
8388
|
export type CodeChatStructuredBlockDto = components['schemas']['CodeChatStructuredBlockDto'];
|
|
8315
8389
|
export type CodeChatWikiPageDto = components['schemas']['CodeChatWikiPageDto'];
|
|
8316
8390
|
export type CodeChatWikiPageListDto = components['schemas']['CodeChatWikiPageListDto'];
|
|
8391
|
+
export type CodeChatWikiOkfExportDto = components['schemas']['CodeChatWikiOkfExportDto'];
|
|
8317
8392
|
export type CodeChatSymbolQueryBodyDto = components['schemas']['CodeChatSymbolQueryBodyDto'];
|
|
8318
8393
|
export type CodeChatSymbolHitDto = components['schemas']['CodeChatSymbolHitDto'];
|
|
8319
8394
|
export type CodeChatSymbolHitListDto = components['schemas']['CodeChatSymbolHitListDto'];
|
|
@@ -15838,6 +15913,53 @@ export interface operations {
|
|
|
15838
15913
|
};
|
|
15839
15914
|
};
|
|
15840
15915
|
};
|
|
15916
|
+
exportCodeChatWikiOkf: {
|
|
15917
|
+
parameters: {
|
|
15918
|
+
query?: {
|
|
15919
|
+
format?: "okf";
|
|
15920
|
+
};
|
|
15921
|
+
header?: never;
|
|
15922
|
+
path: {
|
|
15923
|
+
workspaceId: components["parameters"]["WorkspaceId"];
|
|
15924
|
+
indexId: string;
|
|
15925
|
+
};
|
|
15926
|
+
cookie?: never;
|
|
15927
|
+
};
|
|
15928
|
+
requestBody?: never;
|
|
15929
|
+
responses: {
|
|
15930
|
+
/** @description OKF bundle (JSON with a files array of path/content pairs) */
|
|
15931
|
+
200: {
|
|
15932
|
+
headers: {
|
|
15933
|
+
[name: string]: unknown;
|
|
15934
|
+
};
|
|
15935
|
+
content: {
|
|
15936
|
+
"application/json": components["schemas"]["CodeChatWikiOkfExportDto"];
|
|
15937
|
+
};
|
|
15938
|
+
};
|
|
15939
|
+
/** @description Unsupported format */
|
|
15940
|
+
400: {
|
|
15941
|
+
headers: {
|
|
15942
|
+
[name: string]: unknown;
|
|
15943
|
+
};
|
|
15944
|
+
content?: never;
|
|
15945
|
+
};
|
|
15946
|
+
401: components["responses"]["Unauthorized"];
|
|
15947
|
+
/** @description Index not found */
|
|
15948
|
+
404: {
|
|
15949
|
+
headers: {
|
|
15950
|
+
[name: string]: unknown;
|
|
15951
|
+
};
|
|
15952
|
+
content?: never;
|
|
15953
|
+
};
|
|
15954
|
+
/** @description Wiki has no pages yet */
|
|
15955
|
+
409: {
|
|
15956
|
+
headers: {
|
|
15957
|
+
[name: string]: unknown;
|
|
15958
|
+
};
|
|
15959
|
+
content?: never;
|
|
15960
|
+
};
|
|
15961
|
+
};
|
|
15962
|
+
};
|
|
15841
15963
|
getCodeChatWikiPage: {
|
|
15842
15964
|
parameters: {
|
|
15843
15965
|
query?: never;
|